File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change 2020/* Includes ------------------------------------------------------------------*/
2121#include "stm32_wpan_common.h"
2222
23+ #include <Arduino.h>
24+
2325#include "stm_list.h"
2426#include "shci_tl.h"
2527#include "stm32_def.h"
@@ -250,11 +252,12 @@ static void TlUserEvtReceived(TL_EvtPacket_t *shcievt)
250252/* Weak implementation ----------------------------------------------------------------*/
251253__WEAK void shci_cmd_resp_wait (uint32_t timeout )
252254{
253- (void )timeout ;
254-
255255 CmdRspStatusFlag = SHCI_TL_CMD_RESP_WAIT ;
256- while (CmdRspStatusFlag != SHCI_TL_CMD_RESP_RELEASE );
257-
256+ for (unsigned long start = millis (); (millis () - start ) < timeout ;) {
257+ if (CmdRspStatusFlag == SHCI_TL_CMD_RESP_RELEASE ) {
258+ break ;
259+ }
260+ }
258261 return ;
259262}
260263
You can’t perform that action at this time.
0 commit comments