你的浏览器版本过低,可能导致网站不能正常访问!
为了你能正常使用网站功能,请使用这些浏览器。

Primer2 的SD文件例程

[复制链接]
废鱼 发布时间:2010-3-22 16:29
 这个工程主要是简单的显示SD卡的文件目录。
, |& r% w& {& j$ vThis project implements a simple file explorer that displays the directory structure on the SD card.The included CircleOs binary include a SDIO driver and a Fat12/16/32 implementation based on DosFS. This a demo project to show usage of the SD card.9 H' f; K  I( V% n) X
This project is aimed to be a demo project about how to use the CircleOS filesystem. It can display PRM (converted BMP, JPG, etc) images with a sample viewer.9 z, l  U! G# U% }% \
Included in this project an application to convert BMP, JPG, etc files to PRM with the functionality to scale the image to a desired resolution.
5 U  B+ A- {0 W, M: `# K Current layout of PRM image file:' \$ p9 B; C; ?
 8byte header:# A" H3 ^5 F  H, [
- byte 0: height5 W5 ?3 j1 l0 ^6 P$ ~4 w2 n* W
- byte 1: width- e6 e- ]( ]2 C; e1 y7 u8 L
- 6 bytes for future use- l! j3 ~9 J+ D/ h
- pixel data (2 bytes per pixel)) W) A) r8 I% z# Q' d6 T
 FS interface functions:1 T1 M0 L2 A& c' Y* ]
u32 FS_Mount(enum STORAGE_device device);
, L( h" @  q8 \u32 FS_Unmount(enum STORAGE_device device);# j% b. B* p- o
u32 FS_OpenFile(PVOLINFO volinfo, u8 *path, u8 mode, PFILEINFO fileinfo);
: o, `) f' X( E1 o- H7 L$ [u32 FS_ReadFile(PFILEINFO fileinfo,  u8 *buffer, u32 *successcount, u32 len);% K8 X: T; G5 Z
u32 FS_WriteFile(PFILEINFO fileinfo,  u8 *buffer, u32 *successcount, u32 len);' W- b4 O5 H9 H5 e6 x( \7 Y: _
u32 FS_Close(PFILEINFO fileinfo);
1 _' b$ {0 W( Z2 f  h: s$ U- avoid FS_Seek(PFILEINFO fileinfo, u32 offset);/ o6 Y/ B& ~* s
u32 FS_Delete(PVOLINFO volinfo, u8 *path);; ~- b6 x/ f: o' r8 U2 x4 Z( m* d* y4 q" y
u32 FS_GetNextEntry(PVOLINFO volinfo, PDIRINFO dirinfo, PDIRENT dirent);
& y' X/ V+ `" m) A9 o& q2 ^; Fu32 FS_OpenDirectory(PVOLINFO volinfo,u8 *dirname, PDIRINFO dirinfo);
8 U" R( S7 v1 Cu32 FS_GetVolumeInfo(u8 unit,  u32 startsector, PVOLINFO volinfo);
' K: }" d( ^6 _ ( I8 J" V" [9 ^- w: J! Y' [
 
6 ~# u* k! b& E# m+ sThis is a snapshot of my current work in progress with partially integrated jpg decompressor
; @  S/ G; n1 {. e: F0 M9 |+ [" [/ o" t" g8 T4 V$ k% t
 
收藏 评论0 发布时间:2010-3-22 16:29

举报

0个回答

所属标签

关于
我们是谁
投资者关系
意法半导体可持续发展举措
创新与技术
意法半导体官网
联系我们
联系ST分支机构
寻找销售人员和分销渠道
社区
媒体中心
活动与培训
隐私策略
隐私策略
Cookies管理
行使您的权利
官方最新发布
STM32N6 AI生态系统
STM32MCU,MPU高性能GUI
ST ACEPACK电源模块
意法半导体生物传感器
STM32Cube扩展软件包
关注我们
st-img 微信公众号
st-img 手机版