This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

bt_le_ext_adv_set_data fails in NCS v1.8.0

I recently updated to nRF Connect SDK v1.8.0 from v1.5.0 and am encountering a new error with the same code. The error occurs when I call bt_le_ext_adv_set_data. My advertising set has 4 elements in it and it only fails if the total number of bytes is greater than 62 bytes. I discovered the 62 byte boundary by adding a printk statement at the end of set_data_add_complete(...) in zephyr/subsys/bluetooth/host/adv.c. Anything 62 bytes or less will advertise just fine but once I go above 62 bytes I get the following warning:

<wrn> bt_hci_core: opcode 0x2037 status 0x07

and the advertisement is empty. This error did not occur with the same code using NCS v1.5.0.

Parents
  • I may have found a solution. Setting CONFIG_BT_CTLR_ADV_DATA_LEN_MAX to a higher value in my prj.conf file seems to have fixed this issue.

    Are there any side effects of this solution to consider? Or does this simply increase the size of the buffer set aside for advertising data?

  • I'm very curious now. I have exactly the same problem with V1.8.0 although using Coded PHY. I tried standard PHY using your suggestion which didn't work. I'm suspecting there is a difference in prj.conf, would you mind sharing the settings you are using please ?

  • Coded phy runs at 125 kbps by taking the symbols at 1 Mbps and adding redundancy to achieve longer range and/or lower power. Regular extended advertising uses 2 Mbps, so it's likely that the data length for coded phy needs to be much lower than extended advertising without coded phy.

    I believe the settings from my prj.conf file that matter here are:

    CONFIG_BT_EXT_ADV=y
    CONFIG_BT_PERIPHERAL=y
    CONFIG_BT_CTLR_ADV_DATA_LEN_MAX=128

Reply
  • Coded phy runs at 125 kbps by taking the symbols at 1 Mbps and adding redundancy to achieve longer range and/or lower power. Regular extended advertising uses 2 Mbps, so it's likely that the data length for coded phy needs to be much lower than extended advertising without coded phy.

    I believe the settings from my prj.conf file that matter here are:

    CONFIG_BT_EXT_ADV=y
    CONFIG_BT_PERIPHERAL=y
    CONFIG_BT_CTLR_ADV_DATA_LEN_MAX=128

Children
No Data
Related