Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use ESP32's AsyncUDP when ESPALEXA_ASYNC requested #212

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

DeLoachAero
Copy link

When running on an ESP32 and choosing ESPALEXA_ASYNC, this PR changes the UDP implementation to async as well as TCP/web server. This change solves a memory fragmentation issue for ESP32 devices that results in WiFiUdp's parsePacket getting memory allocation errors causing CPU restarts. The async model also fixes the "flush" problem reported in PR#181 dropping packets since the async model delivers all packets it receives even on busy networks.

When running on an ESP32 and choosing ESPALEXA_ASYNC, this PR changes the UDP implementation to async as well as TCP/web server.  This change solves a memory fragmentation issue for ESP32 devices that results in WiFiUdp's parsePacket getting memory allocation errors causing CPU restarts. The async model also fixes the "flush" problem reported in PR#181 dropping packets since the async model delivers all packets it receives even on busy networks.
Fix debug buffer dump overflow and tweak debugging output
Added an option for subnet filtering to avoid SSDP attack, fixed a light number issue in the state command response, tweaked debugging and added separate define to view all SSDP packet contents to limit debug log spamming.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants