Thank you for your video😉. I have a question, How many times could you write to the flash memory¿ I've read there is a limited write times. Thank you again.
You are very welcome! Please note that I added an example now on Github as well for LittleFS. If you are using an ESP32 library of V2.0.4 or newer then Espressif recommends to use LittleFS instead of SPIFFS. Works exactly the same though :-)
Thank you for bringing this to my attention. For this small config file example there wont be a real difference, but yes: it is better to use LittleFS if your ESP32 library is v2.0.4 or newer. However, luckily the LIttleFS and SPIFFS libraries work exactly the same. I have added a LittleFS example on Github and have updated the video description. Hope it is clear like this.
8 місяців тому
Is this memory safe method? If you get bigger string and write it to the "named.json" next to second file "second.json" will it overwrite the content?
8 місяців тому
SPIFFS garbage collector looks for free space. If there is none it crashes :P If you delete file somtime it leave trash, and garbage collector gets confused. Anyway, if you add formatting case, it will format whole space and repair itself.
There is a bug in the littlefs version spiffs seems okay. I guess you never ran the littlefs version. while(file.available()){ String fileText = file.readString(); } file.close(); return fileText; I am told that that the line String fileText = file.readString(); declares another variable that only exists within the while loop. so value is never passed back to readconfig Thank you for speeding up my learning curve!
Thanks for pointing that out. No idea how that got in there. Think my compiler did not object as fileText was also defined above the while loop. So thank you for pointing this out, I corrected it on GitHub. Cheers!
I love your video's ... Please keep them coming
Thank you very much!
Thank you for your video😉. I have a question, How many times could you write to the flash memory¿ I've read there is a limited write times. Thank you again.
typical is 10,000
@@NathansHVAC LittleFS should be better. It uses wear leveling in some form.
Yes, LittleFS is the better implementation
can you mack ew video - esp8266 with mcp23017
thank u
u teach me
can you do a video on how to save data on an external SPI chip like W25QXX
My apologies, but I am swamped with work and cannot make any videos at the moment
Thank you for the video’s 🙏
You are very welcome! Please note that I added an example now on Github as well for LittleFS. If you are using an ESP32 library of V2.0.4 or newer then Espressif recommends to use LittleFS instead of SPIFFS. Works exactly the same though :-)
Doesn't Espressif recommend using LitleFS now instead of SPIFFS? Thank you for another clear video.
Thank you for bringing this to my attention. For this small config file example there wont be a real difference, but yes: it is better to use LittleFS if your ESP32 library is v2.0.4 or newer. However, luckily the LIttleFS and SPIFFS libraries work exactly the same. I have added a LittleFS example on Github and have updated the video description. Hope it is clear like this.
Is this memory safe method? If you get bigger string and write it to the "named.json" next to second file "second.json" will it overwrite the content?
SPIFFS garbage collector looks for free space. If there is none it crashes :P If you delete file somtime it leave trash, and garbage collector gets confused. Anyway, if you add formatting case, it will format whole space and repair itself.
There is a bug in the littlefs version spiffs seems okay. I guess you never ran the littlefs version.
while(file.available()){
String fileText = file.readString();
}
file.close();
return fileText;
I am told that that the line
String fileText = file.readString(); declares another variable that only exists within the while loop.
so value is never passed back to readconfig
Thank you for speeding up my learning curve!
Thanks for pointing that out. No idea how that got in there. Think my compiler did not object as fileText was also defined above the while loop. So thank you for pointing this out, I corrected it on GitHub. Cheers!
@@mothunderz Really should have said earlier I am enjoying working through so me of your videos. Please don't give up the hard work.
Thank you very much for your encouraging words 😀 🙏
Can we set up a web server and store the data in the sd card connected to esp32 ?
Yes, that should be possible, just combine this code with that of the web server:
ua-cam.com/video/DEFPSfLRObk/v-deo.html
Good luck with your project!
@@mothunderz thank you!
Very good your videos, could implement the triggering of digital inputs and button triggers via websocket with a web interface
Yes, will do in my next video - stay tuned
What about making an AI desk robot like Anki Vector!
Cool idea, I have not looked into that yet...
@mothunderz esp32 has everything. we just need a display module a few motors it'll be done.. You should try it!