- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi:
according to the documents ,I have realized the bluetooth mesh scene,but I have some doubts
1. as we know,the CYW20735 have not On-chip flash,so I think the scene configurations should be saved into the external flash,but I can't find out any code to save the scene configuration
2. the scene server how to process the messages which come from scene client, I can only find the scene server message entry which is wiced_bt_mesh_model_scene_server_message_handler,but this function is encapsulated, what if I want to add my own application
thanks
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Mandy Wu,
1. Memory is allotted in the VS (Vendor-Specific) section of the NVRAM (flash memory) for Mesh parameters that need to survive power cycles. This is accomplished by the mesh_setup_nvram_ids() function defined in mesh_application.c.
2. All the APIs are well documented in the SDK itself. Please use API.html file (inside Doc folder) to understand the API usage.
(Open API.html -> select Components tab -> Bluetooth -> BLE MESH -> Mesh Model Library API)
To understand the simple usage of scene store and recall you can refer Mesh OnOff Server APIs which are wiced_bt_mesh_model_onoff_server_scene_store_handler and wiced_bt_mesh_model_onoff_server_scene_recall_handler.
Thanks,
-Dheeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Mandy Wu,
1. Memory is allotted in the VS (Vendor-Specific) section of the NVRAM (flash memory) for Mesh parameters that need to survive power cycles. This is accomplished by the mesh_setup_nvram_ids() function defined in mesh_application.c.
2. All the APIs are well documented in the SDK itself. Please use API.html file (inside Doc folder) to understand the API usage.
(Open API.html -> select Components tab -> Bluetooth -> BLE MESH -> Mesh Model Library API)
To understand the simple usage of scene store and recall you can refer Mesh OnOff Server APIs which are wiced_bt_mesh_model_onoff_server_scene_store_handler and wiced_bt_mesh_model_onoff_server_scene_recall_handler.
Thanks,
-Dheeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi DheerajP_41:
thank you for your reply.
1. mesh_setup_nvram_ids() is only to allocate the nv ids,I can't find the place where the scene configuration is written to nv by the allocated ids
2.wiced_bt_mesh_model_onoff_server_scene_store_handler and wiced_bt_mesh_model_onoff_server_scene_recall_handler are
encapsulated,I guess if the scene on_off value are written to nv in wiced_bt_mesh_model_onoff_server_scene_store_handler,meanwhile if the on off value are read from nv in the wiced_bt_mesh_model_onoff_server_scene_recall_handler. and the on off message is how to transport to application layer to perform the on off operatiothsn
thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi mawu_4270096,
"nvram write" and "Saving Scene states" are handled by mesh core libraries, which is not accessible by customers. The nv ids which you are setting in mesh_application.c will be used by core and models.
And whenever a scene store or recall valid messages are received by the core, it need to tell all the elements of the device to store/recall the current state. The information for the model state are defined in the model spec: https://www.bluetooth.com/specifications/mesh-specifications/
Thanks,
-Dheeraj