8017035/ZMO9/2017-06-08 • © SICK AG • Subject to change without notice.
115
Serial Communication
Acquiring the profile size
The profile size varies depending on the settings. Therefore, use the
following command to acquire the profile size. Enter the acquired address
in the “Address” part of the command. All other parts are fixed values.
Send
02
03
00
02
03
06
20
00
01
11
03
34
STX
Length
Acquisition
command
Address
rlen
(Fixed
value)
ETX
Sum
Reply
02
03
00
02
03
06
20
00
68
00
10
0E
03
4C
STX
Length
Acquisition
command
Address
Size
Time informa-
tion
ETX
Sum
The value obtained here is 0x6800. Dividing this value by 32 gives 832,
which is the number of profiles.
For time information, a value is input that represents a count in 0.1 ms
units the time from power on and startup.
Reading profiles
After you acquire the address and size of the profile, read the profile values.
The maximum data that can be read with a single command is 126 (0x7E), so
use multiple commands to read the profile.
Also, the reading of the address starts after the 4 bytes of the profile header
are added.
Since the data size of each profile coordinate is 2 words (4 bytes), the read
data size is "2".
Send
02
03
00
02
03
06
20
04
7E
21
03
7F
STX
Length
Acquisition
command
Address
rlen
Thinning
ETX
Sum
* The value “03 4” is assigned to the address.
Reply
02
FF
00
02
03 06 20 04 CC F9 10 35 CD 1D …
…
…
03
02
STX
Length
Acquisition
command
Address
X0
Y0
X1
Y1
…
ETX
Sum