how to change -ve to +ve

Discussion in 'The Projects Forum' started by stirling, Mar 11, 2010.

  1. stirling

    Thread Starter Member

    Mar 11, 2010
    52
    2
    Hi - new to the forum.

    Basic problem: A plasma cutter arc voltage is generally in the range 0 to -300Vdc. I need to monitor this with an adc with an input range of 0 to +5Vdc. Stop me where I go wrong - gently :) I'm good with digital and and a lot to learn with analogue.

    First stage is a potential divider. That gets me 0 to -5Vdc.

    Second stage: I've been pointed towards a unity inverting op amp setup to flip this round to 0 to +5Vdc. Read up on op amps till I'm dizzy but enough to ask: Don't really want to get into split supply so if I use a single supply, will the opamp supply have to be 0 and -5Vdc or 0 to +5Vdc to cater for the negative input? If 0 to -5V, what's an easy way to get this from +5V which I have already on the board?

    That should do for starters.

    Thanks
     
  2. Bernard

    AAC Fanatic!

    Aug 7, 2008
    4,172
    397
    Single ended supply should work, at 0 & +5 outputs may be a little skakey. For a - supply just short of -5V, try a 555 oscillalor. I have used it but values are just guesses now. Frequency around 10 to 20kHz should do. Diodes 1N4002, fast recovery better.
     
  3. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Bernard,
    Our OP wants to monitor the -300v by converting -300 to 0v into a positive range of 0 to +5v; +5v representing -300v.

    Have a look at the attached.

    R1/R2 form a voltage divider to convert the -300v to 0v into a range of 0v to 5v.
    C1 (an option) helps to keep the input quiet (free from resistor hiss and transient spikes).
    D1 and D2 clamp the input to the power rails in case of transients, or the failure of R2.
    Opamp U1 provides a high impedance buffer for the input signal.
    Opamp U2 is an inverting unity-gain buffer, which changes the 0-5v range to 5v-0v range.
    R3 and R4 should be closely matched for unity gain.
    R5 and R6 should also be closely matched; actual value can vary significantly, but aim for a total resistance to give 0.1mA to 1mA current from Vcc to GND.
    C2 keeps the reference voltage quiet. 10nF suggested, but could be anywhere from 330pF to .33uF


    The operational amplifiers used have rail-to-rail input and outputs, and were designed for single-supply operation. You cannot use typically available opamps, like TL082, TL072, 741, 1458, etc.

    Other opamps that may work for you are OP196/OP296, TLC2272, LT1884, LT1495, LMC7111, LM6132.
     
    Last edited: Mar 12, 2010
  4. retched

    AAC Fanatic!

    Dec 5, 2009
    5,201
    312
    Beautiful, It doesn't get much closer than that. If you can get a hold of some %1ers for the resistors, you can increase accuracy through the gamut. You basically have a 60 to 1 - to + convert. So with a 5% resistor, A 2v output could represent between -110 and -130v input.
     
  5. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    I would use metal film resistors. They are less noisy than carbon or carbon film resistors, tend to be more stable, and are available in very tight tolerances if you don't mind spending a bit more for that.

    I didn't show bypass capacitors across the opamp supply inputs, as they should be a given. Please see the datasheet for the opamp you decide to use for their bypass capacitor recommendations. However, 0.1uF (100nF) poly film is generally sufficient.

    D1 and D2 will introduce a slight non-linearity due to leakage currents. If this is of concern, look for fast or Schottky diodes with lower leakage currents than 1N4148/1N914 diodes.
     
  6. stirling

    Thread Starter Member

    Mar 11, 2010
    52
    2
    SgtWookie - Thankyou very much for this. I'm way down the curve on analogue so I'll take it away and study it and try to get up to speed. Hope it's ok to come back with questions - I'm sure I'll have some.

    retched - thanks also for your input. As I understand it, some commercial systems can resolve to around 0.25V so it'll be interesting how close to that I can get.

    Thanks again
     
  7. retched

    AAC Fanatic!

    Dec 5, 2009
    5,201
    312
    You'll do fine. You've got drive to learn and a real professionals help.(Sgt.Wookie)

    And you have access to the same parts as the commercial manufactures.

    With all three, you can't lose.
     
  8. stirling

    Thread Starter Member

    Mar 11, 2010
    52
    2
    OK - I've had a good look at this and (think) I understand it - we'll see!

    1) The 5V source biases the pd to 0 to +5V whereas without it we'd get -5 to 0V.

    2) Diodes: If the pd output tried to go below 0 then D1 would conduct and effectively short to earth thus holding the pd output to 0V. Similarly if the pd out tried to go above 5V then D2 would effectively short to Vcc thus holding the pd output to 5V - yes/no?

    3) U1: If the input to the inverting input of a non-inverting configured opamp is the same as the output then the gain is unity. Not sure though why we need this - havn't quite got my head round impedance yet. The current through the pd is 0.25mA - presumably we need more - why couldn't we just reduce the resistance values to give us higher current availibilty.

    4) U2 is a *regular* unity gain inverting opamp. BUT - a *regular* opamp would need a split supply of 5V 0 -5V. Using an LT1490 and by biasing the non-inverting input to 2.5V we can *somwhow* still get an output range of 5V. Not sure why.

    One thought I had was: Do we actually need the inverting amp? If I changed the requirements (how annoying is that?) from -300 to 0 being represented by 5 to 0 to the other way round i.e. -300 to 0 as 0 to 5. It would make no difference to the ADC - I just switch the math. (yes/no?)

    Another thought: Usually with commercial THC units, the pd in the plasma is connected accross the torch anode to ground. If we were to do that we wouldn't need the 5V *bias* source which is not readilly available inside the plasma unit. Of course we'd then have a -5 to 0V output. Anyway - yadda yadda - here's my attempt (attached) - I won't be too suprised if it falls like a stack of cards.
     
  9. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Right. Note that the +5v supply regulation will be critical to get a properly scaled output from the R1/R2 divider.
    Correct. They are "clamping diodes". Without them, if R2 failed, the input of U1 could be pulled down to -300v, which would destroy the opamp.
    It would be better to use Schottky diodes, like a BAT54 or the like. Schottky diodes have a much lower forward voltage than standard silicon diodes.
    Reducing the resistance values will increase power dissipation in R1 by a significant amount. The 1.2 MEG resistor I used will dissipate about 75mW of power; for reliability you should use a 1/4W metal film resistor.

    The use of the buffer amp U1 isolates the rest of the circuit from the voltage divider. The input impedance of U1 is so high that it has virtually no impact (load) on the divider. Without this isolation, the circuit will not work properly.
    I don't know what you mean by "regular".
    Both U1 and U2 are rail-to-rail input and output opamps that can operate from a single supply. They have high impedance inputs and low offset voltages. You could not use a typical opamp like a 741, LF353, TL072, etc because they do not have rail to rail inputs and outputs (frequently abbreviated as RRIO).

    That is true. You could even eliminate both opamps; just have R1, R2, and C1 - with D1 and D2 as clamps, of course. The ADC requires a low-impedance input; that is why C1 will still be required.

    You're going to need a 5v supply for the uC anyway, right?

    If you want to experiment with your circuit, and with the one I did, download Linear Technology's LTSpice simulator. Google is your friend. I've attached the simulation I did.

    Be certain to calculate the maximum power dissipation in the components, and use components rated for at least twice the power dissipation.
     
  10. stirling

    Thread Starter Member

    Mar 11, 2010
    52
    2
    Been a bit otherwise involved but I'm now back to it...

    Sorry - wrong word maybe - I just meant one that needs a split supply and isn't rail to rail.

    Sounds tempting... :)

    True. I'll also need a 5V supply for other parts of the interface that I havn't mentioned yet - like detecting I actually have an arc - done I believe with a hall effect sensor mounted on a ferrite ring round the plasma earth clamp lead.

    Downloaded as you suggested. Excellent - thanks.

    So. Coming back to the 5V supply for this gubbins - any reason why I can't send this down from the CNC controller - a distance of about 10 feet - rather than try to find 5V in the plasma unit?

    Thanks
     
  11. gerrymoore

    New Member

    Mar 3, 2012
    4
    0
    I know this is an old thread but wondered if Sterling ever managed to get his THC working? I have built my own plasma CNC and would love to sort out a torch height control but bit scared messing with -300volts!! Any news, ideas would be very welcome...regards to all Gerry
     
  12. Goldsmith110

    New Member

    Apr 9, 2012
    5
    0
    Hi
    As i've understood you want convert -300 volts to the + 300 volts . right ?
    It depends on how much current do you need !
    But for a short answer i can tell , you can use an SMPS with a transformer ! ( HF transformer ) e.g push pull or H bridge
    Best Wishes
    Goldsmith110
     
  13. gerrymoore

    New Member

    Mar 3, 2012
    4
    0
    Hiya...thanks for your reply. I think you need to read all the posts...the basic idea is to convert the very noisy -300 volt output from the plasma cutter to a stable 0 to 5 volt dc signal that can then be used via a comparator circuit or microcontroller to manage the plasma torch controller at an optimum height for cutting.........easy if you say it quickly!! Grateful for any more help on this......regards Gerry
     
  14. Goldsmith110

    New Member

    Apr 9, 2012
    5
    0
    Hi again
    so you need to convert a very noisy -300 volts to the pure supply with 0-5 volts out put voltage . ok ? so it is pretty simple ! you can give it to a simple flyback converter or a forward converter . or if isolation isn't important for you you can use a simple buckboost converter to do it and then use a differential LC filter in out put to be sure about purity of this voltage .
    Best Wishes
    Goldsmith110
     
  15. gerrymoore

    New Member

    Mar 3, 2012
    4
    0
    Hi...thanks again for your reply. I'm not sure if I really understand the methods you are describing...I will try and google the various devices you mention and see if I can get any information.

    Would it be possible for you to draw some simple schematics? May help me understand!!

    When you mention a flyback circuit it reminds me of my early days in TV repairs...when they had valves (tubes) !!!

    regards Gerry
     
Loading...