### Application Start and Network Join Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/home_automation_devices/color_dimmer_switch/README.md Logs indicating the application start, Zigbee stack initialization, and successful network join. This is useful for verifying the initial setup and network connectivity. ```log I (404) main_task: Calling app_main() I (424) COLOR_DIMMER_SWITCH: Start ESP Zigbee Stack I (424) ESP-ZIGBEE: SDK Version: v1.6.8-fcae32885b02-94cf5061*; esp32h2; 2026-04-08 12:37:02 UTC I (424) esp zigbee sleep: light sleap disabled I (444) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (444) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (454) COLOR_DIMMER_SWITCH: Initialize Zigbee stack I (454) COLOR_DIMMER_SWITCH: Deferred driver initialization successful I (454) COLOR_DIMMER_SWITCH: Device started up in factory-reset mode I (464) main_task: Returned from app_main() I (1734) COLOR_DIMMER_SWITCH: Network(0x85ff) is open for 180 seconds I (1734) COLOR_DIMMER_SWITCH: Joined network successfully: PAN ID(0x85ff, EXT: 0x4831b7fffec183f0), Channel(13), Short Address(0x940a) ``` -------------------------------- ### Get Local Install Code Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Retrieves the install code currently configured on the local device. ```bash esp> ic get ``` -------------------------------- ### Checkout ESP-IDF Version and Install Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/developing.rst Navigate into the cloned ESP-IDF directory, checkout a specific version, initialize submodules, run the installation script, and export the environment variables. ```bash cd esp-idf git checkout v5.5.4 git submodule update --init --recursive ./install.sh source ./export.sh ``` -------------------------------- ### Application Start and Network Join Log Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/home_automation_devices/on_off_switch/README.md Logs showing the application starting, Zigbee stack initialization, and successful network join. This is useful for verifying the initial setup and connection status. ```log I (417) main_task: Calling app_main() I (427) ON_OFF_SWITCH: Start ESP Zigbee Stack I (437) esp zigbee sleep: light sleap disabled I (447) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (447) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (467) ON_OFF_SWITCH: Initialize Zigbee stack I (467) ON_OFF_SWITCH: Deferred driver initialization successful I (467) ON_OFF_SWITCH: Device started up in factory-reset mode I (477) main_task: Returned from app_main() I (1727) ON_OFF_SWITCH: Joined network successfully: PAN ID(0x3051, EXT: 0x4831b7fffec183f0), Channel(13), Short Address(0xe5e0) ``` -------------------------------- ### Install Delta OTA Requirements Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/ota_upgrade/ota_client/README.md Installs the necessary Python packages for using the HTTPS delta OTA example. Ensure you have Python and pip installed. ```bash pip install -r managed_components/espressif__esp_delta_ota/examples/https_delta_ota/tools/requirements.txt ``` -------------------------------- ### Application Start and Zigbee Stack Initialization Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/touchlink/touchlink_initiator/README.md Logs indicating the application start, Zigbee stack initialization, and device startup mode. ```c I (416) main_task: Calling app_main() I (426) TOUCHLINK_INITIATOR: Start ESP Zigbee Stack I (436) esp zigbee sleep: light sleap disabled I (446) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (446) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (466) TOUCHLINK_INITIATOR: Initialize Zigbee stack I (466) TOUCHLINK_INITIATOR: Deferred driver initialization successful I (466) TOUCHLINK_INITIATOR: Device started up in factory-reset mode I (576) main_task: Returned from app_main() ``` -------------------------------- ### Example App Output Log Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/all_device_types_app/README.md This log shows the typical output when the All Device Types App example is run, including system information and available console commands. ```log I (298) cpu_start: Unicore app I (298) cpu_start: Pro cpu up. W (307) clk: esp_perip_clk_init() has not been implemented yet I (314) cpu_start: Pro cpu start user code I (314) cpu_start: cpu freq: 96000000 Hz I (314) cpu_start: Application information: I (317) cpu_start: Project name: all_device_types_app I (324) app_version: b8aed66-dirty I (329) cpu_start: Compile time: Aug 15 2024 17:38:49 I (335) cpu_start: ELF file SHA256: d1357f7216520fbf... I (341) cpu_start: ESP-IDF: v5.1.3 I (346) cpu_start: Min chip rev: v0.0 I (351) cpu_start: Max chip rev: v0.99 I (356) cpu_start: Chip rev: v0.1 I (360) heap_init: Initializing. RAM available for dynamic allocation: I (368) heap_init: At 40813A30 len 00039950 (230 KiB): D/IRAM I (374) heap_init: At 4084D380 len 00002B60 (10 KiB): STACK/DIRAM I (382) spi_flash: detected chip: generic I (385) spi_flash: flash io: dio W (389) spi_flash: Detected size(4096k) larger than the size in the binary image header(2048k). Using the size in the binary image header. I (403) sleep: Configure to isolate all GPIO pins in sleep state I (409) sleep: Enable automatic switching of GPIO sleep configuration I (417) app_start: Starting scheduler on CPU0 I (421) main_task: Started on CPU0 I (421) main_task: Calling app_main() I (431) esp-zigbee-console: List of ESP Zigbee Console commands: I (431) esp-zigbee-console: - Command 'address' I (441) esp-zigbee-console: - Command 'bdb_comm' I (441) esp-zigbee-console: - Command 'channel' I (441) esp-zigbee-console: - Command 'dm' I (451) esp-zigbee-console: - Command 'factoryreset' I (451) esp-zigbee-console: - Command 'ic' I (461) esp-zigbee-console: - Command 'network' I (461) esp-zigbee-console: - Command 'panid' I (471) esp-zigbee-console: - Command 'radio' I (471) esp-zigbee-console: - Command 'reboot' I (481) esp-zigbee-console: - Command 'role' I (481) esp-zigbee-console: - Command 'start' I (491) esp-zigbee-console: - Command 'tl' I (491) esp-zigbee-console: - Command 'zcl' I (501) esp-zigbee-console: - Command 'zdo' I (501) esp-zigbee-console: - Command 'zgp' I (511) esp-zigbee-console: - Command 'zha' I (591) phy: phy_version: 230,2, 9aae6ea, Jan 15 2024, 11:17:12 I (591) phy: libbtbb version: 944f18e, Jan 15 2024, 11:17:25 I (591) ESP_ZB_CONSOLE_APP: Start ESP Zigbee Console Type 'help' to get the list of commands. Use UP/DOWN arrows to navigate through command history. Press TAB when typing command name to auto-complete. I (601) main_task: Returned from app_main() esp> ``` -------------------------------- ### Build and Flash Application Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/developing.rst Build and flash the selected Zigbee example application to the target device, and then monitor its output. ```bash idf.py -p PORT erase_flash flash monitor ``` -------------------------------- ### Initialize and Start Zigbee Stack Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/developing.rst This task initializes the Zigbee stack with coordinator configuration, starts the stack, and launches the main loop. It includes error checking and cleanup. ```c void esp_zigbee_main_task(void *pvParameters) { esp_zigbee_config_t config = ESP_ZIGBEE_ZC_CONFIG(); ESP_ERROR_CHECK(esp_zigbee_init(&config)); /* Do some stack configuration here. */ /* Create and register the ZCL data model. */ ESP_ERROR_CHECK(esp_zigbee_start(false)); esp_zigbee_launch_mainloop(); esp_zigbee_deinit(); vTaskDelete(NULL); } ``` -------------------------------- ### Touchlink Target Application Start Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/touchlink/touchlink_target/README.md Logs indicating the application start and Zigbee stack initialization for the Touchlink target. ```c I (425) main_task: Calling app_main() I (445) TOUCHLINK_TARGET: Start ESP Zigbee Stack I (445) esp zigbee sleep: light sleap disabled I (455) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (455) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (475) main_task: Returned from app_main() I (485) TOUCHLINK_TARGET: Initialize Zigbee stack W (485) rmt: channel resolution loss, real=10666666 I (485) TOUCHLINK_TARGET: Deferred driver initialization successful I (495) TOUCHLINK_TARGET: Device started up in factory-reset mode ``` -------------------------------- ### Start Zigbee Stack Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Initiate the Zigbee stack, bringing the device online and enabling Zigbee communication. ```bash esp> start Start Zigbee stack ``` -------------------------------- ### Set Local Install Code Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Sets the install code on the local device. ```bash esp> ic set 0x83FED3407A939723A5C639B26916D505C3B5 ``` -------------------------------- ### Application Start and Zigbee Stack Initialization Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/ota_upgrade/ota_client/README.md Logs indicate the application starting, ESP Zigbee Stack initialization, and the device joining a network. This is the initial state when the client board powers up. ```c I (424) main_task: Calling app_main() I (434) OTA_CLIENT: Start ESP Zigbee Stack I (444) esp zigbee sleep: light sleap disabled I (454) phy: phy_version: 323,2, a8ef10c, Aug1 2025, 17:46:10 I (454) phy: libbtbb version: 4515421, Aug1 2025, 17:46:22 I (464) OTA_CLIENT: Initialize Zigbee stack I (474) OTA_CLIENT: Device started up in factory-reset mode I (474) main_task: Returned from app_main() I (2554) OTA_CLIENT: Joined network successfully: PAN ID(0x1c08, EXT: 0x4831b7fffec18405), Channel(13), Short Address(0xa8d6) ``` -------------------------------- ### Application Start Log Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/home_automation_devices/on_off_light/README.md This log output shows the initial messages when the application starts, including Zigbee stack initialization, network formation, and device status. ```log I (425) main_task: Calling app_main() I (435) ON_OFF_LIGHT: Start ESP Zigbee Stack I (445) esp zigbee sleep: light sleap disabled I (455) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (455) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (475) ON_OFF_LIGHT: Initialize Zigbee stack W (475) rmt: channel resolution loss, real=10666666 I (475) ON_OFF_LIGHT: Deferred driver initialization successful I (485) ON_OFF_LIGHT: Device started up in factory-reset mode I (475) main_task: Returned from app_main() I (795) ON_OFF_LIGHT: Formed network successfully: PAN ID(0x3051, EXT: 0x4831b7fffec183f0), Channel(13), Short Address(0x0000) I (1175) ON_OFF_LIGHT: Network steering completed I (3705) ON_OFF_LIGHT: New device commissioned or rejoined (short: 0xa515) ``` -------------------------------- ### Install Python Dependencies Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/tools/mfg_tool/README.md Install necessary Python packages for the manufacturing tool. Navigate to the tool's directory and run this command. ```bash cd path/tools/mfg_tool python3 -m pip install -r requirements.txt ``` -------------------------------- ### Set Install Code Policy Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Configures the policy for using install codes during device joining. Use '2' to require install codes. ```bash esp> ic policy 2 ``` -------------------------------- ### ZDO Command Usage Example Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/all_device_types_app/README.md Shows how to execute the 'zdo' command without parameters to view its subcommands and their descriptions. ```text esp> zdo zdo: Zigbee Device Object management request Request information from node annce Announce current node match Get matched devices bind Request the node to bind to device nwk_open Request the node to open the network nwk_leave Request the node to leave the network ``` -------------------------------- ### Application Start Log Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/ota_upgrade/ota_server/README.md Logs displayed when the OTA server application starts, indicating Zigbee stack initialization and network formation. ```log I (451) main_task: Calling app_main() I (461) OTA_SERVER: Start ESP Zigbee Stack I (471) esp zigbee sleep: light sleap disabled I (481) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (481) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (501) OTA_SERVER: Initialize Zigbee stack I (501) OTA_SERVER: Deferred driver initialization successful I (501) OTA_SERVER: Device started up in factory-reset mode I (511) main_task: Returned from app_main() I (821) OTA_SERVER: Formed network successfully: PAN ID(0x1c08, EXT: 0x4831b7fffec18405), Channel(13), Short Address(0x0000) I (1241) OTA_SERVER: Network steering completed ``` -------------------------------- ### Thermostat Application Start Logs Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/home_automation_devices/thermostat/README.md Logs displayed when the thermostat application starts, forming an open Zigbee network. ```log I (419) main_task: Calling app_main() I (439) THERMOSTAT: Start ESP Zigbee Stack I (439) esp zigbee sleep: light sleap disabled I (449) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (449) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (469) main_task: Returned from app_main() I (479) THERMOSTAT: Initialize Zigbee stack I (479) THERMOSTAT: Deferred driver initialization successful I (479) THERMOSTAT: Device started up in factory-reset mode I (809) THERMOSTAT: Formed network successfully: PAN ID(0x3e40, EXT: 0x4831b7fffec183f0), Channel(13), Short Address(0x0000) I (1249) THERMOSTAT: Network steering completed ``` -------------------------------- ### Clone ESP Zigbee SDK Repository Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/README.md Clone the official ESP Zigbee SDK repository using Git to get started with development. ```bash git clone https://github.com/espressif/esp-zigbee-sdk.git ``` -------------------------------- ### Application Start and Initialization Logs Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/sleepy_devices/light_sleep_end_device/README.md Logs displayed when the application starts, showing initialization of the Zigbee stack and light sleep mode. This output is typical for a device joining a Zigbee network. ```log I (444) main_task: Calling app_main() I (461) pm: Frequency switching config: CPU_MAX: 96, APB_MAX: 96, APB_MIN: 96, Light sleep: ENABLED I (462) LIGHT_SLEEP_END_DEVICE: Start ESP Zigbee Stack I (466) esp zigbee sleep: light sleap enabled I (484) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (486) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (487) sleep_clock: Modem Power, Clock and Reset sleep retention initialization I (514) LIGHT_SLEEP_END_DEVICE: Initialize Zigbee stack I (516) LIGHT_SLEEP_END_DEVICE: Deferred driver initialization successful I (517) LIGHT_SLEEP_END_DEVICE: Device started up in factory-reset mode I (528) main_task: Returned from app_main() ``` -------------------------------- ### Application Start and Deep Sleep Initialization Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/sleepy_devices/deep_sleep_end_device/README.md This snippet shows the initial logs when the application starts, including wake-up cause, entering deep sleep, and Zigbee stack initialization. It indicates the device's state upon waking and its attempt to join a network. ```log I (427) main_task: Calling app_main() I (447) DEEP_SLEEP_END_DEVICE: Wake up from unknown cause, deep sleep for 138 milliseconds I (447) DEEP_SLEEP_END_DEVICE: Enter deep sleep 5 seconds I (447) DEEP_SLEEP_END_DEVICE: Start ESP Zigbee Stack I (457) esp zigbee sleep: light sleap disabled I (467) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (467) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (487) DEEP_SLEEP_END_DEVICE: Initialize Zigbee stack I (487) DEEP_SLEEP_END_DEVICE: Deferred driver initialization successful I (487) DEEP_SLEEP_END_DEVICE: Device started up in factory-reset mode I (497) main_task: Returned from app_main() I (2777) DEEP_SLEEP_END_DEVICE: Joined network successfully: PAN ID(0x3669, EXT: 0x4831b7fffec18405), Channel(13), Short Address(0x1a4b) I (2777) DEEP_SLEEP_END_DEVICE: Attempt to find HA light device in the network I (4757) DEEP_SLEEP_END_DEVICE: Attempt to bind HA light device (short address: 0x0000) I (4767) DEEP_SLEEP_END_DEVICE: Bound HA light device successfully I (5447) DEEP_SLEEP_END_DEVICE: Enter deep sleep for 20 seconds ``` -------------------------------- ### Application Startup Log Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/customized_devices/data_producer/README.md This log output shows the application starting up, initializing the Zigbee stack, and forming a network. It indicates the device is acting as a Coordinator and is open for connections. ```log I (399) main_task: Calling app_main() I (419) CUSTOMIZED_DATA_PRODUCER: Start ESP Zigbee Stack I (419) ESP-ZIGBEE: SDK Version: v1.6.8-fcae32885b02-c1ffcb29; esp32h2; 2026-04-08 11:34:58 UTC I (419) esp zigbee sleep: light sleap disabled I (439) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (439) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (459) CUSTOMIZED_DATA_PRODUCER: Initialize Zigbee stack I (459) CUSTOMIZED_DATA_PRODUCER: Device started up in factory-reset mode I (459) main_task: Returned from app_main() I (789) CUSTOMIZED_DATA_PRODUCER: Formed network successfully: PAN ID(0x891a, EXT: 0x4831b7fffec183f0), Channel(13), Short Address(0x0000) I (1039) CUSTOMIZED_DATA_PRODUCER: Network(0x891a) is open for 180 seconds ``` -------------------------------- ### Build and Flash ESP Zigbee Gateway Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/zigbee_gateway/README.md Build the ESP Zigbee Gateway project, flash it to the board, and start the serial monitor. Replace PORT with your device's serial port. ```bash idf.py -p PORT flash monitor ``` -------------------------------- ### Start BDB Commissioning Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Initiates the top-level BDB commissioning process. The command will start the Zigbee stack if it's not already running. Supported modes include steer, form, bind, initiator, and target. ```bash esp> bdb_comm start form I (15585) cli_cmd_bdb: ZDO signal: ZDO Config Ready (0x17), status: ESP_FAIL I (15585) cli_cmd_bdb: Zigbee stack initialized W (17975) cli_cmd_bdb: Network(0x23ea) closed, devices joining not allowed. I (17985) cli_cmd_bdb: Formed network successfully (Extended PAN ID: 0x4831b7fffec02bbc, PAN ID: 0x23ea, Channel:26, Short Address: 0x0000) ``` -------------------------------- ### Create and Register on_off_light Device Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/all_device_types_app/README.md Creates and registers the HA standard on_off_light data model on Node 1. This is the initial setup for the light device. ```bash esp> zha add 1 on_off_light I (518033) cli_cmd_zha: on_off_light created with endpoint_id 1 esp> dm register esp> ``` -------------------------------- ### OTA Upgrade Server Progress Logs Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/ota_upgrade/ota_server/README.md Logs detailing the OTA upgrade process, including receiving a Query Start request, policy checks, and sending image blocks. ```log I (976) OTA_SERVER: Network steering completed I (2076) OTA_SERVER: Zigbee APP Signal: ZDO Device Update(type: 0x07) I (2116) OTA_SERVER: New device commissioned or rejoined (short: 0x91ab) I (2116) OTA_SERVER: Broadcast OTA Image Notify Command I (2206) OTA_SERVER: -- OTA Upgrade Server Progress I (2206) OTA_SERVER: OTA Query Start: I (2206) OTA_SERVER: Client: short_addr=0x91ab, ep_id=10 I (2206) OTA_SERVER: Query: manuf_code=0x131b, image_type=0x0001, file_version=0xffffffff, hw_version=0x0000 I (2216) OTA_SERVER: Policy: file_version=0x10022000 I (2756) OTA_SERVER: Zigbee APP Signal: ZDO Device Authorized(type: 0x08) I (2786) OTA_SERVER: -- OTA Upgrade Server Progress I (2786) OTA_SERVER: OTA Sending Block: I (2786) OTA_SERVER: manuf_code=0x131b, image_type=0x0001, file_version=0x10022000 W (2786) OTA_SERVER: In progress: [0 / 501134] I (2806) OTA_SERVER: Network(0x726f) is open for 180 seconds I (2946) OTA_SERVER: -- OTA Upgrade Server Progress I (2956) OTA_SERVER: OTA Sending Block: I (2956) OTA_SERVER: manuf_code=0x131b, image_type=0x0001, file_version=0x10022000 W (2956) OTA_SERVER: In progress: [223 / 501134] I (3096) OTA_SERVER: -- OTA Upgrade Server Progress I (3106) OTA_SERVER: OTA Sending Block: I (3106) OTA_SERVER: manuf_code=0x131b, image_type=0x0001, file_version=0x10022000 W (3106) OTA_SERVER: In progress: [446 / 501134] I (3236) OTA_SERVER: -- OTA Upgrade Server Progress I (3246) OTA_SERVER: OTA Sending Block: I (3246) OTA_SERVER: manuf_code=0x131b, image_type=0x0001, file_version=0x10022000 W (3246) OTA_SERVER: In progress: [669 / 501134] I (3376) OTA_SERVER: -- OTA Upgrade Server Progress I (3386) OTA_SERVER: OTA Sending Block: I (3386) OTA_SERVER: manuf_code=0x131b, image_type=0x0001, file_version=0x10022000 W (3386) OTA_SERVER: In progress: [892 / 501134] I (3526) OTA_SERVER: -- OTA Upgrade Server Progress I (3536) OTA_SERVER: OTA Sending Block: I (3536) OTA_SERVER: manuf_code=0x131b, image_type=0x0001, file_version=0x10022000 W (3536) OTA_SERVER: In progress: [1115 / 501134] I (3666) OTA_SERVER: -- OTA Upgrade Server Progress I (3676) OTA_SERVER: OTA Sending Block: I (3676) OTA_SERVER: manuf_code=0x131b, image_type=0x0001, file_version=0x10022000 W (3676) OTA_SERVER: In progress: [1338 / 501134] ``` -------------------------------- ### OTA Image Downloading Progress Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/ota_upgrade/ota_client/README.md Logs indicate the start of the OTA download process and the progress of receiving image blocks. This snippet shows the client actively downloading the new firmware from the server. ```c I (2924) OTA_CLIENT: -- OTA Upgrade Downloading Progress I (2924) OTA_CLIENT: OTA Start: manuf_code=0x1234, image_type=0x5678, file_version=0x00000010, image_size=158966 I (3434) OTA_CLIENT: -- OTA Upgrade Downloading Progress I (3434) OTA_CLIENT: OTA Receiving Block: file_offset=0, block_size=56 W (3434) OTA_CLIENT: In progress: [56 / 158966] ``` -------------------------------- ### Temperature Sensor Application Output Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/home_automation_devices/temperature_sensor/README.md This snippet shows the initial log output when the temperature sensor application starts, including Zigbee stack initialization and network joining. ```log I (416) main_task: Calling app_main() I (426) TEMPERATURE_SENSOR: Start ESP Zigbee Stack I (436) esp zigbee sleep: light sleap disabled I (446) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (446) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (466) TEMPERATURE_SENSOR: Initialize Zigbee stack I (466) temperature_sensor: Range [-10°C ~ 80°C], error < 1°C I (476) TEMPERATURE_SENSOR: Deferred driver initialization successful I (476) TEMPERATURE_SENSOR: Device started up in factory-reset mode I (486) main_task: Returned from app_main() I (1986) TEMPERATURE_SENSOR: Received ZCL Default Response: status(0x00) I (2086) TEMPERATURE_SENSOR: Joined network successfully: PAN ID(0x3e40, EXT: 0x4831b7fffec183f0), Channel(13), Short Address(0xd9bc) ``` -------------------------------- ### Application Output Log Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/home_automation_devices/color_dimmable_light/README.md This log shows the output from the Home Automation Color Dimmable Light application when it starts. It details the initialization of the Zigbee stack, network formation, and device events. ```log I (412) main_task: Calling app_main() I (432) COLOR_DIMMABLE_LIGHT: Start ESP Zigbee Stack I (432) ESP-ZIGBEE: SDK Version: v1.6.8-fcae32885b02-94cf5061*; esp32h2; 2026-04-08 12:28:23 UTC I (432) esp zigbee sleep: light sleap disabled I (452) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (452) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (472) main_task: Returned from app_main() I (522) COLOR_DIMMABLE_LIGHT: Initialize Zigbee stack W (522) rmt: channel resolution loss, real=10666666 I (522) COLOR_DIMMABLE_LIGHT: Deferred driver initialization successful I (532) COLOR_DIMMABLE_LIGHT: Device started up in factory-reset mode I (842) COLOR_DIMMABLE_LIGHT: Formed network successfully: PAN ID(0x85ff, EXT: 0x4831b7fffec183f0), Channel(13), Short Address(0x0000) I (1032) COLOR_DIMMABLE_LIGHT: Network(0x85ff) is open for 180 seconds I (1032) COLOR_DIMMABLE_LIGHT: Network steering completed I (39612) COLOR_DIMMABLE_LIGHT: Zigbee APP Signal: ZDO Device Update(type: 0x7) I (39702) COLOR_DIMMABLE_LIGHT: New device commissioned or rejoined(short: 0x940a) I (39912) COLOR_DIMMABLE_LIGHT: Zigbee APP Signal: ZDO Device Authorized(type: 0x8) I (39952) COLOR_DIMMABLE_LIGHT: Network(0x85ff) is open for 180 seconds ``` -------------------------------- ### Zigbee API Lock Acquisition Example Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/developing.rst Demonstrates acquiring the Zigbee API lock before calling Zigbee APIs, which is mandatory as the APIs are not thread-safe. The lock must be released after the API call. ```c #include "esp_zigbee.h" void application_task(void *pvParameters) { ...... esp_zigbee_lock_acquire(portMAX_DELAY); ezb_zcl_on_off_on_cmd_req(cmd_req); esp_zigbee_lock_release(); ...... } ``` -------------------------------- ### Add Install Code for Remote Device Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Adds an install code for a specific remote device's EUI64 address. This command should be used after the Zigbee stack has started. ```bash esp> ic add 0xbbbbbbbbbbbbbbbb 0x83FED3407A939723A5C639B26916D505C3B5 ``` -------------------------------- ### Create Custom Client Device with Custom Cluster Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/user-guide/zcl_custom.rst Initializes a custom client device, setting up basic, identify, and a custom cluster. This setup is a prerequisite for sending custom commands from a client device. ```c esp_err_t customized_client_device_setup(uint8_t ep_id) { ezb_af_device_desc_t dev_desc = ezb_af_create_device_desc(); ezb_af_ep_desc_t ep_desc = NULL; ezb_zcl_cluster_desc_t basic_desc = NULL; ezb_zcl_cluster_desc_t identify_desc = NULL; ezb_zcl_cluster_desc_t custom_desc = NULL; ``` -------------------------------- ### Build and Create OTA Image using image_builder_tool.py Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/user-guide/zcl_ota_upgrade.rst Builds the light application and uses the image_builder_tool.py to create an OTA image file with specified parameters. Ensure you are in the light application's directory and have set the target chip. ```bash cd ~/esp/esp-zigbee-sdk/examples/esp_zigbee_HA_sample/HA_on_off_light idf.py fullclean idf.py set-target [CHIP] idf.py build python ~/esp/esp-zigbee-sdk/tools/image_builder_tool/image_builder_tool.py --manuf-id 0x1234 --image-type 0x5678 --file-version 0x00000010 --tag 0x0000:build/ha_on_off_light_app.bin ``` -------------------------------- ### Remove Install Code for Remote Device Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Removes the install code associated with a specific remote device's EUI64 address. ```bash esp> ic remove 0xbbbbbbbbbbbbbbbb ``` -------------------------------- ### Get Zigbee Device Address Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Retrieves the short or extended address of the Zigbee device node. Use the '-x' flag to get the extended address. ```bash esp> address 0x0d29 ``` ```bash esp> address -x 0x4831b7fffec02bbc ``` -------------------------------- ### Application Start and Network Join Log Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/customized_devices/data_consumer/README.md This log shows the initial application startup, Zigbee stack initialization, and successful network joining process. It indicates the device is acting as a router and has joined a network with specific PAN ID, channel, and short address. ```log I (402) main_task: Calling app_main() I (422) CUSTOMIZED_DATA_CONSUMER: Start ESP Zigbee Stack I (422) ESP-ZIGBEE: SDK Version: v1.6.8-fcae32885b02-c1ffcb29*; esp32h2; 2026-04-08 12:07:37 UTC I (422) esp zigbee sleep: light sleap disabled I (442) phy: phy_version: 323,2, a8ef10c, Aug 1 2025, 17:46:10 I (442) phy: libbtbb version: 4515421, Aug 1 2025, 17:46:22 I (462) CUSTOMIZED_DATA_CONSUMER: Initialize Zigbee stack I (462) CUSTOMIZED_DATA_CONSUMER: Deferred driver initialization successful I (462) CUSTOMIZED_DATA_CONSUMER: Device started up in factory-reset mode I (472) main_task: Returned from app_main() I (1582) CUSTOMIZED_DATA_CONSUMER: Network(0x891a) is open for 180 seconds I (1582) CUSTOMIZED_DATA_CONSUMER: Joined network successfully: PAN ID(0x891a, EXT: 0x4831b7fffec183f0), Channel(13), Short Address(0xe547) ``` -------------------------------- ### Send Get Group Membership Command Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/user-guide/zcl_groups.rst Sends a Get Group Membership command to a specified endpoint and address. This function prepares and sends the command, handling Zigbee stack locking. ```c static ezb_err_t switch_send_get_group_membership_cmd(uint8_t src_ep, uint8_t dst_ep, uint16_t dst_short_addr) { ezb_err_t ret = EZB_ERR_NONE; ezb_zcl_groups_get_group_membership_cmd_t cmd = { .cmd_ctrl = { .dst_addr = {.addr_mode = EZB_ADDR_MODE_SHORT, .u.short_addr = dst_short_addr}, .src_ep = src_ep, .dst_ep = dst_ep, }, .payload = { .group_count = 0, .group_list = NULL, }, }; esp_zigbee_lock_acquire(portMAX_DELAY); ret = ezb_zcl_groups_get_group_membership_cmd_req(&cmd); esp_zigbee_lock_release(); return ret; } ``` -------------------------------- ### Create Custom Server Device with Custom Cluster Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/user-guide/zcl_custom.rst Sets up a custom server device with basic, identify, and a custom cluster. The custom cluster includes a string attribute with read and reporting access. This is useful for devices requiring non-standard attributes. ```c #define CUSTOM_DEVICE_ID 0xff01 #define CUSTOM_CLUSTER_ID 0xff00 #define CUSTOM_CLUSTER_QUERY_NAME_CMD_ID 0x00 #define CUSTOM_CLUSTER_QUERY_NAME_RSP_CMD_ID 0x01 #define CUSTOM_CLUSTER_NAME_ATTR_ID 0x0000 esp_err_t customized_server_device_setup(uint8_t ep_id) { ezb_af_device_desc_t dev_desc = ezb_af_create_device_desc(); ezb_af_ep_desc_t ep_desc = NULL; ezb_zcl_cluster_desc_t basic_desc = NULL; ezb_zcl_cluster_desc_t identify_desc = NULL; ezb_zcl_cluster_desc_t custom_desc = NULL; ezb_zcl_basic_cluster_server_config_t basic_cfg = { .zcl_version = EZB_ZCL_BASIC_ZCL_VERSION_DEFAULT_VALUE, .power_source = EZB_ZCL_BASIC_POWER_SOURCE_DEFAULT_VALUE, }; basic_desc = ezb_zcl_basic_create_cluster_desc(&basic_cfg, EZB_ZCL_CLUSTER_SERVER); ezb_zcl_basic_cluster_desc_add_attr(basic_desc, EZB_ZCL_ATTR_BASIC_MANUFACTURER_NAME_ID, (void *)"\x09""ESPRESSIF"); ezb_zcl_basic_cluster_desc_add_attr(basic_desc, EZB_ZCL_ATTR_BASIC_MODEL_IDENTIFIER_ID, (void *)"\x07" CONFIG_IDF_TARGET); ezb_zcl_identify_cluster_server_config_t identify_cfg = { .identify_time = EZB_ZCL_IDENTIFY_IDENTIFY_TIME_DEFAULT_VALUE, }; identify_desc = ezb_zcl_identify_create_cluster_desc(&identify_cfg, EZB_ZCL_CLUSTER_SERVER); ezb_zcl_custom_cluster_config_t custom_cfg = { .cluster_id = CUSTOM_CLUSTER_ID, .init_func = customized_server_device_init, .deinit_func = NULL, }; custom_desc = ezb_zcl_custom_create_cluster_desc(&custom_cfg, EZB_ZCL_CLUSTER_SERVER); ezb_zcl_custom_cluster_desc_add_attr(custom_desc, CUSTOM_CLUSTER_NAME_ATTR_ID, EZB_ZCL_ATTR_TYPE_STRING, EZB_ZCL_ATTR_ACCESS_READ | EZB_ZCL_ATTR_ACCESS_REPORTING, (void *)"\x0b""ESP-Zigbee"); ezb_af_ep_config_t ep_config = { .ep_id = ep_id, .app_profile_id = EZB_AF_HA_PROFILE_ID, .app_device_id = CUSTOM_DEVICE_ID, .app_device_version = 0, }; ep_desc = ezb_af_create_endpoint_desc(&ep_config); ESP_ERROR_CHECK(ezb_af_endpoint_add_cluster_desc(ep_desc, basic_desc)); ESP_ERROR_CHECK(ezb_af_endpoint_add_cluster_desc(ep_desc, identify_desc)); ESP_ERROR_CHECK(ezb_af_endpoint_add_cluster_desc(ep_desc, custom_desc)); ESP_ERROR_CHECK(ezb_af_device_add_endpoint_desc(dev_desc, ep_desc)); ESP_ERROR_CHECK(ezb_af_device_desc_register(dev_desc)); return ESP_OK; } ``` -------------------------------- ### Handle Get Scene Membership Response Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/user-guide/zcl_scene.rst Callback function to handle the response for a 'Get Scene Membership' command. It logs the received group ID, capacity, and scene list, validating the status of the response. ```c static void switch_handle_get_scene_membership_rsp(ezb_zcl_scenes_get_scene_membership_rsp_message_t *message) { ESP_RETURN_ON_FALSE(message, , TAG, "Empty message"); ESP_RETURN_ON_FALSE(message->info.status == EZB_ZCL_STATUS_SUCCESS, , TAG, "Received message: error status(%d)", message->info.status); ESP_LOGI(TAG, "Receive scenes get scene membership response with Group ID: 0x%04x, capacity: %d", message->in.group_id, message->in.capacity); ESP_LOGI(TAG, "Scene List:"); for (int i = 0; i < message->in.scene_count; i++) { ESP_LOGI(TAG, "%d", *message->in.scene_list); message->in.scene_list++; } } ``` -------------------------------- ### Initialize 64-bit identifiers with ezb_extaddr_t Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/migration-guide/v2.x/common.rst Demonstrates two methods for initializing 64-bit identifiers using the ezb_extaddr_t type. This is relevant when migrating from older types like esp_zb_64bit_addr_t. ```c ezb_extaddr_t eui64 = { .u64 = 0x0123456789ABCDEF }; ``` ```c ezb_extaddr_t eui64 = { .u8 = { 0x01, 0x23, 0x45, 0x67, 0x89, 0xAB, 0xCD, 0xEF } }; ``` -------------------------------- ### Get PAN ID Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Retrieve the current PAN ID or extended PAN ID of the Zigbee device node. ```bash esp> panid 0x74e5 ``` ```bash esp> panid -x 0x744dbdfffe602d57 ``` -------------------------------- ### Create Scene Client Cluster Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/docs/en/user-guide/zcl_scene.rst This code demonstrates how to create an endpoint with the Scene Cluster, enabling control over a light's status and brightness. This implementation is referred to as the 'Scene Switch'. ```c #define SCENE_CLUSTER_ID 0x0005 #define SCENE_CLUSTER_VERSION 1 static void scene_cluster_init(void) { struct ezb_zcl_scenes_cluster_desc *scene_cluster_desc; struct ezb_zcl_cluster_desc *cluster_desc; struct ezb_zcl_attr_desc *attr_desc; scene_cluster_desc = ezb_zcl_scenes_cluster_desc_create(); if (!scene_cluster_desc) { return; } /* Add OnOff attribute */ attr_desc = ezb_zcl_create_attr_desc(ZCL_ATTR_ID_ONOFF, ZCL_ATTR_TYPE_BOOLEAN, ZCL_ATTR_FLAG_RW, NULL, NULL); if (attr_desc) { ezb_zcl_scenes_cluster_desc_add_attr(scene_cluster_desc, attr_desc); } /* Add CurrentLevel attribute */ attr_desc = ezb_zcl_create_attr_desc(ZCL_ATTR_ID_CURRENT_LEVEL, ZCL_ATTR_TYPE_U8, ZCL_ATTR_FLAG_RW, NULL, NULL); if (attr_desc) { ezb_zcl_scenes_cluster_desc_add_attr(scene_cluster_desc, attr_desc); } cluster_desc = ezb_zcl_scenes_create_cluster_desc(scene_cluster_desc, SCENE_CLUSTER_ID, SCENE_CLUSTER_VERSION); if (!cluster_desc) { return; } ezb_af_endpoint_add_cluster_desc(EXAMPLE_ENDPOINT, cluster_desc); } ``` -------------------------------- ### Add esp-zigbee-lib Dependency Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/README.md Use this command to automatically download the esp-zigbee-lib component by specifying its dependency in the idf_component.yml file. ```bash idf.py add-dependency "espressif/esp-zigbee-lib^2.0.0" ``` -------------------------------- ### Read RCP Version Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/examples/zigbee_gateway/README.md Logs the RCP version read from the remote radio via UART upon program start. ```log I (433) main_task: Started on CPU0 I (443) main_task: Calling app_main() I (453) ZIGBEE_GATEWAY: Start ESP Zigbee Stack I (493) main_task: Returned from app_main() I (503) RCP_UPDATE: RCP: using update sequence 0 I (503) ESP_RADIO_SPINEL: spinel UART interface initialization completed I (503) ESP_RADIO_SPINEL: Spinel UART interface has been successfully enabled I (503) ESP_ZIGBEE_RADIO_SPINEL_UART: Spinel UART interface enable successfully I(513) OPENTHREAD:[I] P-SpinelDrive-: co-processor reset: RESET_POWER_ON E(523) OPENTHREAD:[C] P-SpinelDrive-: Software reset co-processor successfully I (573) ESP_ZIGBEE_RCP: Running RCP version: openthread-esp32/fcae32885b029-b945928d7; esp32h2; 2026-03-11 02:30:22 UTC ``` -------------------------------- ### Generate Factory Partition Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/tools/mfg_tool/README.md Generate a single factory partition binary using direct parameter input. Specify install code, MAC address, channel mask, manufacturer name, and manufacturer code. ```bash python esp_zb_mfg_tool.py -i 966b9f3ef98ae6059708 -m CAFEBEEF50C0FFED -c 0x8000 -mn Espressif -mc 0x131B ``` -------------------------------- ### Get Iperf Test Result Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Dumps the iperf throughput results on the current node, specifying the role and source endpoint. ```bash esp> iperf result -r C -e 2 ``` -------------------------------- ### Get BDB Commissioning Mode Source: https://github.com/espressif/esp-zigbee-sdk/blob/main/components/esp-zigbee-console/README.md Retrieves the current or last BDB commissioning mode. The displayed value is a combination of esp_zb_bdb_commissioning_mode_mask_t. ```bash esp> bdb_comm mode 0x04 ```