sound/motion sensor

I'm interested in using a sound (or motion) sensor as a way to have the ambient sound (or motion) effect the volume of an audio device. I.e when the ambient sound gets loud the the volume gets loud.
Any suggestions on where to start. (i'm assuming the best route would be to control the speaker as opposed to the the volume of the playback device)

Thanks a bunch

You might consider using an audio taper (logarithmic) digital potentiometer. Personally, I think it would be easier to control the input to the preamp rather than the output to the speaker.

There is an app note here:

Well, the sound coming out of the speaker becomes part of the “ambient sound”, so you can find yourself in a feedback loop where the system quickly cranks the volume up to the max, regardless of what the initial ambient noise was.

You need to somehow subtract the music signal from the total measurement, and vary the scaling of that amount depending on the volume at the speaker.


Yeah, you would have to compare the inverted sound system signal, properly phase shifted, to the total room sound and the result would be the "noise".

You would need to arrive at a ratio of good sound to noise that gave you the "legibility" of the good sound you were looking for. There would be a point where your ears were saturated and no amount of amplification would help.

Some car stereos do it already.

JHP, would you be just as happy canceling the noise? I think that would be a lot easier and would save your ears.

Thanks everyone! Actuallywhat I'm actually trying to do is have an environment that responds a little differently. Let me be more specific, I would like to have one channel of audio ascend and another channel descend as a response to activity in the room. Maybe it would be easier with motion sensors but I'd had in mind trying this as a response to ambient sound.