BBC micro:bit Espruino v2.05 quite unstable? #7371
Replies: 1 comment
-
Posted at 2020-04-27 by Andreas_Rozek Ok, I now have some code which crashes the BBC micro:bit within seconds:
Does anybody have any idea why? [EDIT] if the WebBT connection is kept, but the display runs havoc, the IDE's terminal sometimes issues Thanks in advance for your effort! Kind regards, Andreas Rozek Posted at 2020-04-27 by Andreas_Rozek Here are the results of
Posted at 2020-04-27 by Andreas_Rozek Hmmm, I made some progress... Adding an invocation of Is there any chance to work with Espruino on BBC micro:bit? Or does it simply have too little memory? With greetings from Germany, Andreas Rozek Posted at 2020-04-27 by @fanoush if show() is slower than 100ms it probably gets queued up, try to increase the interval Posted at 2020-04-27 by Andreas_Rozek Brilliant idea, unfortunately, there must be more that goes wrong: I order to make it right from the very beginning, I tried to replace The result looked like this:
but did not work at all!!!! (when entered into the Editor area of the IDE and sent to RAM from there - which implies a "reset" before uploading) So, I commented the
Now, I'm completely lost (I do not have any pretokenization or other kind of minification switched on) What makes it even worse: after crashing, I have to push the reset button of my BBC micro:bit in order to let it reappear in the scanned list of BT devices. Sometimes even several resets are necessary before I'm able to upload any JS code again....) I'm now also trying to figure out whether the device itself is broken (which could theoretically be the reason for all these weird problems) Any ideas? Posted at 2020-04-27 by Andreas_Rozek It's extremely weird: if I change the last line of the above code to
the BBC micro:bit does no longer hang up immediately after upload - but it also does not start unless a press RETURN once from within the Terminal area. There must be s.th. going terribly wrong here... Posted at 2020-04-27 by Andreas_Rozek My conclusions so far:
My updated code
runs fine for much longer now than any other variant did. With greetings from Germany, Andreas Rozek Posted at 2020-04-27 by @gfwilliams Hmm, that doesn't sound good. Espruino's pretty limited on the micro:bit (there's only ~6kB of RAM total) - I guess it's possible that something has grown and used up more of the available RAM so there isn't enough stack for it to work reliably? How does 2v04 work? Posted at 2020-04-27 by Andreas_Rozek Hello Gordon, I tried 1.95 (the latest one from the list of available downloads) and that behaved like 2.05. The misbehaviour of Oh, and, meanwhile, my own implementation of "drawLine" crashed as well (on the micro:bit, on Calliope it's still running - but presumably because that was started much later) - I will now try to increase interval length. What also sounds weird is that both devices sometimes suddenly disconnect themselves from the WebBT connection. With greetings from Germany, Andreas Rozek Posted at 2020-04-27 by Andreas_Rozek Increasing interval length does not really help - both boards will eventually hang up. Additionally: when trying to connect after a reset, I also often get the error message "Unable to retrieve board information. Connection Error?" Even if that is followed by "Connected to Web Bluetooth, Espruino MICROBIT (No response from board)" that connection appears to be inoperable. Posted at 2020-04-27 by Andreas_Rozek I meanwhile found the old firmware distributions and tried 1.85 - but apart from a different API (compared to 2.05) I often encounter communication failures (lost characters when uploading) which prevent me from testing... [Update] This is strange as I made my first experiments with Espruino on BBC micro:bit with 1.85 - and I can't remember these problems (my boards are still the same and weren't touched since then). Posted at 2020-04-27 by Andreas_Rozek Oh, what I found in my old notes from 1.85: Espruino on BBC micro:bit hangs quite soon when trying to run the ticker you mentioned in your video about Espruino on the micro:bit... Thus, it seems to have been unstable in those days as well... |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-04-27 by Andreas_Rozek
Hi folks,
after many months of inactivity, I thought I'd give Espruino on BBC micro:bit another try and installed Version v2.05.
It worked in the very beginning (when doing some simple one- or few-liners from the Espruino Web-IDE), but after a few minutes I already got my first disconnect. Such sudden disconnects continued to occur - sometimes I even had to reset the micro:bit before it reappeared in the WebBT list of BT devices - but, initially, I thought, it would be my Mac (macOS is known for its horrible BT support) until I found the first weird pattern on the LED matrix.
Now, I'm quite sure that it's the micro:bit which crashes after a few minutes (usually less than 5) of activity.
Do you have any experiences with that version? As I remember, Espruino ran stable on the micro:bit several months ago (but I can't tell you the version number)
Do you know, which version runs stable?
Thanks in advance for any response!
Kind regards from Germany,
Andreas Rozek
Beta Was this translation helpful? Give feedback.
All reactions