diff options
| author | danicampora | 2015-02-25 11:08:51 +0100 |
|---|---|---|
| committer | danicampora | 2015-02-25 11:37:29 +0100 |
| commit | 11aa6ba456287d6c80598a7ebbebd2887ce8f5a2 (patch) | |
| tree | 82591ae3cdf59ebeca2d4b8df8f129a201198f79 /cc3200/simplelink | |
| parent | fe2eb5f58a92c35e7c35da8853abb195fd30969a (diff) | |
cc3200: Add WDT functionality as part of the pyb module.
Also improve pybsd, and make it save it's pin configuration.
This is a necessary step towards supporting the CC3200 low
power deep sleep (LPDS) mode.
Diffstat (limited to 'cc3200/simplelink')
| -rw-r--r-- | cc3200/simplelink/oslib/osi_freertos.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/cc3200/simplelink/oslib/osi_freertos.c b/cc3200/simplelink/oslib/osi_freertos.c index 8684d8f5d..93b5bb439 100644 --- a/cc3200/simplelink/oslib/osi_freertos.c +++ b/cc3200/simplelink/oslib/osi_freertos.c @@ -50,6 +50,7 @@ #include "rom_map.h" #include "inc/hw_types.h" #include "interrupt.h" +#include "pybwdt.h" portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE; //Local function definition @@ -59,7 +60,7 @@ QueueHandle_t xSimpleLinkSpawnQueue = NULL; TaskHandle_t xSimpleLinkSpawnTaskHndl = NULL; // Queue size #define slQUEUE_SIZE ( 3 ) - +#define SL_SPAWN_MAX_WAIT_MS ( 200 ) /*! \brief This function registers an interrupt in NVIC table @@ -494,11 +495,13 @@ void vSimpleLinkSpawnTask(void *pvParameters) for(;;) { - ret = xQueueReceive( xSimpleLinkSpawnQueue, &Msg, portMAX_DELAY ); + ret = xQueueReceive( xSimpleLinkSpawnQueue, &Msg, SL_SPAWN_MAX_WAIT_MS); if(ret == pdPASS) { Msg.pEntry(Msg.pValue); } + // set the alive flag for the wdt + pybwdt_sl_alive(); } } |
