what is "on-chip flash" for? Is it for firmware only?
Right now, yes - at some point I'll enable the option to write files to internal flash though (which is faster)
there are modules Flash, Storage, StorageFile, fs. all can read/write... to which flash?
It depends. Storage -> external (at the moment), Flash -> anywhere, fs -> not enabled on Bangle.js
does block address space include both on-chip flash and external flash, kind of concatenates 1MB and 8MB, or they are separate?
They're separate
I need to write text or binary files, they may be long size. Should I use StorageFile.write()?
what type of filesystem is it? FAT, VFAT?
It's a custom filesystem designed to allow files to be written in one contiguous chunk (if needed). For text files that are being appended to, use StorageFile.write() - but for binary or if you know the file size up front you just want to write direct with Storage.
I could not find how to get metadata of a file - size, create time, change time. I hope at least size should be somewhere.
There is no metadata apart from size. storage.read("file").length is fine for size
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.
Right now, yes - at some point I'll enable the option to write files to internal flash though (which is faster)
It depends. Storage -> external (at the moment), Flash -> anywhere, fs -> not enabled on Bangle.js
They're separate
It's a custom filesystem designed to allow files to be written in one contiguous chunk (if needed). For text files that are being appended to, use
StorageFile.write()
- but for binary or if you know the file size up front you just want to write direct with Storage.There is no metadata apart from size.
storage.read("file").length
is fine for sizeNope