Hi,
I would like to know if there is a method like sendContent, but for ESPAsyncWebServer instead of the normal (sync) Webserver? I have a project and would like to convert it to use ESPAsyncWebServer.h instead of the normal Webserver.h library, but unfortunately there are many lines webserver.sendContent(...) in there and I don't know with what equivalent function I can replace them when using ESPAsyncWebServer?
webserver.sendContent method equivalent for ESPAsyncWebServer?
-
lbernstone
- Posts: 1132
- Joined: Mon Jul 22, 2019 3:20 pm
Re: webserver.sendContent method equivalent for ESPAsyncWebServer?
There's more than one way to do it. The simplest is to construct your string first, and then use a basic send()
https://github.com/ESP32Async/ESPAsyncW ... ng-content
https://github.com/ESP32Async/ESPAsyncW ... ng-content
Re: webserver.sendContent method equivalent for ESPAsyncWebServer?
What if the message is so large that it doesnt fit in the RAM of the ESP?
-
lbernstone
- Posts: 1132
- Joined: Mon Jul 22, 2019 3:20 pm
Re: webserver.sendContent method equivalent for ESPAsyncWebServer?
Please read the documentation. It explains how to send data from a stream or a file.
Who is online
Users browsing this forum: Google [Bot], Qwantbot and 2 guests