kopia lustrzana https://github.com/blaz-r/pico_python_ws2812b
Updated readme
rodzic
0aa24fb142
commit
06c3e63cf3
|
@ -7,6 +7,8 @@ https://github.com/benevpi/pico_python_ws2812b/blob/main/pico_ws2812b.jpg)
|
|||
|
||||
You'll first need to save the ws2812b.py file to your device (for example, open it in Thonny and go file > save as and select MicroPython device. Give it the same name). Once it's there, you can import it into your code.
|
||||
|
||||
Mind that library works with GRB order of bits. If you have RGBW or want other color/bit orders (RGB, BRG, GRBW.. ) check out my upgraded version https://github.com/blaz-r/pi_pico_neopixel .
|
||||
|
||||
You create an object with the parameters number of LEDs, state machine ID and GPIO number in that order. so, to create a strip of 10 leds on state machine 0 and GPIO 0, you use:
|
||||
|
||||
```
|
||||
|
@ -30,4 +32,9 @@ pixels.set_pixel_line(5, 7, rgb1)
|
|||
pixels.set_pixel_line_gradient(0, 13, rgb1, rgb2)
|
||||
```
|
||||
|
||||
Library is forked from https://github.com/benevpi/pico_python_ws2812b
|
||||
For new settings to take effect you write:
|
||||
```
|
||||
pixels.show()
|
||||
```
|
||||
|
||||
Library is forked from https://github.com/benevpi/pico_python_ws2812b
|
||||
|
|
Ładowanie…
Reference in New Issue