RGB LED Screen - Neopixel Tutorial
This tutorial is about programming the RGB LED Screen using the Neopixel extension.
Effects such as lighting up the whole screen with single or multiple colours, lighting up just a range or marquee effects.
RGB LED Screen is used with the Robotbit, please refer to the following figures.
1. Connect the screen to the adapter.
2. Connect the adapter to Robotbit。
3. For prolonged use, connect a USB power.
As power is delivered via USB, you don’t have to use the 5V pin on the adapter.
4. Demonstration of wiring
The LEDs on the screen are wired in a zig zag pattern in to a rectangle, please refer to the following figures.
Makecode Coding Tutorial
Load the Robotbit extension.
LED Screen Initialization:
Since there are 256 LEDs on the screen, we initialize a light strip with 256 LEDs.
Lighting up the whole screen.
We can light up the screen with a single colour.
You can select a colour from the presets.
We can apply a rainbow effect to the screen.
Rainbow effect uses the HSL format. Showing multiple colours require more power, you may need to connect the external power.
It is recommended to lower the brightness to reduce the current and to avoid damage to our eyes.
The brightness value ranges from 0 to 255. Since the current is reduced, there is no need for external power.
Lighting up a single LED
Each LED can be individualy controlled.
The effect only shows after using show.
Pixels can move when we use a marquee effect, there are two modes in Marquee, shift or rotate.
Effects are only shown after refreshing.
In shift mode, the animation ends after the pixel reaches the end.
In rotate mode, the animation restarts after the pixel reaches the end.
Selecting a range
We can control a range of LEDs.
Selecting 4 LEDs starting from pixel 10. (10, 11, 12 ,13)
We can customize colours using RGB or HSV format.
Extension Version and Updates
There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.
Q: Why is red the only colour lit up when I try to use different colours?
A: There is not enough power.
Solution: Reduce brightness or turn on the power on the Robotbit, or connect to a USB power.
Do not connect a power supply with a voltage higher than 5V.
Connect to a USB power supply when for prolonged use.
Lower the brighness when a lot of LEDs are lit.
This product is suitable for users aged over 14, children aged 8-14 need to be under the supervision of an adult when using this product.
Please refer to Kittenbot’s official guidelines before using, wiring must follow the guidelines, do not use a high power servo or motor when using this product.
To avoid short circuiting, do not put this product on conductive surfaces such as metal.
To avoid short circuiting, do not put this product in water.
Do not touch the exposed wires with bare hands.