iw Wireless tool

iw [options] command

--debug     enable netlink debugging
--version   show version (4.9)

Commands:
help [command]
event [-t|-r] [-f]
features 
commands
phy
list
iw is rather rude regarding incorrect devices or commands as it simply displays the entire help!

not my best web page

iw list   # Pi Zero W  8/30/20      #slightly edited
Wiphy phy0
max # scan SSIDs: 10
max scan IEs length: 2048 bytes
max # sched scan SSIDs: 16
max # match sets: 16
max # scan plans: 1
max scan plan interval: 508
max scan plan iterations: 0
Retry short limit: 7     Retry long limit: 4
Coverage class: 0 (up to 0m)
Device supports roaming.
Supported Ciphers: * WEP40 (00-0f-ac:1) * WEP104 (00-0f-ac:5) * TKIP (00-0f-ac:2) * CCMP-128 (00-0f-ac:4)
Available Antennas: TX 0 RX 0
Supported interface modes: * IBSS * managed * AP * P2P-client * P2P-GO * P2P-device
Band 1:
    Capabilities: 0x1020
        HT20
        Static SM Power Save
        RX HT20 SGI
        No RX STBC
        Max AMSDU length: 3839 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):
        * 1.0 Mbps
        * 2 Mbps (short preamble supported) * 5.5 Mbps (short preamble supported) * 11 Mbps (short preamble supported)
        * 6 Mbps * 9 Mbps * 12 Mbps * 18 Mbps * 24 Mbps * 36 Mbps * 48 Mbps * 54 Mbps
    Frequencies:  all 20dBm
         2412 MHz [1]  2417 MHz [2]  2422 MHz [3]  2427 MHz [4] 
         2432 MHz [5]  2437 MHz [6]  2442 MHz [7]  2447 MHz [8]
         2452 MHz [9]  2457 MHz [10]  2462 MHz [11] (20 dBm)
         2467 MHz [12] (disabled)  2472 MHz [13] (disabled)  2484 MHz [14] (disabled)
Supported commands:
     * new_interface * set_interface
     * new_key
     * start_ap
     * join_ibss
     * set_pmksa * del_pmksa * flush_pmksa
     * remain_on_channel
     * frame
     * set_wiphy_netns
     * set_channel
     * start_sched_scan
     * start_p2p_device
     * connect * disconnect
     * crit_protocol_start * crit_protocol_stop
     * Unknown command (122)
Supported TX frame types:
     * managed:    00 10 20 30 40 50 60 70 80 90 a0 b0 c0 d0 e0 f0
     * P2P-client: 00 10 20 30 40 50 60 70 80 90 a0 b0 c0 d0 e0 f0
     * P2P-GO:     00 10 20 30 40 50 60 70 80 90 a0 b0 c0 d0 e0 f0
     * P2P-device: 00 10 20 30 40 50 60 70 80 90 a0 b0 c0 d0 e0 f0
Supported RX frame types:
     * managed:          40          d0
     * P2P-client:       40          d0
     * P2P-GO:     00 20 40 a0 b0 c0 d0
     * P2P-device:       40          d0
software interface modes (can always be added):
valid interface combinations:
     * #{ managed } <= 1, #{ P2P-device } <= 1, #{ P2P-client, P2P-GO } <= 1,
       total <= 3, #channels <= 2
     * #{ managed } <= 1, #{ AP } <= 1, #{ P2P-client } <= 1, #{ P2P-device } <= 1,
       total <= 4, #channels <= 1
Device supports scan flush.

phy phyname channels dev
> iw dev         #pi93graf
phy#0
Unnamed/non-netdev interface
    wdev 0x2
    addr 2E:F7:FE:E0:43:9a
    type P2P-device
    txpower 31 dBm
Interface wlan0
    ifindex 2
    wdev 0x1
    addr b8:27:eb:1c:5b:93
    ssid disabled
    type managed
    channel 11 (2462 MHz), width: 20 MHz, center1: 2462 MHz
    txpower 31.00 dBm
dev devname info
iw dev wlan0 info   # pi93graf
Interface wlan0
ifindex 2
wdev 1
addr b8:27:eb:1c:5b:93
ssid disabled
type managed
wiphy 0
channel 11 (2462 MHz), width: 20 MHz, center1: 2462 MHz
txpower 31.00 dBm
dev devname del
dev devname interface add nametype type [mesh_id meshid] [4addr on|off] [flags flag*] [addr mac-addr] phy phyname interface add nametype type [mesh_id meshid] [4addr on|off] [flags flag*] [addr mac-addr]
dev devname ibss join SSIDfreq in MHz[NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz] [fixed-freq] [fixed bssid] [beacon-interval TU] [basic-rates rate in Mbps,rate2,...] [mcast-rate rate in Mbps] [key d:0:abcde] dev devname ibss leave
dev devname station set MAC addressplink_action open|block dev devname station set MAC addressvlan ifindex dev devname station set MAC addressmesh_power_mode active|light|deep dev devname station dump [-v] dev devname station del MAC address[subtype subtype] [reason-code code]
dev devname station get MAC address
dev devname survey dump
dev devname ocb leave dev devname ocb join freq in MHz5MHz|10MHz
dev devname mesh leave dev devname mesh join mesh ID[[freq freq in MHzNOHT|HT20|HT40+|HT40-|80MHz] [basic-rates rate in Mbps,rate2,...]], [mcast-rate rate in Mbps] [beacon-interval time in TUs] [dtim-period value] [vendor_sync on|off] [param=value]*
dev devname mpath dump dev devname mpath set destination MAC addressnext_hop next hop MAC address dev devname mpath new destination MAC addressnext_hop next hop MAC address dev devname mpath del MAC address dev devname mpath get MAC address
dev devname mpp dump dev devname mpp get MAC address
dev devname scan[-u][freqfreq*][ieshexas00:11:..][meshidmeshid][lowpri,flush,ap-force][randomise[=addr/mask]] [ssidssid*|passive]
pi93graf  sudo  iw wlan0 scan
BSS 70:62:b8:96:ca:9e(on wlan0)
last seen: 1314247.290s [boottime]
TSF: 0 usec (0d, 00:00:00)
freq: 2437
beacon interval: 100 TUs
capability: ESS Privacy ShortPreamble (0x0031)
signal: -52.00 dBm
last seen: 0 ms ago
SSID: dlink-CA9E
Supported rates: 1.0* 2.0* 5.5* 11.0* 6.0 9.0 12.0 18.0 
DS Parameter set: channel 6
TIM: DTIM Count 0 DTIM Period 1 Bitmap Control 0x0 Bitmap[0] 0x0
Country: US Environment: Indoor/Outdoor
    Channels [1 - 11] @ 30 dBm
ERP: Use_Protection
Extended supported rates: 24.0 36.0 48.0 54.0 
HT capabilities:
    Capabilities: 0x1ad
        RX LDPC
        HT20
        SM Power Save disabled
        RX HT20 SGI
        TX STBC
        RX STBC 1-stream
        Max AMSDU length: 3839 bytes
        No DSSS/CCK HT40
    Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
    Minimum RX AMPDU time spacing: No restriction (0x00)
    HT RX MCS rate indexes supported: 0-15
    HT TX MCS rate indexes are undefined
HT operation:
     * primary channel: 6
     * secondary channel offset: no secondary
     * STA channel width: 20 MHz
     * RIFS: 1
     * 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: 300 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
WMM:     * Parameter version 1
     * u-APSD
     * 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
RSN:     * Version: 1
     * Group cipher: TKIP
     * Pairwise ciphers: CCMP TKIP
     * Authentication suites: PSK
     * Capabilities: 1-PTKSA-RC 1-GTKSA-RC (0x0000)
WPA:     * Version: 1
     * Group cipher: TKIP
     * Pairwise ciphers: CCMP TKIP
     * Authentication suites: PSK
WPS:     * Version: 1.0
     * Wi-Fi Protected Setup State: 2 (Configured)
     * Unknown TLV (0x1049, 6 bytes): 00 37 2a 00 01 20


