Comments on: ESP32: Write Data to a File (LittleFS) – Arduino IDE https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/ Learn ESP8266, ESP32, Arduino, and Raspberry Pi Thu, 29 May 2025 16:17:21 +0000 hourly 1 https://wordpress.org/?v=6.8.2 By: rick https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/#comment-1052169 Thu, 29 May 2025 16:17:21 +0000 https://randomnerdtutorials.com/?p=133987#comment-1052169 Just FYI. I like to see what it’s doing…..

Serial.printf(“Total Bytes: %u\n”, LittleFS.totalBytes());
Serial.printf(“Used Bytes: %u\n”, LittleFS.usedBytes());
Serial.printf(“Free Bytes: %u\n”, LittleFS.totalBytes() – LittleFS.usedBytes());

]]>
By: Patrick Gschwend https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/#comment-952335 Thu, 29 Aug 2024 02:25:11 +0000 https://randomnerdtutorials.com/?p=133987#comment-952335 Hi Sara,

Thanks for this great tutorial! Unfortunately, I’m still having trouble getting it to work. Do you (or anyone else) have any idea why the mounting might not be working?

I’ve tried almost everything I can think of, but I’m out of ideas at this point. I always end up in an error message “LittleFS Mount Failed”. I’m using a simple Arduino Nano ESP32, connected to my laptop with a regular USB-C cable. I usualle program in VS code with PlatformIO, but I tested everything also with ArduinoIDE.

Thanks in advance for any help you can provide. It would help me a lot.
Regards, Patrick

]]>
By: Sara Santos https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/#comment-913135 Mon, 06 May 2024 11:15:34 +0000 https://randomnerdtutorials.com/?p=133987#comment-913135 In reply to Larry Dalton.

It’s included by default.
No need to download.
Just make sure you have an ESP32 selected in Tools > Board.
Regards,
Sara

]]>
By: Larry Dalton https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/#comment-911397 Tue, 30 Apr 2024 20:47:34 +0000 https://randomnerdtutorials.com/?p=133987#comment-911397 Where can I download the LittleFS library?

]]>
By: Udo Dillschneider https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/#comment-885280 Sun, 21 Jan 2024 00:06:21 +0000 https://randomnerdtutorials.com/?p=133987#comment-885280 how can i save the LittleFS file to the Computer or USB-Stick? Regards, Udo]]> Hello,
Sorry für my english 😕 how can i save the LittleFS file to the Computer or USB-Stick?
Regards,
Udo

]]>
By: tahan prahara https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/#comment-881765 Wed, 03 Jan 2024 16:33:10 +0000 https://randomnerdtutorials.com/?p=133987#comment-881765 can LittleFS be used on Arduino IDE 2.2.1 ? Thank You

]]>
By: Andrew https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/#comment-872275 Thu, 16 Nov 2023 00:47:34 +0000 https://randomnerdtutorials.com/?p=133987#comment-872275 Hi Sara,
Thank you for the tutorial.
I use Arduino IDE 2.2.1 with ESP32 S3P2 and so far I do not see a predefined partition scheme that incorporates the littlefs SubType for the 16MB flash size, only for the 32MB one which actually has spiffs defined in it, as I found when I inspected it.
To overcome this I created a custom partition table in a csv file called “partition.csv” and placed it into the root directory of the project. The problem I am facing is the compiler fails to recognise the littlefs SubType and throws that error message referring to the line number wher that is defined. The documentation here https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/partition-tables.html clearly shows that the this SubType exists so I expect it to compile but it does not.
Any ideas why that happens, and can we use the spiffs partition as littlefs partition without a drawback?
Regards,
Andrew

]]>
By: Sara Santos https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/#comment-872091 Wed, 15 Nov 2023 04:17:52 +0000 https://randomnerdtutorials.com/?p=133987#comment-872091 In reply to Jak.

Hi.
I think this should work regardless of the IDE.
What error do you get?
Regards,
Sara

]]>
By: Jak https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/#comment-871953 Tue, 14 Nov 2023 08:48:04 +0000 https://randomnerdtutorials.com/?p=133987#comment-871953 So does this work yet on Arduino 2.x.x ? I am guessing not as it still doesn’t compile for me.

]]>
By: Sara Santos https://randomnerdtutorials.com/esp32-write-data-littlefs-arduino/#comment-865378 Fri, 13 Oct 2023 02:45:40 +0000 https://randomnerdtutorials.com/?p=133987#comment-865378 In reply to Dinesh Vyas.

Hi.
For the ESP8266, you can follow the next tutorial instead: https://randomnerdtutorials.com/esp8266-nodemcu-write-data-littlefs-arduino/
Regards,
Sara

]]>