SCIENTIFIC TECHNOLOGIES INC.
R
8
6
Serial Output
The serial port is used for software setup
and for seial output reports. For serial reports
you must set a serial report, set a serial timing
mode, then save your settings.
You are not required to use the serial
output. In many cases where only detection is
needed, the default settings will work and no
serial setup is required.
S
ERIAL
R
EPORT
C
OMMUNANDS
Serial output report commands determine
what information is reported on the serial port.
Only one command can be used at any time.
Issuing any command erases the previous
setting.
Serial reports give the status of the scanner
during one scan. Data is in binary or ASCII
format. If the scanner does not respond to your
commands press
ESC
twice and
Enter
.
Array modifying commands may be used,
however, the SCREEN function does not affect
ASCII RAW and BINARY RAW modes. (See
section 7 – Array Modifying Commands.)
ASCII Serial Data Modes
In this section values that are written out
are in base ten; values using numerals will be
shown with their base as a subscript. Example:
a decimal value of fifteen will be shown as 15
10
,
or F
16
in hexadecimal, or 1111
2
in binary.
Reports in ASCII format give hexadecimal
values and are easily read by terminal
emulators. The data transmitted are the ASCII
codes for the hexadecimal characters. Each
ASCII character requires one byte. All values
are reported in hexadecimal. Example: An
object blocks ten beams. In the
ASCII SIZE
mode,
the scanner sends the ASCII code for the
character “A”. The ASCII code number is 65
10
or 41
16
.
ASCII NULL Mode
ASCII NULL Mode turns off serial data
reports
Syntax:
ASCII NULL
Data format: none
Comment: BINARY NULL does the same thing.
ASCII RAW Mode
ASCII RAW Mode gives the status of each
beam.
Syntax:
ASCII RAW
Data Format: Reports a string of ASCII
characters for hexadecimal digits. The string
ends with the ASCII character 13
10
(carriage
return). Each hexadecimal digit represents the
status of four beams by direct conversion to
binary. Binary zero represents an unblocked
beam and binary one represents a blocked beam.
Example:
Beam status
1111000010100001
2
(Leftmost
digits are farthest from the
cable.)
Hex digits
F0A1
16
(Every four binary digits
converts to one hexadecimal
digit.)
ASCII Codes
70
10
(ASCII for F character)
48
10
(ASCII for 0 character)
65
10
(ASCII for A character)
49
10
(ASCII for 1 character)
13
10
(ASCII for carriage return)
ASCII LIST Mode
ASCII LIST reports the number of objects
detected, the position and size of each object for
a maximum of 16 objects. The report is a
variable length string consisting of:
1) two ASCII characters for the hexadecimal
number of objects detected; and
Section 6 – Serial Output