djsfantasi
- Joined Apr 11, 2010
- 9,163
Nice! Do you have a link to or a copy of the LTSpice model for it?
Nice! Do you have a link to or a copy of the LTSpice model for it?
The reason I called it confusing was that like I said, components were connected in the middle of the two batteries, which with a normal wallwart, I don't think is possible. Now that I know that circuit won't work, it doesn't really matter.Why is it confusing (see my earlier post). You have +9 and then -9. A range of 18V.
I will check it out. Thanks.But if all you need is coarse following of the audio signal, then I have this project on the site. The professionals will tear it apart. Some will say it doesn’t/can’t work. But I’ve been using it for 10 years. The linked project even has an alternative circuit.
I present it as is. It works with a single side supply op amp. And the published versions give you a 0V to 4V output, sufficiently wide to process audio by the Arduino. I’m working on replacing the LT1013 with a TLV2462, which has a rail to rail output.
I was looking at them, and for 5 it was 15 pounds, which is still a fair bit, along with a tax of 14 pounds which really pushes it out of my price range.What do you consider pricey?
@BobTPH has suggested using the MCP6002. Briefly looking at the specs, it seems right for my applications - correct me if I'm wrong here.1) Eliminate the batteries and use the 5V supply.
2) Select an opamp which will work on a single 5V supply.
3) Select the appropriate input and output bias voltages.
And, just to be clear, use it in a circuit similar to that in #6. You need to adjust the gain and input filter though. I would change the input resistor to 10K. This would allow gain of 0-10 which should be in the right range for a line input.@BobTPH has suggested using the MCP6002. Briefly looking at the specs, it seems right for my applications - correct me if I'm wrong here.
33 cents / 1. Amazing.
Ok, good to know, thanks!And, just to be clear, use it in a circuit similar to that in #6. You need to adjust the gain and input filter though. I would change the input resistor to 10K. This would allow gain of 0-10 which should be in the right range for a line input.
Then you need to decide on the upper frequency limit and change the capacitor to make set the corner frequency.
Bob
Thanks for the recommendation.33 cents / 1. Amazing.
If you want to use a single supply with a GP amp with a cap coupled signal path, consider a rail-splitter for the power supply. I've used this one.
Thanks for the reply. I assume this circuit will not clamp the voltage between 0-5, will it?Here is a circuit for a precision rectifier.
Instead of the TL084, use a single supply opamp. You will need to create a signal common at half the supply voltage.
On second thought, since you only need the amplitude envelope, you can scrap the precision rectifier idea and use a half wave rectifier.
If I was using the rail-splitter suggested would I hook it up like this? (and again, sorry for the crudeness)33 cents / 1. Amazing.
If you want to use a single supply with a GP amp with a cap coupled signal path, consider a rail-splitter for the power supply. I've used this one.
I'm not sure I quite get you. What is the 'same problem'?A peak detector or precision rectifier has the same problem. Only a rail-to-rail opamp can output voltages over the entire range of its supply voltage.
You need an opamp like the one I recommended for any of the circuits.
Bob
Thanks for the help.It would be useful if those who d not know would not reply as though they did know.
The simple approach is to substitute an op-amp that will work with a single supply, such as an LM358. The whole thing can run from a single +5 volt supply, with the + input biased to half the 5 volts by a voltage divider , which has already been shown. The circuit shown in post #15 is good, just be sure to use the correct connections to the LM358.
The sole reason for using the two batteries is to provide the dual power supply required by that kind of op-amp. Don't think of it as 2 batteries in series, rather as a dual polarity supply.
The LM358, connected like the circuit in post #6, with the same 100mfd capacitor and the two 100K resistors tied to the input pin of the arduino, should work. The important thing is that the + input of the opamp is biased to about 1/2 the supply voltage, so that the output can swing from zero to the supply voltage, or at least up and down by two volts. You can also try a model of your exact circuit in spice, to see how it should work.I didn't want to have to bring attention back to this post, but I am going to have to.
I have just received my LM358's. I have put them in a circuit like #15 however it isn't working. The audio signal is not being amplified and is being read by the Arduino as 0.0. The pinouts are correct.
I googled for other LM358 circuits online and there were many different schematics. How do I know what one I should choose?
Bod
Stop thinking for a moment, and THINK. Two 9V batteries in series = 18VDC. If you connect between them, it means part of your circuit needs +9V, and another part of the circuit needs -9V. Audio is A/C (not D/C). Which means it rides on both sides of zero volts. Your arduino may be digital (using plus voltage), but your audio signal is analog, using both positive & negative voltage.
by Duane Benson
by Aaron Carman
by Don Wilcher