RTEMS  5.0.0
Data Structures | Macros | Functions | Variables
spi-sd-card.h File Reference

SD Card LibI2C driver. More...

#include <stdint.h>
#include <stdbool.h>
#include <rtems/libi2c.h>

Go to the source code of this file.

Data Structures

struct  sd_card_driver_entry
 

Macros

#define SD_CARD_IDLE_TOKEN   0xff
 
#define SD_CARD_COMMAND_SIZE   18
 
#define SD_CARD_TRANSFER_MODE_DEFAULT   { .baudrate = 400000, .bits_per_char = 8, .lsb_first = FALSE, .clock_inv = FALSE, .clock_phs = FALSE, .idle_char = SD_CARD_IDLE_TOKEN }
 
#define SD_CARD_COMMAND_DEFAULT
 
#define SD_CARD_N_AC_MAX_DEFAULT   5000
 

Functions

rtems_status_code sd_card_register (void)
 

Variables

sd_card_driver_entry sd_card_driver_table []
 
size_t sd_card_driver_table_size
 

Detailed Description

SD Card LibI2C driver.

Macro Definition Documentation

◆ SD_CARD_COMMAND_DEFAULT

#define SD_CARD_COMMAND_DEFAULT
Value:
{ \
SD_CARD_IDLE_TOKEN, \
0x40, 0, 0, 0, 0, 0x95, \
SD_CARD_IDLE_TOKEN, SD_CARD_IDLE_TOKEN, \
SD_CARD_IDLE_TOKEN, SD_CARD_IDLE_TOKEN, \
SD_CARD_IDLE_TOKEN, SD_CARD_IDLE_TOKEN, \
SD_CARD_IDLE_TOKEN, SD_CARD_IDLE_TOKEN, \
SD_CARD_IDLE_TOKEN, SD_CARD_IDLE_TOKEN, \
SD_CARD_IDLE_TOKEN \
}

◆ SD_CARD_COMMAND_SIZE

#define SD_CARD_COMMAND_SIZE   18

1 idle token before command 6 bytes for the command 1 to 8 bytes for response start (N_CR) 1 to 2 bytes for response 1 idle token after command (minimum N_RC)