Adjusting this schematic to remove the two 9v batteries.

Thread Starter

Bod

Joined Sep 18, 2016
249
I am following a guide to allow you to input sound into the Arduino (https://www.instructables.com/id/Arduino-Audio-Input/). It is a pretty simple schematic however it uses two 9v batteries in series. It is all well and good when testing, but in my actual circuit, I don't want two batteries floating around - It uses the batteries to power the Arduino (through VIN) and also to power the chip (I have the TL082).


How can I get rid of the batteries and use the Arduino's 5V supply? I have a feeling it is quite simple however I can't get my head around it. I can power the Arduino with 12V if need be.

FO7166GH7HY7X7T.LARGE.jpg

Thanks,
Bod
 

djsfantasi

Joined Apr 11, 2010
5,958
First, it uses the two batteries as a dual supply for the op amps. Audio is AC, and the op amp needs both a positive and a negative power supply.

So you would have to add circuitry to create a virtual ground and likely need something to create sufficient voltage for the TL082.
 

Thread Starter

Bod

Joined Sep 18, 2016
249
I see.

Will these batteries have to be replaced? I will assume they do and that is why I want to remove them.

Is this something that can be used and just have one input supply?
Virtual-Ground-Inverting-Amplifier-using-Opamp.jpg
 

KeithWalker

Joined Jul 10, 2017
603
I am following a guide to allow you to input sound into the Arduino (https://www.instructables.com/id/Arduino-Audio-Input/). It is a pretty simple schematic however it uses two 9v batteries in series. It is all well and good when testing, but in my actual circuit, I don't want two batteries floating around - It uses the batteries to power the Arduino (through VIN) and also to power the chip (I have the TL082).


How can I get rid of the batteries and use the Arduino's 5V supply? I have a feeling it is quite simple however I can't get my head around it. I can power the Arduino with 12V if need be.

View attachment 180453

Thanks,
Bod
What are you planning on doing with the audio once it reaches the analog input? Are you going to digitize the audio waveform or just detect it's presence? What is the source of the input to the op-amp?
 

Thread Starter

Bod

Joined Sep 18, 2016
249
What are you planning on doing with the audio once it reaches the analog input? Are you going to digitize the audio waveform or just detect it's presence? What is the source of the input to the op-amp?
I am going to process the incoming audio, an like most, adjust LEDs in turn.

The audio is coming from a mono 3.5mm audio cable.
 

KeithWalker

Joined Jul 10, 2017
603
If you want to digitize the waveform, this circuit should do what you want. Use the 5 volt supply from the Arduino. The output, with no input signal will be approximately 2.5 volts which can be connected directly to the analog input. Adjust R2 to give a good amplification without clipping.
I am going to process the incoming audio, an like most, adjust LEDs in turn.

The audio is coming from a mono 3.5mm audio cable.
This circuit should do what you want. Use the +5V supply from the Arduino. The output will be at approximately 2.5 volts DC. Adjust R2 for maximum gain without clipping.
TL082amp.jpg
 

Thread Starter

Bod

Joined Sep 18, 2016
249
If you want to digitize the waveform, this circuit should do what you want. Use the 5 volt supply from the Arduino. The output, with no input signal will be approximately 2.5 volts which can be connected directly to the analog input. Adjust R2 to give a good amplification without clipping.

This circuit should do what you want. Use the +5V supply from the Arduino. The output will be at approximately 2.5 volts DC. Adjust R2 for maximum gain without clipping.
View attachment 180456
Awesome, I will give that a try!

Bod
 

Thread Starter

Bod

Joined Sep 18, 2016
249
@KeithWalker
I am in the process of putting it together. I believe the numbers around the chip are wrong (on the schematic you provided). It says VCC is pin 7 but on the actual TL082 datasheet, pin 8 is VCC. This is the same with the other pin markings.
It doesn't make that much difference because I am just changing where I put the inputs to the correct pins, just thought I'd mention it.

EDIT: also, last question, where does the audio go in. I assume that the audio ground goes to the unmarked wire that connects to the - of the opamp. And the audio signal - does that go to the wire below with a label of +5v?
 
Last edited:

AnalogKid

Joined Aug 1, 2013
8,259
In post #6, the corner frequency for the non-inverting bias network is 68 Hz. That's a bit high unless you don't care about the bass frequencies. At a minimum, increase the 0.1 uF bypass capacitor to 1.0 uF.

Also, please use reference designators in all schematics. There are two 0.1 uF capacitors on the schematic, and now the TS has to guess which one I mean.

Also, the inverting input coupling capacitor creates a high-pass filter with a corner frequency of 1.6 kHz. That is even worse for bass and midrange frequencies. Better to increase both capacitors to 10 uF.

ak
 

Thread Starter

Bod

Joined Sep 18, 2016
249
Thanks for all the replies,

I have just tried it out and it doesn't really work. Before I go for the TLV2462 because they are quite pricy, especially in a DIP package, is there any other circuit with the TL082 I can use that will do the job?

Bod
 

BobaMosfet

Joined Jul 1, 2009
941
I am following a guide to allow you to input sound into the Arduino (https://www.instructables.com/id/Arduino-Audio-Input/). It is a pretty simple schematic however it uses two 9v batteries in series. It is all well and good when testing, but in my actual circuit, I don't want two batteries floating around - It uses the batteries to power the Arduino (through VIN) and also to power the chip (I have the TL082).


How can I get rid of the batteries and use the Arduino's 5V supply? I have a feeling it is quite simple however I can't get my head around it. I can power the Arduino with 12V if need be.

View attachment 180453

Thanks,
Bod

There isn't much to understand. The two 9V batteries are in series, and are supplying 18V. +9 and -9, for true A/C operation of the amplifier. You cannot just use the 5V of the arduino.
 
Last edited:

Thread Starter

Bod

Joined Sep 18, 2016
249
They are providing a +- 9V supply, so in series.

And how should I do this though - it seems like components are connected in the middle of both of them, which is confusing me as to how I should use a wallwart supply.

Bod
 

MrChips

Joined Oct 2, 2009
19,930
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.

I can provide more details when I get the chance to examine this more closely.
 

BobaMosfet

Joined Jul 1, 2009
941
They are providing a +- 9V supply, so in series.

And how should I do this though - it seems like components are connected in the middle of both of them, which is confusing me as to how I should use a wallwart supply.

Bod
Why is it confusing (see my earlier post). You have +9 and then -9. A range of 18V.
 

djsfantasi

Joined Apr 11, 2010
5,958
Depending on why your processing sound in the Arduino, there are envelope follower circuits available. You can get involved in precision rectifier circuits, bipolar supply op amps an filters.

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.
 

djsfantasi

Joined Apr 11, 2010
5,958
Before I go for the TLV2462 because they are quite pricy, especially in a DIP package, is there any other circuit with the TL082 I can use that will do the job?
What do you consider pricey?

It’s less than a cup of Dunky’s...

(New England coffee that’s wicked pissah)
 
Top