1# Iperf Example 2 3## Note about iperf version 4The iperf example doesn't support all features in standard iperf. It's compitable with iperf version 2.x. 5 6## Note about 80MHz flash frequency 7The iperf can get better throughput if the SPI flash frequency is set to 80MHz, but the system may crash in 80MHz mode for ESP-WROVER-KIT. 8Removing R140~R145 from the board can fix this issue. Currently the default SPI frequency is set to 40MHz, if you want to change the SPI flash 9frequency to 80MHz, please make sure R140~R145 are removed from ESP-WROVER-KIT or use ESP32 DevKitC. 10 11## Introduction 12This example implements the protocol used by the common performance measurement tool [iPerf](https://iperf.fr/). 13Performance can be measured between two ESP32s running this example, or between a single ESP32 and a computer running the iPerf tool 14 15Demo steps to test station TCP Tx performance: 16 171. Build the iperf example with sdkconfig.defaults, which contains performance test specific configurations 18 192. Run the demo as station mode and join the target AP 20 sta ssid password 21 223. Run iperf as server on AP side 23 iperf -s -i 3 24 254. Run iperf as client on ESP32 side 26 iperf -c 192.168.10.42 -i 3 -t 60 27 28The console output, which is printed by station TCP RX throughput test, looks like: 29 30>esp32> sta aptest 31> 32>I (5325) iperf: sta connecting to 'aptest' 33> 34>esp32> I (6017) event: ip: 192.168.10.248, mask: 255.255.255.0, gw: 192.168.10.1 35> 36>esp32> iperf -s -i 3 -t 1000 37> 38>I (14958) iperf: mode=tcp-server sip=192.168.10.248:5001, dip=0.0.0.0:5001, interval=3, time=1000 39> 40>Interval Bandwidth 41> 42>esp32> accept: 192.168.10.42,62958 43> 44>0- 3 sec 8.43 Mbits/sec 45> 46>3- 6 sec 36.16 Mbits/sec 47> 48>6- 9 sec 36.22 Mbits/sec 49> 50>9- 12 sec 36.44 Mbits/sec 51> 52>12- 15 sec 36.25 Mbits/sec 53> 54>15- 18 sec 24.36 Mbits/sec 55> 56>18- 21 sec 27.79 Mbits/sec 57 58 59Steps to test station/soft-AP TCP/UDP RX/TX throughput are similar as test steps in station TCP TX. 60 61See the README.md file in the upper level 'examples' directory for more information about examples. 62