Decoded contents of the SD card CSD register.
More...
Decoded contents of the SD card CSD register.
Populated by decode_csd_v1 or decode_csd_v2 and used to extract capacity, block size, and block count, which are then stored in the sd_handle_s for use by read/write and FatFs ioctl calls.
Definition at line 163 of file sd.c.
◆ capacity_bytes
| uint32_t SD_CSD_INFO_ts::capacity_bytes |
Total card capacity in bytes.
Definition at line 164 of file sd.c.
◆ capacity_mb
| uint32_t SD_CSD_INFO_ts::capacity_mb |
Total card capacity in megabytes.
Definition at line 165 of file sd.c.
◆ block_len
| uint16_t SD_CSD_INFO_ts::block_len |
Read/write block length in bytes.
Definition at line 166 of file sd.c.
◆ block_count
| uint32_t SD_CSD_INFO_ts::block_count |
Total number of blocks on the card.
Definition at line 167 of file sd.c.
◆ tran_speed
| uint8_t SD_CSD_INFO_ts::tran_speed |
Maximum data transfer speed encoded value.
Definition at line 168 of file sd.c.
◆ ccc
| uint16_t SD_CSD_INFO_ts::ccc |
Card command classes bitmask.
Definition at line 169 of file sd.c.
◆ csd_structure
| uint8_t SD_CSD_INFO_ts::csd_structure |
CSD structure version: 0 = v1.0, 1 = v2.0.
Definition at line 170 of file sd.c.
◆ c_size [1/2]
| uint16_t SD_CSD_INFO_ts::c_size |
Device size (12-bit). Used to compute block count.
Definition at line 174 of file sd.c.
◆ c_size_mult
| uint8_t SD_CSD_INFO_ts::c_size_mult |
Device size multiplier (3-bit).
Definition at line 175 of file sd.c.
◆ read_bl_len
| uint8_t SD_CSD_INFO_ts::read_bl_len |
Maximum read block length exponent.
Definition at line 176 of file sd.c.
◆ [struct]
| struct { ... } SD_CSD_INFO_ts::v1 |
CSD v1.0 specific fields (SDSC cards).
◆ c_size [2/2]
| uint32_t SD_CSD_INFO_ts::c_size |
Device size (22-bit). Capacity = (c_size + 1) × 512 KB.
Definition at line 181 of file sd.c.
◆ [struct]
| struct { ... } SD_CSD_INFO_ts::v2 |
CSD v2.0 specific fields (SDHC/SDXC cards).
◆ taac
| uint8_t SD_CSD_INFO_ts::taac |
Time-dependent part of data access time.
Definition at line 184 of file sd.c.
◆ nsac
| uint8_t SD_CSD_INFO_ts::nsac |
Clock-dependent part of data access time (in clock cycles × 100).
Definition at line 185 of file sd.c.
◆ read_bl_partial
| uint8_t SD_CSD_INFO_ts::read_bl_partial |
Partial blocks allowed for read (1 = yes).
Definition at line 186 of file sd.c.
◆ write_blk_misalign
| uint8_t SD_CSD_INFO_ts::write_blk_misalign |
Write block misalignment allowed (1 = yes).
Definition at line 187 of file sd.c.
◆ read_blk_misalign
| uint8_t SD_CSD_INFO_ts::read_blk_misalign |
Read block misalignment allowed (1 = yes).
Definition at line 188 of file sd.c.
◆ dsr_imp
| uint8_t SD_CSD_INFO_ts::dsr_imp |
Configurable driver stage implemented (1 = yes).
Definition at line 189 of file sd.c.
◆ erase_blk_en
| uint8_t SD_CSD_INFO_ts::erase_blk_en |
Erase single block enabled (1 = yes).
Definition at line 190 of file sd.c.
◆ sector_size
| uint8_t SD_CSD_INFO_ts::sector_size |
Erasable sector size in blocks minus 1.
Definition at line 191 of file sd.c.
◆ wp_grp_size
| uint8_t SD_CSD_INFO_ts::wp_grp_size |
Write-protect group size in erasable sectors minus 1.
Definition at line 192 of file sd.c.
◆ wp_grp_enable
| uint8_t SD_CSD_INFO_ts::wp_grp_enable |
Write-protect group enable (1 = yes).
Definition at line 193 of file sd.c.
◆ r2w_factor
| uint8_t SD_CSD_INFO_ts::r2w_factor |
Write speed factor relative to read speed.
Definition at line 194 of file sd.c.
◆ write_bl_len
| uint8_t SD_CSD_INFO_ts::write_bl_len |
Maximum write block length exponent.
Definition at line 195 of file sd.c.
◆ write_bl_partial
| uint8_t SD_CSD_INFO_ts::write_bl_partial |
Partial blocks allowed for write (1 = yes).
Definition at line 196 of file sd.c.
◆ file_format_grp
| uint8_t SD_CSD_INFO_ts::file_format_grp |
File format group (0 = hard disk / DOS FAT).
Definition at line 197 of file sd.c.
◆ copy
| uint8_t SD_CSD_INFO_ts::copy |
Copy flag (0 = original).
Definition at line 198 of file sd.c.
◆ perm_write_protect
| uint8_t SD_CSD_INFO_ts::perm_write_protect |
Permanent write protection (1 = yes).
Definition at line 199 of file sd.c.
◆ tmp_write_protect
| uint8_t SD_CSD_INFO_ts::tmp_write_protect |
Temporary write protection (1 = yes).
Definition at line 200 of file sd.c.
◆ file_format
| uint8_t SD_CSD_INFO_ts::file_format |
File format of the card.
Definition at line 201 of file sd.c.
◆ wp_upc
| uint8_t SD_CSD_INFO_ts::wp_upc |
Write protect until power cycle.
Definition at line 202 of file sd.c.
◆ crc
| uint8_t SD_CSD_INFO_ts::crc |
CRC7 checksum of the CSD register.
Definition at line 203 of file sd.c.
The documentation for this struct was generated from the following file: