Used for sending and receiving UDP datagrams
To send to a remote UDP service, simply use Network.UDP.connect() to create an instance of this class and then use the stream methods to send datagrams. To set up a UDP server bound to a particular port, call the Network.UDP.bind() method, then use the read() methods to receive datagrams. Note that UDP is inherently unreliable. There is no guarantee that a packet you send will arrive at the destination, or if you send multiple packets within a short time that they will arrive in the same order as you sent them. This unfortunate behaviour is due to the way the icmp "port unreachable" mechanism works.
|
|
|