Xinyuan-LilyGO / TTGO_TWatch_Library

MIT License
890 stars 284 forks source link

Failed to compile SimpleWatch in Arduino IDE #162

Closed andyli closed 2 years ago

andyli commented 2 years ago

TTGO_TWatch_Library commit: https://github.com/Xinyuan-LilyGO/TTGO_TWatch_Library/commit/83f59b5f92429307f62bb8ae63078b584771c7ec

Arduino version: 1.8.19

Boards manager installed: esp32 2.0.3-RC1 from https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_dev_index.json

Compilation errors:

...
D:\Documents\Arduino\SimpleWatch\SimpleWatch.ino: In function 'void setupNetwork()':

SimpleWatch:57:21: error: 'SYSTEM_EVENT_STA_DISCONNECTED' is not a member of 'arduino_event_id_t'

     }, WiFiEvent_t::SYSTEM_EVENT_STA_DISCONNECTED);

                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~

SimpleWatch:62:21: error: 'SYSTEM_EVENT_SCAN_DONE' is not a member of 'arduino_event_id_t'

     }, WiFiEvent_t::SYSTEM_EVENT_SCAN_DONE);

                     ^~~~~~~~~~~~~~~~~~~~~~

SimpleWatch:66:21: error: 'SYSTEM_EVENT_STA_CONNECTED' is not a member of 'arduino_event_id_t'

     }, WiFiEvent_t::SYSTEM_EVENT_STA_CONNECTED);

                     ^~~~~~~~~~~~~~~~~~~~~~~~~~

SimpleWatch:70:21: error: 'SYSTEM_EVENT_STA_GOT_IP' is not a member of 'arduino_event_id_t'

     }, WiFiEvent_t::SYSTEM_EVENT_STA_GOT_IP);

                     ^~~~~~~~~~~~~~~~~~~~~~~

Multiple libraries were found for "WiFi.h"

 Used: C:\Users\andy\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.3-RC1\libraries\WiFi

 Not used: C:\Program Files (x86)\Arduino\libraries\WiFi

Multiple libraries were found for "SD.h"

 Used: C:\Users\andy\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.3-RC1\libraries\SD

 Not used: C:\Program Files (x86)\Arduino\libraries\SD

Using library TTGO_TWatch_Library at version 1.4.2 in folder: D:\Documents\Arduino\libraries\TTGO_TWatch_Library 

Using library SPI at version 2.0.0 in folder: C:\Users\andy\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.3-RC1\libraries\SPI 

Using library Ticker at version 2.0.0 in folder: C:\Users\andy\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.3-RC1\libraries\Ticker 

Using library Wire at version 2.0.0 in folder: C:\Users\andy\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.3-RC1\libraries\Wire 

Using library FS at version 2.0.0 in folder: C:\Users\andy\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.3-RC1\libraries\FS 

Using library SPIFFS at version 2.0.0 in folder: C:\Users\andy\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.3-RC1\libraries\SPIFFS 

Using library WiFi at version 2.0.0 in folder: C:\Users\andy\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.3-RC1\libraries\WiFi 

Using library SD at version 2.0.0 in folder: C:\Users\andy\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.3-RC1\libraries\SD 

exit status 1

Compilation log (verbose mode): https://gist.githubusercontent.com/andyli/63b1354f5db9ede3f44acf066a1992b7/raw/b1810e00f9c422172ccea282301a8ebefbb232b6/gistfile1.txt

andyli commented 2 years ago

It compiles and works after I downgraded esp32 from 2.0.3-RC1 to 1.0.6.

LilyGO commented 2 years ago

In the higher version of the ARDUINO-ESP32 library, it needs to be modified here