# Galvanic separation between a microcontroller and a motor driver

Is it possible to achieve galvanic separation between a microcontroller and this driver . It's a dual full bridge driver and I'm going to parallel it's outputs (consequently the inputs and the sense pins) for higher current output (Figure 7 in the datasheet) to drive a DC motor and sense it's current. Is there a simpler solution without using this driver? A H-bridge made of MOSFETs seems to me to be a higher part count and complicated solution.

• m.Alin, no time for an answer, but look into optocouplers, they are the simple and standard solution for isolation with control. – Kortuk Aug 10 '11 at 15:08
• @Kortuk yes, my first thought was optocouplers for the 2 input pins. But what about the driver's sense pin, which I have to measure it with a microcontroller's ADC? Doesn't the driver requires to have the same GND as the microcontroller for the sense pin to work? – m.Alin Aug 10 '11 at 15:16
• You can get an optocoupler that is an LED that injects carriers into a transistor, this means any current on the LED is amplified on the output. Even the LED to a photodiode will exhibit this. With this and a limit resistor you can tell from the other side how much current/voltage is being pushed by the other side and sense the feedback. With a bit of work and a multimeter you can do the calibration yourself if needed. If I have time later I will write an answer. To anyone else whom would like to first, please take anything from what I have written with my full consent. – Kortuk Aug 10 '11 at 15:27
• @Kortuk, you should promote your comment to an answer. – user3045 Aug 10 '11 at 15:56
• @kurtnelle, read the rest of my comment. If I get a chance later I will write an answer. If someone else would like to write an answer previous to me getting to it which might take a day or two please write and answer and feel free to use anything I have written. In its current form my comment is below my quality standards of an answer. I would need to make a few schematics, get links to other sources of information and format the answer better. Right now it is just someone trying to help out a mate with a technical problem while other write more thorough answers to teach the user. – Kortuk Aug 10 '11 at 16:06

For the inputs any common optocoupler should do, like a CNY17. If you want to control the motors with HF PWM the 6N135 may be a better choice; it's faster.

For the feedback you have an analog signal, so the CNY17 is no use here. There are linear optocouplers, however, like the IL300. The current transfer function is anything but linear, but thanks to a second photodiode to use in a feedback loop you get an excellent 0.01% servo linearity.

The power nets ($V_{CC}$ and $GND$) at the left are obviously different from those at the right.

Note: Servo linearity means that neither LED nor photo-diode need to have a linear characteristic (they don't), but that they can achieve this linearity by using them in a feedback system like the one shown in the schematic. The conditions for such linearity are good matching between photo-diodes and a good matching of the current transfer function between LED and either photo-diode.

• very slick circuit. It even compensates for the LED characteristics changing over time, although there would be some problem with the matching of the two photodiodes. You could use two of these such that Vout is fed back (through an LED/photodiode) to U1, which would eliminate that problem. – akohlsmith Aug 10 '11 at 16:29
• @Andrew - Given the 0.01% linearity it looks like they managed to solve the matching problem more than adequately. BTW, you can't get better servo linearity by adding other feedback paths without trimming; this matching level is achieved because both diodes are produced in the same process. – stevenvh Aug 10 '11 at 16:48
• @stevenvh What is servo linearity? – m.Alin Aug 10 '11 at 18:43
• @m.Alin - added a note on servo linearity in my answer. – stevenvh Aug 11 '11 at 4:54

Another technique sometimes used would be to put a microcontroller in the motor's galvanic domain, and isolate serial digital communication between that and the rest of the system - microcontrollers after all being dirt cheap. This lets you avoid having to do any isolation of analog signals - potentially you can close servo loops or whatever with the directly associated microcontroller and perhaps have a receive-only command channel (though if you need a reply channel, that's not hard).

A major downside however is that you then need isolated microcontroller test gear if you want to do in circuit debugging while maintaining isolation. At higher voltages, it could be a safety issue too.

It might also be worth looking more into the specific requirement driving the perceived need for galvanic isolation - Noise? Safety of users or equipment?