ESP32 stops working when i plug any device into the power strip

Hi Everyone. I am new to these dev boards. I have an esp32 that I am using as a timer for my aquarium lights and it is connected to wifi so I can turn on the lights from any device. it is powered through the mains with 220v to 5v converter connected to a power strip.


Lately, I realized that whenever I plug anything into the power strip socket like a laptop charger, the board loses the wifi connection and doesn't work properly unless it is physically reset by pressing the reset button.

I do see sparks while plugging in the charger. maybe that is causing some issues? I am not sure.

Can anyone help me fix this?

Thank you.

Where do you see the sparks ?

It sparks at the contact where the charger plugs into the socket on the power strip.

Only with an adequately lit and detailed photo of the whole of your construction might the problem be evident.

In general, one approach would be to provide a separate extension lead for your ESP's mains converter back to a wall socket.

I have this power strip/extension board (dont know which is the right term) connected to the only outlet in my room. The 3 plugs on the top left are switched through the relay. The rest are always on.

The wires from 220 to 5v converter for ESP32 is soldered to the right bottom 3 pin plug.

When ever i plug anything on the empty plugs that is highlited in red, it sparks at the plug and then the ESP disconnects from wifi and the timer program also stops working.

Thanks in advance for the help.:relaxed:

Hi,

If the ESP is not plugged in, does the other plug still spark?
What is the other plug supplying current to?

Thanks.. Tom.. :grinning: :+1: :coffee: :australia:

Yes, the plugs on the board always used to spark. Even before i bought the ESP32. Plugs on the right side of the board are free. I use them to charge my phone/ laptop.

Ok, let's be clear about something.
ANYTHING PLUGGED INTO A POWER STRIP WHILE TURNED ON WILL ALWAYS SPARK
when the plug contacts get near the receptacle because the electrons jump the gap
when it gets small enough , resulting in small arcs at the contact point. This has always
been the case. The only time it will not occur is when the power strip is OFF or the
device being plugged in is switched off. The current transferred through the arc is
proportional to the distance of the gap, increasing as the distance decreases.

Can the sparking cause issues to the operation of ESP32?
I noticed that once the sparking occurs and I connect the esp32 to computer and turn on serial monitor, it prints random characters until I press the reset button.

Yes, that is part of the problem - it is causing surges that are being picked up by the wiring to your ESP32.

The main problem is how you have wired your ESP32 system together. Unless you reveal this - a decent photo at the very least - we will never know. :woozy_face:

Not if you did a RESET after plugging it in.
Robert




The drawing shows the connections i have done. The 5v converter is connected directly to mains and the output from that is shared by 2 relay modules and ESP32.

You could try adding a 220uf electrolytic output capacitor to the voltage converter.
see data http://www.hlktech.net/product_detail.php?ProId=54

Can i use a 470uf 10v capacitor instead?
Found this from an old phone charger.

So in that photo, I see multiple large open loops of wiring.

The components you are using - the ESP32 - operates at radio frequencies ("RF") - in fact four times the frequency of most Arduinos and more than twice the frequency of CB radio. By those open loops of wire, you are introducing "air wound" RF coupling transformers and coupling capacitors all over your layout to couple impulses from one part to another.

Any chance you have another source of 5V available, just to take the Hi-Link module out of the equation?

Your power supply is probably the culprit, I think it is dropping out when some noise hits if from its primary side. But to expand just a bit does anything else disconnect or reset when this happens like the WiFi glitching and then recovering. Sparking is normal. I would expect the size of the sparks varies and sometimes it doesn't spark. The spark is a load connecting when the AC sine wave is not at or close to zero.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.