Skip to content

Add pixelbuf for accelerating NeoPixel operations #943

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 9 commits into from
Jan 22, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/library/builtins.rst
Original file line number Diff line number Diff line change
Expand Up @@ -78,12 +78,12 @@ Not all of these functions and types are turned on in all CircuitPython ports, f

.. classmethod:: from_bytes(bytes, byteorder)

In CircuitPython, `byteorder` parameter must be positional (this is
In CircuitPython, ``byteorder`` parameter must be positional (this is
compatible with CPython).

.. method:: to_bytes(size, byteorder)

In CircuitPython, `byteorder` parameter must be positional (this is
In CircuitPython, ``byteorder`` parameter must be positional (this is
compatible with CPython).

.. function:: isinstance()
Expand Down
73 changes: 63 additions & 10 deletions locale/ID.po
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2019-01-21 21:50-0500\n"
"POT-Creation-Date: 2019-01-22 14:00-0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <[email protected]>\n"
Expand Down Expand Up @@ -1963,7 +1963,7 @@ msgstr ""
msgid "argument should be a '%q' not a '%q'"
msgstr ""

#: py/runtime.c:1123 py/runtime.c:1197
#: py/runtime.c:1123 py/runtime.c:1197 shared-bindings/_pixelbuf/__init__.c:106
msgid "no such attribute"
msgstr ""

Expand Down Expand Up @@ -2042,6 +2042,54 @@ msgstr ""
msgid "byte code not implemented"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:99
#, c-format
msgid "byteorder is not an instance of ByteOrder (got a %s)"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:104
#, c-format
msgid "Can not use dotstar with %s"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:116
msgid "rawbuf is not the same size as buf"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:121
#, c-format
msgid "buf is too small. need %d bytes"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:127
msgid "write_args must be a list, tuple, or None"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:392
msgid "Only slices with step=1 (aka None) are supported"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:394
msgid "Range out of bounds"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:403
msgid "tuple/list required on RHS"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:419
#, c-format
msgid "Unmatched number of items on RHS (expected %d, got %d)."
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:442
msgid "Pixel beyond bounds of buffer"
msgstr ""

#: shared-bindings/_pixelbuf/__init__.c:112
msgid "readonly attribute"
msgstr ""

#: shared-bindings/_stage/Layer.c:71
msgid "graphic must be 2048 bytes long"
msgstr ""
Expand Down Expand Up @@ -2535,6 +2583,11 @@ msgid ""
"Object has been deinitialized and can no longer be used. Create a new object."
msgstr ""

#: shared-module/_pixelbuf/PixelBuf.c:69
#, c-format
msgid "Expected tuple of length %d, got %d"
msgstr ""

#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
msgid "Couldn't allocate first buffer"
msgstr ""
Expand Down Expand Up @@ -2771,12 +2824,8 @@ msgstr ""
#~ msgstr ""
#~ "Silahkan taruh masalah disini dengan isi dari CIRCUITPY drive: anda \n"

#~ msgid "Invalid UUID parameter"
#~ msgstr "Parameter UUID tidak valid"

#~ msgid "Looks like our core CircuitPython code crashed hard. Whoops!\n"
#~ msgstr ""
#~ "Sepertinya inti kode CircuitPython kita crash dengan sangat keras. Ups!\n"
#~ msgid "Invalid UUID string length"
#~ msgstr "Panjang string UUID tidak valid"

#~ msgid ""
#~ "enough power for the whole circuit and press reset (after ejecting "
Expand All @@ -2785,8 +2834,12 @@ msgstr ""
#~ "tegangan cukup untuk semua sirkuit dan tekan reset (setelah mencabut "
#~ "CIRCUITPY).\n"

#~ msgid "Invalid UUID string length"
#~ msgstr "Panjang string UUID tidak valid"
#~ msgid "Looks like our core CircuitPython code crashed hard. Whoops!\n"
#~ msgstr ""
#~ "Sepertinya inti kode CircuitPython kita crash dengan sangat keras. Ups!\n"

#~ msgid "Invalid UUID parameter"
#~ msgstr "Parameter UUID tidak valid"

#, fuzzy
#~ msgid "unpack requires a buffer of %d bytes"
Expand Down
57 changes: 55 additions & 2 deletions locale/circuitpython.pot
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2019-01-21 21:50-0500\n"
"POT-Creation-Date: 2019-01-22 14:00-0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <[email protected]>\n"
Expand Down Expand Up @@ -1930,7 +1930,7 @@ msgstr ""
msgid "argument should be a '%q' not a '%q'"
msgstr ""

#: py/runtime.c:1123 py/runtime.c:1197
#: py/runtime.c:1123 py/runtime.c:1197 shared-bindings/_pixelbuf/__init__.c:106
msgid "no such attribute"
msgstr ""

Expand Down Expand Up @@ -2009,6 +2009,54 @@ msgstr ""
msgid "byte code not implemented"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:99
#, c-format
msgid "byteorder is not an instance of ByteOrder (got a %s)"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:104
#, c-format
msgid "Can not use dotstar with %s"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:116
msgid "rawbuf is not the same size as buf"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:121
#, c-format
msgid "buf is too small. need %d bytes"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:127
msgid "write_args must be a list, tuple, or None"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:392
msgid "Only slices with step=1 (aka None) are supported"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:394
msgid "Range out of bounds"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:403
msgid "tuple/list required on RHS"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:419
#, c-format
msgid "Unmatched number of items on RHS (expected %d, got %d)."
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:442
msgid "Pixel beyond bounds of buffer"
msgstr ""

#: shared-bindings/_pixelbuf/__init__.c:112
msgid "readonly attribute"
msgstr ""

#: shared-bindings/_stage/Layer.c:71
msgid "graphic must be 2048 bytes long"
msgstr ""
Expand Down Expand Up @@ -2497,6 +2545,11 @@ msgid ""
"Object has been deinitialized and can no longer be used. Create a new object."
msgstr ""

#: shared-module/_pixelbuf/PixelBuf.c:69
#, c-format
msgid "Expected tuple of length %d, got %d"
msgstr ""

#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
msgid "Couldn't allocate first buffer"
msgstr ""
Expand Down
105 changes: 79 additions & 26 deletions locale/de_DE.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2019-01-21 21:50-0500\n"
"POT-Creation-Date: 2019-01-22 14:00-0800\n"
"PO-Revision-Date: 2018-07-27 11:55-0700\n"
"Last-Translator: Sebastian Plamauer\n"
"Language-Team: \n"
Expand Down Expand Up @@ -1959,7 +1959,7 @@ msgstr ""
msgid "argument should be a '%q' not a '%q'"
msgstr ""

#: py/runtime.c:1123 py/runtime.c:1197
#: py/runtime.c:1123 py/runtime.c:1197 shared-bindings/_pixelbuf/__init__.c:106
msgid "no such attribute"
msgstr ""

Expand Down Expand Up @@ -2038,6 +2038,54 @@ msgstr ""
msgid "byte code not implemented"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:99
#, c-format
msgid "byteorder is not an instance of ByteOrder (got a %s)"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:104
#, c-format
msgid "Can not use dotstar with %s"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:116
msgid "rawbuf is not the same size as buf"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:121
#, c-format
msgid "buf is too small. need %d bytes"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:127
msgid "write_args must be a list, tuple, or None"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:392
msgid "Only slices with step=1 (aka None) are supported"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:394
msgid "Range out of bounds"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:403
msgid "tuple/list required on RHS"
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:419
#, c-format
msgid "Unmatched number of items on RHS (expected %d, got %d)."
msgstr ""

#: shared-bindings/_pixelbuf/PixelBuf.c:442
msgid "Pixel beyond bounds of buffer"
msgstr ""

#: shared-bindings/_pixelbuf/__init__.c:112
msgid "readonly attribute"
msgstr ""

#: shared-bindings/_stage/Layer.c:71
msgid "graphic must be 2048 bytes long"
msgstr ""
Expand Down Expand Up @@ -2537,6 +2585,11 @@ msgid ""
"Object has been deinitialized and can no longer be used. Create a new object."
msgstr ""

#: shared-module/_pixelbuf/PixelBuf.c:69
#, c-format
msgid "Expected tuple of length %d, got %d"
msgstr ""

#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
msgid "Couldn't allocate first buffer"
msgstr ""
Expand Down Expand Up @@ -2767,19 +2820,35 @@ msgid ""
"exit safe mode.\n"
msgstr ""

#~ msgid "Invalid UUID string length"
#~ msgstr "Ungültige UUID-Stringlänge"

#~ msgid "Can encode UUID into the advertisement packet."
#~ msgstr "Kann UUID in das advertisement packet kodieren."

#~ msgid "Invalid UUID string length"
#~ msgstr "Ungültige UUID-Stringlänge"

#~ msgid ""
#~ "Please file an issue here with the contents of your CIRCUITPY drive:\n"
#~ msgstr ""
#~ "Bitte erstelle ein issue hier mit dem Inhalt deines CIRCUITPY-speichers:\n"

#~ msgid "Invalid UUID parameter"
#~ msgstr "Ungültiger UUID-Parameter"
#~ msgid "Can not add Characteristic."
#~ msgstr "Kann das Merkmal nicht hinzufügen."

#~ msgid "Cannot apply GAP parameters."
#~ msgstr "Kann GAP Parameter nicht anwenden."

#~ msgid "Can not encode UUID, to check length."
#~ msgstr "Kann UUID nicht kodieren, um die Länge zu überprüfen."

#~ msgid "Can not add Service."
#~ msgstr "Kann den Dienst nicht hinzufügen."

#~ msgid "Can not query for the device address."
#~ msgstr "Kann nicht nach der Geräteadresse suchen."

#, fuzzy
#~ msgid "unpack requires a buffer of %d bytes"
#~ msgstr "Konnte keine RX Buffer mit %d allozieren"

#~ msgid "Invalid Service type"
#~ msgstr "Ungültiger Diensttyp"
Expand All @@ -2791,30 +2860,14 @@ msgstr ""
#~ "genug Strom für den ganzen Schaltkreis liefert und drücke reset (nach dem "
#~ "sicheren Auswerfen von CIRCUITPY.)\n"

#~ msgid "Invalid UUID parameter"
#~ msgstr "Ungültiger UUID-Parameter"

#~ msgid "Can not apply device name in the stack."
#~ msgstr "Der Gerätename kann nicht im Stack verwendet werden."

#~ msgid "Can not query for the device address."
#~ msgstr "Kann nicht nach der Geräteadresse suchen."

#~ msgid "Can not encode UUID, to check length."
#~ msgstr "Kann UUID nicht kodieren, um die Länge zu überprüfen."

#~ msgid "Cannot apply GAP parameters."
#~ msgstr "Kann GAP Parameter nicht anwenden."

#~ msgid "Can not apply advertisement data. status: 0x%02x"
#~ msgstr "Kann advertisement data nicht anwenden. Status: 0x%02x"

#~ msgid "Looks like our core CircuitPython code crashed hard. Whoops!\n"
#~ msgstr "CircuitPython ist abgestürzt. Ups!\n"

#~ msgid "Can not add Service."
#~ msgstr "Kann den Dienst nicht hinzufügen."

#~ msgid "Can not add Characteristic."
#~ msgstr "Kann das Merkmal nicht hinzufügen."

#, fuzzy
#~ msgid "unpack requires a buffer of %d bytes"
#~ msgstr "Konnte keine RX Buffer mit %d allozieren"
Loading