#ANSI Graphics on Rainbow
2 messages in this thread
Rick: For characters 128-255 on the Rainbow, I have two sources: (1)
Rainbow MS-DOS Version 2.11 Advanced User's Guide, page 4-37: in
explaining the use of the SORT command, it lists characters 0 through 255
in SORT order; (2) Rainbow Owner's Manual, appendix F, p. 139: a chart of
all 256 "DEC Multinational Characters" in numerical order with octal,
decimal, and hexadecimal equivalents.
But these are not the "Graphics" characters used to draw lines, boxes, and
checkerboards on the screen. To activate those (called the "Special
Characters and Line Drawing Character Set" in the Rainbow Owner's Manual
appendix H, p.184) you have to send an escape sequence to the screen:
either ESC ( 0 or ESC ) 0 depending on the currently selected character set
(G0 or G1). And to get back to the "U.S. Character Set" you have to send
the corresponding escape sequence ESC ( B or ESC ) B. (I can attest also
that the LA50 printer has the "Special Characters" and responds to the same
escape sequences.)
The "Special Characters and Line Drawing Character Set" are assigned to
some of the bytes from 0 to 127, _not_ 128 to 255. I don't have a list of
them. They are probably described in the VT100 or VT102 terminal manuals,
which I don't have. Who needs them? Make a file with ESC ( 0 or ESC ) 0 in
it and TYPE it (or just enter PROMPT $e(0 or PROMPT $e)0 at the MS-DOS
prompt), and then hit a few keys! If it's confusing, hit the LOCK key.
(Uppercase letters are unchanged in the Special Character set.)
Brian,
Just for the record, and apropos of your note a few days ago inquiring
about ANSI character-set switching…
The "special character/line drawing set" *can* be set up to map to
*either* the 0-to-127 range, OR the 128-to-255 range.
Here's how it works.
The machine (Rainbow, VT2xx, VT3xx, etc.) has several character sets
on-board. Some machines also support downloadable soft character sets. In
total, these add up to way more than 256 characters, but it's not practical
to have to send two bytes to generate each character on the screen, so one
really wants a way of generating any arbitrary character with one byte.
ANSI handles this by dividing the 0-to-255 space into two "halves",
called GL and GR (0-to-127 and 128-to-255 respectively). In addition,
there can be as many as four concurrently-available character sets,
designated as G0, G1, G2, and G3; each character set holds 128 symbols.
ANSI commands exist to map one of the potentially-many on-board or soft
character sets to G0, G1, G2, or G3. For instance, ESC ( B maps the normal
ASCII set to G0; ESC ) B maps it to G1; ESC * B to G2, and ESC + B to G3.
Replace the "B" with a "<" and you can assign the DEC Supplemental (DEC
multinational) character set to one of the four available sets. "0"
instead of "B" maps the "DEC special graphics" (line-drawing) character
set. And some machines have a variety of national character sets (British,
Swiss, etc.) that can be similarly mapped.
From this set of 4 currently-available sets, one can assign two as
"active": one to GL, one to GR. The single-byte SI (octal 16, I think)
maps G0 to GL. SO (octal 17) maps G1 to GL. ESC ~ maps G1 to GR, ESC } maps
G2 to GR, ESC | maps G3 to GR… and there are other sequences for the
other combinations.
So the right sequence of sequences can give you just about any character
set in *either* (or both!) of GL and GR, under software control.
-Bill
P.S. Much of the above is based on the VT200 series. The Rainbow
probably doesn't have as many sets and may not support G2 and G3… I'm not
sure.