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

Are there any initializations I need for my custom radio if I'm including timeslot with bluetooth?

I looked at the radio project in the peripheral folder on SDK5 11. I managed to get a custom radio project that works well with my device. A brief on my project, I set up a GPIOTE input event and when that event is triggered, I send a message to receiver devices using my custom radio protocol.

Now, I have to add bluetooth support to talk to a phone. I created a time slot project following a tutorial I found here. I managed to create a project that runs bluetooth and runs my event only it's timeslot. I would like to be able to send a message when my event is triggered using timeslot and my custom radio protocol.

So my question is, do I need to initialize the my custom radio protocol like I do in the radio project ? Does timeslot take care of this for me? Am I free to send a packet like I already do, or do I need to initialize the radio? Would I have to do it once, or every time my time slot occurs?

  • Hi,

    If your custom protocol uses the same settings as normal BLE you should be fine with regards to configurations, otherwise you will need to reconfigure at the start of each timeslot.

    At the start of the timeslot event the radio is not turned on, so you will have to start the tasks that enable the radio, ie. you still need to call

    NRF_RADIO->TASKS_TXEN   = 1;
    
    while (NRF_RADIO->EVENTS_READY == 0U)
    {
        // wait
    }
    

    and similar calls.

    There's an example on multiprotocol using timeslots available on github, which you might find helpful.

    Best regards,

    Øyvind

Related