class

Swanium::Core::WonderSwanInterruptController

Inherits Reference < Object

Owns the WonderSwan interrupt registers, keypad matrix, and display timers. The bus remains the address-map owner while this device models the state transitions behind the CPU-visible interrupt ports.

Constructors

new(ports : Bytes, model : WonderSwanModel)
Source

Instance methods

keys
Source
on_hblank

Called by the LCD scheduler at the beginning of HBlank.

Source
on_vblank

Called by the LCD scheduler on the VBlank transition.

Source
pending_vector?
Source
read_io?(port : UInt8) : UInt8 | Nil
Source
request(source : WonderSwanInterrupt) : Nil
Source
restore_keys(keys : UInt16) : Nil
Source
set_current_scanline(line : UInt8) : Nil
Source
set_keys(keys : UInt16) : Nil

The platform layer supplies a complete input snapshot. Only a newly pressed key raises the edge-triggered KeyPress source.

Source
write_io?(port : UInt8, value : UInt8) : Bool

Returns true when the port is owned by this device, including read-only registers whose writes must be ignored.

Source