Hi,
We have been using me-no-dev's ESPAsyncWebServer very successfully for a couple of years, with arduino-esp32 <= v2.0.11.
I am investigating whether it is possible to replace ESPAsyncWebServer with WebServer on arduino-esp32 v3.0.0 (RC3). I have the WebServer running on both WiFi and ETH (W5500), but I can not find an equivalent for AsyncWebSocket and/or a handler for "/ws"...
Is it possible to replicate AsyncWebSocket with WebServer in arduino-esp32 v3.0.0 ?
I'd be really grateful if someone could point me at some code....
Sincere thanks in advance,
Paul
AsyncWebSocket: is there an equivalent in arduino-esp32 v3.0.0 ?
-
- Posts: 826
- Joined: Mon Jul 22, 2019 3:20 pm
Re: AsyncWebSocket: is there an equivalent in arduino-esp32 v3.0.0 ?
WebServer simply doesn't have that functionality. There are a couple websocket libraries out there, but you can only have one or the other library listening on a port, so you can't service both at the same time. The ESP-IDF http server library does have a websocket server included.
Re: AsyncWebSocket: is there an equivalent in arduino-esp32 v3.0.0 ?
Many thanks lbernstone ,
I've got WebServer and esp_http_server running simultaneously. esp_http_server is only serving the /ws websocket - on port 81. WebServer is doing everything else - on port 80. They seem to be playing very nicely together! I stole most of the websocket code from the ws_echo_server protocol example.
Very best wishes,
Paul
I've got WebServer and esp_http_server running simultaneously. esp_http_server is only serving the /ws websocket - on port 81. WebServer is doing everything else - on port 80. They seem to be playing very nicely together! I stole most of the websocket code from the ws_echo_server protocol example.
Very best wishes,
Paul
Re: AsyncWebSocket: is there an equivalent in arduino-esp32 v3.0.0 ?
I got the webserver and sockets working just using the esp_http_server if your interested.PaulZC wrote: ↑Thu May 23, 2024 6:00 pmI've got WebServer and esp_http_server running simultaneously. esp_http_server is only serving the /ws websocket - on port 81. WebServer is doing everything else - on port 80. They seem to be playing very nicely together! I stole most of the websocket code from the ws_echo_server protocol example.
Re: AsyncWebSocket: is there an equivalent in arduino-esp32 v3.0.0 ?
I’m interested!
Can you please share how you did that?
Thanks in advance
Can you please share how you did that?
Thanks in advance
Who is online
Users browsing this forum: No registered users and 86 guests