Hi
Can anybody recommend any library for async Websocket client? I know async websocket server (as a part of AsyncWebServer) and I know a Websockets library with client implementation (https://github.com/Links2004/arduinoWebSockets) but it is require a loop, but I'm trying to avoid using a loop and switch to the async callbacks/events.
Async Websocket client
-
- Posts: 6
- Joined: Sun Apr 23, 2023 10:19 am
Re: Async Websocket client
This module is a websocket server. I'm looking for Websocket client for Arduino platform. I don't want to work wit ESP_IDF.
-
- Posts: 826
- Joined: Mon Jul 22, 2019 3:20 pm
Re: Async Websocket client
AsyncWebserver is a polling loop under the covers, so your request is pretty meaningless.
Any async process is going to be prone to race conditions and tight timing windows. These are best solved with the FreeRTOS mutex and queue methods (https://github.com/espressif/arduino-es ... s/FreeRTOS). AsyncWebserver websockets has worked well for me and many others.
Any async process is going to be prone to race conditions and tight timing windows. These are best solved with the FreeRTOS mutex and queue methods (https://github.com/espressif/arduino-es ... s/FreeRTOS). AsyncWebserver websockets has worked well for me and many others.
-
- Posts: 6
- Joined: Sun Apr 23, 2023 10:19 am
Re: Async Websocket client
Sure, I understand, that websocket has a loop under cover. It is ok, but I would like to work with this high-level "cover" to avoid any low-level work which requires a lot of effort. The same as we are using Arduino-ESP32 framework which has FreeRTOS+ESP-IDF under cover (which also has a machine codes under cover).
Who is online
Users browsing this forum: No registered users and 70 guests