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

Disable scanning in Mesh SDK

Hi,

We are using Mesh successfully with the Mesh SDK 3.1.0 combined with Nordic SDK 15.2 and Softdevice 6.1.1.

Due to the nature of our BT device I would like to explore the opportunity to disable the Mesh Scanner in the Mesh enable function. While it is easy to avoid the specific function call I would like to understand the impact on the Mesh SDK.

Best Regards,

Ronny

Parents
  • Hi. 

    When looking at the nrf_mesh_enable () function (in the light switch example from nRF5 SDK for Mesh v3.1.0): 

    uint32_t nrf_mesh_enable(void)
    {
        uint32_t status = NRF_ERROR_INVALID_STATE;
        switch (m_mesh_state)
        {
            case MESH_STATE_INITIALIZED:
    #if !MESH_FEATURE_LPN_ENABLED
                scanner_enable();
    #endif
                network_enable();
                transport_enable();
    

    The scanner is initialized in nrf_mesh_enable() unless the LPN feature is enabled. 

    Due to the nature of our BT device I would like to explore the opportunity to disable the Mesh Scanner in the Mesh enable function.

     I wouldn't say that you need to disable the scanner in the nrf_mesh_enable() function. Instead, I suggest that you don't enable it if that is what you want. 

    I would like to understand the impact on the Mesh SDK.

     Well, if you don't enable the scanner, you won't have the traditional behavior of a Mesh node - Where the node is mostly in RX mode listening for incoming packets. Either listening for packets for that particular node, or packets to relay. We don't enable the scanner when the LPN feature is enabled, in that case the node needs to wake up and request data from it's friend node to receive data. 

    Best regards, 

    Joakim

  • Hi Joakim,

    Thank you for your response.

    1. Not enabling the scanner makes sense.
    2. Treating the RX Mode for an enhanced battery while RX isn't desired anyway

    Best Regards,

    Ronny 

  • Happy to help! 

    Let me know if you have any further questions. 

    Best regards,
    Joakim

Reply Children
No Data
Related