These functions are located on the COM>TCP/IP>TCP menu. Use them to send a vector of raw data to a remote Vision, broadcast the data to the entire network, or receive a stream of data and write it to a vector of registers.
The number of bytes a message can comprise varies according to Vision model:
TCP Raw is a master/slave protocol. In addition to other TCP/IP elements, the master application contains a TCP Connect function.
Configure Ethernet in your application by building a net that comprises the following elements:
|
|
Include a TCP\IP: TCP Connect function.
Configure a TCP RAW Send function to determine the data to send to a specific PLC.
Note ♦ |
Use a Send condition; do not place it directly on the left Ladder rail. |
Parameter Name |
Purpose |
Sending Socket |
The PLC sends the data through this socket. Select a socket that is initialized to UPD_RAW |
Source Start Address |
Start address of the vector containing the data |
Vector Length |
Determines the vector length |
Status |
Shows the status of the message that is sent Value Message 1 Data Sent Successfully -1 Illegal Socket (not 0-3) -2 Data length is longer than Ethernet buffer -3 Illegal operand -4 Socket not initialized -5 Protocol not TCP -6 Send failed |
The Scan function enables a PLC to receive data from a specified remote PLC and write it to a vector of registers.
Configure the application in the PLC that receives the data by building a net that comprises a Card Init function and a Socket Init function, set to UDP_RAW.
Configure a UDP RAW Scan function to receive the data.
Note ♦ |
In most applications, Scan should be active all the time. To accomplish this, place the Scan function in the main routine, directly on the left Ladder rail. |
Parameter Name |
Purpose |
Socket |
This is the socket that receives the data. This socket must be initialized to TCP_RAW |
Destination Start Address |
Start address of the vector to which the received data is written |
Vector Length |
The number of bytes received. Is reset by OS when the element activates. |
Data Arrived |
Use this to monitor message status |
Status
|
Shows the status of the message that is received: Value Message o Data Received Successfully -1 Card not initialized, or link fail -2 Illegal Socket -3 Socket not initialized -4 Protocol not TCP -5 Illegal operand -6 Data length is longer than Ethernet buffer d |