Support Forum

Please or Register to create posts and topics.

Suggested amendment to MMU16 subroutine in nextlib.bas

Hi There,

I suggest the following amendment to MMU16 based on

Sub MMU16(byval memorybank as ubyte)

' changes 16kb 128k style bank @ $c000, supports full ram

IF memorybank <= 46 THEN' Works for unexpanded Next <= 1MB

' doesnt work correctly yet


ld a,(IX+5); bank 16-31 32-95 96-159 169-223



AND %00000111

ld bc,$7ffd

out (c),a

ld a,(IX+5)

AND %11110000

srl a

srl a

srl a

srl a

srl a; Uncommented

ld bc,$dffd

out (c),a

end asm

ELSE' Works for expanded Next > 1MB

MMU8( 6, memorybank * 2 )

MMU8( 7, ( memorybank * 2 ) + 1 )


end sub



Hi thanks for the update, I'll take a look! 🙂