ESP32 Reset with Relay and Solenoid - Diode Selection Sanity Check!

I have an ESP32-S3 N16R8 that I have hooked up to a relay board (4way 5v) that triggers a 12V pneumatic solenoid valve (PC601, DC 12V). When everything is hooked up, the triggering of the solenoid valve causes the ESP32 to crash.

I did a little bit of research and it appears that with an inductive load, you need to add a Snubber / Flyback Diode across the solenoid terminals. It appears that the solenoid is 4.8W @ 12v so about 0.4amp. I think that pretty much any 1N400x diode will do since the lowest rated 1N400x diode is 1A 50V. I am planning on ordering this kit from Amazon so that I have some "in stock".

Does any 1N400x sound about right for this application?

Is there anything else that I would need?

Below is a rough drawing I made of my circuit. Note that the relay is wired with the JD-VCC / VCC jumper installed.

Reverse the diode , the Cathode should go to the +ve and the anode to ground :blush:

3 Likes
1 Like