Please pardon the mess. This is a work in progress and may lack proper formatting. Also please remember that the following information may be based on inaccurate research (my own or someone else's) and may not apply to the specific version of wl that you have.
My goal is to eventually make this a compendium of the commands available to control wireless connectivity via a terminal. Eventually, I'll make PDF or PS versions of the document available.
Manipulates the 802.11a radio's multicast rate. Applicable values include: 6, 9, 12, 18, 24, 36, 48, and 54. A -1 (the default) means "automatically determine the best rate". Examples:
wl a_mrate 54 wl a_mrate -1
Manipulates the 802.11a radio's rate. Applicable values include: 6, 9, 12, 18, 24, 36, 48, and 54. A -1 (the default) means "automatically determine the best rate". Examples:
wl a_rate 54 wl a_rate -1
This is an undocumented command and I do not as yet know what it is. Example:
root@OpenWrt:~# wl abbfl 0
Adding anything after abbfl causes the command to error.
This is an undocumented command. I do not yet know what it is or does. By itself, the command returns a numeric value:
root@OpenWrt:~# wl abminrate 0
Adding a digit to the end of the command changes the returned value:
root@OpenWrt:~# wl abminrate 5 root@OpenWrt:~# wl abminrate 5
Still researching the info behind this one. ACI is short for "adjacent channel interference". The 802.11t document defines the methodology for measuring ACI.
ACI appears to be associated with mesh networks and QoS.
http://www.mpirical.com/companion/Multi_Tech/ACI.htm
http://whitepapers.zdnet.co.uk/0,39025945,60070499p-39000680q,00.htm
This is used to add an Information Element (IE) to 802.11 management frames. The syntax for the command is:
wl add_ie pktflag length OUI hexdata
where "pktflg" is a mask (3210) =
bit 0 for beacon bit 1 for probe response bit 2 for association/re-association response bit 3 for authentication response
Math example:
3 --> 0011 --> beacon and probe response
I still need to capture an example of this command in action.
Sets an encryption key. The key must be 5, 13 or 16 bytes long, or 10, 26, 32, or 64 hex digits long. The encryption algorithm is automatically selected based on the key size. keytype is accepted only when key length is 16 bytes/32 hex digits and specifies whether AES-OCB or AES-CCM encryption is used. Default is ccm.
addwep <keyindex> <keydata> [ocb | ccm] [notx] [xx:xx:xx:xx:xx:xx]
where
keyindex = a name for the key declaration? keydata = the data for the key ocb = use the AES OCB algorithm (exclusive of "ccm") ccm = use the AES CCM algorithm (default) (exclusive of "ocm") notx =
See also "wl rmwep"
need to research the above as it is not explained well anywhere
"wl aes" returns the current status of hardware encryption:
root@OpenWrt:~# wl aes Algorithms (hardware): WEP disabled TKIP disabled AES disabled
"wl aes on", "wl aes enable" or "wl aes 1" enables the AES hardware encryption
"wl aes off", "wl aes disable" or "wl aes 0" disables the AES hardware encryption
"wl aes sw" or "wl aes software" signals that AES encryption is done in software
"wl aes hw" or "wl aes hardware" signals that AES encryption is done in hardware
The above needs verification and reorganization
Selects the receive antenna.
"wl antdiv 0" = use the antenna nearest the power jack "wl antdiv 1" = use the antenna nearest the reset button "wl antdiv 3" = antenna diversity (use which ever one has the best signal) "wl antdiv" returns the current selection
For some reason, "wl antdiv -1" and "wl antdiv 2" produces the same setting as "wl antdiv 3"
Sets the station mode. "wl ap" by itself returns the current device status
0 = station 1 = access point
Examples:
# Set the device as a client root@OpenWrt:~# wl ap 0 root@OpenWrt:~# # Set the device as an access point root@OpenWrt:~# wl ap 1 root@OpenWrt:~#
# Test the current status root@OpenWrt:~# wl ap ap is 1 (on)
This is an undocumented command. It determines whether or not STAs can "see" each other.
0 = STAs can "see" each other 1 = STAs cannot "see" each other
Examples:
root@OpenWrt:~# wl ap_isolate 0 root@OpenWrt:~# wl ap_isolate 1 root@OpenWrt:~# wl ap_isolate 1
Dumps information about the current network association (I'm assuming this applies to client mode)
Example:
root@OpenWrt:~# wl assoc SSID: "joats" Mode: Managed RSSI: 0 dBm noise: 0 dBm Channel: 6 BSSID: 00:0C:43:E3:28:92 Capability: ESS ShortSlot Supported Rates: [ 1(b) 2(b) 5.5(b) 6 9 11(b) 12 18 24 36 48 54 ]
Dumps a list of stations associated with the AP (AP mode only)
Example:
root@OpenWrt:~# wl assoclist assoclist 02:04:C2:6A:F1:C6 assoclist 02:19:00:00:00:00
Relates to the transmit attentuation in 802.11b and 802.11g.
Example:
root@OpenWrt:~# wl atten Current 11b/g tx atten is (auto) bb/radio/ctl1 = 3/3/48
Needs enumeration
Returns or sets the current band setting(s).
Example:
root@OpenWrt:~# wl band auto
Returns the list of available 802.11 bands. (Note: b can include g)
Example:
root@OpenWrt:~# wl bands b
Dumps the capabilities of the device.
Example:
root@OpenWrt:~# wl cap ap sta wet led wme pio 802.11d 802.11h rm cqa
Dumps the list of available commands.
Example:
root@OpenWrt:~# wl cmds a_rate del_ie powerindex scan_channel_time a_mrate eap phyreg scan_unassoc_time ap evm plcphdr scan_home_time atten frag phytype scan_passive_time antdiv fqacurcy primary_key scan_nprobes addwep fasttimer passive ssid aes frameburst prb_resp_timeout shortslot authorize gmode phylist shortslot_override assoc gmode_protection pktcnt shortslot_restrict assoclist gmode_protection_control pwr_percent scb_timeout aciargs gmode_protection_cts quiet slowtimer authe_sta_list gmode_protection_override restart sta_info autho_sta_list glacialtimer reboot tssi add_ie infra radio txpwr bg_rate int revinfo txpwr1 bg_mrate ignore_bcns rts txpathpwr bssid isup rate txpwrlimit band interference radioreg txant bands join ratedump tkip bi keys rateparam tsc cmds lodump rmwep tkip_countermeasures clk lrl regulatory up cwmin locale rateset ucflags cwmax lazywds roam_trigger upgrade channel longtrain roam_delta ver chanlist lbt roam_scan_period wake channels legacy_erp rssi wepstatus channels_in_country list_ie radar wep curpower msglevel rssidump wsec_test channel_qa monitor rm_req wsec_restrict channel_qa_start mrate rm_rep wsec country macreg rand wpa_auth crsuprs mac srdump wds csa macmode srl wet constraint measure_req shmem wds_remote_mac cap malloc_dump scbdump wds_wpa_role_old chan_info nvdump set_pmk wds_wpa_role down nvset scan wme dump nvget spect wme-ac deauthorize noise scanresults deauthenticate out status disassoc PM scansuppress dtim promisc suprates
This command has a number of formats and functions.
"wl country" returns the current country value. Example:
root@OpenWrt:~# wl country ALL/<unknown>
"wl country list" returns a listing of supported countries with their associated ISO 3166 abbreviation. (Example to long to list here.)
"wl country XX" (where XX is a country name or code). Note: you must bring the radio down before changing the country code.
Example:
root@OpenWrt:~# wl country ALL/<unknown> root@OpenWrt:~# wl down root@OpenWrt:~# wl country us Setting country code "us" root@OpenWrt:~# wl up root@OpenWrt:~# wl country US/UNITED STATES root@OpenWrt:~# wl down root@OpenWrt:~# wl country all Setting country code "all" root@OpenWrt:~# wl up root@OpenWrt:~# wl country ALL/<unknown> root@OpenWrt:~# wl down root@OpenWrt:~# wl country "united states" Setting country code "US" root@OpenWrt:~# wl up root@OpenWrt:~# wl country US/UNITED STATES
This is used to remove an Information Element (IE) from 802.11 management frames (see "add_ie"). The syntax for the command is:
wl del_ie pktflag length OUI hexdata
where "pktflg" is a mask (3210) =
bit 0 for beacon bit 1 for probe response bit 2 for association/re-association response bit 3 for authentication response
Math example:
3 --> 0011 --> beacon and probe responses
I still need to capture an example of this command in action.
Disables the radio. Example:
wl down
wl mac - Set or get the list of source MAC address matches.
wl mac wl mac xx:xx:xx:xx:xx:xx [xx:xx:xx:xx:xx:xx ...]
To Clear the list:
wl mac none
wl macmode - Set the mode of the MAC list.
0 - Disable MAC address matching. 1 - Deny association to stations on the MAC list. 2 - Allow association to stations on the MAC list.
This is an undocumented command. It sets the maximum number of associations available for use (Note: absolute maximum for the device is 128.) Examples:
root@OpenWrt:~# wl maxassoc 128 (0x80) root@OpenWrt:~# wl maxassoc 6 root@OpenWrt:~# wl maxassoc 6
Without any numbers appended, returns the status of the radio. Example:
root@OpenWrt:~# wl radio radio is on (WL_RADIO_SW_DISABLE 0 WL_RADIO_HW_DISABLE 0)
Appending a "0" or a "1" will change the DISABLE variable and change the status of the radio. Example:
root@OpenWrt:~# wl radio 1 root@OpenWrt:~# wl radio radio is off (WL_RADIO_SW_DISABLE 1 WL_RADIO_HW_DISABLE 0) root@OpenWrt:~# wl radio 0 root@OpenWrt:~# wl radio radio is on (WL_RADIO_SW_DISABLE 0 WL_RADIO_HW_DISABLE 0)
Note that the relationship between the number and the radio status is counterintuitive.
Reinitializes the radio. Note: the radio must be down and this command does not enable the radio.
"wl status" Show some status
Example:
root@OpenWrt:~# wl status SSID: "Test_231" Mode: Managed RSSI: 0 dBm noise: 0 dBm Channel: 6 BSSID: 00:1B:FC:9D:30:D2 Capability: ESS ShortSlot Supported Rates: [ 1(b) 2(b) 5.5(b) 6 9 11(b) 12 18 24 36 48 54 ]
This is an undocumented command. With no number, returns the status of the built-in WPA supplicant (0=off, 1=0n). With a number, sets turns the built-in supplicant on or off.
root@OpenWrt:~# wl sup_wpa 0 root@OpenWrt:~# wl sup_wpa 1 root@OpenWrt:~# wl sup_wpa 1
Selects the transmit antenna.
"wl txant 0" = force use of antenna 0
"wl txant 1" = force use of antenna 1
"wl txant 3" = use the RX antenna selection that was in force during the most
recently received good PLCP header
"wl txant" = returns the current selection
"wl txpwr1" Set tx power in in various units. Choose one of (default: dbm):
-d dbm units
-q quarter dbm units
-m milliwatt units
Can be combined with:
-o turn on override to disable regulatory and other limitations
Use wl txpwr -1 to restore defaults
Example:
root@OpenWrt:~# wl txpwr1 TxPower is 64 qdbm, 16.00 dbm, 40 mW Override is Off
Enables wireless. Example:
wl up
"wl ver" prints the version information. Example:
root@OpenWrt:~# wl ver
wl: 3.90 RC37.0
wl0: Feb 15 2005 14:08:17 version 3.90.37.0
This is an undocumented command. It returns the BSSID of the remote endpoint. I do not have an example for this yet.
This is an undocumented command. It sets whether the AP is a WPA authenticator or a supplicant. I do not have an example for this yet.
1) According to the following, you can set broadcom-based AP's to use channels 12, 13 and 14. http://forum.openwrt.org/viewtopic.php?pid=9916