Dynamic validation¶
Run the real ROM's link code and check its output against the wire. Source:
emulator/race-link/ — make -C emulator/race-link test.
How¶
- CPU core —
tlcs900h.c/race-memory.c/ngpBios.cfromlibretro/RACE, compiled headless (video/sound stubbed). - COM services — RACE stubs the serial BIOS calls;
linkemu.cre-implements them as a byte transport to a C model peer. The only functional change. - Drive — after boot,
call_rom()invokes the game's comms tick0x206c8fper frame; writing00to0x564estarts the handshake (what the 2P menu does).
flowchart LR
CORE[real ROM on TLCS-900H core] <-->|COM| TRANS[transport] <-->|F-frames| PEER[C model peer]
Result¶
ROM emitted FC 01 .. 30 (advertise) : PASS
ROM emitted FD 01 .. 30 (responder reply) : PASS
ROM emitted F0 heartbeat : PASS
ROM emitted F8 00 <input> offer : PASS
ROM decoded peer reply into 570d/5715 : PASS
- State machine walks
00→04→08→0C→14on real code. - Confirmed the bit-7 gate (set = transport, clear+bit3 =
F8at0x207447). F8offer sends only when0x564f==01, input from0x56ed & 7f.- Receive stores
F8 <p1> <p2>into0x570d/0x5715— button bits match live.
Limits¶
- Peer is a C model, not a second ROM (RACE's global state → two instances need two processes; the COM transport is the seam).
- Phase transitions are poked via status bits, not menu-driven — but the link code run is the real ROM's.
- Timing is logical (1 tick/frame); wall-clock comes from the capture.