-
Notifications
You must be signed in to change notification settings - Fork 672
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
"WIFI roaming" by channel scan (AP switching at low RSSI) #2120
Conversation
general question: |
so the picking of the best AP on startup works also with threshold=0? |
yes, as long the wifi library is working correctly. Also Wifi connect function initiates a wifi scan first (in this case a scan of all channels, then sorting by RSSI and choosing the "best" AP) |
* Activate 802.11kv wifi mesh roaming * Activate roaming by scanning * Revert stack reducation
* Run the Homeassistant Discovery directly after connecting to the broker. Before it was delayed 10s and happened while the first round alredy was in progress * schedule sending HA discovery and static topics * Allow setting QOS for MQTT topics * . * . * change MQTT QOS1 expiration time from (default) 30 to 5s * add logging of heap change on MQTT topic sendings * wait for MQTT transmission timeout after publishing * use QOS0 for Homeassistant Discovery topics. the messages then could possibly get lost but we save a lot of heap * . * use PSRAM for the MQTT outbox * use QOS1 for HA discovery again * . * . * disable delay, not needed with PSRAM * . * consolidated scheduledSendingOf_DiscoveryAndStaticTopics into sendingOf_DiscoveryAndStaticTopics_scheduled * Send Homeasstsiatnt Discovery and static data in MQTT step instead of when the wifi gets connected * "WIFI roaming" by channel scan (AP switching at low RSSI) (#2120) * Activate 802.11kv wifi mesh roaming * Activate roaming by scanning * Revert stack reducation * move Wifi, LWIP and BSSI to PSRAm * added State Class "measurement" to rate_per_time_unit (#2116) Co-authored-by: CaCO3 <caco@ruinelli.ch> * use QOS0 for Homeassistant Discovery topics. the messages then could possibly get lost but we save a lot of heap * use QOS0 for Homeassistant Discovery topics. the messages then could possibly get lost but we save a lot of heap # Conflicts: # code/components/jomjol_mqtt/server_mqtt.cpp # Conflicts: # code/components/jomjol_mqtt/server_mqtt.cpp * . * . * move to next PR * Update code/components/jomjol_mqtt/server_mqtt.cpp * Update code/components/jomjol_mqtt/server_mqtt.cpp --------- Co-authored-by: CaCO3 <caco@ruinelli.ch> Co-authored-by: Slider0007 <115730895+Slider0007@users.noreply.github.com>
Implement a kind of roaming feature #2092 which has less dependencies in terms of capabilities of AP / mesh system and is lightwight to ensure less impact to memory usage of ESP32.
WIFI AP switching by channel scan (simplified "roaming")
Alternative: WIFI roaming 802.11kv --> deactivated by default
NOTE: Fully implemented, but not fully tested (be aware: additional ca. 6-10kB internal heap is consumed to run this feature)
--> The query is only sent when actual RSSI < RSSI Threshold (RSSIThreshold, e.g. -75dBm)
--> The evaluation is only triggered after flow is finished and RSSI < RSSI Threshold every round (The trigger and the neighbour table gets printed with DEBUG level)
--> This does not guarantee that ESP will roam because only a query to AP/mesh is going to be sent. The actual request that ESP needs to roam is still triggered by AP/mesh. If AP/mesh does not see any need to roam, no roam request will sent to ESP and nothing will happen
The info if AP is supporting the roaming features 802.11k and 802.11v will be logged to logfile after wifi connection gets established