refile-重命名文件
仅X2、X3、X5系列支持
refile srcfilepath,decfilepath
srcfilepath:源文件路径
decfilepath:目标文件路径
refile-示例1
1 //将内存文件系统中的0.jpg更名为1.jpg
2 refile "ram/0.jpg","ram/1.jpg"

refile-示例2
1 //将SD卡根目录中的a.jpg更名为b.jpg
2 refile "sd0/a.jpg","sd0/b.jpg"

refile-示例3
1 t1.txt="sd0/a.jpg"
2 t2.txt="sd0/b.jpg"
3
4 //将SD卡根目录中的a.jpg更名为b.jpg
5 refile t1.txt,t2.txt

备注:
要使用内存文件系统必须先在工程配置选项中配置内存文件系统的大小,新建工程默认内存文件系统大小为0,即不可能使用。
refile指令-样例工程下载
演示工程下载链接: