This page is a mirror of Tepples' nesdev forum mirror (URL TBD).
Last updated on Oct-18-2019 Download

Playchoice 10 (PC10)

Playchoice 10 (PC10)
by on (#98134)
Hi, I am just thinking about rev-engineering and maybe emulating the Playchoice 10. There is a PC10 service manual with complete PC10 schematics, and MAME includes PC10 emulation source code - so getting the hardware specs together should be no big problem. But two questions on the software side:

Is there anything known on the INST ROM format?
It contains Instruction texts, and some program code, and this or that other stuff - but I don't know yet what is where.

Is there already a ROM-image format for PC10 games?
The iNES header includes a flag for indicating the presence of the INST ROM - but not for the RP5H01 PROM. The PROM is, I think, required for decrypting the game title (and maybe also for other data in the INST ROMs, like maybe the Instruction text...?).
So far, the iNES format looks incomplete - having only the encrypted INST ROM but not the PROM decryption key - looks rather useless to me (unless there's a way to decrypt the data without the PROM?).
Re: Playchoice 10 (PC10)
by on (#98480)
Okay, rev-engineered the INST ROM format on my own. It contains a bunch of hardcoded pointers, and a somewhat encrypted 40h-byte area, which contains the tilte, GameID (I think), and a bunch more pointers. The good news is that more than half of the plenty pointers don't seem to be used by the BIOS, a few of them might be internally used by INST ROM code, but of course, there's no need to that in homebrew projects.
The actually important pointers are: 1) get 40h-byte-area function, 2) display-instruction-line function, 3) a few very simple functions (ret opcode, jp hl opcode's, waitvblank function, set a variable to zero). Well, and that's all about it. The first 2 functions are looking incredibly complicated - but when removing the decryption code, they can be implemented in a handful of opcodes.
I'll still need to clean up the specs before releasing them & research some details like what character+palette number gives what color, and what GameIDs are used/available.

PC10 ROM-Image Format
There seems to be absolutely no way to use the INST ROMs without the RP5H01 PROMs - so there seems to be no way around changing/expanding the "iNES" format. Somehow like so:
  16 byte   NES Header
  512 byte  Trainer (if any)
  N*16K     PRG-ROM
  N*8K      CHR-ROM (if any)
  8K        PC10 INST-ROM
  16 byte   PC10 PROM Data        <--- NEW
  16 byte   PC10 PROM CounterOut  <--- NEW
  128 byte  Title (if any)

Would that be okay?
Any reasons not to use that format?
Or any suggestions for a better format?

The 16-byte PROM Data would be the 9 bytes plus trailing 7 mirror/padding bytes as how they are returned from the real PROM's Data Out pin. Basically same as the MAME security.prm files - but I'd really prefer to use the correct bit-order (Bit0 stored in BIT0 of first byte, NOT in BIT7 of first byte), and without the inversion being used in MAME. In practice: The first 4 bytes for "1942" should be 31,39,34,32 which does perfectly match the game's title (in the MAME files, the bytes would be 73,63,D3,B3 which doesn't match anything for good).

The 16-byte PROM CounterOut would be the CounterOut pin accordingly. In original carts, this would be always 00,00,00,00,FF,FF,FF,FF,00,00,00,00,FF,FF,FF,FF, but for PROM-less homebrew carts it'd be waste of money to reproduce that pattern (for such games, all sixteen bytes FFh-filled should work, and would be obviously cheaper to implement) (the cheapest way I could imagine would be using the unused 74LS367 output to produce a HIGH level upon /CHANNEL_SELECT, and then to pass that HIGH level to the Data & CounterOut pins via two diodes).

MAME security.prm's
The "security.prm" files in MAME rom-sets might be the best source to get the PROM data for each game. I could make a tool for inverting & reversing them, appending them to existing ROM-images, and alongside fixing missing PC10 flags in some ROM-images.
Though I don't know how many of that PROMs are actually dumped (there should be around 55 PC10 games) - does anybody have a collection of that files & know how many "security.prm" files do exist?
The other problem is that ALL files seem to be called "security.prm" which is rather uncomfortable to use - if somebody could rename them to "<cartname>.prm" would be very helpful!