mirror of
https://github.com/esp8266/Arduino.git
synced 2025-04-19 23:22:16 +03:00
Update ArduinoOTA.cpp
Restarts the UDP port if it becomes disconnected. Works when for example the wifi is disconnected and reconnected
This commit is contained in:
parent
49bc812ccd
commit
46658593b0
@ -51,6 +51,11 @@ void ArduinoOTA::setup() {
|
||||
}
|
||||
|
||||
void ArduinoOTA::handle() {
|
||||
|
||||
if (!*_udp_ota) {
|
||||
_udp_ota->begin(_port);
|
||||
Serial.println(F("OTA restarted"));
|
||||
}
|
||||
|
||||
if (!_udp_ota->parsePacket()) return;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user