RealTek sdk使用iwpriv指令修改wifi工作模式,信道,速率方法
802.11 b/g/n mode1. Related MIB:(1) “band”: This parameter is bit mask of band selection. The value of thisparameter could be set to 1 to use 802.11b band, set to 2 to use 802.11gband, set to 8 to use
802.11 b/g/n mode
1. Related MIB:
(1) “band”: This parameter is bit mask of band selection. The value of this
parameter could be set to 1 to use 802.11b band, set to 2 to use 802.11g
band, set to 8 to use 802.11n band, or set to 11 to use 802.11 b/g/n bands.
(2) “use40M”: This parameter means 11n channel bonding. The value of this
parameter could be set to 0 to use 20MHz channel, or set to 1 to 40MHz
channel.
2. 802.11b mode example with wlan0 interface:
ifconfig wlan0 down
iwpriv wlan0 set_mib band=1
iwpriv wlan0 set_mib deny_legacy=0
iwpriv wlan0 set_mib use_40M=0
ifconfig wlan0 up
3. 802.11g mode example with wlan0 interface:
ifconfig wlan0 down
iwpriv wlan0 set_mib band=2
iwpriv wlan0 set_mib deny_legacy=1
iwpriv wlan0 set_mib use_40M=0
ifconfig wlan0 up
4. 802.11n mode example with wlan0 interface:
ifconfig wlan0 down
iwpriv wlan0 set_mib band=8
iwpriv wlan0 set_mib deny_legacy=3
iwpriv wlan0 set_mib use_40M=1
ifconfig wlan0 up
5. 802.11 b/g/n mode example with wlan0 interface:
ifconfig wlan0 down
iwpriv wlan0 set_mib band=11
iwpriv wlan0 set_mib deny_legacy=0
iwpriv wlan0 set_mib use_40M=1
ifconfig wlan0 up
TX Rate
1. Related MIB:
(1) “autorate”: This parameter means TX rate adaptive enable/disable. The
value of this parameter could be set to 0 to disable rate adaptive, or set to
1 to enable rate adaptive.
(2) “fixrate”: This parameter means the fixed TX rate when “autorate” is
disable. The value of this parameter is a bit map value that bit 0-11 for
rate 1, 2, 5.5, 11, 6, 9, 12, 18, 24, 36, 48, 54M and bit 12-27 for rate MCS0,
MCS1, …, MCS15.
2. WLAN auto rate example with wlan0 interface:
ifconfig wlan0 down
iwpriv wlan0 set_mib autorate=1
iwpriv wlan0 set_mib fixrate=0
ifconfig wlan0 up
3. WLAN fixed rate example with wlan0 interface:
Use MCS7 rate as the fixed rate and it maps to bit 19. The value of this bit 19. The value of this bitmap is 0x80000 that it converts to 524288 on decimal.
ifconfig wlan0 down
iwpriv wlan0 set_mib autorate=0
iwpriv wlan0 set_mib fixrate=524288
ifconfig wlan0 up
更多推荐
所有评论(0)