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

Energy Detection Mode for 1Mbit/2Mbit

Dear people of DevZone,

I set up a TDMA-based sensor network using the NRF52840 without the BLE-Softdevice or any API functions (message transmission and reception all by hand with NRF registers).

Everything works fine and now I wanted to extend the network with the capability to measure the RSSI/signal level of each timeslot in my TDMA-superframes (without receiving messages e.g. also interferences ).
The NRF52840 (and 52833) support Energy Detection (ED) that comes with the IEEE 802.15.4 operation modes of the SoC. I start the ED mode every timeslot and the result looks promising.

But now my question:
I do not use the 802.15.4 mode and also not the corresponding bitrate of 250 kbps.
I use the Ble_1Mbit and Ble_2Mbit mode and cannot find anything in the datasheets if these modes  support the ED at all and if the result I get is valid/trustable? I also observed that by going from Ble_1Mbit to Ble_2Mbit the measured ED is varying more and it also shows way more interference (high ED value in timeslots I am not using). Which again raises my question if the ED is supported in the 1Mbit/2Mbit mode at all?

I hope you can help me with my ED questions or suggest me another way to measure the (average/max) RSSI/signal level over a certain time period (~1ms) without receiving messages.

Br
Julian

  • Hi Julian

    The BLE 1Mbit and 2Mbit modes do not support Energy detection in the same way it is available in the IEEE 802.15.4 operation modes of the SoC, and we have no such examples in the SDK. One thing you might find useful is the QoS channel survey which is an unofficial example by one of my colleagues explained in his blog found here. Alternatively, you can do a more basic approach where you measure the received RSSI level against a set threshold (I.E. -100dBm) where the device will only proceed if the RSSI level is higher than that.

    Best regards,

    Simon

  • Hello Simon,

    First, thank you for your reply.

    I understand that Energy Detection is not supported in the SoftDecive and there is no example in the SDK, but what exactly happens when I start the ED mode (NRF_RADIO->TASKS_EDSTART = 1 ) and wait for the interrupt. Does it trigger a longer RSSIsample period or something completely different what is particularly for the 802.15.4 mode?
    Although I am in the 1Mbit mode the result seems promising as I already wrote, so it would be interesting if the ED mode simply averages the RSSI over the descrived 128us period (nRF52840 PSv1.1 Page 319)? (though, for the 2Mbit mode the result is less promising)

    The link you posted I already found on my google search and at first look, it completely relies on the SoftDevice which I am not using.

    Mhh the problem for the raw RSSI sampling is that the sampling period (nRF52840 PS_v1.1 Page 359) is 0.25us ( which I cannot change in my opinion), which may be a little bit too short to continuously catch every RSSIEND interrupt and average on my own :-/

    Thank you for your help and BR
    Julian

  • Hi

    When you call the RADIO_TASKS_ED_START register, the energy detect measurement used in IEEE 802.15.4 mode will start. This register is only defined to be used in 802.15.4 modes, so it is not defined what will happen if you call it at any other point. Most likely, nothing will happen, or an error may occur. We strongly suggest using the SoftDevice when developing new BLE applications/projects though, as this is what we here at Nordic has most experience with, and are able to provide support for. Is there a specific reason that you don't want to use the SoftDevice?

    Best regards,

    Simon

  • Hello Simon,

    I understand that it is not defined in the manual that is the reason why I am asking here what really happens during the ED Mode and why it is bounded to the 802.15.4 mode.
    From my experience, no error code appears at the "NRF_RADIO->EDSAMPLE" register. In fact, the value that appears here is quite accurate (after conversion (nRF52840 PSv1.1 Page 329) since I also compared it with the RSSI values for message receptions for the same network.
    These very promising results are the reason why I am asking. With the energy detection mode, I would be able to also measure interference from other devices in the ISM radio band (e.g. 802.11 ) and for example, synchronize on this interference and avoid the occupied time-slots (so not only the occupied channels!) or even localize interfering nodes in the network.

    The problem is the BLE Softdevice stack is not sufficient for our task, in fact, I am only using the BLE physical (PHY) layer and handle the rest by my self (I also do not need support on setting up my own protocol stack this already works perfectly). I work in a research organization on Industrial Wireless Sensor Networks and here I need networks with sufficient time synchronization and more possibilities and insights as a predefined stack would allow me. That is also the reason why we go for the Nordic NRF products because you enable a very good control over the radio features at register level (though more access and documentation is always better ;-) )

    I know that most questions in the forum are concerning the Softdevice and stuff but I hope you can also give support on the lower hardware level. This is also the reason why I search for the aid of the manufacturer since here a simple google search and FAQ cannot help me :-D

    Thanks for your help and sorry for the really "nerdy" low-level hardware questions

    br
    Julian

  • Hi Julian

    Okay, I will forward this question internally, but I can't guarantee that we have a good answer for you I'm afraid.

    There are quite a few problems with using a feature that is not designed for BLE: 

    • It has not been tested or qualified with this PHY layer.
    • It is prone to change between variants/revision due to the above point.
    • We do not have any data of how it might change as temperature and voltage changes.
    • We have no data on how it might change due to other modulations or signal levels, etc.

    I will come back to you when I hear from the experts on the matter, but I'm afraid the support will be very limited here due to our lack of documentation and testing on this matter. The energy detection might very well work in the BLE physical layer, but there are no guarantees that it will, so you would be using this feature on your own risk. I'm sorry I can't be of more help to you...

    Best regards,

    Simon

Related