In this project, children will learn how to use variables in making a wire-following game. The aim of the game is to guide a wand along a course without making contact. Making contact will add one to the player’s score - the player with the lowest score wins.
To complete this project, children will need:
- Metal wire (approx. 50cm);
- Electrical tape (optional);
- Crocodile leads (optional).
Steps 1 and 2 of this project can be completed without this equipment.
For this project, the MakeCode (PXT) microbit editor should be used.
You can find a completed version of this project at makecode.microbit.org/#pub:71088-38400-20107-39742, and the compiled .hex file can be downloaded by clicking the ‘Download Project Materials’ link for this project, which contains:
- Input/output (I/O) pins.
This project covers elements from the following strands of the Raspberry Pi Digital Making Curriculum:
- “Display an image” - Display an image on the micro:bit before the number of
- “Cheat mode!” - Subtract 1 from the
failsvariable when button B is pressed.
- “Personalise your game” - Make changes to the wand and course in order to make the game more difficult.