EasyManua.ls Logo

RayTek LineScanner MP150 - 3 Transmission of Scanner Commands; 3.1 Command Structure

Default Icon
42 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Transmission of Scanner Commands
MP150 Protocol Rev. B4 Aug 2019 9
3 Transmission of Scanner Commands
Commands serve to setup functional modes and parameters in the scanner.
3.1 Command structure
Commands are generally transmitted from the PC to the scanner, and have the following format:
SOH Operation Code [Sector] [Parameter] EOT BCC
The [Operation Code] and [Parameter] are to be find in section 7.1 and the [Sector] is described in section
5.2.
The frame (composed of SOH, EOT and BCC) may be left out, but should be used in the RS485
connection to avoid communication errors. (The predecessor MP50 did require the frame.)
If a command was sent with the frame, then the scanner will answer with the frame. The decision
with/without frame is made at the first sign (SOH or not SOH).
These ASCII control characters used in the protocol with their associated decimal and hexadecimal
values are the following:
Control character
hexadecimal
SOH
„start of heading”
01H
STX
„start of text”
02H
EOT
„end of transmission”
04H
ACK
„acknowledge”
06H
NAK
„negative acknowledge
15H
SYN
„synchronous idle”
16H
EOF
„end of file”
1AH
ETB
„end of transmission block
17H
ESC
„escape”
1BH
During command and parameter transmission, transmission reliability is checked with a Block
Character Checksum (BCC).
The BCC is transmitted as the last byte of the command or parameter string. The BCC is a modulo 256
sum of all previously transmitted characters and bitwise OR-ed with 80H or 128D (to set the highest bit
of the BCC).
Example (send the command AR):
SOH 01H
”A” 41H
”R” 52H
+ EOT 04H
BCC = 98H
and afterwards, bitwise OR-ed with 80H yields (which, in this case, does not change the byte’s value):
BCC = 98H

Table of Contents

Related product manuals