Skip to content

Troubleshooting a device that has not checked in

  • Token. Firmware has to check in with the device token. Both clients do that after simpleota_init() and simpleota_start() (managed mode), or via simpleota_check() (polling). You can also call the device API.
  • Rejected token. When the server rejects the token your firmware sent, both clients log server rejected the token (HTTP 401) or HTTP 403, once. That line does not say whether you flashed a project token or a device token. Copy the device's token from its Connect this device page into your firmware, keeping in mind that the page only shows it once. If you no longer have it, use Rotate token in the Authentication section of the device page, then copy the new token from Connect this device.
  • Wi-Fi. Join the network before the check (WiFi.begin on Arduino, esp_wifi_connect in the ESP-IDF example). A wrong name or password stays on "Never checked in". Both clients check as soon as they start, and after a failed check they wait the full interval (an hour by default) before the next one. On Arduino, set cfg.is_connected before simpleota_init() so each check waits for Wi-Fi. On ESP-IDF, call simpleota_start() once Wi-Fi has an IP, or set .is_connected in the config.
  • Server. Both clients default to https://simpleota.com. Set cfg.base_url before init, or call simpleota_set_server_url() only while the managed task is stopped. The URL has to be https:// with a host. Plain http:// is rejected.
  • OTA slots. A partition table with two OTA app slots is required for Arduino and for ESP-IDF. On ESP-IDF the first serial flash needs the partitions.csv and the sdkconfig.defaults lines from the ESP-IDF guide. If the build stops with "All app partitions are too small", the app is larger than its slot: use that table's 1700 KB slots, and build for size with CONFIG_COMPILER_OPTIMIZATION_SIZE=y.
  • Check-in worked. Both clients log check: no update (...) with the server's status, for example no_active_deployment before you create a deployment. Use esp_log_level_set("simpleota", ESP_LOG_DEBUG) after simpleota_init() for verbose HTTP lines.