PI-3B install - how to set WIFI regulatory domain?

HI All

Is there no way to set (and persist) the wireless regulatory domain in OSMC for the Pi 3B ?

I have no option but to operate on wifi channel 13 as the Wifi is provided as part of the serviced
apartment deal at my current dwelling. There is no ethernet connection in the place i can access. All the APs are in the apartment corridors and their connection points are recessed into the ceiling behind the units

I can see the wifi option in MyOSMC and I can see the low channel APs from other buildings ,but the one I need to access happens to be on 13 . spoke to the IT guy , completely see his rationale and why he cant change things to suit “just me” (hes done a proper job - frequency plan - lock mac to AP etc to ensure no one AP gets overloaded)

If not I guess I have to go back to the dark side running kodi under raspbian :-/

Thanks in advance

big bloke

Install crda sudo apt-get install crda and then you can use sudo iw set <COUNTRY CODE>

Thanks - here sadly I have no ethernet I can install from at all not even a laptop with one - its wireless or nothing

incidentally I thought "iw reg set " is not persisted at boot ? so I would need to:

start OSMC
exit with escape to the shell
login
run the command
start OSMC again manually (how do you re-enter OSMC from shell without rebooting ?)

which kind of spoils the whole OSMC “turnkey” experience for me.

I will park it for now until I move somewhere more permanent, or until I visit
my family back home in a few months time.

Many thanks again

Big Bloke

Based on my experience it is permanent

