31#ifndef _TFTP_SERVER_MISC_H
32#define _TFTP_SERVER_MISC_H
44void tftpServerTick(TftpServerContext *context);
46TftpClientConnection *tftpServerOpenConnection(TftpServerContext *context,
47 const IpAddr *clientIpAddr, uint16_t clientPort);
49void tftpServerCloseConnection(TftpClientConnection *connection);
51void tftpServerAcceptRequest(TftpServerContext *context);
53void tftpServerProcessPacket(TftpServerContext *context,
54 TftpClientConnection *connection);
56void tftpServerProcessRrqPacket(TftpServerContext *context,
const IpAddr *clientIpAddr,
57 uint16_t clientPort,
const TftpRrqPacket *rrqPacket,
size_t length);
59void tftpServerProcessWrqPacket(TftpServerContext *context,
const IpAddr *clientIpAddr,
60 uint16_t clientPort,
const TftpWrqPacket *wrqPacket,
size_t length);
62void tftpServerProcessDataPacket(TftpClientConnection *connection,
63 const TftpDataPacket *dataPacket,
size_t length);
65void tftpServerProcessAckPacket(TftpClientConnection *connection,
66 const TftpAckPacket *ackPacket,
size_t length);
68void tftpServerProcessErrorPacket(TftpClientConnection *connection,
69 const TftpErrorPacket *errorPacket,
size_t length);
71error_t tftpServerSendDataPacket(TftpClientConnection *connection);
72error_t tftpServerSendAckPacket(TftpClientConnection *connection);
74error_t tftpServerSendErrorPacket(TftpClientConnection *connection,
75 uint16_t errorCode,
const char_t *errorMsg);
77error_t tftpServerRetransmitPacket(TftpClientConnection *connection);
error_t
Error codes.
Definition error.h:43
IP network address.
Definition ip.h:72