| M480 BSP V3.05.001 The Board Support Package for M480 Series

Data Structures | Macros | Typedefs | Functions
sdh.h File Reference

M480 SDH driver header file. More...

`#include <stdio.h>`

Go to the source code of this file.

## Data Structures
struct | SDH_info_t

## Macros
#define | SDH_ERR_ID
#define | SDH_TIMEOUT
#define | SDH_NO_MEMORY
#define | Successful
#define | Fail
#define | SDH_TYPE_UNKNOWN
#define | SDH_TYPE_SD_HIGH
#define | SDH_TYPE_SD_LOW
#define | SDH_TYPE_MMC
#define | SDH_TYPE_EMMC
#define | SDH_NO_SD_CARD
#define | SDH_ERR_DEVICE
#define | SDH_INIT_TIMEOUT
#define | SDH_SELECT_ERROR
#define | SDH_WRITE_PROTECT
#define | SDH_INIT_ERROR
#define | SDH_CRC7_ERROR
#define | SDH_CRC16_ERROR
#define | SDH_CRC_ERROR
#define | SDH_CMD8_ERROR
#define | MMC_FREQ
#define | SD_FREQ
#define | SDHC_FREQ
#define | SD_PORT0
#define | SD_PORT1
#define | CardDetect_From_GPIO
#define | CardDetect_From_DAT3
#define | SDH_ENABLE_INT(sdh, u32IntMask)
| Enable specified interrupt. More...
#define | SDH_DISABLE_INT(sdh, u32IntMask)
| Disable specified interrupt. More...
#define | SDH_GET_INT_FLAG(sdh, u32IntMask)
| Get specified interrupt flag/status. More...
#define | SDH_CLR_INT_FLAG(sdh, u32IntMask)
| Clear specified interrupt flag/status. More...
#define | SDH_IS_CARD_PRESENT(sdh)
| Check SD Card inserted or removed. More...
#define | SDH_GET_CARD_CAPACITY(sdh)
| Get SD Card capacity. More...

## Typedefs
typedef struct SDH_info_t | SDH_INFO_T

## Functions
void | SDH_Open (SDH_T *sdh, uint32_t u32CardDetSrc)
| This function use to reset SD function and select card detection source and pin. More...
uint32_t | SDH_Probe (SDH_T *sdh)
| This function use to initial SD card. More...
uint32_t | SDH_Read (SDH_T *sdh, uint8_t *pu8BufAddr, uint32_t u32StartSec, uint32_t u32SecCount)
| This function use to read data from SD card. More...
uint32_t | SDH_Write (SDH_T *sdh, uint8_t *pu8BufAddr, uint32_t u32StartSec, uint32_t u32SecCount)
| This function use to write data to SD card. More...
uint32_t | SDH_CardDetection (SDH_T *sdh)
void | SDH_Open_Disk (SDH_T *sdh, uint32_t u32CardDetSrc)
void | SDH_Close_Disk (SDH_T *sdh)

## Detailed Description

M480 SDH driver header file.

Version
  V1.00 SPDX-License-Identifier: Apache-2.0

Copyright
  (C) 2016-2020 Nuvoton Technology Corp. All rights reserved.

Definition in file sdh.h.