khoih-prog / ESP_WiFiManager

This is an ESP32 / ESP8266 WiFi Connection Manager with fallback web configuration portal. Use this library for configuring ESP32 (including ESP32-S2 and ESP32-C3), ESP8266 modules' WiFi, etc. Credentials at runtime. You can also specify static DNS servers, personalized HostName, fixed or random AP WiFi channel. With examples supporting ArduinoJson
MIT License
371 stars 97 forks source link

Update example ConfigOnDoubleReset.ino to avoid error checking ESP_DoubleResetDetector version #48

Closed Bruce17 closed 3 years ago

Bruce17 commented 3 years ago

Hi,

building the example code throws an error:

error: 'ESP_DOUBLE_RESET_DETECTOR_VERSION' was not declared in this scope
   Serial.println("ESP_DoubleResetDetector Version " + String(ESP_DOUBLE_RESET_DETECTOR_VERSION));

The line printing the double reset dectector version needs to be adjusted to:

Serial.println("ESP_DoubleResetDetector Version " + String(ESP_DOUBLERESETDETECTOR_VERSION));

Environment: IDE: Platform.io Libs:

khoih-prog commented 3 years ago

Thanks for your PR.

The reason for this error is that you're using outdated version of

  1. ESP_DoubleResetDetector as stated in Prerequisites. Current release is arduino-library-badgeGitHub release

Selection_648

In v1.1.0

#define ESP_DOUBLE_RESET_DETECTOR_VERSION       "v1.1.0"

in v1.1.1

#define ESP_DOUBLE_RESET_DETECTOR_VERSION       "ESP_DoubleResetDetector v1.1.1"
#define ESP_DOUBLERESETDETECTOR_VERSION         ESP_DOUBLE_RESET_DETECTOR_VERSION
  1. ESP_WiFiManager. Current release is arduino-library-badgeGitHub release

I'm sorry that the libraries have been updated so fast recently to add features.

So I'll won't merge this PR, but please don't hesitate to create new PRs anytime you see errors in the library.

Best Regards,

Bruce17 commented 3 years ago

Mhh this sound like a valid point. But why is Platform.IO not telling me this?

ESP_WifiManager: image

ESP_DoubleResetDetector: Now my Platform.IO shows the latest version. Very weird though.

Platform.IO seems not to know the newer versions:

Library Manager: Installing khoih-prog/ESP_WiFiManager @ 1.4.1
Warning! Could not find the package with 'khoih-prog/ESP_WiFiManager @ 1.4.1' requirements for your system 'windows_amd64'
Library Manager: Installing khoih-prog/ESP_DoubleResetDetector @ 1.1.1
Warning! Could not find the package with 'khoih-prog/ESP_DoubleResetDetector @ 1.1.1' requirements for your system 'windows_amd64'
khoih-prog commented 3 years ago

PIO is broken somehow recently, and didn't update many of the libraries.

That's why I have to publish the new sets of libraries, but under new khoih.prog author name. Duplication is better than being outdated.

You can check and use the following command to get the latest library version as I'll update manually right after having new release.

pio lib install "khoih.prog/ESP_WiFiManager or pio lib install "khoih.prog/ESP_WifiManager

It's much better that you, from now on, check every PIO lib to see if it's outdated. Then use khoih.prog instead of khoih-prog



You can see the latest v1.4.1 here

khoih.prog/ESP_WiFiManager or khoih.prog/ESP_WifiManager

and v1.1.1 here

khoih.prog/ESP_DoubleResetDetector

but this is still outdated v1.3.0

khoih-prog/ESP_WiFiManager

and outdated v1.0.3

khoih-prog/ESP_DoubleResetDetector



So sorry, but I don't like to waste my time in addressing / solving PIO problem.