Skip to content
All prices in US$ - All orders receive free delivery, worldwide - Click here to learn more
All prices in US$ - All orders receive free delivery, worldwide - Touch here to learn more
Play "Zap the Rat" on the BBC micro:bit

Play "Zap the Rat" on the BBC micro:bit

In our opinion, the BBC micro:bit is a completely under-rated learning tool and piece of technology, as it has so many inbuilt functions for such a great price.

One example of this is the ability to make games that use the LED matrix, such as "Zap the Rat" by Tony Goodhew. In his own words:

A rat, represented by a moving LED runs anti-clockwise round the edge of the display. The player presses button B, to Zap the Rat, while the rat is LIT and in the ZAP position (red), between the marker (orange) and button B.

This is harder than it appears. If the rat is ZAPPED one of the score LEDs is switched on (light blue). The player has to zap three rats to complete the turn.

If the player misses a rat an opportunity missed is counted against him - up to a maximum of 25.

Once three rats have been zapped the score of missed rats is displayed on the LEDs. A perfect score is ZERO missed rats - harder to achieve than you think - and a display appears on the grid of LEDs.

Check out the video below for a quick demonstration:

The coding is easy thanks to using the mu python environment for the micro:bit. Check out the project instructable to learn all the details.

And if you're interested in doing this yourself, PMD Way can help you with the parts, such as:

Finally - to keep up to date with interesting news, offers and new products - interact with us on facebook, instagram, and twitter.

Previous article Bill Sideris' Ljinux Puts "a Linux Written in Python" Onto Your Raspberry Pi Pico's RP2040

Leave a comment

Comments must be approved before appearing

* Required fields