AC Line Safety, part II - Linear Optocouplers

Hi everyone,

Well, my current circuit has hit a roadbump of sorts since Digikey will no longer sell the transformer going forward. I have the feeling that commodity prices will continue this trend, i.e. transformers will get eliminated where possible and replaced by solid state electronics. So I am investigating this as an alternative, i.e. the use of linear opto-couplers. The IL300 series seems popular, used by multiple manufacturers.

However, I am stepping way out of my comfort zone here, as I am unfamiliar with this sort of topology. I presume that if I want to capture an AC input that I'd have to use a Bipolar circuit as shown below (pulled from this exhaustive and excellent paper).

Now for my questions...

The article leaves it up in the air what operational amplifiers to use... though the author mentions the OP-07 series further up in his paper. Are there other choices you would endorse? This seems like a somewhat pricey op-amp.

Another question is the Vcc power supply for the op-amp on the 'high' side, i.e. for U1. I presume that in order to maintain isolation that the power supply for the left Op-Amp has to be segregated from the low-voltage part of the board. Presumably, something like the drop-cap power supply that Atmel endorses for its single phase power meter would work? The line is coming in on the top left, 3.3VDC is generated by the U1 voltage regulator.


where:
C10: X2 Type cap, 0.68uF
R10: 1W, 500V, 5% carbon film, 470 Ohm
D11: 1A 400V, IN4004
D10: Zener Diode, 500mW, 15V, BZX55-C15
C11: 470uF, 16V Aluminum Elec. Cap
U4: LM1117MP-3.3V linear voltage regulator
C12: 10uF, 16V Aluminum Elec. Cap
I'd substitute a 5V voltage regulator just stay further inside the electrical limits of the OP-07 and may have to review the circuit performance with 115V inputs... but anyhow, it's interesting! I also presume that I'd have to use multiple resistors on the high side in series to limit currents in case UL or whoever decides to short them during testing?

All in, the cost compared to using a traditional transformer seems comparable and it's certainly a lot more complicated a circuit. But the local supply situation may force me to use this solution as Digikey is about to run out of the transformer in question and the EU supply (while available) is expensive in low quantities ($20 extra per order).

Last but not least, I ran across this amusing tidbit in the Atmel power meter page that reminded me of a certain circuit that we've discussed here before...

where the left input on top is attached to line (230V), the lower left to the low-voltage ground, and the output is the line running off to the right. Atmel is using 680 k? resistors for R20 and R23, 1k? for R21, 3.3M? for R22, a 47uF capacitor for C20, and V1 is a 40J varistor with a 250V rating. The resistance values on the 'low side' seem to be chosen to minimize the current needed to bias the circuit. The use of a single resistor from the capacitor input to line voltage was a bit surprising to me. The output is attached directly to one of the Atmega ADC input pins.

Hmmm.. did some more digging. Looks like Analog devices thought of this long ago... and has a isolated ADC on offer, the 16bit resolution (and price!) are impressive.

A better option may be a isolated op-amp like the HCPL-7510. What's really nifty about this op-amp is that it'll take a bipolar signal and converts it into a unipolar one - perfect for input into the ADC I already have or an Atmel Atmega chip. The 'high side' power supply still applies (i.e. drop-cap) to power the chip on one side. But at least the complete cost is comparable close to that of the transformer it replaces.

The only not-so-great aspects are that the output voltage is centered around 2V, which will likely require me to have a shunt to generate that for the CM input on the ADC, and this op amp also requires an 4Vref input. All in-all, doable since the conversion also would eliminate a number of the chips, parts, etc. currently used to massage the transformer output.

Whipping up the voltage divider over at Rarltron suggests a 1k 'shunt' resistor would require a 1.6M input resistor for a 400Vp input (i.e. 230Vrmsx 1.41 (rms-pp conversion) x 1.25 (safety)). That in turn suggests using either three 560k or two 820k resistors on the input side of the voltage divider. Even if one of the resistors is shorted out, the input voltage into the Op Amp never exceeds safe continuous limits.

I might also look into the energy measurement chips that several of the big semiconductor companies are making. Don't know anything about them, just am aware of them. Some look pretty sophisticated, SoCs with built-in MCUs etc.

[quote author=Jack Christensen link=topic=98629.msg740167#msg740167 date=1332891363]
I might also look into the energy measurement chips that several of the big semiconductor companies are making. Don't know anything about them, just am aware of them. Some look pretty sophisticated, SoCs with built-in MCUs etc.[/quote]

I tried a couple of them. While some folk (like the Olimex energy logger) claim to have a working unit, my experience was not positive. In particular, getting the calibration set up was opaque to impossible, given that I don't have access to a lab where precision current / volt waveforms can be generated. But maybe the documentation has improved to the point where I can use their gear. I have the shield here ($50!) but am not holding out too much hope to be honest - though the Thierry's effort to combine this shield with a Nanode is not only fascinating but much better documented than anything else I have seen. But even he has not cracked the reactive and apparent energy nut yet.

So what made me come back to the Arduino time and again is the simple fact that the Arduino is relatively easy to understand, debuggable, etc. I can't say the same for most energy-logging chips unless one has very specific knowledge about that area of electronics. As a manufacturing engineer, I simply need something that can serial.print problems /status messages for me as I grope my way towards a working solution.