I am making a custom PCB for an ESP32-S2 chip and the LDO controller is returning me 1.88 V instead of 3 V. Of course this is not enough for the ESP, but no matter what I do I can't get it to work.
At first it was returning something around 1.15 V, I guessed it was a bad solder connection, so I warmed up the regulator and MOSFET and now I get that 1.88 V on USB, and even less over the battery.
The LDO is more or less taken from TinyPico and theoretically should work, so I wonder what I could have done wrong.
I measured with a multimeter a few places around the regulator and for some reason the MOSFET appears about 1.2 V less than the USB and the regulator reduces that from about 3.8 V to 1.88 V.
Regulator: ncp170amx300
MOSFET: lp0404n3t5g
Diode: bat60jfilm