
Reference Manual
Chapter
4
IVC-2D
©
SICK AG • Advanced Industrial Sensors • www.sick.com • All rights reserved
183
Communication
Read Ethernet Bytes
This tool is used for receiving a number of bytes – that is, integer values between 0–255
– from another device over an Ethernet connection.
The received values are stored in the table as numerical values. The first received value is
stored in table row
Table index
, the next value in row
Table index
+1 etc, until a total
number of
Expected bytes
have been received.
If the other device sends more data than expected, the remaining bytes are queued and
will be read the next time a 'Read Ethernet' tool is used with the connection.
In order to receive data from a device, a connection to that device must have been
opened with the 'Open Ethernet Raw' tool. The program step in which the connection was
opened is used as the parameter
Open step
.
Input Parameters
01=Open step
The program step in which the connection was opened.
02=Timeout
The time in milliseconds during which the camera will try to
receive data. This includes the time it takes to establish the
connection, if necessary.
03=Expected bytes
The number of values that are expected to be received.
04=Table index
Table row in which to store the first received value.
The tool will store values in the table rows from
Table index
to
(
Table index
+
Expected bytes
-1)
Returned Values
01=Received bytes
The number of bytes that have been received and stored in the
table.
Error Messages
Err. = 1
The program step referred to by
Open step
is not an 'Open
Ethernet Raw' step.
Err. = 8000
Connection timed out.
Err. = 8001
Connection is broken.
Err. = 8002
Not possible to connect to the specified device.
Err. = 8004
The specified connection is for sending data only.
The Emulator does
not emulate this
tool. See section
Handling the
Emulator for more
information.