Hot Potato Game Powered by Microbit


To get familiar with the programming language in Microbit, this week I followed the instruction online and built a "hot potato" game which allows two player to compete wirelessly. So firstly one player would hold the potato which contains a number between 10 and 20. Each time the player shake the microbit, he/she tosses the potato to the other player and the number minus one. Once the number comes to zero, the one holds the potato will see a skull on his/her microbit, which is to say, the player loses the game. The codes are as follows.


In programming this game, I found the radio function in Microbit very powerful. It allows information transmission among different devices, and thus add much interactive and fun elements to it. With such interaction, Microbit is not only for representing signal, but can be used as a game machine, which would arouse K-12 students' interest in studying it to a great extent.

Comments

Popular Posts