Errors compiling ArduinoIoTCloud examples

HELLO,I try to compile the newest ArduinoIoTCloud examples for broad ESP8266, but I get the bellow error. Could anyone tell what is happening please.

Compiling 'ArduinoIoTCloud-Basic' for 'NodeMCU 1.0 (ESP-12E Module)'
 
cborpretty.c: In function hexDump
 
cborpretty.c: 195:32: error: expected ')' before '__INT8
   195 |         err = stream(out, "%02" PRIx8, *buffer++)
   |                                ^
   |                                )
 
cborpretty.c: In function utf8EscapedDump
 
cborpretty.c: 251:39: error: expected ')' before '__INT32
   251 |             err = stream(out, "\\u%04" PRIX32 "\\u%04" PRIX32
   |                                       ^
   |                                       )
 
cborpretty.c: 257:39: error: expected ')' before '__INT32
   257 |             err = stream(out, "\\u%04" PRIX32, uc)
   |                                       ^
   |                                       )
 
cborpretty.c: In function value_to_pretty
 
cborpretty.c: 382:34: error: expected ')' before '__INT64
   382 |             err = stream(out, "%" PRIu64, val)
   |                                  ^
   |                                  )
 
cborpretty.c: 387:39: error: expected ')' before '__INT64
   387 |                 err = stream(out, "-%" PRIu64, val)
   |                                       ^
   |                                       )
 
cborpretty.c: 457:30: error: expected ')' before '__INT64
   457 |         err = stream(out, "%" PRIu64 "%s(", tag, get_indicator(it, flags))
   |                              ^
   |                              )
 
cborpretty.c: 473:37: error: expected ')' before '__INT8
   473 |         err = stream(out, "simple(%" PRIu8 ")", simple_type)
   |                                     ^
   |                                     )
 
cborpretty.c: 531:36: error: expected ')' before '__INT64
   "", ival, suffix)
   |                                    ^
   |                                    )
 
cbortojson.c: In function add_value_metadata
 
cbortojson.c: 297:39: error: expected ')' before '__INT64
   "%" PRIu64 "\"%s", status->lastTag
   |                                       ^
   |                                       )
 
cbortojson.c: 316:40: error: expected ')' before '__INT64
   "%c%" PRIx64 "\"", flags & NumberWasNegative ? - : +
   |                                        ^
   |                                        )
 
cbortojson.c: In function tagged_value_to_json
 
cbortojson.c: 351:35: error: expected ')' before '__INT64
   ", tag) < 0)
   |                                   ^
   |                                   )
 
cbortojson.c: 359:39: error: expected ')' before '__INT64
   {", tag) < 0 ||
   |                                       ^
   |                                       )
 
cbortojson.c: In function value_to_json
 
cbortojson.c: 578:38: error: expected ')' before '__INT8
   578 |         if (fprintf(out, "\"simple(%" PRIu8 ")\"", simple_type) < 0)
   |                                      ^
   |                                      )
 
cbortojson.c: 637:39: error: expected ')' before '__INT64
   "", ival)
   |                                       ^
   |                                       )
Property.cpp:25: note  #pragma message  No RTC available on this architecture - ArduinoIoTCloud will not keep track of local change timestamps
   25 |   #pragma message "No RTC available on this architecture - ArduinoIoTCloud will not keep track of local change timestamps ."
   |                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error compiling libraries
Build failed for project 'ArduinoIoTCloud-Basic'

Hi @djjreal. Unfortunately Arduino IoT Cloud is not compatible with the modern version of the ESP8266 boards platform. The recommended version of that platform for use with Arduino IoT Cloud, which is used by the developers for testing, and is also what is installed in Arduino Cloud, is 2.5.0.

Please do this:

  1. Select Tools > Board > Boards Manager from the Arduino IDE's menus.
  2. Wait for the updates to finish.
  3. Scroll down through the list of boards platforms until you see "esp8266 by ESP8266 Community". Click on it.
  4. From the dropdown version menu, select "2.5.0"
  5. Click the Install button.
  6. Wait for the update to finish.
  7. Click the Close button.

You should now be able to compile sketches using the ArduinoIoTCloud library for the ESP8266.

Hello pert,I get another error after I install the ESP8266-2.5.0.

In file included from sketch\ArduinoIoTCloud-Basic.ino.cpp:1:

C:\Users\Jun\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\cores\esp8266/Arduino.h:270:12: error: 'isinf' has not been declared in 'std'

  270 | using std::isinf;

      |            ^~~~~

C:\Users\Jun\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\cores\esp8266/Arduino.h:271:12: error: 'isnan' has not been declared in 'std'

  271 | using std::isnan;

      |            ^~~~~

exit status 1


I had exactly the same problem as you djjreal to me it got fixed by downgrading to 2.5.0. I did some additional testing and it seems like all of the esp8266 versions below 3.0 works.

EDIT: Version 2.5.0 did trigger the soft WDT (software watchdog timer) all the time rendering the board useless. This was fixed by using version 2.5.1 or above.

See thread: Soft WDT reset on NodeMCU 1.0 when using IoT Cloud

1 Like

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.