Configuring Systems for Terminals, Printers, and Other Serial Devices (32022-90057)
Describing Asynchronous Devices
How to Control Terminals
Chapter 9
178
It is possible to not use parity at all. This is called none parity or 8-bit pass-through.
Neither the sender nor receiver of data sets the eighth bit or checks it for parity. (A
terminal using a 7-bit character set and no parity places a zero in the eighth position so
that characters being transmitted are always eight bits long.)
Parity can be enabled through the FCONTROL intrinsic or the FDEVICECONTROL intrinsic.
When enabled, the ASC software generates parity on outgoing data and checks for parity
errors on incoming data. After the parity is checked, the parity bit is set to zero because
the program using the data has no need for parity information. Parity checking is
handled the same way in block mode as in character mode.
Parity settings for terminals must match the type of parity used by the ASC software.
The default parity setting for HP terminals is to generate zeros parity, but not to check
parity on data from the computer. HP terminals will work correctly with the ASC
software without having to modify any configuration values.
If enabling parity, verify that the program which uses the FCONTROL or the
FDEVICECONTROL intrinsic either requests that the user change the terminal’s parity
setting to the new setting of the ASC software or pass the proper escape sequences to
change the terminal’s settings. When a parity error is detected, the read is completed in
error. The ASC software reports the error to the program reading the data.
Input Modes
Data can be input in character mode or block mode. Characteristics and limitations for
each are determined by the ASC software and the attached terminal.
Character Mode
Characters are transmitted to the DTC as they are typed. The DTC expects to receive
them this way. If DTC echo is enabled, characters are echoed back to the screen as they
are received.
Character mode is how terminals are opened, whether by a session or a program.
Character mode reads are terminated with the carriage return character (
[Return]
or
[CTRL]-M
).
Block Mode
When a terminal operates in block mode, characters are held in the terminal's memory
(buffer) as they are typed. Characters are not transmitted to the DTC until a specific
action is taken. Pressing
[Enter]
at the end of a block of data will normally send it to the
DTC.
An application program can use an alternate method to end a block mode read. Refer to
“Terminating Reads” later in this chapter for more information on ways to end a block
mode read.
Block mode is enabled programmatically by executing a block mode application at the
terminal. The program needs to change the terminal’s configuration settings. It should
do this automatically by sending escape sequences to the terminal.
Blocks of characters can be input to the DTC a line at a time (called line block mode) or a
page at a time (called page block mode), depending on the type of block mode used.
Because characters are displayed on the screen as they are entered, local editing and
cursor control features can be used to alter a line or page before it is transmitted to the
DTC.