PCB issue while breadboard was working ESP32 & relay

Hi All,
I have designed my first PCB based on my functioning breadboard to run a relay with an ESP32.
ESP32 successfully send the signal to the GPIO when not in socket however when in the socket on PCB I get no signal.

Another very odd thing that happens is, when I remove the ESP32 from the socket on the PCB, relay start to click on multiple times which happens twice typically.

I have attached the wiring , PCB and Gerber files.

Can anyone tell me what could be wrong as I check everything looks fine...but I'm no expert..

THANKSSS

Gerber_PCB_ESP Pump Controller_R.7 - 26.10.22 MOFSET_2022-12-12.zip (19.2 KB)

PCB_PCB_ESP Pump Controller_R.7 - 26.10.22 MOFSET_2022-12-12.pdf (17.6 KB)
Schematic_ESP Pump Controller_R.7 - 26.10.22 MOFSET_2022-12-12.pdf (66.3 KB)

I'v gotta say I hate schematics that actually have ZERO connections shown... they just have labels and you have to try and figure out what is connected to what.

Anyway...

Looks like GPIO12 (presume this is the correct pin... your code would help) is connected to the 3rd pin of the header... and I assume this is the pin that drives the MOSFET that turns the relay on...

But... in the "circuit" layout diagram the MOSFET is connected to pin 2 of the header?

And the Gerber files also don't look like anything is connected to pin 3?
image

image

Traces are very thin. If you can use 0,024 inch ore more. Don't use a autorouter.

The trace to the square pad in Q1 and on the header are not the normal way.

An 2 layer PCB costs equal as a 1 layer. It makes the routing much easier.

Thanks Red Car. I will improve :slight_smile:
Thanks for the response. Although the schematics is confusing the PCB connection matches the esp 32 pin, as the ESP32 GPIO 2 is on the pin 4 ( DEVKIT1) which matches the PCB.
So that part to me seems okay. when I follow the path all seem alright apart from the Diodes which looks not exactly connecting between those pins

However, I had a connecting GND that goes to VP pin of ESP32, i.e second top left from the image below.
Although I have disconnected that line on PCB by scrapping it off, the issue still persists.

probably the auto router has messed it up. Will do the next properly..
It's 2 layer though.

Autorouter are mostly very bad. They try to connect al the points end case closed. Is that the best way are not, isn't a difference for the autorouter.

All seems good with schematics and PCB is correct on itself. 0.2 mm traces are totally fine for signals and ok up to ~0.5A currents. Lack of ground polygon is inexcusable for a PCB - this way it's as bad as a breadboard in terms of forward/return current paths, but since you are switching it at low frequency - it shouldn't have caused problems.

I suggest either soldering failed at some point, or maybe mosfet is put in a wrong way (or it's a different part so pins don't match), or this particular mosfet has too high threshold voltage - according to datasheet, it can be as high as 4.0V, and I assume in a large part it depends on random factors, so when you drive it with 3.3V from ESP, one mosfet may work, another won't. The best solution would be to use a mosfet with lower Vgs threshold

1 Like

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