17typedef enum : uint32_t {
38typedef enum : uint16_t {
143 for (uint32_t i = 0U; i < n; i++) {
145 buf[i] = p->
file[reg];
187 sensor->
reg_ptr = (uint16_t)(((uint16_t)(sensor->
reg_ptr << 8U)) | (uint16_t)
byte);
294 (void)
priv_emu_io_errf(
" RIIC PI4IOE : U15 expander 0x%02X acked %u register write(s)\n",
300 " RIIC OV5640 : SCCB 0x%02X chip-id 0x5640 (%u id read(s), %u cfg write(s))\n",
riic_device_const_t
Registry and PI4IOE5V6408 geometry.
@ k_pi4ioe_reg_max
Register-file size modelled (0x00..0x0F).
@ k_riic_dev_max
Device-registry capacity.
@ k_pi4ioe_reg_devid
Device-id register.
@ k_pi4ioe_devid_val
Device-id reset default.
@ k_pi4ioe_addr_7b
EK-RA8D2 U15 default 7-bit address.
static RA8_INTERNAL uint32_t internal_pi4ioe_read(void *ctx, uint8_t *buf, uint32_t max)
Serve PI4IOE5V6408 register bytes to the controller.
RA8_PRIV void priv_riic_devices_reset(void)
Reset and repopulate the board's RIIC device registry.
static RA8_INTERNAL uint32_t internal_ov5640_read(void *ctx, uint8_t *buf, uint32_t max)
Serve one verifier-visible OV5640 register byte.
static pi4ioe_state_t s_pi4ioe
static ov5640_state_t s_ov5640
static RA8_INTERNAL void internal_pi4ioe_write(void *ctx, uint8_t byte)
Accept one controller byte for the PI4IOE5V6408.
static RA8_INTERNAL void internal_ov5640_write(void *ctx, uint8_t byte)
Accept pointer and configuration bytes for the OV5640.
ov5640_const_t
OV5640 SCCB sensor constants used by camera_capture.
@ k_ov5640_addr_7b
SCCB 7-bit address.
@ k_ov5640_id_hi
Chip-ID high byte.
@ k_ov5640_reg_id_lo
Chip-ID low-byte register.
@ k_ov5640_ptr_bytes
Big-endian register-pointer byte count.
@ k_ov5640_reg_id_hi
Chip-ID high-byte register.
@ k_ov5640_id_lo
Chip-ID low byte.
RA8_PRIV void priv_riic_devices_report(void)
Report activity observed by the registered board devices.
static RA8_INTERNAL void internal_pi4ioe_stop(void *ctx)
End a PI4IOE5V6408 transfer.
static RA8_INTERNAL void internal_ov5640_stop(void *ctx)
End an OV5640 SCCB transfer.
static RA8_INTERNAL void internal_riic_device_register(riic_device_t device)
Register one device in the first free bus slot.
static riic_device_t s_riic_dev[k_riic_dev_max]
Fixed registry and board-device states.
RA8_PRIV riic_device_t * priv_riic_device_find(uint8_t addr_7b)
Find the registered RIIC device answering one 7-bit address.
Internal RIIC bus-device registry and board-device models.
Bounded raw-descriptor I/O seam for the RA8 emulator.
emu_io_result_t priv_emu_io_errf(const char *format,...)
Format bounded text and write it to the injected error descriptor.
#define RA8_PRIV
Module-private helper: shared across TUs but only inside one library.
#define RA8_INTERNAL
Marker that a function is intended to be static (file-local).
@ k_ov5640_reg_format
DVP output pixel format register.
@ k_ov5640_reg_test
Pre-output test-pattern register.
@ k_ov5640_reg_isp_mux
ISP output format-mux register.
One OV5640 camera sensor on the SCCB bus.
uint8_t ptr_bytes
Pointer bytes captured this transfer.
uint8_t reg_isp_mux
Latched 0x501F ISP output mux.
uint8_t reg_format
Latched 0x4300 DVP output format.
uint32_t writes
Config register writes accepted.
uint32_t id_reads
Chip-ID bytes served for reporting.
uint8_t reg_test
Latched 0x503D test-pattern control.
uint16_t reg_ptr
Active 16-bit register pointer.
One PI4IOE5V6408 I/O expander on the modelled I2C bus.
uint8_t file[k_pi4ioe_reg_max]
Register-file shadow.
uint32_t writes
Register writes the controller landed.
uint8_t reg_ptr
Active auto-incrementing register pointer.
bool ptr_set
First byte of this transfer set the ptr.
One device registered on the modelled RIIC bus.