ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
Loading...
Searching...
No Matches
board_periph_block.h
Go to the documentation of this file.
1
35
36#pragma once
37
38#include <stdint.h>
39#include <unicorn/unicorn.h>
40
41#include "emu_memory_access.h"
42
43#ifdef __cplusplus
44extern "C" {
45#endif
46
57typedef uint64_t (*board_periph_read_fn)(uc_engine* uc, uint64_t addr, unsigned size);
58
70typedef void (*board_periph_write_fn)(uc_engine* uc, uint64_t addr, unsigned size, uint64_t value);
71
80typedef void (*board_periph_tick_fn)(uc_engine* uc);
81
88typedef void (*board_periph_reset_fn)(void);
89
100typedef void (*board_periph_report_fn)(void);
101
125
168
186
207
226void board_periph_icu_raise_event(uc_engine* uc, uint16_t event);
227
248uint32_t board_periph_icu_dtc_slot(uint16_t event);
249
261bool board_periph_trace(void);
262
263#ifdef __cplusplus
264}
265#endif
void board_periph_icu_raise_event(uc_engine *uc, uint16_t event)
Raise a peripheral ELC event through the core's ICU -> NVIC path.
void board_periph_register_block(const board_periph_block_t *block)
Register a peripheral block's descriptor with the core registry.
void(* board_periph_report_fn)(void)
Print a block's end-of-run summary section, or NULL if it has none.
void(* board_periph_write_fn)(uc_engine *uc, uint64_t addr, unsigned size, uint64_t value)
Write handler for a modelled peripheral block.
uint64_t(* board_periph_read_fn)(uc_engine *uc, uint64_t addr, unsigned size)
Read handler for a modelled peripheral block.
void(* board_periph_tick_fn)(uc_engine *uc)
Per-emulation-chunk advance for a block, or NULL if it has none.
board_periph_block_order_t
Recommended order values so parallel blocks tick in a stable cadence.
@ k_block_order_sci
SCI_B UART.
@ k_block_order_gpio
GPIO/PORT (no tick today).
@ k_block_order_i2c
I3C/I2C + GT911 (no tick today).
@ k_block_order_timer
GPT + AGT timers.
void(* board_periph_reset_fn)(void)
Reset a block to its power-on state, or NULL if it keeps none.
uint32_t board_periph_icu_dtc_slot(uint16_t event)
Find the IELSR slot that activates the DTC for an ELC event.
board_block_device_t
Which modelled device(s) expose a given peripheral block.
@ k_board_block_dev_ra8p1
RA8P1-only (Ethos-U55 NPU).
@ k_board_block_dev_any
Present on every modelled device (default).
bool board_periph_trace(void)
Whether –trace is active (blocks log transitions when true).
Central first-party Unicorn memory access seam.
-proof
A modelled peripheral block's self-description for the core registry.
bool loop_only
Only own window when –usbhs-loop is set (else sparse).
board_periph_reset_fn reset
Power-on reset, or NULL.
board_block_device_t device
Device gate: which chip(s) expose it.
board_periph_report_fn report
End-of-run summary section, or NULL.
bool observe
Observe-only: snoop, do not own the MMIO.
const char * name
Short label (diagnostics only).
uint64_t base
Absolute window base address.
uint32_t order
Ascending tick order (lower ticks first).
uint64_t span
Window length in bytes.
board_periph_read_fn read
MMIO read handler (required).
board_periph_tick_fn tick
Per-chunk advance, or NULL.