0% found this document useful (0 votes)
140 views2 pages

1 - Introduction To The MicroBit

Uploaded by

ishanth.satheesh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
140 views2 pages

1 - Introduction To The MicroBit

Uploaded by

ishanth.satheesh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Introduction to the MicroBit

This worksheet will introduce you to the BBC micro:bit microcomputer, and take you through the steps to create a
simple app.

The micro:bit
The BBC micro:bit is a small but powerful microcomputer, programs are written using either drag and drop blocks or
written in Python. We will start by using the drag and drop blocks, but you should take time to switch between views
and to how the code is formatted. Once you are ready to run the program on the micro:bit you simply download it
and drag it onto the micro:bit which will show in ‘Computer’ once you connect it via USB.

Let’s get to know the parts of the micro:bit.

Reset button A and B


USB connection buttons

Power connection

First program – Scrolling Text


To get used to working with the micro:bit we will start with a simple program which will display your name as
scrolling text on the leds.

Open a web browser to www.microbit.org and click on ‘Let’s Code’ at the top of the page.

Click ‘Let’s Code’ again for the MakeCode Editor, this will allow you to create programs using drag and drop blocks
like in Scratch.

Select ‘New Project’, this will take you to a screen which contains a model of the micro:bit, the code blocks and on
space for your code on the right.

We start with a simple program which will display the text ‘Hello world’, copy the program below by finding the
correct code blocks and dragging them on to the space on the right.

The model on the left should show what will happen when you download your code and put it on the micro:bit, this
allows you to test your code before downloading it.
Putting your program on the micro:bit
Download your program, putting the name ‘HelloWorld’ in the name box and clicking the save button, save the file
to a suitable folder on your home drive. Once there plug the micro:bit into the usb socket and drag and drop the
program file (should be named something like ‘microbit-HelloWorld.hex’) onto the micro:bit, note it will not show as
a file if you click on the micro:bit, but the program should start running as soon as the download has finished.

Program name here

Save button

What next?
Below is another program for you to try, this will allow you to display 2 different messages depending on which
button you press. Write a program to display your and your partner’s names when you press the different buttons.

Don’t forget to give your program a sensible name and save it to


the same folder in your home drive before you copy it on to the
micro:bit.

Next steps
Below is a list of simple micro:bit programs you can make with your partner, take time to look through the different
code blocks available to you, for help with any of these right click on the block and select ‘Help’.

Work together to create the following programs:

 One which displays different messages when you press both buttons A and B together, and when you shake
the micro:bit.
 Display a pattern on the screen by changing the LEDs in sequence, experiment with delays, can you
introduce some randomness?
 Display a random number between 1 and 6 when you shake the micro:bit.
 Can you create a magic 8 ball, when you shake the micro:bit it sets a variable to a random number, and then
displays a short yes/no/maybe message based on the random number.
 If you have completed all the tasks above, have a look through the remaining blocks, what ideas for
programs can you come up with? Can you create the program in the remaining time?

You might also like