小学生
最后登录1970-1-1
在线时间 小时
注册时间2015-9-25
|
楼主 |
发表于 2016-6-2 18:54:03
|
显示全部楼层
if(strstr(fn,".mp3")||strstr(fn,".MP3")||strstr(fn,".wav")||strstr(fn,".WAV"))//ÅD¶ÏêÇ·ñmp3»òwavÎļt
{
if (strlen(path)+strlen(fn)<FILE_NAME_LEN)
{
sprintf(file_name, "%s/%s", path, fn);
//′æ′¢òôÆμÎļtÃûμ½playlist(o¬Â·¾¶)
res = f_open (&file, "0:mp3player/playlist.txt", FA_READ|FA_WRITE|FA_CREATE_ALWAYS );
res = f_lseek (&file, file_num*FILE_NAME_LEN);
res = f_write (&file, file_name, FILE_NAME_LEN, &rw_num);
res = f_close (&file);
//′æ′¢òôÆμÎļtÃû¼°Â·¾¶μ½lcdlist£¨½öÎļtÃû£©
res = f_open (&file, "0:mp3player/lcdlist.txt", FA_READ|FA_WRITE|FA_CREATE_ALWAYS );
res = f_lseek (&file, file_num*FILE_NAME_LEN);
res = f_write (&file, fn, FILE_NAME_LEN, &rw_num);
res = f_close (&file);
file_num++;//¼Ç¼Îļt¸öêy
}
}//if mp3||wav
这段代码不运行啊,为什么 |
|