bt_le_per_adv_set_subevent_data

Hi

I'm using the periodic_adv_conn example from SDK 3.0.0. In the request_cb function, the bt_le_per_adv_set_subevent_data function is used to load data for future subevents. However, I found there is a total length limitation that cannot exceed 255 bytes. My question is: isn't the maximum length for each Periodic Synchronization Broadcast packet 255 bytes? I now want to include 130 bytes of data in each subevent broadcast. Because of this total 255-byte limitation, I cannot load the data for several subevents

Thanks
  • subevent_data_params[0].subevent = (request->start + 1) % per_adv_params.num_subevents;

    According to my program here, it should normally be a cyclic filling of data in the order of 0, 1, 2, 3, 4 for sending, and each piece of data should not be empty. However, during actual testing, I found that only the 1 and 4 from request->start contain data. I wonder if this is related to the amount of data the controller requests each time. For example, at certain moments, the controller might need to fill in 3 pieces of data, but I only filled it once, resulting in the controller sending empty data for the subsequent two pieces. I saw this issue mentioned that the amount of data requested by the controller each time needs to be adjusted. Is it that I need to do this?

  • Hi,

    Good point, I did not think of that. It should be OK to make multipe calls then within a callback (if the count in the request callback is 3 you could make 3 calls with one packet each). I have not tested this on my end, though.

Related