提交 1d44368b 编写于 作者: T tyustli

[bsp] [stm32] port to dfs

上级 03f8762e
...@@ -7,6 +7,9 @@ src = Split(""" ...@@ -7,6 +7,9 @@ src = Split("""
main.c main.c
""") """)
if GetDepend(['RT_USING_DFS']):
src += ['mnt.c']
group = DefineGroup('Applications', src, depend = [''], CPPPATH = CPPPATH) group = DefineGroup('Applications', src, depend = [''], CPPPATH = CPPPATH)
Return('group') Return('group')
#include <rtthread.h>
#ifdef RT_USING_DFS
#include <dfs_fs.h>
int mnt_init(void)
{
if (dfs_mount("W25Q256", "/", "elm", 0, 0) == 0)
{
rt_kprintf("W25Q256 mount successful!\n");
}
else
{
rt_kprintf("W25Q256 mount failed!\n");
}
return 0;
}
INIT_ENV_EXPORT(mnt_init);
#endif
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册