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

How to turn on/off mesh

I am using the RBC mesh in a networking product using the nRF51422. We would like to turn the mesh on and off at selected times, say once per hour for a minute or two. I know how to turn on (init) the mesh. But, what is the best way to turn it off such that the radio is at minimal power?

Thanks in advance --s

Parents
  • The turning on and off of mesh is not exposed. It should be, but we didn't really consider it at first. I think the easiest fix is to stop the timeslots. you would have to modify the way the radio events are handled to keep it from restarting the session, but it should be pretty straight forward.

    in ts_sd_event_handler instead of renewing the timeslot, renew it based on some condition something like this for example

            case NRF_EVT_RADIO_SESSION_IDLE:
                if(!switch_it_off)
                      timeslot_order_earliest(TIMESLOT_SLOT_LENGTH, true);
                else
                      err_code = sd_radio_session_close();
                      if (err_code != NRF_SUCCESS) {handle_error}
                break;
    

    so when the timeslot-start signal isn't triggered, there should be no unexpected hardware usage.

  • the receiver is switched off before the slot has ended, and if no new slot is requested, then it remains off. Timeslots can be used both for transmission and reception of data

Reply Children
No Data
Related