Need help with optoisolator theory, CTR, If ,???

  • Thread starter jalbers@bsu.edu
  • Start date
J

jalbers@bsu.edu

Guest
I am trying to optically isolate the high voltage (0-170VDC)
relaxation oscillator part of an EDM circuit from the servo motor
control part (12VDC). The voltage between the tool and work piece is
zero when the tool is touching the work piece (no sparks). When the
tool is too high above the work piece, the voltage is 170 VDC (no
sparks). When the tool is in the right place for sparks, the voltage
is somewhere between these two extremes. I am wanting the
optoisolator to map the 0-170VDC to roughly a 0-12VDC range.

I am trying to use a 4N27 optoisolator. I picked this one because I
already have a bunch of them on hand. I don’t know much about
optoisolators but it appears to me after reading the datasheet that
the best CTR is going to occur when IF is around 10ma. The data
sheet indicates that the CTR for the 4N27 ranges from 10% (min) to 30%
(typical).

I put together a test circuit to try to map the 0-170 VDC to the 0-12
VDC. I am using 5 -30VDC wall warts wired in series to give me 0, 37,
75, 112, 150, and 187 VDC. I have a 10K resistor (R1) wired in series
with the diode on the input side. On the output side, I have +12VDC
connected to the collector, and a 4.7K resistor (R2) connected between
the emitter and ground. I am measuring the voltage (Vout) across this
resistor 4.7K resistor, hoping that it will vary between 0-12VDC in a
predictable way.

Here are the experimental results:
At 37V (input), IF was 4ma, and Vout was 5.26, I out was 1.2 ma,
making the CTR 30%
At 75V (input), IF was 2.25 ma, and Vout was 11V, I out was 2.25 ma,
making the CTR 100%
At 112V (input), IF was 3.3 ma, and Vout was 11V, I out was 2.32ma,
making the CTR 70%
At 150V, 187V, Vout was at 11V.

Not really what I was expecting. I am looking for a lot more
variation in Vout, especially in the Vin between 75VDC and 170VDC
window. What values for R1 and R2 should I use to make this circuit
behave more like I want it to? Also why is the circuit behaving the
way it is and not the way I want it to?

Any help would be greatly appreciated. Thanks
 
jalbers@bsu.edu wrote:
I am trying to optically isolate the high voltage (0-170VDC)
relaxation oscillator part of an EDM circuit from the servo motor
control part (12VDC). The voltage between the tool and work piece is
zero when the tool is touching the work piece (no sparks). When the
tool is too high above the work piece, the voltage is 170 VDC (no
sparks). When the tool is in the right place for sparks, the voltage
is somewhere between these two extremes. I am wanting the
optoisolator to map the 0-170VDC to roughly a 0-12VDC range.

I am trying to use a 4N27 optoisolator. I picked this one because I
already have a bunch of them on hand. I don’t know much about
optoisolators but it appears to me after reading the datasheet that
the best CTR is going to occur when IF is around 10ma. The data
sheet indicates that the CTR for the 4N27 ranges from 10% (min) to 30%
(typical).

I put together a test circuit to try to map the 0-170 VDC to the 0-12
VDC. I am using 5 -30VDC wall warts wired in series to give me 0, 37,
75, 112, 150, and 187 VDC. I have a 10K resistor (R1) wired in series
with the diode on the input side. On the output side, I have +12VDC
connected to the collector, and a 4.7K resistor (R2) connected between
the emitter and ground. I am measuring the voltage (Vout) across this
resistor 4.7K resistor, hoping that it will vary between 0-12VDC in a
predictable way.

Here are the experimental results:
At 37V (input), IF was 4ma, and Vout was 5.26, I out was 1.2 ma,
making the CTR 30%
At 75V (input), IF was 2.25 ma, and Vout was 11V, I out was 2.25 ma,
making the CTR 100%
At 112V (input), IF was 3.3 ma, and Vout was 11V, I out was 2.32ma,
making the CTR 70%
At 150V, 187V, Vout was at 11V.

Not really what I was expecting. I am looking for a lot more
variation in Vout, especially in the Vin between 75VDC and 170VDC
window. What values for R1 and R2 should I use to make this circuit
behave more like I want it to? Also why is the circuit behaving the
way it is and not the way I want it to?

Any help would be greatly appreciated. Thanks
First, you are saturating your output transistor. The opto-isolator
doesn't have a voltage source to supply more volts on the output side
than you're giving it (12V).

Try a lower resistance on the output side, or a higher one on the input
side.

Second, your listed input currents don't seem to be right. 4mA at 37V I
can believe, but at 75V I would expect 7.5mA, at 112V I would expect
11.2, etc.

Third, there's no functional reason to isolate these, although I won't
argue with you if you're trying to do it for safety reasons (other than
you shouldn't put your trust in it if it's the only safety you have
built in). As long as you're minding your P's and Q's with ground
loops, you should be able to run 12V and 170V rails with a common ground.

--

Tim Wescott
Wescott Design Services
http://www.wescottdesign.com

Do you need to implement control loops in software?
"Applied Control Theory for Embedded Systems" gives you just what it says.
See details at http://www.wescottdesign.com/actfes/actfes.html
 
jalbers@bsu.edu wrote:
I am trying to optically isolate the high voltage (0-170VDC)
relaxation oscillator part of an EDM circuit from the servo motor
control part (12VDC). The voltage between the tool and work piece is
zero when the tool is touching the work piece (no sparks). When the
tool is too high above the work piece, the voltage is 170 VDC (no
sparks). When the tool is in the right place for sparks, the voltage
is somewhere between these two extremes.
Are you sure about that? I was under the impression that
the EDM process operated on a sequence of pulses that dump a
capacitor charged up to the higher voltage down to almost
zero, in a very rapid repeating process. there is almost no
time that the voltage is a steady voltage between the
extremes, but is always charging up to the higher voltage or
shorted out to almost zero. The voltage stays somewhere in
the middle only in an average sense.

I am wanting the
optoisolator to map the 0-170VDC to roughly a 0-12VDC range.

I am trying to use a 4N27 optoisolator. I picked this one because I
already have a bunch of them on hand. I don’t know much about
optoisolators but it appears to me after reading the datasheet that
the best CTR is going to occur when IF is around 10ma. The data
sheet indicates that the CTR for the 4N27 ranges from 10% (min) to 30%
(typical).
Yes, the CTR varies a lot from one unit to another, and over
temperature, so you may need to include an adjustment.
Fortunately, if you are sending the output signal to a high
impedance load, you don't really need much of a CTR, just a
high value pull up resistor.

I put together a test circuit to try to map the 0-170 VDC to the 0-12
VDC. I am using 5 -30VDC wall warts wired in series to give me 0, 37,
75, 112, 150, and 187 VDC. I have a 10K resistor (R1) wired in series
with the diode on the input side.
Okay, so that gives you a peak input current of about
187/10k=18.7mA. That may load the EDM capacitor charging
source a bit. I would probably use about twice that
resistance, if just to lower the resistor heat to below 2 watts.

On the output side, I have +12VDC
connected to the collector, and a 4.7K resistor (R2) connected between
the emitter and ground. I am measuring the voltage (Vout) across this
resistor 4.7K resistor, hoping that it will vary between 0-12VDC in a
predictable way.

Here are the experimental results:
At 37V (input), IF was 4ma, and Vout was 5.26, I out was 1.2 ma,
making the CTR 30%
At 75V (input), IF was 2.25 ma, and Vout was 11V, I out was 2.25 ma,
making the CTR 100%
At 112V (input), IF was 3.3 ma, and Vout was 11V, I out was 2.32ma,
making the CTR 70%
At 150V, 187V, Vout was at 11V.
Well, the transistor will not drop zero volts in any circuit
that has an approximately linear response. That takes a lot
of over drive. I think you should have a couple extra
supply volts compared to the voltage swing you expect. Or,
connect the transistor to an inverting opamp, so that the
voltage across the transistor is held constant (at some few
volts) and only the current varies. The opamp provides the
voltage swing by supplying the transistor current through
the feedback resistor.

