203 uint8 *partition_type);
Definitions for a simple block device interface.
unsigned long long uint64
64-bit unsigned integer
Definition types.h:32
unsigned long uint32
32-bit unsigned integer
Definition types.h:33
unsigned char uint8
8-bit unsigned integer
Definition types.h:35
int sd_write_blocks(uint32 block, size_t count, const uint8 *buf)
Write one or more blocks to the SD card.
uint64 sd_get_size(void)
Retrieve the size of the SD card.
int sd_blockdev_for_device(kos_blockdev_t *rv)
Get a block device for the SD card.
int sd_init(void)
Initialize the SD card for use.
uint8 sd_crc7(const uint8 *data, int size, uint8 crc)
Calculate a SD/MMC-style CRC over a block of data.
int sd_init_ex(const sd_init_params_t *params)
Initialize the SD card with extended parameters.
int sd_read_blocks(uint32 block, size_t count, uint8 *buf)
Read one or more blocks from the SD card.
int sd_shutdown(void)
Shut down SD card support.
int sd_blockdev_for_partition(int partition, kos_blockdev_t *rv, uint8 *partition_type)
Get a block device for a given partition on the SD card.
sd_interface_t
SD card interface type.
Definition sd.h:59
@ SD_IF_SCIF
Use SCIF interface.
Definition sd.h:60
@ SD_IF_SCI
Use SCI interface.
Definition sd.h:61
A simple block device.
Definition blockdev.h:54
SD card initialization parameters.
Definition sd.h:65
sd_interface_t interface
Interface to use (SCIF or SCI)
Definition sd.h:66
bool check_crc
Enable CRC checking (true) or disable (false)
Definition sd.h:67