|
Contiki-NG
|
SD/MMC device driver architecture-specific definitions. More...
Files | |
| file | mmc-arch.h |
| Header file for the SD/MMC device driver architecture-specific definitions. | |
| file | mmc-arch.c |
| Implementation of the SD/MMC device driver RE-Mote-specific definitions. | |
Functions | |
| void | mmc_arch_cd_changed_callback (uint8_t dev, bool cd) |
| Callback of the SD/MMC driver to call when the card-detection signal changes. More... | |
| bool | mmc_arch_get_cd (uint8_t dev) |
| Gets the state of the card-detection signal. More... | |
| bool | mmc_arch_get_wp (uint8_t dev) |
| Gets the state of the write-protection signal. More... | |
| void | mmc_arch_spi_select (uint8_t dev, bool sel) |
| Sets the SPI /CS signal as indicated. More... | |
| void | mmc_arch_spi_set_clock_freq (uint8_t dev, uint32_t freq) |
| Sets the SPI clock frequency. More... | |
| void | mmc_arch_spi_xfer (uint8_t dev, const void *tx_buf, size_t tx_cnt, void *rx_buf, size_t rx_cnt) |
| Performs an SPI transfer. More... | |
SD/MMC device driver architecture-specific definitions.
| void mmc_arch_cd_changed_callback | ( | uint8_t | dev, |
| bool | cd | ||
| ) |
Callback of the SD/MMC driver to call when the card-detection signal changes.
| dev | Device |
| cd | Whether a card is detected |
| bool mmc_arch_get_cd | ( | uint8_t | dev | ) |
Gets the state of the card-detection signal.
| dev | Device |
Definition at line 73 of file mmc-arch.c.
| bool mmc_arch_get_wp | ( | uint8_t | dev | ) |
Gets the state of the write-protection signal.
| dev | Device |
Definition at line 92 of file mmc-arch.c.
| void mmc_arch_spi_select | ( | uint8_t | dev, |
| bool | sel | ||
| ) |
Sets the SPI /CS signal as indicated.
| dev | Device |
| sel | Whether to assert /CS |
Definition at line 98 of file mmc-arch.c.
| void mmc_arch_spi_set_clock_freq | ( | uint8_t | dev, |
| uint32_t | freq | ||
| ) |
Sets the SPI clock frequency.
| dev | Device |
| freq | Frequency (Hz) |
Definition at line 108 of file mmc-arch.c.
References spix_set_clock_freq().
| void mmc_arch_spi_xfer | ( | uint8_t | dev, |
| const void * | tx_buf, | ||
| size_t | tx_cnt, | ||
| void * | rx_buf, | ||
| size_t | rx_cnt | ||
| ) |
Performs an SPI transfer.
| dev | Device |
| tx_buf | Pointer to the transmission buffer, or NULL |
| tx_cnt | Number of bytes to transmit, or 0 |
| rx_buf | Pointer to the reception buffer, or NULL |
| rx_cnt | Number of bytes to receive, or 0 |
Definition at line 114 of file mmc-arch.c.
1.8.13