Google Chat: zj734465502@gmail.com
+86-0755-88291180
sales01@spotpear.com
dragon_manager@163.com
services01@spotpear.com
manager01@spotpear.com
WhatsApp:13246739196
Gesture choose music
1. Purpose
In this course, we mainly learn to use Micro:bit, gesture recognition module and Micro:bit alligator clip expansion board to realize gesture choose music.
2.Programming method
Mode 1 online programming:
First, we need to connect the micro:bit to the computer by USB cable. The computer will pop up a USB flash drive and click on the URL in the USB flash drive: http://microbit.org/ to enter the programming interface. Add the Yahboom package: https://github.com/YahboomTechnology/GR to start programming.
Mode 2 offline programming:
We need to open the offline programming software. After the installation is complete, enter the programming interface, click [New Project]. Add Yahboom package: https://github.com/YahboomTechnology/GR, you can start programming.
3.About wiring
4.Combine building blocks
We need to use the following programming building blocks.
Summary procedure as shown below.
Gesture recognition module needs to be initialized by initializing the recognition block. If the initialization is successful, it will return 0. If the recognition is fail, it will return 255, we can restart the program by pressing the reset button of the micro:bit.
Store the recognition result in the value variable, and compare the value of the value with the selection gesture as a building block. If the two are equal, it is the corresponding gesture.
5. Phenomenon
After the program is downloaded successfully, if the initialization is successful, the micro:bit dot matrix will be a smile face, and if it fails, it will be a cry face.
You can press the micro:bit reset button to restart the program to initialize.
Put the gesture recognition module in the vertical direction, open your palm to face the module.
Swing over your palm from left to right in front of the module, the music “dadaum” will be played, and the dot matrix arrow points to the east.
Swing over your palm from right to left in front of the module, the music “entertainer” will be played, and the dot matrix arrow points to the west.
Swing over your palm from bottom to top in front of the module, the music “prelude” will be played, and the dot matrix arrow points to the north.
Swing over your palm from top to bottom in front of the module, the music “prelude” will be played, and the dot matrix arrow points to the south.
Approach from back to front directly in front of the module, stop playing music, and the dot matrix displays a smile face.
Arduino
Micro:bit
Jetson NANO
Raspberry Pi