BSS f4:f2:6d:a5:20:16(on wlan0)
last seen: 1314247.290s [boottime]
TSF: 0 usec (0d, 00:00:00) freq: 2412 beacon interval: 100 TUs
capability: ESS Privacy ShortPreamble (0x0031)
signal: -33.00 dBm
last seen: 0 ms ago
SSID: TP-LINK_A52016
Supported rates: 1.0* 2.0* 5.5* 11.0* 6.0 9.0 12.0 18.0 
DS Parameter set: channel 1
ERP: NonERP_Present
Extended supported rates: 24.0 36.0 48.0 54.0 
HT capabilities:
    Capabilities: 0x106e
        HT20/HT40
        SM Power Save disabled
        RX HT20 SGI
        RX HT40 SGI
        No RX STBC
        Max AMSDU length: 3839 bytes
        DSSS/CCK HT40
    Maximum RX AMPDU length 32767 bytes (exponent: 0x002)
    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: 1
     * secondary channel offset: above
     * STA channel width: any
     * 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
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
BSS 20:c0:47:c2:a8:a6(on wlan0) -- associated
last seen: 1314247.290s [boottime]
TSF: 0 usec (0d, 00:00:00)
freq: 2437
beacon interval: 100 TUs
capability: ESS Privacy ShortPreamble RadioMeasure (0x1031)
signal: -68.00 dBm
last seen: 0 ms ago

SSID: disabled
Supported rates: 1.0* 2.0* 5.5* 11.0* 18.0 24.0 36.0 54.0 
DS Parameter set: channel 6
TIM: DTIM Count 0 DTIM Period 1 Bitmap Control 0x1 Bitmap[0] 0x20
Country: US Environment: Indoor/Outdoor
    Channels [1 - 11] @ 30 dBm
ERP: 
Extended supported rates: 6.0 9.0 12.0 48.0 
RSN:     * Version: 1
     * Group cipher: CCMP
     * Pairwise ciphers: CCMP
     * Authentication suites: PSK
     * Capabilities: 16-PTKSA-RC 1-GTKSA-RC (0x000c)
BSS Load:
     * station count: 6
     * channel utilisation: 41/255
     * available admission capacity: 0 [*32us]
HT capabilities:
    Capabilities: 0x9ad
        RX LDPC
        HT20
        SM Power Save disabled
        RX HT20 SGI
        TX STBC
        RX STBC 1-stream
        Max AMSDU length: 7935 bytes
        No DSSS/CCK HT40
    Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
    Minimum RX AMPDU time spacing: 8 usec (0x06)
    HT RX MCS rate indexes supported: 0-23
    HT TX MCS rate indexes are undefined
HT operation:
     * primary channel: 6
     * secondary channel offset: no secondary
     * STA channel width: 20 MHz
     * RIFS: 0
     * HT protection: non-HT mixed
     * non-GF present: 1
     * OBSS non-GF present: 1
     * dual beacon: 0
     * dual CTS protection: 0
     * STBC beacon: 0
     * L-SIG TXOP Prot: 0
     * PCO active: 0
     * PCO phase: 0
Extended capabilities: Extended Channel Switching, BSS Transition, 6
WPS:     * Version: 1.0
     * Wi-Fi Protected Setup State: 2 (Configured)
     * UUID: ff8ab30b-943b-ebd7-cd1e-40346192d2bd
     * RF Bands: 0x3
     * Unknown TLV (0x1049, 6 bytes): 00 37 2a 00 01 20
WMM:     * Parameter version 1
     * u-APSD
     * 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
BSS b0:2a:43:b9:d6:21(on wlan0)
last seen: 1314232.736s [boottime]
TSF: 0 usec (0d, 00:00:00)
freq: 2462
beacon interval: 100 TUs
capability: ESS Privacy ShortPreamble RadioMeasure (0x1031)
signal: -87.00 dBm
last seen: 14560 ms ago


SSID: Kremlin Free WiFi
Supported rates: 1.0* 2.0* 5.5* 11.0* 6.0 9.0 12.0 18.0 
DS Parameter set: channel 11
Country: US Environment: Indoor/Outdoor
    Channels [1 - 11] @ 30 dBm
ERP: 
Extended supported rates: 24.0 36.0 48.0 54.0 
RSN:     * Version: 1
     * Group cipher: CCMP
     * Pairwise ciphers: CCMP
     * Authentication suites: PSK
     * Capabilities: 16-PTKSA-RC 1-GTKSA-RC (0x000c)
HT capabilities:
    Capabilities: 0x11ed
        RX LDPC
        HT20
        SM Power Save disabled
        RX HT20 SGI
        RX HT40 SGI
        TX STBC
        RX STBC 1-stream
        Max AMSDU length: 3839 bytes
        DSSS/CCK HT40
    Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
    Minimum RX AMPDU time spacing: 8 usec (0x06)
    HT TX/RX MCS rate indexes supported: 0-15