osmc@dalek:~$ sudo systemctl status systemd-udevd.service
● systemd-udevd.service - udev Kernel Device Manager
   Loaded: loaded (/lib/systemd/system/systemd-udevd.service; static; vendor pre
   Active: active (running) since Sat 2017-12-30 16:06:39 EST; 32min ago
     Docs: man:systemd-udevd.service(8)
           man:udev(7)
 Main PID: 213 (systemd-udevd)
   Status: "Processing with 16 children at max"
   CGroup: /system.slice/systemd-udevd.service
           └─213 /lib/systemd/systemd-udevd

Dec 30 16:06:39 dalek systemd[1]: Starting udev Kernel Device Manager...
Dec 30 16:06:39 dalek systemd[1]: Started udev Kernel Device Manager.

This is an issue that’s existed for some time that I haven’t really got around to addressing yet, but it does want looking at.

By default, OSMC does not bundle the crda package and this seems to be causing problems. It appears that it would be better to use the kernel’s built in regulatory rules instead. If this is done, it needs to be done for all kernels.

As we update the kernel very regularly, the fact that we need to build a kernel each time we update regulatory rules doesn’t seem to be a problem.

So I believe all we need to do is:

  • enable CONFIG_CFG80211_INTERNAL_REGDB for all kernels
  • add a build action to update net/wireless/db.txt. This will ensure that older kernels still have the latest regulatory data.

This is part of OC-51 (JIRA).

Hello,
if I understand this issue well, for my situation:
if I am running 4.9.29-10-osmc with some RTL 8812au USB dongle (identified as Product: Edimax AC600 USB, in fact it is Edimax EW-7811UAC), I cannot use channels >100.
Region is unset/98, iw list says
* …
* 5320 MHz [64] (20.0 dBm) (no IR)
* 5500 MHz [100] (disabled)
* 5520 MHz [104] (disabled)
* 5540 MHz [108] (disabled)… etc

Driver is:
(/lib/modules/4.9.29-10-osmc/kernel/drivers/net/wireless/8812au.ko, version: v4.3.20_16317.20160108)
CRDA does nothing…
sudo iw reg set does nothing - still country 98: DFS-UNSET…

Am I correct? Or can do anything about using channels>100 which is supported by my router, country etc…
Thanks

I must correct myself, partially… after some reboots I was finally able to set country by CRDA, so iw reg get shows correct country… however, iw list still says that channels>100 are disabled… why, oh why?

what’s the out put of both?
For me it is working

iw reg get

global
country HK: DFS-ETSI
	(2402 - 2482 @ 40), (N/A, 20), (N/A)
	(5170 - 5250 @ 80), (N/A, 17), (N/A), AUTO-BW
	(5250 - 5330 @ 80), (N/A, 24), (N/A), DFS, AUTO-BW
	(5490 - 5710 @ 160), (N/A, 24), (N/A), DFS
	(5735 - 5835 @ 80), (N/A, 30), (N/A)

iw list

	Frequencies:
		* 5180 MHz [36] (17.0 dBm)
		* 5200 MHz [40] (17.0 dBm)
		* 5220 MHz [44] (17.0 dBm)
		* 5240 MHz [48] (17.0 dBm)
		* 5260 MHz [52] (24.0 dBm) (radar detection)
		* 5280 MHz [56] (24.0 dBm) (radar detection)
		* 5300 MHz [60] (24.0 dBm) (radar detection)
		* 5320 MHz [64] (24.0 dBm) (radar detection)
		* 5500 MHz [100] (24.0 dBm) (radar detection)
		* 5520 MHz [104] (24.0 dBm) (radar detection)
		* 5540 MHz [108] (24.0 dBm) (radar detection)
		* 5560 MHz [112] (24.0 dBm) (radar detection)
		* 5580 MHz [116] (24.0 dBm) (radar detection)
		* 5600 MHz [120] (24.0 dBm) (radar detection)
		* 5620 MHz [124] (24.0 dBm) (radar detection)
		* 5640 MHz [128] (24.0 dBm) (radar detection)
		* 5660 MHz [132] (24.0 dBm) (radar detection)
		* 5680 MHz [136] (24.0 dBm) (radar detection)
		* 5700 MHz [140] (24.0 dBm) (radar detection)
		* 5720 MHz [144] (disabled)
		* 5745 MHz [149] (30.0 dBm)
		* 5765 MHz [153] (30.0 dBm)
		* 5785 MHz [157] (30.0 dBm)
		* 5805 MHz [161] (30.0 dBm)
		* 5825 MHz [165] (30.0 dBm)

Output is:

country CZ: DFS-ETSI
        (2400 - 2483 @ 40), (N/A, 20), (N/A)
        (5150 - 5250 @ 80), (N/A, 23), (N/A), NO-OUTDOOR
        (5250 - 5350 @ 80), (N/A, 20), (0 ms), NO-OUTDOOR, DFS
        (5470 - 5725 @ 160), (N/A, 26), (0 ms), DFS
        (57000 - 66000 @ 2160), (N/A, 40), (N/A)

And:

Band 2:
                Capabilities: 0x1862
                        HT20/HT40
                        Static SM Power Save
                        RX HT20 SGI
                        RX HT40 SGI
                        No RX STBC
                        Max AMSDU length: 7935 bytes
                        DSSS/CCK HT40
                Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
                Minimum RX AMPDU time spacing: 16 usec (0x07)
                HT TX/RX MCS rate indexes supported: 0-7
                Bitrates (non-HT):
                        * 6.0 Mbps
                        * 9.0 Mbps
                        * 12.0 Mbps
                        * 18.0 Mbps
                        * 24.0 Mbps
                        * 36.0 Mbps
                        * 48.0 Mbps
                        * 54.0 Mbps
                Frequencies:
                        * 5170 MHz [34] (disabled)
                        * 5180 MHz [36] (23.0 dBm)
                        * 5190 MHz [38] (disabled)
                        * 5200 MHz [40] (23.0 dBm)
                        * 5210 MHz [42] (disabled)
                        * 5220 MHz [44] (23.0 dBm)
                        * 5230 MHz [46] (disabled)
                        * 5240 MHz [48] (23.0 dBm)
                        * 5260 MHz [52] (20.0 dBm) (no IR)
                        * 5280 MHz [56] (20.0 dBm) (no IR)
                        * 5300 MHz [60] (20.0 dBm) (no IR)
                        * 5320 MHz [64] (20.0 dBm) (no IR)
                        * 5500 MHz [100] (disabled)
                        * 5520 MHz [104] (disabled)
                        * 5540 MHz [108] (disabled)
                        * 5560 MHz [112] (disabled)
                        * 5580 MHz [116] (disabled)
                        * 5600 MHz [120] (disabled)
                        * 5620 MHz [124] (disabled)
                        * 5640 MHz [128] (disabled)
                        * 5660 MHz [132] (disabled)
                        * 5680 MHz [136] (disabled)
                        * 5700 MHz [140] (disabled)
                        * 5745 MHz [149] (disabled)
                        * 5765 MHz [153] (disabled)
                        * 5785 MHz [157] (disabled)
                        * 5805 MHz [161] (disabled)
                        * 5825 MHz [165] (disabled)
                        * 5920 MHz [184] (disabled)
                        * 5940 MHz [188] (disabled)
                        * 5960 MHz [192] (disabled)
                        * 5980 MHz [196] (disabled)
                        * 6000 MHz [200] (disabled)
                        * 6020 MHz [204] (disabled)
                        * 6040 MHz [208] (disabled)
                        * 6060 MHz [212] (disabled)
                        * 6080 MHz [216] (disabled)

European regulations require DFS/TPC to be enabled on channels >= 100. See The 5 Ghz Wireless Band

I’m guessing that either the hardware or driver doesn’t support DFS/TPC.

Ok not for long time but for testing what happens if you try to set the country to HK like mine to compare the output.

Ok, now I am in HK:

country HK: DFS-ETSI
        (2402 - 2482 @ 40), (N/A, 20), (N/A)
        (5170 - 5250 @ 80), (N/A, 17), (N/A)
        (5250 - 5330 @ 80), (N/A, 24), (0 ms), DFS
        (5490 - 5710 @ 160), (N/A, 24), (0 ms), DFS
        (5735 - 5835 @ 80), (N/A, 30), (N/A)

But, still channels>=100 are disabled:
Band 2:
Capabilities: 0x1862
HT20/HT40
Static SM Power Save
RX HT20 SGI
RX HT40 SGI
No RX STBC
Max AMSDU length: 7935 bytes
DSSS/CCK HT40
Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
Minimum RX AMPDU time spacing: 16 usec (0x07)
HT TX/RX MCS rate indexes supported: 0-7
Bitrates (non-HT):
* 6.0 Mbps
* 9.0 Mbps
* 12.0 Mbps
* 18.0 Mbps
* 24.0 Mbps
* 36.0 Mbps
* 48.0 Mbps
* 54.0 Mbps
Frequencies:
* 5170 MHz [34] (disabled)
* 5180 MHz [36] (17.0 dBm)
* 5190 MHz [38] (disabled)
* 5200 MHz [40] (17.0 dBm)
* 5210 MHz [42] (disabled)
* 5220 MHz [44] (17.0 dBm)
* 5230 MHz [46] (disabled)
* 5240 MHz [48] (17.0 dBm)
* 5260 MHz [52] (24.0 dBm) (no IR)
* 5280 MHz [56] (24.0 dBm) (no IR)
* 5300 MHz [60] (24.0 dBm) (no IR)
* 5320 MHz [64] (24.0 dBm) (no IR)
* 5500 MHz [100] (disabled)
* 5520 MHz [104] (disabled)
* 5540 MHz [108] (disabled)
* 5560 MHz [112] (disabled)
* 5580 MHz [116] (disabled)
* 5600 MHz [120] (disabled)
* 5620 MHz [124] (disabled)
* 5640 MHz [128] (disabled)
* 5660 MHz [132] (disabled)
* 5680 MHz [136] (disabled)
* 5700 MHz [140] (disabled)
* 5745 MHz [149] (disabled)
* 5765 MHz [153] (disabled)
* 5785 MHz [157] (disabled)
* 5805 MHz [161] (disabled)
* 5825 MHz [165] (disabled)
* 5920 MHz [184] (disabled)
* 5940 MHz [188] (disabled)
* 5960 MHz [192] (disabled)
* 5980 MHz [196] (disabled)
* 6000 MHz [200] (disabled)
* 6020 MHz [204] (disabled)
* 6040 MHz [208] (disabled)
* 6060 MHz [212] (disabled)
* 6080 MHz [216] (disabled)

… probably the driver or even hardware as was said…

Yeah maybe one of the two. But clearly not limited to DFS as @dillthedog thought as Channel 149 in HK is outside of DFS range. So it’s really just a plain disable above 100.

To the best of my knowledge, in the EU only bands A and B are permitted for WiFi use. Channel 149 falls into band C and is therefore not allowable within the EU for WiFi use.

Well that was just the test when he switched to HK.
And based on this it is allowed with 0.25w

Is there any way how to examine, if disabled channels are due to firmware of the dongle or due to driver in OSMC? Ok, I can take it and connect it to the windows box… will try, but I cannot do it in remote way instantly :slight_smile:

Trying it on Windows is worth a shot. If you see extra channels, it’s the Linux driver and if you don’t, well… it could still be the driver (or the hardware).

@fzinken In Europe the channels >= 149 are reserved for Short Range Devices, as the Wikipedia table shows. The relevant ETSI document for 5 GHz WiFi seems to be ETSI EN 301 893:

3.1 Definitions
For the purposes of the present document, the terms and definitions given in Directive 2014/53/EU [i.1] and the following apply:
5 GHz RLAN bands: total frequency range that consists of the 5 150 MHz to 5 350 MHz and the 5470 MHz to 5 725 MHz sub-bands