File tree Expand file tree Collapse file tree 1 file changed +14
-3
lines changed
features/FEATURE_BLE/targets/TARGET_STM Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -311,11 +311,22 @@ class HCIDriver : public cordio::CordioHCIDriver
311
311
randCnt++;
312
312
HciLeRandCmd ();
313
313
} else {
314
- /* last command in sequence; set resetting state and call callback */
315
- tr_debug (" signal_reset_sequence_done\r\n " );
316
- signal_reset_sequence_done ();
314
+ uint8_t addr[6 ] = { 0 };
315
+ memcpy (addr, pMsg, sizeof (addr));
316
+ DM_RAND_ADDR_SET (addr, DM_RAND_ADDR_STATIC);
317
+ // note: will invoke set rand address
318
+ cordio::BLE::deviceInstance ().getGap ().setAddress (
319
+ BLEProtocol::AddressType::RANDOM_STATIC,
320
+ addr
321
+ );
317
322
}
318
323
break ;
324
+
325
+ case HCI_OPCODE_LE_SET_RAND_ADDR:
326
+ /* send next command in sequence */
327
+ signal_reset_sequence_done ();
328
+ break ;
329
+
319
330
default :
320
331
tr_debug (" Complete Event in reset seq with unknown opcode =0x%4X\r\n " , opcode);
321
332
break ;
You can’t perform that action at this time.
0 commit comments