HT operation:
     * primary channel: 11
     * secondary channel offset: no secondary
     * STA channel width: 20 MHz
     * RIFS: 0
     * HT protection: no
     * non-GF present: 1
     * 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
Extended capabilities: Extended Channel Switching, BSS Transition, SSID List, 6
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


dev devname scan sched_start [interval in_msecs| scan_plans [interval_secs:iterations*] interval_secs] [delay in_secs] [freqs freq+] [matches [ssid ssid]+]] [active [ssid ssid]+|passive] [randomise[=addrmask]] dev devname scantrigger[freqfreq *][ieshexas00:11:.. ][meshidmeshid ][lowpri,flush,ap-force] [randomise[=addr mask ]][ssidssid *|passive] dev devname scan dump [-u] dev devname scan sched_stop dev devname scan abort
phy [phyname] reg get
sudo iw phy0 reg get
global
country US: DFS-FCC
    (2402 - 2472 @ 40), (N/A, 30), (N/A)
    (5170 - 5250 @ 80), (N/A, 23), (N/A), AUTO-BW
    (5250 - 5330 @ 80), (N/A, 23), (0 ms), DFS, AUTO-BW
    (5490 - 5730 @ 160), (N/A, 23), (0 ms), DFS
    (5735 - 5835 @ 80), (N/A, 30), (N/A)
    (57240 - 63720 @ 2160), (N/A, 40), (N/A)
reg set ISO/IEC 3166-1 alpha2
dev devname auth SSID bssid type:open|shared freq in MHz [key 0:abcde d:1:6162636465] dev devname connect [-w] SSID[freq in MHz] [bssid] [key 0:abcde d:1:6162636465] dev devname disconnect dev devname link dev devname offchannel freqduration dev devname cqm rssi threshold|off[hysteresis]
phy phyname wowlan show phy phyname wowlan disable phy phyname wowlan enable [any] [disconnect] [magic-packet] [gtk-rekey-failure] [eap-identity-request] [4way-handshake] [rfkill-release] [net-detect [interval in_msecs| scan_plans [interval_secs:iterations*] interval_secs] [delay in_secs] [freqs freq+] [matches [ssid ssid]+]] [active [ssid ssid]+|passive] [randomise[=addr/mask]]] [tcp config-file] [patterns [offset1+]pattern1] phy phyname coalesce show phy phyname coalesce disable phy phyname coalesce enable config-file dev devname roc start freqtime in ms
wdev idxp2p stop wdev idxp2p start
dev devname vendor recvbin ouisubcmdfilename|-|hex data dev devname vendor recv ouisubcmdfilename|-|hex data dev devname vendor send ouisubcmdfilename|-|hex data
phy phyname set antenna bitmap| all | tx bitmaprx bitmap dev devname set txpower auto|fixed|limit[tx power in mBm] phy phyname set txpower auto|fixed|limit[tx power in mBm] phy phyname set distance auto|distance phy phyname set coverage coverage class phy phyname set netns { pid| name nsname} phy phyname set retry [short limit] [long limit] phy phyname set rts rts threshold|off phy phyname set frag fragmentation threshold|off dev devname set channel channel[HT20|HT40+|HT40-] phy phyname set channel channel[HT20|HT40+|HT40-] dev devname set freq freq[HT20|HT40+|HT40-] dev devname set freq control freq[20|40|80|80+80|160] [center freq 1] [center freq 2] phy phyname set freq freq[HT20|HT40+|HT40-] phy phyname set name new name dev devname set mcast_rate rate in Mbps dev devname set peer MAC address dev devname set noack_map map dev devname set 4addr on|off dev devname set type type dev devname set meshid meshid dev devname set monitor flag* dev devname set mesh_param param=value[param=value]* dev devname set power_save on|off dev devname set bitrates [legacy-2.4|5legacy rate in Mbps*] [ht-mcs-2.4|5MCS index>*] [vht-mcs-2.4|5NSS:MCSx,MCSy… | NSS:MCSx-MCSy*] [sgi-2.4|lgi-2.4] [sgi-5|lgi-5]
dev devname get mesh_param [param] dev devname get power_save param>
Commands that use the netdev ('dev') can also be given the 'wdev' instead to identify the device. Omit the 'phy' or 'dev' if the identification is unique, e.g. "iw wlan0 info" or "iw phy0 info". (Don't when scripting.)
iwlist