使用STM32和fatfs在SD上记录int int
问题描述:
我想在SD卡上记录一些数据。我使用的是STM32f10x,我的代码对于字符串很适用。我有一个问题在我的SD上写入int。我使用这个代码写入:使用STM32和fatfs在SD上记录int int
解析度= f_write(& FSRC,ramBufferWrite,filecounter,& BW);
此外,我试过sprintf,它没有工作。如果你能帮助我,我将不胜感激。 谢谢。
答
我用“itoa”函数将int更改为字符串。另外,我使用“filecounter”来初始化文件缓冲区写入。
我们可以有更多的细节,也许是[mcve]? – berendi