02.10.2012 Views

Programmer's Reference Manual Intermec Fingerprint® v8.70.0 ...

Programmer's Reference Manual Intermec Fingerprint® v8.70.0 ...

Programmer's Reference Manual Intermec Fingerprint® v8.70.0 ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

COM ERROR ON/OFF<br />

Chapter —Program Instructions<br />

Purpose Statement enabling/disabling error handling on the specified communication<br />

channel.<br />

Syntax COM ↔ ERRORON|OFF<br />

is one of the following communication channels:<br />

1 = "uart1:"<br />

2 = "uart2:"<br />

3 = "uart3:"<br />

4 = "centronics:"<br />

7 = "uart4:"<br />

8 = "uart5"<br />

Default: COM ERROR OFF on all channels.<br />

Remarks This function is closely related to COMSET, ON COMSET GOSUB,<br />

COMSET ON, COMSET OFF, COMSTAT, and COMBUF$.<br />

Each character received is checked for the following errors:<br />

• Received break<br />

• Framing error<br />

• Parity Error<br />

• Overrun error<br />

If any such communication error occurs and COM ERROR is ON for the<br />

channel in question, the reception will be interrupted. This condition can<br />

be read by means of a COMSTAT function, but you cannot read exactly<br />

what type of error has occurred. COM ERROR OFF disables this type of<br />

error-handling for the specified channel.<br />

COM ERROR ON cannot be used with USB (comm. channel #6).<br />

Example In this example, a message will appear on the screen when the reception is<br />

interrupted by any of four COMSET conditions being fulfilled:<br />

10 COM ERROR 1 ON<br />

20 A$="Max. number of char. received"<br />

30 B$="End char. received"<br />

40 C$="Attn. string received"<br />

50 D$="Communication error"<br />

60 COMSET 1, "A",CHR$(90),"#","BREAK",20<br />

70 ON COMSET 1 GOSUB 1000<br />

80 COMSET 1 ON<br />

90 IF QDATA$="" THEN GOTO 90<br />

100 END<br />

1000 QDATA$=COMBUF$(1)<br />

1010 IF COMSTAT(1) AND 2 THEN PRINT A$<br />

1020 IF COMSTAT(1) AND 4 THEN PRINT B$<br />

1030 IF COMSTAT(1) AND 8 THEN PRINT C$<br />

1040 IF COMSTAT(1) AND 32 THEN PRINT D$<br />

1050 PRINT QDATA$:RETURN<br />

<strong>Intermec</strong> Fingerprint <strong>v8.70.0</strong>/v10.0.0 Programmer´s <strong>Reference</strong> <strong>Manual</strong> 1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!