feat(bios): implement background and object affine services
Execute BgAffineSet and ObjAffineSet through original ARM routines with a mathematically generated sine table. Preserve caller state, validate record spans and strides, and use normal bus writes for background registers and sprite matrices. Add independent matrix/origin references, all-phase coverage, rendering integration, diagnostics, stack and DMA checks. Extend image construction with multiple literal pools and reserved table bounds. Document formats and compatibility limits. Validated on Darwin arm64: 694 default and 683 core-only tests in debug and release; formatting, Clippy, rustdoc, ten native window smoke tests, and CPU/timer demos pass.
This commit is contained in:
parent
1edaa4151d
commit
f60db7e43b
5 changed files with 1020 additions and 23 deletions
|
|
@ -12,6 +12,8 @@ const DEST: u32 = 0x0201_0000;
|
|||
const CALLBACK: u32 = 0x0300_0100;
|
||||
const ROM_DATA: u32 = ROM_START + 13 * 4;
|
||||
|
||||
#[path = "bios/affine.rs"]
|
||||
mod affine;
|
||||
#[path = "bios/angles.rs"]
|
||||
mod angles;
|
||||
#[path = "bios/arithmetic.rs"]
|
||||
|
|
@ -225,7 +227,7 @@ fn vblank_wait_halts_dispatches_irq_and_returns_through_original_code() {
|
|||
|
||||
#[test]
|
||||
fn unsupported_services_fail_at_an_explicit_instruction_trap() {
|
||||
for service in [0, 1, 3, 0x0d, 0x0e, 0x0f, 0x19, 0xff] {
|
||||
for service in [0, 1, 3, 0x0d, 0x19, 0xff] {
|
||||
let (mut machine, _) = call(service, false, [0, 0, 0]);
|
||||
let error = (0..100)
|
||||
.find_map(|_| machine.step().err())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue