iPerf#

The iPerf component provides an iPerf2-compatible solution to measure UDP throughput. It has a full UDP support and implements a server and client modes, which are capable of sending and receiving packets to measure the bandwidth performance, the inter-arrival jitter, and packet loss.

The component relies on different functions to help configure and run your iPerf test. It allows you to set up your server and client port, your preferred bandwidth, number of packets, remote peer address, and so on. At the end of every iPerf test, an iPerf report is output. Multicast target measurement is supported also. The component can be used with any network stack because it has a portable custom network interface.

To use the iPerf component in your application, add it to your project and initialize it with sl_iperf_service_init().

The iPerf component offers a solution compatible with [iPerf2] (https://sourceforge.net/projects/iperf2/) for measuring UDP throughput. It provides comprehensive UDP support and implements both server and client modes, enabling the exchange of packets to assess bandwidth performance, inter-arrival jitter, and packet loss.To configure and execute your iPerf test, the component relies on various functions. You can customize parameters such as the server and client ports, preferred bandwidth, packet count, and remote peer address. Upon completion of each iPerf test, an iPerf report is generated.

The component can be used with any network stack, thanks to its portable custom network interface. To integrate the iPerf component into your application, simply add it to your project and initialize it using sl_iperf_service_init().

Modules#

iPerf type definitions

Functions#

void

Initialize the iPerf service.

bool
sl_iperf_test_add(sl_iperf_test_t *const test)

Add the iPerf test to the execution queue.

bool
sl_iperf_test_get(sl_iperf_test_t *const test, const uint32_t timeout_ms)

Get the iPerf test from the result queue.

void
sl_iperf_test_init(sl_iperf_test_t *const test, sl_iperf_mode_t mode, sl_iperf_protocol_t protocol)

Initialize the iPerf test.

void
sl_iperf_test_set_default_buff(sl_iperf_test_t *const test)

Set the default internal test buffer.

void
sl_iperf_test_set_default_logger(sl_iperf_test_t *const test)

Set the default internal logger for the test descriptor.

void
sl_iperf_test_udp_client(sl_iperf_test_t *test)

Execute the iPerf UDP client test.

void
sl_iperf_test_udp_server(sl_iperf_test_t *test)

Execute the iPerf UDP server test.

Function Documentation#

sl_iperf_service_init#

void sl_iperf_service_init (void )

Initialize the iPerf service.

Parameters
N/A

Init OS objects and default contents


Definition at line 108 of file /mnt/raid/workspaces/ws.z1SfSYxIV/overlay/gsdk/app/wisun/component/iperf/sl_iperf.h

sl_iperf_test_add#

bool sl_iperf_test_add (sl_iperf_test_t *const test)

Add the iPerf test to the execution queue.

Parameters
[in]test

Test descriptor

Add test to the input messagequeue. Returns

  • true On Success

  • false On Failure


Definition at line 143 of file /mnt/raid/workspaces/ws.z1SfSYxIV/overlay/gsdk/app/wisun/component/iperf/sl_iperf.h

sl_iperf_test_get#

bool sl_iperf_test_get (sl_iperf_test_t *const test, const uint32_t timeout_ms)

Get the iPerf test from the result queue.

Parameters
[out]test

Destination test descriptor

[in]timeout_ms

Timeout for getting test from messagequeue

Get the test from the output messagequeue. Returns

  • true On Success

  • false On Failure


Definition at line 153 of file /mnt/raid/workspaces/ws.z1SfSYxIV/overlay/gsdk/app/wisun/component/iperf/sl_iperf.h

sl_iperf_test_init#

void sl_iperf_test_init (sl_iperf_test_t *const test, sl_iperf_mode_t mode, sl_iperf_protocol_t protocol)

Initialize the iPerf test.

Parameters
[inout]test

Test descriptor

[in]mode

Mode

[in]protocol

Protocol

Initialize a test descriptor with default content


Definition at line 117 of file /mnt/raid/workspaces/ws.z1SfSYxIV/overlay/gsdk/app/wisun/component/iperf/sl_iperf.h

sl_iperf_test_set_default_buff#

void sl_iperf_test_set_default_buff (sl_iperf_test_t *const test)

Set the default internal test buffer.

Parameters
[out]test

Test descriptor

Helper function


Definition at line 133 of file /mnt/raid/workspaces/ws.z1SfSYxIV/overlay/gsdk/app/wisun/component/iperf/sl_iperf.h

sl_iperf_test_set_default_logger#

void sl_iperf_test_set_default_logger (sl_iperf_test_t *const test)

Set the default internal logger for the test descriptor.

Parameters
[out]test

Test descriptor

Helper function


Definition at line 126 of file /mnt/raid/workspaces/ws.z1SfSYxIV/overlay/gsdk/app/wisun/component/iperf/sl_iperf.h

sl_iperf_test_udp_client#

void sl_iperf_test_udp_client (sl_iperf_test_t * test)

Execute the iPerf UDP client test.

Parameters
[inout]test

Test descriptor

iPerf UDP client test.


Definition at line 66 of file /mnt/raid/workspaces/ws.z1SfSYxIV/overlay/gsdk/app/wisun/component/iperf/sl_iperf_udp_clnt.h

sl_iperf_test_udp_server#

void sl_iperf_test_udp_server (sl_iperf_test_t * test)

Execute the iPerf UDP server test.

Parameters
[inout]test

Test descriptor

iPerf UDP server test.


Definition at line 66 of file /mnt/raid/workspaces/ws.z1SfSYxIV/overlay/gsdk/app/wisun/component/iperf/sl_iperf_udp_srv.h