Trivial File Transfer Protocol module provides implementation of TFTP Client.
More...
Trivial File Transfer Protocol module provides implementation of TFTP Client.
User callback from TFTP module.
- Note
- TFTP module user callback will be invoked even if user asks TFTP to abort (TFTP error event).
- Parameters
-
[in] | p_tftp | Pointer to the TFTP instance. |
[in] | p_evt | Pointer to the TFTP event structure, describing reason. |
- Return values
-
TFTP module Events.
Enumerator |
---|
IOT_TFTP_EVT_ERROR |
Event code indicating that en error occurred.
|
IOT_TFTP_EVT_TRANSFER_GET_COMPLETE |
Event code indicating that transfer read was completed.
|
IOT_TFTP_EVT_TRANSFER_PUT_COMPLETE |
Event code indicating that transfer write was completed.
|
Resets TFTP client instance, so it is possible to make another request after error.
- Parameters
-
[in] | p_tftp | Pointer to the TFTP instance. |
- Return values
-
NRF_SUCCESS | on successful execution of procedure, else an error code indicating reason for failure. |
Retrieves file from remote server into p_file.
- Parameters
-
[in] | p_tftp | Pointer to the TFTP instance. |
[in] | p_file | Reference to the file from which data should be read. Should not be NULL. |
- Return values
-
NRF_SUCCESS | on successful execution of procedure, else an error code indicating reason for failure. |
Holds transmission of ACK (use in order to slow transmission).
- Parameters
-
[in] | p_tftp | Pointer to the TFTP instance. |
- Return values
-
NRF_SUCCESS | on successful execution of procedure, else an error code indicating reason for failure. |
Initializes TFTP client.
- Parameters
-
[in] | p_tftp | Pointer to the TFTP instance. Should not be NULL. |
[in] | p_init_params | Initialization structure for TFTP client. Should not be NULL. |
- Return values
-
NRF_SUCCESS | on successful execution of procedure, else an error code indicating reason for failure. |
Sends local file p_file to a remote server.
- Parameters
-
[in] | p_tftp | Pointer to the TFTP instance. |
[in] | p_file | Reference to the file to which data should be stored. Should not be NULL. |
- Return values
-
NRF_SUCCESS | on successful execution of procedure, else an error code indicating reason for failure. |
Resumes transmission.
- Parameters
-
[in] | p_tftp | Pointer to the TFTP instance. |
- Return values
-
NRF_SUCCESS | on successful execution of procedure, else an error code indicating reason for failure. |
Function used in order to change initial connection parameters.
- Parameters
-
[in] | p_tftp | Reference to the TFTP instance. |
[in] | p_params | Pointer to transmission parameters structure. Should not be NULL. |
- Return values
-
NRF_SUCCESS | if parameters successfully set, else an error code indicating reason for failure. |
Function for performing retransmissions of TFTP acknowledgements.
- Note
- TFTP module implements the retransmission mechanism by invoking this function periodically. So that method has to be added to IoT Timer client list and has to be called with minimum of TFTP_RETRANSMISSION_INTERVAL resolution.
- Parameters
-
[in] | wall_clock_value | The value of the wall clock that triggered the callback. |
- Return values
-
Frees assigned sockets.
- Parameters
-
[in] | p_tftp | Pointer to the TFTP instance. |
- Return values
-
NRF_SUCCESS | on successful execution of procedure, else an error code indicating reason for failure. |