Author Topic: EEVblog #483 - Microcontroller Voltage Inverter Tutorial  (Read 24914 times)

0 Members and 1 Guest are viewing this topic.

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #25 on: June 19, 2013, 04:53:07 pm »
Well, is it sinking or sourcing current? It will source from the positive rail and sink to the negative. Its quiescent operating current flows from the positive rail to the negative, so both equally. If it overdraws on the weak negative rail, the rail will collapse as demonstrated.
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline joycer182

  • Newbie
  • Posts: 6
  • Country: ve
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #26 on: August 05, 2013, 06:08:50 pm »
Hi folks!!! I'm new around here. Kudos for blog and forum are amazing :clap: .

I have a question, how can I use this circuit (used by dave in the video) to feed the negative rail of an opamp?

I tried to use it directly, but it doesn't works. The voltage drop down to 0V (few milivolts).

I'm using an opa2209 from texas instruments, I mesure the consumption for the negative rail, is 4mA tops, I use it as a non inverting amplifier.

How can I do or what do I have to do to get from the dave's circuit at least 5mA without voltage drop?

Thank you very much.

Best Regards.
Nothing is impossible if you can Imagine
 

Offline nitro2k01

  • Frequent Contributor
  • **
  • Posts: 843
  • Country: 00
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #27 on: August 05, 2013, 09:25:21 pm »
4 mA should not be a problem. (Subject to the capacitor size.) More information please. Does the circuit appear to work with no opamp connected? Have you double checked the schematic? Which capacitor size do you use? What is the system Vcc? What are you using to drive the circuit? Maybe your microcontroller's IO ports can't drive enough current.
Whoa! How the hell did Dave know that Bob is my uncle? Amazing!
 

Offline EEVblogTopic starter

  • Administrator
  • *****
  • Posts: 37661
  • Country: au
    • EEVblog
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #28 on: August 05, 2013, 09:51:11 pm »
It's a combination of capacitor size and frequency. It should not drop to zero, something sounds wrong.
 

Offline joycer182

  • Newbie
  • Posts: 6
  • Country: ve
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #29 on: August 06, 2013, 06:09:12 pm »
Hi, Thanks for quick response.

Attached you can find what I'm trying to do, it's a simple amplification of a signal from a LDR sensor. The signal is received by a 12bit ADC converter and sent to microcontroller to report to PC through USB.

The trouble is when the circuit is on (+5V usb power) the opamp doesn't work, I measure the -Vcc (out from the voltage inverter) and I get 0V, and without opamp I get aprox. -4,3V. I guess the opamp is not getting the mA that it needs.

In the past I measured the current consumption from the negative rail and I get aprox. 4mA. Thats why, as I said before, I need at least 5mA.

What I need to do to do what I need?

How I can estimate the capacitor I need?

Thanks again, Dave this community is amazing.

Best Regards.
« Last Edit: August 06, 2013, 06:17:29 pm by joycer182 »
Nothing is impossible if you can Imagine
 

Offline Rufus

  • Super Contributor
  • ***
  • Posts: 2095
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #30 on: August 06, 2013, 08:55:38 pm »
In the past I measured the current consumption from the negative rail and I get aprox. 4mA. Thats why, as I said before, I need at least 5mA.

With 1uF to ground on its output the opamp is probably oscillating.

The charge on the pump capacitor Q is CV where V is the 5v less two diode drops. That is about 370nC and pumping it 5000 times a second is a current of 1.85mA. That is into a short circuit, the pumped current will drop to nothing as the output voltage approaches -3.7v.

For -2v output the voltage change across the capacitor is 5 - 2 diodes - 2v = about 1.7v and 170nC, at 5kHz that would be 0.85mA. 

You need a bigger capacitor and/or higher frequency, but, choosing a better opamp is preferable and if you chose a rail-rail opamp you would not need a -ve supply at all.

 

Offline joycer182

  • Newbie
  • Posts: 6
  • Country: ve
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #31 on: August 06, 2013, 09:58:31 pm »
Hi Rufus, the parameters that I choose was aleatory and with thats values I have those results.

There is no problem for me to change the frecuency, the cap values, etc. I only need a guidance in order to get it works.

Quote
That is about 370nC and pumping it 5000 times a second is a current of 1.85mA

How you calcutale the current with the frecuency?


when you say this:

Quote
With 1uF to ground on its output the opamp is probably oscillating.

You referred to the input of ADC converter (out from the op amp) that has a 1uF cap?
You recommended to remove?

Thank you.
Nothing is impossible if you can Imagine
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #32 on: August 06, 2013, 10:14:29 pm »
Quote
That is about 370nC and pumping it 5000 times a second is a current of 1.85mA

How you calcutale the current with the frecuency?

One amp is one coulomb per second. 370nC * 5000Hz = 1.85 mC/s = 1.85 mA.
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline joycer182

  • Newbie
  • Posts: 6
  • Country: ve
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #33 on: August 06, 2013, 10:24:30 pm »
jajajjaa How could I forget something like that  :-DD   :-+

Thanks c4757p
Nothing is impossible if you can Imagine
 

Offline joycer182

  • Newbie
  • Posts: 6
  • Country: ve
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #34 on: August 07, 2013, 01:54:00 pm »
Hi,

c4757p:
Quote
That is about 370nC and pumping it 5000 times a second is a current of 1.85mA

My confusion was that those 370nC I don't know where he got them (rufus).

Rufus:
Quote
You need a bigger capacitor and/or higher frequency, but, choosing a better opamp is preferable and if you chose a rail-rail opamp you would not need a -ve supply at all.

The opamp that I chose is good for my application, in my country is to hard to buy good stuff, this opamp I bought in mouser electronics, and buy this way is difficult for me. In my country we have exchange control and we don't have much dollars per person (incredible, right?).

I would like to use this opamp (opa2209), when I chose it I don't noticed one detail, this opamp needs at least -3.5V in the negative rail to work properly. So I can't uses with a single supply, in my research I found the Dave's article and I thought this is the solution.

So, change the opamp is not (for now, recently we have problems with imports) an easy solution (I only found in my country ua741, LM358, nothing good enough).

Easy to design here, right?  :'(

I hope you can help me.

Best Regards.
« Last Edit: August 07, 2013, 02:07:56 pm by joycer182 »
Nothing is impossible if you can Imagine
 

Offline joycer182

  • Newbie
  • Posts: 6
  • Country: ve
Re: EEVblog #483 - Microcontroller Voltage Inverter Tutorial
« Reply #35 on: August 10, 2013, 10:04:14 pm »
Hi, finally I did it, the circuit is working fine for my application  O0 :-+ . I changed the values of capacitors and PWM frequency and I get great results.

Without the opamp connected to (-Ve) I got -4,16 Volts, and connected I got -2,60 Volts, enough to operate the opa2209.

According datasheet the Common-Mode Voltage Range in opa2209 = (-Ve) + 1,5 Volts, for me would be = -2,60 Volts + 1,5 Volts = -1,1 Volts. Which means I can operate the opamp well.

In the attached file you can find my final config. It works great for me, my amplifier arrangement finally works using a single supply and the dave's voltage inverter circuit. Experimentally I got these results:

Entry signal to amplifier = 0,019 Volts  :-DMM
Out Signal from the amplifier = 0,206 Volts  :-DMM

Theoretically amplifier gain is 11, and I got (0,206 / 0,019) = 10,84 Experimentally  ;D.

Thank you everyone for help me out.

Thanks dave, rufus, c4757p.  :clap:
« Last Edit: August 10, 2013, 10:14:35 pm by joycer182 »
Nothing is impossible if you can Imagine
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf