- Nov 15, 2013View Source
Welcome to the group.>I've recently been using NuttX in an STM32 project and I'm using SmartFS to store some files on an external SPI flash.>> Unless I've missed something it's not actually possible to use SmartFS in the vanilla source checked out from git. With SmartFS only enabled you can't mount it.. I suspect line 71 of nuttx/fs/fs_mount.c should be changed from:>> #if defined(CONFIG_FS_FAT) || defined(CONFIG_FS_ROMFS)>> to>> #if defined(CONFIG_FS_FAT) || defined(CONFIG_FS_ROMFS) || defined(CONFIG_FS_SMARTFS)
I think you are right! The logic enables the support for mounting file systems that require block drivers.> Then in nuttx/drivers/mtd/smart.c there are a few places that enable support to write that are wrapped in #ifdef CONFIG_FS_WRITABLE and CONFIG_FS_WRITABLE doesn't seem to be settable anywhere in the menuconfig system.>> I have hacked these bits into my local checkout and the fs itself seems to be working pretty well. :)
That definition is sneaky. CONFIG_FS_WRITABLE should be defined in include/nuttx/config.h. It checks the set of file systems that are enabled and if one is writable, it defines CONFIG_FS_WRITABLE.
Yes, CONFIGFS_SMARTFS needs to go in that list too. I will get that one.
This probably worked without issue in the past because most people have some other file system enabled as well.Thanks,