Robot Kit for Micro:bit Tutorial 3.4 LED light exchange lighting
1-1.The position of the LED lights in the robot car
1-2.Learn about the principle of LED
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/lzty634158/Tiny-bit to program.
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/lzty634158/Tiny-bit, you can program.In the picture shown below, the two white squares circled by the red wire frame are the colorful lights on the Tiny-bit.
Principle: LED light (red, green, blue) are packaged in the LED module. We can mix different colors(256*256*256) by controlling the brightness of the three LEDs.
2-1.Learn how to use LED lights graphically program building blocks
2-2.We will make two LED lights of Tiny-bit light up white by programming.
3.Search for block
The following is the location of the building blocks required for this programming.
The summary program is shown below:
After the program is downloaded , we can see that a smile pattern is displayed on the dot matrix of micro:bit board. The two LED lights alternately light up different colors, as shown below.
The code of the experiment: 4.LED light exchange lighting.rar
Lighting with Tiny bit Micro:bit Robot Tutorial:
- Lighting with Tiny bit Micro:bit Robot Tutorial 3.1: LED light
- Lighting with Tiny bit Micro:bit Robot Tutorial 3.2: RGB Searching light
- Lighting with Tiny bit Micro:bit Robot Tutorial 3.3: RGB light exchange lighting
- Lighting with Tiny bit Micro:bit Robot Tutorial 3.4: LED light exchange lighting
- Lighting with Tiny bit Micro:bit Robot Tutorial 3.5: Breathing light