i have a mono ampifier (velleman k8066) http://www.velleman.eu/products/view/?id=354552
and i want to use it to connect my mic (first just my mp3 player) to the arduino (mega), but their are 2 output pins on the amplifier (+ out -)
can i just read this on the analog input pins from the arduino (and what kind of value do i get) ?
I want to make some lights that burn when the music gets louder (or with the beats) (so just beat/sound detection)
As it is the measure of the voltage of the sound waveform it can be any voltage, but the louder it gets the more extreme will be the readings. Normal silence will be about 512, then quite might be values between 412 and 612 with full volume giving values between 0 and 1023.
I want to make some lights that burn when the music gets louder
So you will want to put a peak detector circuit on before the arduino input as well, google for a schematic.
first of al thank you for the reply !
No you need some signal conditioning and AC coupling like shown on the front of this circuit
==> But i already have the board amplifier ? Or do i have to make that circuit and connect my 2 Out pins of the velleman 8066 to the place where the audio line in jack is on this pic: http://interface.khm.de/wp-content/uploads/2008/11/arduinoaudiofig1.gif ? i can't just connect the 2 output pins to annalog pin 0 and 1 ?
And i tried to messure the output + and - pin on the amplifier but voltage was about (0.500 - 0.600 v)
So you will want to put a peak detector circuit on before the arduino input as well, google for a schematic.
==> Can't i just program when i get a high value on the analog input that there have to burn more lights en when their is a low value, their burn just a few lights ?
i can't just connect the 2 output pins to annalog pin 0 and 1 ?
No that will not work because of two things:-
There is no common reference point between your amplifier and the arduino so you won't actually measure anything.
The analogue input to the arduino will fry if you put negative voltages into it.
Therefore you have to connect the -ve of your speaker to the arduino ground and the +ve output to a capacitor. The other end of the capacitor to go to the arduino input with a resistor from the input to ground and input to +5. This will bias the signal to a mid 2.5V.
Can't i just program when i get a high value on the analog input that there have to burn more lights en when their is a low value
You can do that but will not get the effect you want. When the sound is low you will only get a small range of values. When the sound is loud you will get a large range of values which include the values you got when the sound was low. As these are sampled at different parts of the waveform this will be just like random numbers and have little visual relationship with the sound.
ok so like the image on the bottom of this site : ha: Pebrero 2011
But I only have a 22uF capacitor instead of an 10 uF is that also ok or do I need to change the resistors ?
How you power up a kit? Chip works as low as 5 V, probably you could by pass a diode on a board (just use different color wires for power line, and be careful not to swap "+" and ground "-"). Than output of the IC TDA7267 pin 2 would be close to Vpower/2 and you can connect it to analog input directly if you power a kit with arduino +5V.