Open jamesben6688 opened 4 years ago
There could be one or more things wrong. Try printing out the value of fd returned when the call fails and checking the error code list in github here https://github.com/pellepl/spiffs/blob/master/src/spiffs.h. This might give you a clue for further investigation.
When I try to use your demo code in
https://github.com/pellepl/spiffs/wiki/Using-spiffs
like below:spiffs_file fd = SPIFFS_open(FS, "my_file", SPIFFS_CREAT | SPIFFS_TRUNC | SPIFFS_RDWR, 0);
I always get a negative fd. Is there anything else should be done to make this correct?