This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

provision problem

I'm using nrf_MESH app to provision proxy client in nrf_mesh SDK2.20.

There are some questions about provision process.

1).Before provision we know that the device should beacon the device information.Is it use PB_ADV to advertising the UUID?If not, where can I find/print the beacon information?

2).In the provision process,the device can send data by calling function send_data() (provisioning.c) via interface->tx send data to mobile.If I am correct ,is there any event happens in the context  after data sened ? I can see that mesh_gatt_pdu_send() is run in mesh_gatt.c after  interface->tx .I don't know if it sends something to my mobile or the network but the sizeof(p_packet) is always 4.

3).When I receive data from nrf_MESH app in provision process ,which function or call back or event to be triggered to receive data/packet?I can see it received from mesh_gatt_on_ble_evt() in NRF_SDH_BLE_OBSERVER(m_gatt_obs, NRF_MESH_GATT_BLE_OBSERVER_PRIO, mesh_gatt_on_ble_evt, &m_gatt) when event become BLE_GATTS_EVT_WRITE.Am I right?

4).After provision process finish,the next step is to configura the node.Are the configura information  transmites in mesh network use mesh_gatt_pdu_send()?And the node how to get and store the publish and subscribe information and app key?

These make me confused and hope for your reply.

Thanks in advance.

Parents
  • 1) You advertise both a non-connectable (PB-ADV) & a connectable (PB-GATT) beacon. The connectable beacon also includes the mesh provisioning service UUID.

    2) The device sends data via the proxy.c file using the proxy service. This can be seen by looking at the proxy light switch example device log (e.g. debugging using Segger Embedded Studio). One can see that the MESH_GATT_EVT_TYPE_TX_READY & MESH_GATT_EVT_TYPE_TX_COMPLETE events in gatt_evt_handler get called a few times.

    3) The rx_handle function in proxy.c is used to handle incoming packets from the nRF Mesh mobile app (e.g. see MESH_GATT_EVT_TYPE_RX).

    4) You set the publish/subscribe information & the app key via the nRF Mesh app. The same gatt_evt_handler is used to receive the incoming appkey bind & publish/subscribe address messages. Are you wondering where the appkey & the publish/subscribe messages get stored in the device itself?

  • Sorry to reply for a long time.

    I've gotten it.But for qustion(4),I don't find any call or interface in gatt_evt_handler  to connect to the information about setting the publish/subscribe information & the app key in mesh network.So I don't know how to configure them.

  • Check the rx_handle() function, in addition to the other functions in the switch case (i.e. network_packet_in(), net_beacon_packet_in() & config_packet_in()).

Reply Children
No Data
Related