3.1 KiB
Disconnected serial initialization subset
The core supports idle normal-mode data registers and disconnected general-purpose pins. It does not support link transfers, multiplayer, UART, Joybus communication, or external serial interrupts. Unsupported activity remains diagnostic rather than reporting a fabricated completion.
Registers
SIODATA32at0x04000120is a four-byte latch in the supported normal-mode subset.SIODATA8at0x0400012aretains its low byte; its upper byte reads zero.SIOCNTat0x04000128retains normal 8/32-bit mode, IRQ configuration, clock selection, and the output-data bit. The retained mask is0x500b. The disconnected serial input is high, except when a general-purpose output drives it low. Transfer-start bit 7 and multiplayer/UART mode bit 13 return explicit errors.RCNTat0x04000134retains general-purpose mode, output latches, and pin directions with mask0x80ff. In general-purpose mode, each input reads high through its pull-up. Each output reads its output latch.RCNT=0x8000therefore reads back as0x800f, not0x8000. Joybus mode and GPIO interrupt enable return errors. Normal-mode low-byte pin readback remains unmapped rather than guessed.JOYCNTpermits clearing already-empty status flags. Joybus interrupt enable is unsupported.JOY_RECVandJOY_TRANSpermit only zero writes and zero readback for reset initialization. Nonzero writes return an explicit error. Joybus status and data-transfer side effects are not implemented.
GPIO means general-purpose input/output. UART means universal asynchronous receiver/transmitter. No external serial device is connected. Elapsed cycles alone do not change serial data or generate an IRQ. Configuration that hardware accepts in other modes can still be rejected by this intentionally limited subset.
BIOS reset
RegisterRamReset always clears the low halfword of SIODATA32, even without bit 5. The upper halfword remains unchanged in this functional subset. With bit 5 selected, the firmware clears SIOCNT and SIODATA8, selects general-purpose inputs, and clears the supported Joybus reset registers. It uses ordinary ARM bus stores, not a host-side reset bypass.
Original tests cover independent byte lanes, input pull-ups, output directions, reset flag selection, and explicit unsupported operations. Whole-access and block-store validation prevent a rejected control value from committing preceding bytes or registers.
References
- GBATEK reset functions: reset flags, general-purpose selection, and the unconditional SIODATA32 side effect.
- GBATEK normal serial mode: data widths, input status, and control bits.
- GBATEK: general-purpose pin directions and internal pull-ups.
- mGBA BIOS implementation at 3a5e34be: functional serial reset defaults, not copied source.
Exact firmware write ordering and hardware pin timing remain unverified.