I am using AsyncUDP.h. There is one version in the directory AsyncUDP and another in the directory ESP32_Async_UDP. When I use #include <ESP32_Async_UDP/AsyncUDP.h>, the compiler claims there is no such file or directory. When I rename AsyncUDP to AsyncUDPx and use #include <AsyncUDP.h>, the compiler successfully goes to and uses the ESP32_Async_UDP version. This shows the ESP32_Async_UDP version was installed correctly.
Is there a way to direct the compiler to the ESP32_Async_UDP version from the #include line, or do I need to install the correct version in the home directory and use "" at the #include?
Hi @fester225.
Please tell me where you got those libraries. Although there are many libraries in the Arduino Library Manager that contain "AsyncUDP" in their name, none of them have these exact names.
We need to be able to look at the libraries in order to provide effective assistance.
Is there a specific reason why you have both these libraries installed?
I'm not sure I understand what you mean by "home directory" but likely that won't work. We should be able to find a better solution regardless.
I got the files from Github, Arduino-ESP32.
Yes. #include "AsyncUDP.h" works fine when you put a copy of AsyncUDP.h in the directory with the sketch in it..
That is s very vague answer.
I will take a guess that you mean this repository:
If so, it would be weird for you to have actually gotten the libraries from GitHub since the "esp32" boards platform should be installed via the Arduino IDE Boards Manager, according to the installation instructions:
Moving past that, I can see that the "esp32" boards platform does have a bundled library named "AsyncUDP":
However, it does not contain "ESP32_Async_UDP". So I'll ask again: where did you get that library?
Please also answer the other question I asked:
It depends on what you mean by "works fine". Yes, the sketch will compile if it only contains that #include directive and doesn't actually use the library, but it isn't going to do anything more than that for you.
Also, referring to the sketch directory as "the home directory" is very unhelpful. Please make a stronger effort at clearly communicating.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.