Not really what I was expecting. I am looking for a lot more
variation in Vout, especially in the Vin between 75VDC and 170VDC
window. What values for R1 and R2 should I use to make this circuit
behave more like I want it to? Also why is the circuit behaving the
way it is and not the way I want it to?
Your input resistor is too low, compared to the output
resistor. Either raise the input resistance or lower the
output resistance, or both. Make the output resistor a
fixed resistor in series with an adjustable resistor, so you
can set the mid point output or some other convenient
reference point.

Expect the signal to bounce around a lot during operation,
since, as I said, I think the voltage spends most of the
time going up smoothly and discharging rapidly. The energy
dump into the spark is what blasts metal off the surface
being cut.

--
Regards,

John Popelish
 
John Popelish wrote:
jalbers@bsu.edu wrote:
I am trying to optically isolate the high voltage (0-170VDC)
relaxation oscillator part of an EDM circuit from the servo motor
control part (12VDC). The voltage between the tool and work piece is
zero when the tool is touching the work piece (no sparks). When the
tool is too high above the work piece, the voltage is 170 VDC (no
sparks). When the tool is in the right place for sparks, the voltage
is somewhere between these two extremes.

Are you sure about that? I was under the impression that the EDM
process operated on a sequence of pulses that dump a capacitor charged
up to the higher voltage down to almost zero, in a very rapid repeating
process. there is almost no time that the voltage is a steady voltage
between the extremes, but is always charging up to the higher voltage or
shorted out to almost zero. The voltage stays somewhere in the middle
only in an average sense.

I am wanting the
optoisolator to map the 0-170VDC to roughly a 0-12VDC range.

I am trying to use a 4N27 optoisolator. I picked this one because I
already have a bunch of them on hand. I don’t know much about
optoisolators but it appears to me after reading the datasheet that
the best CTR is going to occur when IF is around 10ma. The data
sheet indicates that the CTR for the 4N27 ranges from 10% (min) to 30%
(typical).

Yes, the CTR varies a lot from one unit to another, and over
temperature, so you may need to include an adjustment. Fortunately, if
you are sending the output signal to a high impedance load, you don't
really need much of a CTR, just a high value pull up resistor.

I put together a test circuit to try to map the 0-170 VDC to the 0-12
VDC. I am using 5 -30VDC wall warts wired in series to give me 0, 37,
75, 112, 150, and 187 VDC. I have a 10K resistor (R1) wired in series
with the diode on the input side.

Okay, so that gives you a peak input current of about 187/10k=18.7mA.
That may load the EDM capacitor charging source a bit. I would probably
use about twice that resistance, if just to lower the resistor heat to
below 2 watts.

On the output side, I have +12VDC
connected to the collector, and a 4.7K resistor (R2) connected between
the emitter and ground. I am measuring the voltage (Vout) across this
resistor 4.7K resistor, hoping that it will vary between 0-12VDC in a
predictable way.

Here are the experimental results:
At 37V (input), IF was 4ma, and Vout was 5.26, I out was 1.2 ma,
making the CTR 30%
At 75V (input), IF was 2.25 ma, and Vout was 11V, I out was 2.25 ma,
making the CTR 100%
At 112V (input), IF was 3.3 ma, and Vout was 11V, I out was 2.32ma,
making the CTR 70%
At 150V, 187V, Vout was at 11V.

Well, the transistor will not drop zero volts in any circuit that has an
approximately linear response. That takes a lot of over drive. I think
you should have a couple extra supply volts compared to the voltage
swing you expect. Or, connect the transistor to an inverting opamp, so
that the voltage across the transistor is held constant (at some few
volts) and only the current varies. The opamp provides the voltage
swing by supplying the transistor current through the feedback resistor.

