However, the documentation implies that Storage.read/write are different and not compatible with StorageFile.read/write, so the example read code using StorageFile is inconsistent with using Storage.write. From my reading of the Puck code, the callback of Puck.write doesn't take any arguments, so I'm guessing the following WONT work:
This is rather confusing. It's a shame I can't see a way to try this with the emulator. I think I'll have to be patient and wait for the actual Bangle to turn up.
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.
Thanks. There is quite a bit to learn! Writing then seems straightforward:
However, the documentation implies that Storage.read/write are different and not compatible with StorageFile.read/write, so the example read code using StorageFile is inconsistent with using Storage.write. From my reading of the Puck code, the callback of Puck.write doesn't take any arguments, so I'm guessing the following WONT work:
This is rather confusing. It's a shame I can't see a way to try this with the emulator. I think I'll have to be patient and wait for the actual Bangle to turn up.