Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

What is the highest data rate for multiple-piconet sensor network with 12 nodes?

Greetings,

I have 12 sensors each of which is located on an nRF52832 board. I need to collect the sensor data at 50Hz (10 bytes for each sensor).

For some reason I can not connect all 12 sensors to the same central. 

So here is my setup:

12 sensor boards are divided to three groups, each group has 1 master and 3 slaves

3 masters connected to 1 hub board. all sensor data is sent to the hub via notification or notification relay.

desktop/phone connects to the hub board, and receives all sensor data.  (the minimum connection interval at the phone side may be 20ms)

All 12 sensors boards and the hub board use nRF52832 & S132 SoftDevice, implementing a master/slave dual role.

Is this setup feasible ? If yes, what is the best configuration (connection interval, event length, mtu, etc..) to achieve this ?

What can I do to reduce the delay?

Any help is appreciated, thanks a lot!

  • FormerMember
    0 FormerMember

    Yes, the setup you describe, and should work fine. This is how I understand the setup: three groups consisting of one master and three slaves, the master in each group communicates with a hub. The hub is connected to a phone.

    To make the transfer of data most efficient, I would think you could do something like this:

    Each packet of sensor data: 10bytes (data) + 1 byte (sensor Id) = 11 bytes (an example)

    Each group master could transmit sensor data to hub by collecting sensor data from all four sensors, and then transmit all that at  a time. The MTU size should then be set large enough to cover all that data, for instance 44 bytes.

    The MTU size can be changed/set using the GATT module in the SDK.

     

    For the connection between the hub and the phone, I see two different options:

    •  Set the MTU size in this connection to (for example) 3 x 44 bytes  to cover all the data from the sensors each connection event. The drawback of this method is that if something goes wrong during the transmission of this packet, and the packet will have to be re-transmitted (automatically done by the softdevice), it will have to wait until the next connection interval.
      This option requires that the phone supports ATT MTU exchange.
    • Use connection length extension: When using connection length extension, multiple packets can be transmitted per connection interval within the given time frame. With this option, smaller data packets can be transmitted at a time. If transmission of one packet fails, it can be re-transmitted within the same connection interval. The main difference between this option and the one with long MTU is that, if something goes wrong, the phone will receive some sensor data each connection interval, for example 2 out of 3 packets of sensor data.
      This option requires that the phone supports connection event length extension.

    For how to set up this system most efficiently, I would recommend you to carefully read the "Scheduling" chapter in the softdevice specification.

    For easily testing setting of MTU size, you can for example take a look at the example  "Experimental: ATT_MTU Throughput Example "

Related