关于sd卡是否可以分为两个fatfs文件系统

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

关于sd卡是否可以分为两个fatfs文件系统

887 Views
944706426
Contributor III

MCU:rt1052

板载了一张8G的sd卡,目前有一个需求:  SD卡分成两部分,前面4G挂载fatfs文件系统供rt1052正常读写,后面4G想通过usb虚拟成U盘供电脑使用。不知是否可行?

 

Labels (1)
0 Kudos
2 Replies

876 Views
jeremyzhou
NXP Employee
NXP Employee

Hi,
非常感谢使用NXP产品,很高兴为你提供技术支持!
1) 不知是否可行?
-- 在我看来,这是可行的,关键是如何分配和协调fatfs文件系统和USB协议栈操作SD card.
Have a great day,
TIC

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos

871 Views
944706426
Contributor III

了解了一下fatfs的分区,如下图实现了:

1.png

3.png

然后我在跑下面两个例子时有两种不同的结果:

 

2.png

第一个例子识别出来两个盘:

4.png

第二个例子只识别出第一个分区。

5.png

我暂时还没找出它们的区别,我其实只需要识别出其中一个,不知在那个地方修改?

0 Kudos