ccoors / Valeronoi

A WiFi mapping companion app for Valetudo
GNU General Public License v3.0
352 stars 12 forks source link

Only one access point was mapped #23

Closed firstdorsal closed 1 year ago

firstdorsal commented 2 years ago

Hi and thank you for this awesome project!

I just tried it and the map looks beautiful! The problem is that only one wifi access point (repeater) got mapped. (The one next to the robots charging dock) The router as well as the other repeaters (in the same wlan) aren't showing up on the map. Is this expected? Is there any way to map all?

Best, Paul

ccoors commented 2 years ago

Well. If the robot doesn't switch APs then this is to be expected. You could either lower the signal strength so the robot is forced to connect to the other APs or give them all different SSIDs and map them individually.

@Hypfer What about a new method in the WifiConfigurationCapability that runs iw dev wlanX scan and returns a list of all networks including their signal strengths? That would also allow listing all the networks in the UI and simplify connecting. That call would be a bit slow for Valeronoi, but I guess at reduced recording speed it could work.

Hypfer commented 2 years ago

What about a new method in the WifiConfigurationCapability

Nope. Capabilities can either be implemented fully or not at all. If you were to run Valetudo on something that isn't the robot with such an extension, the scan method couldn't work but you'd still want to be able to configure wifi.

I've been thinking about a WifiScanCapability for a while now but I'm not happy with the thought just yet

Edit: I've just remembered that the scan command might occasionally take a few seconds to return which is pretty bad. I don't want REST API requests to take multiple seconds

I did some tests right now and while most of the time it stayed below 2s, a few times I was seeing even more than 20s(!) until the scan finished.

Hypfer commented 2 years ago

https://github.com/Hypfer/Valetudo/commit/86fe2f207c2f050ca7351c21bd736de4f2d5d27b

This could be helpful either way

sburgh01 commented 1 year ago

Hi,

I just recently changed my Robot to Valetudo and used Valeronoi. Looks really good but I also ran in this Issue with changing Wifis and the Map turned out somethign like this in some areas. grafik

since the ssid and bssid is also a part of the already used API call this information could easily be used.

I would like to add this feature, and already tried a bit and think it should be not that diffucult. I am looking forward to implement this as far as i am able to.

But I would like to discuss or know your opinion on the changes/expansion.

So i would like to save the bssid and ssid information as well as the signal value.

To limit the Data usage, I would like to add a seperate List of "known Wifis" and then just refer to a Id for the known Wifis and add this Id to every measured Point. So you can think of a Z axis in the mapped Data for different Wifi Ids which can be resolved to the full ssid and bssid.

To stay compatible with Valetudo versions before 2022.02 (mentioned Commit from Hypfer), I would add a invalid default bssid for a unkown Wifis. So when there is no known BSSID the Signal will be recorded to a default dummy Wifi, and no recorded Data will be lost.

This "unkown Wifi" record can also be used to stay compatible with previously recorded Data. Every opened file from previouse Valeronoi Versions could just be mapped to the unkown Wifi on first load. So we dont loose compatibility with already recorded Data.

On the GUI there could be a List to select and show map for the different known Wifis because all Datapoints could be seperated on that wifi Id.

And later this could be expanded e.g. to show a coverage Map respecting all known Datapoints over multiple Wifis. (somehow combinde the measured points TBD if wanted in annother issue/feautre/PR...) And to look a bit ahead, this could lay the foundation for something like Wifi Scanning, but this is annother point.

So this would be my first contribution on Github, so please dont be to harsh if I am discussing this feature in the wrong Place or missing vital information.

ccoors commented 1 year ago

@sburgh01 Sounds good to me, I guess that is related to the pull request you recently opened? ;)

Don't worry too much about breaking compatibility with older versions of Valetudo, but older save files from Valeronoi should still work.

ccoors commented 1 year ago

Feature added in v0.2.0