Programming instructions

42
Intermec Fingerprint 6.13 – Programmer's Guide
5. FINGERPRINT PROGRAMMING, cont'd.
10. Program Structure
Although Fingerprint gives the programmer a lot of freedom in
how to compose his programs, based on experience we recommend
that the structure below is more or less implemented, with the
obvious exception of such facilities that are not needed.
Program Information
Program information, e.g. program type, version, release date
and byline (REM).
Initiation
Decides how printer will work and branch to subroutines.
References to subroutines using e.g. ON BREAK GOSUB,
ON COMSET GOSUB, ON ERROR GOSUB, ON KEY
GOSUB.
Printer setup using e.g. SETUP, RIBBON SAVE ON/OFF,
OPTIMIZE ON/OFF, LTS& ON/OFF, CUT ON/OFF, FOR-
MAT DATE$, FORMAT TIME$, NAME DATE$, NAME
WEEKDAY$, SYSVAR).
Character set and map tables (NASC, MAP).
Enabling keyboard (KEY ON, KEYBEEP, KEYBMAP$).
Initial LED setting (LED ON/OFF).
Open "console:" for output (OPEN)
Assign string variables for each line in the display (PRINT#).
Select current directory (CHDIR).
Select standard I/O channel (SETSTDIO).
Open communication channels (OPEN).
Open files (OPEN).
Define arrays (DIM).
Main Loop
Executes the program and keeps it running in a loop.
Reception of input data (INPUT, INPUT#, INPUT$, LINE
INPUT#).
Printing routine (FORMFEED, PRINTFEED, CUT).
Looping instructions (GOTO).
Subroutines
Break subroutines (BREAK ON/OFF, BREAK).
Background communication subroutines (COM ERROR ON/
OFF, COMSET, COMSET ON/OFF, COMBUF$,
COMSTAT).
Subroutines for key-initiated actions.
Subroutines for display messages.
Error handling subroutines (ERR, ERL, PRSTAT).
Label layouts subroutines.