Interfacing a SSR relay to the arduino

Dear all, part of my project is having to OPEN/CLOSE a gas cylinder and so I decided to use a solid state relay - http://www.crydom.com/en/Products/Catalog/m_p.pdf connected to the arduino having its output of the relay connected to a solenoid valve. Since I am not confident in relays, does anyone know if I can just connect the relay to a digital pin, giving it a HIGH or LOW?

I dont know if there can be any Back EMF generated or if I have to coinnect any electronic circuit before the relay.

Thank you

check this thread - http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1221230237/13 might solve your questions.

and the playground - Arduino Playground - HomePage

tnx for reply...

but my relay is a SSR and does not have any coils in it. I have searched the forums and there were queries on this topic.

My question is if I can connect the SSR to the digitla pins without having any current limiting resistance, and if any how do I calculate that impedance?

Tnx

the REALLY Good part of the SSR's is that they have been designed to operate directly from logic level outputs! you dont need any extra circuitry yo run it ( atlest it wont get damaged :wink: )

But I found out that the arduionos pins limit is 40mA . how can I know that I wont fry it or something?

The SSR link used is in the first post.
tnx

A better datasheet is this http://datasheet.octopart.com/MPDCD3-B-Crydom-datasheet-123962.pdf

As one can see the Typical Input Current @ 5Vdc [mA] is 2.6A. How can I know if I wont fry anything?

Tnx

As one can see the Typical Input Current @ 5Vdc [mA] is 2.6A.

:slight_smile: well it was written like this ..
Typical Input Current @ 5Vdc [mA] 2.6

that is not 2.6A but 2.6 mA :wink:

Yes yes my mistake. hehe i just got it to work, since I connected the relay to a bulb and programed it to switch on and of...

Now the next step is to connect it to a solenoid valve.

tnx

Good but when playing with relays do look at the maximum current requirements you need atleast a relay capable of doing double the switching than you require :wink:

SSRs are Mity Fine. No problem on driving the SSR right off a pin... which you already proved using a bulb as SSR load.

An old fashion tungsten bulb is a tame load, you might wanna look at one other thing before you try to kerchunk the solenoid. A solenoid has inductive "kick" and has the same issue with "punching through" the SSR as a conventional relay coil has in "punching through" a microcontroller output pin or transistor. See note 3 of your data sheet.

3) Inductive loads should be diode suppressed

So although you can safely connect the SSR control pins to Arduino, you may need an RC snubber or diode to protect the SSR from the solenoid. We assume its an AC circuit you cant simply use a regular rectifier diode across the solenoid. You need a TVS diode or a MOV or something like that.

The SSR may take the abuse for a while, they are pretty rugged. Even after it punches thru your SSR may be stuck ON or OFF, but the SSR isolation should still prevent any badness from getting back into your Arduino.

Consider the failure mode of the suppression part in your design.

Gas Discharge Tubes usually fail OPEN. This causes no obvious malfunction, but the loss of protection will cause frequent failures of the (formerly) protected component.

Zener diodes, MOVs and solid state suppression generally fail SHORTED. So at end of life the fuse or breaker trips until the part is replaced. This is usually preferred. (you DO have a fuse or breaker DONT YOU ?)

for 120 Vac mains I have used P6KE180CA see it here

if youre too excited and dont wanna stop playing solenoid, just hack open a cheap surge strip and steal the MOV from it.

Good luck with your project!

hi
I was searching for some hint for my project, and hope maybe I can get some answer from this thread. Is heating element considered an inductive power? I am actually using a PIC micro-controller to switch on/off a heating element every 1/8 seconds. and I am getting garbage signal through the digital output line...the SSR I used is rated at 25A AC. the heating element is rated at 1500W, so I assume maximum of 12.5A. so if I have to design a RC snubber, what values should I choose, or is there an easy solution? thanks

Is heating element considered an inductive power?

No it can be considers a resistive load, with just negligible induction if any.

the SSR I used is rated at 25A AC. the heating element is rated at 1500W, so I assume maximum of 12.5A. so if I have to design a RC snubber, what values should I choose, or is there an easy solution?

No snubber required.

A important issue that users new to ssr at high loads is not considering the need for a heat sink. The semiconductor thyristor devices internal to the SSR like all semiconductors are not perfect conductors and thus have a certain voltage drop. The heat dissipation for the device in watts is that voltage drop times the flowing current. Lets say there is 2 volts dropped at 12 amps, that is 24 watts of heat being dissipated inside the SSR. One can relate to how hot a 25 watt incandescent lamp puts out and this inside the rather small SSR package.

There is a reason that the back surface is made of smooth metal, it's designed to be bolted (with heatsink grease) to a heatsink. Now that can be just a large enough metal plate rather then a fancy finned job. If you can't hold a finger on for more then a few seconds you probably need a larger metal surface. :wink:

Lefty

If you can't hold a finger on for more then a few seconds you probably need a larger metal surface.

That could give you a small jolt :wink: so dont tell us that we were trying to kill you ! ::slight_smile:

the heating issue is taken care of. I used a CPU heat sink, mount the SSR on the heat sink with cpu thermal compound..that's why I am not sure where the problem is coming from...

I'm not sure I understand:

I am getting garbage signal through the digital output line...

I got the pic module pre-programmed to do serial LCD output (interfacing a hd47780). The project is to control a popcorn popper to roast coffee. I have a module that'll read the temperature every 1/8 second, output to a computer (router), then my program calculate whether the heating element should be turned on or off. the program then output the current time, temp, all that info through the pic to LCD, and use the pic's digital output to control the SSR. When there is no load, everything seems to be fine. when the SSR starts to switch on/off, the pic starts to screw up (like sending out garbage to the LCD module, rebooting). I know my program is not sending garbage since it record everything that was sent to the pic. thanks for all the help