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

incorrect SSID and BSSID when using router has multiple SSID configured #23

Open
tmoore22 opened this issue Aug 2, 2024 · 2 comments
Open

Comments

@tmoore22
Copy link

tmoore22 commented Aug 2, 2024

Thanks for a great tool, I was about to write something similar myself.. but then I came across your great works!

I have 3x AP setup with wifi presence.
All AP have dual radio (2.4G + 5G), with primary SSID on both (OpenWrt-SSID#1)
All AP have a second SSID on 2.4G radio for IoT (OpenWrt-SSID#2)
All AP have hostapd-wolfssl installed.

I have configured and working wifi-presence on all 3x AP, but..

When devices that are connected to second SSID (OpenWrt-SSID#2) the attributes in Home Assistant shows the SSID (and BSSID) for the primary (OpenWrt-SSID#1). So there is a discrepancy in which SSID they are connected to!

I have tested this with multiple AP and multiple Wifi clients, with the same result.

@awilliams
Copy link
Owner

Hello, I have a similar setup with multiple APs. In my case, Home Assistant properly shows which of the AP a device is connected to.

A few questions:

  • Are the clients presenting the same MAC address to each AP? Apple devices, for example, have the ability to use multiple MAC addresses for privacy reasons.
  • There is a delay between when a device disconnects from an AP, and when wifi-presence will send the disconnect message. How long are you waiting during your testing after disconnecting from an AP?

@tmoore22
Copy link
Author

tmoore22 commented Sep 18, 2024

Hi, i am using the default config.. nothing special.

  • yes, clients all use same MAC on my main SSID, other SSID is for IoT only and they also retain same MAC.
  • I see the delay in your code and config, and I see its effective.. but it actually causes a race-condition in my setup. let me explain:
  1. Device appears in HA with correct MAC but incorrect SSID
  2. Device roams to another AP
  3. wifi-presence then updates the object in HA with new BSSID but same (incorrect SSID), same MAC
  4. moments later, the delayed disconnection from the other AP makes the object in HA show as disconnected! but its actually connected still the second AP

So, I didnt investigate much more.. its still installed and configured but didnt spend any more time on it yet. (waiting for an update here mostly)

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

No branches or pull requests

2 participants