1.1.2.1.1.4.43 BLE_GAP_SetDeviceAddr

C

uint16_t BLE_GAP_SetDeviceAddr(BLE_GAP_Addr_T *p_addr);

Description

Set the Bluetooth device address (identity address). Type of address must be BLE_GAP_ADDR_TYPE_PUBLIC or BLE_GAP_ADDR_TYPE_RANDOM_STATIC. The address identifies the device to other Bluetooth devices.

Note

The default IRK would be changed automatically if Bluetooth device address is revised.

Parameters

ParameterDescription
[in] p_addrPointer to the device address buffer.

Return values

Return valueDescription
MBA_RES_SUCCESSSuccessfully set the device address.
MBA_RES_FAILFail to set device addr. Some types of address can be set by application.
MBA_RES_OOMInternal memory allocation failure.