# data[].attributes.body
padlet.com/RHHSSaida/microbit

# data[].attributes.attachment_link.description
Use the temperature sensor in the micro:bit's processor to make your own digital thermometer.

# data[].attributes.attachment_link.description
Learn how the micro:bit's accelerometer and random number features can make a dice simulator.

# data[].attributes.attachment_link.description
Use the BBC micro:bit's LED display as a light sensor.

# data[].attributes.attachment_link.description
Learn about how computers use random numbers, variables and selection to recreate a classic two-player game of chance.

# data[].attributes.attachment_link.description
Use the micro:bit's accelerometer sensor and random number generators to make a simple, fun game.

# data[].attributes.attachment_link.readable_text
Step 1: Make it

What is it?

Turn your BBC micro:bit into a step counter (or pedometer) to help you track how active you are - and learn some coding at the same time!

These two videos show you what you'll make and how to code it:

How it works

Download the code onto a micro:bit and attach a battery pack.

Attach the micro:bit and battery pack to your shoe or ankle, place it inside your sock, or just hold it in your hand and shake it as you walk.

The code uses the micro:bit's accelerometer sensor input to sense when your leg is moving.

The code counts how many times the micro:bit has been shaken. It stores this number in a variable called 'steps'.

Variables are containers for storing data, which can be accessed and updated while a program is running.

Every time the micro:bit accelerometer input senses a shake, the program increases the number held in the variable by 1, and shows the new number on the LED display output.

What you need

micro:bit (or MakeCode simulator)

MakeCode or Python editor

battery pack

something to attach the micro:bit to your shoe or leg - elastic band, a pipe cleaner, tape or Velcro.

Step 2: Code it

Step 3: Improve it

Modify the code so it shows your current step count when you press a button.

If you find that the code only counts every other step, modify the code to multiply the 'steps' variable by two when it's displayed.

Measure the length of your average stride and get your micro:bit to multiply this by the number of steps to calculate the distance you've walked.

You may also like

# data[].attributes.attachment_link.description
Use the micro:bit's accelerometer to make a step counter or activity tracker.

# data[].attributes.body
Work in groups of 2.
Choose a project.
Go to https://makecode.microbit.org/
Apply
Upload to Microbit
Test
Reflect and comment

# data[].attributes.attachment_link.description
A Blocks / JavaScript code editor for the micro:bit powered by Microsoft MakeCode.

# data[].attributes.body
le projet Dice etait interessant. Je l'ai essaye 10 fois et j'ai recu 2x2 2x3 3x4 2x5 1 x6
MAha et Rana

# data[].attributes.body
Le projet Dice était amusant pour nous! On s'est amusés en faisant le projet de 1 a 6.

De Walid et Touline

# data[].attributes.body
le projet Dice etait interessant. Je l'ai essaye 2 fois et j'ai recu 1x1 2x1 3x1
Ali Et Amir Et Omar

# data[].attributes.body
Lila et Maram
On a aimer le projet Dice