Hi - readStorageFile was added because StorageFile (as opposed to just the standard Storage) can be a bit of a pain to read. Since StorageFile is really for logging data (eg a file that keeps on growing) you probably shouldn't use it for settings, so writeStorageFile hasn't been needed so far.
For settings, what you need is likely just to write to Storage, so you could just use the command:
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Hi -
readStorageFile
was added because StorageFile (as opposed to just the standard Storage) can be a bit of a pain to read. Since StorageFile is really for logging data (eg a file that keeps on growing) you probably shouldn't use it for settings, sowriteStorageFile
hasn't been needed so far.For settings, what you need is likely just to write to Storage, so you could just use the command:
We could definitely build that into
interface.js
but it's not super painful to just do that directly in yourinterface.html
code.