📖 中文文档
Hardware introduction:
LED Matrix Hardware correlation function display Modular. Before calling related functions, you need to import the corresponding libraries.
The LED panel of bpi: bit uses programmable RGB lamp (ws2812b), which can theoretically display 255 * 255 * 255 * 255 colors, or 16 million colors, by programming.
display.scroll(val, color=Red, delay=150)
:
For example: display.scroll("Hello World!",color=Yellow,delay=200)
Scroll over the LED matrix to display the Yellow "Hello World!" string with a scrolling interval of 200 ms.
The display of images is due to the different states of each LED lamp on and off, color and brightness on the LED matrix. As long as the state of different LED lights is controlled, the desired image can be formed. The image is made up of a list, in which the values of 1 (bright) or 0 (dark) are assigned according to the order of LED lights, respectively, to display the image.
display.show(images, loop, delay)
:
For example: display.show(Image.ALL_CLOCKS, loop=True, delay=100)
In the LED matrix, the clock is displayed by the brightness and extinction of the led. The clock is played back and forth with a change interval of 100 ms.
- show_text.py -Display simple text
- display_yellow_text.py -Show Simple Text Show Yellow Text
- display_color_text.py -Display multicolor text
- display_custom_color.py -Display multicolor text to display custom color text
- show_image.py -Display built-in images
- show_my_image.py -Display custom images
- show_clock.py -Display built-in animation
- show_animation.py -Display custom animation