micro:bit


Here are a couple of projects for the micro:bit to download and try out for yourself!


Brake/Tail Light

This is a novelty brake/tail light for your bike, scooter, skateboard, or R/C car!

Open the MakeCode project here: https://makecode.microbit.org/_X9oEboXfehL3

Using the accelerometer it will make a bright brake light come on when you brake, and if you brake really hard the light will flash just like on some cars with LED taillights! There is also a dimmer tail light that optionally stays on all the time. You can also choose between a round and a square pattern for both the tail light and the brake light.

NOTE: Always use proper bicycle lights when riding at night! This is just a novelty for use in your garden or in the park, not on the road!

BrakeTailLight.hex (Can both be dragged directly to the hardware to run AND imported as the full original JavaScript source code in the MakeCode editor)

BrakeTailLight.js (Original JavaScript code as a JavaScript file)

BrakeTailLight.py (optional Python code - was auto-generated from the JavaScript code)

BrakeTailLight.txt (Original JavaScript code as an easy to view text file (in case the editor changes, again.. :D)

Note: The Cube Stack Timer is now updated to work on the latest Microsoft MakeCode Editor (see https://www.microbit.org/). Have fun!


Cube/Stack Timer

Here’s a micro:bit program which simulates official Rubik’s Cube and cup stack competition timers.

Click here to edit/run the MakeCode project directly on the web: https://makecode.microbit.org/_Vx22cXdwghJU

Or just give it a go right here:


Like the official timers, you have to hold both buttons to start the clock, and it only stops when you’ve pressed both buttons again. This is to ensure that you’ve put down the cube / not still touching any cups. The time (accurate to 1 millisecond) scrolls across the screen digitally at the end in an easy to read mm:ss.sss format (and repeats in case you missed it).


There’s a simulated BBC micro:bit right on the website so you don’t even have to have one to have fun with it:


Here are the files available to download:

CubeStackTimer.hex (Can both be dragged directly to the hardware to run AND imported as the full original JavaScript source code in the MakeCode editor)

CubeStackTimer.js (Original JavaScript code as a JavaScript file)

CubeStackTimer.py (optional Python code - was auto-generated from the JavaScript code)

CubeStackTimer.txt (Original JavaScript code as an easy to view text file (in case the editor changes, again.. :D))

Note: Both projects ie Brake/Tail Light and The Cube Stack Timer is now updated to work on the latest Microsoft MakeCode Editor (see https://www.microbit.org/). Have fun!


© 2022 DemonStudios Ltd