Browse Source

wifi: try garp before checking AP, if it is destroyed

master
Max Prokhorov 5 years ago
parent
commit
5622fb8183
1 changed files with 7 additions and 7 deletions
  1. +7
    -7
      code/espurna/wifi.ino

+ 7
- 7
code/espurna/wifi.ino View File

@ -777,6 +777,13 @@ void wifiLoop() {
_wifi_scan_client_id = 0; _wifi_scan_client_id = 0;
} }
// Only send out gra arp when in STA mode
#if WIFI_GRATUITOUS_ARP_SUPPORT
if (_wifi_gratuitous_arp_interval) {
_wifiSendGratuitousArp(_wifi_gratuitous_arp_interval);
}
#endif
// Check if we should disable AP // Check if we should disable AP
static unsigned long last = 0; static unsigned long last = 0;
if (millis() - last > 60000) { if (millis() - last > 60000) {
@ -784,11 +791,4 @@ void wifiLoop() {
_wifiCheckAP(); _wifiCheckAP();
} }
#if WIFI_GRATUITOUS_ARP_SUPPORT
// Only send out gra arp when in STA mode
if (_wifi_gratuitous_arp_interval) {
_wifiSendGratuitousArp(_wifi_gratuitous_arp_interval);
}
#endif
} }

Loading…
Cancel
Save