Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs

Configuring mesh transmission count and interval

I'm new to the Bluetooth mesh world and I'm trying to change some basic configuration parameters during runtime, by modifying the Light Switch example. I've searched around for a correct way or function to change the transmit count and interval for the origin node of a message, and the re-transmit count and interval of a relay node, but found no suitable answer. So far my best bet is using the following code in the main loop; 

mesh_opt_core_adv_t relay_options = {.enabled = true, .tx_count = 3, .tx_interval_ms = 55};
uint8_t is_nested;
ERROR_CHECK(sd_nvic_critical_region_enter(&is_nested));
NRF_MESH_ERROR_CHECK(mesh_opt_core_adv_set(CORE_TX_ROLE_RELAY, &relay_options));
ERROR_CHECK(sd_nvic_critical_region_exit(is_nested));

 for configuring a relay node (server) and switching out the role: CORE_TX_ROLE_RELAY to CORE_TX_ROLE_ORIGINATOR for the client.

The code runs without any errors, but i don't know how to verify that the change has been accepted. When i look at the config of the nodes in the app, the parameters have their default value of 1 count and 100 ms interval, which to me indicates that the new parameters were rejected or changed again afterwards. So what is the correct way of changing these parameters?

Side question: Where can i find the callback that gets triggered when the node receives an input on Rx? I could print how many unfiltered transmission has been received at this location which is why it is of interest.

Parents Reply Children
Related