Chaining - current status

Hallo,

currently I evaluate a few possibilities to transmit larger data portions in a broadcast way, means using several advertising schemes. I have a few nRF52840-DK and use NCS v1.9.1 and Zephyr v2.7.99.

One at least semi-automatic way to handle data portions bigger than what is possible to transmit in a single packet is chaining. According to the standard it should be possible to transmit up to 1650 Bytes, which will be automatically splitted and re-assembled.

In one of the posts (https://devzone.nordicsemi.com/f/nordic-q-a/80022/chained-advertisement-nordic-52832-or-52840-how-to-generate-the-chained-advertisement-with-the-nrf-connect-sdk) I found the statement that chaining was not yet implemented, but "the feature to add more than 255 bytes is still on its way". Since it is more than a year after the statement I would like to know what the current situation is. At least the struct bt_data - used in bt_le_ext_adv_set_data(..) to handle advertising data - still contains a uint8_t variable data_len, which means there is a max size of 255. Therefore I assume that chaining is still not implemented. Is that correct?

Kind regards

Axel

  • Hi Axel, 

    I'm taking over the case from Karl as I have played with chained advertising it a little bit. 

    I'm not so sure about this : 

    axel_s said:
    That leads to the fact that data packets are not conform to the standard anymore

    From my point of view The data packet is still conform to the standard after you merge them together. 

    Could you try testing with my example here. I provided a project at the last reply. 

    In the example I added a counter in every 10 bytes to the array. And send the data as 4 200-byte arrays each in one ad struct.

    If you use a phone that support chained advertising you can capture the data as follow: 

    Note that the nrf Connect app on the phone is a generic app and is not configure to detect the data handling of 200 bytes chunk. It can detect the data structure simply by following the advertising spec/standard. If you click on RAW data, you can see that it has a 0xC9 byte which is the length (201 bytes) before each data structure and then merge them together and send them via the chained advertising packets which has max 255 bytes size. 

    On the receiver side, you can simply follow the spec and use the length byte to parse the advertising data you receive. As you can see it's been done on the phone. 

    So I don't agree with your conclusion that chained advertising doesn't work in our current stack. 

  • Hi Hung Bui,

    thanks for your example. I'm sure I'll be back on that topic soon, but currently there are some more important issues. I'll report my results here.

    Kind regards

    Axel

Related