Troubleshooting¶
Sensors Not Detected¶
Symptoms: Dashboard shows -- for all values. Serial log shows init failed.
- Check I2C wiring — SDA/SCL can't be swapped
- Confirm 3.3V on sensor VCC (not 5V)
- Run an I2C scanner sketch to verify addresses
- Check
i2cSDAandi2cSCLin config match your wiring
WiFi Won't Connect¶
- Confirm the SSID is 2.4 GHz — ESP32 doesn't support 5 GHz
- Check password (case-sensitive)
- Move the device closer to the router for initial setup
- If captive portal never appears, do a full erase and re-flash
Web UI Not Loading¶
ERR_CONNECTION_REFUSED or blank page:
- Verify the filesystem was flashed —
pio run --target uploadfs - Check serial logs for
LittleFS mount failed - Re-upload the filesystem:
pio run --target uploadfs - If still broken, full erase and re-flash
OTA Update Fails¶
- Ensure stable power — don't run on a weak USB charger during flash
- Check WiFi signal strength (RSSI better than -75 dBm)
- Verify the
.binfile is the right type (firmware, notcomplete-flashorlittlefs) - Don't navigate away from the update page during upload
If the device stops responding after a failed OTA, it should fall back to the previous app slot on next boot. If it doesn't, reflash via USB.
"Could not activate partition" after an upload usually means the transfer was corrupted on a weak link - upload again.
N.I.N.A. Can't See the Device¶
- Settings → Safety → ASCOM Alpaca must be on.
- Discovery is a UDP broadcast, which doesn't cross subnets or VLANs. If N.I.N.A.'s PC is on another network, add the device manually: its IP, port
80. - After updating from a release before v0.2.0, re-select the devices in N.I.N.A. once - their unique IDs now include the MAC address.
- Test from the PC:
curl http://<device-ip>/management/v1/configureddevicesshould list both devices.
An Alert Didn't Arrive (or One Did That Shouldn't Have)¶
Open History on the dashboard's Safety card. It lists safety changes, restarts (and why) and every safe/unsafe alert actually sent, and survives restarts. Common reasons for no alert:
- Alerts are switched off (the bell in the header is crossed out) or Send alerts is off
- It isn't dark yet and Safety alerts only when it's dark is on
- The device restarted - start-up and the safe delay aren't announced, see Alerts
- The cooldown held it back; it's sent when the cooldown ends if things haven't changed back
- The channel failed - the bell's list shows each channel's result, e.g. Pushover "user identifier is not a valid user" means the user key (not the app token) is wrong
Web UI Slow With Bluetooth On¶
WiFi and Bluetooth share one radio. Expect slower page loads with Bluetooth on; turn it off in Settings → Device if you don't use the phone alarm.
MQTT Not Publishing¶
- Check
mqtt.enabledistruein config - Ping the broker from another device to confirm it's reachable
- Verify broker address and port
- Check username/password if your broker requires auth
- Watch broker logs:
mosquitto_sub -h broker -t "#" -v
Serial Monitor Garbled¶
Baud rate must be 115200. In PlatformIO:
Resetting Everything¶
Nuclear option — clears firmware, filesystem, and NVS (WiFi config, all settings):
Then re-flash from the release sqmeter-complete-flash-*.bin.