Driving SSR ("hockey-puck") directly with Prop I/O
ags
Posts: 386
I would like to control 120vAC devices with a design that already is using a Propeller. I will use a SSR to do this (datasheet here: http://www.mouser.com/ds/2/418/NG_DS_1308242_SSR_1105-115996.pdf)
The SSR specs are minimum on control voltage 3v and maximum control current 15mA. The Propeller specs are minimum Voh=2.85v @ Ioh=10mA.
From the specs, this does not seem to be a robust design, instead suggesting an intermediate driver providing a 5v control (I have 3.3v and 5v available).
However, I have prototyped and found the Propeller does control this SSR without a buffer. Does anyone have any field experience with a similar situation that validates the reliability of this if I were to not use a 5v buffer (is the Propeller Voh(min) grossly understated/convervative?)
Thanks.
The SSR specs are minimum on control voltage 3v and maximum control current 15mA. The Propeller specs are minimum Voh=2.85v @ Ioh=10mA.
From the specs, this does not seem to be a robust design, instead suggesting an intermediate driver providing a 5v control (I have 3.3v and 5v available).
However, I have prototyped and found the Propeller does control this SSR without a buffer. Does anyone have any field experience with a similar situation that validates the reliability of this if I were to not use a 5v buffer (is the Propeller Voh(min) grossly understated/convervative?)
Thanks.
Comments
-Phil
I am not following the statements about leakage current through tristated pins during reset. I presumed the SSR would not drive the control input to any level.
Edit: Good grief, I've gotten quite lazy. It just occurred to me that I may have been confused and confusing because what I had planned just makes no sense. I was going to use a 74HCT34 (hex non-inverter) for the 3.3v->5v translation. That just doesn't make sense. I can use a single xtor and resistor to accomplish this. (although I don't have a clue which xtor to use - other than RF or power stuff I can't recall when I saw a discrete device). Does this now make more sense?
Let's say the LED has a Vfwd of 1.9V at operating current. Because of this, the Prop will not see more than 5V - 1.9V = 3.1V in operation. But the SSR will see a full 5V across its inputs when the Prop pin is pulled low.
But there are caveats. With the Prop pin driven high, the SSR will still see 1.7V across its inputs. You will have to determine if that is low enough to keep the SSR turned off. Also, when the Prop pin is tristated (e.g. during reset) there is a leakage path into the pin and through the upper protection diode to +3.3V. If the LED leaks more than 500 uA when driven by 5V - 3.3V - 0.6V = 1.1V, it will exceed the Prop's Abs Max rating for the pin.
-Phil
http://www.mouser.com/ProductDetail/NXP-Semiconductors/74AHCT1G126GV125/?qs=sGAEpiMZZMtOwpHsRTksowxVT%2f9EkYvNJBzeRDpsyro%3d
if sinking (open drain) is enough:
http://www.mouser.com/ProductDetail/NXP-Semiconductors/74AHCT1G07GV125/?qs=sGAEpiMZZMtOwpHsRTksowxVT%2f9EkYvNOO40SuOGNBI%3d
http://www.mouser.com/ProductDetail/ON-Semiconductor/MC74VHC1G07DTT1G/?qs=sGAEpiMZZMtOwpHsRTkso1w2FFrRgZoC7DuyJUlkShc%3d
-Phil
@tonyp12 that seems like it would work. $0.08 in quantities of one... I suppose I can afford that (but too bad any additional part is needed).
@PhiPi when you mention a single BJT/MOSFET, do you mean applying +5v to the SSR and then biasing the BJT for a path to ground? I don't even know where to start searching for a a single device any more.
Thanks for all the good feedback.
RadioShack carries transistors. Any general-purpose NPN would do the job.
BTW, I missed the 1.0V for guaranteed "off." That could indeed present a problem.
-Phil
Measure it.- measure the Vi and Drive I, and also lower the voltage to see how much margin you actually have.
SSR's usually use an infrared diode (just over 1V Vf), and they have a series Rs
It if specs 15mA MAX, that is at 32V so indicates a Rs of close to 2k.
Down at 3V drive with a 1V LED, that is going to now be close to 1mA of Drive, so the Prop will drop less.
What would make me nervous, is the higher voltage part specs 4V as a MIN.
I like the simplicity of localroger's approach - but that would be out of spec for my SSR. Perhaps the OPTO-22 specs differ from my SSR. Or perhaps I could get away with it.
It occurs to me that tonyp12's suggestion (74HCT1G126) is basically a one-transistor approach. I actually like the idea of not having the Propeller directly driving (or sinking) the SSR control line. All other signals that go off-board in my design are through some kind of a driver. The drivers are socketed, so if something bad (aka stupid) happens, it is just a quick replacement (the Propeller is not socketed). Unfortunately the NXP part tonyp12 suggests is not available in a DIP, but it would be sacrificial nonetheless. I like the active driver over the open-drain solution (both isolate the Propeller from damage) because it also protects my onboard voltage regulator by not having +5v directly supplied. In the case of the control line being shorted to ground, the open-drain method would result in a direct short of the regulator. The '126 method would protect the regulator at the expense of the $0.38 driver.
Does this sound reasonable? I should try not to make a career of this one connection...
That gives full isolation, and you can use any voltage within the SSR range.
1. A "direct short of the regulator" would only occur if you used a really big transistor. A puny 2N3904 will fail before it shorts the regulator.
2. Most regulators are protected against shorts by virtue of built-in thermal limiters.
-Phil
I'm not following: which higher voltage part?
Your calculations make sense, and a diagram of the SSR does indicate a IR LED and Rs. Reverse engineering, that does mean 2k, and 1mA current if driven to 3.3v. While not a big safety margin, that would work. That would have the Propeller directly driving the control line with 3.3v.
-Phil
So I guess I can use a BJT, which requires a series resistor between Prop pin and base, or I can use a MOSFET and avoid the resistor (but would the Vih/Vil be correct?) or the 74HCT1G126 tonyp12 suggests (which has correct Vih/Vil per spec). I think.
Your link data sheet says this
480VAC Rated Models
Those have 4V min specs.
I would still measure it, & check margin, those guys working at 230V/480V, do not know what a decimal point is
Optocouplers : I see a LTV-826 comes in DIP8, for 2 channels and is a moderate price.
-Phil
I'm not ever going to use the higher-voltage 480VAC SSRs. (until the board is done, at which time I will identify a reason that I must support 480VAC...)
I think the $0.38 part tonyp12 suggested will be the plan if I cannot drive the control line directly from the Prop (which would have the associated risk of damage to the Prop).
@PhiPi so you're saying the MOSFET would conduct with a floating gate - or just a best practice (for robustness)?
Duane J
Ags, you're over analyzing this. For driving any optoisolated device I use a 2n3904 in one of the posted circuits. In your case circuit 1 would be the best choice with R1 ~ 1K and R2 ~ 150 ohms. You could even leave out R2. A mosfet would also work as Phil suggested.
The NPN needs a resistor in series with the base, else the Prop pulldown is clamped hard at 3v3-Vbe
ags,
Yes, the MOSFET could conduct if the gate is left floating, e.g. during a reset.
To avoid the damage of the internal diode simply add an external diode from the pin to vcc(+3.3). I have already used one diode from pin to vcc, one from pin to gnd and two resistors in series (just for insurance) from pin to live 240VAC as a zero crossing detector.
All that is why I tend to just go with a transistor switch. Isolates the prop from all the higher voltages without relying on the protection diodes and trying to stay in the margins. Like Phil says, you can still get simple NPN BJT's at Radio Shack for this application.
I knew not that such a thing existed. I must have them!
I understand that if the MOSFET gate was high then the Prop was reset, the SSR would not be turned off during reset (but it would be turned off immediately upon coming out of reset (if the Prop pin is set OUT and =0). If the power to the Prop was removed, that would also remove the +5v to the SSR, so that's also OK, But it is good practice, I admit, to prevent the gate from floating.
I'm totally puzzled as to why one would add a resistor in series with the MOSFET gate. The capacitance is far less than many other connections that Prop sees, so I suspect the purpose isn't to limit transient/switching current. Why do you suggest this?
Thanks.
Edit: BTW, I did verify that the regulator I use (LM317 series) does have thermal and current protection. All this time I thought it was significant point of failure if the board was improperly connected. Thanks for pointing that out. It never occurred to me that a regulator could survive a direct short across output/ground.
This is brilliant. Thanks. (what is the application in which the resistor between base and emitter is useful?)
1. The Base Emitter resistor consumes any leakage current from the Collector to Base. C to B leakage can be multiplied by the gain of the transistor resulting in some heating.
2. Faster switching times.
Zetex has quite a few variations. NPN, PNP, and many resister combinations.
Duane J