From d443cdf433248fc73dd148f1eada103bd695c9df Mon Sep 17 00:00:00 2001 From: Drew T <50529377+Druthulu@users.noreply.github.com> Date: Tue, 16 Jun 2026 14:18:47 -0600 Subject: [PATCH] =?UTF-8?q?docs(phase-12):=20T5=20(static=20start)=20?= =?UTF-8?q?=E2=80=94=20save/memcard=20format:=20saveHeaderTemplate=20+=20h?= =?UTF-8?q?andler=20table=20(Q#5)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit formats.md §6: SaveLoadRoutine @0x8002B154 = multi-entry save/load blob driving the linked PsyQ libmcrd primitives; saveHeaderTemplate @0x80072DF0 decoded — memcard filename "BASLUS-00726MUSASHI", SJIS title "BRAVE FENCER MUSASHI", and a @+0x54 handler DISPATCH TABLE of 0x8002Bxxx pointers (the "multi-entry blob" IS this table of save/load sub-handlers). Static layout VERIFIED. TBD (needs Ghidra-on-EXE + a Drew-operated PCSX-Redux save trace + PsyQ-memcard CRC research): the save-DATA serialization (player/progress state 0x80078Exx + checksum) + matching the tractable handlers. ram_savescreen.bin holds the live header. --- docs/formats.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/docs/formats.md b/docs/formats.md index ea1639351..c5a23a35f 100644 --- a/docs/formats.md +++ b/docs/formats.md @@ -417,6 +417,30 @@ but the deep MThd→SEQ + VAB-load *playback semantics* are not exhaustively tra work, and not needed for the byte-match). Verdict: **semi-custom** = Square wrappers/glue over stock PsyQ libsnd sequencing. +## 6. Save / memory-card format (Q#5 — Phase 12, partial) + +`SaveLoadRoutine` @ `0x8002B154` (EXE) is a multi-entry save/load handler blob driving the **linked +PsyQ libmcrd** primitives (`0x8005Fxxx`–`0x80061xxx`, e.g. `0x800603BC` heavily, `0x8006023C`, +`0x80060AE0`, `0x80061114`). Its config/dispatch data is `saveHeaderTemplate` @ `0x80072DF0`: + +| Off | Bytes | Meaning | +|---|---|---| +| +0x00 | `82 67 82 85 82 92 82 8F` + pad | 4-char SJIS label (`Hero`?) | +| +0x0C | `"BASLUS-00726MUSASHI"` | **memcard filename** (PS1 `BA` + region-product + name) | +| +0x20 | SJIS `BRAVE FENCER MUSASHI` | **save title** (BIOS memcard-manager display) | +| +0x44 | `2A 00 00 00` | count/flag (0x2A = 42) | +| +0x54 | `0x8002B154, 0x8002B1AC, 0x8002BEA4, …` (a run of `0x8002Bxxx` pointers) | **handler dispatch table** — addresses INTERIOR to the SaveLoadRoutine blob; the save/load/validate sub-operations | + +So the Gen1 "multi-entry blob" note **is** this dispatch table: the header holds a vector of sub-handler +addresses (the 3 known entries + more), each performing one memcard step via libmcrd. + +**VERIFIED (static, Phase 12):** the header layout above; SaveLoadRoutine calls the linked libmcrd objects. +**TBD (needs Ghidra-on-EXE + a Drew-operated PCSX-Redux save trace + PsyQ-memcard research, R17):** the +**save-DATA block** serialization — almost certainly the Phase-3 player/progress state (`0x80078Exx`: +gold/HP/BP/day/hour/flags) + a **checksum**; capture the live memcard buffer from a real save to pin the +field order + the checksum algorithm — and matching the tractable handler entries. `dumps/ram_savescreen.bin` +(save screen, overlay flushed) holds the live `saveHeaderTemplate` for cross-check. + --- ## 6. Extractor implementation notes (Phase 2 pipeline)