brjhaverkamp
Posts: 5
Joined: Tue Oct 06, 2015 6:24 pm

Best SSR kit

Mon Nov 16, 2015 1:28 pm

Hello all,

I am looking for a good Solid State Relay kit/module to switch on and of an amplifier and some other external equipment.
I read a lot about the Sainsmart modules. But they seem to have some drawbacks. The biggest ones is that to switch them on, the GPIO signal should be 0, i.e. inverted. This means that most of the time, the GPI must be high and therefore will draw current.
Also if the Pi fails for some reason and looses power, the amp will switch on.
Many forums advice to buffer the module with a transistor in front.

I would like to have a single module that has it all, so good buffering, non inverted and sufficient capacity to switch a 100-200 W 230VAC device. An added bonus would be a 2 or 4 channel kit.
Soldering is not a problem, but creating my own PCB would be a minus:-(

Does anyone have advice on a good module? I googled extensively, but didn't find anything.

Regards,

Bert

grahamed
Posts: 277
Joined: Mon Jan 30, 2012 7:01 pm

Re: Best SSR kit

Mon Nov 16, 2015 5:03 pm

This one does not seem to be invertinghttp://www.sainsmart.com/8-channel-5v-s ... duino.html

stevend
Posts: 236
Joined: Fri Oct 11, 2013 12:28 pm

Re: Best SSR kit

Tue Nov 17, 2015 1:37 pm

brjhaverkamp wrote: This means that most of the time, the GPI must be high and therefore will draw current.
Not generally the case nowadays; the current drawn in each state will usually depend almost entirely on what is connected to the output. So you need to look at the circuit of the relay interface to determine this
brjhaverkamp wrote: Also if the Pi fails for some reason and looses power, the amp will switch on.
Bert
Quite possibly not. If the Pi loses power, its outputs will most likely turn off completely. So as long as your relay circuit requires some current to turn it on, it will remain off.
There is usually some leakage current which you need to consider, especially if you have a fairly high impedance load such as a transistor or FET. Addition of a bias resistor (to set the "off" level) can often solve this.

grahamed
Posts: 277
Joined: Mon Jan 30, 2012 7:01 pm

Re: Best SSR kit

Tue Nov 17, 2015 4:08 pm

The schematic for http://www.sainsmart.com/8-channel-5v-s ... duino.html indicates that it is non-inverting and will be -
on when the GPIO is high
off when the GPIO is low, or the Pi is off, or the Pi is disconnected.

In general you cannot say that a current will be drawn from the GPIO simply because the GPIO is high, e.g. if the GPIO is connected to an LED and thence to the rail a current will flow, and the LED will light, when the GPIO is low.

Candyjet
Posts: 56
Joined: Sun Jan 10, 2016 3:45 pm

Re: Best SSR kit

Wed Mar 09, 2016 11:15 am

I need a SSR to control a low-current device. I have already bought one incorrect SSR which needed an AC input apparently.
To be sure, are we saying that I can control the SSR in the post above using GPIO pin output?
What I need is for an output of a GPIO pin, of around 1.5secs duration, to trigger the relay for the same time and then switch off the relay.

Thanks,

CJ

grahamed
Posts: 277
Joined: Mon Jan 30, 2012 7:01 pm

Re: Best SSR kit

Wed Mar 09, 2016 2:56 pm

Hi

What do mean by a low-current device?

If you mean it's a d.c load then an SSR would be inappropriate (as 99% of them expect an a.c. load) . You would need a simple BJT or FET, or a BJT/FET plus relay, or if the current and voltage are low enough just a resistor.

Candyjet
Posts: 56
Joined: Sun Jan 10, 2016 3:45 pm

Re: Best SSR kit

Wed Mar 09, 2016 3:43 pm

I am using relays to complete a circuit which uses 2 CR2032 batteries to power it. At the moment I am using mechanical relays on a PiFace, but it is clear that one of the relays on the PiFace is not reliable enough for the project. The time that the relays are activated is important, and must be accurate to +/- 0.05 secs.

Each CR2032 battery is 3V. I presume they don't use much current as they are not big enough.

If I may add, I am no electronics expert (if this is not already evident).

Candyjet
Posts: 56
Joined: Sun Jan 10, 2016 3:45 pm

Re: Best SSR kit

Wed Mar 09, 2016 6:19 pm

I have added a photo for what I am doing here.
There are 2 switches on the controller, both of which have wires attached, soldered by me. The switches are labelled S1 and S2.
There is nearly 6v across them, from the 2x CR2032 batteries which are on the reverse of this controller. When S1 switch is pressed it appears to close the circuit, as the same effect is achieved by shorting together the orange and yellow wires. Similarly when S2 is pressed, it is the same as shorting the red and brown wires.

At the moment, I have each pair of wires going to a relay in a PiFace.It does work, but it has become clear that one relay is more reliable than the other, and the unreliable one is too unreliable to be of use. I would therefore like to get rid of the moving parts (the relays in a PiFace sound mechanical to me).

As was posted above, is it possible that a transistor will do the job?
I have little electronics knowledge, but do have access to a multimeter. I have started looking at the possibility of a transistor, but would seem to need to know the resistance of the circuit, which I don't know how to do here.

Any suggestions would be gratefully received,

Thanks,

CJ
Attachments
controller.JPG
controller.JPG (45.96 KiB) Viewed 2771 times

User avatar
rpdom
Posts: 16390
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: Best SSR kit

Wed Mar 09, 2016 6:34 pm

You could probably use an opto-isolator for that, as long as you connect them across the switches the right way round.

The current, as you suspected, is most likely to be tiny. The phototransistor in an opto-isolator should be able to switch that load with no noticeable delay. You just need resistors to couple them to the Pi.

grahamed
Posts: 277
Joined: Mon Jan 30, 2012 7:01 pm

Re: Best SSR kit

Wed Mar 09, 2016 8:34 pm

Hi

Agreed, use a a pair of optos.

Connect the transistors across the switches - 4 wires - no other connection to the foreign device. You don't need to worry about which way to connect - one way will work, the other won't, so you are 50/50. If one or both don't work just swap that connection.

4N25, 4N35 or any common "simple" opto - one with which shows just a diode and a transistor. Not a 6N137. Do not connect anything to the transistor base.

Why do people always ask for advise without saying what they are actually trying to do.....

Candyjet
Posts: 56
Joined: Sun Jan 10, 2016 3:45 pm

Re: Best SSR kit

Thu Mar 10, 2016 3:19 pm

Thank you both for your advice. I now have a pair of Opto thingys on order.
To be sure, I connect a GPIO controlled 3.3v pin out from the Pi to anode, GND to cathode, and the coloured wires from the controller to collector and emitter. I presume it is the latter 2 that is the 50/50 bet?

Thanks again very much for the advice. I will keep you updated. If rpdom sees a large pall of smoke over Essex, he'll know it didn't work.

CJ

User avatar
rpdom
Posts: 16390
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: Best SSR kit

Thu Mar 10, 2016 3:57 pm

Candyjet wrote:Thank you both for your advice. I now have a pair of Opto thingys on order.
To be sure, I connect a GPIO controlled 3.3v pin out from the Pi to anode, GND to cathode, and the coloured wires from the controller to collector and emitter. I presume it is the latter 2 that is the 50/50 bet?
You will also need a suitable resistor to prevent the LED in the opto from burning out!

The LED in a 4N25 works at about 1.3-1.5V. 10mA should be plenty of current to trigger the output, so you'd need something like a (3.3-1.5)/0.01 = 180 Ohm resistor between each GPIO and Anode.

Yes, it is the collector/emitter that may require trial and error.
Thanks again very much for the advice. I will keep you updated. If rpdom sees a large pall of smoke over Essex, he'll know it didn't work.
Eep!

Candyjet
Posts: 56
Joined: Sun Jan 10, 2016 3:45 pm

Re: Best SSR kit

Thu Mar 10, 2016 4:18 pm

Brilliant thanks. So that I can understand more, is the 1.3 -1.5V quoted, the 'forward voltage' on the datasheet, and the 10mA, the 'DC current transfer ratio'?

(Listen to him, 24 hrs ago, he'd never heard of an optocoupler).

Cheers,

CJ

User avatar
rpdom
Posts: 16390
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: Best SSR kit

Thu Mar 10, 2016 4:40 pm

Yes, that's the forward voltage.

For the current it does say further up about max current being 50mA, but that would be the amount to ensure that the coupler is on fully for it's max current. Also, yes, the Current Transfer ratio. 10mA on the LED will be enough to get sufficient current through the output stage to trigger that device.

Candyjet
Posts: 56
Joined: Sun Jan 10, 2016 3:45 pm

Re: Best SSR kit

Fri Mar 11, 2016 4:38 pm

rpdom and grahamed, my grateful thanks. After a bit of fiddling, the controller is working perfectly, using a 4N25 optocoupler.

For the benefit of anyone else trying this, I have added a photo, showing one optocoupler wired up to my controller.
This is what I have found out.
It is not obvious from the datasheet of the 4N25 which way round it goes.

I found out by trial and error that, holding the 4N25 with the writing the correct way up, the top row, L to R, is Base, Collector, Emitter. My device is using the orange and yellow wires, connected to C and E. As my colleagues said, it is a 50/50 guess which way round these go. Don't forget this fact, if it doesn't work first time.

The bottom row is then Anode, Cathode and erm, NC. I have connected GPIO pin 17 using a red wire through a resistor to the anode, cathode to ground on the Pi (black wire) and that's it.

Working perfectly.
Thanks again, rpdom and grahamed. Brilliant help.

:D
Attachments
Optocoupler.JPG
Optocoupler.JPG (47.6 KiB) Viewed 2485 times

Return to “Automation, sensing and robotics”