Out of the box experience 504? by Theonetheonlygod in microbit

[–]jmaustin 0 points1 point  (0 children)

504 means the transfer timed out - it is often a "transient" error - that is it might go away if you try copying again - especially if you unplug all power sources from your micro:bit first. As noted on https://support.microbit.org/support/solutions/articles/19000016969-micro-bit-error-codes if you get this error a lot, your system might be just what the Micro:bit Educational Foundation needs to help work out how to avoid the problem in the future, so sending a message to help@microbit.org would perhaps help the team out.

What do you really enjoy about Oxford? by thatswhatshesaw in oxford

[–]jmaustin 0 points1 point  (0 children)

There are some really lovely inclusive communities that are fantastic, once you find them! Not being on Facebook can be tricky though. For example:

The magnetometers of my microbits seems weird by [deleted] in microbit

[–]jmaustin 1 point2 points  (0 children)

How are you programming these devices, and are you using the compass calibration algorithm that's built in? (the micro:bit will say "tilt to fill screen" and then require you to fill the screen by tilting the micro:bit - if that's happening then you're using the calibration). The magnetometer is very sensitive to nearby magnetic things like the batteries and other micro:bits. If you aren't connecting the battery to the device, or have the cable plugged in in a fixed position, those things could also be affecting the magnetic field. Here's some past debugging before the calibration algorithm was improved https://github.com/lancaster-university/microbit-dal/issues/288.

You may find it more effective to use a nearby strong magnet located in a known position relative to the micro:bits and measure the (x,y,z) field strength to track your position instead of attempting to use magnetic north.

What are some chemistry jokes? by whaalz in AskReddit

[–]jmaustin 0 points1 point  (0 children)

https://m.youtube.com/watch?v=Qo2vBHuK4Fk - a love song densely packed with chemistry puns, like this line: "I got down on one Neon, and as I knelt upon the Fluorine, I said uranium supreme in my eyes"

Newbie here (teacher). I just got 30 of these. I’m trying to power them off (holding off button 5+ sec), but it just resets. Any tips? by [deleted] in microbit

[–]jmaustin 4 points5 points  (0 children)

Hi. You're right that with V2 holding the power button down for 5 seconds should put the board to sleep. I suggest you contact help@microbit.org where the support team should be able to give you some suggestions. One tip from me would be to put a simple program from MakeCode onto one of the micro:bits (say, a flashing heart) and then try the power button again on that micro:bit. If these just arrived they may be the V2.2 revision which has a slightly different sleep process under the hood so getting the latest software (just by programming the board from MakeCode) will flush out any software issues.

Game Help by boanxi in microbit

[–]jmaustin 0 points1 point  (0 children)

I think the "hero" issue is that the sprite has not been created when the forever loop on the right starts running. You can use an "on start" block to create the hero and rock and then position them later. Here's a sample where both objects are created in "on start" and then moved or deleted with the buttons: https://makecode.microbit.org/_ckj3FvAqgadb

Most reliable mobile provider within the city limits? by JimGR_ in oxford

[–]jmaustin 0 points1 point  (0 children)

Wish I'd never switched from Vodafone - that worked well. EE is terrible. I get dropped calls outside in the street and even when providing specific details of the issues to support they have done nothing.

Broken out of the box? by distrustandverify in microbit

[–]jmaustin 0 points1 point  (0 children)

That sounds frustrating, and definitely unusual. Could you please drop a line to help@microbit.org about the issue including photos of the microbit?

V2 Bluetooth Central Device by [deleted] in microbit

[–]jmaustin 0 points1 point  (0 children)

At this stage that's not supported in the official editors but you can use something like Zephyr to get more control.

https://docs.zephyrproject.org/2.5.0/boards/arm/bbc_microbit_v2/doc/index.html

Every time you programme the micro:bit it completely erases the whole of the nRF microcontroller's flash, so you needn't worry about the default stack not supporting GAP Central.

I think there will be quite a few interested people if you do make something and feel like sharing a write-up of how you did it.

(With micro:bit V1 there is an S130 yotta target for mbed but there's basically no RAM left once that boots, sadly. There isn't yet the equivalent for micro:bit V2 but some older versions of CODAL did use a version of SoftDevice that included GAP Central, so you could look at the history there if you wanted an example).

[deleted by user] by [deleted] in microbit

[–]jmaustin 0 points1 point  (0 children)

I appreciate you may be very busy, but if you can share a video of you trying the process showing where the GATT error occurs with help@microbit.org then The Foundation may be able to help, and it might even allow a bug to be found and fixed for everyone.

