have you enable CONFIG_GPT_PARTITION or CONFIG_MBR_PARTITION and call parse_block_partition: https://github.com/apache/nuttx/blob/master/include/nuttx/fs/partition.h#L81 to register partitions as block devices again, so you can mount the different file systems on these new block devices.
Thanks Xiang On Sat, Oct 26, 2024 at 4:51 AM Matteo Golin <matteo.go...@gmail.com> wrote: > I got my hands on a SPI SD card adapter and managed to try out SD/MMC > support for it through NuttX on my Pico. FAT file > systems worked with no problem, and after a little configuring I managed > to get littlefs going as well. > > Now I'm wondering if NuttX has support for multiple partitions on the same > device; I'm hoping I can take a 32GB micro-SD > card and have 16GB be littlefs and 16GB be vfat. I haven't been able to > find any documentation about this though, and > after formatting my SD card to have two vfat partitions I can see that > NuttX is only able to mount the first one. > > I managed briefly to get both partitions on one card by first formatting > the card as littlefs, then using fdisk on my > host computer to add a vfat partition starting halfway through the card, > and then was able to mount both on NuttX as two > distinct file systems. Unfortunately after putting files on them, > rebooting NuttX and trying to remount, the vfat > partition was corrupted. > > Has anyone managed to get multiple partitions to work? How would I go > about it? > > Matteo >