|
ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
|
The modelled card: backing image + command/response framing. More...
#include <board_periph_sd_internal.h>
Data Fields | |
| int | image_fd |
| Owned anonymous sparse backing descriptor. | |
| uint64_t | image_len |
| Image size in bytes (64-bit: cards > 4 GB). | |
| bool | attached |
| A --sd image is loaded. | |
| uint8_t | fat_bits |
| 12/16/32 if formatted by –sd-new, else 0. | |
| char | label [k_sd_label_cap] |
| Volume label (11 + NUL), for GUI. | |
| bool | collecting |
| Mid command-frame collection. | |
| bool | app_cmd |
| Previous command was CMD55 (APP_CMD). | |
| bool | ready |
| ACMD41 has completed. | |
| uint8_t | cmd [k_sd_cmd_len] |
| Cmd. | |
| uint32_t | cmd_idx |
| Cmd index. | |
| uint8_t | resp [k_sd_resp_cap] |
| Resp. | |
| uint32_t | resp_len |
| Resp length. | |
| uint32_t | resp_pos |
| Resp pos. | |
| board_sd_wr_phase_t | wr_phase |
| CMD24/CMD25 write sub-state. | |
| bool | wr_multi |
| Write is CMD25 (multi-block). | |
| uint64_t | wr_off |
| Byte offset of the current block. | |
| uint32_t | wr_cnt |
| Bytes seen in the data/CRC phase. | |
| uint8_t | wr_block [k_sd_block] |
| Bounded block-write staging buffer. | |
| bool | rd_multi |
| An open CMD18 read stream. | |
| uint64_t | rd_off |
| Byte offset of the next streamed CMD18 block. | |
| uint32_t | erase_start |
| CMD32 ERASE_WR_BLK_START block. | |
| uint32_t | erase_end |
| CMD33 ERASE_WR_BLK_END block. | |
The modelled card: backing image + command/response framing.
Definition at line 86 of file board_periph_sd_internal.h.
| bool board_sd_state_t::app_cmd |
Previous command was CMD55 (APP_CMD).
Definition at line 93 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_dispatch_ident(), and internal_board_sd_process_cmd().
| bool board_sd_state_t::attached |
A --sd image is loaded.
Definition at line 89 of file board_periph_sd_internal.h.
| uint8_t board_sd_state_t::cmd[k_sd_cmd_len] |
Cmd.
Definition at line 95 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_process_cmd().
| uint32_t board_sd_state_t::cmd_idx |
Cmd index.
Definition at line 96 of file board_periph_sd_internal.h.
| bool board_sd_state_t::collecting |
Mid command-frame collection.
Definition at line 92 of file board_periph_sd_internal.h.
| uint32_t board_sd_state_t::erase_end |
CMD33 ERASE_WR_BLK_END block.
Definition at line 109 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_cmd_erase(), and internal_board_sd_dispatch_data().
| uint32_t board_sd_state_t::erase_start |
CMD32 ERASE_WR_BLK_START block.
Definition at line 108 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_cmd_erase(), and internal_board_sd_dispatch_data().
| uint8_t board_sd_state_t::fat_bits |
12/16/32 if formatted by –sd-new, else 0.
Definition at line 90 of file board_periph_sd_internal.h.
| int board_sd_state_t::image_fd |
Owned anonymous sparse backing descriptor.
Definition at line 87 of file board_periph_sd_internal.h.
| uint64_t board_sd_state_t::image_len |
Image size in bytes (64-bit: cards > 4 GB).
Definition at line 88 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_cmd_erase(), internal_board_sd_cmd_send_csd(), and internal_board_sd_fill_block().
| char board_sd_state_t::label[k_sd_label_cap] |
Volume label (11 + NUL), for GUI.
Definition at line 91 of file board_periph_sd_internal.h.
| bool board_sd_state_t::rd_multi |
An open CMD18 read stream.
Definition at line 105 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_begin_read(), internal_board_sd_read_stream_next(), and internal_board_sd_stop_read().
| uint64_t board_sd_state_t::rd_off |
Byte offset of the next streamed CMD18 block.
Definition at line 106 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_begin_read(), and internal_board_sd_read_stream_next().
| bool board_sd_state_t::ready |
ACMD41 has completed.
Definition at line 94 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_process_cmd().
| uint8_t board_sd_state_t::resp[k_sd_resp_cap] |
Resp.
Definition at line 97 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_begin_read(), internal_board_sd_begin_write(), internal_board_sd_cmd_erase(), internal_board_sd_cmd_erase_bound(), internal_board_sd_dispatch_data(), internal_board_sd_dispatch_ident(), internal_board_sd_process_cmd(), internal_board_sd_read_stream_next(), internal_board_sd_stage_block(), internal_board_sd_stop_read(), internal_sd_write_crc(), and internal_sd_write_token().
| uint32_t board_sd_state_t::resp_len |
Resp length.
Definition at line 98 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_begin_read(), internal_board_sd_begin_write(), internal_board_sd_cmd_erase(), internal_board_sd_cmd_erase_bound(), internal_board_sd_dispatch_data(), internal_board_sd_dispatch_ident(), internal_board_sd_process_cmd(), internal_board_sd_read_stream_next(), internal_board_sd_stage_block(), internal_board_sd_stop_read(), internal_sd_write_crc(), and internal_sd_write_token().
| uint32_t board_sd_state_t::resp_pos |
Resp pos.
Definition at line 99 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_process_cmd(), internal_board_sd_read_stream_next(), internal_sd_write_crc(), and internal_sd_write_token().
| uint8_t board_sd_state_t::wr_block[k_sd_block] |
Bounded block-write staging buffer.
Definition at line 104 of file board_periph_sd_internal.h.
Referenced by internal_sd_write_crc(), and internal_sd_write_data().
| uint32_t board_sd_state_t::wr_cnt |
Bytes seen in the data/CRC phase.
Definition at line 103 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_begin_write(), internal_sd_write_crc(), internal_sd_write_data(), and internal_sd_write_token().
| bool board_sd_state_t::wr_multi |
Write is CMD25 (multi-block).
Definition at line 101 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_begin_write(), internal_sd_write_crc(), and internal_sd_write_token().
| uint64_t board_sd_state_t::wr_off |
Byte offset of the current block.
Definition at line 102 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_begin_write(), and internal_sd_write_crc().
| board_sd_wr_phase_t board_sd_state_t::wr_phase |
CMD24/CMD25 write sub-state.
Definition at line 100 of file board_periph_sd_internal.h.
Referenced by internal_board_sd_begin_write(), internal_board_sd_write_byte(), internal_sd_write_crc(), internal_sd_write_data(), and internal_sd_write_token().