Searching \ for '[EE]: Optical isolation for FET driver?' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/index.htm?key=optical+isolation
Search entire site for: 'Optical isolation for FET driver?'.

Exact match. Not showing close matches.
PICList Thread
'[EE]: Optical isolation for FET driver?'
2000\06\27@112754 by Nicholas Irias

flavicon
face
I am using a pair of Micrel 5022 half-h-bridge drivers to drive large FETs
for motor control (20 amp x 24 volt application), and am wondering what the
appropriate level of isolation is to prevent glitching on the PIC that will
be providing the input signals to the Micrel 5022s.

Micrel says that the ground for the 5022 driver should be connected to
signal ground rather than the power ground, and that Vcc should be connected
to the motor power supply, which is to be decoupled with a 10uF capacitor.
I assume that the decoupling capacitor is connected to the motor power
supply ground rather than to the signal ground.

My concern with Micrel's recommendation is that I will create some sort of
ground loop or otherwise get noise into the PIC through the signal leads.
Would it be adviseable to use optical isolation on the input signals, with a
separate 5v regulator to create power the optical isolator?

2000\06\27@115018 by Andrew Kunz

flavicon
face
It's a good idea to isolate the PIC from the power electronics as much as
possible.

You can use any any opto you want provided itmeets the switching requirements
you have.

In my Electronic Speed Control (6-30V, 100A), I approached it from the other
direction - I isolated the PIC from the "master" side (PIC was a slave to it,
driving FETs).  The PIC derived it's power from the batteries which ran the
motor, but through an LC circuit which blocked the switching noise.

The PIC and FETs shared a common ground, used a MIC4427 to drive the FETs.  V+
went into an inductor etched onto the PCB, into a big cap C1 (220uF).  Other
side of C1 went into a 5V LDO regulator, which had 1.0uF and 0.1uF on its
outputs.  These fed the PIC, which had one pin driving the 4427 (both inputs)
with a pull-down for fail-safe.  C1 also fed a 12V regulator which provide gate
drive voltage to the FETs (through the 4427), which had a 22ohm resistor on the
gate to control slew.

I had to design around several things:

75 MHz AM radio receiver which didn't need any more interference,
60 Hz refresh rate of digital data from radio,
Variable "frequency" pulse-position-modulated data (standard RC data),
4 MHz oscillator on the PIC,
3 kHz PWM frequency to the motor.

Works well!

Andy











Nicholas Irias <spam_OUTniriasTakeThisOuTspamPACBELL.NET> on 06/27/2000 11:25:06 AM

Please respond to pic microcontroller discussion list <.....PICLISTKILLspamspam@spam@MITVMA.MIT.EDU>








To:      PICLISTspamKILLspamMITVMA.MIT.EDU

cc:      (bcc: Andrew Kunz/TDI_NOTES)



Subject: [EE]: Optical isolation for FET driver?








I am using a pair of Micrel 5022 half-h-bridge drivers to drive large FETs
for motor control (20 amp x 24 volt application), and am wondering what the
appropriate level of isolation is to prevent glitching on the PIC that will
be providing the input signals to the Micrel 5022s.

Micrel says that the ground for the 5022 driver should be connected to
signal ground rather than the power ground, and that Vcc should be connected
to the motor power supply, which is to be decoupled with a 10uF capacitor.
I assume that the decoupling capacitor is connected to the motor power
supply ground rather than to the signal ground.

My concern with Micrel's recommendation is that I will create some sort of
ground loop or otherwise get noise into the PIC through the signal leads.
Would it be adviseable to use optical isolation on the input signals, with a
separate 5v regulator to create power the optical isolator?

2000\06\27@124859 by Andy Shaw

flavicon
face
Hi Andy,
Sounds like you may have fixed some of the problems I'm struggling with on a
R/C project of mine (non-commercial). Any chance of providing a little bit
more detail.....
a) What was the pattern of the inductor on the board?
b) I assume that C1 went from the end of the inductor to the common ground?
c) Then the LDO regulator - which one did you use, did it also provide power
to the R/C side of things including servos?
d) Did you have any filtering on the R/C inputs to the pic?
e) Any other tips for stopping spikes in the system from causing a reset of
the pic or basically screwing up the measurement of the R/C inputs?

Thanks

Andy - Really a software kind of guy :-)


{Original Message removed}

2000\06\27@131846 by Andrew Kunz

