We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 5ceaf45 + 870c91e commit 39406aaCopy full SHA for 39406aa
src/utility/HCISharedMemTransport.cpp
@@ -20,6 +20,7 @@
20
21
#include "HCISharedMemTransport.h"
22
#include "STM32Cube_FW/hw.h"
23
+#include "otp.h"
24
25
/* Private variables ---------------------------------------------------------*/
26
PLACE_IN_SECTION("MB_MEM1") ALIGN(4) static TL_CmdPacket_t BleCmdBuffer;
@@ -338,8 +339,13 @@ static bool get_bd_address(uint8_t *bd_addr)
338
339
340
bd_found = true;
341
} else {
- bd_addr = NULL;
342
- bd_found = false;
+ OTP_BT_t *p_otp = (OTP_BT_t *)OTP_Read(0);
343
+ if (p_otp) {
344
+ memcpy(bd_addr, p_otp->bd_address, CONFIG_DATA_PUBADDR_LEN);
345
+ bd_found = true;
346
+ } else {
347
+ bd_found = false;
348
+ }
349
}
350
351
return bd_found;
0 commit comments