Micro:bit v2 examples don't work #7540
Replies: 1 comment
-
Posted at 2021-10-13 by @gfwilliams Hi - how did you write the code to the micro:bit? Were any messages displayed? I just tried here and it works great, regardless of if you paste it into the console on the left-hand side or use the right-hand side and click 'upload'. You'd only expect the HID example to work with button A because the code does:
If you want button B to work as well, add a new line with BTN changed to BTN2:
Posted at 2021-10-13 by coat Hi Gordon. I can't write on the left-hand side. This is my IDE. Posted at 2021-10-13 by Robin Wed 221.10.13 Hi @coat while I don't have any experience with micro:bit there are a few areas that will need some clarification for others to zero in on in your particular case.
So to confirm, as I understand the above, what does work is to cut-n-paste into the R-Hand editor side only?
Are you connected by the USB cable from a port on the PC? (to remove Bluetooth connectivity as a possibility using battery) After the numerous 'Initialising Utils, Initialising Config, . . .' entries, are any other errors reported within the IDE console output? Upper Right of IDE :: Settings >> Console Posted at 2021-10-13 by Robin Wed 221.10.13
What IDE version is displayed? From that image, I see that a recent flash of Espruino was done. Was this flashed using the WebIDE itself, or some other means? While the Chrome browser is mentioned, what is the PC OS the Chrome browser is running on? By chance have you tried the online IDE directly? Posted at 2021-10-14 by coat Hi Robin and thanks for your help.
Yes, I can only write and cut-n-paste into the Right-Hand editor side. On the Left-hand side I can't do anything.
Yes, I'm connected by USB. When I open Espruino IDE, I click on the Connect/Disconnect button on the top left corner and select COM8 mBed serial port.
Yes, I have try yesterday and this morning too. On the left-hand editor side I see the message Unable to retrieve board information. Connection Error? and immediatly below Connected to COM8 (No response from board) but the code is upload correctly.
I can see a Warning advise. Here you can find what console writes after all the initialising:
In Settings >> About I read 0.74.1
I have use just WebIDE
Windows 10 21H1
Oh here works! But why? Posted at 2021-10-14 by @gfwilliams Hi - glad you got it sorted! So just to confirm: you were previously using the 'Chrome app IDE' - this one? https://chrome.google.com/webstore/detail/espruino-web-ide/bleoifhkdalbjfbobjackfdifdneehpo And https://www.espruino.com/ide/ works? The issue was definitely some communication problem - the IDE couldn't send/receive data to the board. If you see the a red error message that's probably a sign something is wrong :) One option is: were you using the IDE with other boards (like ESP8266/ESP32) beforehand? It's possible you changed the baud rate? Posted at 2021-10-18 by coat
Yes, it is.
Yes, it works But, I think I am a very stupid person. I'm very sorry for my mistake and thank you for your support |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2021-10-13 by coat
Hi everyone.
I'm new here and I would learn to program my microbit v2 with espruino.
So, I've connect my board to Espruino Web IDE. So far so good.
But when I try the examples here it seems that they doesn't work.
For example, I have flash on micro:bit this one
but nothing happens.
Then I have try with the following one
But nothing.
Instead, when I have try the BLE keyboard example:
It worked (but only when I press A button, not B).
Where am I wrong?
Thank you for your replies!
Beta Was this translation helpful? Give feedback.
All reactions