{ "_comment": "generated by tools/mergeSurvey.py from survey/*.json - do not edit by hand", "notes": { "8009": { "routine": [ "cartColdStart - Cold/warm start entry of the CBM80 pseudo-cartridge that the C128 boot sector copies to $8000 before GO64. Re-implements the parts of the C64 KERNAL reset that are skipped when a cartridge is present (IOINIT, clear $0002-$0101/$0200-$03FF, MEMTOP=$A000, MEMSTR=$0800, HIBASE=$0400, RESTOR, CINT), sets border/background to blue (6) and blanks the screen (VIC_CTRL1 bit 4 cleared), opens the drive command channel via $0B45, sends drive command index 2 = \"I\" via $0B55, closes lfn 15, then SETNAM \"0:EA\" and falls into cartLoadEaFile. It never returns; execution continues at $02B8 (eaLoadGame).", "In: None (entered from the KERNAL reset via the $8000 cold-start vector). Relies on the C128 boot sector code still being present at $0B45/$0B55 (it is: the KERNAL reset skips RAMTAS when CBM80 is found and this routine only clears $0002-$0101 and $0200-$03FF).", "Out: Zero page $02-$FF and $0100/$0101, $0200-$03FF cleared; $0282=$08, $0288=$04; MEMTOP=$A000; KERNAL vectors restored; screen editor initialised; VIC_BORDER=VIC_BG0=6; display blanked; drive initialised; stack pointer = $F0; A=0 (LOAD, not verify) on entry to cartLoadEaFile. Does not return." ], "unit": "boot/c64CartridgeStub8000" }, "800F": { "routine": [ "clearLowRamLoop - Loop body inside cartColdStart: with A=0 and Y=0..255 it stores to $0002+Y (absolute-indexed, so $0002-$0101), $0200+Y and $0300+Y. Equivalent to the RAMTAS clear but leaves $00/$01 (CPU port) untouched. Not a callable routine, just the loop label.", "In: A=0, Y=0", "Out: $0002-$0101, $0200-$03FF zeroed; Y=0 on exit" ], "unit": "boot/c64CartridgeStub8000" }, "8065": { "routine": [ "cartLoadEaFile - Tail of cartColdStart (reached by JMP over the embedded \"0:EA\" filename): JSR KERNAL_LOAD then JMP $02B8. The LOAD uses the SETLFS left by $0B45 (lfn 15, device 8, secondary 15), so the file \"ea\" is loaded to its own address $02A8-$030B; control then goes straight to eaLoadGame at $02B8 rather than through the BASIC vector hijack used on the plain C64 path. The carry/error result of LOAD is ignored.", "In: A=0 (load), filename set by SETNAM (4 bytes at $8061), logical file parameters from $0B45", "Out: $02A8-$030B loaded from disk; jumps to $02B8, never returns" ], "unit": "boot/c64CartridgeStub8000" }, "8000": { "unit": "boot/c64CartridgeStub8000", "block": [ "cartHeader: addrTable, 9 bytes. Standard C64 cartridge header: cold-start vector $8009, warm-start vector $8009, signature \"CBM80\" ($C3 $C2 $CD $38 $30). Found by the KERNAL reset code, which then jumps to $8009." ] }, "8061": { "unit": "boot/c64CartridgeStub8000", "block": [ "eaFileNameCart: text, 4 bytes. Filename \"0:EA\" passed to SETNAM (X=$61, Y=$80, length 4) at $8050-$8056; plain PETSCII, no terminator (length-counted). Sits in the middle of the code and is skipped by the JMP at $805E." ] }, "806B": { "unit": "boot/c64CartridgeStub8000", "block": [ "cartTailFiller: unknown, 12 bytes. Never referenced: $00 followed by the byte pattern 8E 72 17 8E 73 17 8E 70 17 8E 71, i.e. fragments of STX $1772 / STX $1773 / STX $1770 / STX $1771. These are the last bytes ($F4-$FF) of track 1 sector 0 and look like leftovers from the mastering buffer (compare the assembler-source fragments on track 1 sector 16)." ] } } }