micropython iPerf on W55RP20
This Python code is an iperf3-compatible network performance test client. It measures network throughput using TCP/UDP and collects performance statistics.
This Python code implements a client for network performance testing, compatible with iperf3.
It connects to a server using either TCP or UDP to measure network performance, including metrics like throughput and latency.
The code supports sending and receiving data, gathering statistics, and handling commands exchanged with the server. The Stats
class collects data about the number of bytes transferred and handles timing to evaluate network throughput.
Usage
File: iperf3.py
When executed as a server process, this script performs the following actions:
- Obtains an IP address via DHCP
- Opens and listens on port 5201
Due to the nature of MicroPython execution, the test results may show lower performance compared to the board's actual capabilities. This is an inherent limitation of the interpreted language environment.
For more accurate iPerf test results that reflect the true performance of the W55RP20-EVB-Pico board, we recommend using the C language implementation.
Please refer to the following repository for a C-based iPerf implementation:
This C implementation will provide more representative performance metrics for the W55RP20-EVB-Pico board.
File: iperf3_test.py
This script is designed to test the iperf3.py
running on the W55RP20 board from a Windows environment.
The primary purpose of this script is to facilitate iPerf3 testing between a Windows machine and a W55RP20 board running the iperf3.py
script.
To use this script, follow these steps:
- Ensure the
iperf3.py
script is running on your W55RP20 board. - Note the IP address displayed by the W55RP20 board.
- Open a command prompt or PowerShell window on your Windows machine.
- Navigate to the directory containing this script.
- Run the script using the following command format: