I'm trying to set a public custom BLE mac address to my device but the flag CONFIG_BT_HCI_SET_PUBLIC_ADDR is not enabled. If i try to set it to true on prj.conf file the code doesn't compile anymore. im using nrf connect v.3.0.0.
I'm trying to set a public custom BLE mac address to my device but the flag CONFIG_BT_HCI_SET_PUBLIC_ADDR is not enabled. If i try to set it to true on prj.conf file the code doesn't compile anymore. im using nrf connect v.3.0.0.
Hi,
You can see here: https://docs.nordicsemi.com/bundle/ncs-2.7.0/page/kconfig/index.html#CONFIG_BT_HCI_SET_PUBLIC_ADDR
that this config is not directly user assignable. Please read the above documentation for more details.
I don't think you would need to enable it, rather, you would just need to call bt_ctrl_set_public_addr() before the bt_enable() in order to set the public address.
If the address change is not reflected, then,
Could you try to disable Bluetooth after setting the public address and re-enabling then?
-Priyanka
Using bt_ctrl_set_public_addr() before the bt_enable() is working!
It wasn't necessary to disable and re-enable bluetooth!
Thank you!