udp: UDP/IP socket functions

Top  Previous  Next

The UDP socket functions are used for communicating over the internet via IP-networks. The udp() functions use UDP/IP.

For TCP/IP support, please see TCP/IP socket functions.

 

Please see the example program (shown for each function):

 


udpStartListen

Starts to listen for data


udpStopListen

Stop listening for data


udpReceive

Receive data


udpSend

Send data

 

 

For NX32L based devices it is recommended to use the Advanced so socket API.

 

IP address format:

In all places where an IP address aaa.bbb.ccc.ddd is stored in a DINT, the following format is used:

 

ddd is stored in bit 24..31.

ccc is stored in bit 16..23.

bbb is stored in bit 8..15.

aaa is stored in bit 0..7.