NetBurner 3.1
TFTP - Trivial File Transfer Protocol

Modules

 TFTP Return Codes
 

Functions

int GetTFTP (PCSTR fileName, PCSTR mode, puint8_t buffer, int &len, uint32_t timeout, IPADDR4 server, uint16_t port=IANA_TFTP_PORT)
 Get a file from a TFTP server. More...
 
int SendTFTP (PCSTR fileName, PCSTR mode, puint8_t buffer, int len, uint32_t timeout, uint32_t packetTimeout, IPADDR4 server, uint16_t port=IANA_TFTP_PORT)
 Send a file to a TFTP server. More...
 

Detailed Description

The NetBurner TFTP Group

Function Documentation

◆ GetTFTP()

int GetTFTP ( PCSTR  fileName,
PCSTR  mode,
puint8_t  buffer,
int &  len,
uint32_t  timeout,
IPADDR4  server,
uint16_t  port = IANA_TFTP_PORT 
)

Get a file from a TFTP server.

Parameters
fileNameName of file to retrieve
modeTransfer mode. 'b' = binary, 't' = text
bufferData destination buffer
lenMaximum length when function is called, bytes read upon function return.
timeoutTotal amount of time for file transfer, in system TimeTicks
serverIPv4 address of TFTP server
portOptional TFTP server port number. If not specified the default TFTP port number 69 will be used.
Returns
TFTP Return Codes
See also
SendTFTP

◆ SendTFTP()

int SendTFTP ( PCSTR  fileName,
PCSTR  mode,
puint8_t  buffer,
int  len,
uint32_t  timeout,
uint32_t  packetTimeout,
IPADDR4  server,
uint16_t  port = IANA_TFTP_PORT 
)

Send a file to a TFTP server.

Parameters
fileNameName of file to retrieve
modeTransfer mode. 'b' = binary, 't' = text
bufferData destination buffer
lenLength of file to transfer, in bytes
timeoutTotal amount of time for file transfer, in system TimeTicks
packetTimeoutTimeout for any single UDP packet to successfully transfer and be acknowledged, in system Time Ticks
serverIPv4 address of TFTP server
portOptional TFTP server port number. If not specified the default TFTP port number 69 will be used.
Returns
TFTP Return Codes
See also
SendTFTP