PRO
mstephens_42
USA
Asked
Hello DJ,
I'm encountering a compilation error while following the tutorial to convert the ESP-32 into an EZ-B, approximately 10:49 into the video. The error seems to be related to the ESP32PWM.cpp
file and involves several undeclared functions and incorrect event identifiers. Below is a screen capture of the error message:
Here is the error message I'm receiving:
C:\Users\mstep\Documents\Arduino\EZ-ESP32\ESP32PWM.cpp: In destructor 'virtual ESP32PWM::~ESP32PWM()':
C:\Users\mstep\Documents\Arduino\EZ-ESP32\ESP32PWM.cpp:50:17: error: 'ledcDetachPin' was not declared in this scope; did you mean 'ledcDetach'?
50 | ledcDetachPin(pin);
| ^~~~~~~~~~~~~
| ledcDetach
The error continues with similar issues, such as:
ledcSetup
not being declared.- Incorrect event identifiers like
SYSTEM_EVENT_WIFI_READY
instead ofWIFI_EVENT_WIFI_READY
. - Ambiguous call of
analogWrite
.
It seems like there might be a mismatch in the function declarations or possibly an issue with the library versions being used. Could you provide any guidance on how to resolve these errors?
Thank you for your assistance!
Hello MStephens, you will find the detailed step-by-step instructions for the ESP32 Doit Dev kit here: https://synthiam.com/Support/Hardware/Esp32-DevKit-v1
In addition, you will find all other available EZB firmware in that link along the left sidebar under the "Compatible Hardware" section in the support.
The issue you'll run into is that the library changes constantly. You're treading into the open-source territory, which is the wild west. People can submit changes because they dislike how something was spelled. That breaks everyone's code moving forward. It's the argument between "what works" vs. "what is esthetically pleasing to the author(s)." Programming stopped being about completing a task and now is a superficial art to programmers, and in the open source community, doubly so. Because of that, updates break everything.
I can take a look for you, but you'd probably have better luck looking at my video and installing the same version of the esp32 library. The newer library probably breaks everything.
This builds but i'm not sure if it works
Link: https://synthiam.com/Firmware/DJs-ESP32-DOIT-DevKit-v1-YGHLAL0K4JE
I updated the firmwares for the ESP to work with the current latest esp32 libraries. i listed the versions because in the future that's the version you'll want to use if you don't find the latest compatible. It's too much work to maintain code bases for open source projects that change a variable name because they don't like it - even though it'll break everyone else's programs. lol