sd_32m_manager.h

来自「基于U(375)盘及SD(SPI模式)卡集成文件系统(包括底层驱动)」· C头文件 代码 · 共 45 行

H
45
字号
#ifndef _SD_32M_MANAGER_H
#define _SD_32M_MANAGER_H

#include "sd_cmd.h"

typedef struct _Record_photo{
   UINT8 data[1024*4];
   UINT16 len;
}Record_photo;



typedef struct _photo_record_inf{
   UINT8          work_num[4]; //eight BCD number 
   UINT16         name[5];     //GBK
   UINT8          time[5];     //ten BCD number  , no second 
   Record_photo     jpeg;
}photo_record_inf;



typedef struct _SD32M_mgr{
   UINT16      RecordFlag;
   UINT32      realPhotoRecordNum; //
   UINT8       (*save_photo_record) (struct _SD32M_mgr* p, photo_record_inf* pRecord);
   UINT8       (*get_photo_record)  (struct _SD32M_mgr* p, photo_record_inf* pRecord, UINT32 index);
   int	 	   (*init_sd32M)  (struct _SD32M_mgr* p);
   UINT8       (*clear_record) (struct _SD32M_mgr* p);//include normal record and photo record

}SD32M_mgr;

extern SD32M_mgr *pSD32MManager;
SD32M_mgr* SD32MManagerCreate(void);


static  UINT8 SD32MmgrSavePhotoRecord(SD32M_mgr* p, photo_record_inf* pRecord);

static  UINT8 SD32MmgrGetPhotoRecord(SD32M_mgr* p, photo_record_inf* pRecord, UINT32 index);

static  UINT8 SD32MmgrClearRecord(SD32M_mgr* p);

static  int SD32MmgrInitSD32M(SD32M_mgr* p);

#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?