File content rollover #1400
Replies: 3 comments
-
Posted at 2020-04-09 by @gfwilliams Well, using just What I'd suggest is to have one StorageFile (with That way you're actually being super kind to the flash, and it should be reasonably easy to implement? |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-04-13 by msdeibel Here's what I implemented. I'll leave it here for further reference.
|
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-04-14 by @gfwilliams Great - thanks for posting it up! However it looks like you need It's a bit tricky at the moment but StorageFile and the files created by require("Storage").read/write/erase are a bit different. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-04-09 by msdeibel
Hello everyone,
I just started working on a data recorder widget/app for the Bangle and want to limit the file size to keep a maximum of one week worth of data. Which amounts to around 1000 lines in a text file (1 line/10 min).
Now that the storage size is limited and flash mem has a limited number of write cycles I was wondering what would be the best way to handle this.
In a simple solution I would
Since I'm quite new to developing for the Espruino I don't want to mess up the flash within a few days of the widget repeatedly writing to the flash.
Do you have any suggestions how the proposed solution could be improved?
Beta Was this translation helpful? Give feedback.
All reactions