Programming instructions

Intermec Fingerprint v7.61 Programmers Reference Manual Ed. 744
Chapter 2 Program Instructions
COM ERROR ON/OFF
Field of Application
Statement enabling/disabling error handling on the specified
communication channel.
Syntax COM
ERROR<nexp>ON|OFF
<nexp> is one of the following communication channels:
1 = "uart1:"
2 = "uart2:"
3 = "uart3:"
4 = "centronics:"
Default: COM ERROR OFF on all channels.
Remarks
This function is closely related to COMSET, ON COMSET GOSUB,
COMSET ON, COMSET OFF, COMSTAT, and COMBUF$.
Each character received is checked for the following errors:
Received break
Framing error
Parity Error
Overrun error
If any such communication error occurs and COM ERROR is ON for the
channel in question, the reception will be interrupted. This condition can
be read by means of a COMSTAT function, but you cannot read exactly
what type of error has occurred. COM ERROR OFF disables this type of
error-handling for the speci ed channel.
COM ERROR ON cannot be used with USB (communication channel #6).
Example
In this example, a message will appear on the screen when the reception is
interrupted by any of four COMSET conditions being ful lled:
10 COM ERROR 1 ON
20 A$="Max. number of char. received"
30 B$="End char. received"
40 C$="Attn. string received"
50 D$="Communication error"
60 COMSET 1, "A",CHR$(90),"#","BREAK",20
70 ON COMSET 1 GOSUB 1000
80 COMSET 1 ON
90 IF QDATA$="" THEN GOTO 90
100 END
1000 QDATA$=COMBUF$(1)
1010 IF COMSTAT(1) AND 2 THEN PRINT A$
1020 IF COMSTAT(1) AND 4 THEN PRINT B$
1030 IF COMSTAT(1) AND 8 THEN PRINT C$
1040 IF COMSTAT(1) AND 32 THEN PRINT D$
1050 PRINT QDATA$:RETURN