flavicon
face
>a) What was the pattern of the inductor on the board?

A straight line, but the adjacent circuits were the important part.  Other
signals crossed it (FET leads, etc) at a right angle.

>b) I assume that C1 went from the end of the inductor to the common ground?

Yes.

>c) Then the LDO regulator - which one did you use, did it also provide power
>to the R/C side of things including servos?

I used a National part, I forget which.  I used a 100mA part, but only use 20mA
max out of it.

It ONLY powers the PIC.  The PIC12C508 drives a LED to indicate mode (full
off=red, full-on = green), reads the pulse train, and generates the PWM to the
FETs.

If you power the radio & servos off the LDO, you _will_ have problems.  The
radio will be directly coupled to all that noise, the ground will be bouncing
all over the place, just not a good idea.  I use an opto on the input from the
radio to make sure that there are exactly NO electrical paths between the ESC
and the radio.

>d) Did you have any filtering on the R/C inputs to the pic?

Not electrical.

The input pulse is measured, and compared to the previous state.  1-bit changes
are ignored (no jitter), but a slowly-changing signal is picked up because we
don't compare this input to last input, we compare this input to last output.

To minimize glitching yet still preserve a failsafe function, the unit needs to
see at least 2 good pulses in a row within a second or so to keep operating.
There are other safety features as well.

>e) Any other tips for stopping spikes in the system from causing a reset of
>the pic or basically screwing up the measurement of the R/C inputs?

Isolate the power supply to the PIC (common ground is OK) as much as possible.
Use resistors on the I/O pins to prevent sudden changes causing problems.  Use a
resistor so that you get an "acceptable" slew rate (I have 1uS slew on all my
I/O pins) with the built-in capacitance of the pin.  You don't get to do things
like toggling the pin at high speed, but I don't need that feature anyway.

A picture of an EARLY unit is at http://www.rc-hydros.com/escproducts.html

What are you making?

Andy

2000\06\27@140804 by Andy Shaw

flavicon
face
Hi Andy,
Thanks for the info, a few more questions below...


> >a) What was the pattern of the inductor on the board?
>
> A straight line, but the adjacent circuits were the important part.  Other
> signals crossed it (FET leads, etc) at a right angle.
>

Right now I really am lost on this one Andy/Anyone care to explain how this
works and more to the point how on earth do you know when/how to use this
technique? Take pity on me, as I said I'm really a software guy :-)


>
> It ONLY powers the PIC.  The PIC12C508 drives a LED to indicate mode (full
> off=red, full-on = green), reads the pulse train, and generates the PWM to
the
> FETs.
>
> If you power the radio & servos off the LDO, you _will_ have problems.
The
> radio will be directly coupled to all that noise, the ground will be
bouncing
> all over the place, just not a good idea.  I use an opto on the input from
the
> radio to make sure that there are exactly NO electrical paths between the
ESC
> and the radio.
>

OK so in my project I only have a single 12V supply (no extra pack for the
radio gear). Any suggestions on the best way to set things up to provide
power to the "noisy" power part of the system, the pic based part and the
radio part from the same supply?

>
> The input pulse is measured, and compared to the previous state.  1-bit
changes
> are ignored (no jitter), but a slowly-changing signal is picked up because
we
> don't compare this input to last input, we compare this input to last
output.
>

Slightly confused here when you say "compare this input to last output" do
you mean - the last input after application of the jitter filter? Maybe you
could provide an example set of input and output values?

>
> What are you making?
>

