Skip to content

Commit 309a585

Browse files
Docs: update for V2 neopixel module (#694)
* Docs: update for RGBW neopixel * Docs: RGBW neopixels * Update docs/neopixel.rst Co-authored-by: Carlos Pereira Atencio <carlos@microbit.org> * Update docs/neopixel.rst Co-authored-by: Carlos Pereira Atencio <carlos@microbit.org> * change to bpp * change to bpp * add image attribution * Update docs/neopixel.rst Co-authored-by: Carlos Pereira Atencio <carlos@microbit.org> * Add V2 methods * Docs: Update neopixel Co-authored-by: Carlos Pereira Atencio <carlos@microbit.org>
1 parent cd5a13e commit 309a585

1 file changed

Lines changed: 13 additions & 3 deletions

File tree

docs/neopixel.rst

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ module, you need to import it separately with::
1313

1414
From our tests, the Microbit NeoPixel module can drive up to around 256
1515
NeoPixels. Anything above that and you may experience weird bugs and
16-
issues. As the micro:bit can only supply 90mA to external devices,
17-
larger numbers of NeoPixels require an external power supply with common
18-
ground.
16+
issues. The micro:bit can only supply 90mA **V1** or 190mA **V2** to
17+
external devices,larger numbers of NeoPixels require an external power
18+
supply with common ground.
1919

2020
NeoPixels are designed to work at 5V, but luckily they still function using
2121
the 3V supply of the BBC micro:bit. Please note that the micro:bit edge
@@ -71,9 +71,19 @@ Classes
7171

7272

7373
.. py:method:: show()
74+
write()
7475
7576
Show the pixels. Must be called for any updates to become visible.
77+
For micro:bit **V2**, an additional ``write()`` method is
78+
available and is equivalent to ``show()``
7679

80+
.. py:method:: fill(colour)
81+
82+
**V2** Colour all pixels a given RGB/RGBW value. The `colour` argument
83+
should be a tuple of the same length as the mumber of bytes per pixel
84+
(bpp). For example ``fill((0,0,255))``. Use in conjunction with
85+
``show()`` to update the Neopixels.
86+
7787
Operations
7888
==========
7989

0 commit comments

Comments
 (0)