AI Agents port the Apollo Guidance Computer to Rust
GitHub: https://github.com/senacor2/AGC-in-Rust
| 指标 | 值 |
|---|---|
| Stars | 2 |
| Language | Rust |
| License | Unknown |
| Topics | N/A |
AI Agents port the Apollo Guidance Computer to Rust.
The goal is to transform the AGC code into idiomatic, readable and maintainable Rust code. This will require to re-create the abstractions that where lost, when the AGC assembler code was written. We are focussing on the Command Module (aka Comanche055) in this project which is tasked with the travel from the earth to the moon and back. Landing on the moon is out of scope, partly because of a lack of a lunar module. The current mission is Apollo 8-style: fly around the moon and back but without an LM.
Aside from the input documents, practically all code and documentation has been written by @claude.
| Directory | Content |
|---|---|
agc-core | Rust code for the AGC command module code |
agc-sim | a simulator for the AGC with all devices virtualized. Runs on any platform |
agc-protocol | Implements a serial line protocol used by agc-core to communicate with agc-bridge-pico |
agc-board-nucleo-f767 | Bare metal port of the AGC to a NUCLEO-F767ZI |
agc-bridge-pico | Firmware for the Raspberry Pi Pico that acts as a bridge between all peripherals (except the IMU) and the AGC software |
agc-imu-platform | Contains the code to handle a BMI088 inertial sensors platform and integrates it into the core |
agc-test | Code for scenario-based testing |
docs | Overall documentation generated by Claude |
input | Reference material for use by Claude |
specs | Module specifications generated and maintained by the analyst agent |
transformation | Documents to guide the transformation process. Initial version generated in the planning phase and maintained throughout the transformation |
The integration test suite lives in agc-test/tests/. The functional-completeness gate is cargo test --test full_mission: a single end-to-end Apollo 8 walkthrough that chains all seven mission phases — TLI, trans-lunar coast (with MCC-2 and MCC-4), LOI, lunar orbit (eight revolutions with P22 landmark marks), TEI, trans-earth coast (with MCC-5), and entry — on the same AgcState and SimHardware instance. The test verifies AGC onboard state against the ground-truth oracle at every phase boundary and asserts the spacecraft reaches drogue deploy within 3000 km of the configured splashdown target. Runtime: well under a second on a modern host.
Per-phase tests (phase_tli.rs, phase_translunar.rs, phase_loi.rs, phase_lunar_orbit.rs, phase_tei.rs, phase_transearth.rs, phase_entry.rs) exercise individual mission segments in isolation and should be the first place to look when a specific phase breaks.
本文基于 GitHub 项目 senacor2/AGC-in-Rust 整理。