Well it is a third generation of my submarine control unit (see
http://freespace.virgin.net/andy.shaw/microcon.htm for an older version).
I'm basically adding closed loop control of the dive system, it already has
depth and tilt inputs for depth and attitude control but I would really like
to fully automate the dive sequence. To do this I really need better control
than the open loop mode of operation for the compressor/valve system that
controls the ballast system. I'm probably going to be using an 876 to do the
job (so I can make a better job of driving the tilt sensor and make use of
the eeprom to store configuaration data). I may also build a varient with
twin PWM outputs (but no ballast control) for a model ROV I'm toying with
building but that as they say is another story!

BTW: If you look closely you may notice a name on the above web page that is
familiar - hint take a look at the acknowledgements! You may also find the
general layout of the speed controller I've put together is rather similar
to something you have seen before - but actually rather different in detail!

Andy

2000\06\27@151516 by Andrew Kunz

flavicon
face
>Right now I really am lost on this one Andy/Anyone care to explain how this
>works and more to the point how on earth do you know when/how to use this
>technique? Take pity on me, as I said I'm really a software guy :-)

Me, too.

The "how" is best covered in a high school or better Physics text.  The "when"
is "whenever you can."

>OK so in my project I only have a single 12V supply (no extra pack for the
>radio gear). Any suggestions on the best way to set things up to provide
>power to the "noisy" power part of the system, the pic based part and the
>radio part from the same supply?

OK, but seeing your application, you aren't in a noisy environment.  I race
"targets" at 50 MPH, with 60A+ loads on the nicads.

>Slightly confused here when you say "compare this input to last output" do
>you mean - the last input after application of the jitter filter? Maybe you
>could provide an example set of input and output values?

PulseIn = signal as measured by hardware, used only at the lowest level
PulseOut = signal as reported to next stage of the software (the "application"
layer)

if (PulseIn == PulseOut)      // Same signal, pass it through
    PulseOut = PulseOut
else if (PulseIn+1 == PulseOut)    // One shorter, stick with older output value
    PulseOut = PulseOut
else if (PulseIn-1 == PulseOut)    // One longer, stick with older output value
    PulseOut = PulseOut
else
    PulseOut = PulseIn       // Much different, pass newly measured value
through

You can also do other filtering at that last step, such as an FIR filter.

>Well it is a third generation of my submarine control unit (see
>http://freespace.virgin.net/andy.shaw/microcon.htm for an older version).
>I'm basically adding closed loop control of the dive system, it already has
>depth and tilt inputs for depth and attitude control but I would really like

Sounds interesting.

>BTW: If you look closely you may notice a name on the above web page that is
>familiar - hint take a look at the acknowledgements! You may also find the
>general layout of the speed controller I've put together is rather similar
>to something you have seen before - but actually rather different in detail!

I did all the PIC stuff that's in Skip Asay's (SubTech = http://www.rcboats.com) items
and I'm constantly working to upgrade them with him.  Tonight (I hope) to finish
up yet another X-tail mixer version for him.

Couldn't say that a few months ago, as he was still using Sergio's speed
control.  Not Any More!! <VBG>  Sure looks a lot like yours, except the new one
is in a 4 MHz 12C508 and his was a 16 MHz 16C54.

If I were doing something like you are, I'd go with the multi-chip approach.
Basically, you already have certain portions working with an RC-style interface,
right?  So have the 876 drive them using that interface, with a 74-series or GAL
chip to select the appropriate device to be controlled.  Then you have a LOT
more memory and time available to do the calculations.

The SubTech APC is a PI control also (at least the last versions I sent him, I
don't know what he's shipping right now).  The original was PD.  The PI control
is a real pain to set up if you don't have your boat level!  Next thing to do is
make a PD "setup mode" for it.

All the code is in Parallax assembly, but I use C to develop a lot of the later
algorithms, then just cut-and-paste it's output into the .SRC file.  Much
quicker way to make assembly!

Andy

2000\06\28@063351 by Andy Shaw

flavicon
face
Hi Andy/Folks,
Thanks for the info see below for a few points...
>
> The "how" is best covered in a high school or better Physics text.  The
"when"
> is "whenever you can."
>

OK so another question (which I'm going to create a new thread for) is what
books/web-sites etc. are around that give a good coverage of these sorts of
issues - PCB design, layout, ways of dealing with noise etc. How did you
learn about doing this sort of stuff? How do you know if it will work?

> >OK so in my project I only have a single 12V supply (no extra pack for
the
> >radio gear). Any suggestions on the best way to set things up to provide
> >power to the "noisy" power part of the system, the pic based part and the
> >radio part from the same supply?
>
> OK, but seeing your application, you aren't in a noisy environment.  I
race
> "targets" at 50 MPH, with 60A+ loads on the nicads.
>

Yeah I know that my problems are not as bad as yours, however a sub does
have a few issues of it's own. The signal levels drop very quickly as you
dive so noise often becomes a problem. Also I'm not as good as you at fixing
these problems so avoiding any noise is good for me! What would you advise
as a good power supply setup for the above? Would it help/make sense to have
a setup like the one you described for the pic side of things then a
separate LDO regulator for the R/C stuff, any advice on the best
configuration for the regulator etc. for the R/C stuff?


>
> I did all the PIC stuff that's in Skip Asay's (SubTech = http://www.rcboats.com)
items
> and I'm constantly working to upgrade them with him.  Tonight (I hope) to
finish
> up yet another X-tail mixer version for him.
>
> Couldn't say that a few months ago, as he was still using Sergio's speed
> control.  Not Any More!! <VBG>  Sure looks a lot like yours, except the
new one
> is in a 4 MHz 12C508 and his was a 16 MHz 16C54.
>

And it all works really well. If what I wanted was to get a sub up and
running quickly and working well I'd just go out and buy the stuff from
Skip. But that would be no fun, one of the major reasons I'm into subs is
the "interesting" control problems you have. I enjoy trying to build my own!

> If I were doing something like you are, I'd go with the multi-chip
approach.
> Basically, you already have certain portions working with an RC-style
interface,
> right?  So have the 876 drive them using that interface, with a 74-series
or GAL
> chip to select the appropriate device to be controlled.  Then you have a
LOT
> more memory and time available to do the calculations.
>

Once again I'm sure that the above is the best way, but I quite like the
idea of seeing how much I can get out of one chip - obviously if I was doing
this for a living the amount of time I'm going to waste on this would not
make sense but this is my hobby I like making things hard for myself! I'm
also going to re-write the whole lot in C this time around, ASM is fun but
I'm getting a bit fed up of making things really hard for myself. Also the
algorithms are getting more complex and it is hard to see exactly what you
are doing in ASM (wood and trees sort of thing).

The other thing I really want to include this time is...
a) The ability to tune most of the stuff at the waterside so I can reduce my
test time.
b) In circuit programming so when things get bad I fix it. Though is does
mean I'm going to look even more of a geek, you don't get many people
plugging a notebook into a boat in my local club!

Thanks

Andy

2000\06\28@081553 by Andrew Kunz

flavicon
face
>OK so another question (which I'm going to create a new thread for) is what
>books/web-sites etc. are around that give a good coverage of these sorts of
>issues - PCB design, layout, ways of dealing with noise etc. How did you
>learn about doing this sort of stuff? How do you know if it will work?

I worked for an RF-oriented company at the time.  I learned all kinds of stuff,
but NO WAY do I understand even half of it!

I worked, they didn't pay, so now I got a real job!

>Yeah I know that my problems are not as bad as yours, however a sub does
>have a few issues of it's own. The signal levels drop very quickly as you
>dive so noise often becomes a problem.

That's a different kind of noise, tho - "real" random noise (moreso than me).
The noise in my system was caused by the electronics, and that's a lot easier to
deal with.

I did a smart receiver to FMA (never went to market, it was a bad experience).
In one demo I did the signal was much less than the noise, but the receiver
worked perfectly (I was surprised).  I might revive some of that code, and make
it available to the public.

>What would you advise
>as a good power supply setup for the above?

Do the same thing.  LC filter the input from the batteries.  Have both big and
small caps at the inputs to the regulators.  Have big and small bypass caps at
the processor.  Put big caps at the power leads feeding each servo (you can draw
1A on those critters).  Have resistors on all processor I/O pins.

>Would it help/make sense to have
>a setup like the one you described for the pic side of things then a
>separate LDO regulator for the R/C stuff, any advice on the best
>configuration for the regulator etc. for the R/C stuff?

I would recommend a regulator for the processors (all on the same is OK).

If possible, it would be great to have one regulator per servo (ie, do the 12V
to 6V drop right where the servo plugs in).

The radio itself should be on a separate regulator, LC isolated on the power
side and R isolated on its output.

Most of these can be 100mA TO-92 or SMT regulators and caps.

>Once again I'm sure that the above is the best way, but I quite like the
>idea of seeing how much I can get out of one chip - obviously if I was doing
>this for a living the amount of time I'm going to waste on this would not
>make sense but this is my hobby I like making things hard for myself! I'm

That's a valid reason for your operation.  Skip and I were talking about you
last night.  He's probably going to visit your site today.

There are other advantages to your method.  You have one set of connections, his
requires connecting all these little boxes together.

His goal was to have one box do one thing well, and I think we achieved that.
It's also a lot easier to add updates this way, as they don't affect other parts
of the system as much (time-wise).

All that I did for him would easily fit in a '876 chip, and I've discussed
putting them all together, but it won't ever happen.  There's a guy in Europe
who did that and wishes he hadn't!

>also going to re-write the whole lot in C this time around, ASM is fun but
>I'm getting a bit fed up of making things really hard for myself. Also the
>algorithms are getting more complex and it is hard to see exactly what you
>are doing in ASM (wood and trees sort of thing).

Tell me about it!  This is one of the very good reasons for C on a PIC (another
being not having to worry about if a register is available at any one time).

>The other thing I really want to include this time is...
>a) The ability to tune most of the stuff at the waterside so I can reduce my
>test time.

'876 and ICD!

>b) In circuit programming so when things get bad I fix it. Though is does
>mean I'm going to look even more of a geek, you don't get many people
>plugging a notebook into a boat in my local club!

'876 and ICD again!

Andy


Thanks

Andy

2000\06\28@084248 by ArthurBrown

flavicon
face
Hi all just to add this.

One more point to pcb and supply smothing is to use a diode in the supply to
the servo's with a large cap to supply the current these need.
The caps supply the cuurent and the diode's stop the rest of ciruit taking
voltage from servo being feed.
Modle railway point's are feed this way save's having to have large power
supply.

Regards Art

---Snip---

> If possible, it would be great to have one regulator per servo (ie, do the
12V
> to 6V drop right where the servo plugs in).

2000\06\28@090751 by Andy Shaw

flavicon
face
Hi Andy,
I guess you like to start work nice and early in the morning.....

>
> That's a different kind of noise, tho - "real" random noise (moreso than
me).
> The noise in my system was caused by the electronics, and that's a lot
easier to
> deal with.
>

Yeah, I understand that but it does mean that the R/C side becomes much more
likely to be troubled by any noise from the electronics as well....

>
> That's a valid reason for your operation.  Skip and I were talking about
you
> last night.  He's probably going to visit your site today.
>

Say Hi to Skip for me (and from Alec Gibson a mutual friend), and thany him
again for me.
BTW his Albacore kit looks very nice I particularly like the dive system
(never did like all that compressed gas stuff that seems so popular in the
US). So have you built one up as a test rig for the X tail mixer ;-)

