Developing a Bluetooth mesh Gateway using nrf52840 and Control through multiple NRF_MESH app

Hai, 

 We are planning to develop a Bluetooth gateway based on nrf52840.

the nrf is connected to esp32 through uart.

The duty of the nrf52840 is

 1. It should receive all the messages in the mesh network.

like if sensor published a data, light is turned off, switch is pressed.

2. It can be able to publish a message in the mesh network

like turning on/off the light.

3. Replacing the gateway, what are the mesh parameters we need to take it out from the old nrf52840 to 

make other nrf52840 to connect to mesh.

Also In nrf mesh app I'm having doubts

Using nrf mesh app only we are planning to provision the new devices.

How can I share app? (for control purpose)

What are the mesh data we have to share between the two apps?

Best Regards

Bose

  • Hello Bose,

    There is no "leader"/"gateway"/"master" role in Bluetooth Mesh, so to me it sounds like you would need to create your own "supernode" that basically subscribes to everything of interest in your Bluetooth Mesh network, and report it to the ESP32, and vice versa, you need to write some command set that will send the corresponding messages out to your Mesh network to e.g. turn on/off lights. 

    3. Replacing the gateway, what are the mesh parameters we need to take it out from the old nrf52840 to 

    make other nrf52840 to connect to mesh.

    For the gateway, I think the easiest option is to provision it again, and make it subscribe to the same channels/addresses as before. 

    Using nrf mesh app only we are planning to provision the new devices.

    How can I share app? (for control purpose)

    What are the mesh data we have to share between the two apps?

    I have not tested this, but in your nRF Mesh app, if you go to settings -> Provisioners, you can add new provisioners. As you see, you need to assign some parameters, such as unicast and group addresses. So this will allow more devices to act as provisioners, but they don't really have a backup of eachother's data (I think), so this means that if you add a device using one provisioner, the other provisioners will not be aware of this. In order to share this, you need to set up some sort of database that you can store online, that the other provisioners can keep up to date whenever you add or remove a device.

    Best regards,

    Edvin

  • Hai  

     Thank you for your response.

    "supernode" - Method will be easy for gateway.

    is it possible to remove a Device from the mesh using supernode?

    We are planning to develop a BLE mesh app like nRF Mesh app. (based on Android-nRF-Mesh-Library)

    What are the data we have to store to give access to the other app for control?

    For example:

      To provision the new device, what are the Mesh network parameters required?

    Already provisioned network, if any new mobile wants to connect and control the devices, 

    what are the mesh parameters is required?

    Best Regards

    Bose

  • Bosemani_Raja said:
    is it possible to remove a Device from the mesh using supernode?

    Good question. I believe you need to be a provisioner in order to do this. An nRF can be the provisioner, but I see that we don't have any samples showing this (so I am not sure whether it is supported in NCS. We used to have a provisioner sample in the nRF5 SDK for Mesh).

    Bosemani_Raja said:

      To provision the new device, what are the Mesh network parameters required?

    Already provisioned network, if any new mobile wants to connect and control the devices, 

    what are the mesh parameters is required?

    Strictly speaking, the only thing that a provisioner needs to know is:

    1: Network Keys (may be several)

    2: Application keys (may be several)

    3: A set of addresses (unicast and group addresses and scene addresses) that it can control (assign to nodes).

    Strictly speaking, it doesn't need to be that strictly divided, so that it is pre-set what addresses the different provisioners can control, but that is the way it is done in our nRF Mesh app, if you try to add another provisioner. I think the key takeaway is that one address is used for several things. E.g. one unicast address assigned to two devices, or one group address being used for different functionality by different provisioners.

    Best regards,

    Edvin

  • Hai  

        In "NRF MESH" app itself having an option to export and import mesh network information.

    It is creating the .json file containing the network information. we can share to other mobiles and able to connect to the network.

    Thank you

    best regards

    Bose

Related