You are reading a single comment by @fanoush and its replies. Click here to read the full conversation.
  • Oh after some time it recovered. I left it alone and after few hours I tried to connect and it still failed and serial console was dead but suddenly - in nrfconnect I tried directly write RX characteristics and it suddenly echoed the data into TX. I sent string E.reboot() and after some time I checked serial console and saw

    Uncaught SyntaxError: Got EOF expected '}'
     at line 2 col 6493
    ...?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255]]
    

    So either it rebooted or not and printed this. Then I tried

    s=require("Storage");s.read(".bootcde")
    ="Modules.addCached" ... "\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xF­F\xFF\xFF\xFF\xFF\xFF\xFF\xFF"
    > console.log(btoa(s.read(".bootcde")))
    

    and copied the base64 string to computer and decoded back into binary and there is beginning of the program and the rest of file is 0xff. first 0x400 bytes in sensible code and rest until 0x1b66 is all 0xff.

    I will try to copy this to opened DS-D6 I can recover and see what the file does after reboot. Maybe it takes time for the interpreter to handle such long line of 0xff bytes , i.e no end of line and strange 0xff 'tokens'?

    Anyway, I erased storage in HX03W and it is fine now.

    EDIT: when looking at the partial code it even looks like it is not the latest version, I think I had the watchdog setup code on the beginning that later caused this mishap so this looks like flash page of some older code. And BTW when webide uploaded the code, I think the progress bar went to end normally so there was not any feedback that anything went wrong. It happily progressed while the watch was already rebooted. I'm not sure but think it was over serial so that may explain since there is no echo(?) so data is just pushed without any check(?).

About

Avatar for fanoush @fanoush started