Apple III: Console Driver--Changing the Character SetApple III: Console Driver--Changing the Character Set
- Last Modified: February 08, 2000
- Article: TA37056
- Old Article: 24
The console driver has a control call that will load up to eight new character definitions for the video display. Below is a Pascal program that will change one character.
PROGRAM SWAP;
VAR
UNITNUM : INTEGER;
REQUESTCODE : PACKED RECORD
CHANNEL : 0..1;
STAT_OR_CTRL : 0..1;
REQUEST_NUM : 0..255;
RESERVED : 0..63;
END;
DATA : PACKED RECORD
NUMBER : 0..255;
CHARACTER : CHAR;
INFO : PACKED ARRAY [1..8] OF 0..255;
END;
BEGIN
WITH REQUESTCODE DO BEGIN
CHANNEL:=0;
STAT_OR_CTRL:=1;
RESERVED:=0;
REQUEST_NUM:=17; { character replace code }
END;
WITH DATA DO BEGIN
NUMBER := 1; { How many characters to change }
CH := ' '; { which character to change }
INFO [1] := 255; { character definition }
INFO [2] := 255; { See page 166 of the }
INFO [3] := 255; { STANDARD DEVICE DRIVER MANUAL }
INFO [4] := 255;
INFO [5] := 255;
INFO [6] := 255;
INFO [7] := 255;
INFO [8] := 255;
END;
UNITNUM:=1;
UNITSTATUS (UNITNUM, DATA, REQUESTCODE);
WRITELN ('ALL_SPACES_WILL_NOW_DISPLAY_AS_" "!');
END.