lorol / LITTLEFS

LittleFS library for arduino-esp32
GNU General Public License v2.0
166 stars 68 forks source link

Porting issues #29

Open fanfanlatulipe26 opened 3 years ago

fanfanlatulipe26 commented 3 years ago

Some months ago I started a new development on ESP8266, and following various guide lines I started with LittleFS, the new only now supported file system. Perfect.
I discover now that LittleFS is beeing integrated now in ESP32 core. Perfect. And so I tried to port my project on ESP32, using https://github.com/lorol/LITTLEFS and fall into some frustrating incompatibility / porting issues:
- no dir / openDir support
- change in   .info / totalBytes / usedBytes support
- file name must start with "/"
- no file.fileName() support

I discovered that most of these issues are wellknown.
Of course I found here some links and helps dealing with these issues and we can play with some #ifdef ESP32  but the code become soon obfuscated and cryptic.
I admit that ESP8266 and ESP32 are different platforms, but maybe not that much for a simple user playing with basic filesystem application, at "high level"  far from bit and bytes. 
LittleFS being pusched as the new "standard" I would espect a bit more high level compatibility for basic users.
Or just name this new filesystem for ESP32 with a different name.

On the other hand: congratulation for your work and implication

lorol commented 3 years ago

@fanfanlatulipe26 Thank you for your notes. Please try first SPIFFS compatibility between esp8266 and esp32 and then post here whatever you find is necessary. Indeed these platforms are different. :) feel free to be frustrated as much as you can or write your own whatever you want.

Thank you for understanding. I put the pieces of wrapper together just because it was not available. and I wanted to use LittleFS on my esp32 projects. 99.9% of the "library" is from: https://github.com/espressif/arduino-esp32/tree/master/libraries/SPIFFS and https://github.com/joltwallet/esp_littlefs Also the things you pointed are mostly esp32 platform fs decisions and not much I can do about them. Regards.