• I tried the FS module and it was working just fine until I ran very busy timers. Then it wasn't able to read/write files anymore. I issued reset(); and tried again without any success, afterward I went to the computer, fsck'ed the SD card with no error and noticed a file that was in fs.readdir(); missing from the computer listing.
    I tried again on the Espruino and the missing file was still appearing, I then tried readdir() without any SD card and it seems to list the same files over and over again ignoring the fact that there is no card.
    I finally was able to recover by using the reset button followed by BTN1 to ignore loading from memory.
    I did a quick check on the code jswrap_fat.c but I'm not at ease with JsVars yet, could it be some sort of static var that reuse the same space in memory?

  • Ahh, thanks for letting me know. I've just created a bug for this: https://github.com/espruino/Espruino/iss­ues/200

    Also posted a reply there - I don't think there's anything required with JsVars, it just needs to be deinitialised in the right place.

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

SD Card (fs module) does not reset when issuing reset();

Posted by Avatar for TiCPU @TiCPU

Actions