自己弄了下,用chdir 就不需要用全路径了。先mkdir 在chdir 最后直接open 文件名
res =f_opendir(&dir, path);/* Open the directory */if(res == FR_OK) { res = f_open(&file, nfile, FA_CREATE_NEW | FA_WRITE);/* Open the file with name "Hacking.txt" */GPIO_SetBits(GPIOD, GPIO_Pin_13);if(res == FR_OK) { insert_signatre(&file); f_close(&file); ...
/* Open the current directory for access. */ fresult = f_opendir(&dir, path); /* Enter loop to enumerate through all directory entries. */ while(FR_OK == fresult) { /* Read an entry from the directory. */ fresult = f_readdir(&dir, &fno); /* Check for error and return ...
下面是一段代码,这段代码中有标准未定义的行为。代码如下: #include<iostream> using namespace std...
下面是一段代码,这段代码中有标准未定义的行为。代码如下: #include<iostream> using namespace std...