Measuring negative voltage (on variable DC power supply)
Robot Freak
Posts: 168
Hello all,
I'm building a variable DC power supply, with digital voltage and current measurement.
I'd like to use the Propeller for the measurements, so I can display it on a LCD display.
The propeller is powered by it's own supply, so that it doesn't produce noise on the DC outputs.
The power supply has a ground, 1.2 till 12V and -1.2 till -12V outputs.
Measuring the positive output is easy, using an appropriate voltage divider to scale the voltage down to a 3.3V max.
With interconnected grounds, an ADC can then measure the voltage on the positive DC output.
Main problem: measuring voltage on the negative DC output.
The negative DC output can't be connected to the ADC because that only works for 0 till 3.3V.
What do I need to read the negative voltage?
Thanks in advance,
Robot Freak
Post Edited (Robot Freak) : 5/8/2009 2:31:08 PM GMT
I'm building a variable DC power supply, with digital voltage and current measurement.
I'd like to use the Propeller for the measurements, so I can display it on a LCD display.
The propeller is powered by it's own supply, so that it doesn't produce noise on the DC outputs.
The power supply has a ground, 1.2 till 12V and -1.2 till -12V outputs.
Measuring the positive output is easy, using an appropriate voltage divider to scale the voltage down to a 3.3V max.
With interconnected grounds, an ADC can then measure the voltage on the positive DC output.
Main problem: measuring voltage on the negative DC output.
The negative DC output can't be connected to the ADC because that only works for 0 till 3.3V.
What do I need to read the negative voltage?
Thanks in advance,
Robot Freak
Post Edited (Robot Freak) : 5/8/2009 2:31:08 PM GMT
Comments
Also, I've used the MAX1270 because it can accept negative voltages. But, the MAX1270 has a fairly low input impedance, so I had to use an opamp buffer anyway... But, if you're measuring supply voltage, you don't have to worry abou the impedance too much. But, the price of the MAX1270 is pretty hefty!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My Prop Info&Apps: ·http://www.rayslogic.com/propeller/propeller.htm
An OpAmp seems the best solution, but it needs a positive and negative voltage supply to function.
The only negative supply is from the power supply itself, and that one is variable.
Kind regards,
Robot Freak
Remember that you need to put a potential divider across the supply before feeding it into an inverting op-amp because the opamp won't get closer than about a volt to either rail, so it can't output more than about 11V if you run it off a +/-12v supply. This shouldn't be much of a problem because you need to scale the output anyway.
Edit:
What is the arrangement for the DC supply? Are you using variable regulators running off unregulated supply?
See the attachment for my simulation schematic.
Kind regards,
Robot Freak
Edit: the transformer has been replaced by two function generators.
The transformer has two times stabilised 12V AC, RMS.
Post Edited (Robot Freak) : 5/8/2009 2:28:24 PM GMT
Here's how opamp summers work:
http://www.allaboutcircuits.com/vol_3/chpt_8/8.html
I think if you sum a constant 3.3 V signal with a signal that can very from 0 to -3.3V, you can get an output that varies from 0 to 3.3 V...
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My Prop Info&Apps: ·http://www.rayslogic.com/propeller/propeller.htm
Post Edited (Rayman) : 5/8/2009 2:45:37 PM GMT
If you feed the 0V rail in to the non-inverting input of the op-amp the measurement will be relative to this and not the unregulated supply rails so it doesn't matter that they aren't a specific voltage.
You could always add an LM7812/LM7912 regulator pair as well to give you regulated +/-12V for running the op-amp if you wanted.
I didn't think about using the unregulated power supply, but it seems to work.
Will it be stable enough without additional regulators?
The OpAmp will never output more then 3.3V so I think it will...
Kind regards,
Robot Freak
I'd guess the un-regulated supply will be fine, you don't normally find regulators in audio amplifiers, the op-amps run straight off the smoothed DC.
Post Edited (Robot Freak) : 5/8/2009 3:50:34 PM GMT
No op amps required, just a bit of math.
Kevin
Thanks for explaining, now I understand what Kwinn meant.
Kind regards,
Robot Freak
Edit: Of course you'll still have to do the maths to invert and apply a scaling factor to make the number between 0 and -12 so you may be just as well to use a fixed resistor without the instability of a trimmer.
Post Edited (hairymnstr) : 5/8/2009 4:04:06 PM GMT
here's an app that can help:
http://www.pulsedpower.net/Applets/Electronics/SigmaDeltaADC/SigmaDeltab.html
Just change R2 to 500k and R3 to 100k and you get a nice input range... (R4 isn't needed).
You don't have to use the Prop as your ADC for this to work.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My Prop Info&Apps: ·http://www.rayslogic.com/propeller/propeller.htm
Post Edited (Rayman) : 5/8/2009 6:17:43 PM GMT