Ascii Coding; Read And Type Routines - RCA CDPl8S693 User Manual

Table of Contents

Advertisement

2. Features of UT62 Monitor Program
Examplest:
E
MCDS TAPE EDITOR VERSION X.X
A Commands (CDP18S694 only)
Name:
Run Assembler
Purpose:
To start execution of the Level I
assembler
Format:
A
Action:
System pauses to search for the top of
the free RAM and then issues the title
and starts by asking for "READ" tape.
For subsequent action refer to Chapter
5, Running the MCDS COSMAC
Resident Assembler (CRA).
Examplest:
A
MCDS ASSEMBLER VER. X.X
READ?
C Commands
Copy to Monitor
Name:
Purpose:
To display ASCII file on the Video
Monitor from tape.
Format:
C
Action:
Data in ASCII format is read from tape
and displayed on the Video Monitor.
After twenty Carriage Returns (ASCII
ODH). The display is stopped and 4 *'s
are displayed on the bottom line. To
restart the display, press any key. While
characters are being written on the
screen (not while the tape is being read)
pressing the BREAK key will halt the
display. Pressing the Q key will abort
the routine and return the prompt.
Pressing any other key will start the
display. (The space bar is recommended
because whichever key is pressed is
echoed to the screen.)
Examplef:
C
TAPE# 0 (CR)
user's code

ASCII Coding

The CDP18S693 and CDP18S694 are designed to
interface to a data terminal via a serial ASCII code
using either a 20-mA current loop or an EIA RS232C
standard electrical interface. When a key is struck on a
TTY terminal, the information denoting that character
is converted to its ASCII code and appears on the
output terminals as a serial data-bit stream. The serial
data originating at the TTY for the letter 'M'is shown
in Fig. 3. The character is framed by a start bit B and
two stop bits FF. By convention two stop bits are used
for data transmission at 10 characters per second
although 1, 1 ' / 2, or 2 are also acceptable outputs from
various different terminals. A parity bit P is also
shown. For even parity, the parity bit would be a '1'
only if the 7 data bits contain an odd number o fT s.
fIn these examples the system response is indicated byan underline.
Hence, the total number of l 's in the eight intelligence
bits is always an even number. Some data terminals
may be set up to generate either even or odd parity.
UT62 ignores the parity bit, so either even or odd
parity is acceptable.
LOGIC I -----
2
3
4
LOGIC 0
I D I I D I D I
ACTUAL
DATA BITS
INTELLIGENCE BITS
* ----- 7 DATA BITS
PLUS I PARITY BIT
_____ COMPLETE CHARACTER
" M " (4 D |6 )
* = ONE BIT TIME
P = PARITY BIT
D= DATA BIT
B = START BIT
F = STOP B IT
------- =ASYNCHRONOUS TIME
Fig. 3—Data terminal bit serial output for the
character "M ".
Data from the MCDS are generated with the same
format; i.e., a start bit, 7 data bits, a parity bit, and two
stop bits. Note that the MCDS does not generate
parity—the parity bit is always a '1' regardless of the
data bits. Therefore, terminals interfacing to the
MCDS should ignore the parity bit.

Read and Type Routines

The UT62 read and type routines provide the basic
software mechanism for communication between the
System and the data terminal. Several different
routines are available to facilitate different types of
I/O data transfers. These routines are listed in Table I.
These routines are designed to allow adoption to
various terminal speeds and to determine whether or
not characters read in should be "echoed" (i.e., typed
back immediately). For these purposes, a 'sub-
su b routine' called DELAY1 is included which
provides the necessary bit timing delays to the read and
type routines. DELAY 1 uses the CDP1802 register RC
as its program counter, which must be set-up to point
to location 80EF. UT62 does this set up automatically
when it is started. Any user program using a read or
type routine must not alter RC, or must restore it to
80EF before calling a read or type routine. Also, the
upper half of register RE (RE.1) contains a control
constant. The least significant bit specifies echo (0
denotes echo, 1 denotes no echo). For full-duplex
operation, then, this bit is a zero. Again, this bit is
automatically set when UT62 is started and the CR or
LF characters received.
The remainder of RE.1 constitutes a timing
---------------- i H
7
5
6
8
I D I P
D | D
B
»J
*
----- <
BETWEEN CHARACTERS
9 2 C S - 3 2 9 6 I
9

Advertisement

Table of Contents
loading

This manual is also suitable for:

Cdpl8s694

Table of Contents