powercxz 发表于 2011-3-12 23:22:39

kernel_finsh_filesystem 例子问题

用IAR 6.1 编译执行:

SystemInit......

\ | /
- RT -   Thread Operating System
/ | \ 0.4.0 build Mar 12 2011
2006 - 2009 Copyright by rt-thread team
found part, begin: 32256, size: 1.860GB
File System initialized!
准备读取文件 测试: cat("/readme.txt")
Open /readme.txt failed
finsh>>ls("/")
Directory /:
      'm', 134273901, 0x0800db6d
finsh>>ls()
(filename != RT_NULL) assert failed at dfs_normalize_path:270


用MDK412 编译执行
SystemInit......

\ | /
- RT -   Thread Operating System
/ | \ 0.4.0 build Mar 12 2011
2006 - 2009 Copyright by rt-thread team
found part, begin: 32256, size: 1.860GB
File System initialized!
准备读取文件 测试: cat("/readme.txt")
Open /readme.txt failed
finsh>>ls()\
Invalid token
finsh>>ls()
system does not support working dir
No such directory
      0, 0x00000000
finsh>>ls("/")
Directory /:
      0, 0x00000000
finsh>>


对开发工具,对软件本事产生怀疑, 感觉商业开发工具都不稳定。

aozima 发表于 2011-3-13 13:37:25

Rt-thread的finsh命令语法按C语言语法为准.
ls的参数是路径名(具体请看工程中的ls函数).
ls() 不加参数,那么实际执行ls函数时参数为不确定值.会出现任何不可预料的结果.

aozima 发表于 2011-3-13 13:39:58

既然楼主是用的这份打包过的代码.那么包里应该有readme.txt
不过楼主应该没有看.
页: [1]
查看完整版本: kernel_finsh_filesystem 例子问题