commit
3abc671bbd
2
.github/workflows/build.yml
vendored
2
.github/workflows/build.yml
vendored
@ -421,7 +421,7 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
board:
|
||||
- "adafruit_esp32s2_eink_portal"
|
||||
- "adafruit_magtag_2.9_grayscale"
|
||||
- "adafruit_metro_esp32s2"
|
||||
- "electroniccats_bastwifi"
|
||||
- "espressif_kaluga_1"
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit de6b7704c530d886ad8dfa0fa1864764d86117ee
|
||||
Subproject commit 902c16f49197a8baf5e71ec924a812a86e733a74
|
14
locale/ID.po
14
locale/ID.po
@ -5,7 +5,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-10-10 23:51+0000\n"
|
||||
"Last-Translator: oon arfiandwi <oon.arfiandwi@gmail.com>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
@ -300,6 +300,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "Semua perangkat I2C sedang digunakan"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -431,6 +435,11 @@ msgstr "Di bawah frame rate minimum"
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr "Bit clock dan word harus memiliki kesamaan pada clock unit"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "Kedalaman bit harus kelipatan 8."
|
||||
@ -1130,7 +1139,8 @@ msgid "Invalid phase"
|
||||
msgstr "Fase tidak valid"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Pin tidak valid"
|
||||
|
@ -8,7 +8,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
@ -296,6 +296,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -425,6 +429,11 @@ msgstr ""
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr ""
|
||||
@ -1109,7 +1118,8 @@ msgid "Invalid phase"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr ""
|
||||
|
14
locale/cs.po
14
locale/cs.po
@ -5,7 +5,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-05-24 03:22+0000\n"
|
||||
"Last-Translator: dronecz <mzuzelka@gmail.com>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
@ -300,6 +300,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -429,6 +433,11 @@ msgstr ""
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr ""
|
||||
@ -1113,7 +1122,8 @@ msgid "Invalid phase"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr ""
|
||||
|
@ -5,7 +5,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-06-16 18:24+0000\n"
|
||||
"Last-Translator: Andreas Buchen <andreas.buchen@gmail.com>\n"
|
||||
"Language: de_DE\n"
|
||||
@ -299,6 +299,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "Alle I2C-Peripheriegeräte sind in Benutzung"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -432,6 +436,11 @@ msgstr "Unterhalb der minimalen Frame Rate"
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr "Bit clock und word select müssen eine clock unit teilen"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "Bit depth muss ein Vielfaches von 8 sein."
|
||||
@ -1130,7 +1139,8 @@ msgid "Invalid phase"
|
||||
msgstr "Ungültige Phase"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Ungültiger Pin"
|
||||
|
14
locale/el.po
14
locale/el.po
@ -7,7 +7,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: Automatically generated\n"
|
||||
"Language-Team: none\n"
|
||||
@ -295,6 +295,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -424,6 +428,11 @@ msgstr ""
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr ""
|
||||
@ -1108,7 +1117,8 @@ msgid "Invalid phase"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr ""
|
||||
|
14
locale/es.po
14
locale/es.po
@ -7,7 +7,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-11-01 16:26+0000\n"
|
||||
"Last-Translator: Alvaro Figueroa <alvaro@greencore.co.cr>\n"
|
||||
"Language-Team: \n"
|
||||
@ -303,6 +303,10 @@ msgstr "Todos los periféricos CAN están en uso"
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "Todos los periféricos I2C están siendo usados"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -438,6 +442,11 @@ msgstr "Por debajo de taza mínima de refrescamiento"
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr "Bit clock y word select deben compartir una unidad de reloj"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "Bits depth debe ser múltiplo de 8."
|
||||
@ -1131,7 +1140,8 @@ msgid "Invalid phase"
|
||||
msgstr "Fase inválida"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Pin inválido"
|
||||
|
@ -5,7 +5,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2018-12-20 22:15-0800\n"
|
||||
"Last-Translator: Timothy <me@timothygarcia.ca>\n"
|
||||
"Language-Team: fil\n"
|
||||
@ -297,6 +297,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "Lahat ng I2C peripherals ginagamit"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -429,6 +433,11 @@ msgstr ""
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr "Ang bit clock at word select dapat makibahagi sa isang clock unit"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "Bit depth ay dapat multiple ng 8."
|
||||
@ -1123,7 +1132,8 @@ msgid "Invalid phase"
|
||||
msgstr "Mali ang phase"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Mali ang pin"
|
||||
|
14
locale/fr.po
14
locale/fr.po
@ -7,7 +7,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: 0.1\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-10-22 20:48+0000\n"
|
||||
"Last-Translator: Antonin ENFRUN <antonin.e@me.com>\n"
|
||||
"Language: fr\n"
|
||||
@ -304,6 +304,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "Tous les périphériques I2C sont utilisés"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -438,6 +442,11 @@ msgstr "Inférieur à la fréquence d'images minimale"
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr "'bit clock' et 'word select' doivent partager une horloge"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "La profondeur de bit doit être un multiple de 8."
|
||||
@ -1136,7 +1145,8 @@ msgid "Invalid phase"
|
||||
msgstr "Phase invalide"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Broche invalide"
|
||||
|
14
locale/hi.po
14
locale/hi.po
@ -7,7 +7,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: Automatically generated\n"
|
||||
"Language-Team: none\n"
|
||||
@ -295,6 +295,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -424,6 +428,11 @@ msgstr ""
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr ""
|
||||
@ -1108,7 +1117,8 @@ msgid "Invalid phase"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr ""
|
||||
|
@ -6,7 +6,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2018-10-02 16:27+0200\n"
|
||||
"Last-Translator: Enrico Paganin <enrico.paganin@mail.com>\n"
|
||||
"Language-Team: \n"
|
||||
@ -296,6 +296,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "Tutte le periferiche I2C sono in uso"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -429,6 +433,11 @@ msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr ""
|
||||
"Clock di bit e selezione parola devono condividere la stessa unità di clock"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "La profondità di bit deve essere multipla di 8."
|
||||
@ -1125,7 +1134,8 @@ msgid "Invalid phase"
|
||||
msgstr "Fase non valida"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Pin non valido"
|
||||
|
54
locale/ja.po
54
locale/ja.po
@ -7,16 +7,16 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"PO-Revision-Date: 2020-09-25 18:20+0000\n"
|
||||
"Last-Translator: Taku Fukada <naninunenor@gmail.com>\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-11-12 22:51+0000\n"
|
||||
"Last-Translator: sporeball <sporeballdev@gmail.com>\n"
|
||||
"Language-Team: none\n"
|
||||
"Language: ja\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Weblate 4.3-dev\n"
|
||||
"X-Generator: Weblate 4.4-dev\n"
|
||||
|
||||
#: main.c
|
||||
msgid ""
|
||||
@ -162,12 +162,12 @@ msgstr "'%s' にはラベルが必要"
|
||||
#: py/emitinlinethumb.c py/emitinlinextensa.c
|
||||
#, c-format
|
||||
msgid "'%s' expects a register"
|
||||
msgstr ""
|
||||
msgstr "'%s'にはレジスタが必要"
|
||||
|
||||
#: py/emitinlinethumb.c
|
||||
#, c-format
|
||||
msgid "'%s' expects a special register"
|
||||
msgstr ""
|
||||
msgstr "'%s'には特別レジスタが必要"
|
||||
|
||||
#: py/emitinlinethumb.c
|
||||
#, c-format
|
||||
@ -192,7 +192,7 @@ msgstr ""
|
||||
#: py/emitinlinethumb.c
|
||||
#, c-format
|
||||
msgid "'%s' expects {r0, r1, ...}"
|
||||
msgstr ""
|
||||
msgstr "'%s'には{r0, r1, ...}が必要"
|
||||
|
||||
#: py/emitinlinextensa.c
|
||||
#, c-format
|
||||
@ -246,7 +246,7 @@ msgstr "'data'には整数の引数が必要"
|
||||
|
||||
#: py/compile.c
|
||||
msgid "'label' requires 1 argument"
|
||||
msgstr ""
|
||||
msgstr "'label'には1つの引数が必要"
|
||||
|
||||
#: py/compile.c
|
||||
msgid "'return' outside function"
|
||||
@ -296,12 +296,16 @@ msgstr "address_typeが範囲外"
|
||||
|
||||
#: ports/esp32s2/common-hal/canio/CAN.c
|
||||
msgid "All CAN peripherals are in use"
|
||||
msgstr ""
|
||||
msgstr "全てのCAN周辺機器が使用中"
|
||||
|
||||
#: ports/esp32s2/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "全てのI2C周辺機器が使用中"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -433,6 +437,11 @@ msgstr "最低のフレームレート未満"
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr "bit clockとword selectはクロックユニットを共有しなければなりません"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "ビット深度は8の倍数でなければなりません"
|
||||
@ -821,19 +830,19 @@ msgstr "%qが必要"
|
||||
#: shared-bindings/_bleio/CharacteristicBuffer.c
|
||||
#: shared-bindings/_bleio/Descriptor.c shared-bindings/_bleio/PacketBuffer.c
|
||||
msgid "Expected a Characteristic"
|
||||
msgstr ""
|
||||
msgstr "Characteristicが必要"
|
||||
|
||||
#: shared-bindings/_bleio/Adapter.c
|
||||
msgid "Expected a DigitalInOut"
|
||||
msgstr ""
|
||||
msgstr "DigitalInOutが必要"
|
||||
|
||||
#: shared-bindings/_bleio/Characteristic.c
|
||||
msgid "Expected a Service"
|
||||
msgstr ""
|
||||
msgstr "Serviceが必要"
|
||||
|
||||
#: shared-bindings/_bleio/Adapter.c
|
||||
msgid "Expected a UART"
|
||||
msgstr ""
|
||||
msgstr "UARTが必要"
|
||||
|
||||
#: shared-bindings/_bleio/Characteristic.c shared-bindings/_bleio/Descriptor.c
|
||||
#: shared-bindings/_bleio/Service.c
|
||||
@ -842,7 +851,7 @@ msgstr "UUIDが必要"
|
||||
|
||||
#: shared-bindings/_bleio/Adapter.c
|
||||
msgid "Expected an Address"
|
||||
msgstr ""
|
||||
msgstr "Addressが必要"
|
||||
|
||||
#: shared-module/_pixelbuf/PixelBuf.c
|
||||
#, c-format
|
||||
@ -886,7 +895,7 @@ msgstr "%dバイトのRXバッファの確保に失敗"
|
||||
|
||||
#: ports/esp32s2/common-hal/wifi/__init__.c
|
||||
msgid "Failed to allocate Wifi memory"
|
||||
msgstr ""
|
||||
msgstr "Wi-Fiのメモリの確保に失敗"
|
||||
|
||||
#: ports/esp32s2/common-hal/wifi/ScannedNetworks.c
|
||||
msgid "Failed to allocate wifi scan memory"
|
||||
@ -1052,7 +1061,7 @@ msgstr "不正なBMPファイル"
|
||||
|
||||
#: shared-bindings/wifi/Radio.c
|
||||
msgid "Invalid BSSID"
|
||||
msgstr ""
|
||||
msgstr "不正なBSSID"
|
||||
|
||||
#: ports/esp32s2/common-hal/analogio/AnalogOut.c
|
||||
#: ports/stm/common-hal/analogio/AnalogOut.c
|
||||
@ -1103,7 +1112,7 @@ msgstr "フォーマットチャンクのサイズが不正"
|
||||
|
||||
#: ports/esp32s2/common-hal/pwmio/PWMOut.c
|
||||
msgid "Invalid frequency"
|
||||
msgstr ""
|
||||
msgstr "不正な周波数"
|
||||
|
||||
#: ports/stm/common-hal/pwmio/PWMOut.c
|
||||
msgid "Invalid frequency supplied"
|
||||
@ -1123,7 +1132,8 @@ msgid "Invalid phase"
|
||||
msgstr "不正なphase"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "不正なピン"
|
||||
@ -1338,11 +1348,11 @@ msgstr "long integerに対応していません"
|
||||
|
||||
#: ports/esp32s2/common-hal/pwmio/PWMOut.c
|
||||
msgid "No more channels available"
|
||||
msgstr ""
|
||||
msgstr "使えるチャネルがもうありません"
|
||||
|
||||
#: ports/esp32s2/common-hal/pwmio/PWMOut.c
|
||||
msgid "No more timers available"
|
||||
msgstr ""
|
||||
msgstr "使えるタイマーがもうありません"
|
||||
|
||||
#: ports/stm/common-hal/pwmio/PWMOut.c
|
||||
msgid "No more timers available on this pin."
|
||||
@ -1658,7 +1668,7 @@ msgstr ""
|
||||
|
||||
#: ports/cxd56/common-hal/camera/Camera.c
|
||||
msgid "Size not supported"
|
||||
msgstr ""
|
||||
msgstr "サイズは対応していません"
|
||||
|
||||
#: shared-bindings/nvm/ByteArray.c
|
||||
msgid "Slice and value different lengths."
|
||||
@ -2781,7 +2791,7 @@ msgstr ""
|
||||
|
||||
#: shared-bindings/wifi/Radio.c
|
||||
msgid "invalid hostname"
|
||||
msgstr ""
|
||||
msgstr "不正なホスト名"
|
||||
|
||||
#: extmod/modussl_axtls.c
|
||||
msgid "invalid key"
|
||||
|
14
locale/ko.po
14
locale/ko.po
@ -6,7 +6,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-10-05 12:12+0000\n"
|
||||
"Last-Translator: Michal Čihař <michal@cihar.com>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
@ -298,6 +298,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "사용중인 모든 I2C주변 기기"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -429,6 +433,11 @@ msgstr ""
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr ""
|
||||
@ -1113,7 +1122,8 @@ msgid "Invalid phase"
|
||||
msgstr "단계가 잘못되었습니다"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "핀이 잘못되었습니다"
|
||||
|
14
locale/nl.po
14
locale/nl.po
@ -5,7 +5,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-10-27 16:47+0000\n"
|
||||
"Last-Translator: Jelle Jager <jell@jjc.id.au>\n"
|
||||
"Language-Team: none\n"
|
||||
@ -300,6 +300,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "Alle I2C peripherals zijn in gebruik"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -431,6 +435,11 @@ msgstr "Onder de minimum frame rate"
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr "Bit clock en word select moeten een clock eenheid delen"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "Bit diepte moet een meervoud van 8 zijn."
|
||||
@ -1125,7 +1134,8 @@ msgid "Invalid phase"
|
||||
msgstr "Ongeldige fase"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Ongeldige pin"
|
||||
|
48
locale/pl.po
48
locale/pl.po
@ -6,8 +6,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"PO-Revision-Date: 2020-09-29 01:39+0000\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-11-11 19:13+0000\n"
|
||||
"Last-Translator: Maciej Stankiewicz <tawezik@gmail.com>\n"
|
||||
"Language-Team: pl\n"
|
||||
"Language: pl\n"
|
||||
@ -16,7 +16,7 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=3; plural=n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 "
|
||||
"|| n%100>=20) ? 1 : 2;\n"
|
||||
"X-Generator: Weblate 4.3-dev\n"
|
||||
"X-Generator: Weblate 4.4-dev\n"
|
||||
|
||||
#: main.c
|
||||
msgid ""
|
||||
@ -76,7 +76,7 @@ msgstr "%q poza zakresem"
|
||||
|
||||
#: py/obj.c
|
||||
msgid "%q indices must be integers, not %q"
|
||||
msgstr ""
|
||||
msgstr "%q indeksy muszą być liczbami typu int, a nie %q"
|
||||
|
||||
#: shared-bindings/vectorio/Polygon.c
|
||||
msgid "%q list must be a list"
|
||||
@ -104,7 +104,7 @@ msgstr "%q poza zakresem"
|
||||
|
||||
#: ports/atmel-samd/common-hal/microcontroller/Pin.c
|
||||
msgid "%q pin invalid"
|
||||
msgstr ""
|
||||
msgstr "nieprawidłowy pin %q"
|
||||
|
||||
#: shared-bindings/fontio/BuiltinFont.c
|
||||
msgid "%q should be an int"
|
||||
@ -254,7 +254,7 @@ msgstr "'return' poza funkcją"
|
||||
|
||||
#: py/compile.c
|
||||
msgid "'yield from' inside async function"
|
||||
msgstr ""
|
||||
msgstr "'yield from' wewnątrz funkcji asynchronicznej"
|
||||
|
||||
#: py/compile.c
|
||||
msgid "'yield' outside function"
|
||||
@ -283,7 +283,7 @@ msgstr "Kanał przerwań sprzętowych w użyciu"
|
||||
|
||||
#: ports/esp32s2/common-hal/analogio/AnalogIn.c
|
||||
msgid "ADC2 is being used by WiFi"
|
||||
msgstr ""
|
||||
msgstr "ADC2 jest używany przez WiFi"
|
||||
|
||||
#: shared-bindings/_bleio/Address.c shared-bindings/ipaddress/IPv4Address.c
|
||||
#, c-format
|
||||
@ -302,6 +302,10 @@ msgstr ""
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "Wszystkie peryferia I2C w użyciu"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -433,6 +437,11 @@ msgstr ""
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr "Zegar bitowy i wybór słowa muszą współdzielić jednostkę zegara"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "Głębia musi być wielokrotnością 8."
|
||||
@ -1029,7 +1038,7 @@ msgstr "Błąd wewnętrzny #%d"
|
||||
|
||||
#: shared-bindings/sdioio/SDCard.c
|
||||
msgid "Invalid %q"
|
||||
msgstr ""
|
||||
msgstr "Nieprawidłowe %q"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c
|
||||
#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c
|
||||
@ -1103,7 +1112,7 @@ msgstr "Zła wielkość fragmentu formatu"
|
||||
|
||||
#: ports/esp32s2/common-hal/pwmio/PWMOut.c
|
||||
msgid "Invalid frequency"
|
||||
msgstr ""
|
||||
msgstr "Nieprawidłowa częstotliwość"
|
||||
|
||||
#: ports/stm/common-hal/pwmio/PWMOut.c
|
||||
msgid "Invalid frequency supplied"
|
||||
@ -1123,7 +1132,8 @@ msgid "Invalid phase"
|
||||
msgstr "Zła faza"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Zła nóżka"
|
||||
@ -1201,7 +1211,7 @@ msgstr ""
|
||||
|
||||
#: shared-module/displayio/Group.c
|
||||
msgid "Layer must be a Group or TileGrid subclass."
|
||||
msgstr "Layer musi dziedziczyć z Group albo TileGrid"
|
||||
msgstr "Layer musi dziedziczyć z Group albo TileGrid."
|
||||
|
||||
#: py/objslice.c
|
||||
msgid "Length must be an int"
|
||||
@ -1339,7 +1349,7 @@ msgstr ""
|
||||
|
||||
#: ports/esp32s2/common-hal/pwmio/PWMOut.c
|
||||
msgid "No more channels available"
|
||||
msgstr ""
|
||||
msgstr "Brak dostępnych kanałów"
|
||||
|
||||
#: ports/esp32s2/common-hal/pwmio/PWMOut.c
|
||||
msgid "No more timers available"
|
||||
@ -1431,7 +1441,7 @@ msgstr ""
|
||||
|
||||
#: shared-module/displayio/ColorConverter.c
|
||||
msgid "Only one color can be transparent at a time"
|
||||
msgstr ""
|
||||
msgstr "W danym momencie przezroczysty może być tylko jeden kolor"
|
||||
|
||||
#: shared-bindings/ipaddress/__init__.c
|
||||
msgid "Only raw int supported for ip"
|
||||
@ -1500,7 +1510,7 @@ msgstr "Oraz moduły w systemie plików\n"
|
||||
|
||||
#: shared-module/vectorio/Polygon.c
|
||||
msgid "Polygon needs at least 3 points"
|
||||
msgstr ""
|
||||
msgstr "Wielokąt musi mieć co najmniej 3 punkty"
|
||||
|
||||
#: ports/esp32s2/common-hal/pulseio/PulseOut.c
|
||||
msgid ""
|
||||
@ -1812,7 +1822,7 @@ msgstr ""
|
||||
|
||||
#: ports/stm/common-hal/busio/UART.c
|
||||
msgid "UART write error"
|
||||
msgstr ""
|
||||
msgstr "Błąd zapisu UART"
|
||||
|
||||
#: shared-module/usb_hid/Device.c
|
||||
msgid "USB Busy"
|
||||
@ -2009,7 +2019,7 @@ msgstr "__init__() powinien zwracać None"
|
||||
|
||||
#: py/objtype.c
|
||||
msgid "__init__() should return None, not '%q'"
|
||||
msgstr ""
|
||||
msgstr "__init__() powinno zwrócić None, a nie '%q'"
|
||||
|
||||
#: py/objobject.c
|
||||
msgid "__new__ arg must be a user-type"
|
||||
@ -3052,11 +3062,11 @@ msgstr "nie dość argumentów przy formatowaniu"
|
||||
|
||||
#: extmod/ulab/code/poly/poly.c
|
||||
msgid "number of arguments must be 2, or 3"
|
||||
msgstr ""
|
||||
msgstr "liczba argumentów musi wynosić 2 lub 3"
|
||||
|
||||
#: extmod/ulab/code/ulab_create.c
|
||||
msgid "number of points must be at least 2"
|
||||
msgstr ""
|
||||
msgstr "liczba punktów musi wynosić co najmniej 2"
|
||||
|
||||
#: py/obj.c
|
||||
msgid "object '%q' is not a tuple or list"
|
||||
@ -3369,7 +3379,7 @@ msgstr ""
|
||||
|
||||
#: shared-bindings/displayio/Bitmap.c
|
||||
msgid "source palette too large"
|
||||
msgstr ""
|
||||
msgstr "źródłowa paleta jest zbyt duża"
|
||||
|
||||
#: py/objstr.c
|
||||
msgid "start/end indices"
|
||||
|
@ -5,8 +5,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"PO-Revision-Date: 2020-10-28 21:45+0000\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-11-08 10:26+0000\n"
|
||||
"Last-Translator: Wellington Terumi Uemura <wellingtonuemura@gmail.com>\n"
|
||||
"Language-Team: \n"
|
||||
"Language: pt_BR\n"
|
||||
@ -14,7 +14,7 @@ msgstr ""
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=n > 1;\n"
|
||||
"X-Generator: Weblate 4.3.2-dev\n"
|
||||
"X-Generator: Weblate 4.3.2\n"
|
||||
|
||||
#: main.c
|
||||
msgid ""
|
||||
@ -304,6 +304,10 @@ msgstr "Todos os periféricos CAN estão em uso"
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "Todos os periféricos I2C estão em uso"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr "Todas as unidades PCNT estão em uso"
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -439,6 +443,11 @@ msgstr ""
|
||||
"O clock de bits e a seleção de palavras devem compartilhar uma unidade de "
|
||||
"clock"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "A profundidade de bits deve ser o múltiplo de 8."
|
||||
@ -1134,7 +1143,8 @@ msgid "Invalid phase"
|
||||
msgstr "Fase Inválida"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Pino inválido"
|
||||
|
24
locale/sv.po
24
locale/sv.po
@ -5,8 +5,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"PO-Revision-Date: 2020-11-01 16:26+0000\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-11-05 20:26+0000\n"
|
||||
"Last-Translator: Jonny Bergdahl <jonny@bergdahl.it>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"Language: sv\n"
|
||||
@ -14,7 +14,7 @@ msgstr ""
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
"X-Generator: Weblate 4.3.2-dev\n"
|
||||
"X-Generator: Weblate 4.3.2\n"
|
||||
|
||||
#: main.c
|
||||
msgid ""
|
||||
@ -300,6 +300,10 @@ msgstr "All I2C-kringutrustning används"
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "All I2C-kringutrustning används"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr ""
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -415,8 +419,8 @@ msgid ""
|
||||
"Auto-reload is on. Simply save files over USB to run them or enter REPL to "
|
||||
"disable.\n"
|
||||
msgstr ""
|
||||
"Autoladdning är på. Spara bara filer via USB för att köra dem eller ange "
|
||||
"REPL för att inaktivera.\n"
|
||||
"Autoladdning är på. Spara filer via USB för att köra dem eller ange REPL för "
|
||||
"att inaktivera.\n"
|
||||
|
||||
#: ports/esp32s2/common-hal/canio/CAN.c
|
||||
msgid "Baudrate not supported by peripheral"
|
||||
@ -431,6 +435,11 @@ msgstr "Under minsta bildfrekvens"
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr "Bitklocka och ordval måste dela en klockenhet"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "Bitdjup måste vara multipel av 8."
|
||||
@ -1123,7 +1132,8 @@ msgid "Invalid phase"
|
||||
msgstr "Ogiltig fas"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Ogiltig pinne"
|
||||
@ -2220,7 +2230,7 @@ msgstr "kan bara ha upp till 4 parametrar att Xtensa assembly"
|
||||
|
||||
#: py/persistentcode.c
|
||||
msgid "can only save bytecode"
|
||||
msgstr "kan bara spara bytekod"
|
||||
msgstr "kan bara spara bytecode"
|
||||
|
||||
#: py/objtype.c
|
||||
msgid "can't add special method to already-subclassed class"
|
||||
|
@ -6,8 +6,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: circuitpython-cn\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-10-21 20:13-0500\n"
|
||||
"PO-Revision-Date: 2020-10-28 21:45+0000\n"
|
||||
"POT-Creation-Date: 2020-11-04 21:18+0530\n"
|
||||
"PO-Revision-Date: 2020-11-11 19:13+0000\n"
|
||||
"Last-Translator: hexthat <hexthat@gmail.com>\n"
|
||||
"Language-Team: Chinese Hanyu Pinyin\n"
|
||||
"Language: zh_Latn_pinyin\n"
|
||||
@ -15,7 +15,7 @@ msgstr ""
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Weblate 4.3.2-dev\n"
|
||||
"X-Generator: Weblate 4.4-dev\n"
|
||||
|
||||
#: main.c
|
||||
msgid ""
|
||||
@ -302,6 +302,10 @@ msgstr "suǒ yǒu CAN wài shè dōu zài shǐ yòng zhōng"
|
||||
msgid "All I2C peripherals are in use"
|
||||
msgstr "Suǒyǒu I2C wàiwéi qì zhèngzài shǐyòng"
|
||||
|
||||
#: ports/esp32s2/peripherals/pcnt_handler.c
|
||||
msgid "All PCNT units in use"
|
||||
msgstr "suǒ yǒu zhèng zài shǐ yòng zhōng de PCNT dān yuán"
|
||||
|
||||
#: ports/atmel-samd/common-hal/canio/Listener.c
|
||||
#: ports/esp32s2/common-hal/canio/Listener.c
|
||||
#: ports/stm/common-hal/canio/Listener.c
|
||||
@ -433,6 +437,11 @@ msgstr "Dī yú zuìdī zhèng sùlǜ"
|
||||
msgid "Bit clock and word select must share a clock unit"
|
||||
msgstr "Bǐtè shízhōng hé dānzì xuǎnzé bìxū gòngxiǎng shízhōng dānwèi"
|
||||
|
||||
#: shared-bindings/rgbmatrix/RGBMatrix.c
|
||||
#, c-format
|
||||
msgid "Bit depth must be from 1 to 6 inclusive, not %d"
|
||||
msgstr ""
|
||||
|
||||
#: shared-bindings/audiobusio/PDMIn.c
|
||||
msgid "Bit depth must be multiple of 8."
|
||||
msgstr "Bǐtè shēndù bìxū shì 8 bèi yǐshàng."
|
||||
@ -1121,7 +1130,8 @@ msgid "Invalid phase"
|
||||
msgstr "Jiēduàn wúxiào"
|
||||
|
||||
#: ports/atmel-samd/common-hal/audioio/AudioOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: ports/atmel-samd/common-hal/touchio/TouchIn.c
|
||||
#: ports/esp32s2/common-hal/touchio/TouchIn.c shared-bindings/pwmio/PWMOut.c
|
||||
#: shared-module/rgbmatrix/RGBMatrix.c
|
||||
msgid "Invalid pin"
|
||||
msgstr "Wúxiào de yǐn jiǎo"
|
||||
|
@ -12,11 +12,15 @@ EXTERNAL_FLASH_DEVICE_COUNT = 1
|
||||
EXTERNAL_FLASH_DEVICES = "GD25Q32C"
|
||||
LONGINT_IMPL = MPZ
|
||||
|
||||
CIRCUITPY_FULLBUILD = 0
|
||||
CIRCUITPY_BITBANGIO = 0
|
||||
CIRCUITPY_FREQUENCYIO = 0
|
||||
CIRCUITPY_COUNTIO = 0
|
||||
CIRCUITPY_I2CPERIPHERAL = 0
|
||||
CIRCUITPY_I2CPERIPHERAL = 1
|
||||
CIRCUITPY_VECTORIO = 0
|
||||
CIRCUITPY_DISPLAYIO = 0
|
||||
CIRCUITPY_TOUCHIO = 0
|
||||
CIRCUITPY_ROTARYIO = 0
|
||||
|
||||
CFLAGS_INLINE_LIMIT = 60
|
||||
|
||||
|
@ -4,17 +4,17 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_SCK), MP_ROM_PTR(&pin_PB11) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_MOSI), MP_ROM_PTR(&pin_PA12) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_MISO), MP_ROM_PTR(&pin_PB10) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D30), MP_ROM_PTR(&pin_PA30) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D31), MP_ROM_PTR(&pin_PA31) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D26), MP_ROM_PTR(&pin_PA30) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D27), MP_ROM_PTR(&pin_PA31) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_RX), MP_ROM_PTR(&pin_PA17) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D0), MP_ROM_PTR(&pin_PA07) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_OVTEMP), MP_ROM_PTR(&pin_PA07) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_TX), MP_ROM_PTR(&pin_PA16) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_PA08) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_PA09) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D1), MP_ROM_PTR(&pin_PA11) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D2), MP_ROM_PTR(&pin_PA11) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_SAT_RESET), MP_ROM_PTR(&pin_PA11) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D2), MP_ROM_PTR(&pin_PA10) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D1), MP_ROM_PTR(&pin_PA10) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_SAT_PWR_ENABLE), MP_ROM_PTR(&pin_PA10) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D3), MP_ROM_PTR(&pin_PA19) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_INT_IMU_OBC), MP_ROM_PTR(&pin_PA19) },
|
||||
@ -22,10 +22,17 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_PWRMON_SDA), MP_ROM_PTR(&pin_PA04) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_PWRMON_SCL), MP_ROM_PTR(&pin_PA05) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_PWRMON_ALERT), MP_ROM_PTR(&pin_PB03) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_A0), MP_ROM_PTR(&pin_PB09) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_A1), MP_ROM_PTR(&pin_PB02) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_V_3V3_MEAS), MP_ROM_PTR(&pin_PB09) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_V_5V_MEAS), MP_ROM_PTR(&pin_PB02) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_FLASH_SCK), MP_ROM_PTR(&pin_PA23) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_FLASH_MOSI), MP_ROM_PTR(&pin_PA22) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_FLASH_MISO), MP_ROM_PTR(&pin_PA21) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_FLASH_CS), MP_ROM_PTR(&pin_PA20) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D13), MP_ROM_PTR(&pin_PA06) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_PA06) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&board_i2c_obj) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_I2C_MONITOR), MP_ROM_PTR(&board_i2c_obj) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_SPI), MP_ROM_PTR(&board_spi_obj) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_UART), MP_ROM_PTR(&board_uart_obj) },
|
||||
};
|
||||
|
@ -26,12 +26,16 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_D7), MP_ROM_PTR(&pin_PB07) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D8), MP_ROM_PTR(&pin_PB06) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D9), MP_ROM_PTR(&pin_PB30) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D10), MP_ROM_PTR(&pin_PA12) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D11), MP_ROM_PTR(&pin_PA15) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D12), MP_ROM_PTR(&pin_PB00) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D13), MP_ROM_PTR(&pin_PA08) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D32), MP_ROM_PTR(&pin_PA30) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D33), MP_ROM_PTR(&pin_PA31) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_SD_CS), MP_ROM_PTR(&pin_PB22) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_INT_IMU), MP_ROM_PTR(&pin_PA12) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_SAT_POWER), MP_ROM_PTR(&pin_PA15) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_OVTEMP), MP_ROM_PTR(&pin_PB00) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_PA08) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&board_i2c_obj) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_SPI), MP_ROM_PTR(&board_spi_obj) },
|
||||
|
@ -33,6 +33,10 @@
|
||||
#define DEFAULT_UART_BUS_RX (&pin_PA11)
|
||||
#define DEFAULT_UART_BUS_TX (&pin_PA10)
|
||||
|
||||
// These pins are connected to the external crystal.
|
||||
#define IGNORE_PIN_PA00 1
|
||||
#define IGNORE_PIN_PA01 1
|
||||
|
||||
// USB is always used internally so skip the pin objects for it.
|
||||
#define IGNORE_PIN_PA24 1
|
||||
#define IGNORE_PIN_PA25 1
|
||||
|
@ -326,7 +326,7 @@ static void setup_dma(audiobusio_pdmin_obj_t* self, uint32_t length,
|
||||
// higher sample rate than specified. Then after the audio is
|
||||
// recorded, a more expensive filter non-real-time filter could be
|
||||
// used to down-sample and low-pass.
|
||||
uint16_t sinc_filter [OVERSAMPLING] = {
|
||||
const uint16_t sinc_filter [OVERSAMPLING] = {
|
||||
0, 2, 9, 21, 39, 63, 94, 132,
|
||||
179, 236, 302, 379, 467, 565, 674, 792,
|
||||
920, 1055, 1196, 1341, 1487, 1633, 1776, 1913,
|
||||
|
@ -129,7 +129,8 @@ bool common_hal_displayio_parallelbus_begin_transaction(mp_obj_t obj) {
|
||||
return true;
|
||||
}
|
||||
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length) {
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length) {
|
||||
displayio_parallelbus_obj_t* self = MP_OBJ_TO_PTR(obj);
|
||||
common_hal_digitalio_digitalinout_set_value(&self->command, byte_type == DISPLAY_DATA);
|
||||
uint32_t* clear_write = (uint32_t*) &self->write_group->OUTCLR.reg;
|
||||
|
@ -47,6 +47,7 @@
|
||||
// MICROPY_PY_UJSON depends on MICROPY_PY_IO
|
||||
#define MICROPY_PY_IO (0)
|
||||
#define MICROPY_PY_REVERSE_SPECIAL_METHODS (0)
|
||||
#define MICROPY_PY_UBINASCII (0)
|
||||
#define MICROPY_PY_UJSON (0)
|
||||
#define MICROPY_PY_COLLECTIONS_ORDEREDDICT (0)
|
||||
#define MICROPY_PY_UERRNO_LIST \
|
||||
|
@ -188,6 +188,7 @@ SRC_C += \
|
||||
lib/utils/pyexec.c \
|
||||
lib/utils/stdout_helpers.c \
|
||||
lib/utils/sys_stdio_mphal.c \
|
||||
peripherals/pcnt.c \
|
||||
peripherals/pins.c \
|
||||
peripherals/rmt.c \
|
||||
supervisor/shared/memory.c
|
||||
|
169
ports/esp32s2/boards/adafruit_magtag_2.9_grayscale/board.c
Normal file
169
ports/esp32s2/boards/adafruit_magtag_2.9_grayscale/board.c
Normal file
@ -0,0 +1,169 @@
|
||||
/*
|
||||
* This file is part of the MicroPython project, http://micropython.org/
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2020 Scott Shawcroft for Adafruit Industries
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include "boards/board.h"
|
||||
#include "mpconfigboard.h"
|
||||
#include "shared-bindings/busio/SPI.h"
|
||||
#include "shared-bindings/displayio/FourWire.h"
|
||||
#include "shared-bindings/microcontroller/Pin.h"
|
||||
#include "shared-module/displayio/__init__.h"
|
||||
#include "supervisor/shared/board.h"
|
||||
|
||||
#define DELAY 0x80
|
||||
|
||||
// This is an ILO373 control chip. The display is a 2.9" grayscale EInk.
|
||||
|
||||
const uint8_t display_start_sequence[] = {
|
||||
0x01, 5, 0x03, 0x00, 0x2b, 0x2b, 0x13, // power setting
|
||||
0x06, 3, 0x17, 0x17, 0x17, // booster soft start
|
||||
0x04, DELAY, 200, // power on and wait 200 ms
|
||||
0x00, 1, 0x7f, // panel setting
|
||||
0x50, 1, 0x97, // CDI setting
|
||||
0x30, 1, 0x3c, // PLL set to 50 Hx (M = 7, N = 4)
|
||||
0x61, 3, 0x80, 0x01, 0x28, // Resolution
|
||||
0x82, DELAY | 1, 0x12, 50, // VCM DC and delay 50ms
|
||||
|
||||
// Look up tables for voltage sequence for pixel transition
|
||||
// Common voltage
|
||||
0x20, 0x2a,
|
||||
0x00, 0x0a, 0x00, 0x00, 0x00, 0x01,
|
||||
0x60, 0x14, 0x14, 0x00, 0x00, 0x01,
|
||||
0x00, 0x14, 0x00, 0x00, 0x00, 0x01,
|
||||
0x00, 0x13, 0x0a, 0x01, 0x00, 0x01,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
|
||||
// White to white
|
||||
0x21, 0x2a,
|
||||
0x40, 0x0a, 0x00, 0x00, 0x00, 0x01,
|
||||
0x90, 0x14, 0x14, 0x00, 0x00, 0x01,
|
||||
0x10, 0x14, 0x0a, 0x00, 0x00, 0x01,
|
||||
0xa0, 0x13, 0x01, 0x00, 0x00, 0x01,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
|
||||
// Black to white
|
||||
0x22, 0x2a,
|
||||
0x40, 0x0a, 0x00, 0x00, 0x00, 0x01,
|
||||
0x90, 0x14, 0x14, 0x00, 0x00, 0x01,
|
||||
0x00, 0x14, 0x0a, 0x00, 0x00, 0x01,
|
||||
0x99, 0x0c, 0x01, 0x03, 0x04, 0x01,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
|
||||
// White to black
|
||||
0x23, 0x2a,
|
||||
0x40, 0x0a, 0x00, 0x00, 0x00, 0x01,
|
||||
0x90, 0x14, 0x14, 0x00, 0x00, 0x01,
|
||||
0x00, 0x14, 0x0a, 0x00, 0x00, 0x01,
|
||||
0x99, 0x0b, 0x04, 0x04, 0x01, 0x01,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
|
||||
// Black to black
|
||||
0x24, 0x2a,
|
||||
0x80, 0x0a, 0x00, 0x00, 0x00, 0x01,
|
||||
0x90, 0x14, 0x14, 0x00, 0x00, 0x01,
|
||||
0x20, 0x14, 0x0a, 0x00, 0x00, 0x01,
|
||||
0x50, 0x13, 0x01, 0x00, 0x00, 0x01,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00
|
||||
};
|
||||
|
||||
const uint8_t display_stop_sequence[] = {
|
||||
0x50, 0x01, 0x17, // CDI Setting
|
||||
0x82, 0x01, 0x00, // VCM DC to -0.1V
|
||||
0x02, 0x00 // Power off
|
||||
};
|
||||
|
||||
void board_init(void) {
|
||||
// USB
|
||||
common_hal_never_reset_pin(&pin_GPIO19);
|
||||
common_hal_never_reset_pin(&pin_GPIO20);
|
||||
|
||||
// Debug UART
|
||||
common_hal_never_reset_pin(&pin_GPIO43);
|
||||
common_hal_never_reset_pin(&pin_GPIO44);
|
||||
|
||||
busio_spi_obj_t* spi = &displays[0].fourwire_bus.inline_bus;
|
||||
common_hal_busio_spi_construct(spi, &pin_GPIO36, &pin_GPIO35, NULL);
|
||||
common_hal_busio_spi_never_reset(spi);
|
||||
|
||||
displayio_fourwire_obj_t* bus = &displays[0].fourwire_bus;
|
||||
bus->base.type = &displayio_fourwire_type;
|
||||
common_hal_displayio_fourwire_construct(bus,
|
||||
spi,
|
||||
&pin_GPIO7, // EPD_DC Command or data
|
||||
&pin_GPIO8, // EPD_CS Chip select
|
||||
&pin_GPIO6, // EPD_RST Reset
|
||||
4000000, // Baudrate
|
||||
0, // Polarity
|
||||
0); // Phase
|
||||
|
||||
displayio_epaperdisplay_obj_t* display = &displays[0].epaper_display;
|
||||
display->base.type = &displayio_epaperdisplay_type;
|
||||
common_hal_displayio_epaperdisplay_construct(
|
||||
display,
|
||||
bus,
|
||||
display_start_sequence, sizeof(display_start_sequence),
|
||||
display_stop_sequence, sizeof(display_stop_sequence),
|
||||
296, // width
|
||||
128, // height
|
||||
160, // ram_width
|
||||
296, // ram_height
|
||||
0, // colstart
|
||||
0, // rowstart
|
||||
270, // rotation
|
||||
NO_COMMAND, // set_column_window_command
|
||||
NO_COMMAND, // set_row_window_command
|
||||
NO_COMMAND, // set_current_column_command
|
||||
NO_COMMAND, // set_current_row_command
|
||||
0x10, // write_black_ram_command
|
||||
false, // black_bits_inverted
|
||||
0x13, // write_color_ram_command
|
||||
false, // color_bits_inverted
|
||||
0x000000, // highlight_color
|
||||
0x12, // refresh_display_command
|
||||
1.0, // refresh_time
|
||||
&pin_GPIO5, // busy_pin
|
||||
false, // busy_state
|
||||
5.0, // seconds_per_frame
|
||||
false, // always_toggle_chip_select
|
||||
true); // grayscale
|
||||
}
|
||||
|
||||
bool board_requests_safe_mode(void) {
|
||||
return false;
|
||||
}
|
||||
|
||||
void reset_board(void) {
|
||||
|
||||
}
|
@ -26,7 +26,7 @@
|
||||
|
||||
//Micropython setup
|
||||
|
||||
#define MICROPY_HW_BOARD_NAME "EInk Portal"
|
||||
#define MICROPY_HW_BOARD_NAME "MagTag"
|
||||
#define MICROPY_HW_MCU_NAME "ESP32S2"
|
||||
|
||||
#define MICROPY_HW_NEOPIXEL (&pin_GPIO1)
|
@ -1,6 +1,6 @@
|
||||
USB_VID = 0x239A
|
||||
USB_PID = 0x80E6
|
||||
USB_PRODUCT = "EInk Portal"
|
||||
USB_PRODUCT = "MagTag"
|
||||
USB_MANUFACTURER = "Adafruit"
|
||||
|
||||
INTERNAL_FLASH_FILESYSTEM = 1
|
@ -1,5 +1,7 @@
|
||||
#include "shared-bindings/board/__init__.h"
|
||||
|
||||
#include "shared-module/displayio/__init__.h"
|
||||
|
||||
STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_D10), MP_ROM_PTR(&pin_GPIO10) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_AD1), MP_ROM_PTR(&pin_GPIO18) },
|
||||
@ -37,5 +39,7 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
|
||||
|
||||
{ MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&board_i2c_obj) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_SPI), MP_ROM_PTR(&board_spi_obj) },
|
||||
|
||||
{ MP_ROM_QSTR(MP_QSTR_DISPLAY), MP_ROM_PTR(&displays[0].epaper_display)}
|
||||
};
|
||||
MP_DEFINE_CONST_DICT(board_module_globals, board_global_dict_table);
|
@ -25,7 +25,6 @@
|
||||
*/
|
||||
|
||||
//Micropython setup
|
||||
|
||||
#define MICROPY_HW_BOARD_NAME "microS2"
|
||||
#define MICROPY_HW_MCU_NAME "ESP32S2"
|
||||
|
||||
@ -33,8 +32,20 @@
|
||||
#define MICROPY_HW_BUTTON (&pin_GPIO0)
|
||||
#define MICROPY_HW_NEOPIXEL (&pin_GPIO33)
|
||||
|
||||
// Default bus pins
|
||||
#define DEFAULT_I2C_BUS_SCL (&pin_GPIO1)
|
||||
#define DEFAULT_I2C_BUS_SDA (&pin_GPIO2)
|
||||
|
||||
#define DEFAULT_SPI_BUS_SCK (&pin_GPIO36)
|
||||
#define DEFAULT_SPI_BUS_MOSI (&pin_GPIO35)
|
||||
#define DEFAULT_SPI_BUS_MISO (&pin_GPIO37)
|
||||
|
||||
#define DEFAULT_UART_BUS_TX (&pin_GPIO43)
|
||||
#define DEFAULT_UART_BUS_RX (&pin_GPIO44)
|
||||
|
||||
#define CIRCUITPY_BOOT_BUTTON (&pin_GPIO0)
|
||||
|
||||
// Explanation of how a user got into safe mode.
|
||||
#define BOARD_USER_SAFE_MODE_ACTION translate("pressing boot button at start up.\n")
|
||||
|
||||
#define AUTORESET_DELAY_MS 500
|
||||
|
@ -37,3 +37,13 @@
|
||||
|
||||
// #define MICROPY_HW_APA102_MOSI (&pin_GPIO40)
|
||||
// #define MICROPY_HW_APA102_SCK (&pin_GPIO45)
|
||||
|
||||
#define DEFAULT_I2C_BUS_SCL (&pin_GPIO9)
|
||||
#define DEFAULT_I2C_BUS_SDA (&pin_GPIO8)
|
||||
|
||||
#define DEFAULT_SPI_BUS_SCK (&pin_GPIO36)
|
||||
#define DEFAULT_SPI_BUS_MOSI (&pin_GPIO35)
|
||||
#define DEFAULT_SPI_BUS_MISO (&pin_GPIO37)
|
||||
|
||||
#define DEFAULT_UART_BUS_RX (&pin_GPIO44)
|
||||
#define DEFAULT_UART_BUS_TX (&pin_GPIO43)
|
||||
|
84
ports/esp32s2/common-hal/countio/Counter.c
Normal file
84
ports/esp32s2/common-hal/countio/Counter.c
Normal file
@ -0,0 +1,84 @@
|
||||
/*
|
||||
* This file is part of the MicroPython project, http://micropython.org/
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2020 microDev
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include "common-hal/countio/Counter.h"
|
||||
#include "common-hal/microcontroller/Pin.h"
|
||||
|
||||
#include "py/runtime.h"
|
||||
#include "supervisor/shared/translate.h"
|
||||
|
||||
void common_hal_countio_counter_construct(countio_counter_obj_t* self,
|
||||
const mcu_pin_obj_t* pin) {
|
||||
claim_pin(pin);
|
||||
|
||||
// Prepare configuration for the PCNT unit
|
||||
const pcnt_config_t pcnt_config = {
|
||||
// Set PCNT input signal and control GPIOs
|
||||
.pulse_gpio_num = pin->number,
|
||||
.ctrl_gpio_num = PCNT_PIN_NOT_USED,
|
||||
.channel = PCNT_CHANNEL_0,
|
||||
// What to do on the positive / negative edge of pulse input?
|
||||
.pos_mode = PCNT_COUNT_INC, // Count up on the positive edge
|
||||
.neg_mode = PCNT_COUNT_DIS, // Keep the counter value on the negative edge
|
||||
};
|
||||
|
||||
// Initialize PCNT unit
|
||||
const int8_t unit = peripherals_pcnt_init(pcnt_config);
|
||||
if (unit == -1) {
|
||||
mp_raise_RuntimeError(translate("All PCNT units in use"));
|
||||
}
|
||||
|
||||
self->pin = pin->number;
|
||||
self->unit = (pcnt_unit_t)unit;
|
||||
}
|
||||
|
||||
bool common_hal_countio_counter_deinited(countio_counter_obj_t* self) {
|
||||
return self->unit == PCNT_UNIT_MAX;
|
||||
}
|
||||
|
||||
void common_hal_countio_counter_deinit(countio_counter_obj_t* self) {
|
||||
if (common_hal_countio_counter_deinited(self)) {
|
||||
return;
|
||||
}
|
||||
reset_pin_number(self->pin);
|
||||
peripherals_pcnt_deinit(&self->unit);
|
||||
}
|
||||
|
||||
mp_int_t common_hal_countio_counter_get_count(countio_counter_obj_t* self) {
|
||||
int16_t count;
|
||||
pcnt_get_counter_value(self->unit, &count);
|
||||
return count+self->count;
|
||||
}
|
||||
|
||||
void common_hal_countio_counter_set_count(countio_counter_obj_t* self,
|
||||
mp_int_t new_count) {
|
||||
self->count = new_count;
|
||||
pcnt_counter_clear(self->unit);
|
||||
}
|
||||
|
||||
void common_hal_countio_counter_reset(countio_counter_obj_t* self) {
|
||||
common_hal_countio_counter_set_count(self, 0);
|
||||
}
|
@ -3,7 +3,7 @@
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2020 Scott Shawcroft for Adafruit Industries
|
||||
* Copyright (c) 2020 microDev
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@ -24,24 +24,17 @@
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include "boards/board.h"
|
||||
#include "mpconfigboard.h"
|
||||
#include "shared-bindings/microcontroller/Pin.h"
|
||||
#ifndef MICROPY_INCLUDED_ESP32S2_COMMON_HAL_COUNTIO_COUNTER_H
|
||||
#define MICROPY_INCLUDED_ESP32S2_COMMON_HAL_COUNTIO_COUNTER_H
|
||||
|
||||
void board_init(void) {
|
||||
// USB
|
||||
common_hal_never_reset_pin(&pin_GPIO19);
|
||||
common_hal_never_reset_pin(&pin_GPIO20);
|
||||
#include "py/obj.h"
|
||||
#include "peripherals/pcnt.h"
|
||||
|
||||
// Debug UART
|
||||
common_hal_never_reset_pin(&pin_GPIO43);
|
||||
common_hal_never_reset_pin(&pin_GPIO44);
|
||||
}
|
||||
typedef struct {
|
||||
mp_obj_base_t base;
|
||||
uint8_t pin;
|
||||
mp_int_t count;
|
||||
pcnt_unit_t unit;
|
||||
} countio_counter_obj_t;
|
||||
|
||||
bool board_requests_safe_mode(void) {
|
||||
return false;
|
||||
}
|
||||
|
||||
void reset_board(void) {
|
||||
|
||||
}
|
||||
#endif // MICROPY_INCLUDED_ESP32S2_COMMON_HAL_COUNTIO_COUNT_H
|
1
ports/esp32s2/common-hal/countio/__init__.c
Normal file
1
ports/esp32s2/common-hal/countio/__init__.c
Normal file
@ -0,0 +1 @@
|
||||
//No countio module functions
|
@ -57,7 +57,8 @@ bool common_hal_displayio_parallelbus_begin_transaction(mp_obj_t obj) {
|
||||
return false;
|
||||
}
|
||||
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length) {
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length) {
|
||||
|
||||
}
|
||||
|
||||
|
86
ports/esp32s2/common-hal/rotaryio/IncrementalEncoder.c
Normal file
86
ports/esp32s2/common-hal/rotaryio/IncrementalEncoder.c
Normal file
@ -0,0 +1,86 @@
|
||||
/*
|
||||
* This file is part of the MicroPython project, http://micropython.org/
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2020 microDev
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include "common-hal/rotaryio/IncrementalEncoder.h"
|
||||
#include "common-hal/microcontroller/Pin.h"
|
||||
|
||||
#include "py/runtime.h"
|
||||
#include "supervisor/shared/translate.h"
|
||||
|
||||
void common_hal_rotaryio_incrementalencoder_construct(rotaryio_incrementalencoder_obj_t* self,
|
||||
const mcu_pin_obj_t* pin_a, const mcu_pin_obj_t* pin_b) {
|
||||
claim_pin(pin_a);
|
||||
claim_pin(pin_b);
|
||||
|
||||
// Prepare configuration for the PCNT unit
|
||||
const pcnt_config_t pcnt_config = {
|
||||
// Set PCNT input signal and control GPIOs
|
||||
.pulse_gpio_num = pin_a->number,
|
||||
.ctrl_gpio_num = pin_b->number,
|
||||
.channel = PCNT_CHANNEL_0,
|
||||
// What to do on the positive / negative edge of pulse input?
|
||||
.pos_mode = PCNT_COUNT_DEC, // Count up on the positive edge
|
||||
.neg_mode = PCNT_COUNT_INC, // Keep the counter value on the negative edge
|
||||
// What to do when control input is low or high?
|
||||
.lctrl_mode = PCNT_MODE_REVERSE, // Reverse counting direction if low
|
||||
.hctrl_mode = PCNT_MODE_KEEP, // Keep the primary counter mode if high
|
||||
};
|
||||
|
||||
// Initialize PCNT unit
|
||||
const int8_t unit = peripherals_pcnt_init(pcnt_config);
|
||||
if (unit == -1) {
|
||||
mp_raise_RuntimeError(translate("All PCNT units in use"));
|
||||
}
|
||||
|
||||
self->pin_a = pin_a->number;
|
||||
self->pin_b = pin_b->number;
|
||||
self->unit = (pcnt_unit_t)unit;
|
||||
}
|
||||
|
||||
bool common_hal_rotaryio_incrementalencoder_deinited(rotaryio_incrementalencoder_obj_t* self) {
|
||||
return self->unit == PCNT_UNIT_MAX;
|
||||
}
|
||||
|
||||
void common_hal_rotaryio_incrementalencoder_deinit(rotaryio_incrementalencoder_obj_t* self) {
|
||||
if (common_hal_rotaryio_incrementalencoder_deinited(self)) {
|
||||
return;
|
||||
}
|
||||
reset_pin_number(self->pin_a);
|
||||
reset_pin_number(self->pin_b);
|
||||
peripherals_pcnt_deinit(&self->unit);
|
||||
}
|
||||
|
||||
mp_int_t common_hal_rotaryio_incrementalencoder_get_position(rotaryio_incrementalencoder_obj_t* self) {
|
||||
int16_t count;
|
||||
pcnt_get_counter_value(self->unit, &count);
|
||||
return (count/2)+self->position;
|
||||
}
|
||||
|
||||
void common_hal_rotaryio_incrementalencoder_set_position(rotaryio_incrementalencoder_obj_t* self,
|
||||
mp_int_t new_position) {
|
||||
self->position = new_position;
|
||||
pcnt_counter_clear(self->unit);
|
||||
}
|
40
ports/esp32s2/common-hal/rotaryio/IncrementalEncoder.h
Normal file
40
ports/esp32s2/common-hal/rotaryio/IncrementalEncoder.h
Normal file
@ -0,0 +1,40 @@
|
||||
/*
|
||||
* This file is part of the MicroPython project, http://micropython.org/
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2020 microDev
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef MICROPY_INCLUDED_ESP32S2_COMMON_HAL_ROTARYIO_INCREMENTALENCODER_H
|
||||
#define MICROPY_INCLUDED_ESP32S2_COMMON_HAL_ROTARYIO_INCREMENTALENCODER_H
|
||||
|
||||
#include "py/obj.h"
|
||||
#include "peripherals/pcnt.h"
|
||||
|
||||
typedef struct {
|
||||
mp_obj_base_t base;
|
||||
uint8_t pin_a, pin_b;
|
||||
mp_int_t position;
|
||||
pcnt_unit_t unit;
|
||||
} rotaryio_incrementalencoder_obj_t;
|
||||
|
||||
#endif // MICROPY_INCLUDED_ESP32S2_COMMON_HAL_ROTARYIO_INCREMENTALENCODER_H
|
1
ports/esp32s2/common-hal/rotaryio/__init__.c
Normal file
1
ports/esp32s2/common-hal/rotaryio/__init__.c
Normal file
@ -0,0 +1 @@
|
||||
// No rotaryio module functions.
|
@ -79,15 +79,15 @@ mp_uint_t common_hal_socketpool_socket_send(socketpool_socket_obj_t* self, const
|
||||
|
||||
mp_uint_t common_hal_socketpool_socket_recv_into(socketpool_socket_obj_t* self, const uint8_t* buf, mp_uint_t len) {
|
||||
size_t received = 0;
|
||||
ssize_t last_read = 1;
|
||||
int status = 0;
|
||||
uint64_t start_ticks = supervisor_ticks_ms64();
|
||||
int sockfd;
|
||||
esp_err_t err = esp_tls_get_conn_sockfd(self->tcp, &sockfd);
|
||||
if (err != ESP_OK) {
|
||||
mp_raise_OSError(MP_EBADF);
|
||||
}
|
||||
while (received < len &&
|
||||
last_read > 0 &&
|
||||
while (received == 0 &&
|
||||
status >= 0 &&
|
||||
(self->timeout_ms == 0 || supervisor_ticks_ms64() - start_ticks <= self->timeout_ms) &&
|
||||
!mp_hal_is_interrupted()) {
|
||||
RUN_BACKGROUND_TASKS;
|
||||
@ -95,27 +95,25 @@ mp_uint_t common_hal_socketpool_socket_recv_into(socketpool_socket_obj_t* self,
|
||||
if (available == 0) {
|
||||
// This reads the raw socket buffer and is used for non-TLS connections
|
||||
// and between encrypted TLS blocks.
|
||||
int status = lwip_ioctl(sockfd, FIONREAD, &available);
|
||||
if (status < 0) {
|
||||
last_read = status;
|
||||
break;
|
||||
}
|
||||
status = lwip_ioctl(sockfd, FIONREAD, &available);
|
||||
}
|
||||
size_t remaining = len - received;
|
||||
if (available > remaining) {
|
||||
available = remaining;
|
||||
}
|
||||
if (available > 0) {
|
||||
last_read = esp_tls_conn_read(self->tcp, (void*) buf + received, available);
|
||||
received += last_read;
|
||||
status = esp_tls_conn_read(self->tcp, (void*) buf + received, available);
|
||||
if (status > 0) {
|
||||
received += status;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (last_read == 0) {
|
||||
if (received == 0) {
|
||||
// socket closed
|
||||
common_hal_socketpool_socket_close(self);
|
||||
}
|
||||
if (last_read < 0) {
|
||||
if (status < 0) {
|
||||
mp_raise_BrokenPipeError();
|
||||
}
|
||||
return received;
|
||||
|
@ -3,7 +3,7 @@
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2016 Scott Shawcroft for Adafruit Industries
|
||||
* Copyright (c) 2020 microDev
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
|
@ -3,7 +3,7 @@
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2016 Scott Shawcroft
|
||||
* Copyright (c) 2020 microDev
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
|
@ -135,6 +135,7 @@ CONFIG_COMPILER_STACK_CHECK_MODE_NONE=y
|
||||
# CONFIG_COMPILER_STACK_CHECK_MODE_ALL is not set
|
||||
# CONFIG_COMPILER_WARN_WRITE_STRINGS is not set
|
||||
# CONFIG_COMPILER_DISABLE_GCC8_WARNINGS is not set
|
||||
# CONFIG_COMPILER_DUMP_RTL_FILES is not set
|
||||
# end of Compiler options
|
||||
|
||||
#
|
||||
@ -263,6 +264,11 @@ CONFIG_ESP32S2_ALLOW_RTC_FAST_MEM_AS_HEAP=y
|
||||
# CONFIG_PM_ENABLE is not set
|
||||
# end of Power Management
|
||||
|
||||
#
|
||||
# ADC-Calibration
|
||||
#
|
||||
# end of ADC-Calibration
|
||||
|
||||
#
|
||||
# Common ESP-related
|
||||
#
|
||||
@ -332,12 +338,13 @@ CONFIG_ESP_TIMER_IMPL_SYSTIMER=y
|
||||
#
|
||||
# Wi-Fi
|
||||
#
|
||||
CONFIG_ESP32_WIFI_STATIC_RX_BUFFER_NUM=10
|
||||
CONFIG_ESP32_WIFI_DYNAMIC_RX_BUFFER_NUM=32
|
||||
CONFIG_ESP32_WIFI_STATIC_RX_BUFFER_NUM=4
|
||||
CONFIG_ESP32_WIFI_DYNAMIC_RX_BUFFER_NUM=8
|
||||
# CONFIG_ESP32_WIFI_STATIC_TX_BUFFER is not set
|
||||
CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER=y
|
||||
CONFIG_ESP32_WIFI_TX_BUFFER_TYPE=1
|
||||
CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER_NUM=32
|
||||
CONFIG_ESP32_WIFI_CACHE_TX_BUFFER_NUM=16
|
||||
CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER_NUM=16
|
||||
# CONFIG_ESP32_WIFI_CSI_ENABLED is not set
|
||||
CONFIG_ESP32_WIFI_AMPDU_TX_ENABLED=y
|
||||
CONFIG_ESP32_WIFI_TX_BA_WIN=6
|
||||
@ -401,6 +408,7 @@ CONFIG_FREERTOS_QUEUE_REGISTRY_SIZE=0
|
||||
# CONFIG_FREERTOS_GENERATE_RUN_TIME_STATS is not set
|
||||
CONFIG_FREERTOS_CHECK_MUTEX_GIVEN_BY_OWNER=y
|
||||
# CONFIG_FREERTOS_CHECK_PORT_CRITICAL_COMPLIANCE is not set
|
||||
# CONFIG_FREERTOS_PLACE_FUNCTIONS_INTO_FLASH is not set
|
||||
CONFIG_FREERTOS_DEBUG_OCDAWARE=y
|
||||
# end of FreeRTOS
|
||||
|
||||
@ -439,7 +447,7 @@ CONFIG_LWIP_DNS_SUPPORT_MDNS_QUERIES=y
|
||||
# CONFIG_LWIP_L2_TO_L3_COPY is not set
|
||||
# CONFIG_LWIP_IRAM_OPTIMIZATION is not set
|
||||
CONFIG_LWIP_TIMERS_ONDEMAND=y
|
||||
CONFIG_LWIP_MAX_SOCKETS=10
|
||||
CONFIG_LWIP_MAX_SOCKETS=4
|
||||
# CONFIG_LWIP_USE_ONLY_LWIP_SELECT is not set
|
||||
# CONFIG_LWIP_SO_LINGER is not set
|
||||
CONFIG_LWIP_SO_REUSE=y
|
||||
@ -459,6 +467,9 @@ CONFIG_LWIP_TCPIP_RECVMBOX_SIZE=32
|
||||
CONFIG_LWIP_DHCP_DOES_ARP_CHECK=y
|
||||
# CONFIG_LWIP_DHCP_RESTORE_LAST_IP is not set
|
||||
|
||||
#
|
||||
# CONFIG_FREERTOS_PLACE_FUNCTIONS_INTO_FLASH is not set
|
||||
|
||||
#
|
||||
# DHCP server
|
||||
#
|
||||
@ -474,15 +485,15 @@ CONFIG_LWIP_LOOPBACK_MAX_PBUFS=8
|
||||
#
|
||||
# TCP
|
||||
#
|
||||
CONFIG_LWIP_MAX_ACTIVE_TCP=16
|
||||
CONFIG_LWIP_MAX_LISTENING_TCP=16
|
||||
CONFIG_LWIP_MAX_ACTIVE_TCP=4
|
||||
CONFIG_LWIP_MAX_LISTENING_TCP=4
|
||||
CONFIG_LWIP_TCP_MAXRTX=12
|
||||
CONFIG_LWIP_TCP_SYNMAXRTX=6
|
||||
CONFIG_LWIP_TCP_MSS=1440
|
||||
CONFIG_LWIP_TCP_TMR_INTERVAL=250
|
||||
CONFIG_LWIP_TCP_MSL=60000
|
||||
CONFIG_LWIP_TCP_SND_BUF_DEFAULT=5744
|
||||
CONFIG_LWIP_TCP_WND_DEFAULT=5744
|
||||
CONFIG_LWIP_TCP_SND_BUF_DEFAULT=2880
|
||||
CONFIG_LWIP_TCP_WND_DEFAULT=2880
|
||||
CONFIG_LWIP_TCP_RECVMBOX_SIZE=6
|
||||
CONFIG_LWIP_TCP_QUEUE_OOSEQ=y
|
||||
# CONFIG_LWIP_TCP_SACK_OUT is not set
|
||||
@ -505,6 +516,8 @@ CONFIG_LWIP_TCPIP_TASK_AFFINITY_NO_AFFINITY=y
|
||||
# CONFIG_LWIP_TCPIP_TASK_AFFINITY_CPU0 is not set
|
||||
CONFIG_LWIP_TCPIP_TASK_AFFINITY=0x7FFFFFFF
|
||||
# CONFIG_LWIP_PPP_SUPPORT is not set
|
||||
CONFIG_LWIP_IPV6_MEMP_NUM_ND6_QUEUE=3
|
||||
CONFIG_LWIP_IPV6_ND6_NUM_NEIGHBORS=5
|
||||
# CONFIG_LWIP_SLIP_SUPPORT is not set
|
||||
|
||||
#
|
||||
@ -552,8 +565,10 @@ CONFIG_MBEDTLS_INTERNAL_MEM_ALLOC=y
|
||||
# CONFIG_MBEDTLS_CUSTOM_MEM_ALLOC is not set
|
||||
CONFIG_MBEDTLS_ASYMMETRIC_CONTENT_LEN=y
|
||||
CONFIG_MBEDTLS_SSL_IN_CONTENT_LEN=16384
|
||||
CONFIG_MBEDTLS_SSL_OUT_CONTENT_LEN=4096
|
||||
# CONFIG_MBEDTLS_DYNAMIC_BUFFER is not set
|
||||
CONFIG_MBEDTLS_SSL_OUT_CONTENT_LEN=2048
|
||||
CONFIG_MBEDTLS_DYNAMIC_BUFFER=y
|
||||
CONFIG_MBEDTLS_DYNAMIC_FREE_PEER_CERT=y
|
||||
CONFIG_MBEDTLS_DYNAMIC_FREE_CONFIG_DATA=y
|
||||
# CONFIG_MBEDTLS_DEBUG is not set
|
||||
|
||||
#
|
||||
@ -706,6 +721,7 @@ CONFIG_SPI_FLASH_YIELD_DURING_ERASE=y
|
||||
CONFIG_SPI_FLASH_ERASE_YIELD_DURATION_MS=20
|
||||
CONFIG_SPI_FLASH_ERASE_YIELD_TICKS=1
|
||||
CONFIG_SPI_FLASH_WRITE_CHUNK_SIZE=8192
|
||||
# CONFIG_SPI_FLASH_SIZE_OVERRIDE is not set
|
||||
|
||||
#
|
||||
# Auto-detect flash chips
|
||||
@ -824,8 +840,8 @@ CONFIG_TCP_MAXRTX=12
|
||||
CONFIG_TCP_SYNMAXRTX=6
|
||||
CONFIG_TCP_MSS=1440
|
||||
CONFIG_TCP_MSL=60000
|
||||
CONFIG_TCP_SND_BUF_DEFAULT=5744
|
||||
CONFIG_TCP_WND_DEFAULT=5744
|
||||
CONFIG_TCP_SND_BUF_DEFAULT=2880
|
||||
CONFIG_TCP_WND_DEFAULT=2880
|
||||
CONFIG_TCP_RECVMBOX_SIZE=6
|
||||
CONFIG_TCP_QUEUE_OOSEQ=y
|
||||
# CONFIG_ESP_TCP_KEEP_CONNECTION_WHEN_IP_CHANGES is not set
|
||||
|
@ -17,10 +17,10 @@ CIRCUITPY_FULL_BUILD = 1
|
||||
CIRCUITPY_AUDIOBUSIO = 0
|
||||
CIRCUITPY_AUDIOIO = 0
|
||||
CIRCUITPY_CANIO = 1
|
||||
CIRCUITPY_COUNTIO = 0
|
||||
CIRCUITPY_COUNTIO = 1
|
||||
CIRCUITPY_FREQUENCYIO = 0
|
||||
CIRCUITPY_I2CPERIPHERAL = 0
|
||||
CIRCUITPY_ROTARYIO = 0
|
||||
CIRCUITPY_ROTARYIO = 1
|
||||
CIRCUITPY_NVM = 0
|
||||
# We don't have enough endpoints to include MIDI.
|
||||
CIRCUITPY_USB_MIDI = 0
|
||||
|
68
ports/esp32s2/peripherals/pcnt.c
Normal file
68
ports/esp32s2/peripherals/pcnt.c
Normal file
@ -0,0 +1,68 @@
|
||||
/*
|
||||
* This file is part of the MicroPython project, http://micropython.org/
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2020 microDev
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include "peripherals/pcnt.h"
|
||||
|
||||
#define PCNT_UNIT_ACTIVE 1
|
||||
#define PCNT_UNIT_INACTIVE 0
|
||||
|
||||
static uint8_t pcnt_unit_state[4];
|
||||
|
||||
void peripherals_pcnt_reset(void) {
|
||||
for (uint8_t i = 0; i<=3; i++) {
|
||||
pcnt_unit_state[i] = PCNT_UNIT_INACTIVE;
|
||||
}
|
||||
}
|
||||
|
||||
int peripherals_pcnt_init(pcnt_config_t pcnt_config) {
|
||||
// Look for available pcnt unit
|
||||
for (uint8_t i = 0; i<=3; i++) {
|
||||
if (pcnt_unit_state[i] == PCNT_UNIT_INACTIVE) {
|
||||
pcnt_config.unit = (pcnt_unit_t)i;
|
||||
pcnt_unit_state[i] = PCNT_UNIT_ACTIVE;
|
||||
break;
|
||||
} else if (i == 3) {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
// Initialize PCNT unit
|
||||
pcnt_unit_config(&pcnt_config);
|
||||
|
||||
// Initialize PCNT's counter
|
||||
pcnt_counter_pause(pcnt_config.unit);
|
||||
pcnt_counter_clear(pcnt_config.unit);
|
||||
|
||||
// Everything is set up, now go to counting
|
||||
pcnt_counter_resume(pcnt_config.unit);
|
||||
|
||||
return pcnt_config.unit;
|
||||
}
|
||||
|
||||
void peripherals_pcnt_deinit(pcnt_unit_t* unit) {
|
||||
pcnt_unit_state[*unit] = PCNT_UNIT_INACTIVE;
|
||||
*unit = PCNT_UNIT_MAX;
|
||||
}
|
36
ports/esp32s2/peripherals/pcnt.h
Normal file
36
ports/esp32s2/peripherals/pcnt.h
Normal file
@ -0,0 +1,36 @@
|
||||
/*
|
||||
* This file is part of the MicroPython project, http://micropython.org/
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2020 microDev
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef MICROPY_INCLUDED_ESP32S2_PERIPHERALS_PCNT_HANDLER_H
|
||||
#define MICROPY_INCLUDED_ESP32S2_PERIPHERALS_PCNT_HANDLER_H
|
||||
|
||||
#include "driver/pcnt.h"
|
||||
|
||||
extern int peripherals_pcnt_init(pcnt_config_t pcnt_config);
|
||||
extern void peripherals_pcnt_deinit(pcnt_unit_t* unit);
|
||||
extern void peripherals_pcnt_reset(void);
|
||||
|
||||
#endif // MICROPY_INCLUDED_ESP32S2_PERIPHERALS_PCNT_HANDLER_H
|
35
ports/esp32s2/supervisor/esp_port.h
Normal file
35
ports/esp32s2/supervisor/esp_port.h
Normal file
@ -0,0 +1,35 @@
|
||||
/*
|
||||
* This file is part of the MicroPython project, http://micropython.org/
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2019 Lucian Copeland for Adafruit Industries
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef MICROPY_INCLUDED_ESP32S2_SUPERVISOR_PORT_H
|
||||
#define MICROPY_INCLUDED_ESP32S2_SUPERVISOR_PORT_H
|
||||
|
||||
#include "freertos/FreeRTOS.h"
|
||||
#include "freertos/task.h"
|
||||
|
||||
extern TaskHandle_t sleeping_circuitpython_task;
|
||||
|
||||
#endif // MICROPY_INCLUDED_ESP32S2_SUPERVISOR_PORT_H
|
@ -30,6 +30,8 @@
|
||||
#include "supervisor/port.h"
|
||||
#include "boards/board.h"
|
||||
#include "modules/module.h"
|
||||
#include "py/runtime.h"
|
||||
#include "supervisor/esp_port.h"
|
||||
|
||||
#include "freertos/FreeRTOS.h"
|
||||
#include "freertos/task.h"
|
||||
@ -47,6 +49,7 @@
|
||||
#include "shared-bindings/rtc/__init__.h"
|
||||
|
||||
#include "peripherals/rmt.h"
|
||||
#include "peripherals/pcnt.h"
|
||||
#include "components/heap/include/esp_heap_caps.h"
|
||||
#include "components/soc/soc/esp32s2/include/soc/cache_memory.h"
|
||||
|
||||
@ -115,6 +118,10 @@ void reset_port(void) {
|
||||
uart_reset();
|
||||
#endif
|
||||
|
||||
#if defined(CIRCUITPY_COUNTIO) || defined(CIRCUITPY_ROTARYIO)
|
||||
peripherals_pcnt_reset();
|
||||
#endif
|
||||
|
||||
#if CIRCUITPY_RTC
|
||||
rtc_reset();
|
||||
#endif
|
||||
@ -148,7 +155,18 @@ uint32_t *port_stack_get_limit(void) {
|
||||
}
|
||||
|
||||
uint32_t *port_stack_get_top(void) {
|
||||
return port_stack_get_limit() + CONFIG_ESP_MAIN_TASK_STACK_SIZE / (sizeof(uint32_t) / sizeof(StackType_t));
|
||||
// The sizeof-arithmetic is so that the pointer arithmetic is done on units
|
||||
// of uint32_t instead of units of StackType_t. StackType_t is an alias
|
||||
// for a byte sized type.
|
||||
//
|
||||
// The main stack is bigger than CONFIG_ESP_MAIN_TASK_STACK_SIZE -- an
|
||||
// "extra" size is added to it (TASK_EXTRA_STACK_SIZE). This total size is
|
||||
// available as ESP_TASK_MAIN_STACK. Presumably TASK_EXTRA_STACK_SIZE is
|
||||
// additional stack that can be used by the esp-idf runtime. But what's
|
||||
// important for us is that some very outermost stack frames, such as
|
||||
// pyexec_friendly_repl, could lie inside the "extra" area and be invisible
|
||||
// to the garbage collector.
|
||||
return port_stack_get_limit() + ESP_TASK_MAIN_STACK / (sizeof(uint32_t) / sizeof(StackType_t));
|
||||
}
|
||||
|
||||
supervisor_allocation _fixed_stack;
|
||||
@ -188,25 +206,28 @@ void port_disable_tick(void) {
|
||||
esp_timer_stop(_tick_timer);
|
||||
}
|
||||
|
||||
TickType_t sleep_time_set;
|
||||
TickType_t sleep_time_duration;
|
||||
|
||||
void port_interrupt_after_ticks(uint32_t ticks) {
|
||||
sleep_time_set = xTaskGetTickCount();
|
||||
sleep_time_duration = ticks / portTICK_PERIOD_MS;
|
||||
// esp_sleep_enable_timer_wakeup(uint64_t time_in_us)
|
||||
sleep_time_duration = (ticks * 100)/1024;
|
||||
sleeping_circuitpython_task = xTaskGetCurrentTaskHandle();
|
||||
}
|
||||
|
||||
void port_sleep_until_interrupt(void) {
|
||||
// FreeRTOS delay here maybe.
|
||||
// Light sleep shuts down BLE and wifi.
|
||||
// esp_light_sleep_start()
|
||||
|
||||
uint32_t NotifyValue = 0;
|
||||
|
||||
if (sleep_time_duration == 0) {
|
||||
return;
|
||||
}
|
||||
vTaskDelayUntil(&sleep_time_set, sleep_time_duration);
|
||||
xTaskNotifyWait(0x01,0x01,&NotifyValue,
|
||||
sleep_time_duration );
|
||||
if (NotifyValue == 1) {
|
||||
sleeping_circuitpython_task = NULL;
|
||||
mp_handle_pending();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Wrap main in app_main that the IDF expects.
|
||||
extern void main(void);
|
||||
void app_main(void) {
|
||||
|
@ -52,6 +52,8 @@
|
||||
StackType_t usb_device_stack[USBD_STACK_SIZE];
|
||||
StaticTask_t usb_device_taskdef;
|
||||
|
||||
TaskHandle_t sleeping_circuitpython_task = NULL;
|
||||
|
||||
// USB Device Driver task
|
||||
// This top level thread process all usb events and invoke callbacks
|
||||
void usb_device_task(void* param)
|
||||
@ -114,3 +116,23 @@ void init_usb_hardware(void) {
|
||||
usb_device_stack,
|
||||
&usb_device_taskdef);
|
||||
}
|
||||
/**
|
||||
* Callback invoked when received an "wanted" char.
|
||||
* @param itf Interface index (for multiple cdc interfaces)
|
||||
* @param wanted_char The wanted char (set previously)
|
||||
*/
|
||||
void tud_cdc_rx_wanted_cb(uint8_t itf, char wanted_char)
|
||||
{
|
||||
(void) itf; // not used
|
||||
// Workaround for using lib/utils/interrupt_char.c
|
||||
// Compare mp_interrupt_char with wanted_char and ignore if not matched
|
||||
if (mp_interrupt_char == wanted_char) {
|
||||
tud_cdc_read_flush(); // flush read fifo
|
||||
mp_keyboard_interrupt();
|
||||
// CircuitPython's VM is run in a separate FreeRTOS task from TinyUSB.
|
||||
// So, we must notify the other task when a CTRL-C is received.
|
||||
if (sleeping_circuitpython_task != NULL) {
|
||||
xTaskNotifyGive(sleeping_circuitpython_task);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -57,7 +57,8 @@ bool common_hal_displayio_parallelbus_begin_transaction(mp_obj_t obj) {
|
||||
return false;
|
||||
}
|
||||
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length) {
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length) {
|
||||
|
||||
}
|
||||
|
||||
|
@ -109,10 +109,10 @@ STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_D26), MP_ROM_PTR(&pin_P0_27) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_TFT_DC), MP_ROM_PTR(&pin_P0_27) },
|
||||
|
||||
{ MP_ROM_QSTR(MP_QSTR_P27), MP_ROM_PTR(&pin_P1_14) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D27), MP_ROM_PTR(&pin_P1_14) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_TFT_RESET), MP_ROM_PTR(&pin_P1_14) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_TFT_BACKLIGHT), MP_ROM_PTR(&pin_P1_14) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_P27), MP_ROM_PTR(&pin_P1_13) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D27), MP_ROM_PTR(&pin_P1_13) },
|
||||
//{ MP_ROM_QSTR(MP_QSTR_TFT_RESET), MP_ROM_PTR(&pin_P1_13) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_TFT_BACKLIGHT), MP_ROM_PTR(&pin_P1_13) },
|
||||
|
||||
// P28~P33/D28~D33 connecte into QSPI FlashROM (W25Q16JV_IQ)
|
||||
|
||||
|
@ -141,7 +141,8 @@ bool common_hal_displayio_parallelbus_begin_transaction(mp_obj_t obj) {
|
||||
}
|
||||
|
||||
// This ignores chip_select behaviour because data is clocked in by the write line toggling.
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length) {
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length) {
|
||||
displayio_parallelbus_obj_t* self = MP_OBJ_TO_PTR(obj);
|
||||
common_hal_digitalio_digitalinout_set_value(&self->command, byte_type == DISPLAY_DATA);
|
||||
uint32_t* clear_write = (uint32_t*) &self->write_group->OUTCLR;
|
||||
|
@ -57,7 +57,8 @@ bool common_hal_displayio_parallelbus_begin_transaction(mp_obj_t obj) {
|
||||
return false;
|
||||
}
|
||||
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length) {
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length) {
|
||||
|
||||
}
|
||||
|
||||
|
@ -186,7 +186,7 @@ typedef long mp_off_t;
|
||||
#define MICROPY_CPYTHON_COMPAT (CIRCUITPY_FULL_BUILD)
|
||||
#define MICROPY_PY_BUILTINS_POW3 (CIRCUITPY_FULL_BUILD)
|
||||
#define MICROPY_COMP_FSTRING_LITERAL (MICROPY_CPYTHON_COMPAT)
|
||||
#define MICROPY_MODULE_WEAK_LINKS (CIRCUITPY_FULL_BUILD)
|
||||
#define MICROPY_MODULE_WEAK_LINKS (0)
|
||||
#define MICROPY_PY_ALL_SPECIAL_METHODS (CIRCUITPY_FULL_BUILD)
|
||||
#define MICROPY_PY_BUILTINS_COMPLEX (CIRCUITPY_FULL_BUILD)
|
||||
#define MICROPY_PY_BUILTINS_FROZENSET (CIRCUITPY_FULL_BUILD)
|
||||
@ -197,6 +197,9 @@ typedef long mp_off_t;
|
||||
#ifndef MICROPY_PY_COLLECTIONS_ORDEREDDICT
|
||||
#define MICROPY_PY_COLLECTIONS_ORDEREDDICT (CIRCUITPY_FULL_BUILD)
|
||||
#endif
|
||||
#ifndef MICROPY_PY_UBINASCII
|
||||
#define MICROPY_PY_UBINASCII (CIRCUITPY_FULL_BUILD)
|
||||
#endif
|
||||
// Opposite setting is deliberate.
|
||||
#define MICROPY_PY_UERRNO_ERRORCODE (!CIRCUITPY_FULL_BUILD)
|
||||
#ifndef MICROPY_PY_URE
|
||||
@ -699,6 +702,12 @@ extern const struct _mp_obj_module_t ustack_module;
|
||||
#endif
|
||||
|
||||
// These modules are not yet in shared-bindings, but we prefer the non-uxxx names.
|
||||
#if MICROPY_PY_UBINASCII
|
||||
#define BINASCII_MODULE { MP_ROM_QSTR(MP_QSTR_binascii), MP_ROM_PTR(&mp_module_ubinascii) },
|
||||
#else
|
||||
#define BINASCII_MODULE
|
||||
#endif
|
||||
|
||||
#if MICROPY_PY_UERRNO
|
||||
#define ERRNO_MODULE { MP_ROM_QSTR(MP_QSTR_errno), MP_ROM_PTR(&mp_module_uerrno) },
|
||||
#else
|
||||
@ -770,6 +779,7 @@ extern const struct _mp_obj_module_t wifi_module;
|
||||
AUDIOMIXER_MODULE \
|
||||
AUDIOMP3_MODULE \
|
||||
AUDIOPWMIO_MODULE \
|
||||
BINASCII_MODULE \
|
||||
BITBANGIO_MODULE \
|
||||
BLEIO_MODULE \
|
||||
BOARD_MODULE \
|
||||
|
@ -239,7 +239,12 @@ STATIC const mp_rom_map_elem_t mp_builtin_module_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_hashlib), MP_ROM_PTR(&mp_module_uhashlib) },
|
||||
#endif
|
||||
#if MICROPY_PY_UBINASCII
|
||||
{ MP_ROM_QSTR(MP_QSTR_binascii), MP_ROM_PTR(&mp_module_ubinascii) },
|
||||
#if CIRCUITPY
|
||||
// CircuitPython: Defined in MICROPY_PORT_BUILTIN_MODULES, so not defined here.
|
||||
// TODO: move to shared-bindings/
|
||||
#else
|
||||
{ MP_ROM_QSTR(MP_QSTR_ubinascii), MP_ROM_PTR(&mp_module_ubinascii) },
|
||||
#endif
|
||||
#endif
|
||||
#if MICROPY_PY_URANDOM
|
||||
{ MP_ROM_QSTR(MP_QSTR_urandom), MP_ROM_PTR(&mp_module_urandom) },
|
||||
|
@ -58,24 +58,26 @@
|
||||
//| r"""Create a Display object on the given display bus (`FourWire`, `ParallelBus` or `I2CDisplay`).
|
||||
//|
|
||||
//| The ``init_sequence`` is bitpacked to minimize the ram impact. Every command begins with a
|
||||
//| command byte followed by a byte to determine the parameter count and if a delay is need after.
|
||||
//| When the top bit of the second byte is 1, the next byte will be the delay time in milliseconds.
|
||||
//| The remaining 7 bits are the parameter count excluding any delay byte. The third through final
|
||||
//| bytes are the remaining command parameters. The next byte will begin a new command definition.
|
||||
//| Here is a portion of ILI9341 init code:
|
||||
//| command byte followed by a byte to determine the parameter count and delay. When the top bit
|
||||
//| of the second byte is 1 (0x80), a delay will occur after the command parameters are sent.
|
||||
//| The remaining 7 bits are the parameter count excluding any delay byte. The bytes following
|
||||
//| are the parameters. When the delay bit is set, a single byte after the parameters specifies
|
||||
//| the delay duration in milliseconds. The value 0xff will lead to an extra long 500 ms delay
|
||||
//| instead of 255 ms. The next byte will begin a new command definition.
|
||||
//| Here is an example:
|
||||
//|
|
||||
//| .. code-block:: python
|
||||
//|
|
||||
//| init_sequence = (b"\xe1\x0f\x00\x0E\x14\x03\x11\x07\x31\xC1\x48\x08\x0F\x0C\x31\x36\x0F" # Set Gamma
|
||||
//| b"\x11\x80\x78"# Exit Sleep then delay 0x78 (120ms)
|
||||
//| b"\x29\x80\x78"# Display on then delay 0x78 (120ms)
|
||||
//| b"\x29\x81\xaa\x78"# Display on then delay 0x78 (120ms)
|
||||
//| )
|
||||
//| display = displayio.Display(display_bus, init_sequence, width=320, height=240)
|
||||
//|
|
||||
//| The first command is 0xe1 with 15 (0xf) parameters following. The second and third are 0x11 and
|
||||
//| 0x29 respectively with delays (0x80) of 120ms (0x78) and no parameters. Multiple byte literals
|
||||
//| (b"") are merged together on load. The parens are needed to allow byte literals on subsequent
|
||||
//| lines.
|
||||
//| The first command is 0xe1 with 15 (0xf) parameters following. The second is 0x11 with 0
|
||||
//| parameters and a 120ms (0x78) delay. The third command is 0x29 with one parameter 0xaa and a
|
||||
//| 120ms delay (0x78). Multiple byte literals (b"") are merged together on load. The parens
|
||||
//| are needed to allow byte literals on subsequent lines.
|
||||
//|
|
||||
//| The initialization sequence should always leave the display memory access inline with the scan
|
||||
//| of the display to minimize tearing artifacts.
|
||||
|
@ -65,11 +65,12 @@
|
||||
//| """Create a EPaperDisplay object on the given display bus (`displayio.FourWire` or `displayio.ParallelBus`).
|
||||
//|
|
||||
//| The ``start_sequence`` and ``stop_sequence`` are bitpacked to minimize the ram impact. Every
|
||||
//| command begins with a command byte followed by a byte to determine the parameter count and if
|
||||
//| a delay is need after. When the top bit of the second byte is 1, the next byte will be the
|
||||
//| delay time in milliseconds. The remaining 7 bits are the parameter count excluding any delay
|
||||
//| byte. The third through final bytes are the remaining command parameters. The next byte will
|
||||
//| begin a new command definition.
|
||||
//| command begins with a command byte followed by a byte to determine the parameter count and
|
||||
//| delay. When the top bit of the second byte is 1 (0x80), a delay will occur after the command
|
||||
//| parameters are sent. The remaining 7 bits are the parameter count excluding any delay
|
||||
//| byte. The bytes following are the parameters. When the delay bit is set, a single byte after
|
||||
//| the parameters specifies the delay duration in milliseconds. The value 0xff will lead to an
|
||||
//| extra long 500 ms delay instead of 255 ms. The next byte will begin a new command definition.
|
||||
//|
|
||||
//| :param display_bus: The bus that the display is connected to
|
||||
//| :type _DisplayBus: displayio.FourWire or displayio.ParallelBus
|
||||
@ -244,6 +245,23 @@ const mp_obj_property_t displayio_epaperdisplay_time_to_refresh_obj = {
|
||||
(mp_obj_t)&mp_const_none_obj},
|
||||
};
|
||||
|
||||
//| busy: bool
|
||||
//| """True when the display is refreshing. This uses the ``busy_pin`` when available or the
|
||||
//| ``refresh_time`` otherwise."""
|
||||
//|
|
||||
STATIC mp_obj_t displayio_epaperdisplay_obj_get_busy(mp_obj_t self_in) {
|
||||
displayio_epaperdisplay_obj_t *self = native_display(self_in);
|
||||
return mp_obj_new_bool(common_hal_displayio_epaperdisplay_get_busy(self));
|
||||
}
|
||||
MP_DEFINE_CONST_FUN_OBJ_1(displayio_epaperdisplay_get_busy_obj, displayio_epaperdisplay_obj_get_busy);
|
||||
|
||||
const mp_obj_property_t displayio_epaperdisplay_busy_obj = {
|
||||
.base.type = &mp_type_property,
|
||||
.proxy = {(mp_obj_t)&displayio_epaperdisplay_get_busy_obj,
|
||||
(mp_obj_t)&mp_const_none_obj,
|
||||
(mp_obj_t)&mp_const_none_obj},
|
||||
};
|
||||
|
||||
//| width: int
|
||||
//| """Gets the width of the display in pixels"""
|
||||
//|
|
||||
@ -300,6 +318,7 @@ STATIC const mp_rom_map_elem_t displayio_epaperdisplay_locals_dict_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_width), MP_ROM_PTR(&displayio_epaperdisplay_width_obj) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_height), MP_ROM_PTR(&displayio_epaperdisplay_height_obj) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_bus), MP_ROM_PTR(&displayio_epaperdisplay_bus_obj) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_busy), MP_ROM_PTR(&displayio_epaperdisplay_busy_obj) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_time_to_refresh), MP_ROM_PTR(&displayio_epaperdisplay_time_to_refresh_obj) },
|
||||
};
|
||||
STATIC MP_DEFINE_CONST_DICT(displayio_epaperdisplay_locals_dict, displayio_epaperdisplay_locals_dict_table);
|
||||
|
@ -39,7 +39,7 @@ extern const mp_obj_type_t displayio_epaperdisplay_type;
|
||||
#define NO_COMMAND 0x100
|
||||
|
||||
void common_hal_displayio_epaperdisplay_construct(displayio_epaperdisplay_obj_t* self,
|
||||
mp_obj_t bus, uint8_t* start_sequence, uint16_t start_sequence_len, uint8_t* stop_sequence, uint16_t stop_sequence_len,
|
||||
mp_obj_t bus, const uint8_t* start_sequence, uint16_t start_sequence_len, const uint8_t* stop_sequence, uint16_t stop_sequence_len,
|
||||
uint16_t width, uint16_t height, uint16_t ram_width, uint16_t ram_height, int16_t colstart, int16_t rowstart, uint16_t rotation,
|
||||
uint16_t set_column_window_command, uint16_t set_row_window_command,
|
||||
uint16_t set_current_column_command, uint16_t set_current_row_command,
|
||||
@ -52,6 +52,7 @@ bool common_hal_displayio_epaperdisplay_show(displayio_epaperdisplay_obj_t* self
|
||||
|
||||
// Returns time in milliseconds.
|
||||
uint32_t common_hal_displayio_epaperdisplay_get_time_to_refresh(displayio_epaperdisplay_obj_t* self);
|
||||
bool common_hal_displayio_epaperdisplay_get_busy(displayio_epaperdisplay_obj_t* self);
|
||||
|
||||
uint16_t common_hal_displayio_epaperdisplay_get_width(displayio_epaperdisplay_obj_t* self);
|
||||
uint16_t common_hal_displayio_epaperdisplay_get_height(displayio_epaperdisplay_obj_t* self);
|
||||
|
@ -48,7 +48,8 @@ bool common_hal_displayio_fourwire_bus_free(mp_obj_t self);
|
||||
|
||||
bool common_hal_displayio_fourwire_begin_transaction(mp_obj_t self);
|
||||
|
||||
void common_hal_displayio_fourwire_send(mp_obj_t self, display_byte_type_t byte_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length);
|
||||
void common_hal_displayio_fourwire_send(mp_obj_t self, display_byte_type_t byte_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length);
|
||||
|
||||
void common_hal_displayio_fourwire_end_transaction(mp_obj_t self);
|
||||
|
||||
|
@ -44,7 +44,8 @@ bool common_hal_displayio_i2cdisplay_bus_free(mp_obj_t self);
|
||||
|
||||
bool common_hal_displayio_i2cdisplay_begin_transaction(mp_obj_t self);
|
||||
|
||||
void common_hal_displayio_i2cdisplay_send(mp_obj_t self, display_byte_type_t byte_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length);
|
||||
void common_hal_displayio_i2cdisplay_send(mp_obj_t self, display_byte_type_t byte_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length);
|
||||
|
||||
void common_hal_displayio_i2cdisplay_end_transaction(mp_obj_t self);
|
||||
|
||||
|
@ -46,7 +46,8 @@ bool common_hal_displayio_parallelbus_bus_free(mp_obj_t self);
|
||||
|
||||
bool common_hal_displayio_parallelbus_begin_transaction(mp_obj_t self);
|
||||
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t self, display_byte_type_t byte_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length);
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t self, display_byte_type_t byte_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length);
|
||||
|
||||
void common_hal_displayio_parallelbus_end_transaction(mp_obj_t self);
|
||||
|
||||
|
@ -42,7 +42,8 @@ typedef enum {
|
||||
typedef bool (*display_bus_bus_reset)(mp_obj_t bus);
|
||||
typedef bool (*display_bus_bus_free)(mp_obj_t bus);
|
||||
typedef bool (*display_bus_begin_transaction)(mp_obj_t bus);
|
||||
typedef void (*display_bus_send)(mp_obj_t bus, display_byte_type_t byte_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length);
|
||||
typedef void (*display_bus_send)(mp_obj_t bus, display_byte_type_t byte_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length);
|
||||
typedef void (*display_bus_end_transaction)(mp_obj_t bus);
|
||||
|
||||
void common_hal_displayio_release_displays(void);
|
||||
|
@ -197,6 +197,11 @@ STATIC mp_obj_t rgbmatrix_rgbmatrix_make_new(const mp_obj_type_t *type, size_t n
|
||||
uint8_t clock_pin = validate_pin(args[ARG_clock_pin].u_obj);
|
||||
uint8_t latch_pin = validate_pin(args[ARG_latch_pin].u_obj);
|
||||
uint8_t output_enable_pin = validate_pin(args[ARG_output_enable_pin].u_obj);
|
||||
int bit_depth = args[ARG_bit_depth].u_int;
|
||||
|
||||
if (bit_depth <= 0 || bit_depth > 6) {
|
||||
mp_raise_ValueError_varg(translate("Bit depth must be from 1 to 6 inclusive, not %d"), bit_depth);
|
||||
}
|
||||
|
||||
validate_pins(MP_QSTR_rgb_pins, rgb_pins, MP_ARRAY_SIZE(self->rgb_pins), args[ARG_rgb_list].u_obj, &rgb_count);
|
||||
validate_pins(MP_QSTR_addr_pins, addr_pins, MP_ARRAY_SIZE(self->addr_pins), args[ARG_addr_list].u_obj, &addr_count);
|
||||
@ -229,7 +234,7 @@ STATIC mp_obj_t rgbmatrix_rgbmatrix_make_new(const mp_obj_type_t *type, size_t n
|
||||
|
||||
common_hal_rgbmatrix_rgbmatrix_construct(self,
|
||||
args[ARG_width].u_int,
|
||||
args[ARG_bit_depth].u_int,
|
||||
bit_depth,
|
||||
rgb_count, rgb_pins,
|
||||
addr_count, addr_pins,
|
||||
clock_pin, latch_pin, output_enable_pin,
|
||||
|
@ -55,7 +55,7 @@ uint8_t displayio_colorconverter_compute_luma(uint32_t color_rgb888) {
|
||||
uint32_t r8 = (color_rgb888 >> 16);
|
||||
uint32_t g8 = (color_rgb888 >> 8) & 0xff;
|
||||
uint32_t b8 = color_rgb888 & 0xff;
|
||||
return (r8 * 19) / 255 + (g8 * 182) / 255 + (b8 + 54) / 255;
|
||||
return (r8 * 19 + g8 * 182 + b8 * 54) / 255;
|
||||
}
|
||||
|
||||
uint8_t displayio_colorconverter_compute_chroma(uint32_t color_rgb888) {
|
||||
|
@ -43,7 +43,8 @@
|
||||
#include <string.h>
|
||||
|
||||
void common_hal_displayio_epaperdisplay_construct(displayio_epaperdisplay_obj_t* self,
|
||||
mp_obj_t bus, uint8_t* start_sequence, uint16_t start_sequence_len, uint8_t* stop_sequence, uint16_t stop_sequence_len,
|
||||
mp_obj_t bus, const uint8_t* start_sequence, uint16_t start_sequence_len,
|
||||
const uint8_t* stop_sequence, uint16_t stop_sequence_len,
|
||||
uint16_t width, uint16_t height, uint16_t ram_width, uint16_t ram_height,
|
||||
int16_t colstart, int16_t rowstart, uint16_t rotation,
|
||||
uint16_t set_column_window_command, uint16_t set_row_window_command,
|
||||
@ -133,14 +134,15 @@ STATIC void wait_for_busy(displayio_epaperdisplay_obj_t* self) {
|
||||
}
|
||||
}
|
||||
|
||||
STATIC void send_command_sequence(displayio_epaperdisplay_obj_t* self, bool should_wait_for_busy, uint8_t* sequence, uint32_t sequence_len) {
|
||||
STATIC void send_command_sequence(displayio_epaperdisplay_obj_t* self,
|
||||
bool should_wait_for_busy, const uint8_t* sequence, uint32_t sequence_len) {
|
||||
uint32_t i = 0;
|
||||
while (i < sequence_len) {
|
||||
uint8_t *cmd = sequence + i;
|
||||
const uint8_t *cmd = sequence + i;
|
||||
uint8_t data_size = *(cmd + 1);
|
||||
bool delay = (data_size & DELAY) != 0;
|
||||
data_size &= ~DELAY;
|
||||
uint8_t *data = cmd + 2;
|
||||
const uint8_t *data = cmd + 2;
|
||||
displayio_display_core_begin_transaction(&self->core);
|
||||
self->core.send(self->core.bus, DISPLAY_COMMAND, self->chip_select, cmd, 1);
|
||||
self->core.send(self->core.bus, DISPLAY_DATA, self->chip_select, data, data_size);
|
||||
@ -358,6 +360,11 @@ void displayio_epaperdisplay_background(displayio_epaperdisplay_obj_t* self) {
|
||||
}
|
||||
}
|
||||
|
||||
bool common_hal_displayio_epaperdisplay_get_busy(displayio_epaperdisplay_obj_t* self) {
|
||||
displayio_epaperdisplay_background(self);
|
||||
return self->refreshing;
|
||||
}
|
||||
|
||||
void release_epaperdisplay(displayio_epaperdisplay_obj_t* self) {
|
||||
if (self->refreshing) {
|
||||
wait_for_busy(self);
|
||||
@ -375,8 +382,8 @@ void release_epaperdisplay(displayio_epaperdisplay_obj_t* self) {
|
||||
|
||||
void displayio_epaperdisplay_collect_ptrs(displayio_epaperdisplay_obj_t* self) {
|
||||
displayio_display_core_collect_ptrs(&self->core);
|
||||
gc_collect_ptr(self->start_sequence);
|
||||
gc_collect_ptr(self->stop_sequence);
|
||||
gc_collect_ptr((void *) self->start_sequence);
|
||||
gc_collect_ptr((void *) self->stop_sequence);
|
||||
}
|
||||
|
||||
bool maybe_refresh_epaperdisplay(void) {
|
||||
|
@ -38,9 +38,9 @@ typedef struct {
|
||||
displayio_display_core_t core;
|
||||
digitalio_digitalinout_obj_t busy;
|
||||
uint32_t milliseconds_per_frame;
|
||||
uint8_t* start_sequence;
|
||||
const uint8_t* start_sequence;
|
||||
uint32_t start_sequence_len;
|
||||
uint8_t* stop_sequence;
|
||||
const uint8_t* stop_sequence;
|
||||
uint32_t stop_sequence_len;
|
||||
uint16_t refresh_time;
|
||||
uint16_t set_column_window_command;
|
||||
|
@ -113,7 +113,8 @@ bool common_hal_displayio_fourwire_begin_transaction(mp_obj_t obj) {
|
||||
return true;
|
||||
}
|
||||
|
||||
void common_hal_displayio_fourwire_send(mp_obj_t obj, display_byte_type_t data_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length) {
|
||||
void common_hal_displayio_fourwire_send(mp_obj_t obj, display_byte_type_t data_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length) {
|
||||
displayio_fourwire_obj_t* self = MP_OBJ_TO_PTR(obj);
|
||||
common_hal_digitalio_digitalinout_set_value(&self->command, data_type == DISPLAY_DATA);
|
||||
if (chip_select == CHIP_SELECT_TOGGLE_EVERY_BYTE) {
|
||||
|
@ -103,7 +103,8 @@ bool common_hal_displayio_i2cdisplay_begin_transaction(mp_obj_t obj) {
|
||||
return common_hal_busio_i2c_try_lock(self->bus);
|
||||
}
|
||||
|
||||
void common_hal_displayio_i2cdisplay_send(mp_obj_t obj, display_byte_type_t data_type, display_chip_select_behavior_t chip_select, uint8_t *data, uint32_t data_length) {
|
||||
void common_hal_displayio_i2cdisplay_send(mp_obj_t obj, display_byte_type_t data_type,
|
||||
display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length) {
|
||||
displayio_i2cdisplay_obj_t* self = MP_OBJ_TO_PTR(obj);
|
||||
if (data_type == DISPLAY_COMMAND) {
|
||||
uint8_t command_bytes[2 * data_length];
|
||||
|
@ -83,10 +83,16 @@ bool common_hal_displayio_tilegrid_get_hidden(displayio_tilegrid_t* self) {
|
||||
|
||||
void common_hal_displayio_tilegrid_set_hidden(displayio_tilegrid_t* self, bool hidden) {
|
||||
self->hidden = hidden;
|
||||
if(!hidden){
|
||||
self->full_change = true;
|
||||
}
|
||||
}
|
||||
|
||||
void displayio_tilegrid_set_hidden_by_parent(displayio_tilegrid_t *self, bool hidden) {
|
||||
self->hidden_by_parent = hidden;
|
||||
if(!hidden){
|
||||
self->full_change = true;
|
||||
}
|
||||
}
|
||||
|
||||
bool displayio_tilegrid_get_previous_area(displayio_tilegrid_t *self, displayio_area_t* area) {
|
||||
|
@ -39,7 +39,7 @@
|
||||
|
||||
#define MSC_FLASH_BLOCK_SIZE 512
|
||||
|
||||
static bool ejected[1] = {true};
|
||||
static bool ejected[1] = {false};
|
||||
|
||||
void usb_msc_mount(void) {
|
||||
// Reset the ejection tracking every time we're plugged into USB. This allows for us to battery
|
||||
|
Loading…
x
Reference in New Issue
Block a user