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

More efficient way to change 'manufacturer data' in advertising packet?

Is it possible through the API/Softdevice to do one of the following:

  • read out the current advertising data structure, change a the manufacturing data field, and write back; or

  • only change the manufacturing data field directly

Currently I'm using something very close to advertising_init and that seems inefficient.

  • Hi there,

    If you mean partially modifying the advertisement data without having to copy the unmodified bytes again, then I'm sorry to say that it is not possible.

    This is because at the lowest level, the only SoftDevice API call to modify the advertisement data is:

    sd_ble_gap_adv_data_set()

    And unfortunately that requires you to set the complete adv or scan response packet (although you can modify one of the two without disturbing the other one).

    EDIT: Your remark however makes a lot of sense, so I will log it internally and maybe one day the API will support partial modification of adv data.

    Regards,

    Carles

Related