How to control a solenoid valve? (Unusual Solenoid)

I have a solenoid valve which isn't like the usual solenoid valve when it gets power, it is on and when it does not get power, it is off. Take a look:


How can I exactly control it? I have diodes, transistors, 5V relays. What will I have to use?

Hi,
Please post a link to data/specs of your solenoid valve.

I would say you have a garden solenoid valve that is designed for automated, low power control.
The solenoid toggles on and off with each power application.

You apply power to change it, no power and it stays where it is set.
That is what your diagram is inferring.

Tom.. :smiley: :+1: :coffee: :australia:

The solenoid valve has been taken outside an automatic watering system (You may remember me from my previous topics but anyway). That's correct that's what my diagram is inferring.

I think the easiest way to control it would be using two relays, one DPDTto reverse the polarity and one SPST to turn power on/off

2 Likes

Oh. Yeah that might work. Will a 9V battery work with my 5V relay modules (I also have 2 12V relay modules)?

Do you have a data sheet for the 5V relays?
If the solenoid is actually 12V, you could use the 12V relays and supply everything with 12V rather than 9V

1 Like

Is is a 9V solenoid valve. To make the device smaller, will transistors work? I have a TIP120 transistor. (These are generic Chinese relays, I can't find them). And I will use a 9V battery (Alkanine).

As I said, my recommendation is to use two relays, 5V or 12V doesn't matter.
If it's 5V, then you will need a 5V supply if it's 12V, then you will need a 12V supply.

It works as intended with my 5V relay modules. But because I want to use one relay module for another project, can I do the same thing by using TIP120 transistors? If so, how I will do it?

No, it's not that easy. But there exist ready made H-bridge modules which can control the solenoid. For the selection you have to know the voltage (9V) and switching current (???) of the solenoid.

Drop that dinosaur and look for low side switching logic level N channel MOSFET transistor.

Trying to build your own H bridge without a good skillset is an easy way to start a fire. I'd recommend just getting something like this. Others might have better solutions.

Because I have to order these things from other countries and I don't wanna wait (I ordered stuff for my project twice) I will just use 2 5V relay modules (It works so why not :slight_smile: )

Because it's a fire hazard

Are they DPDT relays? Or at least one of them?

What? Really? (These relays with an ESP32 will be placed into a box IP54). It generates heat?

Because you didn't give a diagram and if you're using STDP relays and activate them both at once, you'll create a short circuit and probably some fire.

1 Like

No (I don't even know what an STDP relay is I'm new to electronics :frowning:) it will be used in a IoT automatic watering system so it will not activate the relays both at once. If that's the case, would this solution be good?

Which is fine. I'd ask that you try to fully understand what we're recommending and why before you suggest otherwise though. Unless you have a properly setup H bridge driver (please read up on them) with short circuit protection, you're putting yourself in danger.

I just don't wanna wait 1 month to just get these H bridge drivers. Thank you for helping me :slight_smile:

As @jim-p stated, use two relays of the types he suggested which is effectively the same thing. If you don't know what they are, Google them and come back with questions. An auto parts store should carry those types of relays if you can't order them.

1 Like