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

control notifications in connection event

Hello all, my question is related to notifications and to maximize data bandwidth using them; First af all i have already read this: devzone.nordicsemi.com/.../ but it is not enough for my situation;

In my scenario, i have a nRF51822 device which needs to update some characteristics at high frequencies (up to 100Hz) by using notifications; each characteristic is optimized to be 20 bytes long in order to take advantage of all the data payload available for each notification;

In one of my use-case i need to update togheter 4 characteristics at 100Hz frequency, so on the nRF51822 side the firmware updates at the same time (with 4 consecutive calls to sd_ble_gatts_hvx specifically timed at 100Hz) the 4 characteristics to be notified with a connection interval previously set to 10ms; My problem is that it seems (by executing some debug and checking the TX_COMPLETE event, reading the number of packets transmitted each time) that on each connection event the number of packets transmitted is not always 4 as i was expecting (1 packet for each notification requested), and i see a similar problem also when transmitting 3 characteristics instead of 4; So, considering the fact that the nRF51822 can send up to 6 packets per connection event, this behaviour seems strange to me; this can be a normal behaviour of the S110 stack or there can be a problem? Is there a way (standard coding or some sort of "hack") to force the nRF51822 to send a X number of notifications (so packets) on each connection event?

The peer device used for these tests is an android smartphone at a very short distance to avoid re-transmission problems (one time a Motorola MotoG 2gen 4.4.4 and another time a Nexus5 5.0 with similar results - the Nexus5 seems to allow a slightly greater number of packets transmitted than the MotoG)

Thanks to all in advance

UPDATE 1: I have executed other tests with a slightly different configuration in order to know more of this problem: connection interval: 7.5ms; slave interval: 500ms; With a timer each 400ms are updated 5 different characteristics togheter (with 5 consecutive calls to sd_ble_gatts_hvx);

Then, by checking the TX_COMPLETE event continuously (reading the number of packets transmitted and timings between them) i can see these results:

  • with MotoG 4.4.4, most of the time are needed 3 consecutive connection events to transmit the 5 notification packets with the scheme 2-2-1 (packets each connection event), while sometimes are enough 2 connection events with the scheme 3-2 (packets each connection event);
  • with Nexus5 5.0, most of the time are needed 3 consecutive connection events to transmit the 5 notification packets with the scheme 3-1-1 and sometimes 2 connection events; sporadically i have seen also 4 packets in one single connection event;

Do you think is a Central problem that can't accept more packets in each connection event? Or could be the S110 stack which doesn't try to send all the queued notifications (up to 6 for 6 packets) togheter within the first available connection event?

Parents
  • Hi

    I highly suspect that the throughput limitation is on the central side, i.e. limitation is on the phone side. Android phones have different throughput capabilities, see this thread. Android phones also support different minimum connection interval.

    IOS 8 devices can however receive 6 packets per connection interval, but have minimum connection interval of ~20ms.

    Also, if you have additional nRF51-Dongle or nRF51-DK board then you can connect to the peripheral with the Master Control Panel via the dongle/DK and the master emulator firmware 0.11. You can program the master emulator firmware 0.11 to the dongle/DK with Master Control Panel. The Master Control Panel supports 7.5ms connection interval.

  • I read that thread and i know that could be limitations due to smartphone hardwares, in this case i want to be sure if this problem depends from the central side;

    i am sure that the connection interval set is right (10 ms) because i have checked the parameters of the BLE_GAP_EVT_CONN_PARAM_UPDATE event after having requested the connection parameters update;

    With the Master Control Panel can I test 7.5 ms x 4/6 packets continuous transmission?

    I have also updated the question with results of new tests, please read it, thanks

Reply
  • I read that thread and i know that could be limitations due to smartphone hardwares, in this case i want to be sure if this problem depends from the central side;

    i am sure that the connection interval set is right (10 ms) because i have checked the parameters of the BLE_GAP_EVT_CONN_PARAM_UPDATE event after having requested the connection parameters update;

    With the Master Control Panel can I test 7.5 ms x 4/6 packets continuous transmission?

    I have also updated the question with results of new tests, please read it, thanks

Children
No Data
Related