• Hi Gordon

    Can you explain the difference between E.openFile and storage.open? In existing apps, I see they use "storage.open" more often than E.openFile, but it isn't clear to me when I have to use which function.
    https://www.espruino.com/Reference#t_l_E_openFile
    https://www.espruino.com/Reference#l_Storage_open

    • E­.openFile is for FAT filesystems (eg SD card) - it's not something that's even supported on Bangle.js
    • Storage.open uses the Bangle.js flash storage, so that's that one I'd suggest. But even then, if you're just writing simple files (and not appending/streaming data) I'd suggest just using Storage.write
  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

Difference between E.openFile and storage.open?

Posted by Avatar for skelesp @skelesp

Actions