Previous Next Contents Index
The page in/out routines

THE 'PAGE 128K RAM' ROUTINE
The 128K RAM-bank contained in the A register is paged-in.

003D RAMPAGE_A  LD   BC,#7FFD            128K bank-switch port address.
0040            OUT  (C),A               Select RAM bank.
0042            RET

THE 'SECRET VERSION NUMBER'

0043            DEFM "6.8"

THE 'UNPAGE 128 ROM' SUBROUTINE
This routine pages out the DISCiPLE system and returns to the 128K ROM at address
#0049. That address contains a RET instruction so the effect is a jump to BC with
the 128K ROM paged in.

0046 UNPAGE_BC  PUSH BC                  Stack return address.
0047 UNPAGE_0   OUT  (187),A             Page out DISCiPLE system.
0049            RET                      ? This statement is  not  reached  from
                                         above.
004A            DEFB #00,#00,#00,#00,#00 Unused locations.

THE 'UNPAGE' SUBROUTINE
This routine pages out the DISCiPLE system and returns to the 'main' ROM at
address #0052. That address contains a RET instruction so the effect is a jump
to HL with the 'main' ROM paged in.

004F UNPAGE_HL  PUSH HL                  Stack return address.
0050 UNPAGE_1   OUT  (187),A             Page out DISCiPLE system.