Created
January 27, 2023 10:50
-
-
Save ovalenti/842560b8db40239257748d9016620a51 to your computer and use it in GitHub Desktop.
Template for Mattel Aquarius extension ROM (with header signature)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; Basic template of a Mattel Aquarius extension ROM | |
; build: z80asm -o aq_romext.bin aq_romext.asm | |
; run: mame aquariusp -bp . -cart1 aq_romext.bin | |
; uncomment the following block to create a 16K ROM | |
;org 0xc000 | |
; ... | |
; ### lower part of a 16K ROM ### | |
; ... | |
; ds 0xe000 - $ | |
; ### Header ### | |
; can be customized | |
H0: equ 0 | |
H1: equ 0 | |
H2: equ 0 | |
H3: equ 0 | |
H4: equ 0 | |
H6: equ 0 | |
H8: equ 0 | |
HA: equ 0 | |
HC: equ 0 | |
; signature: fixed values | |
H5: equ 0x9c | |
H7: equ 0xb0 | |
H9: equ 0x6c | |
HB: equ 0x64 | |
HD: equ 0xA8 | |
HF: equ 0x70 | |
HE: equ (HF - 0x4e - (H3 + H4 + H5 + H6 + H7 + H8 + H9 + HA + HB + HC + HD)) & 0xff | |
if H3 == 0xf7 | |
error | |
endif | |
org 0xe000 | |
; ROM signature | |
db H0 | |
db H1 | |
db H2 | |
db H3 | |
db H4 | |
db H5 | |
db H6 | |
db H7 | |
db H8 | |
db H9 | |
db HA | |
db HB | |
db HC | |
db HD | |
db HE | |
db HF | |
; ### high part of the ROM ### | |
PRNCHR: equ 0x1d94 | |
start: | |
ld a,'@' | |
call PRNCHR | |
hang: | |
jp hang | |
ds 0x10000 - $ ; pad to the ROM size |
Hi @bushy555, briefly looking at your work to port to Aquarius, I could notice a few things:
- in order to be accepted by mame, ROM files have to be exactly 8K or 16K
- some engines (at least juston) rely on modifying the code (inject delay values or addresses). This is not possible when the code executes from ROM. 2K of RAM are available at 0x3800 if you need to store values.
Thanks. Makes so much more sense.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi
Using your header, Ive managed to get another three working that previously didn't work with the previous hacked header that I was attempting to use. So thanks heaps.
Ive been using the old VirtualAquarius and MESS emulators, since I can't get anything else to work (MAME, Aqualite). However, I can only get players that are under 8k working (Assembled to $E000). Anything to $C000 just fails unfortunately. Aquarius stuff just seems very very 'finicky' to me.
Various stuff is here if interested: https://github.com/bushy555/Aquarius_1-bit_music