Virtual H19 Terminal
The virtual H19 terminal implements many of the terminal features.
The following keys from a modern computer keyboard are mapped to the
H19 Keys as follows:
PC Key | H19 Key | Notes |
F1-F5 | f1-f5 | |
F6 | BLUE | |
F7 | RED | |
F8 | WHITE (GRAY) | |
Shift F9 | SHIFT RESET | |
Scroll Lock | SCROLL | Shift applied as for H19 |
Shift Backspace | DELETE | |
Home | HOME | |
<Cursor> | <CURSOR> | Irrespective of which keypad |
Delete | DC | |
Shift Delete | DL | |
Insert | IC | Sends ESC @ or ESC O, whichever is opposite current mode |
Shift Insert | IL | |
Enter | RETURN | Also ENTER on keypad |
Ctrl Enter | LINE FEED | |
All other "standard" keys should have the expected results, given a direct
translation to H19 keys.
Note that the H19 keypad is emulated only when "Num Lock" is on.
The terminal settings for "Alternate Keypad mode" and "Keypad Shifted",
along with the "Shift" key on your keyboard, should work as expected.
A modern keyboard has more keys on the keypad than the H19, and those keys
do not produce values. Otherwise, the keys work as their H19 counterparts.
PC Key | H19 Key |
0 / Ins | 0 |
1 / End | 1 / IL |
2 / ↓ | 2 / ↓ |
3 / PgDn | 3 / DL |
4 / ← | 4 / ← |
5 | 5 / HOME |
6 / → | 6 / → |
7 / Home | 7 / IC |
8 / ↑ | 8 / ↑ |
9 / PgUp | 9 / DC |
. / Del | . |
Enter | ENTER |
Beware that the modern keypad alternate functions do not align with
the H19 keypad functions. However, the dedicated cursor/editing keys of
a modern keyboard do produce the appropriate codes. For example,
the "Insert" editing key produces the same codes as
the Shifted "7 / IC" keypad key on the H19, but the "0 / Ins" does not
produce the "IC" code when "Ins" is selected.
While most standard features are implemented,
the following terminal features are NOT implemented:
- Modify Baud Rate (ESC r X)
- Keyboard Disable (ESC })
- Key Click (ESC y 2)
Note that the above codes are accepted (will not cause stray characters on the screen),
but do not perform the prescribed function.
Because of the way screen characters are displayed, it is not possible
to represent the cursor exactly as the H19 - in the sense that the cursor
does not "invert" the character beneath it. This can lead to a cursor
that is difficult to see, if not invisible, when over reverse-video
characters. As a workaround, the cursor color may be set to something
different from the normal video color, thus making it always discernible.
The chosen color can be made close to normal video, to maintain more authenticity.
Basic copy-paste is supported. Clicking (button 1) and dragging will
show a faint blue area around selected text. The area
will remain highlighted for about 2 seconds after releasing the mouse button,
but text is copied to the clipboard immediately.
Text from the clipboard may be pasted into the Z19 "keyboard" stream using the middle
mouse button. Note, however, that pasting large amounts of text
may overrun the program as the data can arrive faster than
human typing speed. See properties h19_paste_rate and h19_paste_cr_wait.
The following properties control the basic and
initial functioning of the virtual terminal:
- h19_font
- The name of the (TrueType) font file to use for the H19 CRT screen.
Default is "h19a.ttf" which is built-in to the JAR. This font closely
resembles the original character generator (and video characteristics)
of the H19.
Font may be a TTF file included in the JAR,
or an absolute pathname to a TTF file on your system,
or the name of an installed (ISO character set) font on your system,
or a JAVA generic font name (e.g. "Monospaced").
Note that only monospaced fonts are likely to work well.
For custom TTF fonts:
- The graphics characters 0x00-0x1f (in ROM locations)
must be located at TTF font characters 0x100-0x11f.
- TTF font characters 0x80-0xff must represent the reverse-video version of
ROM characters 0x00-0x7f.
Fonts built in to your system:
- Must support the ISO character set that includes
the line drawing characters, in the '\u2500' range
(in order to support H19 graphics).
- The characters for the triangle
graphics symbols are not exactly the same as the H19, so some screens
(such as INVADERS) will look a little different.
- Most modern fonts do not replicate the aspect ratio of the H19,
so the screen dimensions will be different.
- The performance of the virtual H19 may be adversely affected by running ISO fonts.
- h19_font_size
- This selects the size of the font used for the H19 CRT screen.
Most systems require this number to be a multiple of 10 in order
to display clean characters. Default is 20, which is probably the
most useful value.
- h19_font_color
- Selects the color to use for the H19 CRT screen.
This color must have a good contrast ratio to the dark background
of the screen. Format is 6 hexadecimal digits where each pair
(octet) represents, respectively from hi to low, red, green, and blue.
Default is "00ff00" which is the green. An amber color is "ffc000" and
white would be "ffffff".
- h19_cursor_color
- Selects the color to use for the H19 cursor. This can be used to avoid
a "disappearing cursor" when over reverse-video characters.
- h19_beep
- Selects the WAV file to use for the H19 "beep" sound.
The default is the built-in "h19beep.wav" which is the 1/2-second,
1024Hz, beep. Other built-in files allow for different durations,
"h19beep250.wav" and "h19beep125.wav", for 1/4 and 1/8 second respectively.
Sound file must exist in the JAR file.
- h19_beep_volume
- The volume to set when sounding the H19 "beep". Values are percent
of maximum volume.
- h19_s401, h19_s402
- Dipswitch settings for the H19. See H19/Z19 owner's manual.
Settings related to serial port (s401) have no affect, but
many terminal features defaults (s402) are supported. Values are 8-bit binary,
with the left-most digit being the MSB, corresponding to switch 7.
A "0" represents an OFF switch.
- h19_paste_rate, h19_paste_cr_wait
- These are used to control the rate at which text is pasted to
the computer console. "h19_paste_rate" is the rate for normal characters,
in characters per second (values 1 to 1000). The default is 30.
"h19_paste_cr_wait" is the delay in milliseconds used after RETURN,
in place of h19_paste_rate. Default is 100 mS.
These values are used to prevent overrun of the computer software for pasted text.