ESP32-C3 Smartfs Read-Only issue

esp32c3_read: esp32c3_read(0x3fc8588c, 0x1ff000, 5, 0x3fc86824)
esp32c3_read: esp32c3_read()=5
smart_scan: Scan sector 1021
esp32c3_read: esp32c3_read(0x3fc8588c, 0x1ff400, 5, 0x3fc86824)
esp32c3_read: esp32c3_read()=5
smart_scan: Scan sector 1022
esp32c3_read: esp32c3_read(0x3fc8588c, 0x1ff800, 5, 0x3fc86824)
esp32c3_read: esp32c3_read()=5
smart_scan: Scan sector 1023
esp32c3_read: esp32c3_read(0x3fc8588c, 0x1ffc00, 5, 0x3fc86824)
esp32c3_read: esp32c3_read()=5
smart_readsector: Entry
esp32c3_read: esp32c3_read(0x3fc8588c, 0x100000, 5, 0x3fc867e8)
esp32c3_read: esp32c3_read()=5
esp32c3_read: esp32c3_read(0x3fc8588c, 0x100021, 8, 0x3fc8682c)
esp32c3_read: esp32c3_read()=8
smart_readsector: Entry
esp32c3_read: esp32c3_read(0x3fc8588c, 0x100000, 5, 0x3fc867e8)
esp32c3_read: esp32c3_read()=5
esp32c3_read: esp32c3_read(0x3fc8588c, 0x100029, 128, 0x3fc87420)
esp32c3_read: esp32c3_read()=128
smart_scan: SMART Scan
smart_scan: Erase size: 4096
smart_scan: Erase count: 256
smart_scan: Sect/block: 4
smart_scan: MTD Blk/Sect: 4

NuttShell (NSH) NuttX-10.0.1
nsh> ?
help usage: help [-v] []

. cp exit mb mw source usleep
[ cmp false mkdir ps test xd
? dirname free mkrd pwd time
basename dd help mksmartfs rm true
break df hexdump mh rmdir uname
cat echo kill mount set umount
cd exec ls mv sleep unset

Builtin Apps:
fstest sh nsh flash_eraseall
nsh> mksmartfs /dev/smart0
bchdev_register: blkdev="/dev/smart0" chardev="/dev/tmpc000001" readonly=T
find_blockdriver: pathname="/dev/smart0"
smart_open: Entry
smart_geometry: Entry
smart_geometry: available: true mediachanged: false writeenabled: true
smart_geometry: nsectors: 1024 sectorsize: 1024
smart_ioctl: Entry
smart_getformat: Entry
smart_close: Entry
nsh> mount -t smartfs /dev/smart0 /mnt
find_blockdriver: pathname="/dev/smart0"
smart_open: Entry
smart_geometry: Entry
smart_geometry: available: true mediachanged: false writeenabled: true
smart_geometry: nsectors: 1024 sectorsize: 1024
smart_ioctl: Entry
smart_getformat: Entry
smartfs_mount: SMARTFS:
smartfs_mount: Sector size: 1024
smartfs_mount: Bytes/sector 1019
smartfs_mount: Num sectors: 1024
smartfs_mount: Free sectors: 1015
smartfs_mount: Max filename: 16
smartfs_mount: RootDirSector: 3
nsh> cd /mnt
nsh> ls -l
/mnt:
smart_ioctl: Entry
smart_readsector: Entry
smart_readsector: ERROR: Logical sector 3 not allocated
nsh>

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s