|
CardSight 0.1.0
C API reference for the CardSight firmware and application
|
SD/MMC core: the description of the card and the disk it creates ("mmcblk0"). More...
Go to the source code of this file.
Functions | |
| bool | mmc_card_ready (const struct mmc_card *card) |
| Whether the card was identified and has not been removed. | |
| int | mmc_card_info (const struct mmc_card *card, struct mmc_card_info *info) |
| Copy what the card reports. | |
| int | mmc_blk_init (void) |
| Register the disk driver. | |
| const char * | mmc_last_error (void) |
| The last command-level card failure. | |
| void | mmc_last_error_clear (void) |
| Forget the last command-level failure. | |
| int | mmc_probe_error (void) |
| The last identification result. | |
| bool | mmc_slot_detecting (void) |
| Whether a card is in the slot but has not been identified yet. | |
SD/MMC core: the description of the card and the disk it creates ("mmcblk0").
Return values are 0 or a negative errno. A card reference keeps the structure alive after the card went away; its description stays readable.
| int mmc_blk_init | ( | void | ) |
Register the disk driver.
Initializes the card lock, waits for the slot power delay, probes a card when one is present, and registers the card as the block device "mmcblk0".
| int mmc_card_info | ( | const struct mmc_card * | card, |
| struct mmc_card_info * | info ) |
Copy what the card reports.
| [in] | card | Card to query. |
| [out] | info | Receives a snapshot of the card description. |
| bool mmc_card_ready | ( | const struct mmc_card * | card | ) |
Whether the card was identified and has not been removed.
| [in] | card | Card to check; NULL is not ready. |
| const char * mmc_last_error | ( | void | ) |
The last command-level card failure.
| int mmc_probe_error | ( | void | ) |
The last identification result.
| bool mmc_slot_detecting | ( | void | ) |
Whether a card is in the slot but has not been identified yet.