>
> >The other thing I really want to include this time is...
> >a) The ability to tune most of the stuff at the waterside so I can reduce
my
> >test time.
>
> '876 and ICD!
>

Actually for this one I'm probably going to just build in a config mode
(possibly enter it by some odd combination of the various R/C inputs), that
basically lets you change some of the settings held in the eeprom. My
current design has a couple of pots etc. for setting various things and it
would be really nice to be able to change them quickly (i.e. without taking
the sub to bits).

> >b) In circuit programming so when things get bad I fix it. Though is does
> >mean I'm going to look even more of a geek, you don't get many people
> >plugging a notebook into a boat in my local club!
>
> '876 and ICD again!
>

Yup that's the plan. Need to find a suitable waterproof connector though....

Andy

2000\06\28@092207 by Andrew Kunz

flavicon
face
>I guess you like to start work nice and early in the morning.....

No, I don't get in until 7:00 AM.  It's a half-hour drive and my wife likes to
see me in the morning.  I like to be here by 6:30 when they unlock the doors but
it doesn't happen too often.

It's a lot more relaxed than the 3:00 AM-noon shift I used to do, though.

>Yeah, I understand that but it does mean that the R/C side becomes much more
>likely to be troubled by any noise from the electronics as well....

Right, but it also means that it can be filtered better.  Guess I need to get
some source code out...

>US). So have you built one up as a test rig for the X tail mixer ;-)

One of these days, when he gets caught up, I will.  I have the radio for it, and
all the electronic gadgets (in prototype form at least).

I never figured out where the sponsons go, though <G>.

>Actually for this one I'm probably going to just build in a config mode
>(possibly enter it by some odd combination of the various R/C inputs), that
>basically lets you change some of the settings held in the eeprom. My
>current design has a couple of pots etc. for setting various things and it
>would be really nice to be able to change them quickly (i.e. without taking
>the sub to bits).

An opto-isoloted RS-232 port would be one idea.

>Yup that's the plan. Need to find a suitable waterproof connector though....

An opto-isolated port is easy, and doesn't need to be waterproof.  You just need
a programmer which talks slowly enough to the part to make it happen.

Didn't we just finish that thread?

Andy

More... (looser matching)
- Last day of these posts
- In 2000 , 2001 only
- Today
- New search...