Well, I would like to know is you guys could give some ideas in order to do this project.
Im looking to:
1.- Connect a sound sensor as a microphone.
2.- get an input line in arduino from any device as audio source.
3.- get an output line in arduino to connect a line for the speakers or amplifier if apply.
4.- if the microphone detects a lot of noise volume down the output source, and the opposite if the micro detects almost no sound.
Thank you in advance I will try my best to look deep in your recommendations.
If the microphone picks-up too much program material instead of the background/environmental noise things could get "weird".
You can get digital potentiometers. (A regular mechanical volume control is a "pot".) There are a few different ways that digital pots are controlled but the Arduino can work with most (all?) kinds.
But... There are a couple of things to watch-out for - Audio is sensitive to noise so you'll have to keep the power supplies "clean" and make sure no digital switching noise leaks into the audio circuitry. And, you'll need to make sure the digital pots work with AC signals. If not, you may need to bias the signal going into the pot (so it never actually goes negative) and then filter the bias out before the signal goes-on to the amplifier.
You'll also need to make sure the pot is reset to minimum, or reset to the last setting at power-on. (I believe there are digital pots with non-volatile memory.)
:o Thanks DVDdoug, this morning i discover digital potentiometers in a paper.. I will get some and begin to write some codes.. I dont have so much (any) knowledge abot audio so I dont get it when you said about the AC signals, alternating current, right? Getting familiar with biasing
You have to put the microphone near the noise source, where noise is much higher than music, otherwise it will work like an AGC (automatic level control) on the music.
The arduino works with digital signals, you need to do this with the A/D
You need a DAC or CODAC for this.
That is possible however it is a lot more involved then just pointing a microphone. You describe an AGC but you want to front end it with a noise filter.
This will be a very difficult project and I do not feel the arduino can do all the math etc needed for your filters and the converters. There is probably commercial equipment that will do this.