esp8266: Let machine.WDT trigger the software WDT if obj is not fed.

This patch allows scripts to have more control over the software WDT.  If
an instance of machine.WDT is created then the underlying OS is prevented
from feeding the software WDT, and it is up to the user script to feed it
instead via WDT.feed().  The timeout for this WDT is currently fixed and
will be between 1.6 and 3.2 seconds.
This commit is contained in:
Damien George
2018-07-03 15:31:10 +10:00
parent b6e5f82ba5
commit bccf9d3dcf
3 changed files with 19 additions and 1 deletions

View File

@@ -2,6 +2,7 @@
#define MICROPY_INCLUDED_ESP8266_ETS_ALT_TASK_H
extern int ets_loop_iter_disable;
extern int ets_loop_dont_feed_sw_wdt;
extern uint32_t system_time_high_word;
bool ets_loop_iter(void);