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

AN36 and advertising custom and std profiles

I am having the same basic issue that is described here: https://devzone.nordicsemi.com/index.php/setting-advertisement-parameter-s-for-custom-profile

Including the error value (0x7) that is returned. And while this thread goes off on checking returned error values it doesnt really address the OP question. I can get AN36 code to work, as pure custom... and then I can add in a std profile (i.e. "battery") and it worked (i.e. "advertised both, and didnt throw any errors).

I have tried everything I can think of but there is obviously some odd dependency or interference from something else that can cause this error. I have copied over the entire advertising_init routine (and reference to lbs.c/.h) and it errors out as well when it is in my code base with the same 0x7 error code (which is only described in the documentation of "invalid parameter", which is somewhat less than helpful!).

Any ideas about undocumented incompatibilities here???

Chris

Parents
  • It's hard to help without seeing your source code, but one typcial error that may result in an 0x07 error is if your UUID type isn't filled (i.e. if you haven't called sd_uuid_vs_add() before you call ble_advdata_set()).

    If this is not the problem, can you please check whether it is the SDK's ble_advdata module that throws this error, or if it comes from the softdevice itself? As you can see, the SDK provides a ble_advdata.c file which takes the ble_advdata_t struct and translates it into the raw format expected by sd_ble_adv_data_set(). Is the 0x07 error returned by the SDK module or the softdevice function?

Reply
  • It's hard to help without seeing your source code, but one typcial error that may result in an 0x07 error is if your UUID type isn't filled (i.e. if you haven't called sd_uuid_vs_add() before you call ble_advdata_set()).

    If this is not the problem, can you please check whether it is the SDK's ble_advdata module that throws this error, or if it comes from the softdevice itself? As you can see, the SDK provides a ble_advdata.c file which takes the ble_advdata_t struct and translates it into the raw format expected by sd_ble_adv_data_set(). Is the 0x07 error returned by the SDK module or the softdevice function?

Children
No Data
Related