Skip to main content
ANX OS reads a config.json file from the root of the device’s LittleFS flash file system at boot time. Every configurable aspect of the firmware — network credentials, BLE identity, power behavior, and OTA preferences — lives in this single file. You can write or update config.json using the ANX CLI either by pushing a complete file, reading back the current state, or setting individual keys without touching the rest of the configuration.

config.json Structure

Below is a complete config.json showing every supported section and a representative value for each field. All sections are optional; omitted sections fall back to their factory defaults.
config.json

Configuration Reference

The device section controls how the module identifies itself and how verbose its log output is.Example:
The wifi section configures how ANX OS connects to or hosts a wireless network. Wi-Fi must be configured here before OTA updates or any network-dependent SDK calls will work.Example — joining a home network:
Example — hosting an access point:
The ble section controls the Bluetooth 5.0 stack. BLE and Wi-Fi can operate simultaneously without additional configuration.Example:
The power section lets you trade off between compute performance and battery life. All modes are fully compatible with both Wi-Fi and BLE.Example — battery-powered sensor:
The ota section controls which firmware release channel the device tracks and whether it checks for updates automatically in the background.Example — stable channel, daily check:

Writing Config to Your Device

Push a local config.json file to the device’s flash file system with the anx config write command:
To read back the configuration currently stored on the device:
The CLI prints the live config.json content to stdout, which you can redirect to a local file for editing:

Setting Individual Values

You can update a single configuration field without editing or re-uploading the entire file using dot-notation keys:
This is useful for quickly rotating credentials or toggling a flag during development without replacing the whole configuration. Chain multiple set calls to update several fields at once:
Configuration changes written via anx config write or anx config set take effect on the next reboot. Apply them immediately by running anx device reboot after making your changes.