udpAddrMakePLCopen motion icon

Description

This function builds an address buffer for UDP functions. This function is required for building an internal "UDP" address to be passed to the udpSendTo function in case of UDP client processing.

Arguments

Input

En Description Execute the function
  Data type BOOL
  Range [0,1]
  Unit n/a
  Default
IPaddr Description IP address in the form XXX.XXX.XXX.XXX
  Data type STRING
  Range [0.0.0.0,255.255.255.255]
  Unit n/a
  Default

port Description IP port number
  Data type DINT
  Range [0,+65535]
  Unit n/a
  Default
add[] Description Buffer where to store the UDP address (filled on output)
  Data type USINT
  Range [0,32]
  Unit n/a
  Default

Output

OK Description Returns true when the function successfully executes. See Function - General rules.
  Data type BOOL
  Unit n/a

Examples

Structured Text

bAddrMake := udpAddrMake('10.156.238.176',Server_Port,add); //server details

Ladder Diagram

Function Block Diagram