require("Flash").getFree() is the memory in internal flash, not used by Storage
require("Storage").getFree() is the memory available in Storage, in Bangle.js this is external storage
Do I actually have 8 MByte available for access through the 'Storage' module ?
Yes.
What then is the length of 483328 for the 'Flash' module ?
That's internal flash that isn't used by code
All these questions because I need 'a lot' of space for storing a Far-East unicode font...
Eep. Obviously I don't know quite what you have planned, but the approach I'm taking with text messages on Bangle.js is to render them to a bitmap on a bigger computer, and send the bitmap over rather than just the text.
You can now add images in-line in text that you draw with drawstring (just add a 0 character then the raw image data in Espruino's image format) so it may be quite easy to implement.
The very newest firmware actually has two blocks of memory used for storage - internal and external - so it is possible to use that ~500k of internal flash as well.
However I feel like if the difference between 8MB and 8.5MB is a killer for you, it may be worth looking at different approaches.
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.
Yes, it is a bit confusing, but basically:
flash_length
is how much internal flash you haverequire("Flash").getFree()
is the memory in internal flash, not used by Storagerequire("Storage").getFree()
is the memory available in Storage, in Bangle.js this is external storageYes.
That's internal flash that isn't used by code
Eep. Obviously I don't know quite what you have planned, but the approach I'm taking with text messages on Bangle.js is to render them to a bitmap on a bigger computer, and send the bitmap over rather than just the text.
You can now add images in-line in text that you draw with drawstring (just add a 0 character then the raw image data in Espruino's image format) so it may be quite easy to implement.
The very newest firmware actually has two blocks of memory used for storage - internal and external - so it is possible to use that ~500k of internal flash as well.
However I feel like if the difference between 8MB and 8.5MB is a killer for you, it may be worth looking at different approaches.