-
Notifications
You must be signed in to change notification settings - Fork 325
gluon-core: distribute dualband radios #1606
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
Conversation
eeab671
to
539e1b1
Compare
i just tested a single-band 2.4GHz device (vocore2) and your changes didn't have any effect (so like it should be) |
8153e22
to
43b6d64
Compare
I moved the band distribution to the initial setup. This way, the band selection is only done on first bootup, allowing a user to change the frequency band of the radio themselves afterwards. Also fixed a bug which caused ac radios not to be detected as 5GHz. |
This commit distributes dualband radios evenly on 2.4 GHz and 5GHz with 2.4 GHz being prioritised higher than 5 GHz. This means in case a device has only a single radio and this radio supports operation in both bands, it will be set to 2.4 GHz. Tested-by: Martin Weinelt <martin@darmstadt.freifunk.net> Signed-off-by: David Bauer <mail@david-bauer.net>
43b6d64
to
16e4080
Compare
-- Dualband - do nothing in this step | ||
elseif hwmodes.g then | ||
-- 2.4 GHz | ||
radio_band_count["band24"] = radio_band_count["band24"] + 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, we could use this code and clean up legacy hwmode values '11ng' and '11na' (that we have to handle in multiple places otherwise). How about using the strings '11n' and '11a' as map keys in radio_band_count - the increment + uci:set could be refactored into a local function that way, where only radio_name and one of these two strings need to be passed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, or not. At least when guarded by if not sysconfig.gluon_version then
, this will obviously not help with upgrading legacy configurations...
This commit distributes dualband radios evenly on 2.4 GHz and 5GHz with 2.4 GHz being prioritised higher than 5 GHz. This means in case a device has only a single radio and this radio supports operation in both bands, it will be set to 2.4 GHz. Tested-by: Martin Weinelt <martin@darmstadt.freifunk.net> Signed-off-by: David Bauer <mail@david-bauer.net>
This commit distributes dualband radios evenly on 2.4 GHz and 5GHz with 2.4 GHz being prioritised higher than 5 GHz. This means in case a device has only a single radio and this radio supports operation in both bands, it will be set to 2.4 GHz. Tested-by: Martin Weinelt <martin@darmstadt.freifunk.net> Signed-off-by: David Bauer <mail@david-bauer.net>
This commit distributes dualband radios evenly on 2.4 GHz and 5GHz with 2.4 GHz being prioritised higher than 5 GHz. This means in case a device has only a single radio and this radio supports operation in both bands, it will be set to 2.4 GHz. Tested-by: Martin Weinelt <martin@darmstadt.freifunk.net> Signed-off-by: David Bauer <mail@david-bauer.net>
This commit distributes dualband radios evenly on 2.4 GHz and 5GHz with 2.4 GHz being prioritised higher than 5 GHz.
This means in case a device has only a single radio and this radio supports operation in both bands, it will be set to 2.4 GHz.
#1604 depends on this PR