RTEMS 6.1-rc5
Loading...
Searching...
No Matches
Data Fields
tftp_net_config Struct Reference

This structure represents configuration value used by the TFTP client. More...

#include <tftp.h>

Data Fields

uint16_t retransmissions
 This member defines how many attempts are made to send a network packet to the server.
 
uint16_t server_port
 This member defines the port on which the server is listening for incoming connections.
 
uint32_t timeout
 This member defines the maximum time in milliseconds the client waits for an answer packet from the server.
 
uint32_t first_timeout
 This member defines the maximum time in milliseconds the client waits for the first answer packet from the server.
 
tftp_options options
 This member represents the options to be sent to the server.
 

Detailed Description

This structure represents configuration value used by the TFTP client.

As defaults the values suggested in RFC 7440 are used.

Field Documentation

◆ first_timeout

uint32_t tftp_net_config::first_timeout

This member defines the maximum time in milliseconds the client waits for the first answer packet from the server.

The first_timeout is used instead of the regular timeout for the first wait-period directly after the client sends a packet for the first time to the server. That is, this is the timeout of the first re-transmission. For any following re-transmissions of the current packet the regular timeout is used.

The default value is 400ms.

◆ options

tftp_options tftp_net_config::options

This member represents the options to be sent to the server.

These option values are sent to the server. Yet, the server may

  • ignore one or all options
  • ask the client to use a different value for an option
  • reject the whole request with an error

If the server rejects a request with options, the current client implementation will automatically send a second request without options. Hence, the user should be aware that the actual file transfer may not use the option values specified here.

◆ retransmissions

uint16_t tftp_net_config::retransmissions

This member defines how many attempts are made to send a network packet to the server.

Repetitions occur when the server does not response to a packet send by the client within a timeout period. When the here defined number of repetitions is reached and the server does still not respond, the connection is considered broken and the file transfer is ended with an error.

The default value is 6.

◆ server_port

uint16_t tftp_net_config::server_port

This member defines the port on which the server is listening for incoming connections.

The default port number is 69.

◆ timeout

uint32_t tftp_net_config::timeout

This member defines the maximum time in milliseconds the client waits for an answer packet from the server.

If the time out is exceeded, the client will re-transmit the last packet it send to the server. In case window_size is larger one, several packets may subject to re-transmission.

Note that this timeout applies only after the first re-transmission of a packet. The timeout till the first re-transmission is first_timeout.

The default value is 1000ms.


The documentation for this struct was generated from the following file: