User Manual
Parameters: None
Returns: Nothing
int beginPacket (IPAddress ip, uint16_t port)
Starts a UDP connection to write data to the specified remote IP address and port.
Parameters:
ip: The remote IPAddress (https://adafru.it/lGd) where the UDP server is located
port: The remote port number to connect to (0..65535)
Returns: '1' if successful, '0' if there was a problem connecting to the specified IP address or port.
int beginPacket (const char *host, uint16_t port)
Starts a UDP connection to write data to the specified domain name and remote port.
Parameters:
host: A string containing the domain name to connect to
port: The port number to connect to (0..65536)
Returns: '1' if the connection was successfully established, otherwise '0'.
int endPacket (void)
This function must be called after writing UDP data to the remote server.
Parameters: None
Returns: '1' if the packet was sent successfully, otherwise '0'.
int parsePacket (void)
Checks whether a UDP packet is available, and returns the size of the UDP packet as a return value.
Parameters: None
Returns: The number of bytes available in the buffered UDP packet.
IPAddress remoteIP (void)
Returns the IP address of the remote UDP server.
You must call this function BEFORE reading any data from the buffer via AdafruitUDP.read()!
AdafruitUDP.parsePacket() must be called BEFORE this function.
© Adafruit Industries https://learn.adafruit.com/introducing-the-adafruit-wiced-feather-wifi Page 88 of 202










