3.4 Using The Keyboard Under
CP/M
Since
CP
1M
has been designed as a universal operating system, it does not neces-
sarily allow all the special keys
on
the PX-8
to
function as they do in BASIC
or
in some applications programs. In particular the cursor keys are
not
sup-
ported by
CP/M.
Some
of
the special keys behave differently. The following
summarises the use
of
the different functions available form the keyboard when
the PX-8
is
on
the
CP
1M
command line. They do not hold for the MENU com-
mand line.
3.4.1 Using the programmable function keys
The keys
~
to
I PF5 I and their shifted counterparts can be used
to
print the
common
CP
1M
command words, thus preventing errors and saving time. When
setting them up, it
is
worth ensuring
that
trailing spaces are included
to
con-
form with the requirements
of
CP
1M.
The key display
is
normally absent from
the lowest line
of
the screen
but
can be switched on using the CONFIG pro-
gram. Another alternative in deciding which key provides which string
is
to
use
the attached Programmable Function key label. The CONFIG program also
allows alteration
of
the strings given by each key.
3.4.2 Line termination commands
When you have entered a command, you must tell
CP
1M
that you have finished.
There are three key commands to do this:
The
I
RETURN
I key
is
the simplest way
to
enter a command.
A
I
CTRL
I -
[MJ
is
equivalent to a pressing the I
RETURN
I key.
A
I
CTRL
I -
QJ
is
equivalent to a line feed.
On
the
CP
1M
command line it
also causes the command to be entered as though you had pressed the
I
RETURN
I
key.
3.4.3 Character deletion commands
If
a mistake
is
made, it
is
necessary to correct it. This can be done in two ways,
but
the CURSOR KEYS CANNOT BE USED.
I
CTRL
I -
[Hl
or the
BS
(backspace) characters delete the character
to
the left
of
the cursor from the screen and move the cursor one step back.
The
[QKJkey
causes the key
to
the left
of
the cursor to be deleted,
but
also
repeats the deleted character on the screen.
lethe
~
or I
CTRL
I -
[Hl
is
used
3-10
to delete another character it will place the cursor one place
to
the left
of
this
deleted character because any characters deleted by
the[QKJkey
do not exist
except
on
the screen.
3.4.4 Line deletion commands
Sometimes it
is
necessary to delete a whole line when a mistake
is
made or for
other reasons. There are two ways
to
do this:
00
will backspace
to
the beginning
of
the line, erasing all
of
the text.
I
CTRL
I -
[Q]
will place a " # " character
at
the end
of
the line and then place
the cursor
on
the next line ready
to
start over again. This
is
useful, because
the incorrect command
is
still present on the screen, although it has been erased.
3.4.5 Display control commands
There are a number
of
control key sequences which can be used to handle the
screen display. Again not all the special keys work, although some can be made
to
perform their function to a limited extent.
The
I
CLR
I key can be used to clear the screen, although it
is
not supported by
CP/M.
It
is
equivalent to a I
CTRL
I -
UJ
. Typing either
of
these commands
causes the
CP
1M
command line to show:
Pressing the
I
RETURN
I key will clear the screen, printing a question mark in the
top
left hand corner. The system prompt will be placed
on
the third line. This
is
because
if
you give
CP
1M
a command it does
not
understand it will repeat
the command followed by a question mark and return the system prompt.
I
CTRL
\ -
[f]
can be used
to
overflow on
to
the next line before the user has
pressed the
I
RETURN
\ key. This
is
useful
if
the screen
is
split (screen mode 1
or
2), as it enables a new word
to
be written
on
to
a new line so
that
it can
be read more easily.
The"
#"
character
is
placed
at
the end
of
a
l~ne
when
using the \
CTRL
\ -
[Q]
or
I
CTRL
\ -
[BJ
command to show it
is
a terminated
line, to distinguish it from a
1
CTRL
\ -
[f]
.
I
CTRL
\ -
[BJ
is
used to repeat a line with the errors removed
if
you are a bad
typist and using the
I
DEL
I key frequently. For example
if
you type an
"R"
in-
stead
of
a
"T"
in the
"STAT"
command, and ha(Cdeleted the
"R"
using DEL,
and
pressed I
CTRL
\-
[BJ
keys after typing
"T"
again the screen would show:
3-11