Bit:bots are go!
Delving deeper with BBC micro:bits - Project 4
Objectives
- Understand looping as a form of iteration
- Understand and use variables in a program
- Understand and use conditional statements
- Combine inputs, loops, conditional statements and variables to create a micro:bit game
Lesson Resources
Project 1 – Bit:bopping music
Project 2 – Inputs, loops, conditionals, variables… games!
Project 3 – Incoming message!
Project 4 – Bit:bots are go!
Introduction - Meet the Bit:bot
Bit:bots are available from 4Tronix and are one of a number of very affordable robot chassis kits available for the BBC micro:bit.
https://shop.4tronix.co.uk/collections/robot-kits/products/bit-bot-robot-for-bbc-micro-bit-bitbot-for-microbit, £30.00 (inc VAT £36.00)
Meet the Bitbot! A fantastic companion for your micro:bit, but what do you think it is and what could it do?
Ask the students to have a good look at it on its own and discuss what it could be used for and any features they think it might have.
Then take a look at it together:
Images courtesy of: https://4tronix.co.uk/blog/?p=1490
It has the following features:
- 2 micro-metal gear motors. Both fully controllable in software, for both speed (0 to 100%) and direction (forward or reverse)
- Wheels with rubber tyres for maximum grip
- Really smooth nylon ball front caster
- 12 mini neopixels in 2 sets of 6 along the arms either side. Select any colour for any pixel, produce stunning lighting effects as your Bit:Bot moves around
- 2 digital line following sensors. Code your own line-following robots and race them to see whose code produces the fastest lap time!
- 2 analog light sensors (front left and front right) so your Bit:Bot can be programmed to follow a light source such as a torch, or you could code it to go and hide in the darkest place it can find
- Buzzer, so you can make beeping sounds whenever you want
- Powered from integrated 3xAA battery holder with on/off switch and blue indicator LED
- Easily plug your BBC micro:bit in and out using the edge connector
- Extension port for addition neopixels
- Expansion connections at the front for additional sensors (Ultrasonic rangefinder available now, more in development)
In this project we are going to learn how to program it to move and investigate other ways we can interact with it too.
Controlling your Bitbot with MakeCode.
The Bitbot can be coded in a number of ways, but the most simple method is by adding the Bitbot extension blocks to the MakeCode editor. Ask the students to go to microbit.org and open a new project in the MakeCode editor (via the 'Let's Code' page).
Once a project is open, click on the Advanced section of blocks and scroll down to the Extensions section.
Select the BitBot extension.
This will add the Bitbot extension to your block library.