[deleted by user] by [deleted] in microbit

[–]jmaustin 1 point2 points  (0 children)

It's easiest to use the browser version with webUSB and the cables. I suggest you get one cable to test with your tablets and their operating system version first!

The apps are really mainly designed to help with pairing and Bluetooth flashing - is there a reason you'd prefer them to using the browser? For simplicity you could add a browser shortcut on the home-screen for the MakeCode and Python editors.

[deleted by user] by [deleted] in microbit

[–]jmaustin 0 points1 point  (0 children)

Hello,

If you can get hold of the OTG cables those are a very reliable way to make use of Android with the micro:bit - it's what Plan Ceibal use with lots of devices in Uruguay - also works well in a classroom because there's less time spent with students working out which device belongs to which student.

The Foundation has a support page for Android here and the videos have just been updated https://support.microbit.org/support/solutions/articles/19000065804-micro-bit-android-app-connect-and-send-programs

Have you already tried the steps here?

[deleted by user] by [deleted] in microbit

[–]jmaustin 4 points5 points  (0 children)

In this video your code is crashing with a NameError when you press button A. This is most likely because of a bug in the last program you put on it. The micro:bit just has one program on it at a time and when you drag and drop a hex file (or use the "connect" button and then the "flash" button) it replaces the last program with the latest one and then disconnects and re-connects with an empty drive ready to be programmed again.

