SD ドライバ 32F469IDISCOVERY
[詳解]
#include "sysconfig.h"
#include "tkprintf.h"
#include "timer.h"
#include "device.h"
#include "str.h"
#include "interrupt.h"
#include "device/sd_ioctl.h"
#include "task/syscall.h"
#include "stm32469i_discovery_sd.h"
#include "dkprintf.h"
[ソースコード]
|
#define | ENABLE_SD_DMA |
|
#define | SD_TIMEOUT (3*1000) |
|
|
void | BSP_SD_ReadCpltCallback (void) |
|
void | BSP_SD_WriteCpltCallback (void) |
|
static void | inthdr_sd_dma_rx (unsigned int intnum, void *sp) |
|
static void | inthdr_sd_dma_tx (unsigned int intnum, void *sp) |
|
static void | inthdr_sd (unsigned int intnum, void *sp) |
|
static int | sd_register (struct st_device *dev, char *param) |
|
static int | sd_unregister (struct st_device *dev) |
|
static int | sd_open (struct st_device *dev) |
|
static int | sd_close (struct st_device *dev) |
|
static int | sd_block_read (struct st_device *dev, void *data, unsigned int sector, unsigned int blkcount) |
|
static int | sd_block_write (struct st_device *dev, const void *data, unsigned int sector, unsigned int blkcount) |
|
static int | sd_ioctl (struct st_device *dev, unsigned int com, unsigned int arg, void *param) |
|
static int | sd_sync (struct st_device *dev) |
|
static int | sd_suspend (struct st_device *dev) |
|
static int | sd_resume (struct st_device *dev) |
|
|
SD_HandleTypeDef | uSdHandle |
|
static struct st_event | dma_rx_evt |
|
static struct st_event | dma_tx_evt |
|
static int | flg_dma_rx_cmp = 0 |
|
static int | flg_dma_tx_cmp = 0 |
|
static int | flg_sd_cmp = 0 |
|
static uint32_t | sdbuf [BLOCKSIZE] |
|
const struct st_device | sd_device |
|
SD ドライバ 32F469IDISCOVERY
- 日付
- 2018.08.18
- 著者
- Takashi SHUDO
32f469i-disc_sd.c に定義があります。
◆ sd_device
初期値:= {
.explan = "32F469IDISCOVERY SD Card Storage",
.register_dev = sd_register,
.unregister_dev = sd_unregister,
.open = sd_open,
.close = sd_close,
.block_read = sd_block_read,
.block_write = sd_block_write,
.ioctl = sd_ioctl,
.sync = sd_sync,
.suspend = sd_suspend,
.resume = sd_resume,
}
#define DEF_DEV_NAME_SD
標準ストレージデバイス名(MMC,SD等)
32f469i-disc_sd.c の 387 行目に定義があります。