
<bobryan9@my-deja.com> wrote:

> In article <93lnac$91u$1@nnrp1.deja.com>,
>   bobryan9@my-deja.com wrote:
> > I am looking for the following information:
> >
> 
> Jeff B. Replied:
> 
> >>PR#3 enable 80 column firmware
> >>PR#0 to disable it.
> >>
> >>Once the 80 column firmware is active (ie. you've done a PR#3 and have
> >>the solid block cursor instead of the checkerboard cursor) you can
> >>use ESC followed by the number 4 to switch to 40 column mode and ESC
> >>followed by the number 8 to switch to 80 column mode.
> 
> What is the difference between the firmware being active and inactive?
> 
> $C007: Map internal ROM into $C100...$CFFF
> $C00A: Map built-in 80-column firmware into $C300...$C3FF

Neither of these is directly relevant.

$C007 isn't relevant - it enables internal ROM in $C100-$C2FF and
$C400-$C7FF.  It doesn't affect $C300-$C3FF or $C800-$CFFF.

There is also $C006, which turns off the internal ROM in these areas and
enables the corresponding slot firmware.

The firmware in these areas (for the IIe) consists of extensions to
monitor routines ($C100-$C2FF) and the self-test code ($C400-$C7FF).


The $C00A/$C00B soft switches are used to enable and disable the
internal 80-column firmware ($C300-$C3FF).  This is usually set by the
firmware and/or operating system when the machine starts up.  The rule
is basically that the internal slot 3 firmware is enabled as long as an
80-column card is detected in the auxiliary slot, unless a firmware card
is detected in slot 3 (possibly conditioned on that card containing the
correct IIe interrupt handling code, which is near the end of the $C3
page).

The main soft switches that deal with 80-column mode are $C000-$C001,
which control memory mapping in the text page (taking over the
PAGE1/PAGE2 switch to toggle between main and auxiliary memory), and
$C00C-$C00D, which turn 80-column video display on and off.

The 80-column firmware is normally responsible for managing these soft
switches, along with several variables that are affected by the active
video mode (the size of the text window, for example).

You can't expect to be able to directly control the video mode using
these soft switches while the 80-column firmware is active.  They should
only be used by your own code if you are writing your own driver to
control the text screen.


If you want to control the active video mode (and several other details)
while the 80-column firmware is active, it provides several control
characters which can be output through the COUT routine (or using the
PRINT statement from a BASIC program).

You can't generate the ESC 4, ESC 8 or ESC Ctrl-Q sequences under
program control because they only work as part of the keyboard input
routine.  In any case, there are control character equivalents for each
of these commands.

The control character commands supported by the 80-column firmware are:

Ctrl-G   Bell
Ctrl-H   Backspace
Ctrl-J   Line Feed
Ctrl-K   Clear to end of screen
Ctrl-L   Home (clear screen, go to to left corner)
Ctrl-M   Return
Ctrl-N   Normal display mode
Ctrl-O   Inverse display mode
Ctrl-Q   40-column mode (leaving 80-column firmware active)
Ctrl-R   80-column mode
Ctrl-U   Terminate 80-column firmware, going to 40 column mode
Ctrl-V   Scroll down one line
Ctrl-W   Scroll up one line
Ctrl-X   Disable MouseText output (not available on unenhanced IIe)
Ctrl-Y   Move cursor to home position but don't clear screen
Ctrl-Z   Clear the line that the cursor is on
Ctrl-[   Enable MouseText output (not available on unenhanced IIe)
Ctrl-\   Move one position right
Ctrl-]   Clear to end of line
Ctrl-_   Move up one line, but don't scroll at top of screen

The ESC 4 command is equivalent to Ctrl-Q, ESC 8 is equivalent to
Ctrl-R, and ESC Ctrl-Q is equivalent to Ctrl-U.

Note that many of the above commands don't work from the keyboard, only
when output via the COUT routine (or PRINT from BASIC).


The only supported way to start the 80-column firmware is to use PR#3 or
an equivalent operation.


