android
android copied to clipboard
[Feature request] fixed GPS coordinates based on wifi SSID
Hey folks,
~~I've searched online, and in the issues, and can't find a close enough match, so here goes.~~ This may have been discussed, in slightly different terms and here sorry.
It would be nice if one could specify fixed GPS coordinates based on which Wifi SSID you're connected to. My GPS/Location happens to be really noisy, for reasons unknown; it can jump a few hundred meters while I've been plopped on the couch. My historical data is all over the place, and ultimately, I can't really rely on my reported location.
While the issue clearly has to do with my own circumstances, I wouldn't be surprised others find it useful as well. It would certainly clean up my data, enough to trust it for geo-fencing things, and might also save some battery at the same time.
Perhaps this could be tied to regions, where a region could be either the mapping of a location radius to a name, or mapping an SSID to a set of coordinates.
While no Android expert, seems like a permissions change might not be required, as getting the SSID requires location, which obviously users would have granted.
Anyway, just a thought.
This is a very interesting idea, and I too imagine it would benefit a number of users. Thank you for proposing it.
Agree, it's an interesting idea.
Couple of thoughts off the top of my head:
- SSIDs are not unique. I'd worry about the possiblity of coming across a duplicate network name and having Owntracks then assume that it's at one location when it's actually at another. Might the BSSID be a better selector for such a feature?
- I'd also be concerned about overloading the meaning of the "location" field in the Location message. Currently, it's sort-of assumed that this is a location that has come explicitly from the device. Overloading that field to mean "could be from the device, or it could be set by an app-specific override rule" might cause problems further down the line. I'd be more comfortable if we could explicitly indicate somehow that the value of the location has been derived from proximity to an SSID/BSSID rather than the location services of the device. Maybe a flag, or even a different message type?
SSIDs are not unique
Quite right, good point. I'm afraid it complicates matters indeed. While it's more work, supporting both SSID and BSSID in some fashion might be the winning move.
If I understood correctly, each VLAN has one SSID (name), but can have one BSSID for each of the radios of each access point. In a home setting, we're dealing with handful, at worst, but in an office setting, it could approach hundreds. The challenge would be to input all of them all.
UI wise, it could be relatively simple. Show the current connected SSID, the current GPS coordinates, and a checkbox, "restrict to the following BSSIDs", which enables a textbox where you could paste the list. I tried a BSSID logging app from Google play, but it didn't work as advertised. I'd still be happy to copy paste from my laptop, though. Perhaps obtaining the list of BSSIDs for the current SSID is possible and not an astronomical amount of work; I don't know.
If kept simplistic, one could map a different set of BSSIDs of the same SSID to different locations (eg, cafe chain branch X vs branch Y).
Overloading the meaning of "location"
I can imagine the concern. I haven't looked at the codebase, but I can imagine the location concept gets passed up and down quite a bit in every part, and tacking on the concept of "deduced location" (or something to that effect) wouldn't be trivial.
OTOH, as a starting point, using this feature would require configuration (and therefore opt-in). Users could be warned, and should be able to understand the distinction between reported location vs deduced location. Restricting the feature to the currently connected SSID/BSSID, vs those that are visible would also help in terms of noise/false-positives (eg, you're close enough to be connected, and bothered connecting so probably intentionally at that location).
$0.02