pip install -r requirements.txt
The scripts have been developed using Python 3.9.
- Controller:
- Has a Wi-Fi device capable of monitoring the channel used by the AP
- Runs the tools in this repo. Therefore, also builds Linux with its (mainlined) drivers rtl8xxxu and rtl8192cu, as well as 8192cu
- Is part of two (Ethernet) networks:
- Productive
- Testing
- Device under Test (DUT):
- Machine with a RTL8192CUS dongle attached
- Connected to the productive network
- Access Point (AP):
- Connected to the testing network
- DUT: Controller must be able to log into as root user
- AP: Ideally configured to use a non-crowded channel
- Needs to be built as module and with support for untested chips (CONFIG_RTL8XXXU_UNTESTED=y)
- Patch to register dumping:
- Needs to be built as module
- Patches for register dumping:
- Vendor driver patched to allo register dumping and work with Linux 5.10, cfg80211:
- https://github.com/husqvarnagroup/rtl8xxxu-8192cu-for-rtl8188cus
Example usage:
./rtl8xxxu_benchmark.py --log-level INFO \
--dut machine-with-rtl8188cus-dongle \
--driver rtl8192cu \
--direction tx \
--mon-interface wifi-inteface-in-monitoring-mode \
--network-ssid rtl8xxxu-testwifi \
--network-psk=very-secure \
--linux-build-directory "$HOME/code/3rd-party/build-linux-amd64-5.10"
Please note:
- The Linux build directory must be configured and its kernel running on the DUT ahead of the testrun
./rtl8xxxu_register_dump_diff.py $HOME/code/3rd-party/linux/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_regs.h latest/*.reg_dump
./rtl8xxxu_analyze.py --ap 00:a0:c5:d0:30:22 --sta 74:da:38:0e:49:7d latest/*pcap
The code base uses abbreviations extensively, many of which are never fully spelled out. This section attempts to document them. Please take this with a grain of salt, most of this is just googled!
- ADDA: Analog Digital Digital Analog
- IQ: The term "I/Q" is an abbreviation for "in-phase" and "quadrature."
- PI mode: ?
- SI mode: ?