• I have an old BangleJS 1 that I am trying to use again. I installed the latest firmware 2v15 and tried to installed the default apps.

    It is happy having the time set, refreshing the installed app list (none) but it seem to be timing out installing the first default app (bootloader).

    From the browser console...

    <BLE> Device Name:       Bangle.js 7c0f
    puck.js:410 <BLE> Device ID:         VPRhxE6xGa1cqWh73qotbA==
    puck.js:410 <BLE> Connected
    comms.js:204 <COMMS> Ctrl-C gave ""
    comms.js:250 <COMMS> getDeviceInfo {currentTime: 1660693185000, version: '2v14', id: 'BANGLEJS', apps: Array(0)}
    ui.js:86 <TOAST>[warning] You're using an old Bangle.js firmware (2v14) and 2v15 is available (<a href="http://www.espruino.com/ChangeLog"­ target="_blank">see changes</a>). You can update <a href="https://www.espruino.com/Bangle.js­#firmware-updates" target="_blank">with the instructions here</a>
    index.js:828 Current device time is Wed Aug 17 2022 09:39:45 GMT+1000 (Australian Eastern Standard Time)
    index.js:834 SETTINGS.settime=true and >2 seconds out - updating time
    comms.js:146 <COMMS> uploadApp: .boot0, .bootcde, bootupdate.js, boot.info
    comms.js:41 <COMMS> reset
    comms.js:43 <COMMS> reset: got "\u001b[?7l\r\n ____                 _ \r\n|  __|___ ___ ___ _ _|_|___ ___ \r\n|  __|_ -| . |  _| | | |   | . |\r\n|____|___|  _|_| |___|_|_|_|___|\r\n         |_| espruino.com\r\n 2v14 (c) 2021 G.Williams\r\n\r\n>"
    comms.js:49 <COMMS> reset: rebooted - sending commands to clear out any boot code
    comms.js:52 <COMMS> reset: complete.
    comms.js:18 <COMMS> showMessage "Uploading\nboot..."
    comms.js:29 <COMMS> getProgressCmd START
    comms.js:171 <COMMS> Upload .boot0 => "// Initially this runs and rewrites itself\neval(require('Storage').read('bo­otupdate.js'));\n"
    comms.js:29 <COMMS> getProgressCmd 1%
    comms.js:80 <COMMS> Response:  ""
    comms.js:93 <COMMS> Blank line received - ignoring...
    comms.js:80 <COMMS> Response:  undefined
    comms.js:97 <COMMS> No response received - ignoring...
    comms.js:80 <COMMS> Response:  undefined
    comms.js:97 <COMMS> No response received - ignoring...
    comms.js:80 <COMMS> Response:  undefined
    comms.js:97 <COMMS> No response received - ignoring...
    comms.js:80 <COMMS> Response:  undefined
    comms.js:97 <COMMS> No response received - ignoring...
    comms.js:80 <COMMS> Response:  undefined
    comms.js:97 <COMMS> No response received - ignoring...
    comms.js:80 <COMMS> Response:  undefined
    

    ... for a while then ...

    <COMMS> No response received - ignoring...
    comms.js:80 <COMMS> Response:  undefined
    comms.js:97 <COMMS> No response received - ignoring...
    comms.js:80 <COMMS> Response:  "FW addr 0x00000000 fail\r"
    banglejs.com/:1 Uncaught (in promise) Unexpected response "FW addr 0x00000000 fail"
    

    I have also tried ti with 2v10 and 2v14 (same problem installing the apps).

    Any ideas?

  • What happens if you go to the IDE at https://www.espruino.com/ide/# and connect (top left)

    Then on the left-hand side, paste in:

    • require("Storage").eraseAll() - could take a while
    • require("Storage").write("hello","World"­)
    • require("Storage").read("hello") - should write ="World" on the console

    The FW addr 0x00000000 fail message is an internal error that comes up when the Bangle is unable to write anything into the external flash memory.

    Was the Bangle working when you put it away? For this kind of thing to happen I'd assume there could be some kind of damage to the internals (like water damage?)

    You could always try totally flattening the battery (to reset everything) then charging it up fully, turning it on and trying again

  • I tried the IDE commands...

    >require("Storage").eraseAll()
    =undefined
    >require("Storage").write("hello","World­")
    FW addr 0x00000000 fail
    Status 255
    FW addr 0x00000020 fail
    Status 255
    Uncaught InternalError: Timeout on jshFlashWrite
     at line 1 col 41
    require("Storage").write("hello","World"­)
                                            ^
    >require("Storage").read("hello")
    =undefined
    > 
    

    It was working when it when away, I'll try totally flattening the battery.

    Thanks for the help.

  • Could it be that you once flashed firmware for other board like PUCKJS or MDBT42Q and then reflashed it with BANGLEJS again? pin 21 which is normally a reset pin is used as flash CS pin https://github.com/espruino/Espruino/blo­b/master/boards/BANGLEJS.py#L142 and most other builds would reconfigure it back as reset pin which would make flash CS pin not working. You can verify by running peek32(0x10001200) If it prints 21 then it is this issue and can be fixed.

  • Thanks @fanoush! That's well worth testing @user148332

  • @fanoush, the peek did print 21 however flashing it with PUCKJS or MDBET42Q didn't help.
    Do you know where it is being reconfigured back as a reset pin? (I am happy to hack and build my own binary to figure it out).

  • however flashing it with PUCKJS or MDBET42Q didn't help.

    No, of course not, flashing with PUCKJS or MDBT42Q can only break it. But it is good the hardware is probably OK if you see 21.
    It can be fixed by copy pasting following code to left side of WebIDE (use ctrl+v to paste)

    setTimeout(function() { NRF.restart(function(){
    poke32(0x4001e504,2);while(!peek32(0x400­1e400)); // enable flash erase
    poke32(0x4001e514,1);while(!peek32(0x400­1e400)); // erase whole uicr
    poke32(0x4001e504,1);while(!peek32(0x400­1e400)); // enable flash writing
    poke32(0x10001014,0x7A000);while(!peek32­(0x4001e400)); // set bootloader
    poke32(0x10001018,0x7E000);while(!peek32­(0x4001e400)); // set mbr settings
    poke32(0x1000120c,0xfffffffe);while(!pee­k32(0x4001e400)); // NFC pins as GPIO
    poke32(0x4001e504, 0);while(!peek32(0x4001e400)); // disable flash writing
    }) }, 2000);NRF.disconnect();
    

    then wait few seconds, reconnect and try the peek32(0x10001200).toString(16) again, if it prints all FFs then it is fixed, reboot the watch (via buttons or E.reboot()) and hopefully flash storage will start working again.

  • That worked, thanks for the help.

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

BangleJS 1, cannot install default apps after firmware update.

Posted by Avatar for user148332 @user148332

Actions