Electrical – Interfacing coin cell back up for internal RTC of ESP32

coin-cellpowerrtcswitching

In esp wroom-32 all the VDD pins has a common connection. It includes VDD_RTC too. So in case of power failure if I switch the power between main DC source and coin cell using a mosfet, will it create any interrupt on updating the RTC time?

I haven't done any practical on this topic. I got this doubt while going through the internal connection of wroom-32. So please share if there is any proper solution.

Best Answer

A diode steering type setup is common. As long as the supply voltage is slightly higher than the battery voltage the diode will stay reverse biased. If the supply voltage drops out then the battery will take over automatically. Using a Schottky type diode can help reduce the forward voltage drop. Also, the device would have to detect the missing power supply and go into a hibernation type mode not to kill the battery too fast.

schematic

simulate this circuit – Schematic created using CircuitLab