esp_zb_start() function
Start Zigbee function. For example, you can use this function if it is needed to enable leds, timers or any other devices on periphery to work with them before starting working in a network. It's also useful if you want to run something locally during joining.
Arguments
autostart
- true autostart mode - false no-autostart mode
Return value
- ESP_OK on success
Notes
Autostart mode: It initializes, load some parameters from NVRAM and proceed with startup. Startup means either Formation (for ZC), rejoin or discovery/association join. After startup complete, esp_zb_app_signal_handler is called, so application will know when to do some useful things. No-autostart mode: It initializes scheduler and buffers pool, but not MAC and upper layers. Notifies the application that Zigbee framework (scheduler, buffer pool, etc.) has started, but no join/rejoin/formation/BDB initialization has been done yet. Typically esp_zb_start with no_autostart mode is used when application wants to do something before starting joining the network. Precondition: stack must be initialized by esp_zb_init call. esp_zb_init sets default IB parameters, so caller has a chance to change some of them. Note that NVRAM and product config will be loaded after esp_zb_start() call. Zigbee stack is not looped in this routine. Instead, it schedules callback and returns. Caller must run esp_zb_stack_main_loop() after this routine. Application should later call Zigbee commissioning initiation - for instance, esp_zb_bdb_start_top_level_commissioning(). @anchor esp_zb_start