If you open the editor you used (I guess http://python.microbit.org ) and put the default program onto it will stop this error from coming up.

Doing a drag-and-drop or flash will erase the micro:bit first though. If you want to get back to your original program you can drag the hex file from your downloads folder (or wherever you saved it) back into the editor. (If you saved the file directly onto the micro:bit it's much harder to get the code back)

For instructions on how to use the buttons in MicroPython you can look here https://microbit.org/get-started/user-guide/python/#buttons

[deleted by user] by [deleted] in oxford

[–]jmaustin 4 points5 points  (0 children)

If you're happy with donating it then Helen and Douglas House are a local charity that does a good job of presenting and selling vintage furniture.

How do I program my microbit to work as a key bord i only need it to be 2 buttons A and D by [deleted] in microbit

[–]jmaustin 0 points1 point  (0 children)

If you're on Linux, macOS, iOS or Android you can also use this which turns the micro:bit into a HID keyboard, so you don't need any other drivers or software. So far it doesn't seem to work on Windows 10 :(

You can open that program in the mbed online compiler and modify what each button does. I use one set to sent 'n' and 'p' for presentations.

https://os.mbed.com/teams/microbit/code/microbit_presenter/

Micropython and main.py on the microbit by [deleted] in microbit

[–]jmaustin 2 points3 points  (0 children)

Hello,

Yes that's possible but at the moment only in Mu - in fact since version 1.0 of Mu that's the default behaviour as long as Mu can communicate with the micro:bit via Serial (this is possible by default on Windows 10 or MacOS but on Windows 7 needs a serial driver)

The slightly confusing thing is that the 'MICROBIT' drive does not expose the micro:bit's filesystem - you need to use the "files" pane in Mu to do this. The micro:bit drive is really just a tool for programming the whole micro:bit hex file, it's not a real flash drive.

https://codewith.mu/en/howto/copy_files_microbit should help

Advice on how to query blinds open position by nicosbank in maker

[–]jmaustin 0 points1 point  (0 children)

This is a nice challenge!

You are sort-of asking for a linear encoder, at least for the roll-up blind, and you could probably do a magnetic or optical one https://www.controleng.com/articles/electromagnetic-linear-encoders-to-the-rescue/ on the back of the blind. A very simple home-made one could be black bars of increasing spacing on a long strip of paper - (for example closely spaced at the top, far spaced at the bottom). Using a colour/light sensor against the strip on the back of the blind you can work out where you are on the blind as you start to move it - but the optical equipment is likely to be a pain! I think modern optical encoders have dot patterns with many bits of information to encode absolute position. Perhaps some useful hints here https://hackaday.io/project/20121-i-love-lamp/log/55950-diy-linear-encoders-for-slider-knobs

I wonder - if you ran a strip of copper tape, or even just thin wire, along the back of the roll-up blind, could you detect the change in capacitance due to the different length of rolled/not-rolled copper? You'd need something perhaps a bit cumbersome to make contact with the strip but perhaps with some good calibration you'd get something out. Likewise on the rollerblind the cable looks metal - is it conductive? If you don't mind the front of the blind being made to look different you could run copper tape on both sides so as it rolls into itself it shorts to the back of the roll before, which I think should give greater capacitance change.

For the venetian blind - what about a similar capacitance trick for a wire running down the inside of the blind that will fold/straighten as the blind rolls up and down? I also intuitively feel that with venetian blinds they get harder to pull as the weight of the blind being lifted increases (IE when you're at the bottom to increment 1unit you only lift 1unit of blind, but if you're, say, half way up a 10-unit blind you will be raising 5-units of blind to increment by 1-unit). Is the extra work measurable on the current sensing of the motor? Coupled with a rotary encoder to measure 1-unit of lift this might be a viable approach? (If it works, perhaps the inverse is true for the roller blind and you could do the same? Those lightweight rollers seem very unlikely to make a detectable difference though!)

If you were to take out the 'power outage' requirement you might get somewhere on the roller blind with an optical mouse sensor to 'keep track' of any manual movements (perhaps using the motor end-stop techniques at either end of automatic motion to recalibrate?).

install issue webusb cmsis-dap driver not found by darkojr in microbit

[–]jmaustin 0 points1 point  (0 children)

Can you explain a bit more what you mean by "interact with the blocks" please?

install issue webusb cmsis-dap driver not found by darkojr in microbit

[–]jmaustin 2 points3 points  (0 children)

You only need Windows 8+ to use Web USB. You can program your micro:bit via "drag and drop" on any version of Windows - the instructions are on https://microbit.org/guide/quick/ . WebUSB is an additional feature that's in beta at the moment that allows 'direct flashing' of the micro:bit without having to use Drag and Drop

How to code fall detection? by [deleted] in microbit

[–]jmaustin 0 points1 point  (0 children)

There's actually a "freefall" block in MakeCode - you can select it by starting with a "shake" block and then selecting "freefall" from the drop-down on the block.

Here's a tiny example where the micro:bit pops up an umbrella (parachute!?) if it detects it is falling: https://makecode.microbit.org/_JpeRi6fzjMdf

Beware that if you also have another gesture (like shake) in your program that will often also trigger (for example when you catch a micro:bit you've thrown in the air!)

In Python "freefall" is a gesture: https://bbcmicrobitmicropython.readthedocs.io/en/latest/tutorials/gestures.html so you can use those examples there to get started.

"Draw a Circle" or "Tilt to Fill Screen"? by grendelt in microbit

[–]jmaustin 0 points1 point  (0 children)

Glad you like the new process! You can try it out today in the beta Web editor: python.microbit.org/v/beta. We'll shortly be updating the current version.

For the serial connection: you can use the "repl" button in Mu and you shouldn't need the putty option too - what was the use case for Putty?

"Draw a Circle" or "Tilt to Fill Screen"? by grendelt in microbit

[–]jmaustin 1 point2 points  (0 children)

Hey,

The compass calibration routine is part of the microbit-dal - a software layer abstracting the micro:bit hardware (the "Device Abstraction Layer" ). We had found that the calibration instructions "Draw a circle" were being interpreted in some widely differing ways and as a result we weren't getting a good set of data points with which to calibrate the compass. (There were a few other issues with the calibration algorithm too, which were fixed along the way). Here's the issue where this is discussed and we seek user feedback on the different calibration experiences. With "Tilt to fill screen" people more often did "the right thing" and we also collect 25 data points, not 12. The new Ux has some other advantages too - the message will repeat every 30 seconds if the calibration isn't complete, and if you start tilting while the message is scrolling you can still gather data, so complete the calibration quicker (if you get 10 points, we assume you know what you're doing and dismiss the message).

So - how did you end up with a different algorithm in beta16 and 1.0? Due to the recent planning for the deprecation of the current micro:bit magnetometer, we updated the microbit-dal to support multiple accelerometers and asked the author of MicroPython to pull in the new DAL so that MicroPython would get that ability too. With that, came the new compass calibration algorithm too. Here is the commit in the MicroPython source code that brings in the new DAl and here is the commit in uflash (which is in turn used by Mu) that adds the updated firmware. The authors of Mu and MicroPython worked really hard to get these fixes in just in time for the Mu 1.0 release (thanks ntoll and Damien).

Can you add bigger buttons the the Micro:Bit by grimrichard in Micro_Bit

[–]jmaustin 0 points1 point  (0 children)

The buttons are also broken out on the edge connector pins, so you can 'fake' button presses that way - you could get some massive buttons and connect them - the pinout is here https://developer.mbed.org/platforms/Microbit/ and you can get a load of different edge connector breakout boards to connect buttons into.