TWDT
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
#include "Logger.h"
|
||||
#include "Config.h"
|
||||
#include <ArduinoJson.h>
|
||||
#include "hal/wdt_hal.h"
|
||||
|
||||
NukiNetworkOpener::NukiNetworkOpener(NukiNetwork* network, Preferences* preferences, char* buffer, size_t bufferSize)
|
||||
: _preferences(preferences),
|
||||
@@ -131,6 +132,11 @@ void NukiNetworkOpener::initialize()
|
||||
|
||||
void NukiNetworkOpener::update()
|
||||
{
|
||||
wdt_hal_context_t rtc_wdt_ctx = RWDT_HAL_CONTEXT_DEFAULT();
|
||||
wdt_hal_write_protect_disable(&rtc_wdt_ctx);
|
||||
wdt_hal_feed(&rtc_wdt_ctx);
|
||||
wdt_hal_write_protect_enable(&rtc_wdt_ctx);
|
||||
|
||||
if(_resetRingStateTs != 0 && espMillis() >= _resetRingStateTs)
|
||||
{
|
||||
_resetRingStateTs = 0;
|
||||
|
||||
Reference in New Issue
Block a user