From 5dd3d0369998d1d178d4b6860e7a94466647bfe8 Mon Sep 17 00:00:00 2001 From: Simon Duquennoy Date: Fri, 23 Sep 2016 09:07:58 +0200 Subject: [PATCH] cc1200: call watchdog_periodic while in busy-wait --- dev/cc1200/cc1200.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dev/cc1200/cc1200.c b/dev/cc1200/cc1200.c index 6e766855a..6cb1d1be6 100644 --- a/dev/cc1200/cc1200.c +++ b/dev/cc1200/cc1200.c @@ -40,6 +40,7 @@ #include "net/netstack.h" #include "net/packetbuf.h" #include "net/rime/rimestats.h" +#include "dev/watchdog.h" #include "dev/leds.h" @@ -289,7 +290,9 @@ extern const cc1200_rf_cfg_t CC1200_RF_CFG; do { \ rtimer_clock_t t0; \ t0 = RTIMER_NOW(); \ - while(!(cond) && RTIMER_CLOCK_LT(RTIMER_NOW(), t0 + (max_time))) {} \ + while(!(cond) && RTIMER_CLOCK_LT(RTIMER_NOW(), t0 + (max_time))) { \ + watchdog_periodic(); \ + } \ } while(0) /*---------------------------------------------------------------------------*/ #if CC1200_USE_GPIO2