|
ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
|
Event Link Controller (ELC) register layout for the Renesas RA8D2. More...
#include <stdint.h>Go to the source code of this file.
Event Link Controller (ELC) register layout for the Renesas RA8D2.
The ELC lets one peripheral's event directly trigger another peripheral's input without CPU involvement. Register layout cross-verified against FSP R_ELC_Type in R7KA8D2KF_core0.h (size 0x11C, base 0x40201000).
Register map (at 0x40201000, HUM Ch 19, p 817..836):
| Offset | Name | Width | Purpose |
|---|---|---|---|
| 0x000 | ELCR | 8 | Event Link Control Register (ELCON bit 7) |
| 0x004 | ELSEGR[0] | 8 | Software Event Gen 0 (3-byte stride padding) |
| 0x008 | ELSEGR[1] | 8 | Software Event Gen 1 |
| 0x00C | ELSEGR[2] | 8 | Software Event Gen 2 |
| 0x010 | ELSEGR[3] | 8 | Software Event Gen 3 |
| 0x020 | ELSR[n] | 16 | Event Link Setting Register n (n = 0..52) |
| 0x100 | ELCSARA | 32 | Security attribution (ELCR + ELSEGR0..3 bits) |
| 0x104 | ELCSARB | 32 | Security attribution for ELSR0..31 |
| 0x108 | ELCSARC | 32 | Security attribution for ELSR32..52 |
| 0x110 | ELCPARA | 32 | Privilege attribution (ELCR + ELSEGR0..3) |
| 0x114 | ELCPARB | 32 | Privilege attribution for ELSR0..31 |
| 0x118 | ELCPARC | 32 | Privilege attribution for ELSR32..52 |
The ELS field inside ELSR.HA is 10 bits (mask 0x3FF), so a uint16_t fits any valid event number.
Definition in file ra8_elc_regs.h.
| enum ra8_elc_addr_t : uintptr_t |
| Enumerator | |
|---|---|
| k_ra8_elc_base_addr | RA8 elc base address. |
Definition at line 50 of file ra8_elc_regs.h.
| enum ra8_elc_elcr_bit_t : uint8_t |
Bit positions inside the ELCR register.
HUM Ch 19.2.1 "ELCR : Event Link Control Register", p 817.
| Enumerator | |
|---|---|
| k_ra8_elcr_bit_elcon | ELCR.ELCON – global enable. |
Definition at line 99 of file ra8_elc_regs.h.
| enum ra8_elc_elsegr_step_t : uint8_t |
3-step write-protect unlock sequence required by ELSEGRn.
Per HUM Ch 19.2.2 "ELSEGRn : Event Link Software Event Generation Register n", p 817 (and FSP r_elc.c ELC_ELSEGRN_STEP1..3), a software event is generated by writing three values in sequence to clear WI, set WE, then set SEG. Any other value pattern is silently dropped by the hardware.
Definition at line 87 of file ra8_elc_regs.h.
| enum ra8_elc_event_t : uint16_t |
Partial list of ELC events (populate as drivers need them).
Values taken from the RA8D2 Hardware User's Manual Ch 19 (HUM Table 19.2 "Event signal table") and verified against FSP bsp_elc.h for ra8d2. Only the entries the firmware actually wires up live here; see the manual (or fsp/ra/fsp/src/bsp/mcu/ra8d2/bsp_elc.h) for the full list.
Definition at line 118 of file ra8_elc_regs.h.
| enum ra8_elc_off_t : uint16_t |
Byte offsets within the ELC register block at k_ra8_elc_base_addr.
Cross-verified against FSP R_ELC_Type in R7KA8D2KF_core0.h (HUM Ch 19, p 817..836).
Definition at line 62 of file ra8_elc_regs.h.