Safe Mode
Safe mode starts ESPGeiger with only the core parts running: WiFi, the web pages, settings, firmware update and the serial console. It is there so a device that keeps crashing can still be reached and fixed. On HV builds the HV pin is held low, so the high voltage stays off.
When it starts
- After 3 crashes in a row, each before the device has run for 10 minutes. A crash here is an exception or a watchdog reset. A brownout, from a poor power supply, doesn’t count (see Troubleshooting).
- On request, with the
safecommand over serial, or by opening/guard?enter=1. The device restarts into safe mode.
Installing a new firmware clears the crash count.
What it does
- Counting stops. No uploads, MQTT, display, sounds or other outputs.
- HV stays off on HV builds.
- The home page shows SAFE MODE, why it started, and how long until it tries normal mode again. An OLED shows Safe mode when it first starts.
- The Config, Network Config, Info and Update pages still work. Config shows every setting, so a recent change can be undone. On ESPGeiger-HW and the
_hvbuilds the HV settings are the exception:/hvis off in safe mode, so undo them withset espghw.duty <n>orreset espghwover serial. /infoshows the latest crash, worth including in a bug report.- The Status and History pages aren’t there, nor is the command box on the Status page or
/json. Use the serial console:set,get,reset,rebootand the other built-in commands work, the rest answeroff in safe mode. ESPGeiger Log builds read no serial commands. /outputslists each stopped module as{"quarantined":true}.- A short hold of the push button at boot does nothing, so no offline mode. A hold of 5 seconds or more still does a factory reset.
Getting out
- Wait. The device restarts and tries normal mode after 30 minutes. If it ends up back in safe mode the wait doubles each time, up to 16 hours, and goes back to 30 minutes once the device has run for a day.
- Restart it: the restart now link on the home page, the
rebootcommand, or a power cycle. The next boot is normal. The device’s own restarts, for a lost WiFi network or a setup portal that timed out, stay in safe mode. - Install a different firmware from the Update page. On HV builds, tick Another build (an older firmware) to install another build’s bin.
After safe mode, one crash in the first 10 minutes takes it straight back.