From 63f8a2aafdc70a31dbe099b38a74e4dc51499508 Mon Sep 17 00:00:00 2001 From: Theo Arends <11044339+arendst@users.noreply.github.com> Date: Thu, 18 Jun 2020 10:18:49 +0200 Subject: [PATCH] Fix ESP32 network checks Fix ESP32 network checks (#8503) --- tasmota/support_rtc.ino | 2 +- tasmota/xdrv_40_telegram.ino | 2 +- tasmota/xdrv_81_webcam.ino | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tasmota/support_rtc.ino b/tasmota/support_rtc.ino index 445976eb3..25ad82435 100644 --- a/tasmota/support_rtc.ino +++ b/tasmota/support_rtc.ino @@ -379,7 +379,7 @@ void RtcSecond(void) Rtc.millis = millis(); if (!Rtc.user_time_entry) { - if (!global_state.wifi_down) { + if (!global_state.network_down) { uint8_t uptime_minute = (uptime / 60) % 60; // 0 .. 59 if ((Rtc.ntp_sync_minute > 59) && (uptime_minute > 2)) { Rtc.ntp_sync_minute = 1; // If sync prepare for a new cycle diff --git a/tasmota/xdrv_40_telegram.ino b/tasmota/xdrv_40_telegram.ino index 97c5aa453..a7beb5005 100644 --- a/tasmota/xdrv_40_telegram.ino +++ b/tasmota/xdrv_40_telegram.ino @@ -322,7 +322,7 @@ String TelegramExecuteCommand(const char *svalue) { } void TelegramLoop(void) { - if (!global_state.wifi_down && (Telegram.recv_enable || Telegram.echo_enable)) { + if (!global_state.network_down && (Telegram.recv_enable || Telegram.echo_enable)) { switch (Telegram.state) { case 0: TelegramInit(); diff --git a/tasmota/xdrv_81_webcam.ino b/tasmota/xdrv_81_webcam.ino index 9cbeb4133..71d81d2ac 100644 --- a/tasmota/xdrv_81_webcam.ino +++ b/tasmota/xdrv_81_webcam.ino @@ -792,7 +792,7 @@ void HandleWebcamRoot(void) { /*********************************************************************************************/ uint32_t WcSetStreamserver(uint32_t flag) { - if (global_state.wifi_down) { return 0; } + if (global_state.network_down) { return 0; } Wc.stream_active = 0;