Topic: Problems compiling openhivescale_v4.8.ino

Hi,
I tried to play around with the openhivescale_v4.8.ino and then I want to compile it.
During this process I got the following error messages:

_________________________________________________________________________________________
error: 'IPAddress' was not declared in this scope

unsigned long sendNTPpacket(IPAddress& address, WiFiUDP udp)

                             ^_time:256:40: error: 'address' was not declared in this scope

unsigned long sendNTPpacket(IPAddress& address, WiFiUDP udp)

                                        ^

_time:256:49: error: 'WiFiUDP' was not declared in this scope

unsigned long sendNTPpacket(IPAddress& address, WiFiUDP udp)

                                                 ^

_time:256:60: error: expression list treated as compound expression in initializer [-fpermissive]

unsigned long sendNTPpacket(IPAddress& address, WiFiUDP udp)

                                                            ^

_time:305:25: error: variable or field 'GetNTPConfigureRTC' declared void

void GetNTPConfigureRTC(IPAddress& timeServerIP) {

                         ^

_time:305:25: error: 'IPAddress' was not declared in this scope

_time:305:36: error: 'timeServerIP' was not declared in this scope

void GetNTPConfigureRTC(IPAddress& timeServerIP) {

                                    ^

modem:4:39: error: 'File' has not been declared

void modemSendCommand(String command, File logfile) {

                                       ^

modem:18:36: error: 'File' has not been declared

String modemGetAnswer(int timeout, File logfile) {

                                    ^

In file included from C:\Users\vornk\Documents\Arduino\openhivescale_v4.8\openhivescale_v4.8.ino:11:0:

debug.h:7:53: error: 'void debug(String, bool)' was declared 'extern' and later 'static' [-fpermissive]

static void debug(String text, bool sameLine = false);

                                                     ^

debug:8:6: error: previous declaration of 'void debug(String, bool)' [-fpermissive]

void debug(String text, bool sameLine) {

      ^

In file included from C:\Users\vornk\Documents\Arduino\openhivescale_v4.8\openhivescale_v4.8.ino:11:0:

debug.h:8:54: error: 'void debug(int, bool)' was declared 'extern' and later 'static' [-fpermissive]

static void debug(int intInput, bool sameLine = false);

                                                      ^

debug:30:6: error: previous declaration of 'void debug(int, bool)' [-fpermissive]

void debug(int intInput, bool sameLine) {

      ^

In file included from C:\Users\vornk\Documents\Arduino\openhivescale_v4.8\openhivescale_v4.8.ino:12:0:

telnet.h:11:26: error: 'void telnetHandle()' was declared 'extern' and later 'static' [-fpermissive]

static void telnetHandle();

                          ^

telnet:4:6: error: previous declaration of 'void telnetHandle()' [-fpermissive]

void telnetHandle() {

      ^

In file included from C:\Users\vornk\Documents\Arduino\openhivescale_v4.8\openhivescale_v4.8.ino:13:0:

_time.h:39:60: error: 'long unsigned int sendNTPpacket(IPAddress&, WiFiUDP)' redeclared as different kind of symbol

unsigned long sendNTPpacket(IPAddress& address, WiFiUDP udp);

                                                            ^

_time:256:15: error: previous declaration of 'long unsigned int sendNTPpacket'

unsigned long sendNTPpacket(IPAddress& address, WiFiUDP udp)

               ^

C:\Users\vornk\Documents\Arduino\openhivescale_v4.8\_time.ino: In function 'long unsigned int sendNTPpacket(IPAddress&, WiFiUDP)':

_time:256:60: error: 'long unsigned int sendNTPpacket(IPAddress&, WiFiUDP)' redeclared as different kind of symbol

unsigned long sendNTPpacket(IPAddress& address, WiFiUDP udp)

                                                            ^

_time:256:15: error: previous declaration of 'long unsigned int sendNTPpacket'

unsigned long sendNTPpacket(IPAddress& address, WiFiUDP udp)

               ^

C:\Users\vornk\Documents\Arduino\openhivescale_v4.8\_time.ino: In function 'void GetNTPConfigureRTC(IPAddress&)':

_time:322:43: error: 'sendNTPpacket' cannot be used as a function

   sendNTPpacket(timeServerIP, udpNtpClient); // send an NTP packet to a time server

                                           ^

_time:327:45: error: 'sendNTPpacket' cannot be used as a function

     sendNTPpacket(timeServerIP, udpNtpClient);

                                             ^

Bibliothek ESP8266WiFi in Version 1.0 im Ordner: C:\Users\vornk\Documents\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266WiFi  wird verwendet
Bibliothek Wire in Version 1.0 im Ordner: C:\Users\vornk\Documents\Arduino\hardware\esp8266com\esp8266\libraries\Wire  wird verwendet
Bibliothek Time-1.5.0 in Version 1.5 im Ordner: C:\Users\vornk\Documents\Arduino\hardware\esp8266com\esp8266\libraries\Time-1.5.0  wird verwendet
Bibliothek EEPROM in Version 1.0 im Ordner: C:\Users\vornk\Documents\Arduino\hardware\esp8266com\esp8266\libraries\EEPROM  wird verwendet
Bibliothek Ticker in Version 1.0 im Ordner: C:\Users\vornk\Documents\Arduino\hardware\esp8266com\esp8266\libraries\Ticker  wird verwendet
Bibliothek ESP8266WebServer in Version 1.0 im Ordner: C:\Users\vornk\Documents\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266WebServer  wird verwendet
Bibliothek ESP8266HTTPClient in Version 1.1 im Ordner: C:\Users\vornk\Documents\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266HTTPClient  wird verwendet
Bibliothek ESP8266HTTPUpdateServer in Version 1.0 im Ordner: C:\Users\vornk\Documents\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266HTTPUpdateServer  wird verwendet
Bibliothek TinyGsm im Ordner: C:\Users\vornk\Documents\Arduino\hardware\esp8266com\esp8266\libraries\TinyGsm (legacy) wird verwendet
Bibliothek ArduinoHttpClient im Ordner: C:\Users\vornk\Documents\Arduino\hardware\esp8266com\esp8266\libraries\ArduinoHttpClient (legacy) wird verwendet
exit status 1
'IPAddress' was not declared in this scope
_________________________________________________________________________________________

This is in file _time.ino in line 305 (void GetNTPConfigureRTC(IPAddress& timeServerIP) {)

Could you please tell an absolute arduino beginner, where and how I can define the variable IPAdress?

Maybe, I have the wrong version of the Time lib (I use Time-1.5.0)

Thank you

Michael

Re: Problems compiling openhivescale_v4.8.ino

Hello Michael,

First, I was not understanding. Tonight I tried to compile and flash boards from a new computer....
I got the same error than you. So I spent some time to understand.
And I don't really understand why, but it doesn't compile with recent versions of arduino and board extension.

I updated the README with the version I had originally and that is working.

You need to fallback to arduino 1.8.2 and a git version of esp8266 from 5 May 2018, links in the readme.

Tell me if you still have issues to compile.