terodox
Posts: 9
Joined: Fri Mar 14, 2014 4:22 pm

Driving a DC to DC SSR for Solenoid Valve-Voltage leak issue

Fri Mar 14, 2014 4:32 pm

Hello All!

I'm fairly new to Raspberry Pi, but I'm a fairly old hat at electronics. Here's what I'm doing:

I have a kegerator with 4 taps. I also have two young children (one of whom just figured out how to open the taps). My basic plan is to have 4 solenoid valves that will prevent beer flowing unless an appropriate password is entered via a website hosted on my pi.

I have everything working to enable the gpio pin and automatically disable it after 2 minutes. The issue I'm having now is on the other side of this circuit. The SSR I'm using ( http://www.amazon.com/gp/product/B009EQG1UY ) is allowing some voltage (2.3-2.5 v ish) to leak through even when the SSR is not powered from the input side.

My concern is for the health of the solenoid valve if it being given a trickle of power over a long period of time. Is there a way to draw down this voltage before it reaches my valves? Should I not be using this tpye of SSR? Is there a better solution to this whole problem that I've simply overlooked?

Any and all help/advice would be wonderful.

Thanks in advance!

danjperron
Posts: 3402
Joined: Thu Dec 27, 2012 4:05 am
Location: Québec, Canada

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Fri Mar 14, 2014 11:15 pm

Hi the SSR has some leakage current and it is normal.

This current is needed to feed the electronic control of the solid state relay.

So 2VAC on 110VAC/220VAC doesn't have a big impact. Selenoid valve are only coil.
With this little leakage voltage , they won't heat than they won't be affected.

Daniel

terodox
Posts: 9
Joined: Fri Mar 14, 2014 4:22 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Fri Mar 14, 2014 11:26 pm

Hey Daniel!

Thanks for the reply! The SSR I'm using is actually DC to DC. It's being powered by the 3.3V off the gpio port and the output side has a 12v DC power supply running across it.

That being said the 2.5V is now 20% of it's fully loaded voltage. If it were 1% as in the AC example you mentioned I would be much less concerned.

Thoughts?

User avatar
iinnovations
Posts: 621
Joined: Thu Jun 06, 2013 5:17 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Fri Mar 14, 2014 11:33 pm

I would guess that your input is floating. Have you checked the voltage on it when the GPIO is off? Typically you would use a pull-down resistor on the relay in put to ensure that it is at 0V and not floating when you are not enabling the GPIO.

Are you switching low side or high-side on your relay, i.e. is your solenoid between the PS and relay or between the relay and ground?

Colin
CuPID Controls :: Open Source browser-based sensor and device control
interfaceinnovations.org/cupidcontrols.html
cupidcontrols.com

danjperron
Posts: 3402
Joined: Thu Dec 27, 2012 4:05 am
Location: Québec, Canada

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Fri Mar 14, 2014 11:39 pm

Do you have the model number of your SSR relay.

terodox
Posts: 9
Joined: Fri Mar 14, 2014 4:22 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Fri Mar 14, 2014 11:43 pm

Hey Colin,

This was was without any wiring hooked up to the input side of the SSR. I have it wired on the + side of the solenoid circuit. I run directly from the power source positive, to the solenoid. I haven't hooked up any of the solenoid valves yet. This was purely with a multimeter.

Daniel,
ASIN: B009EQG1UY
http://www.amazon.com/gp/product/B009EQG1UY

User avatar
iinnovations
Posts: 621
Joined: Thu Jun 06, 2013 5:17 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Fri Mar 14, 2014 11:49 pm

I'm not quite clear on what is connected and being measured.

Let's call the side of the relay that you connect your Pi to the input/control side, and the part you use to power your solenoid the output side. The high and low you can call +/- or high/low.

Your plan is to connect the solenoid like this, correct: http://www.raspberrypi.org/forum/viewto ... id#p517897

See the diagram. Let me know what is connected where. If your input is not connected, pull it down to ground for testing leakage.

Colin
CuPID Controls :: Open Source browser-based sensor and device control
interfaceinnovations.org/cupidcontrols.html
cupidcontrols.com

terodox
Posts: 9
Joined: Fri Mar 14, 2014 4:22 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Fri Mar 14, 2014 11:55 pm

The SSR has an input side which is going to be power using the pi. I haven't hooked anything up to it yet (by the sounds of your post I should hook it up and try this again, which I will do as soon as I post this).

I have the high side of my power supply wired to the SSR. When I use a multimeter from the high side to low, I get the expected 12v. When I go to what should be the unpowered high side of the SSR to the low I am still ready approx. 2.5V

I hope this helps to clarify things.

terodox
Posts: 9
Joined: Fri Mar 14, 2014 4:22 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 12:12 am

I hooked up the pi. The situation hasn't changed with the pi in place.

If I send the gpio pin high the SSR acs accordingly and send the full 12V across, however if the gpio pin is low, there is still that residual 2.5V leaking across.

terodox
Posts: 9
Joined: Fri Mar 14, 2014 4:22 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 12:17 am

Image
View it larger here: https://lh3.googleusercontent.com/-L_CK ... 200624.jpg

A quick image of how it's all hooked up. The lower side of the SSR in this picture is the + side.

techpaul
Posts: 1512
Joined: Sat Jul 14, 2012 6:40 pm
Location: Reading, UK
Contact: Website

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 12:28 am

There appears to be things missing in photo.

Can you post a simple circuit diagram of what you ar doing and manufacturers part number of SSR or datasheet link.
Just another techie on the net - For GPIO boards see http:///www.facebook.com/pcservicesreading
or http://www.pcserviceselectronics.co.uk/pi/

danjperron
Posts: 3402
Joined: Thu Dec 27, 2012 4:05 am
Location: Québec, Canada

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 12:34 am

Do you really need 25A ?

Most of those valves are less than 20W

What is your valve power. I think your SSR is overrated for it and this is why the leakage current is high.

Maybe an opto22 DC60S3 with a leakage current of 1 ma.

http://www.opto22.com/documents/0859_So ... _sheet.pdf

Daniel

terodox
Posts: 9
Joined: Fri Mar 14, 2014 4:22 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 12:37 am

Hmmmmm,......

You're very right that this is WAY overrated for what I'm going to push through it. I'm going to be pushing 4 valves at 500mA each so i really only need 2 amps, maybe three for some wiggle room.

I'll check out the opto22 tonight.

As for part number/datasheet, what you see on amazon is what I have to go with unfortunately. It looks like this thing will be headed back to amazon in short order.

User avatar
iinnovations
Posts: 621
Joined: Thu Jun 06, 2013 5:17 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 12:43 am

You can't judge this until you connect the low side. It may float up if it is not grounded. Connect the thing as intended with an ammeter and measure once and for all.

For 2A, however, I would definitely consider a MOSFET instead, as in the post I linked. You could even use four FETs for a couple bucks and separate your solenoids.

Colin
CuPID Controls :: Open Source browser-based sensor and device control
interfaceinnovations.org/cupidcontrols.html
cupidcontrols.com

danjperron
Posts: 3402
Joined: Thu Dec 27, 2012 4:05 am
Location: Québec, Canada

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 12:50 am

By definition SSR relay are opto isolated so nothing plug = no current on led in the opto then no output.

And it is a good thing to have an opto-coupler when you have coil and water around.
This is the best way to isolate the Pi.

Daniel

terodox
Posts: 9
Joined: Fri Mar 14, 2014 4:22 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 12:56 am

opts22 DC60S3 ordered.

http://www.amazon.com/gp/product/B0058U ... refresh_T1

Go go prime! I don't mind waiting a few weeks.

Thanks to everyone who replied, I appreciate all the input and advice!

danjperron
Posts: 3402
Joined: Thu Dec 27, 2012 4:05 am
Location: Québec, Canada

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 1:10 am

Don't forget to put a diode like 1n4004 to kill the inductive spike when you will cut the power.
check the pdf page 11.

Daniel

User avatar
iinnovations
Posts: 621
Joined: Thu Jun 06, 2013 5:17 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 2:19 am

Did you connect the low side of the PS and output before measuring? If not, the measurement doesn't mean much.

It seems pretty crazy to me to spend $30 for what a couple bucks and a bjt or mosfet can do. A mosfet won't allow you to pass current from the GPIO, and I don't think the difference between a mosfet and and optoisolator should be the difference between toasting your Pi if there is water involved.
CuPID Controls :: Open Source browser-based sensor and device control
interfaceinnovations.org/cupidcontrols.html
cupidcontrols.com

danjperron
Posts: 3402
Joined: Thu Dec 27, 2012 4:05 am
Location: Québec, Canada

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 3:09 am

This all depends are good you are with electronic and solder iron.

If you have to do more than 25 units. Maybe it is worth while to build a small pcb to hold the power mosfet or driver i.c.
since the cost of building the pcb will be split.

For a single unit , time spend to build a veroboard or any mounting adapter will cost more than using this simple DC60S-3.
Don't forget to calculate your time.

Also I don't think a veroboard will look professional anyway.

The DC60S-3 could be mount easily and you just need to tight the wires with a screw.

The biggest thing about it is "No electronic skill needed".

The other approach will be to use some available L298/293 board . like this one

http://dx.com/p/l298n-stepper-motor-dri ... yO-V1F5NKE

Cheaper ,more output, but less robust. You need some spacer to mount it. Input wires need to be solder on a single line header, etc.

Like my boss said.
If you are doing one of a kind , part cost is not an issue since time spend will be around 10X the cost. ( up to certain degree)
But if you make thousand of them be sure that each washer is needed and where could you remove a screw.


Daniel

Tarcas
Posts: 740
Joined: Thu Jan 09, 2014 5:38 am
Location: USA

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 3:54 am

If it was me, I'd just buy a $5 4-relay board from Ebay (You can go with a 2-relay board, but they're really not much cheaper, and don't have separated VCC and JD-VCC.) No current leakage through one of those boards. I don't imagine the audible click would be a problem for your application, and it would be an audible notification that the code was accepted, and a reminder after the 2 minute timeout that it's been successfully shut back off (if you can hear it at all.) Plus the relay boards have optical isolation, so that concern is already covered as well.
Is there a reason that the SSR would be preferable in this application? (Not a rhetorical question. I'd really like to know, if there is a reason.)

danjperron
Posts: 3402
Joined: Thu Dec 27, 2012 4:05 am
Location: Québec, Canada

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 5:26 am

When you put a SSR you could forget about it. (unless the output short).
They don't make noise. (unless you are using AC and the valve start to vibrate)

Relay wear out faster since they are mechanical.

They have faster response. on industrial level they are able to operate in ms range.

I did a PLC control on a paint chop, The omron relay didn't last more than 3 month. I change them for SSR. They were all operational after 10 years of usage.

Tarcas
Posts: 740
Joined: Thu Jan 09, 2014 5:38 am
Location: USA

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 6:41 am

danjperron wrote:When you put a SSR you could forget about it. (unless the output short).
They don't make noise. (unless you are using AC and the valve start to vibrate)
I know, but that doesn't seem like an issue for this project. A click when you enter your code and another 2 minutes later doesn't seem like it would be a problem, although this is of course subjective.
Relay wear out faster since they are mechanical.
Again, doesn't seem like an issue on this project. One 2-minute cycle when you want to pour a beer? Doesn't sound like it's going to get a lot of use. Unless this bar gets a whole lot of traffic, or the life cycle is far lower than I suspect it is, the life expectancy of the relay is probably significantly longer than that of the kegerator. (My estimates: 10,000 cycles / 2 cycles/day (average) = 5000 days = 13.7 years. By this time his young children won't be young children anymore, the kegerator will have likely given out, the Raspberry Pi will be ancient, and statistically there's a good chance that he's sold his house and moved once or twice. I don't remember where I saw the 10,000 cycle number, but I found a PDF that mentioned a 100,000 cycle life expectancy, which would multiply all those numbers by 10, giving the relay a longer life expectancy than not only the kegerator and the OP, but his young children and possibly his unborn grandchildren as well.) So... I'm going to go with... nonissue.
They have faster response. on industrial level they are able to operate in ms range.
Definitely not an issue here. It's responding to human input, not precision computer controls.
I did a PLC control on a paint chop, The omron relay didn't last more than 3 month. I change them for SSR. They were all operational after 10 years of usage.
Not sure what a paint chop is, but I suspect that it puts a relay through a whole lot more cycles than a kegerator could. The PDF I cited above with the 100,000 cycle life expectancy contains a theoretical case study of a commercial oven with a relay switching the burners on and off several times per minute, which adds up to over 600,000 cycles per year, translating to a 2 month life expectancy. This leads me to believe that your paint chop has a similar usage pattern, as it matches the theoretical life expectancy of the theoretical oven. If he's pouring that many beers in his home bar, I suggest he update his insurance and put the hospital on speed dial, because someone will have alcohol poisoning WAY before a relay would burn out. He would also be going through roughly one keg every hour, and this is even forgetting the fact that the relay remains open for two minutes, not just one pour.

I was asking about the benefits of a $30 SSR compared to a $5 relay board for this particular project, not in general. I know SSR has definite benefits for many applications, and is in fact the only realistic choice for many purposes. I just don't see the benefits for this particular project. Unless of course the OP is opposed to a confirmation click when the code is successfully entered and again when the childproof safety valve closes, which would be his prerogative.

johndough
Posts: 254
Joined: Sun Jan 13, 2013 2:00 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 8:20 am

[quote=
I did a PLC control on a paint chop, The omron relay didn't last more than 3 month. I change them for SSR. They were all operational after 10 years of usage.[/quote]

Hi

Mechanical Relays etc. I used to build control panels, and the guarantee was for 1 year or 100,00 cycles on an industrial door. Usually the year came up first, but not always.

danjperron
Posts: 3402
Joined: Thu Dec 27, 2012 4:05 am
Location: Québec, Canada

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 12:39 pm

In reality there is always a cheaper way to do stuff . But you need to consider that ssr relay are dum simple to put. Two screw to attach and and only 4 wires to hook up.

Granted it is not cheap but it is so easy .

Just the time we take to chat about this and it is already paid.

Daniel

terodox
Posts: 9
Joined: Fri Mar 14, 2014 4:22 pm

Re: Driving a DC to DC SSR for Solenoid Valve-Voltage leak i

Sat Mar 15, 2014 12:44 pm

For my two cents, I wanted the simplest circuit design. A little extra cost is worth it to me to have very few parts to troubleshoot in the future. This kegerator has been around for years and will be around for a long time to come. Troubleshooting components needs to be easy and quick.

Having two children tends to limit free time!

Return to “Automation, sensing and robotics”