diff --git a/compiled/due/firmware.bin b/compiled/due/firmware.bin new file mode 100755 index 0000000..34b6aed Binary files /dev/null and b/compiled/due/firmware.bin differ diff --git a/compiled/due/uploadOTA.sh b/compiled/due/uploadOTA.sh new file mode 100755 index 0000000..fe93e19 --- /dev/null +++ b/compiled/due/uploadOTA.sh @@ -0,0 +1 @@ +../tools/mac/arduinoOTA -address 192.168.8.56 -port 65280 -username arduino -password password -sketch firmware.bin -b -upload /sketch diff --git a/compiled/tools/mac/arduinoOTA b/compiled/tools/mac/arduinoOTA new file mode 100755 index 0000000..a1e805e Binary files /dev/null and b/compiled/tools/mac/arduinoOTA differ diff --git a/compiled/update_bin.sh b/compiled/update_bin.sh index 961d203..90c86f3 100755 --- a/compiled/update_bin.sh +++ b/compiled/update_bin.sh @@ -1,3 +1,4 @@ +cp ../.pio/build/due/firmware.bin due cp ../.pio/build/controllino/firmware.hex controllino cp ../.pio/build/m5stack/firmware.bin m5stack cp ../.pio/build/mega2560slim-5100/firmware.hex mega2560slim-5100 diff --git a/lighthub/main.cpp b/lighthub/main.cpp index a229f8b..41d4a29 100644 --- a/lighthub/main.cpp +++ b/lighthub/main.cpp @@ -66,7 +66,7 @@ PWM Out */ #include "main.h" - +#include #if defined(OTA) #include #endif @@ -406,16 +406,6 @@ if (WiFi.status() != WL_CONNECTED) } #endif -#ifndef wiz5500 - -#define DHCP_CHECK_RENEW_FAIL 1 -#define DHCP_CHECK_RENEW_OK 2 -#define DHCP_CHECK_REBIND_FAIL 3 -#define DHCP_CHECK_REBIND_OK 4 -#define NO_LINK 5 - -#endif - #if defined(ARDUINO_ARCH_AVR) || defined(__SAM3X8E__) || defined (NRF5) wdt_dis(); @@ -423,9 +413,11 @@ if (WiFi.status() != WL_CONNECTED) { int etherStatus = Ethernet.maintain(); - #ifdef ETHENET_GENERIC + #ifndef Wiz5500 + #define NO_LINK 5 if (Ethernet.linkStatus() == LinkOFF) etherStatus = NO_LINK; #endif + switch (etherStatus) { case NO_LINK: debugSerial<