Unable to use firmware above 1v95 on Espruino Wifi

Posted on
  • I just received my first Espruino Wifi which originally had 1v88 firmware. The device worked fine, I was able to connect to it and upload commands using the Espruino IDE on my Macbook pro without issue.

    I tried updating to the latest (as of this post 1v99) and noticed extremely odd behaviour. My system would freeze up every five seconds for a period of 1-2 seconds, repeatedly unless the device was disconnected from USB. Additionally the Espruino IDE could no longer see the device on the connect screen.

    I then tried downgrading the firmware to 1v98. I successfully downgraded, and no longer had the freezing issue. I was able to connect to the device in the IDE, but then when connected the terminal was flooded with the repeating messages over and over making it unusable.

    Uncaught undefined
    Execution Interrupted
    Uncaught undefined
    Execution Interrupted
    Uncaught undefined
    Execution Interrupted
    ...
    

    I tried clearing the device to ensure no programs were running on it using the steps outlined in the troubleshooting docs in the section Espruino stopped working after I typed save() which unfortunately didn't help. I then tried downgrading firmware to 1v97, and 1v96 each of which did what 1v99 and 1v98 did respectively. I finally tried 1v95 and that worked as expected without issue.

    Does anyone have any insight into what's happening here? I couldn't find anything any forum post with a similar issue.

  • ...weird... I just had recently weird behavior in my Web IDE on OSX... but shutting down and restarting helped and I could re-flash the firmware. You obviously found the sweet spot of how long to hold the button when powering Espruino on in in order to get it into the re-flash mode (alternate pulsing of LEDs). Watch the progress bars... if they do not move smothly or too slow or are stuttering, something if of the tracks.USB cables are not all at their best and some iffy connection can cause weird effect. Check wires, cables... and just restart.

  • That is strange - Uncaught undefined, Execution Interrupted sort of implies that there's some code running on there for some reason.

    Do you ever see the:

     ____                 _
    |  __|___ ___ ___ _ _|_|___ ___
    |  __|_ -| . |  _| | | |   | . |
    |____|___|  _|_| |___|_|_|_|___|
             |_| espruino.com
     1v... (c) 2018 G.Williams
    

    logo? Does it say the correct version number on it?

    The WiFi really shouldn't be able to cause your Mac to freeze though, I'd imagine that would be due to USB communications issues. Can you try with another Micro USB cable? It's truly amazing how many of them have data wires that are broken or which break.

    Maybe after a new cable, make sure you restart the IDE as @allObjects says, then try reflashing with 1v99 and check that it does get all the way through successfully. On Espruino WiFi the act of updating the firmware blows away any saved code, so hopefully when it succeeds the device should be 'as new'.

  • Thanks for the suggestions. I saw the logo screen with correct version displayed on 1v98 before the terminal was flooded with those messages. I wasn't able to connect on 1v99.

    I will try again with a new cable, hopefully that will solve the problem.

  • @Gordon sadly nothing has worked so far. First I restarted my machine and used a brand new micro-usb cable with no success. Then I tried flashing the device using stm32loader.py and received the exact same behaviour. 1v96-1v99 do not work in different ways, but 1v95 still works perfectly.

    I then tried flashing from a co-workers Macbook pro using the IDE and had the exact same result. Really strange behaviour indeed.

  • @Gordon, could it be that the ESP8266 module is somewhat 'shot' for 1V95+ on this Espruino-Wifi? ...or is updating the Espruino-Wifi also updating the ESP8166 module? ...I guess not.

    I did not come across any 'how to update the ESP866 module firmware on Espruino-Wifi...

  • @allObjects the ESP8266 shouldn't really come into it. When the Espruino WiFi first starts the ESP8266 is powered down so it's acting just like a faster Pico.

    @tkamen you mentioned you'd just got the Espruino WiFi - so it's just a bare board right now and it's not connected to anything else that could be causing problems?

    Does the WiFi with the 1v99 firmware work on your coworker's computer, or does it do the same thing on that as well? I'd be happy to replace it with another one, but I'd just be a bit worried that a new one would behave in the same way as it's hard to see how any hardware issues could be causing this.

  • @Gordon Correct, it's just the bare board without anything connected to it (other than the usb cable of course). When I connected it to my coworkers computer it did the exact same thing. I tried it on my wife's macbook air last night and also did the same thing. Thus far I have also tried four different micro-usb cables. The only thing I can think of is to try it on a Windows or Linux machine as the only common thing so far has been OSX. I'll try on a Windows machine today and will report back.

    If you're willing to send a replacement unit I'd gladly accept, but I understand this is a very strange occurrence and one that you haven't seen before so the possibility of user error exists. Though I'm pretty sure i'm following all the steps correctly ;)

  • It'd be great if you could give it a try on Windows (check out the Quick Start guide as it's possible you'll need to install drivers). I just tried 1v99 on Mac OS though and it works fine for me, so something does seem broken with yours :)

    I'll drop you an email and figure out what we can do about swapping it - but a test on Windows would still be interesting.

  • I do this in OSX and everything has been working fine since:

    1) In the IDE goto communications/connect over TCP address and put this there: "127.0.0.1:12345"

    2) In the terminal type "ls /dev/cu*" and copy the device "cu.usbmodemXXxxx", then type this:

    nc -k -l 12345 > /dev/cu.usbmodemXXxxx < /dev/cu.usbmodemXXxxx
    

    3) Select TCP port 127.0.0.1:12345 when Connect asks.

    Sometimes, after a reset or disconnect the name of the device changes, if you can no longer connect this way, hit ctrl-c to cancel nc, and repeat from 2).

    It has worked wonders for me in my Macs.

  • Thanks for posting up - wow, that's a big workaround!

    So just connecting via /dev/cu.. in the IDE options doesn't work for you?

  • So just connecting via /dev/cu.. in the IDE options doesn't work for you?

    Nope, if I select the device in the web ide it hangs there "connecting" forever, but with nc it works always, flawlessly.

    You could put that trick in the docs!

  • BTW, the online web IDE, not the chrome app, how does it do to connect to a normal (Original/Pico) Espruino?

  • The online (non-app) Web IDE can't connect via USB yet (unless you use https://github.com/espruino/EspruinoHost which is pretty beta). However, Web Serial support will hopefully land in Chrome in the next 6 months or so which should make it 'just work'.

  • Given their EOL plans for chrome apps for Windows, Linux and Mac OS, that would be a good thing indeed.

    Thanks!

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

Unable to use firmware above 1v95 on Espruino Wifi

Posted by Avatar for tkamen @tkamen

Actions