Enhancements to the SDC driver.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@3002 35acf78f-673a-0410-8e92-d51de3d6d3f4master
parent
88e92b3fc3
commit
9b9bd471ed
|
@ -163,6 +163,32 @@ typedef enum {
|
|||
*/
|
||||
#define SDC_R1_IS_CARD_LOCKED(r1) (((r1) >> 21) & 1)
|
||||
|
||||
/**
|
||||
* @brief Returns the driver state.
|
||||
*
|
||||
* @param[in] sdcp pointer to the @p SDCDriver object
|
||||
* @return The driver state.
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
#define sdcGetDriverState(sdcp) ((sdcp)->state)
|
||||
|
||||
/**
|
||||
* @brief Returns the write protect status.
|
||||
* @note This macro wraps a low level function named
|
||||
* @p sdc_lld_is_write_protected(), this function must be
|
||||
* provided by the application because it is not part of the
|
||||
* SDC driver.
|
||||
*
|
||||
* @param[in] sdcp pointer to the @p SDCDriver object
|
||||
* @return The card state.
|
||||
* @retval FALSE card not inserted.
|
||||
* @retval TRUE card inserted.
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
#define sdcIsWriteProtected(sdcp) (sdc_lld_is_write_protected(sdcp))
|
||||
|
||||
/*===========================================================================*/
|
||||
/* External declarations. */
|
||||
/*===========================================================================*/
|
||||
|
|
|
@ -190,6 +190,7 @@ extern "C" {
|
|||
uint8_t *buf, uint32_t n);
|
||||
bool_t sdc_lld_write(SDCDriver *sdcp, uint32_t startblk,
|
||||
const uint8_t *buf, uint32_t n);
|
||||
bool_t sdc_lld_is_write_protected(SDCDriver *sdcp);
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -72,6 +72,7 @@
|
|||
|
||||
*** 2.3.4 ***
|
||||
- NEW: Now the STM32 SDC driver supports unaligned buffers transparently.
|
||||
Optimized the driver for single block read and write operations.
|
||||
|
||||
*** 2.3.3 ***
|
||||
- FIX: Fixed race condition in output queues (bug 3303908)(backported
|
||||
|
|
Loading…
Reference in New Issue