2016-08-18, 18:13
(2016-08-18, 14:39)ElectricPim Wrote: Still having trouble to use channel 13 for WIFI.
Is there a setting for WIFI country, or any way to enable channel 12/13
This is most likely a configuration issue with your access point - if your AP is not announcing a country code then the Linux kernel in LibreELEC won't know which channels it is permitted to use so it will default to the most restrictive "global" regulatory configuration (country code 00, channels 1-11).
See this discussion for more details.
Install "Network Tools" from the LibreELEC Repository and you can check if your AP is announcing a country code:
Code:
iw dev wlan0 scan
For example my Netgear DGND4000 access point is not transmitting a country code, but one of my neighbours is:
Code:
BSS xx:xx:xx:xx:xx:xx(on wlan0)
TSF: 0 usec (0d, 00:00:00)
freq: 2462
beacon interval: 100 TUs
capability: ESS Privacy ShortSlotTime (0x0411)
signal: -83.00 dBm
last seen: 0 ms ago
SSID: TALKTALK17xxxx
Supported rates: 1.0* 2.0* 5.5* 11.0* 6.0 9.0 12.0 18.0
DS Parameter set: channel 11
ERP: <no flags>
Extended supported rates: 24.0 36.0 48.0 54.0
HT capabilities:
Capabilities: 0x198e
HT20/HT40
SM Power Save disabled
TX STBC
RX STBC 1-stream
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 RX MCS rate indexes supported: 0-15
HT TX MCS rate indexes are undefined
HT operation:
* primary channel: 11
* secondary channel offset: no secondary
* STA channel width: 20 MHz
* RIFS: 0
* HT protection: no
* non-GF present: 0
* OBSS non-GF present: 0
* dual beacon: 0
* dual CTS protection: 0
* STBC beacon: 0
* L-SIG TXOP Prot: 0
* PCO active: 0
* PCO phase: 0
Overlapping BSS scan params:
* passive dwell: 20 TUs
* active dwell: 10 TUs
* channel width trigger scan interval: 180 s
* scan passive total per channel: 200 TUs
* scan active total per channel: 20 TUs
* BSS width channel transition delay factor: 5
* OBSS Scan Activity Threshold: 0.25 %
Extended capabilities: HT Information Exchange Supported
WPA: * Version: 1
* Group cipher: TKIP
* Pairwise ciphers: TKIP CCMP
* Authentication suites: PSK
RSN: * Version: 1
* Group cipher: TKIP
* Pairwise ciphers: TKIP CCMP
* Authentication suites: PSK
* Capabilities: 1-PTKSA-RC 1-GTKSA-RC (0x0000)
WMM: * Parameter version 1
* BE: CW 15-1023, AIFSN 3
* BK: CW 15-1023, AIFSN 7
* VI: CW 7-15, AIFSN 2, TXOP 3008 usec
* VO: CW 3-7, AIFSN 2, TXOP 1504 usec
Country: GB Environment: Indoor/Outdoor
Channels [1 - 13] @ 20 dBm
WPS: * Version: 1.0
* Wi-Fi Protected Setup State: 2 (Configured)
* Response Type: 3 (AP)
* UUID: 63041253-1019-2006-1228-50a72b17f378
* Manufacturer: Realtek Semiconductor Corp.
* Model: RTL8xxx
* Model Number: EV-2010-09-20
* Serial Number: 123456789012347
* Primary Device Type: 6-0050f204-1
* Device name: ADSL Modem/Router
* Config methods: PBC
* Unknown TLV (0x1049, 6 bytes): 00 37 2a 00 01 20
Another neighbour has thinks he is in America, even though we are both in the UK...
Code:
Country: US Environment: Indoor only
Channels [1 - 11] @ 27 dBm
However most of the APs that I can "see" do NOT announce any country code, so any connecting (Linux) client will default to regulatory domain 00 (ie. global).
To force a specific regulatory domain/country, you can try (on your LibreELEC client):
Code:
echo "options cfg80211 ieee80211_regdom=GB" > /etc/modprobe.d/cfg80211.conf
reboot
To see which frequencies are currently supported by your LibreELEC client:
Code:
iwlist wlan0 frequency
So for my RPi3, before forcing the regulatory domain to GB:
Code:
rpi22:~ # iwlist wlan0 frequency
wlan0 11 channels in total; available frequencies :
Channel 01 : 2.412 GHz
Channel 02 : 2.417 GHz
Channel 03 : 2.422 GHz
Channel 04 : 2.427 GHz
Channel 05 : 2.432 GHz
Channel 06 : 2.437 GHz
Channel 07 : 2.442 GHz
Channel 08 : 2.447 GHz
Channel 09 : 2.452 GHz
Channel 10 : 2.457 GHz
Channel 11 : 2.462 GHz
Current Frequency:2.447 GHz (Channel 8)
Code:
rpi22:~ # iwlist wlan0 frequency
wlan0 13 channels in total; available frequencies :
Channel 01 : 2.412 GHz
Channel 02 : 2.417 GHz
Channel 03 : 2.422 GHz
Channel 04 : 2.427 GHz
Channel 05 : 2.432 GHz
Channel 06 : 2.437 GHz
Channel 07 : 2.442 GHz
Channel 08 : 2.447 GHz
Channel 09 : 2.452 GHz
Channel 10 : 2.457 GHz
Channel 11 : 2.462 GHz
Channel 12 : 2.467 GHz
Channel 13 : 2.472 GHz
Current Frequency:2.447 GHz (Channel 8)
Forcing a specific regulatory domain is not likely to be something that will be implemented or even needs fixing in LibreELEC - if the AP you are connected to is not announcing the correct regulatory domain (ie. country) then the current default behaviour ("global") is entirely correct. In such circumstances you will have to manually configure the regulatory domain/country in /etc/modprobe.d/cfg80211.conf.