fix Mega compilation

This commit is contained in:
2019-03-03 16:16:35 +03:00
parent c74575e0e9
commit 23e493097e
3 changed files with 11 additions and 3 deletions

View File

@@ -928,14 +928,14 @@ void cmdFunctionIp(int arg_cnt, char **args)
{ {
IPAddress ip0(0, 0, 0, 0); IPAddress ip0(0, 0, 0, 0);
IPAddress ip; IPAddress ip;
/*
#if defined(ARDUINO_ARCH_AVR) || defined(__SAM3X8E__) || defined(NRF5) #if defined(ARDUINO_ARCH_AVR) || defined(__SAM3X8E__) || defined(NRF5)
DNSClient dns; DNSClient dns;
#define inet_aton(cp, addr) dns.inet_aton(cp, addr) #define inet_aton(cp, addr) dns.inet_aton(cp, addr)
#else #else
#define inet_aton(cp, addr) inet_aton(cp, addr) #define inet_aton(cp, addr) inet_aton(cp, addr)
#endif #endif
*/
switch (arg_cnt) { switch (arg_cnt) {
case 5: case 5:
if (inet_aton(args[4], ip)) saveFlash(OFFSET_MASK, ip); if (inet_aton(args[4], ip)) saveFlash(OFFSET_MASK, ip);

View File

@@ -24,6 +24,7 @@ e-mail anklimov@gmail.com
#define VAR_NAME_VALUE(var) #var "=" VALUE(var) #define VAR_NAME_VALUE(var) #var "=" VALUE(var)
#include <Arduino.h> #include <Arduino.h>
#include <IPAddress.h>
#include "options.h" #include "options.h"
#ifdef WITH_PRINTEX_LIB #ifdef WITH_PRINTEX_LIB
#include "PrintEx.h" #include "PrintEx.h"

View File

@@ -9,7 +9,7 @@
; http://docs.platformio.org/page/projectconf.html ; http://docs.platformio.org/page/projectconf.html
[platformio] [platformio]
src_dir = lighthub src_dir = lighthub
env_default = esp32 env_default = megaatmega2560
;monitor_speed = 115200 ;monitor_speed = 115200
; megaatmega2560 ; megaatmega2560
; megaatmega2560-net ; megaatmega2560-net
@@ -50,6 +50,7 @@ lib_ignore =
DHT sensor library DHT sensor library
DHT sensor library for ESPx DHT sensor library for ESPx
Adafruit Unified Sensor Adafruit Unified Sensor
WebServer
; Adafruit_Sensor ; Adafruit_Sensor
lib_deps = lib_deps =
https://github.com/anklimov/Arduino-Temperature-Control-Library.git https://github.com/anklimov/Arduino-Temperature-Control-Library.git
@@ -130,6 +131,7 @@ lib_ignore =
WifiManager WifiManager
Ethernet3 Ethernet3
NRFFlashStorage NRFFlashStorage
WebServer
lib_deps = lib_deps =
https://github.com/sebnil/DueFlashStorage https://github.com/sebnil/DueFlashStorage
https://github.com/anklimov/Arduino-Temperature-Control-Library.git https://github.com/anklimov/Arduino-Temperature-Control-Library.git
@@ -165,6 +167,7 @@ lib_ignore =
Ethernet3 Ethernet3
HTTPClient HTTPClient
NRFFlashStorage NRFFlashStorage
WebServer
lib_deps = lib_deps =
https://github.com/anklimov/Arduino-Temperature-Control-Library.git https://github.com/anklimov/Arduino-Temperature-Control-Library.git
https://github.com/anklimov/DS2482_OneWire https://github.com/anklimov/DS2482_OneWire
@@ -232,6 +235,7 @@ lib_ignore =
Ethernet3 Ethernet3
Ethernet2 Ethernet2
NRFFlashStorage NRFFlashStorage
WebServer
lib_deps = lib_deps =
https://github.com/anklimov/Arduino-Temperature-Control-Library.git https://github.com/anklimov/Arduino-Temperature-Control-Library.git
https://github.com/anklimov/DS2482_OneWire https://github.com/anklimov/DS2482_OneWire
@@ -268,6 +272,7 @@ lib_ignore =
Ethernet Ethernet
Ethernet3 Ethernet3
NRFFlashStorage NRFFlashStorage
WebServer
lib_deps = lib_deps =
https://github.com/sebnil/DueFlashStorage https://github.com/sebnil/DueFlashStorage
@@ -304,6 +309,7 @@ lib_ignore =
Ethernet3 Ethernet3
Ethernet2 Ethernet2
NRFFlashStorage NRFFlashStorage
WebServer
lib_deps = lib_deps =
https://github.com/anklimov/Arduino-Temperature-Control-Library.git https://github.com/anklimov/Arduino-Temperature-Control-Library.git
https://github.com/anklimov/DS2482_OneWire https://github.com/anklimov/DS2482_OneWire
@@ -348,6 +354,7 @@ lib_ignore =
Artnet Artnet
Ethernet3 Ethernet3
NRFFlashStorage NRFFlashStorage
WebServer
lib_deps = lib_deps =