Blog

Blog

March is all about MAKING!! I have decided to take on the challenge of making a 5-minute micro:bit make every day throughout March. Day06 – Coin Flip Today I have decided to make a Coin Flip program. Great for decision making! Let’s get coding! Python Code from microbit import * import random while True: if button_a.is_pressed(): if random.choice([True, False]): display.show(Image.HAPPY) else: display.show(Image.SAD) EduBlocks Code MakeCode Code Demo Final Words Come back Tomorrow for another fun
March is all about MAKING!! I have decided to take on the challenge of making a 5-minute micro:bit make every day throughout March. Day05 – Simple Dice Today I have decided to make a Dice. This is a great little project if you want to play a board game, but the dice seems to have been misplaced. Let’s get coding! Python Code from microbit import * import random while True: dice = random.randint(1,6) if accelerometer.
March is all about MAKING!! I have decided to take on the challenge of making a 5-minute micro:bit make every day throughout March. Day04 – Step Counter Today I have decided to make a step counter. Everytime the micro:bit is shaken it increases the number of steps by 1. Lets get coding! Python Code steps = None from microbit import * steps = 0 while True: display.scroll(steps) sleep(50) if accelerometer. is_gesture('shake') steps += 1 EduBlocks
March is all about MAKING!! I have decided to take on the challenge of making a 5 minute micro:bit make everyday throughout March. Day03 – Count Down Timer Today I have decided to make a countdown timer. The timer will count up to 20 when button A is pressed and the timer will start counting down from what ever number you chose between 1 and 20 when button B is pressed. Lets get coding! Python
March is all about MAKING!! I have decided to take on the challenge of making a 5-minute micro:bit make every day throughout March. Day02 – Random Number Generator Today I decided to make a random number generator. The random number generator will generate a number between 1 and 5 and dsiplay it on the micro:bit. Lets get coding! Python Code from microbit import * import random display.scroll("Shake Me") while True: if accelerometer.was_gesture('shake'): shake = random.randint(1,