0x00
up to 0x1F
are control characters, eg. 0x0D
:
Carriage Return; on a Teletype (working like an electric typewriter) it has to be taken literally!
0x20
up to 0x7E
are normal characters.
Unfortunately it was missed here to define country-specific characters.
Eg. the character 0x7B
will be displayed in American as {' but in German as 'ä' - not to mention other languages.
0x7F
.
This is a very special character- RUB OUT (bit pattern 1111111).
RUB OUT (punch) points to the fact that a Teletype was equipped with a paper tape puncher.
On an invalid input simply the key RUB OUT was pressed, whereby the paper tape was punched accordingly (all holes punched) - not a very good idea for a screen device.
0x1b
) does exist.
Mostly this character was used as a lead-in for cursor settings.
(But some manufacturers used special control characters for controlling the screen).
In the beginning any manufacturer had his unique set of control sequences.
With their VT models (Video Terminal) the company Digital Equipment Corporation (DEC) created a standard.
Look here for a compilation of documents for the VT series.
The control sequences are well documented in the VT100 User Guide.
When CP/M came on the market no standard was available.
But MS-DOS already used the ANSI controls.
Look here for an overview in the MS-DOS environment.
TINST.COM
allows the installation of any terminal.
Look here for a section out of nearly endless combinations.
When the Joyce came on the market it did not use the ANSI standard
but control sequences for the Zenith Z19/Z29 terminal.
Look here for an overview for this terminal.
Recognize the similarity of both pf the control sets.
When I started to connect to the world with my machine Joye and a MODEM, I used the terminal emulation part of the tool KERMIT.
Those institutions I connected to did support the VT 100 terminal and I wrote an ANSI emulator for proper work with it.
I implemented the sequences in the following way:
Function | ANSI sequence | JOCYE conversion |
---|---|---|
Cursor up | ESC [ Pn A | Pn-mal ESC A |
Cursor down | ESC [ Pn B | Pn-mal ESC B |
Cursor right | ESC [ Pn C | Pn-mal ESC C |
Cursor left | ESC [ Pn D | Pn-mal ESC D |
Cursor setting | ESC [ P1;P2 H | ESC Y P1+31 P2+31 |
Erase screen | ESC [ Pn J | ESC J |
Erase line | ESC [ Pn K | ESC K |
Set attributes | ESC [ P1;..;Pn m |
Px=0 ESC u ESC q Px=4 ESC r Px=7 ESC p |
Later on I implemented an ANSI RSX with additional functions: | ||
Function | ANSI sequence | JOCYE conversion |
Cursor setting | ESC [ P1;P2 f | ESC Y P1+31 P2+31 |
Save cursor position | ESC [ s | ESC j |
Restore cursor position | ESC [ u | ESC k |
ESC [ Pn J
and ESC [ Pn K
is missing to my implementation of KERMIT.
Correctly the conversion must look as follows:
Correct functionen | ||
---|---|---|
Erase screen | ||
Function | ANSI sequence | JOCYE conversion |
From Cursor to end | ESC [ 0 J | ESC J - Default |
From start to cursor | ESC [ 1 J | ESC d |
Erase all | ESC [ 2 J | ESC E |
Erase line | ||
Function | ANSI sequence | JOCYE conversion |
From Cursor to end | ESC [ 0 K | ESC K - Default |
From start to cursor | ESC [ 1 K | ESC o |
Erase all | ESC [ 2 K | ESC l |
GENCOM
;
the control program allows activating and removing of this RSX.
Here an overview of the tools:
ANSI RSX | ANSI control program | KERMIT (part 10) |