WWW.NNC.IR
Macro Reference
697
8
Appendices
Vision System FH/FZ5 Series
User’s Manual (Z340)
Example
In normal UDP communication, specifies the destination and sends data.
In PLC link, specifying the offset value and writing data to the data output area.
Useable Modules
Scene Control Macro / Communication Command Macro / Unit Macro
Supported Versions
Version 3.50 or later
Related Items
Rem Create the destination address information (10.1.1.101)
Dim IPADDR&(4)
IPADDR&(0) = 10
IPADDR&(1) = 1
IPADDR&(2) = 1
IPADDR&(3) = 101
Rem Make the transmit data.
Dim BUFFER&(4)
BUFFER&(0) = 1
BUFFER&(1) = 2
BUFFER&(2) = 3
BUFFER&(3) = 4
BUFFER&(4) = 5
Rem Transmit the data selected address.
SendData "UdpNormal", BUFFER&(), 4 * 5, IPADDR&(), 4 * 4
Rem Create the offset data.
Dim OFFSET&(0)
OFFSET&(0) = 2
Rem Make the transmit data.
Dim BUFFER&(4)
BUFFER&(0) = 1
BUFFER&(1) = 2
BUFFER&(2) = 3
BUFFER&(3) = 4
BUFFER&(4) = 5
Rem Use the offset value to send the data.
SendData "SerialPlcLink", BUFFER&(), 4 * 5, OFFSET&(), 4 * 1
ReceiveData (Reference: X Details (p.651)) SendString (Reference: X Details (p.698))