-
-
Original MIT-licensed lantern ghost artwork for the TinyZynq CUI launcher
-
Open controller demo (mimi v2023.04.13) hardware and ARM host verification evidence
-
Kiroween N64 cover slide — From cartridge to HDMI with open controller demo
-
Physical TinyZynq XC7Z010 hardware wired to HDMI monitor showing the ghost-themed Kiroween N64 CUI launcher (Protected PL / Clean)
-
TinyZynq XC7Z010 board driving live accelerated 64-bit gameplay over HDMI (camera view and enlarged screen)
-
Kiroween N64 CUI launcher highlighting the MIT-licensed mimi v2023.04.13 open controller tester (HDMI / Clean)
-
TinyZynq v1.0 (XC7Z010): KEY1/KEY2, DDR3, TF card, JTAG, USB-C & HDMI OUT (photo: hellofpga.com)
-
Hybrid PS/PL architecture: Cortex-A9 CPU & audio via Shared DDR to FPGA RSP/RDP logic & HDMI
-
Measured board traces: 53.98 frame submissions/s (Mario 64) vs. 21.93 distinct displayed FPS (Luigi)
-
Kiro CLI 3.5.0 workflow: specs, always-on steering rules, SessionStart hook & read-only MCP tool
-
Kiroween N64 — TinyZynq XC7Z010 digital capture (15 FPS sample showcase)
Inspiration
Many old development boards still have useful programmable logic. Kiroween N64 brings an older TinyZynq v1.0 (XC7Z010) board back into use as a cartridge-era 64-bit console for retro hardware enthusiasts and learners. An ARM Linux menu selects a local cartridge image and runs the emulator on the FPGA board with HDMI output. The Resurrection theme pairs the restored cartridge-to-screen flow with an original lantern ghost, display filters, and a Halloween overlay.
What it does
- ARM Linux Console Menu (CUI): Provides an on-device launcher on TinyZynq that discovers local
.z64,.v64, and.n64cartridge images and renders original lantern ghost artwork, with a terminal menu fallback (KIROW_N64_MENU=terminal) and a 90° counterclockwise default display orientation on M720 HDMI output. - Hybrid PS/PL Console Pipeline: The Cortex-A9 Processing System (PS) runs ARM Linux, the launcher, the N64 CPU recompiler (
dynarec), and HDMI PCM audio recovery (including optional SoundTouch tempo control). In the accelerated 75 MHz profile, programmable logic (PL) handles RSP graphics tasks, RDP rasterization, and protected video scanout. - Board Controls & Halloween Visual Modes: Physical buttons control gameplay modes without stopping execution — short-pressing KEY2 cycles Raw, Scanlines, Phosphor, and Amber filters; holding KEY2 for two seconds toggles Halloween corner overlay graphics; pressing KEY1 returns cleanly to the menu.
- Public Open-Demo Verification: Tested with the openly licensed controller tester mimi v2023.04.13 by
wermi(MIT) and reproducible host/QEMU smoke checks without bundling copyrighted ROMs.
How we built it
- Spec-Driven Development with Kiro CLI 3.5.0: Bounded specs split the launch path, cartridge loading, input handling, HDMI display adapter, and acceptance criteria into incremental tasks. Kiro produced the POSIX single-entry menu, native Linux player, cartridge-loading changes, initial HDMI display adapter, an ARM execution-mode fix, an FPGA rasterizer fill prototype, tests, and measurement code, followed by integration review and refinement.
- Always-On Steering & Traceable Evidence: Steering rules separated host software checks, RTL/HDL simulation results, and physical board runs, requiring resource evaluation, timestamped records under
docs/, and pre-commit privacy audits. - Custom Release-Review Agent, Hook & MCP Tool: A project-scoped custom Kiro agent (
.kiro/agents/kiroween-release-review.json) pairs a deterministicSessionStartevidence preflight hook (scripts/kiroween_release_evidence.py) with a local read-only MCP tool surfacing release gates fromdocs/release-evidence.json.
Challenges we ran into
- Evaluating Offload Honesty vs. Copy-Back Overhead: An early Zelda FPGA offload passed pixel-hash equivalence comparison, yet a separate physical-board timing run took 20.960 seconds on FPGA versus 18.542 seconds in software due to transfer and copy-back costs. Keeping that evidence intact guided our pivot toward a protected shared-memory and ACP presentation path.
- PS/PL Synchronization on a Compact XC7Z010: Coordinating reserved core memory, ARM Linux caches, ACP runtime ownership, and M720 HDMI scanout required clean session quiesce, verification, and recovery logic so exiting back to the CUI never stalls display or DMA.
- Cross-Layer Integration Bugs: Keeping host, RTL, and physical-board checks distinct surfaced real issues early, including correcting POSIX parsing in the initial menu draft.
Accomplishments that we're proud of
- Measured Real-Board 75 MHz Acceleration: Two warm Luigi launches from the themed CUI each ran hardware tasks and produced valid HDMI output. Two scripted Luigi replays on the board each completed 5,520 updates, 2,618 hardware tasks and synchronizations, and a menu return, showing 60 distinct frames across the slow cutscene at 21.930 FPS and 21.924 FPS. An earlier Mario 64 trace averaged 53.98 frame submissions per second across 4,400 updates (measuring submissions rather than distinct cutscene output frames).
- Deterministic Host, RTL & QEMU Verification: Host tests pass pixel-layout and CRT scanline checks (
m720_test/rdp_shadow_test, including the 19-case pixel suite), RTL verification passes in Verilator (rtl/rdp_tri_edge_step.sv), andqemu-arm(cortex-a9) executes the ARM loader, player, core, andmimidemo reproducibly (90updates /90video callbacks with checksum4eb2b8898457fbc3; scripted D-pad replay over110callbacks deterministically shifts checksum from6f07e3cc78b81a43to5159a83f8bae5ea3).
What we learned
- Grounding AI-assisted hardware and systems work in explicit Specs and Steering rules (requiring separate labels for host, simulation, and physical-board results) prevents false positives and drives clearer architecture trade-offs.
- Small bounded tasks paired with deterministic preflight hooks and read-only MCP manifest checks keep C, ARM Linux, and FPGA work auditable.
What's next for Kiroween N64
- Complete sustained gameplay, physical KEY2 ergonomics, visual appearance, and continuous HDMI audio listening acceptance across additional titles on the 75 MHz candidate.
- Publish standalone prebuilt release packages alongside the full reproducible build recipes and notices so any TinyZynq owner can verify digests and boot the open demo directly.
Third-Party Attributions & Pre-Existing Work
- Upstream Emulation & UI: libretro/parallel-n64 (GPL-2.0 and upstream component licenses), yappologistic/CUI (MIT), optional SoundTouch 2.4.0 (LGPL-2.1-or-later), and documented RTL references in
THIRD_PARTY.md. - Open Test ROM & Art Assets: mimi v2023.04.13 by
wermi(MIT), Enter Command font by Font End Dev (CC BY 4.0), and MIT-licensed original lantern ghost artwork.