crapalanche
New Member
Hello all,
I'm trying to watch residential single phase 60hz 120 volts zero-cross with a microcontroller. I've built a resistor divider and attached it to an optoisolator (darlington NPN on the isolated side). I'm not using a rectifier bridge, so I'm only getting a half-rectified signal. The optoisolator is then connected to my MCU and I can see the zero cross.
Granted, the signal I'm getting for the zero cross is a fairly square wave with a duty cycle that spans a good portion on the center of the mains sine wave. That's not really an issue. I'm more interested in determining which direction the AC current is flowing. I've been able to accomplish this programatically in the MCU with the signal that I have.
Now, I'm trying to attach an inductive load via a triac on the mains side of things and control it from the MCU--gate triggered from the MCU. Safely. My MCU is powered off an isolating step-down transformer. Can I connect the ground of this circuit to the ground of the mains? Is this safe? Will this explode my circuit? Will it work?
Or, do I have to put a small isolation transformer or optoisolator between the MCU and the triac?
I'm trying to watch residential single phase 60hz 120 volts zero-cross with a microcontroller. I've built a resistor divider and attached it to an optoisolator (darlington NPN on the isolated side). I'm not using a rectifier bridge, so I'm only getting a half-rectified signal. The optoisolator is then connected to my MCU and I can see the zero cross.
Granted, the signal I'm getting for the zero cross is a fairly square wave with a duty cycle that spans a good portion on the center of the mains sine wave. That's not really an issue. I'm more interested in determining which direction the AC current is flowing. I've been able to accomplish this programatically in the MCU with the signal that I have.
Now, I'm trying to attach an inductive load via a triac on the mains side of things and control it from the MCU--gate triggered from the MCU. Safely. My MCU is powered off an isolating step-down transformer. Can I connect the ground of this circuit to the ground of the mains? Is this safe? Will this explode my circuit? Will it work?
Or, do I have to put a small isolation transformer or optoisolator between the MCU and the triac?