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

Coded PHY Advertising on nRF Connect SDK

Hey All,

I ran into an issue on the nRF Connect SDK trying to get a nRF52840 advertising using CODED PHY. I figure it's not fully implemented yet are there any updates on timeline for that? I also posted a bug in the Zephyr repo.

Describe the bug
BLE advertising failed to start on a nRF52840 when enabling BT_LE_ADV_OPT_EXT_ADV.

[00:00:00.002,960] <inf> ble_m: BLE Stack Ready!
[00:00:00.002,960] <inf> ble_peripheral: Bluetooth initialized
[00:00:00.002,960] <err> ble_peripheral: Advertising failed to start (err -22)

To Reproduce

  1. Choose any BLE example
  2. Use a compatible board like nrf52840dk_nrf52840
  3. Add CONFIG_BT_EXT_ADV=y to your prj.conf
  4. When initializing struct bt_le_adv_param *adv_param = add these two flags BT_LE_ADV_OPT_CODED | BT_LE_ADV_OPT_EXT_ADV

Looks like this:


struct bt_le_adv_param *adv_param = BT_LE_ADV_PARAM(BT_LE_ADV_OPT_CONNECTABLE | BT_LE_ADV_OPT_ONE_TIME | BT_LE_ADV_OPT_CODED | BT_LE_ADV_OPT_EXT_ADV, BT_GAP_ADV_FAST_INT_MIN_2, BT_GAP_ADV_FAST_INT_MAX_2, NULL);


For instance, if I used the throughput example in the SDK and try to set BT_LE_ADV_OPT_CODED | BT_LE_ADV_OPT_EXT_ADV as some of the parameters it always return -22. Looking further into it, it appears that CODED PHY advertising is (purposefully?) disabled in valid_adv_param.

Any insight is appreciated!

Parents Reply Children
Related