You are reading a single comment by @Gordon and its replies. Click here to read the full conversation.
  • Well, using just Storage.write will result in the whole file re-written each time, which is obviously not good.,"a") creates a slightly different file type which allows easy appends, but dropping the first few lines of the file and rewriting will still be bad.

    What I'd suggest is to have one StorageFile (with,"a")) for each day of the week, and then at midnight when you swap over you do,"r").erase() to erase the previous day (7 days ago) before starting afresh.

    That way you're actually being super kind to the flash, and it should be reasonably easy to implement?


Avatar for Gordon @Gordon started