1、初始化流程,存储初始化,nvs擦除, board_init();初始化LED。
2、bluetooth_init();ble协议栈初始化
3、ble_mesh_get_dev_uuid(dev_uuid);//获取设备uuid加载到mac,后两位dev uuid
4、ble_mesh_init();//ble mesh协议栈初始化。
4.2注册配网的回调 esp_ble_mesh_register_prov_callback(example_ble_mesh_provisioning_cb);
4.3注册服务配置回调 esp_ble_mesh_register_config_server_callback(example_ble_mesh_config_server_cb);
4.4/vendor模型回调 esp_ble_mesh_register_custom_model_callback(example_ble_mesh_custom_model_cb);
4.5配网初始化.节点配置esp_ble_mesh_init(&provision, &composition);
4.7开启节点使能ADV与GATT广播esp_ble_mesh_node_prov_enable(ESP_BLE_MESH_PROV_ADV | ESP_BLE_MESH_PROV_GATT);
4.8开启led灯board_led_operation(LED_G, LED_ON);