You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Unexpected error -10004 when creating&deleting files #266
I build a testbench to evaluate spiffs and other flash filesystems for use with a large (64MB) NOR flash.
After a promising start, I now have a testcase that reliably crashes with code -10004 (some changes also resulted in code -10011). Wait for it to run until the end - it gets slow as the flash fills up. The crash is in the last loop.
In spiffs_config.h, did you make sure these types are big enough:
// Block index type. Make sure the size of this type can hold
// the highest number of all blocks - i.e. spiffs_file_system_size / log_block_size
typedef u16_t spiffs_block_ix;
// Page index type. Make sure the size of this type can hold
// the highest page number of all pages - i.e. spiffs_file_system_size / log_page_size
typedef u16_t spiffs_page_ix;
// Object id type - most significant bit is reserved for index flag. Make sure the
// size of this type can hold the highest object id on a full system,
// i.e. 2 + (spiffs_file_system_size / (2*log_page_size))*2
typedef u16_t spiffs_obj_id;
// Object span index type. Make sure the size of this type can
// hold the largest possible span index on the system -
// i.e. (spiffs_file_system_size / log_page_size) - 1
typedef u16_t spiffs_span_ix;
Activity
pellepl commentedon Jul 1, 2020
In spiffs_config.h, did you make sure these types are big enough:
MightyPork commentedon Jul 3, 2020
You are correct, that was indeed the case.
I think
SPIFFS_mount()could easily catch this - compare the values fromspiffs_configwith(1ULL << sizeof(spiffs_whatever_ix) * 8ULL) - 1ULL