Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Access to AUX mem at $D000

64 views
Skip to first unread message

Marc Golombeck

unread,
Feb 12, 2022, 12:36:37 PM2/12/22
to
Is there a method to access AUX mem from $D000 in 128 k Apple IIe? AUXMOVE only covers the range up to $BFFF.

Is the area $D000-$DFFF also bank switched like the language card memory? How can that bank switching be achieved in AUX mem?

Thx for any hints!

qkumba

unread,
Feb 12, 2022, 1:58:14 PM2/12/22
to
writing to $C009 enables access to $D000-FFFF, then $C083 or $C08B as usual to choose the $D000 page that you want.
write to $C008 to restore access to main $D000-FFFF.

qkumba

unread,
Feb 12, 2022, 2:01:03 PM2/12/22
to
Note also that writing to $C009 enables both read and write access to $D000-FFFF (unlike $C003/C005 for the regular memory), and that $C009 switches to aux zero-page and stack, so you can't call it easily from a subroutine that doesn't also write to $C008 before returning.

I am Rob

unread,
Feb 12, 2022, 7:29:39 PM2/12/22
to
You can copy the COPY routine at $FE2C in ROM to the lower Main 48k and use that. You can also use it to copy to both the Aux48k and the AuxLC instead of using the AUXMOVE.

From Main memory, flip switches $C009 and $C005 to copy routines from Main and write to anywhere in Aux. This has to be done first before setting up zero-page locations $3C.42 as the AuxZP is now in effect.

From Main you can now do a JSR $D000, or where the routine is in the AuxLC, but remember this will put the return address on the Aux stack, so you cannot flip the $C008 switch until the call is returned to Main memory.

Your AuxLC routine should flip the $C003 switch to enable reading from the lower Aux48k, then call the Aux48k routine. Your Aux48k routine should never flip any switches to Read Main memory (either lower 48k or MainZPLC), but can flip $C004 to write to Main. Upon return to the AuxLC routine, it should then flip the $C002 switch to read from Lower Main48k again before returning to the Main memory routine.

And lastly, immediately after the JSR $D000 from Main, you need to flip the $C008 switch to allow any return addresses on the Main stack and variables in MainZP to be used normally again.

Personally, I wouldn't use the LC banks at $D000.DFFF as they still require two softswitch accesses to do a write, just like MainLC does. And you still have all of $E000.FFFF you can use without extra switching. A lot of code can be packed in the upper 8 kb.

0 new messages