My sick vision of a 68000 table includes letter names for registers
Heh. I created a 6502 mnemonic set for the SPC700. You could tell 90% of the opcodes were "inspired" by 6502 anyway. They probably just redid it all last minute for legal reasons. mov x,#$00? Come on. ldx #$00.
nocash remakes every instruction set into x86 for some reason.
So there's definitely precedent if you want to make your own. Unlikely to catch on, but we usually do these things for our own benefit.
Then perhaps it's time to design our own copier header: jSNS. It'd be like iSNS but one better, as it would encode the missing info as a JSON object stored in a separate file: Super Mario World.sfc and Super Mario World.jsns.
That was part of the joke, yeah. For all the good iNES does, you could just make a 2-byte mapper ID and uniquely specify every tiny variant of every board out there. The same is true for the SNES. Drop the maker ID (SHVC-, MJSC-, MAXI-, EA-) as irrelevant, and then store the rest as the header. "1A3B-20" ... and an internal DB of the 50 boards. That's all you need for 100% perfect mapping.
My vision though is to leave the binary files as pure ROM contents, no user-supplied stuff that is due to be argued about for generations like iNES 2.0 and UNIF are, no compression archives, no existing containers like ZIP/TAR with all the stuff that doesn't matter to emulators. That gives emulator authors two choices.
Option 1: keep a database of SHA256={mapping layout}.
I'm making that database now at byuu.org/snes/database
Option 2: provide a manifest file that describes the PCB.
Just like your .jsns, I support this as well. Only instead of JSON, I went with something far simpler to parse. I call it BML.
Basically it's indent-level sensitive ala Python. You can do attributes like XML, but internally they're child nodes just like anything else.
You can assign with name=data, or name="data with spaces", or name:data with spaces and "quotes"
= runs to the next space
="..." runs to the second "
: runs to the next line feed (if it's a child node, it appends multiple lines)
And that's it. No comments for the same reason as JSON. No escape character/entities to decode. No Billion Laughs by entity expansions (XML) or linked nodes (YAML). Can be decoded with no memory allocation other than the child nodes (inserting zeroes into the loaded document, nothing ever expands.)
Here's an example:
Code: Select all
cartridge region=NTSC
board type=2J5M revision=01
rom name=program.rom size=0x180000
ram name=save.ram size=0x8000
map id=rom address=00-3f,80-bf:8000-ffff
map id=rom address=40-7f,c0-ff:0000-ffff
map id=ram address=10-1f,90-9f:6000-7fff
map id=ram address=30-3f,b0-bf:6000-7fff
information
title: Romance of the Three Kingdoms III: Dragon of Destiny
name: Romance of the Three Kingdoms III - Dragon of Destiny
region: NA
revision: 1.0
board: SHVC-2J5M-01
sha256: 88fa0a78ca98c6386e086c7fa9e81a2625bdecc55115dde6c6f4770b0670aa40
description
:This is a strategy game by Koei.
:It's very confusing to try and play.
configuration
rom name=program.rom size=0x180000
ram name=save.ram size=0x8000
Only cartridge/board is needed. cartridge/information is optional, and cartridge/information/configuration tells you how to split a ROM file into individual chunks. For the NES, it'd help you split PRG and CHR. For the SNES, it helps you split program from data ROMs, and coprocessor firmware ROMs.
Emulators would be free to support whatever they wanted in cartridge/information, since it's extensible.
Aside: title is for the native language, so it'd be Japanese letters if from Japan. name is always using Roman letters (A-Za-z), and avoids NTFS restricted characters like : and \, and is sort friendly ("Brainies, The" and not "The Brainies" like the title.)
So my long-term vision ...
Most people will just have their folder full of .sfc files. They will pick games and play them. I find them in my database of verified software, and load the mapping from there.
ROM hacks will be distributed as BPS patches, that have the manifest.bml embedded in the patch. The emulator will apply the patch, pull the manifest out, and use that mapping (some games change mapping rules.)
Users can also distribute ZIP containers that have SFC+BML files, and it'll use that mapping.
Developers can have folders with game.sfc+game.bml files, and it'll use that mapping.
Behind the scenes, I make game folders. It's a folder named game.sfc/, and inside you have all the files related to it. program.rom, save.ram, bsnes/state-1.bst, cheats.bml, box/front.png, etc.
The emulator cores only load game folders. The frontend makes them before sending them to the core, completely transparently to the user.
For people who -really- agree with my vision, they can use game folders directly as well. They're my favorite approach. No compression, no merged files at all. Anything emulator-specific in its own subfolder. A folder is equivalent to a real game. When you move it, you move everything related to that game with you. There is no need for the emulator to have separate path configurations for every file type.