It’s time to get my train controller right. Starting with the PSU.
The power feed for a model train is the rail track that on some old systems can be AC, but mostly is 12V DC. To cover both these i use a classic rectifier MB6S. This will allow the 12V to be connected any way we please.
The next step is a bit trickier because I need 3.3V. This is easy using SPX3819 that comes in SO23-5 format and cover 16V with 500mA out. Just make sure you use a 3.3V Version.
The tricky part is that we will lose power as the train move over track gaps. Some old model trains had weights to give the train mechanical energy, but I am adding a 0.33F supercap on the 3.3V. These are small and aand using a small JST micro Connector we can hide this somewhere on the Train. The supercap will not drive the model train, but it will keep the ESP32 alive about 0,5 sec while the PSU have a glitch in Power. Without this the ESP32 will stop while it reboots and reconnect on Wifi.