0
\$\begingroup\$

schematic

simulate this circuit – Schematic created using CircuitLab

My project requires switching a 4 ohm solenoid at 24v for 200ms to turn on a water supply and then -24v to turn it off. Previously I used relays and an Arduino R3 but the next version is using an esp32 which won't trigger the relays so I am planning to use MOSFETS (which are new to me) so I'd like to ask if I'm making the right choices of parameters.

This is what I think I need... VGS(TH) max < 3v VDS 130% x 24v, approx 40v ID 150% x 6A, approx 10A

Am I on the right track? Do I need to be mindful of VGS(max). Am I missing anything? Any advice gratefully received.

EDIT. Please excuse the hastily drawn schematic - hope it helps. As I said, I'm trying to get my head around using MOSFETS instead of relays. The idea is that when PIN1 is LOW, PIN4 is also LOW and PINs 2 & 3 are HIGH and that when PIN1 is HIGH, PIN4 is HIGH and PINs 2 & 3 are LOW causing the current to flow through the valve in the other direction

I'm using a valve from an old Orbis watering system - the controller died but I'm left with servicable valves. Applying 24v triggers the solenoid which latches the valve open, reversing the polarity triggers it closed. I'm looking at a BSS123 but was concerned that the VGS(max) says +/- 20V

\$\endgroup\$
6
  • \$\begingroup\$ I'm confused about your +24 to turn on and -24V to turn off. Perhaps some details about the specific solenoid and MOSFET you are considering would be helpful. \$\endgroup\$
    – jwh20
    Jun 28, 2021 at 13:42
  • \$\begingroup\$ Please give us a schematic showing how you intend to use MOSFET(s) to switch the positive and negative voltages. \$\endgroup\$ Jun 28, 2021 at 14:45
  • \$\begingroup\$ Thank you for replying. I'm using a valve from an old Orbis watering system - the controller died but I'm left with servicable valves. Applying 24v triggers the solenoid which latches the valve open, reversing the polarity triggers it closed. I'm looking at a BSS123 but was concerned that the VGS(max) says +/- 20V \$\endgroup\$ Jun 28, 2021 at 14:45
  • 2
    \$\begingroup\$ You should be able to use the same relays you used with the Arduino. If the ESP32 can't drive the relays directly, you would use a single transistor to drive each relay. (you probably should have used transistors to drive the relays even with the Arduino.) \$\endgroup\$ Jun 28, 2021 at 16:04
  • 1
    \$\begingroup\$ Are you not allowed to keep the relays you had in the previous version? If the ESP can't drive the relay coils, you could use logic-level MOSFETS to drive the relays. Although the overall circuit will be more complex, the MOSFET drive will be simpler. \$\endgroup\$
    – Theodore
    Jun 28, 2021 at 16:15

2 Answers 2

3
\$\begingroup\$

No, this won't work because you won't be able to apply a high enough gate voltage to turn off the high-side P MOSFETs. You need to bring these gates to 24 V to turn them off.

You should be looking for something called an "H-bridge". You should be able find one device that contains all of the logic you need, and works with your desired voltages. Please don't ask us to recommend a specific part number; that's against site policy.

\$\endgroup\$
1
  • \$\begingroup\$ Many thanks for your help. Much appreciated \$\endgroup\$ Jun 28, 2021 at 16:55
1
\$\begingroup\$

It would be wise to use optocouplers in order to obtain galvanic isolation, so your senstive electronics (ESP32) don't get destroyed in case of some surge current.

If you plan to use MOSFETs as a switch, is it wise to use gate drivers like TC4424 since MCU's current output might not be enough to drive certain loads with a MOSFET.

This guy (GreatScott) has some great educational videos about the topic. I've learnt a lot from him. https://www.youtube.com/watch?v=8swJ_Bnsgl4&ab_channel=GreatScott%21

Also don't forget to add a flyback diode to the solenoid valve to prevent/protect against current spikes.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.