使用iw可以获取到连接到路由器上所有设备的MAC地址
root@OpenWrt:~# iw dev wlan0 station dump
Station e0:ac:cb:b1:ca:ba (on wlan0)
inactive time: 27010 ms
rx bytes: 198087
rx packets: 1417
tx bytes: 843928
tx packets: 969
tx retries: 66
tx failed: 4
signal: -70 dBm
signal avg: -70 dBm
tx bitrate: 72.2 MBit/s MCS 7 short GI
rx bitrate: 24.0 MBit/s
expected throughput: 34.84Mbps
authorized: yes
authenticated: yes
preamble: short
WMM/WME: yes
MFP: no
TDLS peer: no
Station 04:52:f3:87:cf:77 (on wlan0)
inactive time: 620 ms
rx bytes: 316840
rx packets: 3260
tx bytes: 419569
tx packets: 1576
tx retries: 91
tx failed: 0
signal: -78 dBm