|
ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
|
Aggregate USBHS host-controller model state. More...
Data Fields | |
| uint16_t | reg [k_usbhs_words] |
| 16-bit reflect-on-read register shadow. | |
| uint8_t | din [k_usbhs_din_cap] |
| DCP IN staging (device -> host control data). | |
| uint16_t | din_len |
Bytes staged in din. | |
| uint16_t | din_rd |
Read cursor as the host drains din. | |
| bool | din_ready |
| din holds an unread packet (DCP BRDY source). | |
| uint8_t | setup [k_usbhs_setup_len] |
| Latched 8-byte SETUP packet. | |
| bool | ctrl_read |
| Last SETUP was a control read. | |
| uint8_t | ctrl_breq |
| Last SETUP bRequest. | |
| bool | ctrl_status_pending |
| Control-write status awaits dev CCPL. | |
| uint8_t | pout [k_usbhs_pipes][k_usbhs_pkt_cap] |
| Per-pipe OUT staging (host->dev). | |
| uint16_t | pout_len [k_usbhs_pipes] |
| Bytes accumulated per OUT pipe. | |
| bool | pout_wait [k_usbhs_pipes] |
| OUT pipe awaiting device drain (BEMP). | |
| uint8_t | pin [k_usbhs_pipes][k_usbhs_pkt_cap] |
| Per-pipe IN staging (dev->host). | |
| uint16_t | pin_len [k_usbhs_pipes] |
| Bytes staged per IN pipe. | |
| uint16_t | pin_rd [k_usbhs_pipes] |
| Read cursor per IN pipe. | |
| bool | pin_ready [k_usbhs_pipes] |
| Pipe holds an unread packet. | |
| uint8_t | pipe_ep [k_usbhs_pipes] |
| Device endpoint number per host pipe. | |
| uint16_t | pipe_maxp [k_usbhs_pipes] |
| PIPEMAXP shadow per host pipe. | |
| uint16_t | pipe_pid [k_usbhs_pipes] |
| PIPECTR PID shadow per host pipe. | |
| bool | prev_usbrst |
| Previous DVSTCTR0.USBRST level (reset-edge detect). | |
| uint32_t | setups |
| SETUP packets bridged to the device. | |
| uint32_t | bulk_out |
| Bulk-OUT packets delivered. | |
| uint32_t | bulk_in |
| Bulk-IN packets collected. | |
| uint16_t | pipecfg [k_ra8_usb_pipe_count] |
| Windowed PIPECFG per pipe. | |
| uint16_t | pipebuf [k_ra8_usb_pipe_count] |
| Windowed PIPEBUF per pipe. | |
| uint16_t | pipemaxp [k_ra8_usb_pipe_count] |
| Windowed PIPEMAXP per pipe. | |
| uint16_t | pipeperi [k_ra8_usb_pipe_count] |
| Windowed PIPEPERI per pipe. | |
| uint8_t | stage [k_usbhs_stage_cap] |
| CFIFO OUT staging buffer. | |
| uint16_t | stage_len |
| Staged OUT bytes. | |
| uint16_t | rhst |
| DVSTCTR0.RHST after bus reset. | |
| bool | engaged |
| Model owns the window. | |
| bool | allowed |
| main.c granted the loop. | |
| bool | last_setup_in |
| Last SETUP was device-to-host. | |
| bool | sie_status_done |
| SIE ran the status (SET_ADDR). | |
| bool | ccpl_armed |
| Awaiting the device's CCPL. | |
| bool | status_zlp |
| Status ZLP ready for the host. | |
Aggregate USBHS host-controller model state.
Aggregate USBHS host-model state.
The 16-bit reg shadow answers the plain register reads/writes; the staging buffers carry the bytes crossing the modelled cable. din holds the device's control-IN response (or a synthetic status ZLP); pout / pin hold the per-pipe bulk OUT / IN payloads. pipe_ep / pipe_maxp / pipe_pid mirror the per-pipe config the host programs through PIPESEL/PIPECTR.
The 16-bit reg shadow answers every register without special semantics; the per-pipe arrays are the PIPESEL-windowed configuration; stage accumulates CFIFO writes until BVAL commits them over the loop.
stage_len <= k_usbhs_stage_cap. Definition at line 141 of file board_periph_usbhs_host.c.
| bool usbhs_state_t::allowed |
main.c granted the loop.
Definition at line 127 of file board_usb_host.c.
| uint32_t usbhs_state_t::bulk_in |
Bulk-IN packets collected.
Bulk-IN packets (report).
Definition at line 171 of file board_periph_usbhs_host.c.
| uint32_t usbhs_state_t::bulk_out |
Bulk-OUT packets delivered.
Bulk-OUT packets (report).
Definition at line 170 of file board_periph_usbhs_host.c.
| bool usbhs_state_t::ccpl_armed |
Awaiting the device's CCPL.
Definition at line 130 of file board_usb_host.c.
| uint8_t usbhs_state_t::ctrl_breq |
Last SETUP bRequest.
Definition at line 151 of file board_periph_usbhs_host.c.
| bool usbhs_state_t::ctrl_read |
Last SETUP was a control read.
Definition at line 150 of file board_periph_usbhs_host.c.
| bool usbhs_state_t::ctrl_status_pending |
Control-write status awaits dev CCPL.
Definition at line 152 of file board_periph_usbhs_host.c.
| uint8_t usbhs_state_t::din[k_usbhs_din_cap] |
DCP IN staging (device -> host control data).
Definition at line 144 of file board_periph_usbhs_host.c.
| uint16_t usbhs_state_t::din_len |
Bytes staged in din.
Definition at line 145 of file board_periph_usbhs_host.c.
| uint16_t usbhs_state_t::din_rd |
Read cursor as the host drains din.
Definition at line 146 of file board_periph_usbhs_host.c.
| bool usbhs_state_t::din_ready |
din holds an unread packet (DCP BRDY source).
Definition at line 147 of file board_periph_usbhs_host.c.
| bool usbhs_state_t::engaged |
Model owns the window.
Definition at line 126 of file board_usb_host.c.
| bool usbhs_state_t::last_setup_in |
Last SETUP was device-to-host.
Definition at line 128 of file board_usb_host.c.
| uint8_t usbhs_state_t::pin[k_usbhs_pipes][k_usbhs_pkt_cap] |
Per-pipe IN staging (dev->host).
Definition at line 158 of file board_periph_usbhs_host.c.
| uint16_t usbhs_state_t::pin_len[k_usbhs_pipes] |
Bytes staged per IN pipe.
Definition at line 159 of file board_periph_usbhs_host.c.
| uint16_t usbhs_state_t::pin_rd[k_usbhs_pipes] |
Read cursor per IN pipe.
Definition at line 160 of file board_periph_usbhs_host.c.
| bool usbhs_state_t::pin_ready[k_usbhs_pipes] |
Pipe holds an unread packet.
Definition at line 161 of file board_periph_usbhs_host.c.
| uint8_t usbhs_state_t::pipe_ep[k_usbhs_pipes] |
Device endpoint number per host pipe.
Definition at line 163 of file board_periph_usbhs_host.c.
| uint16_t usbhs_state_t::pipe_maxp[k_usbhs_pipes] |
PIPEMAXP shadow per host pipe.
Definition at line 164 of file board_periph_usbhs_host.c.
| uint16_t usbhs_state_t::pipe_pid[k_usbhs_pipes] |
PIPECTR PID shadow per host pipe.
Definition at line 165 of file board_periph_usbhs_host.c.
| uint16_t usbhs_state_t::pipebuf[k_ra8_usb_pipe_count] |
Windowed PIPEBUF per pipe.
Definition at line 120 of file board_usb_host.c.
| uint16_t usbhs_state_t::pipecfg[k_ra8_usb_pipe_count] |
Windowed PIPECFG per pipe.
Definition at line 119 of file board_usb_host.c.
| uint16_t usbhs_state_t::pipemaxp[k_ra8_usb_pipe_count] |
Windowed PIPEMAXP per pipe.
Definition at line 121 of file board_usb_host.c.
| uint16_t usbhs_state_t::pipeperi[k_ra8_usb_pipe_count] |
Windowed PIPEPERI per pipe.
Definition at line 122 of file board_usb_host.c.
| uint8_t usbhs_state_t::pout[k_usbhs_pipes][k_usbhs_pkt_cap] |
Per-pipe OUT staging (host->dev).
Definition at line 154 of file board_periph_usbhs_host.c.
| uint16_t usbhs_state_t::pout_len[k_usbhs_pipes] |
Bytes accumulated per OUT pipe.
Definition at line 155 of file board_periph_usbhs_host.c.
| bool usbhs_state_t::pout_wait[k_usbhs_pipes] |
OUT pipe awaiting device drain (BEMP).
Definition at line 156 of file board_periph_usbhs_host.c.
| bool usbhs_state_t::prev_usbrst |
Previous DVSTCTR0.USBRST level (reset-edge detect).
Definition at line 167 of file board_periph_usbhs_host.c.
| uint16_t usbhs_state_t::reg |
16-bit reflect-on-read register shadow.
Plain register shadow.
Definition at line 142 of file board_periph_usbhs_host.c.
| uint16_t usbhs_state_t::rhst |
DVSTCTR0.RHST after bus reset.
Definition at line 125 of file board_usb_host.c.
| uint8_t usbhs_state_t::setup[k_usbhs_setup_len] |
Latched 8-byte SETUP packet.
Definition at line 149 of file board_periph_usbhs_host.c.
| uint32_t usbhs_state_t::setups |
SETUP packets bridged to the device.
SETUPs delivered (report).
Definition at line 169 of file board_periph_usbhs_host.c.
| bool usbhs_state_t::sie_status_done |
SIE ran the status (SET_ADDR).
Definition at line 129 of file board_usb_host.c.
| uint8_t usbhs_state_t::stage[k_usbhs_stage_cap] |
CFIFO OUT staging buffer.
Definition at line 123 of file board_usb_host.c.
| uint16_t usbhs_state_t::stage_len |
Staged OUT bytes.
Definition at line 124 of file board_usb_host.c.
| bool usbhs_state_t::status_zlp |
Status ZLP ready for the host.
Definition at line 131 of file board_usb_host.c.