I am using a USB DAC which has two audio outputs, one is pure DAC output and the other one is amplified.
Can I read the sound level directly from the audio jack with Arduino?
The questions are:Can I read the sound level directly from the audio jack with Arduino?How should I connect the electrical components?Do I need any resistor or capacitor? Why?
This is the place to start:- http://interface.khm.de/index.php/labor/experimente/arduino-realtime-audio-processing/Read that and get the idea of what you are doing. You need two resistors and a capacitor like the input side shows.Never come across an USB DAC have you got a link? What has the Arduino got to do with this?Yes but for the largest dynamic range you need to have a signal that is +/- 2.5V.Do you actually want the sound signal or just the envelope?
No, not directly, you need two resistors for coupling the audio signal into Arduinos analog input, i.e. A0.I've searched acircuit schematics for youThis circuit can be used for coupling the audio output from your smarthone or "line out" from your PC into Ar duino:You can leave out resistor R1 and capacitor C, but you need those two 100K resistors R2 as voltage divider.Value of R2=100K is not critical.You can use R2=68K or R2=82K as well.But don't use this circuit with coupling of output from power amplifiers, which could provide dozens of volt output power.This is circuit is suitable for PC "line out" audio level or for audio output from your smartphone only, not for output from power amplifiers.
but why would they do in this way
Are the resistors and capacitor used to make the audio signal into the range 0-5v?
I expect to read the analog value as 0-1023 (loudness)
Thank you for the circuit. I think it is the simplest one I have seen in these few days.
But I found some circuits suggest using 0.47uF capacitor, what are the differences?
I am not very good at reading circuit diagrams, I would be appreciate if you could make me a simulation picture with the Arduino, breadboard and other electrical components,
Am I doing it right?
No, and you are wasting both your time and ours with Fritzing.
No.You have no diode.The resistor is connected to both sides of the capacitor.@doug - he is trying to implement the envelope follower circuit. That will do for just the volume indication he wants.
How about this one?
Yes a lot better.