Not really what I was expecting. I am looking for a lot more
variation in Vout, especially in the Vin between 75VDC and 170VDC
window. What values for R1 and R2 should I use to make this circuit
behave more like I want it to? Also why is the circuit behaving the
way it is and not the way I want it to?

Your input resistor is too low, compared to the output resistor. Either
raise the input resistance or lower the output resistance, or both.
Make the output resistor a fixed resistor in series with an adjustable
resistor, so you can set the mid point output or some other convenient
reference point.

Expect the signal to bounce around a lot during operation, since, as I
said, I think the voltage spends most of the time going up smoothly and
discharging rapidly. The energy dump into the spark is what blasts
metal off the surface being cut.

Come to think if it, you probably want to servo to that peak voltage.

--

Tim Wescott
Wescott Design Services
http://www.wescottdesign.com

Do you need to implement control loops in software?
"Applied Control Theory for Embedded Systems" gives you just what it says.
See details at http://www.wescottdesign.com/actfes/actfes.html
 
Tim Wescott wrote:
John Popelish wrote:
(snip)
Expect the signal to bounce around a lot during operation, since, as I
said, I think the voltage spends most of the time going up smoothly
and discharging rapidly. The energy dump into the spark is what
blasts metal off the surface being cut.

Come to think if it, you probably want to servo to that peak voltage.
Or you low pass filter the signal to average a couple pulses
and servo that average with a longer response time than the
average. Generally, the spacing between the electrode and
the work is varied very slowly compared to the arc cycle.

--
Regards,

John Popelish
 
jalbers@bsu.edu wrote:
I am trying to optically isolate the high voltage (0-170VDC)
relaxation oscillator part of an EDM circuit from the servo motor
control part (12VDC). The voltage between the tool and work piece is
zero when the tool is touching the work piece (no sparks). When the
tool is too high above the work piece, the voltage is 170 VDC (no
sparks). When the tool is in the right place for sparks, the voltage
is somewhere between these two extremes. I am wanting the
optoisolator to map the 0-170VDC to roughly a 0-12VDC range.

I am trying to use a 4N27 optoisolator. I picked this one because I
already have a bunch of them on hand. I don’t know much about
optoisolators but it appears to me after reading the datasheet that
the best CTR is going to occur when IF is around 10ma. The data
sheet indicates that the CTR for the 4N27 ranges from 10% (min) to 30%
(typical).

I put together a test circuit to try to map the 0-170 VDC to the 0-12
VDC. I am using 5 -30VDC wall warts wired in series to give me 0, 37,
75, 112, 150, and 187 VDC. I have a 10K resistor (R1) wired in series
with the diode on the input side. On the output side, I have +12VDC
connected to the collector, and a 4.7K resistor (R2) connected between
the emitter and ground. I am measuring the voltage (Vout) across this
resistor 4.7K resistor, hoping that it will vary between 0-12VDC in a
predictable way.

Here are the experimental results:
At 37V (input), IF was 4ma, and Vout was 5.26, I out was 1.2 ma,
making the CTR 30%
At 75V (input), IF was 2.25 ma, and Vout was 11V, I out was 2.25 ma,
making the CTR 100%
At 112V (input), IF was 3.3 ma, and Vout was 11V, I out was 2.32ma,
making the CTR 70%
At 150V, 187V, Vout was at 11V.

Not really what I was expecting. I am looking for a lot more
variation in Vout, especially in the Vin between 75VDC and 170VDC
window. What values for R1 and R2 should I use to make this circuit
behave more like I want it to? Also why is the circuit behaving the
way it is and not the way I want it to?

Any help would be greatly appreciated. Thanks
Go to this site: http://www.modelenginenews.org/, and search on "EDM".
There's an interesting set of articles in there. I don't know if any
will _help_, but you may find them interesting.

--

Tim Wescott
Wescott Design Services
http://www.wescottdesign.com

Do you need to implement control loops in software?
"Applied Control Theory for Embedded Systems" gives you just what it says.
See details at http://www.wescottdesign.com/actfes/actfes.html
 

Welcome to EDABoard.com

Sponsor

Back
Top