Skip to content

Compiling Error #3

@turgro

Description

@turgro

Hi,

I've tried to compile on IDE 2.3.2 with libraries that you specify but I've got error:

In file included from c:\Users\...\Documents\Arduino\libraries\ESPAsync_WiFiManager\src/ESPAsync_WiFiManager.h:41,
                 from C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h:210,
                 from C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\7-Segment-LED-Clock.ino:29:
c:\Users\...\Documents\Arduino\libraries\ESPAsync_WiFiManager\src/ESPAsync_WiFiManager.hpp:222:10: fatal error: ESPAsyncDNSServer.h: No such file or directory
  222 | #include <ESPAsyncDNSServer.h>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
exit status 1

So, I manually install ESP_AsynsDNSServer, I've got other error
And if I comment this include from line 222 in file mention above, I've got the same error as below

In file included from c:\Users\...\Documents\Arduino\libraries\FastLED\src/FastLED.h:67,
                 from C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\7-Segment-LED-Clock.ino:24:
c:\Users\...\Documents\Arduino\libraries\FastLED\src/fastspi.h:145:23: note: '#pragma message: No hardware SPI pins defined.  All SPI access will default to bitbanged output'
  145 | #      pragma message "No hardware SPI pins defined.  All SPI access will default to bitbanged output"
      |                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h:148,
                 from C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\7-Segment-LED-Clock.ino:29:
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h: In constructor 'DoubleResetDetector::DoubleResetDetector(int, int)':
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:120:29: error: 'LittleFS' was not declared in this scope
  120 |       #define FileFS        LittleFS
      |                             ^~~~~~~~
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:175:12: note: in expansion of macro 'FileFS'
  175 |       if (!FileFS.begin())
      |            ^~~~~~
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h: In member function 'bool DoubleResetDetector::detectRecentlyResetFlag()':
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:120:29: error: 'LittleFS' was not declared in this scope
  120 |       #define FileFS        LittleFS
      |                             ^~~~~~~~
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:268:11: note: in expansion of macro 'FileFS'
  268 |       if (FileFS.exists(DRD_FILENAME))
      |           ^~~~~~
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h: In member function 'void DoubleResetDetector::setRecentlyResetFlag()':
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:120:29: error: 'LittleFS' was not declared in this scope
  120 |       #define FileFS        LittleFS
      |                             ^~~~~~~~
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:324:19: note: in expansion of macro 'FileFS'
  324 |       File file = FileFS.open(DRD_FILENAME, "w");
      |                   ^~~~~~
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h: In member function 'void DoubleResetDetector::clearRecentlyResetFlag()':
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:120:29: error: 'LittleFS' was not declared in this scope
  120 |       #define FileFS        LittleFS
      |                             ^~~~~~~~
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:370:19: note: in expansion of macro 'FileFS'
  370 |       File file = FileFS.open(DRD_FILENAME, "w");
      |                   ^~~~~~
In file included from c:\Users\...\Documents\Arduino\libraries\ESPAsync_WiFiManager\src/ESPAsync_WiFiManager.h:42,
                 from C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h:210:
c:\Users\...\Documents\Arduino\libraries\ESPAsync_WiFiManager\src/ESPAsync_WiFiManager-Impl.h: In member function 'void ESPAsync_WiFiManager::setupConfigPortal()':
c:\Users\...\Documents\Arduino\libraries\ESPAsync_WiFiManager\src/ESPAsync_WiFiManager-Impl.h:355:12: error: 'class WiFiClass' has no member named 'getAutoConnect'; did you mean 'getAutoReconnect'?
  355 |   if (WiFi.getAutoConnect() == 0)
      |            ^~~~~~~~~~~~~~
      |            getAutoReconnect
c:\Users\...\Documents\Arduino\libraries\ESPAsync_WiFiManager\src/ESPAsync_WiFiManager-Impl.h:356:10: error: 'class WiFiClass' has no member named 'setAutoConnect'; did you mean 'setAutoReconnect'?
  356 |     WiFi.setAutoConnect(1);
      |          ^~~~~~~~~~~~~~
      |          setAutoReconnect
C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h: In function 'bool loadConfigData()':
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:120:29: error: 'LittleFS' was not declared in this scope
  120 |       #define FileFS        LittleFS
      |                             ^~~~~~~~
C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h:421:15: note: in expansion of macro 'FileFS'
  421 |   File file = FileFS.open(CONFIG_FILENAME, "r");
      |               ^~~~~~
C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h: In function 'void saveConfigData()':
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:120:29: error: 'LittleFS' was not declared in this scope
  120 |       #define FileFS        LittleFS
      |                             ^~~~~~~~
C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h:452:15: note: in expansion of macro 'FileFS'
  452 |   File file = FileFS.open(CONFIG_FILENAME, "w");
      |               ^~~~~~
C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h: In function 'void initEspAsyncWiFiManager()':
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:120:29: error: 'LittleFS' was not declared in this scope
  120 |       #define FileFS        LittleFS
      |                             ^~~~~~~~
C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h:489:5: note: in expansion of macro 'FileFS'
  489 |     FileFS.format();
      |     ^~~~~~
c:\Users\...\Documents\Arduino\libraries\ESP_DoubleResetDetector\src/ESP_DoubleResetDetector.h:120:29: error: 'LittleFS' was not declared in this scope
  120 |       #define FileFS        LittleFS
      |                             ^~~~~~~~
C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h:492:8: note: in expansion of macro 'FileFS'
  492 |   if (!FileFS.begin(true)) {
      |        ^~~~~~
C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h:530:3: error: 'DNSServer' was not declared in this scope; did you mean 'webServer'?
  530 |   DNSServer dnsServer;
      |   ^~~~~~~~~
      |   webServer
C:\Users\...\Downloads\STL\Zegarek ESP - LED\7-Segment-LED-Clock-main-Printables-68013\7-Segment-LED-Clock\ESPAsync_WiFiManager_DRD.h:532:58: error: 'dnsServer' was not declared in this scope; did you mean 'webServer'?
  532 |   ESPAsync_WiFiManager ESPAsync_wifiManager(&webServer, &dnsServer, "AsyncConfigOnDoubleReset");
      |                                                          ^~~~~~~~~
      |                                                          webServer
Multiple libraries were found for "WiFiClient.h"
  Used: C:\Users\...\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.2.0\libraries\WiFi
  Not used: C:\Users\...\Documents\Arduino\libraries\WiFi101
exit status 1

Compilation error: 'DNSServer' was not declared in this scope; did you mean 'webServer'?

And Stuck.
I tryed many programs to run my new clock based on ESP8266 or ESP32 but ever of them is old and not working :(

Update a few hours later.
With help Chat GPT I was manage to correct DNS Server by changing in file ESPAsync_WiFiManager_DRD.h
DNSServer dnsServer;
to
AsyncDNSServer dnsServer;

And this worked.
Other thing that GPT helped was in file ESPAsync_WiFiManager-Impl.h changing WiFi.getAutoConnect() and WiFi.setAutoConnect() to WiFi.getAutoReconnect() and WiFi.setAutoReconnect()

Also I removed WiFi101 from libraries folder, and this works, but still have errors LittleFS

I've tried on IDE 1.8.18 and got the same result.

Help

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is needed

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions