new game early preview

Page 3/3
1 | 2 |

By mzoran

Rookie (24)

mzoran's picture

17-05-2020, 13:40

@Louthrax: any chance you had time to check this out ?
Basically I use this device with Philips VG-8020
https://www.msx.org/wiki/Fractal2000_SD_Mapper/Megaram_512kb

Code that handles pagining in ROM in the range $8000-$BFFF has been copied from some forum post :)

;--------------------------------------------------------
; Which slot address is the cartridge placed?
; Return A = slot address
GTMSLT:
CALL RSLREG ; read primary slot register
RRCA ; move it to bit 0,1 of A
RRCA
AND 3 ; get bit 1,0
LD C,A ; set primary slot No.
LD B,0
LD HL,EXPTBL ; see if the slot is expanded or not
ADD HL,BC
OR (HL) ; set MSB if so
LD C,A
INC HL ; point to SLTTBL entry
INC HL
INC HL
INC HL
LD A,(HL) ; get what is currently output to expansion slot register
AND &C0 ; get bits 3,2
OR C ; finally form slot address

RET ; return to main

CALL GTMSLT
LD H, &80
CALL ENASLT

Anyone has some experience on making this work ?
Thanks

By Louthrax

Prophet (2255)

Louthrax's picture

17-05-2020, 16:34

Hi mzoran,

Not yet, sorry. I'm finishing the new SofaRun release currently, maybe it could fix the problem. If not I'll have a look !

By mzoran

Rookie (24)

mzoran's picture

22-05-2020, 19:45

My fault, I made a typo, code above has a line
AND &C0
and that needs to be
AND &0C

It is working now Smile
Running Naked in a Field of Flowers Running Naked in a Field of Flowers Running Naked in a Field of Flowers

Page 3/3
1 | 2 |