Struct MapperDebugInfo
pub struct MapperDebugInfo {Show 16 fields
pub mapper_id: u16,
pub name: String,
pub mirroring: &'static str,
pub prg_banks: Vec<(String, String)>,
pub chr_banks: Vec<(String, String)>,
pub irq_state: Vec<(String, String)>,
pub extra: Vec<(String, String)>,
pub submapper: u8,
pub tier: &'static str,
pub prg_rom_size: usize,
pub chr_rom_size: usize,
pub prg_ram_size: usize,
pub chr_ram_size: usize,
pub has_battery: bool,
pub irq_kind: &'static str,
pub expansion_audio: Option<&'static str>,
}Expand description
Read-only debug snapshot of mapper-internal state for the UI.
Mappers override [Mapper::debug_info] to surface their banking
registers and any IRQ-counter state. Fields are pre-formatted strings
so the UI doesn’t have to know the protocol of each mapper.
Fields§
§mapper_id: u16Mapper id (e.g. 4 for MMC3).
name: StringHuman-readable mapper name (e.g. "MMC3 (Sharp)").
mirroring: &'static strCurrent mirroring layout name ("Horizontal", "Vertical",
"SingleScreen", "FourScreen").
prg_banks: Vec<(String, String)>PRG bank registers — one (label, value) entry per register the mapper exposes. Values are hex-formatted by the mapper.
chr_banks: Vec<(String, String)>CHR bank registers — same shape as prg_banks.
irq_state: Vec<(String, String)>IRQ counter state — (label, value) pairs, e.g.
[("counter", "0x12"), ("reload", "0x80"), ("enabled", "true")].
extra: Vec<(String, String)>Free-form extra status (envelope shape, sub-mapper flags, …).
submapper: u8NES 2.0 submapper id (0 for iNES 1.0).
tier: &'static strAccuracy-evidence tier name ("Core" / "Curated" / "BestEffort"),
empty if the id isn’t classified.
prg_rom_size: usizePRG-ROM size in bytes.
chr_rom_size: usizeCHR-ROM size in bytes (0 when the board uses CHR-RAM).
prg_ram_size: usizeRequested PRG-RAM size in bytes.
chr_ram_size: usizeRequested CHR-RAM size in bytes (0 when the board ships CHR-ROM).
has_battery: boolTrue when PRG-RAM is battery-backed (save RAM / NVRAM present).
irq_kind: &'static strThe IRQ mechanism, when the board has one (e.g. "PPU A12 (MMC3)",
"PPU scanline (MMC5)", "CPU cycle (VRC/FME-7/N163)"). Empty if the
board has no IRQ source.
expansion_audio: Option<&'static str>On-cart expansion-audio chip name, if any (e.g. "VRC6").
Trait Implementations§
§impl Clone for MapperDebugInfo
impl Clone for MapperDebugInfo
§fn clone(&self) -> MapperDebugInfo
fn clone(&self) -> MapperDebugInfo
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more