-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Compiling issues #1410
Comments
This needs guardrails for when to include, but here are the necessary includes
|
Hi lbernstone, I see there are 3 files that needs to be updated. I can update it manually. However, I like to learn how to update it from your given code. What tool should I use for that? It looks similar to some diffs I've seen very long time ago using |
That was a git diff. It was updated with my own 2 hands :) I just looked at what was missing, grep'd for those functions in the arduino-esp32/tools/esp32-arduino-libs/esp32/include folder, and included those files in the correct locations. To make a PR, I need to figure out a way to only include those headers if the version is >3.0.0. |
Oh got it. I knew I will have issues when Arduino popped up something on the lower right corner. Alrighty, I'll make changes to my local. Thank you. |
I add the lines above with the + on them |
I found this:
on h2zero/NimBLE-Arduino#676 (comment), from a comment made by ednieuw. ednieuw says they got this piece of code from the Espressif migration 2.x -> 3.x document. Supposedly, this piece of code makes a library compatible for both ESP32 versions. I hope this helps. Update: I found a file with a piece a code explaining the manipulation of the ESP32 versions better in the Espressif's official repository for Arduino core for the ESP32. A little bit more information can be found in Espressif's Compatibility Guide for ESP32 Arduino Core page |
Just an observation, but in I can confirm that after making the changes above and commenting out this line, it compiles and seems to work fine on an ESP32 dev board. |
Is this already fixed? |
i changed it to printf... dont do that! so maybe ::printf instead of ets_printf? |
I've encountered the same errors as the original poster, and managed to fix them by following @lbernstone 's recommendations for extra #include statements, as well as @jimdgit 's recommendation to comment out line #551 in AsyncWebSocket.cpp. Unfortunately I'm still experiencing a compilation error. Here's the compilation error message:
And here's a simplified form of my code that still creates this error:
I can find the offending lines of code in AsyncWebSynchronization.h, lines 32-35 here:
But I'm not sure what to try next to debug this. Please could you give me some help for what to try next? Arduino Version: 2.3.2 Using library WiFi at version 3.1.0 Mac OS 13.5 |
OK I've made the lock() function in AsyncWebSynchronization.h always return false, by commenting out other lines inside that function. My very basic code is now working. I'll keep an eye out for what I've broken as I build up the complexity of the firmware again. |
A good fix I found and tried with success is to modify the file AsyncWebSynchronization.h using the following steps :
|
This has been fixed by 17a8d44 @c0debreaker please install the latest version of the library from this GitHub repository (make sure you don't install one of the forks which haven't pulled down the fix), then check to see if the bug is fixed. If so, you can close the issue by clicking the "Close issue" button here on the issue web page. |
@per1234 |
I am using version 1.2.9 and esp32 3.1.0 and also getting the issue. |
@PureTek-Innovations this issue is not about |
@misterjtc there is no such version so you must be using one of the forks of the repository. Uninstall that version and then install the library from this repository. You can't install this library via the Arduino Library Manager (#1433). If you are using Arduino IDE, you can install it by the following procedure:
|
I'm getting the errors below. If I remove
#include <ESPAsyncWebServer.h>
and other related code, the compile becomes successful. What did I do someting wrong?and my source code is
The text was updated successfully, but these errors were encountered: