Micro:bit Based Neck Stretching Game With Meowbit BLE

by KittenBot in Circuits > Wearables

1449 Views, 10 Favorites, 0 Comments

Micro:bit Based Neck Stretching Game With Meowbit BLE

FK9G87SKUPIZ2UL.png
IMG_2864 copy.jpg

Sitting in front of the computer all day is exhausting, so we decided to make a game with Micro:bit and Meowbit to stretch our necks and relax. Meowbit can communicate with Micro:bit through the wireless SD BLE module, so we made an interactive game based on this feature.

All the things we used are listed below, and the code for this project is also provided in this article, so let's give it a go!

If you like our projects and tutorials, you can follow us on TwitterFacebook, and Youtube for more interesting STEM projects and ideas.

Supplies

IMG_2858 copy.jpg

Electronics:

1 × Meowbit Game Console

1 × Micro:bit V2

1 × Wireless SD BLE Module

1 × Hook-and-loop fastener

1 × Lithium battery 400mAh

1 × battery holder

2 × AAA battery

1 × Micro:bit silicone case

You may also need some bobby pins.

Online Service:

Microsoft MakeCode

MakeCode Arcade

Design

design.jpeg
BLE.jpeg

Our idea is to make a game on MakeCode Arcade, and then write another program with MakeCode to control the sprite in the game.

The protagonist - the puppy has to eat the bones dropping from the sky in 25 seconds.

And by tilting Micro:bit to the right or left, the puppy would move correspondingly in Meowbit.

Micro:bit collects its gesture and controls the puppy sprite on Meowbit through the 2.4G wireless communication control.

The Program of Micro:bit on MakeCode

makecode 编程.png

The program is simple: set a radio group 1, by evaluating whether Micro:bit is leaning to the left or right, it sends different wireless signals.

You can also open the program directly on MakeCode here

Then download it to your Micro:bit.

The Program of Meowbit on MakeCode Arcade

makecodearcade 编程.png
download arcade.png

Set a radio group 1. When receiving the radio signal from Micro:bit, it controls the sprite (the puppy) to move to the left or right.

Or you can open the program directly on MakeCode Arcade here

When you open the link of this program directly, you may find that the box of the Set Radio Group is blank, then please delete the block, and then drag a new one from the Sdwireless section and change the number 0 into 1.

When you finish your program, download it to your Meowbit.

What Should I Do With the Error Report

error.png

If you see an error report when opening the MakeCode Arcade program and the simulator is not working, it is because MakeCode Arcade currently doesn't support the SD wireless BLE module perfectly. We can just ignore it, because it works at last when downloaded to the game console (Meowbit).

Turn on the SD BLE Module

turn on green mode.jpeg

Remember to insert the SD module into Meowbit and switch it to the green light mode (2.4G)

Power Micro:bit and Meowbit With Batteries

battery for microbit.jpg
battery for meowbit.jpg

Connect Micro:bit to the battery holder holding two AAA batteries.

Connect Meowbit to the 4000 mAh lithium battery.

Tips - Fix Micro:bit on the Hook-and-loop Fastener

IMG_2871 copy.jpg

Now you see why we put a silicone case on Micro:bit, because it's easier to fix Micro:bit on the hook-and-loop fastener with some bobby pins in this way.

Done! Test It Out

Microbit & Meowbit Wireless Communication: A MakeCode Arcade Game to Stretch Your Neck

Tie the Micro:nbit and battery on your head and see how it works ^^

Test it out and enjoy your work!