# Cores: what exists, what the board needs from each Reuse first: every chip on these boards against the family's existing cores (read 2026-11-26; sibling repositories were read, not touched). | Chip | Family core | Status | What this board needs | | --- | --- | --- | --- | | MC6809E (main CPU) | `../m6809-python` | **Phase 0 only** (HEAD b35c084): documents, oracle research, a pinned MAME-generated vector corpus (`neetandev/m6809`, 249,871 cases), MAME trace scripts; **no core code** | the core, built to its own brief, plus the items below. The board cannot start before the core's rungs 1-2 pass | | MC6808 / MC6802 (sound CPU) | `../m6800-python` | **built**: v0.2.0, PUBLIC, seven rungs passed (manuals, MAME corpus, 17.6 M instructions of replayed arcade code, a Williams sound board host, two emulators, measured undocumented opcodes); `M6802` and `M6808` classes; Python >= 3.11 | nothing new: `step()` with cycles, level IRQ, edge NMI, RESET. Pin by commit (HEAD 96302c2) | | MC6821 PIA (x3, x4) | none as a core; atari8bit-python models the 6520 inside its board (Phase 0); m6800-python has a sound-board PIA inside a host *script* | | stays in this board behind a pin-shaped class; open decision 3 on extraction | | Special Chips SC1/SC2 | none | Williams-only (and the second-generation Williams boards) | in the board | | MC1408 DAC | none (trivial) | | in the board | | HC-55516 CVSD | none | Williams sound/speech only in the family | in the board | | YM2151 (Joust 2's background board, second generation) | `../ym2151-python` | Phase 0 (tonight's other batch) | out of scope until the second generation | ## What the board needs from m6809-python (requests to raise on the core) These follow from the board, so they go to the core's brief before its build session starts (fixes start upstream): 1. **HALT and bus grant.** The Special Chips pull /HALT; the 6809E finishes its instruction, raises BA and BS, and lets a dead cycle pass before the blitter drives the bus, then another on release (DOC: 6809E data sheet, 6809PM; MEASURED: SR-BLIT "after nearly one instruction cycle ... after nearly 2 instruction cycles"). The core needs a `halt` input sampled at instruction boundaries (as the board drives it) and a way to report the dead cycles it spends entering and leaving the halted state, so the board can count them on its timeline. m6809-python's brief has no HALT item today (its timing.md treats the blitter's theft as "an extra advance of the host clock"); that model loses the halt's exact start and the dead cycles that Riddle measured. 2. **Every bus cycle, in order, with VMA.** The board's video RAM is shared per microsecond and the PIAs clear flags on reads; dummy cycles (the 6809's VMA-low reads of FFFF) must be visible to the board and marked, as the core's rung 2 (bus order) already plans. 3. **Level IRQ resampled at every boundary** (already in its timing.md, from the PIA's behaviour). 4. **Python floor 3.11** (PyPy): the core's README and brief still say 3.12+; the Vectrex Phase 0 raised the same correction (vectrex-python's handoff brief). 5. **Rung 4's Williams host skeleton** in the core's brief (a scanline counter, PIA1 CB1 on VA11) should become this board's job: the core's rung 4 can stop at "the 552,507 pre-I/O instructions agree" and this board's milestone 1 takes over. Proposed, for the core's owner to accept. ## The sound board on m6800-python - Rows: `M6808` for every Williams set, `M6802` for two Defender bootlegs (OBSERVED). The core treats both as the 6800 instruction set; the 6802's internal 128 bytes of RAM are the board's business (the core does not own memory). - Clock: 3,579,545 / 4 E (nextcent 3,120,000 / 4). - The core's undocumented-opcode mode: `undocumented="measured"` for the board (the hardware-measured behaviour); `"mame"` only for MAME comparisons. ## Chip rule summary CPUs have their cores (both exist as repositories; one still needs building). The PIA is the only chip with a second family user (Atari 8-bit's 6520), so its extraction is the only open chip-rule question; everything else stays in the board.