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.
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.
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.
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.