Peripherals¶
Lince models the four GR712RC peripherals required to boot RTEMS plus
a fully wired example of a custom DMA peripheral. Every peripheral
implements the same IPeripheral interface, so adding your own is
mechanically the same as anything in the four reference devices.
Built-in peripherals¶
| Peripheral | MMIO base | IRQ | Page |
|---|---|---|---|
| IRQMP — multi-core interrupt controller | 0x80000200 |
— | IRQMP |
| GPTimer — 4 sub-timers + watchdog | 0x80000300 |
8 | GPTimer |
| APBUART — serial port (FIFO + IRQ) | 0x80000100 |
3 | APBUART |
| MemCtrl (FTMCTRL) — memory controller stub | 0x80000000 |
— | MemCtrl |
The base addresses are wired during Emulator::initialize() from the
GR712RC defaults; they are not part of EmulatorConfig.
Custom peripherals¶
Adding your own is one C++ file plus a single add_peripheral() call.
The reference example (DMA + IRQ + an XOR mask) lives under
examples/demo-dma/:
- Custom peripheral walkthrough — the step-by-step guide.
- Demo DMA device — the reference example, annotated.
What is shared across all peripherals¶
Every peripheral conforms to the contract documented on the
modules/peripherals page: the same
reset() semantics, the same tick() cadence, the same word-only
MMIO policy, and the same PeripheralContext injection model.
The dedicated sub-pages here go deeper than the module documentation: each register, each bit, each side-effect, and the GR712RC manual sections that anchor the behaviour.