summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSabas <sabasjimenez@gmail.com>2018-10-11 23:04:53 -0500
committerGitHub <noreply@github.com>2018-10-11 23:04:53 -0500
commitc8d0509eb22cea41e2030c26b8c4ec206e3636c0 (patch)
tree40fb5374acfc081c9bfaaa330d41c3f2695b3178
parentf09537bbc4c58ed04e240170fd742497a2a3df5a (diff)
parent29334511956ab1d4ef04d3dcca72e90b4b932d4a (diff)
Merge pull request #1 from adafruit/master
Update
-rwxr-xr-x.travis.yml92
m---------lib/tinyusb0
-rw-r--r--locale/circuitpython.pot185
-rw-r--r--locale/de_DE.po192
-rw-r--r--locale/en_US.po185
-rw-r--r--locale/es.po373
-rw-r--r--locale/fil.po204
-rw-r--r--locale/fr.po200
-rw-r--r--locale/it_IT.po2506
-rw-r--r--locale/pt_BR.po2463
-rw-r--r--ports/atmel-samd/Makefile2
-rw-r--r--ports/atmel-samd/audio_dma.c76
-rw-r--r--ports/atmel-samd/boards/trellis_m4_express/mpconfigboard.h2
-rw-r--r--ports/atmel-samd/boards/trellis_m4_express/pins.c3
-rwxr-xr-xports/atmel-samd/common-hal/supervisor/Runtime.c4
-rw-r--r--ports/atmel-samd/external_flash/devices.h18
-rw-r--r--ports/atmel-samd/mpconfigport.h2
-rw-r--r--ports/esp8266/README.md8
-rwxr-xr-xports/nrf/Makefile3
-rw-r--r--ports/nrf/boards/feather_nrf52832/mpconfigboard.h1
-rw-r--r--ports/nrf/boards/feather_nrf52840_express/mpconfigboard.h2
-rw-r--r--ports/nrf/boards/pca10056/mpconfigboard.h8
-rw-r--r--ports/nrf/boards/pca10056/pins.c2
-rw-r--r--ports/nrf/common-hal/busio/I2C.c6
-rw-r--r--ports/nrf/common-hal/busio/I2C.h2
-rw-r--r--ports/nrf/common-hal/busio/SPI.c96
-rw-r--r--ports/nrf/common-hal/busio/SPI.h2
-rw-r--r--ports/nrf/common-hal/busio/UART.c317
-rw-r--r--ports/nrf/common-hal/busio/UART.h17
-rw-r--r--ports/nrf/common-hal/pulseio/PWMOut.c312
-rw-r--r--ports/nrf/common-hal/pulseio/PWMOut.h14
-rwxr-xr-xports/nrf/common-hal/supervisor/Runtime.c4
-rw-r--r--ports/nrf/drivers/bluetooth/ble_drv.c16
-rw-r--r--ports/nrf/examples/ubluepy_eddystone.py2
-rw-r--r--ports/nrf/examples/ubluepy_temp.py2
-rw-r--r--ports/nrf/modules/ubluepy/ubluepy_peripheral.c4
-rw-r--r--ports/nrf/mphalport.c36
-rw-r--r--ports/nrf/mphalport.h13
m---------ports/nrf/nrfx0
-rw-r--r--ports/nrf/nrfx_config.h9
-rw-r--r--ports/nrf/supervisor/filesystem.c4
-rw-r--r--ports/nrf/supervisor/port.c11
-rw-r--r--ports/nrf/supervisor/serial.c43
-rw-r--r--py/emitinlinethumb.c34
-rw-r--r--shared-bindings/audioio/Mixer.c249
-rw-r--r--shared-bindings/audioio/Mixer.h52
-rw-r--r--shared-bindings/audioio/__init__.c4
-rw-r--r--shared-bindings/busio/SPI.c15
-rw-r--r--shared-bindings/pulseio/PWMOut.c2
-rwxr-xr-xshared-bindings/supervisor/Runtime.c26
-rwxr-xr-xshared-bindings/supervisor/Runtime.h2
-rw-r--r--shared-module/audioio/Mixer.c341
-rw-r--r--shared-module/audioio/Mixer.h75
-rw-r--r--shared-module/audioio/WaveFile.c18
-rw-r--r--shared-module/audioio/__init__.c125
-rw-r--r--shared-module/audioio/__init__.h17
-rw-r--r--shared-module/displayio/Sprite.c2
-rwxr-xr-xtools/preprocess_frozen_modules.py2
58 files changed, 7588 insertions, 817 deletions
diff --git a/.travis.yml b/.travis.yml
index 1237a6a6b..65983fc92 100755
--- a/.travis.yml
+++ b/.travis.yml
@@ -6,39 +6,26 @@ compiler:
git:
depth: 1
-# Put a representative board from each port or sub-port near the top
-# to determine more quickly whether that port is going to build or not.
+# Each item under 'env' is a separate Travis job to execute.
+# They run in separate environments, so each one must take the time
+# to clone the repository and submodules; to download and install SDKs,
+# pip packages, and so forth. By gathering activities together in optimal
+# ways, the "run time" and "total time" of the travis jobs can be minimized.
+#
+# Since at the time of writing Travis generally starts 5 or 6 jobs, the
+# builds have been organized into 5 groups of *approximately* equal durations.
+# Additionally, the jobs that need extra SDKs are also organized together.
+#
+# When adding new boards, take a look on the travis CI page
+# https://travis-ci.org/adafruit/circuitpython to which build that installs
+# that SDK is shortest and add it there. In the case of major re-organizations,
+# just try to make the builds "about equal in run time"
env:
- - TRAVIS_TEST=unix
- - TRAVIS_TEST=docs
- - TRAVIS_TEST=translations
- - TRAVIS_BOARD=feather_huzzah
- - TRAVIS_BOARD=circuitplayground_express
- - TRAVIS_BOARD=pca10056
- # The rest of the boards, in alphabetical order.
- - TRAVIS_BOARD=trinket_m0
- - TRAVIS_BOARD=feather_m4_express
- - TRAVIS_BOARD=grandcentral_m4_express
- - TRAVIS_BOARD=arduino_zero
- - TRAVIS_BOARD=circuitplayground_express_crickit
- - TRAVIS_BOARD=feather_m0_adalogger
- - TRAVIS_BOARD=feather_m0_basic
- - TRAVIS_BOARD=feather_m0_express
- - TRAVIS_BOARD=feather_m0_express_crickit
- - TRAVIS_BOARD=feather_m0_rfm69
- - TRAVIS_BOARD=feather_m0_rfm9x
- - TRAVIS_BOARD=feather_nrf52832
- - TRAVIS_BOARD=feather_nrf52840_express
- - TRAVIS_BOARD=feather_radiofruit_zigbee
- - TRAVIS_BOARD=gemma_m0
- - TRAVIS_BOARD=hallowing_m0_express
- - TRAVIS_BOARD=itsybitsy_m0_express
- - TRAVIS_BOARD=itsybitsy_m4_express
- - TRAVIS_BOARD=metro_m0_express
- - TRAVIS_BOARD=metro_m4_express
- - TRAVIS_BOARD=pca10059
- - TRAVIS_BOARD=pirkey_m0
- - TRAVIS_BOARD=trellis_m4_express
+ - TRAVIS_TESTS="unix docs translations" TRAVIS_BOARDS="feather_huzzah circuitplayground_express pca10056 pca10059 feather_nrf52832 feather_nrf52840_express" TRAVIS_SDK=arm:nrf:esp8266
+ - TRAVIS_BOARDS="metro_m0_express metro_m4_express pirkey_m0 trellis_m4_express trinket_m0" TRAVIS_SDK=arm
+ - TRAVIS_BOARDS="feather_radiofruit_zigbee gemma_m0 hallowing_m0_express itsybitsy_m0_express itsybitsy_m4_express" TRAVIS_SDK=arm
+ - TRAVIS_BOARDS="feather_m0_express_crickit feather_m0_rfm69 feather_m0_rfm9x feather_m4_express arduino_zero" TRAVIS_SDK=arm
+ - TRAVIS_BOARDS="circuitplayground_express_crickit feather_m0_adalogger feather_m0_basic feather_m0_express" TRAVIS_SDK=arm
addons:
artifacts:
@@ -57,21 +44,28 @@ notifications:
on_error: always
before_script:
+ - function var_search () { case "$1" in *$2*) true;; *) false;; esac; }
- sudo dpkg --add-architecture i386
- - ([[ -z "$TRAVIS_BOARD" || $TRAVIS_BOARD = "feather_huzzah" ]] || (wget https://s3.amazonaws.com/adafruit-circuit-python/gcc-arm-embedded_7-2018q2-1~trusty1_amd64.deb && sudo dpkg -i gcc-arm-embedded*_amd64.deb))
+ - (! var_search "${TRAVIS_SDK-}" arm || (wget https://s3.amazonaws.com/adafruit-circuit-python/gcc-arm-embedded_7-2018q2-1~trusty1_amd64.deb && sudo dpkg -i gcc-arm-embedded*_amd64.deb))
# For nrf builds
- - ([[ $TRAVIS_BOARD != "feather_nrf52832" && $TRAVIS_BOARD != "feather_nrf52840_express" && $TRAVIS_BOARD != "pca10056" && $TRAVIS_BOARD != "pca10059" ]] || sudo ports/nrf/drivers/bluetooth/download_ble_stack.sh)
+ - (! var_search "${TRAVIS_SDK-}" nrf || sudo ports/nrf/drivers/bluetooth/download_ble_stack.sh)
+
# For huzzah builds
- - if [[ $TRAVIS_BOARD = "feather_huzzah" ]]; then wget https://github.com/jepler/esp-open-sdk/releases/download/2018-06-10/xtensa-lx106-elf-standalone.tar.gz && tar xavf xtensa-lx106-elf-standalone.tar.gz; PATH=$(readlink -f xtensa-lx106-elf/bin):$PATH; fi
+ - (! var_search "${TRAVIS_SDK-}" esp8266 || (wget https://github.com/jepler/esp-open-sdk/releases/download/2018-06-10/xtensa-lx106-elf-standalone.tar.gz && tar -C .. -xavf xtensa-lx106-elf-standalone.tar.gz))
+ - if var_search "${TRAVIS_SDK-}" esp8266 ; then PATH=$(readlink -f ../xtensa-lx106-elf/bin):$PATH; fi
+
# For coverage testing (upgrade is used to get latest urllib3 version)
- - ([[ -z "$TRAVIS_TEST" ]] || sudo apt-get install -y python3-pip)
- - ([[ -z "$TRAVIS_TEST" ]] || sudo pip install --upgrade cpp-coveralls)
- - ([[ $TRAVIS_TEST != "docs" ]] || sudo pip install 'Sphinx<1.8.0' sphinx-rtd-theme recommonmark)
- - ([[ $TRAVIS_TEST != "translations" ]] || sudo pip3 install polib)
+ - ([[ -z "$TRAVIS_TESTS" ]] || sudo apt-get install -y python3-pip)
+ - ([[ -z "$TRAVIS_TESTS" ]] || sudo pip install --upgrade cpp-coveralls)
+ - (! var_search "${TRAVIS_TESTS-}" docs || sudo pip install 'Sphinx<1.8.0' sphinx-rtd-theme recommonmark)
+ - (! var_search "${TRAVIS_TESTS-}" translations || sudo pip3 install polib)
+
+ # report some good version numbers to the build
- gcc --version
- - ([[ -z "$TRAVIS_BOARD" || $TRAVIS_BOARD = "feather_huzzah" ]] || arm-none-eabi-gcc --version)
+ - (! var_search "${TRAVIS_SDK-}" elf || arm-none-eabi-gcc --version)
+ - (! var_search "${TRAVIS_SDK-}" esp8266 || xtensa-lx106-elf-gcc --version)
- python3 --version
script:
@@ -81,13 +75,11 @@ script:
- echo -en 'travis_fold:end:mpy-cross\\r'
- echo 'Building Adafruit binaries' && echo -en 'travis_fold:start:adafruit-bins\\r'
- - ([[ -z "$TRAVIS_BOARD" ]] || tools/build_adafruit_bins.sh)
+ - (for board in $TRAVIS_BOARDS; do TRAVIS_BOARD=$board tools/build_adafruit_bins.sh || exit $?; done)
- echo -en 'travis_fold:end:adafruit-bins\\r'
- echo 'Building unix' && echo -en 'travis_fold:start:unix\\r'
- - ([[ $TRAVIS_TEST != "unix" ]] || make -C ports/unix deplibs -j2)
- - ([[ $TRAVIS_TEST != "unix" ]] || make -C ports/unix -j2)
- - ([[ $TRAVIS_TEST != "unix" ]] || make -C ports/unix coverage -j2)
+ - (! var_search "${TRAVIS_TESTS-}" unix || (make -C ports/unix deplibs -j2 && make -C ports/unix -j2 && make -C ports/unix coverage -j2))
- echo -en 'travis_fold:end:unix\\r'
# run tests without coverage info
@@ -96,27 +88,27 @@ script:
# run tests with coverage info
- echo 'Test all' && echo -en 'travis_fold:start:test_all\\r'
- - ([[ $TRAVIS_TEST != "unix" ]] || (cd tests && MICROPY_CPYTHON3=python3.4 MICROPY_MICROPYTHON=../ports/unix/micropython_coverage ./run-tests -j1))
+ - (! var_search "${TRAVIS_TESTS-}" unix || (cd tests && MICROPY_CPYTHON3=python3.4 MICROPY_MICROPYTHON=../ports/unix/micropython_coverage ./run-tests -j1))
- echo -en 'travis_fold:end:test_all\\r'
- echo 'Test threads' && echo -en 'travis_fold:start:test_threads\\r'
- - ([[ $TRAVIS_TEST != "unix" ]] || (cd tests && MICROPY_CPYTHON3=python3.4 MICROPY_MICROPYTHON=../ports/unix/micropython_coverage ./run-tests -j1 -d thread))
+ - (! var_search "${TRAVIS_TESTS-}" unix || (cd tests && MICROPY_CPYTHON3=python3.4 MICROPY_MICROPYTHON=../ports/unix/micropython_coverage ./run-tests -j1 -d thread))
- echo -en 'travis_fold:end:test_threads\\r'
- echo 'Testing with native' && echo -en 'travis_fold:start:test_native\\r'
- - ([[ $TRAVIS_TEST != "unix" ]] || (cd tests && MICROPY_CPYTHON3=python3.4 MICROPY_MICROPYTHON=../ports/unix/micropython_coverage ./run-tests -j1 --emit native))
+ - (! var_search "${TRAVIS_TESTS-}" unix || (cd tests && MICROPY_CPYTHON3=python3.4 MICROPY_MICROPYTHON=../ports/unix/micropython_coverage ./run-tests -j1 --emit native))
- echo -en 'travis_fold:end:test_native\\r'
- (echo 'Testing with mpy' && echo -en 'travis_fold:start:test_mpy\\r')
- - ([[ $TRAVIS_TEST != "unix" ]] || (cd tests && MICROPY_CPYTHON3=python3.4 MICROPY_MICROPYTHON=../ports/unix/micropython_coverage ./run-tests -j1 --via-mpy -d basics float))
+ - (! var_search "${TRAVIS_TESTS-}" unix || (cd tests && MICROPY_CPYTHON3=python3.4 MICROPY_MICROPYTHON=../ports/unix/micropython_coverage ./run-tests -j1 --via-mpy -d basics float))
- echo -en 'travis_fold:end:test_mpy\\r'
- (echo 'Building docs' && echo -en 'travis_fold:start:build_docs\\r')
- - ([[ $TRAVIS_TEST != "docs" ]] || sphinx-build -E -W -b html . _build/html)
+ - (! var_search "${TRAVIS_TESTS-}" docs || sphinx-build -E -W -b html . _build/html)
- echo -en 'travis_fold:end:build_docs\\r'
- (echo 'Building translations' && echo -en 'travis_fold:start:build_translations\\r')
- - ([[ $TRAVIS_TEST != "translations" ]] || make check-translate)
+ - (! var_search "${TRAVIS_TESTS-}" translations || make check-translate)
- echo -en 'travis_fold:end:build_translations\\r'
# run coveralls coverage analysis (try to, even if some builds/tests failed)
diff --git a/lib/tinyusb b/lib/tinyusb
-Subproject 583326e535454f16b06ebdb9cc06869602a5564
+Subproject 33c61bfda2c3aada3cb06d36e12d7cf57da0203
diff --git a/locale/circuitpython.pot b/locale/circuitpython.pot
index 513ec8efd..83662734a 100644
--- a/locale/circuitpython.pot
+++ b/locale/circuitpython.pot
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2018-09-21 12:23-0400\n"
+"POT-Creation-Date: 2018-10-09 20:51-0400\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"
@@ -218,7 +218,7 @@ msgstr ""
msgid "soft reboot\n"
msgstr ""
-#: ports/atmel-samd/audio_dma.c:285
+#: ports/atmel-samd/audio_dma.c:209
#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:361
msgid "All sync event channels in use"
msgstr ""
@@ -361,7 +361,7 @@ msgstr ""
#: ports/atmel-samd/common-hal/busio/SPI.c:132
#: ports/atmel-samd/common-hal/busio/UART.c:119
#: ports/atmel-samd/common-hal/i2cslave/I2CSlave.c:45
-#: ports/nrf/common-hal/busio/I2C.c:77
+#: ports/nrf/common-hal/busio/I2C.c:81
msgid "Invalid pins"
msgstr ""
@@ -378,10 +378,12 @@ msgid "bytes > 8 bits not supported"
msgstr ""
#: ports/atmel-samd/common-hal/busio/UART.c:72
+#: ports/nrf/common-hal/busio/UART.c:82
msgid "tx and rx cannot both be None"
msgstr ""
#: ports/atmel-samd/common-hal/busio/UART.c:145
+#: ports/nrf/common-hal/busio/UART.c:115
msgid "Failed to allocate RX buffer"
msgstr ""
@@ -390,10 +392,12 @@ msgid "Could not initialize UART"
msgstr ""
#: ports/atmel-samd/common-hal/busio/UART.c:240
+#: ports/nrf/common-hal/busio/UART.c:149
msgid "No RX pin"
msgstr ""
#: ports/atmel-samd/common-hal/busio/UART.c:294
+#: ports/nrf/common-hal/busio/UART.c:195
msgid "No TX pin"
msgstr ""
@@ -409,7 +413,8 @@ msgstr ""
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:120
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:369
-#: ports/nrf/common-hal/pulseio/PWMOut.c:227
+#: ports/nrf/common-hal/pulseio/PWMOut.c:120
+#: ports/nrf/common-hal/pulseio/PWMOut.c:232
msgid "Invalid PWM frequency"
msgstr ""
@@ -690,24 +695,33 @@ msgstr ""
msgid "AnalogOut functionality not supported"
msgstr ""
-#: ports/nrf/common-hal/busio/I2C.c:91
+#: ports/nrf/common-hal/busio/I2C.c:95
msgid "All I2C peripherals are in use"
msgstr ""
-#: ports/nrf/common-hal/busio/SPI.c:109
+#: ports/nrf/common-hal/busio/SPI.c:115
msgid "All SPI peripherals are in use"
msgstr ""
-#: ports/nrf/common-hal/busio/SPI.c:170
-msgid "Baud rate too high for this SPI peripheral"
+#: ports/nrf/common-hal/busio/UART.c:48
+#, c-format
+msgid "error = 0x%08lX"
+msgstr ""
+
+#: ports/nrf/common-hal/busio/UART.c:86
+msgid "Invalid buffer size"
+msgstr ""
+
+#: ports/nrf/common-hal/busio/UART.c:90
+msgid "Odd parity is not supported"
msgstr ""
-#: ports/nrf/common-hal/busio/UART.c:43 ports/nrf/common-hal/busio/UART.c:47
-#: ports/nrf/common-hal/busio/UART.c:51 ports/nrf/common-hal/busio/UART.c:60
-#: ports/nrf/common-hal/busio/UART.c:66 ports/nrf/common-hal/busio/UART.c:71
-#: ports/nrf/common-hal/busio/UART.c:76 ports/nrf/common-hal/busio/UART.c:81
-#: ports/nrf/common-hal/busio/UART.c:86 ports/nrf/common-hal/busio/UART.c:90
-msgid "busio.UART not yet implemented"
+#: ports/nrf/common-hal/busio/UART.c:322 ports/nrf/common-hal/busio/UART.c:326
+#: ports/nrf/common-hal/busio/UART.c:331 ports/nrf/common-hal/busio/UART.c:336
+#: ports/nrf/common-hal/busio/UART.c:342 ports/nrf/common-hal/busio/UART.c:347
+#: ports/nrf/common-hal/busio/UART.c:352 ports/nrf/common-hal/busio/UART.c:356
+#: ports/nrf/common-hal/busio/UART.c:364
+msgid "busio.UART not available"
msgstr ""
#: ports/nrf/common-hal/microcontroller/Processor.c:49
@@ -715,6 +729,10 @@ msgstr ""
msgid "Can not get temperature. status: 0x%02x"
msgstr ""
+#: ports/nrf/common-hal/pulseio/PWMOut.c:162
+msgid "All PWM peripherals are in use"
+msgstr ""
+
#: ports/nrf/drivers/bluetooth/ble_drv.c:199
msgid "Cannot apply GAP parameters."
msgstr ""
@@ -751,27 +769,27 @@ msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:470
#: ports/nrf/drivers/bluetooth/ble_drv.c:520
-msgid "Can encode UUID into the advertisment packet."
+msgid "Can encode UUID into the advertisement packet."
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:545
-msgid "Can not fit data into the advertisment packet."
+msgid "Can not fit data into the advertisement packet."
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:558
#: ports/nrf/drivers/bluetooth/ble_drv.c:604
#, c-format
-msgid "Can not apply advertisment data. status: 0x%02x"
+msgid "Can not apply advertisement data. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:614
#, c-format
-msgid "Can not start advertisment. status: 0x%02x"
+msgid "Can not start advertisement. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:631
#, c-format
-msgid "Can not stop advertisment. status: 0x%02x"
+msgid "Can not stop advertisement. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:650
@@ -1078,38 +1096,85 @@ msgstr ""
msgid "'data' requires integer arguments"
msgstr ""
-#: py/emitinlinextensa.c:86
-msgid "can only have up to 4 parameters to Xtensa assembly"
+#: py/emitinlinethumb.c:102
+msgid "can only have up to 4 parameters to Thumb assembly"
msgstr ""
-#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
-msgid "parameters must be registers in sequence a2 to a5"
+#: py/emitinlinethumb.c:107 py/emitinlinethumb.c:112
+msgid "parameters must be registers in sequence r0 to r3"
msgstr ""
-#: py/emitinlinextensa.c:162
+#: py/emitinlinethumb.c:188 py/emitinlinethumb.c:230
+#, c-format
+msgid "'%s' expects at most r%d"
+msgstr ""
+
+#: py/emitinlinethumb.c:197 py/emitinlinextensa.c:162
#, c-format
msgid "'%s' expects a register"
msgstr ""
-#: py/emitinlinextensa.c:169
+#: py/emitinlinethumb.c:211
+#, c-format
+msgid "'%s' expects a special register"
+msgstr ""
+
+#: py/emitinlinethumb.c:239
+#, c-format
+msgid "'%s' expects an FPU register"
+msgstr ""
+
+#: py/emitinlinethumb.c:292
+#, c-format
+msgid "'%s' expects {r0, r1, ...}"
+msgstr ""
+
+#: py/emitinlinethumb.c:299 py/emitinlinextensa.c:169
#, c-format
msgid "'%s' expects an integer"
msgstr ""
-#: py/emitinlinextensa.c:174
+#: py/emitinlinethumb.c:304
#, c-format
-msgid "'%s' integer %d is not within range %d..%d"
+msgid "'%s' integer 0x%x does not fit in mask 0x%x"
msgstr ""
-#: py/emitinlinextensa.c:182
+#: py/emitinlinethumb.c:328
+#, c-format
+msgid "'%s' expects an address of the form [a, b]"
+msgstr ""
+
+#: py/emitinlinethumb.c:334 py/emitinlinextensa.c:182
#, c-format
msgid "'%s' expects a label"
msgstr ""
-#: py/emitinlinextensa.c:193
+#: py/emitinlinethumb.c:345 py/emitinlinextensa.c:193
msgid "label '%q' not defined"
msgstr ""
+#: py/emitinlinethumb.c:806
+#, c-format
+msgid "unsupported Thumb instruction '%s' with %d arguments"
+msgstr ""
+
+#: py/emitinlinethumb.c:810
+msgid "branch not in range"
+msgstr ""
+
+#: py/emitinlinextensa.c:86
+msgid "can only have up to 4 parameters to Xtensa assembly"
+msgstr ""
+
+#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
+msgid "parameters must be registers in sequence a2 to a5"
+msgstr ""
+
+#: py/emitinlinextensa.c:174
+#, c-format
+msgid "'%s' integer %d is not within range %d..%d"
+msgstr ""
+
#: py/emitinlinextensa.c:327
#, c-format
msgid "unsupported Xtensa instruction '%s' with %d arguments"
@@ -1966,6 +2031,22 @@ msgid ""
"destination buffer must be a bytearray or array of type 'B' for bit_depth = 8"
msgstr ""
+#: shared-bindings/audioio/Mixer.c:94
+msgid "Invalid voice count"
+msgstr ""
+
+#: shared-bindings/audioio/Mixer.c:99
+msgid "Invalid channel count"
+msgstr ""
+
+#: shared-bindings/audioio/Mixer.c:103
+msgid "Sample rate must be positive"
+msgstr ""
+
+#: shared-bindings/audioio/Mixer.c:107
+msgid "bits_per_sample must be 8 or 16"
+msgstr ""
+
#: shared-bindings/audioio/RawSample.c:98
msgid ""
"sample_source buffer must be a bytearray or array of type 'h', 'H', 'b' or "
@@ -1990,19 +2071,19 @@ msgstr ""
msgid "Buffer must be at least length 1"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:168
+#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:175
msgid "Invalid polarity"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:172
+#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:179
msgid "Invalid phase"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:176
+#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:183
msgid "Invalid number of bits"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:341
+#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:348
msgid "buffer slices must be of equal length"
msgstr ""
@@ -2163,7 +2244,7 @@ msgstr ""
#: shared-bindings/pulseio/PWMOut.c:195
msgid ""
-"PWM frequency not writeable when variable_frequency is False on construction."
+"PWM frequency not writable when variable_frequency is False on construction."
msgstr ""
#: shared-bindings/pulseio/PulseIn.c:275
@@ -2256,6 +2337,34 @@ msgid ""
"Object has been deinitialized and can no longer be used. Create a new object."
msgstr ""
+#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
+msgid "Couldn't allocate first buffer"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:53 shared-module/audioio/WaveFile.c:123
+msgid "Couldn't allocate second buffer"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:82
+msgid "Voice index too high"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:85
+msgid "The sample's sample rate does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:88
+msgid "The sample's channel count does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:91
+msgid "The sample's bits_per_sample does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:100
+msgid "The sample's signedness does not match the mixer's"
+msgstr ""
+
#: shared-module/audioio/WaveFile.c:61
msgid "Invalid wave file"
msgstr ""
@@ -2276,14 +2385,6 @@ msgstr ""
msgid "Invalid file"
msgstr ""
-#: shared-module/audioio/WaveFile.c:117
-msgid "Couldn't allocate first buffer"
-msgstr ""
-
-#: shared-module/audioio/WaveFile.c:123
-msgid "Couldn't allocate second buffer"
-msgstr ""
-
#: shared-module/bitbangio/I2C.c:58
msgid "Clock stretch too long"
msgstr ""
diff --git a/locale/de_DE.po b/locale/de_DE.po
index 72f7b254d..de9a21e96 100644
--- a/locale/de_DE.po
+++ b/locale/de_DE.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2018-09-21 12:23-0400\n"
+"POT-Creation-Date: 2018-10-09 20:51-0400\n"
"PO-Revision-Date: 2018-07-27 11:55-0700\n"
"Last-Translator: Sebastian Plamauer\n"
"Language-Team: \n"
@@ -227,7 +227,7 @@ msgstr ""
msgid "soft reboot\n"
msgstr "weicher reboot\n"
-#: ports/atmel-samd/audio_dma.c:285
+#: ports/atmel-samd/audio_dma.c:209
#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:361
msgid "All sync event channels in use"
msgstr "Alle sync event Kanäle werden benutzt"
@@ -370,7 +370,7 @@ msgstr "Nicht genug Pins vorhanden"
#: ports/atmel-samd/common-hal/busio/SPI.c:132
#: ports/atmel-samd/common-hal/busio/UART.c:119
#: ports/atmel-samd/common-hal/i2cslave/I2CSlave.c:45
-#: ports/nrf/common-hal/busio/I2C.c:77
+#: ports/nrf/common-hal/busio/I2C.c:81
msgid "Invalid pins"
msgstr "Ungültige Pins"
@@ -387,10 +387,12 @@ msgid "bytes > 8 bits not supported"
msgstr "bytes mit merh als 8 bits werden nicht unterstützt"
#: ports/atmel-samd/common-hal/busio/UART.c:72
+#: ports/nrf/common-hal/busio/UART.c:82
msgid "tx and rx cannot both be None"
msgstr "tx und rx können nicht beide None sein"
#: ports/atmel-samd/common-hal/busio/UART.c:145
+#: ports/nrf/common-hal/busio/UART.c:115
msgid "Failed to allocate RX buffer"
msgstr "Konnte keinen RX Buffer allozieren"
@@ -399,10 +401,12 @@ msgid "Could not initialize UART"
msgstr "Konnte UART nicht initialisieren"
#: ports/atmel-samd/common-hal/busio/UART.c:240
+#: ports/nrf/common-hal/busio/UART.c:149
msgid "No RX pin"
msgstr "Kein RX Pin"
#: ports/atmel-samd/common-hal/busio/UART.c:294
+#: ports/nrf/common-hal/busio/UART.c:195
msgid "No TX pin"
msgstr "Kein TX Pin"
@@ -418,7 +422,8 @@ msgstr "Reset zum bootloader nicht möglich da bootloader nicht vorhanden"
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:120
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:369
-#: ports/nrf/common-hal/pulseio/PWMOut.c:227
+#: ports/nrf/common-hal/pulseio/PWMOut.c:120
+#: ports/nrf/common-hal/pulseio/PWMOut.c:232
msgid "Invalid PWM frequency"
msgstr "Ungültige PWM Frequenz"
@@ -699,26 +704,37 @@ msgstr ""
msgid "AnalogOut functionality not supported"
msgstr ""
-#: ports/nrf/common-hal/busio/I2C.c:91
+#: ports/nrf/common-hal/busio/I2C.c:95
#, fuzzy
msgid "All I2C peripherals are in use"
msgstr "Alle timer werden benutzt"
-#: ports/nrf/common-hal/busio/SPI.c:109
+#: ports/nrf/common-hal/busio/SPI.c:115
#, fuzzy
msgid "All SPI peripherals are in use"
msgstr "Alle timer werden benutzt"
-#: ports/nrf/common-hal/busio/SPI.c:170
-msgid "Baud rate too high for this SPI peripheral"
+#: ports/nrf/common-hal/busio/UART.c:48
+#, c-format
+msgid "error = 0x%08lX"
msgstr ""
-#: ports/nrf/common-hal/busio/UART.c:43 ports/nrf/common-hal/busio/UART.c:47
-#: ports/nrf/common-hal/busio/UART.c:51 ports/nrf/common-hal/busio/UART.c:60
-#: ports/nrf/common-hal/busio/UART.c:66 ports/nrf/common-hal/busio/UART.c:71
-#: ports/nrf/common-hal/busio/UART.c:76 ports/nrf/common-hal/busio/UART.c:81
-#: ports/nrf/common-hal/busio/UART.c:86 ports/nrf/common-hal/busio/UART.c:90
-msgid "busio.UART not yet implemented"
+#: ports/nrf/common-hal/busio/UART.c:86
+#, fuzzy
+msgid "Invalid buffer size"
+msgstr "ungültiger dupterm index"
+
+#: ports/nrf/common-hal/busio/UART.c:90
+#, fuzzy
+msgid "Odd parity is not supported"
+msgstr "bytes mit merh als 8 bits werden nicht unterstützt"
+
+#: ports/nrf/common-hal/busio/UART.c:322 ports/nrf/common-hal/busio/UART.c:326
+#: ports/nrf/common-hal/busio/UART.c:331 ports/nrf/common-hal/busio/UART.c:336
+#: ports/nrf/common-hal/busio/UART.c:342 ports/nrf/common-hal/busio/UART.c:347
+#: ports/nrf/common-hal/busio/UART.c:352 ports/nrf/common-hal/busio/UART.c:356
+#: ports/nrf/common-hal/busio/UART.c:364
+msgid "busio.UART not available"
msgstr ""
#: ports/nrf/common-hal/microcontroller/Processor.c:49
@@ -726,6 +742,11 @@ msgstr ""
msgid "Can not get temperature. status: 0x%02x"
msgstr ""
+#: ports/nrf/common-hal/pulseio/PWMOut.c:162
+#, fuzzy
+msgid "All PWM peripherals are in use"
+msgstr "Alle timer werden benutzt"
+
#: ports/nrf/drivers/bluetooth/ble_drv.c:199
msgid "Cannot apply GAP parameters."
msgstr ""
@@ -762,27 +783,27 @@ msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:470
#: ports/nrf/drivers/bluetooth/ble_drv.c:520
-msgid "Can encode UUID into the advertisment packet."
+msgid "Can encode UUID into the advertisement packet."
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:545
-msgid "Can not fit data into the advertisment packet."
+msgid "Can not fit data into the advertisement packet."
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:558
#: ports/nrf/drivers/bluetooth/ble_drv.c:604
#, c-format
-msgid "Can not apply advertisment data. status: 0x%02x"
+msgid "Can not apply advertisement data. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:614
#, c-format
-msgid "Can not start advertisment. status: 0x%02x"
+msgid "Can not start advertisement. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:631
#, c-format
-msgid "Can not stop advertisment. status: 0x%02x"
+msgid "Can not stop advertisement. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:650
@@ -1089,38 +1110,86 @@ msgstr ""
msgid "'data' requires integer arguments"
msgstr ""
-#: py/emitinlinextensa.c:86
-msgid "can only have up to 4 parameters to Xtensa assembly"
+#: py/emitinlinethumb.c:102
+msgid "can only have up to 4 parameters to Thumb assembly"
msgstr ""
-#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
-msgid "parameters must be registers in sequence a2 to a5"
+#: py/emitinlinethumb.c:107 py/emitinlinethumb.c:112
+msgid "parameters must be registers in sequence r0 to r3"
+msgstr ""
+
+#: py/emitinlinethumb.c:188 py/emitinlinethumb.c:230
+#, c-format
+msgid "'%s' expects at most r%d"
msgstr ""
-#: py/emitinlinextensa.c:162
+#: py/emitinlinethumb.c:197 py/emitinlinextensa.c:162
#, c-format
msgid "'%s' expects a register"
msgstr ""
-#: py/emitinlinextensa.c:169
+#: py/emitinlinethumb.c:211
+#, c-format
+msgid "'%s' expects a special register"
+msgstr ""
+
+#: py/emitinlinethumb.c:239
+#, c-format
+msgid "'%s' expects an FPU register"
+msgstr ""
+
+#: py/emitinlinethumb.c:292
+#, c-format
+msgid "'%s' expects {r0, r1, ...}"
+msgstr ""
+
+#: py/emitinlinethumb.c:299 py/emitinlinextensa.c:169
#, c-format
msgid "'%s' expects an integer"
msgstr ""
-#: py/emitinlinextensa.c:174
+#: py/emitinlinethumb.c:304
#, c-format
-msgid "'%s' integer %d is not within range %d..%d"
+msgid "'%s' integer 0x%x does not fit in mask 0x%x"
msgstr ""
-#: py/emitinlinextensa.c:182
+#: py/emitinlinethumb.c:328
+#, c-format
+msgid "'%s' expects an address of the form [a, b]"
+msgstr ""
+
+#: py/emitinlinethumb.c:334 py/emitinlinextensa.c:182
#, c-format
msgid "'%s' expects a label"
msgstr ""
-#: py/emitinlinextensa.c:193
+#: py/emitinlinethumb.c:345 py/emitinlinextensa.c:193
msgid "label '%q' not defined"
msgstr ""
+#: py/emitinlinethumb.c:806
+#, c-format
+msgid "unsupported Thumb instruction '%s' with %d arguments"
+msgstr ""
+
+#: py/emitinlinethumb.c:810
+#, fuzzy
+msgid "branch not in range"
+msgstr "Kalibrierung ist außerhalb der Reichweite"
+
+#: py/emitinlinextensa.c:86
+msgid "can only have up to 4 parameters to Xtensa assembly"
+msgstr ""
+
+#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
+msgid "parameters must be registers in sequence a2 to a5"
+msgstr ""
+
+#: py/emitinlinextensa.c:174
+#, c-format
+msgid "'%s' integer %d is not within range %d..%d"
+msgstr ""
+
#: py/emitinlinextensa.c:327
#, c-format
msgid "unsupported Xtensa instruction '%s' with %d arguments"
@@ -1977,6 +2046,25 @@ msgid ""
"destination buffer must be a bytearray or array of type 'B' for bit_depth = 8"
msgstr ""
+#: shared-bindings/audioio/Mixer.c:94
+#, fuzzy
+msgid "Invalid voice count"
+msgstr "Ungültiger clock pin"
+
+#: shared-bindings/audioio/Mixer.c:99
+#, fuzzy
+msgid "Invalid channel count"
+msgstr "Ungültiger clock pin"
+
+#: shared-bindings/audioio/Mixer.c:103
+msgid "Sample rate must be positive"
+msgstr ""
+
+#: shared-bindings/audioio/Mixer.c:107
+#, fuzzy
+msgid "bits_per_sample must be 8 or 16"
+msgstr "bits müssen 8 sein"
+
#: shared-bindings/audioio/RawSample.c:98
msgid ""
"sample_source buffer must be a bytearray or array of type 'h', 'H', 'b' or "
@@ -2001,19 +2089,19 @@ msgstr ""
msgid "Buffer must be at least length 1"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:168
+#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:175
msgid "Invalid polarity"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:172
+#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:179
msgid "Invalid phase"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:176
+#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:183
msgid "Invalid number of bits"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:341
+#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:348
msgid "buffer slices must be of equal length"
msgstr ""
@@ -2175,7 +2263,7 @@ msgstr ""
#: shared-bindings/pulseio/PWMOut.c:195
msgid ""
-"PWM frequency not writeable when variable_frequency is False on construction."
+"PWM frequency not writable when variable_frequency is False on construction."
msgstr ""
#: shared-bindings/pulseio/PulseIn.c:275
@@ -2268,6 +2356,34 @@ msgid ""
"Object has been deinitialized and can no longer be used. Create a new object."
msgstr ""
+#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
+msgid "Couldn't allocate first buffer"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:53 shared-module/audioio/WaveFile.c:123
+msgid "Couldn't allocate second buffer"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:82
+msgid "Voice index too high"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:85
+msgid "The sample's sample rate does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:88
+msgid "The sample's channel count does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:91
+msgid "The sample's bits_per_sample does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:100
+msgid "The sample's signedness does not match the mixer's"
+msgstr ""
+
#: shared-module/audioio/WaveFile.c:61
msgid "Invalid wave file"
msgstr ""
@@ -2288,14 +2404,6 @@ msgstr ""
msgid "Invalid file"
msgstr ""
-#: shared-module/audioio/WaveFile.c:117
-msgid "Couldn't allocate first buffer"
-msgstr ""
-
-#: shared-module/audioio/WaveFile.c:123
-msgid "Couldn't allocate second buffer"
-msgstr ""
-
#: shared-module/bitbangio/I2C.c:58
msgid "Clock stretch too long"
msgstr ""
diff --git a/locale/en_US.po b/locale/en_US.po
index 63ae50ba5..15c97e329 100644
--- a/locale/en_US.po
+++ b/locale/en_US.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2018-09-21 12:23-0400\n"
+"POT-Creation-Date: 2018-10-09 20:51-0400\n"
"PO-Revision-Date: 2018-07-27 11:55-0700\n"
"Last-Translator: \n"
"Language-Team: \n"
@@ -218,7 +218,7 @@ msgstr ""
msgid "soft reboot\n"
msgstr ""
-#: ports/atmel-samd/audio_dma.c:285
+#: ports/atmel-samd/audio_dma.c:209
#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:361
msgid "All sync event channels in use"
msgstr ""
@@ -361,7 +361,7 @@ msgstr ""
#: ports/atmel-samd/common-hal/busio/SPI.c:132
#: ports/atmel-samd/common-hal/busio/UART.c:119
#: ports/atmel-samd/common-hal/i2cslave/I2CSlave.c:45
-#: ports/nrf/common-hal/busio/I2C.c:77
+#: ports/nrf/common-hal/busio/I2C.c:81
msgid "Invalid pins"
msgstr ""
@@ -378,10 +378,12 @@ msgid "bytes > 8 bits not supported"
msgstr ""
#: ports/atmel-samd/common-hal/busio/UART.c:72
+#: ports/nrf/common-hal/busio/UART.c:82
msgid "tx and rx cannot both be None"
msgstr ""
#: ports/atmel-samd/common-hal/busio/UART.c:145
+#: ports/nrf/common-hal/busio/UART.c:115
msgid "Failed to allocate RX buffer"
msgstr ""
@@ -390,10 +392,12 @@ msgid "Could not initialize UART"
msgstr ""
#: ports/atmel-samd/common-hal/busio/UART.c:240
+#: ports/nrf/common-hal/busio/UART.c:149
msgid "No RX pin"
msgstr ""
#: ports/atmel-samd/common-hal/busio/UART.c:294
+#: ports/nrf/common-hal/busio/UART.c:195
msgid "No TX pin"
msgstr ""
@@ -409,7 +413,8 @@ msgstr ""
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:120
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:369
-#: ports/nrf/common-hal/pulseio/PWMOut.c:227
+#: ports/nrf/common-hal/pulseio/PWMOut.c:120
+#: ports/nrf/common-hal/pulseio/PWMOut.c:232
msgid "Invalid PWM frequency"
msgstr ""
@@ -690,24 +695,33 @@ msgstr ""
msgid "AnalogOut functionality not supported"
msgstr ""
-#: ports/nrf/common-hal/busio/I2C.c:91
+#: ports/nrf/common-hal/busio/I2C.c:95
msgid "All I2C peripherals are in use"
msgstr ""
-#: ports/nrf/common-hal/busio/SPI.c:109
+#: ports/nrf/common-hal/busio/SPI.c:115
msgid "All SPI peripherals are in use"
msgstr ""
-#: ports/nrf/common-hal/busio/SPI.c:170
-msgid "Baud rate too high for this SPI peripheral"
+#: ports/nrf/common-hal/busio/UART.c:48
+#, c-format
+msgid "error = 0x%08lX"
+msgstr ""
+
+#: ports/nrf/common-hal/busio/UART.c:86
+msgid "Invalid buffer size"
+msgstr ""
+
+#: ports/nrf/common-hal/busio/UART.c:90
+msgid "Odd parity is not supported"
msgstr ""
-#: ports/nrf/common-hal/busio/UART.c:43 ports/nrf/common-hal/busio/UART.c:47
-#: ports/nrf/common-hal/busio/UART.c:51 ports/nrf/common-hal/busio/UART.c:60
-#: ports/nrf/common-hal/busio/UART.c:66 ports/nrf/common-hal/busio/UART.c:71
-#: ports/nrf/common-hal/busio/UART.c:76 ports/nrf/common-hal/busio/UART.c:81
-#: ports/nrf/common-hal/busio/UART.c:86 ports/nrf/common-hal/busio/UART.c:90
-msgid "busio.UART not yet implemented"
+#: ports/nrf/common-hal/busio/UART.c:322 ports/nrf/common-hal/busio/UART.c:326
+#: ports/nrf/common-hal/busio/UART.c:331 ports/nrf/common-hal/busio/UART.c:336
+#: ports/nrf/common-hal/busio/UART.c:342 ports/nrf/common-hal/busio/UART.c:347
+#: ports/nrf/common-hal/busio/UART.c:352 ports/nrf/common-hal/busio/UART.c:356
+#: ports/nrf/common-hal/busio/UART.c:364
+msgid "busio.UART not available"
msgstr ""
#: ports/nrf/common-hal/microcontroller/Processor.c:49
@@ -715,6 +729,10 @@ msgstr ""
msgid "Can not get temperature. status: 0x%02x"
msgstr ""
+#: ports/nrf/common-hal/pulseio/PWMOut.c:162
+msgid "All PWM peripherals are in use"
+msgstr ""
+
#: ports/nrf/drivers/bluetooth/ble_drv.c:199
msgid "Cannot apply GAP parameters."
msgstr ""
@@ -751,27 +769,27 @@ msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:470
#: ports/nrf/drivers/bluetooth/ble_drv.c:520
-msgid "Can encode UUID into the advertisment packet."
+msgid "Can encode UUID into the advertisement packet."
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:545
-msgid "Can not fit data into the advertisment packet."
+msgid "Can not fit data into the advertisement packet."
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:558
#: ports/nrf/drivers/bluetooth/ble_drv.c:604
#, c-format
-msgid "Can not apply advertisment data. status: 0x%02x"
+msgid "Can not apply advertisement data. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:614
#, c-format
-msgid "Can not start advertisment. status: 0x%02x"
+msgid "Can not start advertisement. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:631
#, c-format
-msgid "Can not stop advertisment. status: 0x%02x"
+msgid "Can not stop advertisement. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:650
@@ -1078,38 +1096,85 @@ msgstr ""
msgid "'data' requires integer arguments"
msgstr ""
-#: py/emitinlinextensa.c:86
-msgid "can only have up to 4 parameters to Xtensa assembly"
+#: py/emitinlinethumb.c:102
+msgid "can only have up to 4 parameters to Thumb assembly"
msgstr ""
-#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
-msgid "parameters must be registers in sequence a2 to a5"
+#: py/emitinlinethumb.c:107 py/emitinlinethumb.c:112
+msgid "parameters must be registers in sequence r0 to r3"
msgstr ""
-#: py/emitinlinextensa.c:162
+#: py/emitinlinethumb.c:188 py/emitinlinethumb.c:230
+#, c-format
+msgid "'%s' expects at most r%d"
+msgstr ""
+
+#: py/emitinlinethumb.c:197 py/emitinlinextensa.c:162
#, c-format
msgid "'%s' expects a register"
msgstr ""
-#: py/emitinlinextensa.c:169
+#: py/emitinlinethumb.c:211
+#, c-format
+msgid "'%s' expects a special register"
+msgstr ""
+
+#: py/emitinlinethumb.c:239
+#, c-format
+msgid "'%s' expects an FPU register"
+msgstr ""
+
+#: py/emitinlinethumb.c:292
+#, c-format
+msgid "'%s' expects {r0, r1, ...}"
+msgstr ""
+
+#: py/emitinlinethumb.c:299 py/emitinlinextensa.c:169
#, c-format
msgid "'%s' expects an integer"
msgstr ""
-#: py/emitinlinextensa.c:174
+#: py/emitinlinethumb.c:304
#, c-format
-msgid "'%s' integer %d is not within range %d..%d"
+msgid "'%s' integer 0x%x does not fit in mask 0x%x"
msgstr ""
-#: py/emitinlinextensa.c:182
+#: py/emitinlinethumb.c:328
+#, c-format
+msgid "'%s' expects an address of the form [a, b]"
+msgstr ""
+
+#: py/emitinlinethumb.c:334 py/emitinlinextensa.c:182
#, c-format
msgid "'%s' expects a label"
msgstr ""
-#: py/emitinlinextensa.c:193
+#: py/emitinlinethumb.c:345 py/emitinlinextensa.c:193
msgid "label '%q' not defined"
msgstr ""
+#: py/emitinlinethumb.c:806
+#, c-format
+msgid "unsupported Thumb instruction '%s' with %d arguments"
+msgstr ""
+
+#: py/emitinlinethumb.c:810
+msgid "branch not in range"
+msgstr ""
+
+#: py/emitinlinextensa.c:86
+msgid "can only have up to 4 parameters to Xtensa assembly"
+msgstr ""
+
+#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
+msgid "parameters must be registers in sequence a2 to a5"
+msgstr ""
+
+#: py/emitinlinextensa.c:174
+#, c-format
+msgid "'%s' integer %d is not within range %d..%d"
+msgstr ""
+
#: py/emitinlinextensa.c:327
#, c-format
msgid "unsupported Xtensa instruction '%s' with %d arguments"
@@ -1966,6 +2031,22 @@ msgid ""
"destination buffer must be a bytearray or array of type 'B' for bit_depth = 8"
msgstr ""
+#: shared-bindings/audioio/Mixer.c:94
+msgid "Invalid voice count"
+msgstr ""
+
+#: shared-bindings/audioio/Mixer.c:99
+msgid "Invalid channel count"
+msgstr ""
+
+#: shared-bindings/audioio/Mixer.c:103
+msgid "Sample rate must be positive"
+msgstr ""
+
+#: shared-bindings/audioio/Mixer.c:107
+msgid "bits_per_sample must be 8 or 16"
+msgstr ""
+
#: shared-bindings/audioio/RawSample.c:98
msgid ""
"sample_source buffer must be a bytearray or array of type 'h', 'H', 'b' or "
@@ -1990,19 +2071,19 @@ msgstr ""
msgid "Buffer must be at least length 1"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:168
+#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:175
msgid "Invalid polarity"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:172
+#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:179
msgid "Invalid phase"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:176
+#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:183
msgid "Invalid number of bits"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:341
+#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:348
msgid "buffer slices must be of equal length"
msgstr ""
@@ -2163,7 +2244,7 @@ msgstr ""
#: shared-bindings/pulseio/PWMOut.c:195
msgid ""
-"PWM frequency not writeable when variable_frequency is False on construction."
+"PWM frequency not writable when variable_frequency is False on construction."
msgstr ""
#: shared-bindings/pulseio/PulseIn.c:275
@@ -2256,6 +2337,34 @@ msgid ""
"Object has been deinitialized and can no longer be used. Create a new object."
msgstr ""
+#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
+msgid "Couldn't allocate first buffer"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:53 shared-module/audioio/WaveFile.c:123
+msgid "Couldn't allocate second buffer"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:82
+msgid "Voice index too high"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:85
+msgid "The sample's sample rate does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:88
+msgid "The sample's channel count does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:91
+msgid "The sample's bits_per_sample does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:100
+msgid "The sample's signedness does not match the mixer's"
+msgstr ""
+
#: shared-module/audioio/WaveFile.c:61
msgid "Invalid wave file"
msgstr ""
@@ -2276,14 +2385,6 @@ msgstr ""
msgid "Invalid file"
msgstr ""
-#: shared-module/audioio/WaveFile.c:117
-msgid "Couldn't allocate first buffer"
-msgstr ""
-
-#: shared-module/audioio/WaveFile.c:123
-msgid "Couldn't allocate second buffer"
-msgstr ""
-
#: shared-module/bitbangio/I2C.c:58
msgid "Clock stretch too long"
msgstr ""
diff --git a/locale/es.po b/locale/es.po
index 48cfdcda8..324fe0720 100644
--- a/locale/es.po
+++ b/locale/es.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2018-09-21 12:23-0400\n"
+"POT-Creation-Date: 2018-10-09 20:51-0400\n"
"PO-Revision-Date: 2018-08-24 22:56-0500\n"
"Last-Translator: \n"
"Language-Team: \n"
@@ -233,7 +233,7 @@ msgstr ""
msgid "soft reboot\n"
msgstr "reinicio suave\n"
-#: ports/atmel-samd/audio_dma.c:285
+#: ports/atmel-samd/audio_dma.c:209
#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:361
msgid "All sync event channels in use"
msgstr "Todos los sync event channels están siendo utilizados"
@@ -343,11 +343,11 @@ msgstr "pin inválido"
#: ports/atmel-samd/common-hal/audioio/AudioOut.c:84
msgid "Invalid pin for left channel"
-msgstr ""
+msgstr "Pin inválido para canal izquierdo"
#: ports/atmel-samd/common-hal/audioio/AudioOut.c:88
msgid "Invalid pin for right channel"
-msgstr ""
+msgstr "Pin inválido para canal derecho"
#: ports/atmel-samd/common-hal/audioio/AudioOut.c:91
msgid "Cannot output both channels on the same pin"
@@ -366,7 +366,7 @@ msgstr "Todos los canales de eventos están siendo utilizados"
#: ports/atmel-samd/common-hal/audioio/AudioOut.c:297
#, c-format
msgid "Sample rate too high. It must be less than %d"
-msgstr ""
+msgstr "Frecuencia de muestreo demasiado alta. Debe ser menor que %d"
#: ports/atmel-samd/common-hal/busio/I2C.c:71
msgid "Not enough pins available"
@@ -376,57 +376,62 @@ msgstr "No hay suficientes pines disponibles"
#: ports/atmel-samd/common-hal/busio/SPI.c:132
#: ports/atmel-samd/common-hal/busio/UART.c:119
#: ports/atmel-samd/common-hal/i2cslave/I2CSlave.c:45
-#: ports/nrf/common-hal/busio/I2C.c:77
+#: ports/nrf/common-hal/busio/I2C.c:81
msgid "Invalid pins"
msgstr "pines inválidos"
#: ports/atmel-samd/common-hal/busio/I2C.c:101
msgid "SDA or SCL needs a pull up"
-msgstr ""
+msgstr "SDA o SCL necesitan una pull up"
#: ports/atmel-samd/common-hal/busio/I2C.c:121
msgid "Unsupported baudrate"
-msgstr ""
+msgstr "Baudrate sin soporte"
#: ports/atmel-samd/common-hal/busio/UART.c:66
msgid "bytes > 8 bits not supported"
msgstr "bytes > 8 bits no son soportados"
#: ports/atmel-samd/common-hal/busio/UART.c:72
+#: ports/nrf/common-hal/busio/UART.c:82
msgid "tx and rx cannot both be None"
msgstr "tx y rx no pueden ser ambos None"
#: ports/atmel-samd/common-hal/busio/UART.c:145
+#: ports/nrf/common-hal/busio/UART.c:115
msgid "Failed to allocate RX buffer"
msgstr "Fallo la asignación del buffer RX"
#: ports/atmel-samd/common-hal/busio/UART.c:153
msgid "Could not initialize UART"
-msgstr ""
+msgstr "No se pudo inicializar la UART"
#: ports/atmel-samd/common-hal/busio/UART.c:240
+#: ports/nrf/common-hal/busio/UART.c:149
msgid "No RX pin"
-msgstr ""
+msgstr "Sin pin RX"
#: ports/atmel-samd/common-hal/busio/UART.c:294
+#: ports/nrf/common-hal/busio/UART.c:195
msgid "No TX pin"
-msgstr ""
+msgstr "Sin pin TX"
#: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c:170
#: ports/nrf/common-hal/digitalio/DigitalInOut.c:142
msgid "Cannot get pull while in output mode"
-msgstr ""
+msgstr "No se puede obtener pull mientras en modo de salida"
#: ports/atmel-samd/common-hal/microcontroller/__init__.c:74
#: ports/esp8266/common-hal/microcontroller/__init__.c:64
msgid "Cannot reset into bootloader because no bootloader is present."
-msgstr ""
+msgstr "No se puede reiniciar en bootloader porque no hay bootloader presente."
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:120
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:369
-#: ports/nrf/common-hal/pulseio/PWMOut.c:227
+#: ports/nrf/common-hal/pulseio/PWMOut.c:120
+#: ports/nrf/common-hal/pulseio/PWMOut.c:232
msgid "Invalid PWM frequency"
-msgstr ""
+msgstr "Frecuencia PWM inválida"
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:187
msgid "All timers for this pin are in use"
@@ -434,7 +439,7 @@ msgstr "Todos los timers para este pin están siendo utilizados"
#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:110
msgid "No hardware support on pin"
-msgstr ""
+msgstr "pin no tiene soporte en hardware"
#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:113
msgid "EXTINT channel already in use"
@@ -449,16 +454,16 @@ msgstr "Fallo la asignación del buffer RX de %d bytes"
#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:205
#: ports/esp8266/common-hal/pulseio/PulseIn.c:151
msgid "pop from an empty PulseIn"
-msgstr ""
+msgstr "pop en un PulseIn vacío"
#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:237
#: ports/esp8266/common-hal/pulseio/PulseIn.c:182 py/obj.c:420
msgid "index out of range"
-msgstr ""
+msgstr "index fuera de rango"
#: ports/atmel-samd/common-hal/pulseio/PulseOut.c:178
msgid "Another send is already active"
-msgstr ""
+msgstr "Otro envío ya está activo"
#: ports/atmel-samd/common-hal/rotaryio/IncrementalEncoder.c:38
msgid "Both pins must support hardware interrupts"
@@ -474,11 +479,11 @@ msgstr "Valor de calibración fuera de rango +/-127"
#: ports/atmel-samd/common-hal/storage/__init__.c:48
msgid "Cannot remount '/' when USB is active."
-msgstr ""
+msgstr "No se puede volver a montar '/' cuando el USB esta activo."
#: ports/atmel-samd/common-hal/touchio/TouchIn.c:75
msgid "No free GCLKs"
-msgstr ""
+msgstr "Sin GCLKs libres"
#: ports/atmel-samd/common-hal/usb_hid/Device.c:78
#: ports/nrf/common-hal/usb_hid/Device.c:45
@@ -489,48 +494,48 @@ msgstr "Tamaño de buffer incorrecto. Debe ser de %d bytes."
#: ports/atmel-samd/common-hal/usb_hid/Device.c:82
#: ports/nrf/common-hal/usb_hid/Device.c:53
msgid "USB Busy"
-msgstr ""
+msgstr "USB ocupado"
#: ports/atmel-samd/common-hal/usb_hid/Device.c:82
#: ports/nrf/common-hal/usb_hid/Device.c:59
msgid "USB Error"
-msgstr ""
+msgstr "Error USB"
#: ports/esp8266/common-hal/analogio/AnalogIn.c:43
msgid "Pin %q does not have ADC capabilities"
-msgstr ""
+msgstr "Pin %q no tiene capacidades ADC"
#: ports/esp8266/common-hal/analogio/AnalogOut.c:39
msgid "No hardware support for analog out."
-msgstr ""
+msgstr "Sin soporte de hardware para salida análoga"
#: ports/esp8266/common-hal/busio/SPI.c:72
msgid "Pins not valid for SPI"
-msgstr ""
+msgstr "Pines no válidos para SPI"
#: ports/esp8266/common-hal/busio/UART.c:45
msgid "Only tx supported on UART1 (GPIO2)."
-msgstr ""
+msgstr "Solo tx soportada en UART1 (GPIO2)"
#: ports/esp8266/common-hal/busio/UART.c:67 ports/esp8266/machine_uart.c:108
msgid "invalid data bits"
-msgstr ""
+msgstr "data bits inválidos"
#: ports/esp8266/common-hal/busio/UART.c:91 ports/esp8266/machine_uart.c:144
msgid "invalid stop bits"
-msgstr ""
+msgstr "stop bits inválidos"
#: ports/esp8266/common-hal/digitalio/DigitalInOut.c:200
msgid "ESP8266 does not support pull down."
-msgstr ""
+msgstr "ESP8266 no tiene soporte para pull down"
#: ports/esp8266/common-hal/digitalio/DigitalInOut.c:210
msgid "GPIO16 does not support pull up."
-msgstr "GPIO16 no soporta pull up."
+msgstr "GPIO16 no tiene soporte para pull up."
#: ports/esp8266/common-hal/microcontroller/__init__.c:66
msgid "ESP8226 does not support safe mode."
-msgstr "ESP8226 no soporta modo seguro"
+msgstr "ESP8226 no tiene soporte para modo seguro"
#: ports/esp8266/common-hal/pulseio/PWMOut.c:54
#: ports/esp8266/common-hal/pulseio/PWMOut.c:113
@@ -564,273 +569,288 @@ msgstr "No se pudo montar de nuevo el sistema de archivos"
#: ports/esp8266/common-hal/storage/__init__.c:38
msgid "Use esptool to erase flash and re-upload Python instead"
-msgstr ""
+msgstr "Usa esptool para borrar la flash y vuelve a cargar Python en su lugar"
#: ports/esp8266/esp_mphal.c:154
msgid "C-level assert"
-msgstr ""
+msgstr "C-level assert"
#: ports/esp8266/machine_adc.c:57
#, c-format
msgid "not a valid ADC Channel: %d"
-msgstr ""
+msgstr "no es un canal ADC válido: %d"
#: ports/esp8266/machine_hspi.c:131 ports/esp8266/machine_hspi.c:137
msgid "impossible baudrate"
-msgstr ""
+msgstr "baudrate imposible"
#: ports/esp8266/machine_pin.c:129
msgid "expecting a pin"
-msgstr ""
+msgstr "esperando un pin"
#: ports/esp8266/machine_pin.c:284
msgid "Pin(16) doesn't support pull"
-msgstr ""
+msgstr "Pin(16) no tiene soporte para pull"
#: ports/esp8266/machine_pin.c:323
msgid "invalid pin"
-msgstr ""
+msgstr "pin inválido"
#: ports/esp8266/machine_pin.c:389
msgid "pin does not have IRQ capabilities"
-msgstr ""
+msgstr "pin no tiene capacidades IRQ"
#: ports/esp8266/machine_rtc.c:185
msgid "buffer too long"
-msgstr ""
+msgstr "buffer demasiado largo"
#: ports/esp8266/machine_rtc.c:209 ports/esp8266/machine_rtc.c:223
#: ports/esp8266/machine_rtc.c:246
msgid "invalid alarm"
-msgstr ""
+msgstr "alarma inválida"
#: ports/esp8266/machine_uart.c:169
#, c-format
msgid "UART(%d) does not exist"
-msgstr ""
+msgstr "UART(%d) no existe"
#: ports/esp8266/machine_uart.c:219
msgid "UART(1) can't read"
-msgstr ""
+msgstr "UART(1) no puede leer"
#: ports/esp8266/modesp.c:119
msgid "len must be multiple of 4"
-msgstr ""
+msgstr "len debe de ser múltiple de 4"
#: ports/esp8266/modesp.c:274
#, c-format
msgid "memory allocation failed, allocating %u bytes for native code"
msgstr ""
+"la asignación de memoria ha fallado, asignando %u bytes para código nativo"
#: ports/esp8266/modesp.c:317
msgid "flash location must be below 1MByte"
-msgstr ""
+msgstr "la ubicación de la flash debe estar debajo de 1MByte"
#: ports/esp8266/modmachine.c:63
msgid "frequency can only be either 80Mhz or 160MHz"
-msgstr ""
+msgstr "la frecuencia solo puede ser 80MHz o 160MHz"
#: ports/esp8266/modnetwork.c:61
msgid "AP required"
-msgstr ""
+msgstr "AP necesario"
#: ports/esp8266/modnetwork.c:61
msgid "STA required"
-msgstr ""
+msgstr "STA necesario"
#: ports/esp8266/modnetwork.c:87
msgid "Cannot update i/f status"
-msgstr ""
+msgstr "No se puede actualizar i/f status"
#: ports/esp8266/modnetwork.c:142
msgid "Cannot set STA config"
-msgstr ""
+msgstr "No se puede establecer STA config"
#: ports/esp8266/modnetwork.c:144
msgid "Cannot connect to AP"
-msgstr ""
+msgstr "No se puede conectar a AP"
#: ports/esp8266/modnetwork.c:152
msgid "Cannot disconnect from AP"
-msgstr ""
+msgstr "No se puede desconectar de AP"
#: ports/esp8266/modnetwork.c:173
msgid "unknown status param"
-msgstr ""
+msgstr "status param desconocido"
#: ports/esp8266/modnetwork.c:222
msgid "STA must be active"
-msgstr ""
+msgstr "STA debe estar activo"
#: ports/esp8266/modnetwork.c:239
msgid "scan failed"
-msgstr ""
+msgstr "scan ha fallado"
#: ports/esp8266/modnetwork.c:306
msgid "wifi_set_ip_info() failed"
-msgstr ""
+msgstr "wifi_set_ip_info() ha fallado"
#: ports/esp8266/modnetwork.c:319
msgid "either pos or kw args are allowed"
-msgstr ""
+msgstr "ya sea pos o kw args son permitidos"
#: ports/esp8266/modnetwork.c:329
msgid "can't get STA config"
-msgstr ""
+msgstr "no se puede obtener STA config"
#: ports/esp8266/modnetwork.c:331
msgid "can't get AP config"
-msgstr ""
+msgstr "no se puede obtener AP config"
#: ports/esp8266/modnetwork.c:346
msgid "invalid buffer length"
-msgstr ""
+msgstr "longitud de buffer inválida"
#: ports/esp8266/modnetwork.c:405
msgid "can't set STA config"
-msgstr ""
+msgstr "no se puede establecer STA config"
#: ports/esp8266/modnetwork.c:407
msgid "can't set AP config"
-msgstr ""
+msgstr "no se puede establecer AP config"
#: ports/esp8266/modnetwork.c:416
msgid "can query only one param"
-msgstr ""
+msgstr "puede consultar solo un param"
#: ports/esp8266/modnetwork.c:469
msgid "unknown config param"
-msgstr ""
+msgstr "parámetro config desconocido"
#: ports/nrf/common-hal/analogio/AnalogOut.c:37
msgid "AnalogOut functionality not supported"
-msgstr ""
+msgstr "Funcionalidad AnalogOut no soportada"
-#: ports/nrf/common-hal/busio/I2C.c:91
+#: ports/nrf/common-hal/busio/I2C.c:95
msgid "All I2C peripherals are in use"
msgstr "Todos los timers están siendo utilizados"
-#: ports/nrf/common-hal/busio/SPI.c:109
+#: ports/nrf/common-hal/busio/SPI.c:115
msgid "All SPI peripherals are in use"
msgstr "Todos los timers están siendo utilizados"
-#: ports/nrf/common-hal/busio/SPI.c:170
-msgid "Baud rate too high for this SPI peripheral"
-msgstr ""
+#: ports/nrf/common-hal/busio/UART.c:48
+#, c-format
+msgid "error = 0x%08lX"
+msgstr "error = 0x%08lx"
-#: ports/nrf/common-hal/busio/UART.c:43 ports/nrf/common-hal/busio/UART.c:47
-#: ports/nrf/common-hal/busio/UART.c:51 ports/nrf/common-hal/busio/UART.c:60
-#: ports/nrf/common-hal/busio/UART.c:66 ports/nrf/common-hal/busio/UART.c:71
-#: ports/nrf/common-hal/busio/UART.c:76 ports/nrf/common-hal/busio/UART.c:81
-#: ports/nrf/common-hal/busio/UART.c:86 ports/nrf/common-hal/busio/UART.c:90
-msgid "busio.UART not yet implemented"
-msgstr ""
+#: ports/nrf/common-hal/busio/UART.c:86
+msgid "Invalid buffer size"
+msgstr "Tamaño de buffer inválido"
+
+#: ports/nrf/common-hal/busio/UART.c:90
+msgid "Odd parity is not supported"
+msgstr "Paridad impar no soportada"
+
+#: ports/nrf/common-hal/busio/UART.c:322 ports/nrf/common-hal/busio/UART.c:326
+#: ports/nrf/common-hal/busio/UART.c:331 ports/nrf/common-hal/busio/UART.c:336
+#: ports/nrf/common-hal/busio/UART.c:342 ports/nrf/common-hal/busio/UART.c:347
+#: ports/nrf/common-hal/busio/UART.c:352 ports/nrf/common-hal/busio/UART.c:356
+#: ports/nrf/common-hal/busio/UART.c:364
+msgid "busio.UART not available"
+msgstr "busio.UART no disponible"
#: ports/nrf/common-hal/microcontroller/Processor.c:49
#, c-format
msgid "Can not get temperature. status: 0x%02x"
-msgstr ""
+msgstr "No se puede obtener la temperatura. status: 0x%02x"
+
+#: ports/nrf/common-hal/pulseio/PWMOut.c:162
+#, fuzzy
+msgid "All PWM peripherals are in use"
+msgstr "Todos los timers están siendo utilizados"
#: ports/nrf/drivers/bluetooth/ble_drv.c:199
msgid "Cannot apply GAP parameters."
-msgstr ""
+msgstr "No se pueden aplicar los parámetros GAP."
#: ports/nrf/drivers/bluetooth/ble_drv.c:213
msgid "Cannot set PPCP parameters."
-msgstr ""
+msgstr "No se pueden establecer los parámetros PPCP."
#: ports/nrf/drivers/bluetooth/ble_drv.c:245
msgid "Can not query for the device address."
-msgstr ""
+msgstr "No se puede consultar la dirección del dispositivo."
#: ports/nrf/drivers/bluetooth/ble_drv.c:264
msgid "Can not add Vendor Specific 128-bit UUID."
-msgstr ""
+msgstr "No se puede agregar el UUID de 128-bits Especifico del Vendedor."
#: ports/nrf/drivers/bluetooth/ble_drv.c:284
#: ports/nrf/drivers/bluetooth/ble_drv.c:298
msgid "Can not add Service."
-msgstr ""
+msgstr "No se puede agregar el Servicio"
#: ports/nrf/drivers/bluetooth/ble_drv.c:373
msgid "Can not add Characteristic."
-msgstr ""
+msgstr "No se puede agregar la Característica"
#: ports/nrf/drivers/bluetooth/ble_drv.c:400
msgid "Can not apply device name in the stack."
-msgstr ""
+msgstr "No se puede aplicar el nombre del dispositivo en el stack."
#: ports/nrf/drivers/bluetooth/ble_drv.c:464
#: ports/nrf/drivers/bluetooth/ble_drv.c:514
msgid "Can not encode UUID, to check length."
-msgstr ""
+msgstr "No se puede codificar el UUID, para revisar la longitud."
#: ports/nrf/drivers/bluetooth/ble_drv.c:470
#: ports/nrf/drivers/bluetooth/ble_drv.c:520
-msgid "Can encode UUID into the advertisment packet."
-msgstr ""
+msgid "Can encode UUID into the advertisement packet."
+msgstr "Se puede codificar el UUID en el paquete de anuncio."
#: ports/nrf/drivers/bluetooth/ble_drv.c:545
-msgid "Can not fit data into the advertisment packet."
-msgstr ""
+msgid "Can not fit data into the advertisement packet."
+msgstr "Los datos no caben en el paquete de anuncio."
#: ports/nrf/drivers/bluetooth/ble_drv.c:558
#: ports/nrf/drivers/bluetooth/ble_drv.c:604
#, c-format
-msgid "Can not apply advertisment data. status: 0x%02x"
-msgstr ""
+msgid "Can not apply advertisement data. status: 0x%02x"
+msgstr "No se puede aplicar los datos de anuncio. status: 0x%02x"
#: ports/nrf/drivers/bluetooth/ble_drv.c:614
#, c-format
-msgid "Can not start advertisment. status: 0x%02x"
-msgstr ""
+msgid "Can not start advertisement. status: 0x%02x"
+msgstr "No se puede inicar el anuncio. status: 0x%02x"
#: ports/nrf/drivers/bluetooth/ble_drv.c:631
#, c-format
-msgid "Can not stop advertisment. status: 0x%02x"
-msgstr ""
+msgid "Can not stop advertisement. status: 0x%02x"
+msgstr "No se puede detener el anuncio. status: 0x%02x"
#: ports/nrf/drivers/bluetooth/ble_drv.c:650
#: ports/nrf/drivers/bluetooth/ble_drv.c:726
#, c-format
msgid "Can not read attribute value. status: 0x%02x"
-msgstr ""
+msgstr "No se puede leer el valor del atributo. status 0x%02x"
#: ports/nrf/drivers/bluetooth/ble_drv.c:667
#: ports/nrf/drivers/bluetooth/ble_drv.c:756
#, c-format
msgid "Can not write attribute value. status: 0x%02x"
-msgstr ""
+msgstr "No se puede escribir el valor del atributo. status: 0x%02x"
#: ports/nrf/drivers/bluetooth/ble_drv.c:691
#, c-format
msgid "Can not notify attribute value. status: 0x%02x"
-msgstr ""
+msgstr "No se puede notificar el valor del anuncio. status: 0x%02x"
#: ports/nrf/drivers/bluetooth/ble_drv.c:784
#, c-format
msgid "Can not start scanning. status: 0x%02x"
-msgstr ""
+msgstr "No se puede iniciar el escaneo. status: 0x%02x"
#: ports/nrf/drivers/bluetooth/ble_drv.c:829
#, c-format
msgid "Can not connect. status: 0x%02x"
-msgstr ""
+msgstr "No se puede conectar. status: 0x%02x"
#: ports/nrf/modules/ubluepy/ubluepy_characteristic.c:68
#: ports/nrf/modules/ubluepy/ubluepy_service.c:80
#: ports/nrf/modules/ubluepy/ubluepy_service.c:132
#: ports/nrf/modules/ubluepy/ubluepy_uuid.c:137
msgid "Invalid UUID parameter"
-msgstr ""
+msgstr "Parámetro UUID inválido"
#: ports/nrf/modules/ubluepy/ubluepy_service.c:73
msgid "Invalid Service type"
-msgstr ""
+msgstr "Tipo de Servicio inválido"
#: ports/nrf/modules/ubluepy/ubluepy_uuid.c:127
msgid "Invalid UUID string length"
-msgstr ""
+msgstr "Longitud de string UUID inválida"
#: ports/unix/modffi.c:138
msgid "Unknown type"
@@ -1095,38 +1115,86 @@ msgstr ""
msgid "'data' requires integer arguments"
msgstr ""
-#: py/emitinlinextensa.c:86
-msgid "can only have up to 4 parameters to Xtensa assembly"
+#: py/emitinlinethumb.c:102
+msgid "can only have up to 4 parameters to Thumb assembly"
msgstr ""
-#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
-msgid "parameters must be registers in sequence a2 to a5"
+#: py/emitinlinethumb.c:107 py/emitinlinethumb.c:112
+msgid "parameters must be registers in sequence r0 to r3"
msgstr ""
-#: py/emitinlinextensa.c:162
+#: py/emitinlinethumb.c:188 py/emitinlinethumb.c:230
+#, c-format
+msgid "'%s' expects at most r%d"
+msgstr ""
+
+#: py/emitinlinethumb.c:197 py/emitinlinextensa.c:162
#, c-format
msgid "'%s' expects a register"
msgstr ""
-#: py/emitinlinextensa.c:169
+#: py/emitinlinethumb.c:211
+#, fuzzy, c-format
+msgid "'%s' expects a special register"
+msgstr "ord espera un carácter"
+
+#: py/emitinlinethumb.c:239
+#, c-format
+msgid "'%s' expects an FPU register"
+msgstr ""
+
+#: py/emitinlinethumb.c:292
+#, c-format
+msgid "'%s' expects {r0, r1, ...}"
+msgstr ""
+
+#: py/emitinlinethumb.c:299 py/emitinlinextensa.c:169
#, c-format
msgid "'%s' expects an integer"
msgstr ""
-#: py/emitinlinextensa.c:174
+#: py/emitinlinethumb.c:304
#, c-format
-msgid "'%s' integer %d is not within range %d..%d"
+msgid "'%s' integer 0x%x does not fit in mask 0x%x"
+msgstr ""
+
+#: py/emitinlinethumb.c:328
+#, c-format
+msgid "'%s' expects an address of the form [a, b]"
msgstr ""
-#: py/emitinlinextensa.c:182
+#: py/emitinlinethumb.c:334 py/emitinlinextensa.c:182
#, c-format
msgid "'%s' expects a label"
msgstr ""
-#: py/emitinlinextensa.c:193
+#: py/emitinlinethumb.c:345 py/emitinlinextensa.c:193
msgid "label '%q' not defined"
msgstr ""
+#: py/emitinlinethumb.c:806
+#, c-format
+msgid "unsupported Thumb instruction '%s' with %d arguments"
+msgstr ""
+
+#: py/emitinlinethumb.c:810
+#, fuzzy
+msgid "branch not in range"
+msgstr "El argumento de chr() no esta en el rango(256)"
+
+#: py/emitinlinextensa.c:86
+msgid "can only have up to 4 parameters to Xtensa assembly"
+msgstr ""
+
+#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
+msgid "parameters must be registers in sequence a2 to a5"
+msgstr ""
+
+#: py/emitinlinextensa.c:174
+#, c-format
+msgid "'%s' integer %d is not within range %d..%d"
+msgstr ""
+
#: py/emitinlinextensa.c:327
#, c-format
msgid "unsupported Xtensa instruction '%s' with %d arguments"
@@ -1620,7 +1688,7 @@ msgstr "struct: index fuera de rango"
#: py/objstr.c:1071
#, fuzzy
msgid "attributes not supported yet"
-msgstr "bytes > 8 bits no son soportados"
+msgstr "bytes > 8 bits no soportados"
#: py/objstr.c:1079
msgid ""
@@ -1802,7 +1870,6 @@ msgid "int() arg 2 must be >= 2 and <= 36"
msgstr ""
#: py/parsenum.c:151
-#, fuzzy
msgid "invalid syntax for integer"
msgstr "formato inválido"
@@ -1812,12 +1879,10 @@ msgid "invalid syntax for integer with base %d"
msgstr ""
#: py/parsenum.c:339
-#, fuzzy
msgid "invalid syntax for number"
msgstr "argumentos inválidos"
#: py/parsenum.c:342
-#, fuzzy
msgid "decimal numbers not supported"
msgstr "bytes > 8 bits no son soportados"
@@ -1832,7 +1897,6 @@ msgid "can only save bytecode"
msgstr ""
#: py/runtime.c:206
-#, fuzzy
msgid "name not defined"
msgstr "módulo no encontrado"
@@ -2009,6 +2073,26 @@ msgid ""
"destination buffer must be a bytearray or array of type 'B' for bit_depth = 8"
msgstr ""
+#: shared-bindings/audioio/Mixer.c:94
+#, fuzzy
+msgid "Invalid voice count"
+msgstr "Dirección inválida."
+
+#: shared-bindings/audioio/Mixer.c:99
+#, fuzzy
+msgid "Invalid channel count"
+msgstr "argumentos inválidos"
+
+#: shared-bindings/audioio/Mixer.c:103
+#, fuzzy
+msgid "Sample rate must be positive"
+msgstr "STA debe estar activo"
+
+#: shared-bindings/audioio/Mixer.c:107
+#, fuzzy
+msgid "bits_per_sample must be 8 or 16"
+msgstr "bits debe ser 8"
+
#: shared-bindings/audioio/RawSample.c:98
msgid ""
"sample_source buffer must be a bytearray or array of type 'h', 'H', 'b' or "
@@ -2033,19 +2117,19 @@ msgstr ""
msgid "Buffer must be at least length 1"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:168
+#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:175
msgid "Invalid polarity"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:172
+#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:179
msgid "Invalid phase"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:176
+#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:183
msgid "Invalid number of bits"
msgstr ""
-#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:341
+#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:348
msgid "buffer slices must be of equal length"
msgstr ""
@@ -2207,7 +2291,7 @@ msgstr ""
#: shared-bindings/pulseio/PWMOut.c:195
msgid ""
-"PWM frequency not writeable when variable_frequency is False on construction."
+"PWM frequency not writable when variable_frequency is False on construction."
msgstr ""
#: shared-bindings/pulseio/PulseIn.c:275
@@ -2301,6 +2385,34 @@ msgid ""
"Object has been deinitialized and can no longer be used. Create a new object."
msgstr ""
+#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
+msgid "Couldn't allocate first buffer"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:53 shared-module/audioio/WaveFile.c:123
+msgid "Couldn't allocate second buffer"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:82
+msgid "Voice index too high"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:85
+msgid "The sample's sample rate does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:88
+msgid "The sample's channel count does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:91
+msgid "The sample's bits_per_sample does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:100
+msgid "The sample's signedness does not match the mixer's"
+msgstr ""
+
#: shared-module/audioio/WaveFile.c:61
msgid "Invalid wave file"
msgstr ""
@@ -2321,14 +2433,6 @@ msgstr ""
msgid "Invalid file"
msgstr ""
-#: shared-module/audioio/WaveFile.c:117
-msgid "Couldn't allocate first buffer"
-msgstr ""
-
-#: shared-module/audioio/WaveFile.c:123
-msgid "Couldn't allocate second buffer"
-msgstr ""
-
#: shared-module/bitbangio/I2C.c:58
msgid "Clock stretch too long"
msgstr ""
@@ -2396,3 +2500,6 @@ msgstr ""
#: shared-module/struct/__init__.c:83
msgid "too many arguments provided with the given format"
msgstr ""
+
+#~ msgid "Baud rate too high for this SPI peripheral"
+#~ msgstr "Baud rate demasiado alto para este periférico SPI"
diff --git a/locale/fil.po b/locale/fil.po
index ad6252a21..e4f3105c9 100644
--- a/locale/fil.po
+++ b/locale/fil.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2018-09-21 12:23-0400\n"
+"POT-Creation-Date: 2018-10-09 20:51-0400\n"
"PO-Revision-Date: 2018-08-30 23:04-0700\n"
"Last-Translator: Timothy <me@timothygarcia.ca>\n"
"Language-Team: fil\n"
@@ -230,7 +230,7 @@ msgstr ""
msgid "soft reboot\n"
msgstr "malambot na reboot\n"
-#: ports/atmel-samd/audio_dma.c:285
+#: ports/atmel-samd/audio_dma.c:209
#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:361
msgid "All sync event channels in use"
msgstr "Lahat ng sync event channels ay ginagamit"
@@ -373,7 +373,7 @@ msgstr "Hindi sapat ang magagamit na pins"
#: ports/atmel-samd/common-hal/busio/SPI.c:132
#: ports/atmel-samd/common-hal/busio/UART.c:119
#: ports/atmel-samd/common-hal/i2cslave/I2CSlave.c:45
-#: ports/nrf/common-hal/busio/I2C.c:77
+#: ports/nrf/common-hal/busio/I2C.c:81
msgid "Invalid pins"
msgstr "Mali ang pins"
@@ -390,10 +390,12 @@ msgid "bytes > 8 bits not supported"
msgstr "hindi sinusuportahan ang bytes > 8 bits"
#: ports/atmel-samd/common-hal/busio/UART.c:72
+#: ports/nrf/common-hal/busio/UART.c:82
msgid "tx and rx cannot both be None"
msgstr "tx at rx hindi pwedeng parehas na None"
#: ports/atmel-samd/common-hal/busio/UART.c:145
+#: ports/nrf/common-hal/busio/UART.c:115
msgid "Failed to allocate RX buffer"
msgstr "Nabigong ilaan ang RX buffer"
@@ -402,10 +404,12 @@ msgid "Could not initialize UART"
msgstr "Hindi ma-initialize ang UART"
#: ports/atmel-samd/common-hal/busio/UART.c:240
+#: ports/nrf/common-hal/busio/UART.c:149
msgid "No RX pin"
msgstr "Walang RX pin"
#: ports/atmel-samd/common-hal/busio/UART.c:294
+#: ports/nrf/common-hal/busio/UART.c:195
msgid "No TX pin"
msgstr "Walang TX pin"
@@ -421,7 +425,8 @@ msgstr "Hindi ma-reset sa bootloader dahil walang bootloader."
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:120
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:369
-#: ports/nrf/common-hal/pulseio/PWMOut.c:227
+#: ports/nrf/common-hal/pulseio/PWMOut.c:120
+#: ports/nrf/common-hal/pulseio/PWMOut.c:232
msgid "Invalid PWM frequency"
msgstr "Mali ang PWM frequency"
@@ -705,33 +710,49 @@ msgstr "hindi alam na config param"
msgid "AnalogOut functionality not supported"
msgstr "Hindi supportado ang AnalogOut"
-#: ports/nrf/common-hal/busio/I2C.c:91
+#: ports/nrf/common-hal/busio/I2C.c:95
#, fuzzy
msgid "All I2C peripherals are in use"
msgstr "Lahat ng timer ginagamit"
-#: ports/nrf/common-hal/busio/SPI.c:109
+#: ports/nrf/common-hal/busio/SPI.c:115
#, fuzzy
msgid "All SPI peripherals are in use"
msgstr "Lahat ng timer ginagamit"
-#: ports/nrf/common-hal/busio/SPI.c:170
-msgid "Baud rate too high for this SPI peripheral"
+#: ports/nrf/common-hal/busio/UART.c:48
+#, c-format
+msgid "error = 0x%08lX"
msgstr ""
-#: ports/nrf/common-hal/busio/UART.c:43 ports/nrf/common-hal/busio/UART.c:47
-#: ports/nrf/common-hal/busio/UART.c:51 ports/nrf/common-hal/busio/UART.c:60
-#: ports/nrf/common-hal/busio/UART.c:66 ports/nrf/common-hal/busio/UART.c:71
-#: ports/nrf/common-hal/busio/UART.c:76 ports/nrf/common-hal/busio/UART.c:81
-#: ports/nrf/common-hal/busio/UART.c:86 ports/nrf/common-hal/busio/UART.c:90
-msgid "busio.UART not yet implemented"
-msgstr "hindi pa implemented ang busio.UART"
+#: ports/nrf/common-hal/busio/UART.c:86
+#, fuzzy
+msgid "Invalid buffer size"
+msgstr "mali ang buffer length"
+
+#: ports/nrf/common-hal/busio/UART.c:90
+#, fuzzy
+msgid "Odd parity is not supported"
+msgstr "hindi sinusuportahan ang bytes > 8 bits"
+
+#: ports/nrf/common-hal/busio/UART.c:322 ports/nrf/common-hal/busio/UART.c:326
+#: ports/nrf/common-hal/busio/UART.c:331 ports/nrf/common-hal/busio/UART.c:336
+#: ports/nrf/common-hal/busio/UART.c:342 ports/nrf/common-hal/busio/UART.c:347
+#: ports/nrf/common-hal/busio/UART.c:352 ports/nrf/common-hal/busio/UART.c:356
+#: ports/nrf/common-hal/busio/UART.c:364
+msgid "busio.UART not available"
+msgstr ""
#: ports/nrf/common-hal/microcontroller/Processor.c:49
#, c-format
msgid "Can not get temperature. status: 0x%02x"
msgstr "Hindi makuha ang temperatura. status 0x%02x"
+#: ports/nrf/common-hal/pulseio/PWMOut.c:162
+#, fuzzy
+msgid "All PWM peripherals are in use"
+msgstr "Lahat ng timer ginagamit"
+
#: ports/nrf/drivers/bluetooth/ble_drv.c:199
msgid "Cannot apply GAP parameters."
msgstr "Hindi ma-apply ang GAP parameters."
@@ -768,28 +789,28 @@ msgstr "Hindi ma-encode UUID, para suriin ang haba."
#: ports/nrf/drivers/bluetooth/ble_drv.c:470
#: ports/nrf/drivers/bluetooth/ble_drv.c:520
-msgid "Can encode UUID into the advertisment packet."
+msgid "Can encode UUID into the advertisement packet."
msgstr "Maaring i-encode ang UUID sa advertisement packet."
#: ports/nrf/drivers/bluetooth/ble_drv.c:545
-msgid "Can not fit data into the advertisment packet."
+msgid "Can not fit data into the advertisement packet."
msgstr "Hindi makasya ang data sa loob ng advertisement packet."
#: ports/nrf/drivers/bluetooth/ble_drv.c:558
#: ports/nrf/drivers/bluetooth/ble_drv.c:604
#, c-format
-msgid "Can not apply advertisment data. status: 0x%02x"
-msgstr "Hindi ma i-apply ang advertisment data. status: 0x%02x"
+msgid "Can not apply advertisement data. status: 0x%02x"
+msgstr "Hindi ma i-apply ang advertisement data. status: 0x%02x"
#: ports/nrf/drivers/bluetooth/ble_drv.c:614
#, c-format
-msgid "Can not start advertisment. status: 0x%02x"
+msgid "Can not start advertisement. status: 0x%02x"
msgstr "Hindi masimulaan ang advertisement. status 0x%02x"
#: ports/nrf/drivers/bluetooth/ble_drv.c:631
#, c-format
-msgid "Can not stop advertisment. status: 0x%02x"
-msgstr "Hindi mahinto ang advertisment. status: 0x%02x"
+msgid "Can not stop advertisement. status: 0x%02x"
+msgstr "Hindi mahinto ang advertisement. status: 0x%02x"
#: ports/nrf/drivers/bluetooth/ble_drv.c:650
#: ports/nrf/drivers/bluetooth/ble_drv.c:726
@@ -1099,38 +1120,88 @@ msgstr "'data' kailangan ng hindi bababa sa 2 argument"
msgid "'data' requires integer arguments"
msgstr "'data' kailangan ng integer arguments"
-#: py/emitinlinextensa.c:86
-msgid "can only have up to 4 parameters to Xtensa assembly"
+#: py/emitinlinethumb.c:102
+#, fuzzy
+msgid "can only have up to 4 parameters to Thumb assembly"
msgstr "maaari lamang magkaroon ng hanggang 4 na parameter sa Xtensa assembly"
-#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
-msgid "parameters must be registers in sequence a2 to a5"
+#: py/emitinlinethumb.c:107 py/emitinlinethumb.c:112
+#, fuzzy
+msgid "parameters must be registers in sequence r0 to r3"
msgstr "ang mga parameter ay dapat na nagrerehistro sa sequence a2 hanggang a5"
-#: py/emitinlinextensa.c:162
+#: py/emitinlinethumb.c:188 py/emitinlinethumb.c:230
+#, fuzzy, c-format
+msgid "'%s' expects at most r%d"
+msgstr "Inaasahan ng '%s' ang isang rehistro"
+
+#: py/emitinlinethumb.c:197 py/emitinlinextensa.c:162
#, c-format
msgid "'%s' expects a register"
msgstr "Inaasahan ng '%s' ang isang rehistro"
-#: py/emitinlinextensa.c:169
+#: py/emitinlinethumb.c:211
+#, fuzzy, c-format
+msgid "'%s' expects a special register"
+msgstr "Inaasahan ng '%s' ang isang rehistro"
+
+#: py/emitinlinethumb.c:239
+#, fuzzy, c-format
+msgid "'%s' expects an FPU register"
+msgstr "Inaasahan ng '%s' ang isang rehistro"
+
+#: py/emitinlinethumb.c:292
+#, fuzzy, c-format
+msgid "'%s' expects {r0, r1, ...}"
+msgstr "Inaasahan ng '%s' ang isang rehistro"
+
+#: py/emitinlinethumb.c:299 py/emitinlinextensa.c:169
#, c-format
msgid "'%s' expects an integer"
msgstr "Inaasahan ng '%s' ang isang integer"
-#: py/emitinlinextensa.c:174
-#, c-format
-msgid "'%s' integer %d is not within range %d..%d"
+#: py/emitinlinethumb.c:304
+#, fuzzy, c-format
+msgid "'%s' integer 0x%x does not fit in mask 0x%x"
msgstr "'%s' integer %d ay wala sa sakop ng %d..%d"
-#: py/emitinlinextensa.c:182
+#: py/emitinlinethumb.c:328
+#, fuzzy, c-format
+msgid "'%s' expects an address of the form [a, b]"
+msgstr "Inaasahan ng '%s' ang isang rehistro"
+
+#: py/emitinlinethumb.c:334 py/emitinlinextensa.c:182
#, c-format
msgid "'%s' expects a label"
msgstr "'%s' umaasa ng label"
-#: py/emitinlinextensa.c:193
+#: py/emitinlinethumb.c:345 py/emitinlinextensa.c:193
msgid "label '%q' not defined"
msgstr "label '%d' kailangan na i-define"
+#: py/emitinlinethumb.c:806
+#, fuzzy, c-format
+msgid "unsupported Thumb instruction '%s' with %d arguments"
+msgstr "hindi sinusuportahan ang instruction ng Xtensa '%s' sa %d argumento"
+
+#: py/emitinlinethumb.c:810
+#, fuzzy
+msgid "branch not in range"
+msgstr "chr() arg wala sa sakop ng range(256)"
+
+#: py/emitinlinextensa.c:86
+msgid "can only have up to 4 parameters to Xtensa assembly"
+msgstr "maaari lamang magkaroon ng hanggang 4 na parameter sa Xtensa assembly"
+
+#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
+msgid "parameters must be registers in sequence a2 to a5"
+msgstr "ang mga parameter ay dapat na nagrerehistro sa sequence a2 hanggang a5"
+
+#: py/emitinlinextensa.c:174
+#, c-format
+msgid "'%s' integer %d is not within range %d..%d"
+msgstr "'%s' integer %d ay wala sa sakop ng %d..%d"
+
#: py/emitinlinextensa.c:327
#, c-format
msgid "unsupported Xtensa instruction '%s' with %d arguments"
@@ -2004,6 +2075,26 @@ msgstr ""
"ang destination buffer ay dapat na isang bytearray o array ng uri na 'B' "
"para sa bit_depth = 8"
+#: shared-bindings/audioio/Mixer.c:94
+#, fuzzy
+msgid "Invalid voice count"
+msgstr "Mali ang tipo ng serbisyo"
+
+#: shared-bindings/audioio/Mixer.c:99
+#, fuzzy
+msgid "Invalid channel count"
+msgstr "Maling argumento"
+
+#: shared-bindings/audioio/Mixer.c:103
+#, fuzzy
+msgid "Sample rate must be positive"
+msgstr "Dapat aktibo ang STA"
+
+#: shared-bindings/audioio/Mixer.c:107
+#, fuzzy
+msgid "bits_per_sample must be 8 or 16"
+msgstr "bits ay dapat 7, 8 o 9"
+
#: shared-bindings/audioio/RawSample.c:98
msgid ""
"sample_source buffer must be a bytearray or array of type 'h', 'H', 'b' or "
@@ -2030,19 +2121,19 @@ msgstr "Function nangangailangan ng lock"
msgid "Buffer must be at least length 1"
msgstr "Buffer dapat ay hindi baba sa 1 na haba"
-#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:168
+#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:175
msgid "Invalid polarity"
msgstr "Mali ang polarity"
-#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:172
+#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:179
msgid "Invalid phase"
msgstr "Mali ang phase"
-#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:176
+#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:183
msgid "Invalid number of bits"
msgstr "Mali ang bilang ng bits"
-#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:341
+#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:348
msgid "buffer slices must be of equal length"
msgstr "aarehas na haba dapat ang buffer slices"
@@ -2216,8 +2307,9 @@ msgid ""
msgstr "PWM duty_cycle ay dapat sa loob ng 0 at 65535 (16 bit resolution)"
#: shared-bindings/pulseio/PWMOut.c:195
+#, fuzzy
msgid ""
-"PWM frequency not writeable when variable_frequency is False on construction."
+"PWM frequency not writable when variable_frequency is False on construction."
msgstr ""
"PWM frequency hindi maisulat kapag variable_frequency ay False sa pag buo."
@@ -2313,6 +2405,34 @@ msgstr ""
"Object ay deinitialized at hindi na magagamit. Lumikha ng isang bagong "
"Object."
+#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
+msgid "Couldn't allocate first buffer"
+msgstr "Hindi ma-iallocate ang first buffer"
+
+#: shared-module/audioio/Mixer.c:53 shared-module/audioio/WaveFile.c:123
+msgid "Couldn't allocate second buffer"
+msgstr "Hindi ma-iallocate ang second buffer"
+
+#: shared-module/audioio/Mixer.c:82
+msgid "Voice index too high"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:85
+msgid "The sample's sample rate does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:88
+msgid "The sample's channel count does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:91
+msgid "The sample's bits_per_sample does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:100
+msgid "The sample's signedness does not match the mixer's"
+msgstr ""
+
#: shared-module/audioio/WaveFile.c:61
msgid "Invalid wave file"
msgstr "May hindi tama sa wave file"
@@ -2333,14 +2453,6 @@ msgstr "Dapat sunurin ng Data chunk ang fmt chunk"
msgid "Invalid file"
msgstr "Mali ang file"
-#: shared-module/audioio/WaveFile.c:117
-msgid "Couldn't allocate first buffer"
-msgstr "Hindi ma-iallocate ang first buffer"
-
-#: shared-module/audioio/WaveFile.c:123
-msgid "Couldn't allocate second buffer"
-msgstr "Hindi ma-iallocate ang second buffer"
-
#: shared-module/bitbangio/I2C.c:58
msgid "Clock stretch too long"
msgstr "Masyadong mahaba ang Clock stretch"
diff --git a/locale/fr.po b/locale/fr.po
index d6d7b6087..02beae6d0 100644
--- a/locale/fr.po
+++ b/locale/fr.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: 0.1\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2018-09-21 12:23-0400\n"
+"POT-Creation-Date: 2018-10-09 20:51-0400\n"
"PO-Revision-Date: 2018-08-14 11:01+0200\n"
"Last-Translator: Pierrick Couturier <arofarn@arofarn.info>\n"
"Language-Team: fr\n"
@@ -225,7 +225,7 @@ msgstr "Appuyez sur une touche pour entrer sur REPL ou CTRL-D pour recharger."
msgid "soft reboot\n"
msgstr "redémarrage logiciel\n"
-#: ports/atmel-samd/audio_dma.c:285
+#: ports/atmel-samd/audio_dma.c:209
#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:361
msgid "All sync event channels in use"
msgstr "Tous les canaux d'événements de synchro sont utilisés"
@@ -368,7 +368,7 @@ msgstr "Pas assez de broches disponibles"
#: ports/atmel-samd/common-hal/busio/SPI.c:132
#: ports/atmel-samd/common-hal/busio/UART.c:119
#: ports/atmel-samd/common-hal/i2cslave/I2CSlave.c:45
-#: ports/nrf/common-hal/busio/I2C.c:77
+#: ports/nrf/common-hal/busio/I2C.c:81
msgid "Invalid pins"
msgstr "Broche invalide"
@@ -385,10 +385,12 @@ msgid "bytes > 8 bits not supported"
msgstr "octets > 8 bits non supporté"
#: ports/atmel-samd/common-hal/busio/UART.c:72
+#: ports/nrf/common-hal/busio/UART.c:82
msgid "tx and rx cannot both be None"
msgstr "TX et RX ne peuvent être None tous les deux"
#: ports/atmel-samd/common-hal/busio/UART.c:145
+#: ports/nrf/common-hal/busio/UART.c:115
msgid "Failed to allocate RX buffer"
msgstr "Echec de l'allocation du tampon RX"
@@ -397,10 +399,12 @@ msgid "Could not initialize UART"
msgstr "L'UART n'a pu être initialisé"
#: ports/atmel-samd/common-hal/busio/UART.c:240
+#: ports/nrf/common-hal/busio/UART.c:149
msgid "No RX pin"
msgstr "Pas de broche RX"
#: ports/atmel-samd/common-hal/busio/UART.c:294
+#: ports/nrf/common-hal/busio/UART.c:195
msgid "No TX pin"
msgstr "Pas de broche TX"
@@ -417,7 +421,8 @@ msgstr ""
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:120
#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:369
-#: ports/nrf/common-hal/pulseio/PWMOut.c:227
+#: ports/nrf/common-hal/pulseio/PWMOut.c:120
+#: ports/nrf/common-hal/pulseio/PWMOut.c:232
msgid "Invalid PWM frequency"
msgstr "Fréquence de PWM invalide"
@@ -701,33 +706,50 @@ msgstr "paramètre de config. inconnu"
msgid "AnalogOut functionality not supported"
msgstr "AnalogOut non supporté"
-#: ports/nrf/common-hal/busio/I2C.c:91
+#: ports/nrf/common-hal/busio/I2C.c:95
#, fuzzy
msgid "All I2C peripherals are in use"
msgstr "Tous les timers sont utilisés"
-#: ports/nrf/common-hal/busio/SPI.c:109
+#: ports/nrf/common-hal/busio/SPI.c:115
#, fuzzy
msgid "All SPI peripherals are in use"
msgstr "Tous les timers sont utilisés"
-#: ports/nrf/common-hal/busio/SPI.c:170
-msgid "Baud rate too high for this SPI peripheral"
+#: ports/nrf/common-hal/busio/UART.c:48
+#, c-format
+msgid "error = 0x%08lX"
msgstr ""
-#: ports/nrf/common-hal/busio/UART.c:43 ports/nrf/common-hal/busio/UART.c:47
-#: ports/nrf/common-hal/busio/UART.c:51 ports/nrf/common-hal/busio/UART.c:60
-#: ports/nrf/common-hal/busio/UART.c:66 ports/nrf/common-hal/busio/UART.c:71
-#: ports/nrf/common-hal/busio/UART.c:76 ports/nrf/common-hal/busio/UART.c:81
-#: ports/nrf/common-hal/busio/UART.c:86 ports/nrf/common-hal/busio/UART.c:90
-msgid "busio.UART not yet implemented"
-msgstr "busio.UART pas encore implémenté"
+#: ports/nrf/common-hal/busio/UART.c:86
+#, fuzzy
+msgid "Invalid buffer size"
+msgstr "longueur de tampon invalide"
+
+#: ports/nrf/common-hal/busio/UART.c:90
+#, fuzzy
+msgid "Odd parity is not supported"
+msgstr "octets > 8 bits non supporté"
+
+#: ports/nrf/common-hal/busio/UART.c:322 ports/nrf/common-hal/busio/UART.c:326
+#: ports/nrf/common-hal/busio/UART.c:331 ports/nrf/common-hal/busio/UART.c:336
+#: ports/nrf/common-hal/busio/UART.c:342 ports/nrf/common-hal/busio/UART.c:347
+#: ports/nrf/common-hal/busio/UART.c:352 ports/nrf/common-hal/busio/UART.c:356
+#: ports/nrf/common-hal/busio/UART.c:364
+#, fuzzy
+msgid "busio.UART not available"
+msgstr "busio.UART n'est pas disponible"
#: ports/nrf/common-hal/microcontroller/Processor.c:49
#, c-format
msgid "Can not get temperature. status: 0x%02x"
msgstr "Impossible de lire la température. status: 0x%02x"
+#: ports/nrf/common-hal/pulseio/PWMOut.c:162
+#, fuzzy
+msgid "All PWM peripherals are in use"
+msgstr "Tous les timers sont utilisés"
+
#: ports/nrf/drivers/bluetooth/ble_drv.c:199
msgid "Cannot apply GAP parameters."
msgstr "Impossible d'appliquer les paramètres GAP"
@@ -764,27 +786,27 @@ msgstr "Impossible d'encoder l'UUID pour vérifier la longueur."
#: ports/nrf/drivers/bluetooth/ble_drv.c:470
#: ports/nrf/drivers/bluetooth/ble_drv.c:520
-msgid "Can encode UUID into the advertisment packet."
+msgid "Can encode UUID into the advertisement packet."
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:545
-msgid "Can not fit data into the advertisment packet."
+msgid "Can not fit data into the advertisement packet."
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:558
#: ports/nrf/drivers/bluetooth/ble_drv.c:604
#, c-format
-msgid "Can not apply advertisment data. status: 0x%02x"
+msgid "Can not apply advertisement data. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:614
#, c-format
-msgid "Can not start advertisment. status: 0x%02x"
+msgid "Can not start advertisement. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:631
#, c-format
-msgid "Can not stop advertisment. status: 0x%02x"
+msgid "Can not stop advertisement. status: 0x%02x"
msgstr ""
#: ports/nrf/drivers/bluetooth/ble_drv.c:650
@@ -1092,38 +1114,87 @@ msgstr "'data' nécessite au moins 2 arguments"
msgid "'data' requires integer arguments"
msgstr "'data' nécessite des arguments entiers"
-#: py/emitinlinextensa.c:86
-msgid "can only have up to 4 parameters to Xtensa assembly"
+#: py/emitinlinethumb.c:102
+msgid "can only have up to 4 parameters to Thumb assembly"
msgstr ""
-#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
-msgid "parameters must be registers in sequence a2 to a5"
+#: py/emitinlinethumb.c:107 py/emitinlinethumb.c:112
+#, fuzzy
+msgid "parameters must be registers in sequence r0 to r3"
msgstr "les paramètres doivent être des registres dans la séquence a2 à a5"
-#: py/emitinlinextensa.c:162
+#: py/emitinlinethumb.c:188 py/emitinlinethumb.c:230
+#, fuzzy, c-format
+msgid "'%s' expects at most r%d"
+msgstr "'%s' attend un registre"
+
+#: py/emitinlinethumb.c:197 py/emitinlinextensa.c:162
#, c-format
msgid "'%s' expects a register"
msgstr "'%s' attend un registre"
-#: py/emitinlinextensa.c:169
+#: py/emitinlinethumb.c:211
+#, fuzzy, c-format
+msgid "'%s' expects a special register"
+msgstr "'%s' attend un registre"
+
+#: py/emitinlinethumb.c:239
+#, fuzzy, c-format
+msgid "'%s' expects an FPU register"
+msgstr "'%s' attend un registre"
+
+#: py/emitinlinethumb.c:292
+#, fuzzy, c-format
+msgid "'%s' expects {r0, r1, ...}"
+msgstr "'%s' attend un registre"
+
+#: py/emitinlinethumb.c:299 py/emitinlinextensa.c:169
#, c-format
msgid "'%s' expects an integer"
msgstr "'%s' attend un entier"
-#: py/emitinlinextensa.c:174
-#, c-format
-msgid "'%s' integer %d is not within range %d..%d"
+#: py/emitinlinethumb.c:304
+#, fuzzy, c-format
+msgid "'%s' integer 0x%x does not fit in mask 0x%x"
msgstr "'%s' l'entier %d n'est pas dans la gamme %d..%d"
-#: py/emitinlinextensa.c:182
+#: py/emitinlinethumb.c:328
+#, fuzzy, c-format
+msgid "'%s' expects an address of the form [a, b]"
+msgstr "'%s' attend un registre"
+
+#: py/emitinlinethumb.c:334 py/emitinlinextensa.c:182
#, c-format
msgid "'%s' expects a label"
msgstr "'%s' attend un label"
-#: py/emitinlinextensa.c:193
+#: py/emitinlinethumb.c:345 py/emitinlinextensa.c:193
msgid "label '%q' not defined"
msgstr "label '%q' non supporté"
+#: py/emitinlinethumb.c:806
+#, fuzzy, c-format
+msgid "unsupported Thumb instruction '%s' with %d arguments"
+msgstr "instruction Xtensa '%s' non supportée avec %d arguments"
+
+#: py/emitinlinethumb.c:810
+#, fuzzy
+msgid "branch not in range"
+msgstr "argument de chr() hors de la gamme range(256)"
+
+#: py/emitinlinextensa.c:86
+msgid "can only have up to 4 parameters to Xtensa assembly"
+msgstr ""
+
+#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
+msgid "parameters must be registers in sequence a2 to a5"
+msgstr "les paramètres doivent être des registres dans la séquence a2 à a5"
+
+#: py/emitinlinextensa.c:174
+#, c-format
+msgid "'%s' integer %d is not within range %d..%d"
+msgstr "'%s' l'entier %d n'est pas dans la gamme %d..%d"
+
#: py/emitinlinextensa.c:327
#, c-format
msgid "unsupported Xtensa instruction '%s' with %d arguments"
@@ -1995,6 +2066,26 @@ msgid ""
msgstr ""
"le tampon de destination doit être un tableau de type 'B' pour bit_depth = 8"
+#: shared-bindings/audioio/Mixer.c:94
+#, fuzzy
+msgid "Invalid voice count"
+msgstr "Type de service invalide"
+
+#: shared-bindings/audioio/Mixer.c:99
+#, fuzzy
+msgid "Invalid channel count"
+msgstr "Argument invalide"
+
+#: shared-bindings/audioio/Mixer.c:103
+#, fuzzy
+msgid "Sample rate must be positive"
+msgstr "'STA' doit être actif"
+
+#: shared-bindings/audioio/Mixer.c:107
+#, fuzzy
+msgid "bits_per_sample must be 8 or 16"
+msgstr "bits doivent être 7, 8 ou 9"
+
#: shared-bindings/audioio/RawSample.c:98
msgid ""
"sample_source buffer must be a bytearray or array of type 'h', 'H', 'b' or "
@@ -2021,19 +2112,19 @@ msgstr "La fonction nécessite un verrou"
msgid "Buffer must be at least length 1"
msgstr "Le tampon doit être de longueur au moins 1"
-#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:168
+#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:175
msgid "Invalid polarity"
msgstr "Polarité invalide"
-#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:172
+#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:179
msgid "Invalid phase"
msgstr "Phase invalide"
-#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:176
+#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:183
msgid "Invalid number of bits"
msgstr "Nombre de bits invalide"
-#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:341
+#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:348
msgid "buffer slices must be of equal length"
msgstr "les slices de tampon doivent être de longueurs égales"
@@ -2211,8 +2302,9 @@ msgstr ""
"bits)"
#: shared-bindings/pulseio/PWMOut.c:195
+#, fuzzy
msgid ""
-"PWM frequency not writeable when variable_frequency is False on construction."
+"PWM frequency not writable when variable_frequency is False on construction."
msgstr ""
"La fréquence de PWM n'est pas modifiable quand variable_frequency est False "
"à laconstruction."
@@ -2309,6 +2401,34 @@ msgstr ""
"L'objet a été désinitialisé et ne peut plus être utilisé. Créez un nouvel "
"objet."
+#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
+msgid "Couldn't allocate first buffer"
+msgstr "Impossible d'allouer le 1er tampon"
+
+#: shared-module/audioio/Mixer.c:53 shared-module/audioio/WaveFile.c:123
+msgid "Couldn't allocate second buffer"
+msgstr "Impossible d'allouer le 2e tampon"
+
+#: shared-module/audioio/Mixer.c:82
+msgid "Voice index too high"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:85
+msgid "The sample's sample rate does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:88
+msgid "The sample's channel count does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:91
+msgid "The sample's bits_per_sample does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:100
+msgid "The sample's signedness does not match the mixer's"
+msgstr ""
+
#: shared-module/audioio/WaveFile.c:61
msgid "Invalid wave file"
msgstr "Fichier WAVE invalide"
@@ -2329,14 +2449,6 @@ msgstr "Un bloc de données doit suivre un bloc de format"
msgid "Invalid file"
msgstr "Fichier invalide"
-#: shared-module/audioio/WaveFile.c:117
-msgid "Couldn't allocate first buffer"
-msgstr "Impossible d'allouer le 1er tampon"
-
-#: shared-module/audioio/WaveFile.c:123
-msgid "Couldn't allocate second buffer"
-msgstr "Impossible d'allouer le 2e tampon"
-
#: shared-module/bitbangio/I2C.c:58
msgid "Clock stretch too long"
msgstr "Période de l'horloge trop longue"
diff --git a/locale/it_IT.po b/locale/it_IT.po
new file mode 100644
index 000000000..5490c699c
--- /dev/null
+++ b/locale/it_IT.po
@@ -0,0 +1,2506 @@
+# Italian translation.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# Enrico Paganin <enrico.paganin@mail.com>, 2018
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2018-10-09 20:51-0400\n"
+"PO-Revision-Date: 2018-10-02 16:27+0200\n"
+"Last-Translator: Enrico Paganin <enrico.paganin@mail.com>\n"
+"Language-Team: \n"
+"Language: it_IT\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: extmod/machine_i2c.c:299
+msgid "invalid I2C peripheral"
+msgstr "periferica I2C invalida"
+
+#: extmod/machine_i2c.c:340 extmod/machine_i2c.c:354 extmod/machine_i2c.c:368
+#: extmod/machine_i2c.c:392
+msgid "I2C operation not supported"
+msgstr "operazione I2C non supportata"
+
+#: extmod/machine_mem.c:45 ports/unix/modmachine.c:53
+#, c-format
+msgid "address %08x is not aligned to %d bytes"
+msgstr "l'indirizzo %08x non è allineato a %d bytes"
+
+#: extmod/machine_spi.c:57
+msgid "invalid SPI peripheral"
+msgstr "periferica SPI invalida"
+
+#: extmod/machine_spi.c:124
+msgid "buffers must be the same length"
+msgstr "i buffer devono essere della stessa lunghezza"
+
+#: extmod/machine_spi.c:207
+msgid "bits must be 8"
+msgstr "i bit devono essere 8"
+
+#: extmod/machine_spi.c:210
+msgid "firstbit must be MSB"
+msgstr "il primo bit deve essere il più significativo (MSB)"
+
+#: extmod/machine_spi.c:215
+msgid "must specify all of sck/mosi/miso"
+msgstr "è necessario specificare tutte le sck/mosi/miso"
+
+#: extmod/modframebuf.c:299
+msgid "invalid format"
+msgstr "formato non valido"
+
+#: extmod/modubinascii.c:38 extmod/moduhashlib.c:102
+msgid "a bytes-like object is required"
+msgstr "un oggetto byte-like è richiesto"
+
+#: extmod/modubinascii.c:90
+msgid "odd-length string"
+msgstr "stringa di lunghezza dispari"
+
+#: extmod/modubinascii.c:101
+msgid "non-hex digit found"
+msgstr "trovata cifra non esadecimale"
+
+#: extmod/modubinascii.c:169
+msgid "incorrect padding"
+msgstr "padding incorretto"
+
+#: extmod/moductypes.c:122
+msgid "syntax error in uctypes descriptor"
+msgstr "errore di sintassi nel descrittore uctypes"
+
+#: extmod/moductypes.c:219
+msgid "Cannot unambiguously get sizeof scalar"
+msgstr "Impossibile ricavare la grandezza scalare di sizeof inequivocabilmente"
+
+#: extmod/moductypes.c:397
+msgid "struct: no fields"
+msgstr "struct: nessun campo"
+
+#: extmod/moductypes.c:530
+msgid "struct: cannot index"
+msgstr "struct: impossibile indicizzare"
+
+#: extmod/moductypes.c:544
+msgid "struct: index out of range"
+msgstr "struct: indice fuori intervallo"
+
+#: extmod/moduheapq.c:38
+msgid "heap must be a list"
+msgstr "l'heap deve essere una lista"
+
+#: extmod/moduheapq.c:86 extmod/modutimeq.c:147 extmod/modutimeq.c:172
+msgid "empty heap"
+msgstr "heap vuoto"
+
+#: extmod/modujson.c:281
+msgid "syntax error in JSON"
+msgstr "errore di sintassi nel JSON"
+
+#: extmod/modure.c:161
+msgid "Splitting with sub-captures"
+msgstr "Suddivisione con sotto-catture"
+
+#: extmod/modure.c:207
+msgid "Error in regex"
+msgstr "Errore nella regex"
+
+#: extmod/modussl_axtls.c:81
+msgid "invalid key"
+msgstr "chiave non valida"
+
+#: extmod/modussl_axtls.c:87
+msgid "invalid cert"
+msgstr "certificato non valido"
+
+#: extmod/modutimeq.c:131
+msgid "queue overflow"
+msgstr "overflow della coda"
+
+#: extmod/moduzlib.c:98
+msgid "compression header"
+msgstr "compressione dell'header"
+
+#: extmod/uos_dupterm.c:120
+msgid "invalid dupterm index"
+msgstr "indice dupterm non valido"
+
+#: extmod/vfs_fat.c:426 py/moduerrno.c:150
+msgid "Read-only filesystem"
+msgstr "Filesystem in sola lettura"
+
+#: extmod/vfs_posix_file.c:48 ports/unix/file.c:50 py/objstringio.c:43
+msgid "I/O operation on closed file"
+msgstr "operazione I/O su file chiuso"
+
+#: lib/embed/abort_.c:8
+msgid "abort() called"
+msgstr "abort() chiamato"
+
+#: lib/netutils/netutils.c:83
+msgid "invalid arguments"
+msgstr "argomenti non validi"
+
+#: lib/utils/pyexec.c:97 py/builtinimport.c:253
+msgid "script compilation not supported"
+msgstr "compilazione dello scrip non suportata"
+
+#: main.c:143
+msgid " output:\n"
+msgstr " output:\n"
+
+#: main.c:157 main.c:230
+msgid ""
+"Auto-reload is on. Simply save files over USB to run them or enter REPL to "
+"disable.\n"
+msgstr ""
+"L'auto-reload è attivo. Salva i file su USB per eseguirli o entra nel REPL "
+"per disabilitarlo.\n"
+
+#: main.c:159
+msgid "Running in safe mode! Auto-reload is off.\n"
+msgstr "Modalità sicura in esecuzione! Auto-reload disattivato.\n"
+
+#: main.c:161 main.c:232
+msgid "Auto-reload is off.\n"
+msgstr "Auto-reload disattivato.\n"
+
+#: main.c:175
+msgid "Running in safe mode! Not running saved code.\n"
+msgstr "Modalità sicura in esecuzione! Codice salvato non in esecuzione.\n"
+
+#: main.c:191
+msgid "WARNING: Your code filename has two extensions\n"
+msgstr "ATTENZIONE: Il nome del sorgente ha due estensioni\n"
+
+#: main.c:239
+msgid "You requested starting safe mode by "
+msgstr "È stato richiesto l'avvio in modalità sicura da "
+
+#: main.c:242
+msgid "To exit, please reset the board without "
+msgstr "Per uscire resettare la scheda senza "
+
+#: main.c:249
+msgid ""
+"You are running in safe mode which means something really bad happened.\n"
+msgstr ""
+"Sei nella modalità sicura che significa che qualcosa di molto brutto è "
+"successo.\n"
+
+#: main.c:251
+msgid "Looks like our core CircuitPython code crashed hard. Whoops!\n"
+msgstr ""
+"Sembra che il codice del core di CircuitPython sia crashato malamente. "
+"Whoops!\n"
+
+#: main.c:252
+msgid "Please file an issue here with the contents of your CIRCUITPY drive:\n"
+msgstr ""
+"Ti preghiamo di compilare una issue con il contenuto del tuo drie "
+"CIRCUITPY:\n"
+
+#: main.c:255
+msgid ""
+"The microcontroller's power dipped. Please make sure your power supply "
+"provides\n"
+msgstr ""
+"La potenza del microcontrollore è calata. Assicurati che l'alimentazione sia "
+"attaccata correttamente\n"
+
+#: main.c:256
+msgid ""
+"enough power for the whole circuit and press reset (after ejecting "
+"CIRCUITPY).\n"
+msgstr ""
+"abbastanza potenza per l'intero circuito e premere reset (dopo aver espulso "
+"CIRCUITPY).\n"
+
+#: main.c:260
+msgid "Press any key to enter the REPL. Use CTRL-D to reload."
+msgstr ""
+"Premi un qualunque tasto per entrare nel REPL. Usa CTRL-D per ricaricare."
+
+#: main.c:416
+msgid "soft reboot\n"
+msgstr "soft reboot\n"
+
+#: ports/atmel-samd/audio_dma.c:209
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:361
+msgid "All sync event channels in use"
+msgstr "Tutti i canali di eventi sincronizzati in uso"
+
+#: ports/atmel-samd/bindings/samd/Clock.c:135
+msgid "calibration is read only"
+msgstr "la calibrazione è in sola lettura"
+
+#: ports/atmel-samd/bindings/samd/Clock.c:137
+msgid "calibration is out of range"
+msgstr "la calibrazione è fuori intervallo"
+
+#: ports/atmel-samd/board_busses.c:59 ports/nrf/board_busses.c:39
+msgid "No default I2C bus"
+msgstr "Nessun bus I2C predefinito"
+
+#: ports/atmel-samd/board_busses.c:85 ports/nrf/board_busses.c:64
+msgid "No default SPI bus"
+msgstr "Nessun bus SPI predefinito"
+
+#: ports/atmel-samd/board_busses.c:112 ports/nrf/board_busses.c:91
+msgid "No default UART bus"
+msgstr "Nessun bus UART predefinito"
+
+#: ports/atmel-samd/common-hal/analogio/AnalogIn.c:63
+#: ports/nrf/common-hal/analogio/AnalogIn.c:39
+msgid "Pin does not have ADC capabilities"
+msgstr "Il pin non ha capacità di ADC"
+
+#: ports/atmel-samd/common-hal/analogio/AnalogOut.c:49
+msgid "No DAC on chip"
+msgstr "Nessun DAC sul chip"
+
+#: ports/atmel-samd/common-hal/analogio/AnalogOut.c:56
+msgid "AnalogOut not supported on given pin"
+msgstr "AnalogOut non supportato sul pin scelto"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:147
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:150
+msgid "Invalid bit clock pin"
+msgstr "Pin del clock di bit non valido"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:153
+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"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:156
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:130
+msgid "Invalid data pin"
+msgstr "Pin dati non valido"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:169
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:174
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:145
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:150
+msgid "Serializer in use"
+msgstr "Serializer in uso"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:230
+msgid "Clock unit in use"
+msgstr "Unità di clock in uso"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:240
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:172
+msgid "Unable to find free GCLK"
+msgstr "Impossibile trovare un GCLK libero"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:254
+msgid "Too many channels in sample."
+msgstr ""
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:305
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:339
+msgid "No DMA channel found"
+msgstr "Nessun canale DMA trovato"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:308
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:341
+msgid "Unable to allocate buffers for signed conversion"
+msgstr "Ipossibilitato ad allocare buffer per la conversione con segno"
+
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:109
+msgid "Invalid clock pin"
+msgstr "Pin di clock non valido"
+
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:134
+msgid "Only 8 or 16 bit mono with "
+msgstr ""
+
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:167
+msgid "sampling rate out of range"
+msgstr "frequenza di campionamento fuori intervallo"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:69
+msgid "DAC already in use"
+msgstr "DAC già in uso"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:73
+msgid "Right channel unsupported"
+msgstr "Canale destro non supportato"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:76
+#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:116
+#: ports/atmel-samd/common-hal/touchio/TouchIn.c:65
+msgid "Invalid pin"
+msgstr "Pin non valido"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:84
+msgid "Invalid pin for left channel"
+msgstr "Pin non valido per il canale sinistro"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:88
+msgid "Invalid pin for right channel"
+msgstr "Pin non valido per il canale destro"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:91
+msgid "Cannot output both channels on the same pin"
+msgstr "Impossibile dare in output entrambi i canal sullo stesso pin"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:176
+#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:189
+#: ports/atmel-samd/common-hal/pulseio/PulseOut.c:110
+msgid "All timers in use"
+msgstr "Tutti i timer utilizzati"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:218
+msgid "All event channels in use"
+msgstr "Tutti i canali eventi utilizati"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:297
+#, c-format
+msgid "Sample rate too high. It must be less than %d"
+msgstr ""
+"Frequenza di campionamento troppo alta. Il valore deve essere inferiore a %d"
+
+#: ports/atmel-samd/common-hal/busio/I2C.c:71
+msgid "Not enough pins available"
+msgstr "Non sono presenti abbastanza pin"
+
+#: ports/atmel-samd/common-hal/busio/I2C.c:78
+#: ports/atmel-samd/common-hal/busio/SPI.c:132
+#: ports/atmel-samd/common-hal/busio/UART.c:119
+#: ports/atmel-samd/common-hal/i2cslave/I2CSlave.c:45
+#: ports/nrf/common-hal/busio/I2C.c:81
+msgid "Invalid pins"
+msgstr "Pin non validi"
+
+#: ports/atmel-samd/common-hal/busio/I2C.c:101
+msgid "SDA or SCL needs a pull up"
+msgstr "SDA o SCL necessitano un pull-up"
+
+#: ports/atmel-samd/common-hal/busio/I2C.c:121
+msgid "Unsupported baudrate"
+msgstr "baudrate non supportato"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:66
+msgid "bytes > 8 bits not supported"
+msgstr "byte > 8 bit non supportati"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:72
+#: ports/nrf/common-hal/busio/UART.c:82
+msgid "tx and rx cannot both be None"
+msgstr "tx e rx non possono essere entrambi None"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:145
+#: ports/nrf/common-hal/busio/UART.c:115
+msgid "Failed to allocate RX buffer"
+msgstr "Impossibile allocare buffer RX"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:153
+msgid "Could not initialize UART"
+msgstr "Impossibile inizializzare l'UART"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:240
+#: ports/nrf/common-hal/busio/UART.c:149
+msgid "No RX pin"
+msgstr "Nessun pin RX"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:294
+#: ports/nrf/common-hal/busio/UART.c:195
+msgid "No TX pin"
+msgstr "Nessun pin TX"
+
+#: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c:170
+#: ports/nrf/common-hal/digitalio/DigitalInOut.c:142
+msgid "Cannot get pull while in output mode"
+msgstr ""
+
+#: ports/atmel-samd/common-hal/microcontroller/__init__.c:74
+#: ports/esp8266/common-hal/microcontroller/__init__.c:64
+msgid "Cannot reset into bootloader because no bootloader is present."
+msgstr ""
+"Impossibile resettare nel bootloader poiché nessun bootloader è presente."
+
+#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:120
+#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:369
+#: ports/nrf/common-hal/pulseio/PWMOut.c:120
+#: ports/nrf/common-hal/pulseio/PWMOut.c:232
+msgid "Invalid PWM frequency"
+msgstr "Frequenza PWM non valida"
+
+#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:187
+msgid "All timers for this pin are in use"
+msgstr "Tutti i timer per questo pin sono in uso"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:110
+msgid "No hardware support on pin"
+msgstr "Nessun supporto hardware sul pin"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:113
+msgid "EXTINT channel already in use"
+msgstr "Canale EXTINT già in uso"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:118
+#: ports/esp8266/common-hal/pulseio/PulseIn.c:86
+#, c-format
+msgid "Failed to allocate RX buffer of %d bytes"
+msgstr "Fallita allocazione del buffer RX di %d byte"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:205
+#: ports/esp8266/common-hal/pulseio/PulseIn.c:151
+msgid "pop from an empty PulseIn"
+msgstr "pop sun un PulseIn vuoto"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:237
+#: ports/esp8266/common-hal/pulseio/PulseIn.c:182 py/obj.c:420
+msgid "index out of range"
+msgstr "indice fuori intervallo"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseOut.c:178
+msgid "Another send is already active"
+msgstr ""
+
+#: ports/atmel-samd/common-hal/rotaryio/IncrementalEncoder.c:38
+msgid "Both pins must support hardware interrupts"
+msgstr "Entrambi i pin devono supportare gli interrupt hardware"
+
+#: ports/atmel-samd/common-hal/rotaryio/IncrementalEncoder.c:46
+msgid "A hardware interrupt channel is already in use"
+msgstr "Un canale di interrupt hardware è già in uso"
+
+#: ports/atmel-samd/common-hal/rtc/RTC.c:101
+msgid "calibration value out of range +/-127"
+msgstr "valore di calibrazione fuori intervallo +/-127"
+
+#: ports/atmel-samd/common-hal/storage/__init__.c:48
+msgid "Cannot remount '/' when USB is active."
+msgstr "Non è possibile rimontare '/' mentre l'USB è attiva."
+
+#: ports/atmel-samd/common-hal/touchio/TouchIn.c:75
+msgid "No free GCLKs"
+msgstr "Nessun GCLK libero"
+
+#: ports/atmel-samd/common-hal/usb_hid/Device.c:78
+#: ports/nrf/common-hal/usb_hid/Device.c:45
+#, c-format
+msgid "Buffer incorrect size. Should be %d bytes."
+msgstr "Buffer di lunghezza non valida. Dovrebbe essere di %d bytes."
+
+#: ports/atmel-samd/common-hal/usb_hid/Device.c:82
+#: ports/nrf/common-hal/usb_hid/Device.c:53
+msgid "USB Busy"
+msgstr "USB occupata"
+
+#: ports/atmel-samd/common-hal/usb_hid/Device.c:82
+#: ports/nrf/common-hal/usb_hid/Device.c:59
+msgid "USB Error"
+msgstr "Errore USB"
+
+#: ports/esp8266/common-hal/analogio/AnalogIn.c:43
+msgid "Pin %q does not have ADC capabilities"
+msgstr "Il pin %q non ha capacità ADC"
+
+#: ports/esp8266/common-hal/analogio/AnalogOut.c:39
+msgid "No hardware support for analog out."
+msgstr "Nessun supporto hardware per l'uscita analogica."
+
+#: ports/esp8266/common-hal/busio/SPI.c:72
+msgid "Pins not valid for SPI"
+msgstr "Pin non validi per SPI"
+
+#: ports/esp8266/common-hal/busio/UART.c:45
+msgid "Only tx supported on UART1 (GPIO2)."
+msgstr "Solo tx supportato su UART1 (GPIO2)."
+
+#: ports/esp8266/common-hal/busio/UART.c:67 ports/esp8266/machine_uart.c:108
+msgid "invalid data bits"
+msgstr "bit dati invalidi"
+
+#: ports/esp8266/common-hal/busio/UART.c:91 ports/esp8266/machine_uart.c:144
+msgid "invalid stop bits"
+msgstr "bit di stop invalidi"
+
+#: ports/esp8266/common-hal/digitalio/DigitalInOut.c:200
+msgid "ESP8266 does not support pull down."
+msgstr "ESP8266 non supporta pull-down"
+
+#: ports/esp8266/common-hal/digitalio/DigitalInOut.c:210
+msgid "GPIO16 does not support pull up."
+msgstr "GPIO16 non supporta pull-up"
+
+#: ports/esp8266/common-hal/microcontroller/__init__.c:66
+msgid "ESP8226 does not support safe mode."
+msgstr "ESP8266 non supporta la modalità sicura."
+
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:54
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:113
+#, c-format
+msgid "Maximum PWM frequency is %dhz."
+msgstr "Frequenza massima su PWM è %dhz"
+
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:57
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:116
+msgid "Minimum PWM frequency is 1hz."
+msgstr "Frequenza minima su PWM è 1hz"
+
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:68
+#, c-format
+msgid "Multiple PWM frequencies not supported. PWM already set to %dhz."
+msgstr "Frequenze PWM multiple non supportate. PWM già impostato a %shz."
+
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:77 ports/esp8266/machine_pwm.c:70
+#, c-format
+msgid "PWM not supported on pin %d"
+msgstr "PWM non è supportato sul pin %d"
+
+#: ports/esp8266/common-hal/pulseio/PulseIn.c:78
+msgid "No PulseIn support for %q"
+msgstr "Nessun supporto per PulseIn per %q"
+
+#: ports/esp8266/common-hal/storage/__init__.c:34
+msgid "Unable to remount filesystem"
+msgstr "Imposssibile rimontare il filesystem"
+
+#: ports/esp8266/common-hal/storage/__init__.c:38
+msgid "Use esptool to erase flash and re-upload Python instead"
+msgstr "Usa esptool per cancellare la flash e ricaricare Python invece"
+
+#: ports/esp8266/esp_mphal.c:154
+msgid "C-level assert"
+msgstr "assert a livello C"
+
+#: ports/esp8266/machine_adc.c:57
+#, c-format
+msgid "not a valid ADC Channel: %d"
+msgstr "canale ADC non valido: %d"
+
+#: ports/esp8266/machine_hspi.c:131 ports/esp8266/machine_hspi.c:137
+msgid "impossible baudrate"
+msgstr "baudrate impossibile"
+
+#: ports/esp8266/machine_pin.c:129
+msgid "expecting a pin"
+msgstr "pin atteso"
+
+#: ports/esp8266/machine_pin.c:284
+msgid "Pin(16) doesn't support pull"
+msgstr "Pin(16) non supporta pull"
+
+#: ports/esp8266/machine_pin.c:323
+msgid "invalid pin"
+msgstr "pin non valido"
+
+#: ports/esp8266/machine_pin.c:389
+msgid "pin does not have IRQ capabilities"
+msgstr "il pin non implementa IRQ"
+
+#: ports/esp8266/machine_rtc.c:185
+msgid "buffer too long"
+msgstr "buffer troppo lungo"
+
+#: ports/esp8266/machine_rtc.c:209 ports/esp8266/machine_rtc.c:223
+#: ports/esp8266/machine_rtc.c:246
+msgid "invalid alarm"
+msgstr "alarm non valido"
+
+#: ports/esp8266/machine_uart.c:169
+#, c-format
+msgid "UART(%d) does not exist"
+msgstr "UART(%d) non esistente"
+
+#: ports/esp8266/machine_uart.c:219
+msgid "UART(1) can't read"
+msgstr "UART(1) non leggibile"
+
+#: ports/esp8266/modesp.c:119
+msgid "len must be multiple of 4"
+msgstr "len deve essere multiplo di 4"
+
+#: ports/esp8266/modesp.c:274
+#, c-format
+msgid "memory allocation failed, allocating %u bytes for native code"
+msgstr ""
+"allocazione di memoria fallita, allocazione di %d byte per codice nativo"
+
+#: ports/esp8266/modesp.c:317
+msgid "flash location must be below 1MByte"
+msgstr "Locazione della flash deve essere inferiore a 1mb"
+
+#: ports/esp8266/modmachine.c:63
+msgid "frequency can only be either 80Mhz or 160MHz"
+msgstr "la frequenza può essere o 80Mhz o 160Mhz"
+
+#: ports/esp8266/modnetwork.c:61
+msgid "AP required"
+msgstr "AP richiesto"
+
+#: ports/esp8266/modnetwork.c:61
+msgid "STA required"
+msgstr "STA richiesta"
+
+#: ports/esp8266/modnetwork.c:87
+msgid "Cannot update i/f status"
+msgstr "Impossibile aggiornare status di i/f"
+
+#: ports/esp8266/modnetwork.c:142
+msgid "Cannot set STA config"
+msgstr "Impossibile impostare la configurazione della STA"
+
+#: ports/esp8266/modnetwork.c:144
+msgid "Cannot connect to AP"
+msgstr "Impossible connettersi all'AP"
+
+#: ports/esp8266/modnetwork.c:152
+msgid "Cannot disconnect from AP"
+msgstr "Impossible disconnettersi all'AP"
+
+#: ports/esp8266/modnetwork.c:173
+msgid "unknown status param"
+msgstr "prametro di stato sconosciuto"
+
+#: ports/esp8266/modnetwork.c:222
+msgid "STA must be active"
+msgstr "STA deve essere attiva"
+
+#: ports/esp8266/modnetwork.c:239
+msgid "scan failed"
+msgstr "scansione fallita"
+
+#: ports/esp8266/modnetwork.c:306
+msgid "wifi_set_ip_info() failed"
+msgstr "wifi_set_ip_info() faillito"
+
+#: ports/esp8266/modnetwork.c:319
+msgid "either pos or kw args are allowed"
+msgstr "sono permesse solo gli argomenti pos o kw"
+
+#: ports/esp8266/modnetwork.c:329
+msgid "can't get STA config"
+msgstr "impossibile recuperare la configurazione della STA"
+
+#: ports/esp8266/modnetwork.c:331
+msgid "can't get AP config"
+msgstr "impossibile recuperare le configurazioni dell'AP"
+
+#: ports/esp8266/modnetwork.c:346
+msgid "invalid buffer length"
+msgstr "lunghezza del buffer non valida"
+
+#: ports/esp8266/modnetwork.c:405
+msgid "can't set STA config"
+msgstr "impossibile impostare le configurazioni della STA"
+
+#: ports/esp8266/modnetwork.c:407
+msgid "can't set AP config"
+msgstr "impossibile impostare le configurazioni dell'AP"
+
+#: ports/esp8266/modnetwork.c:416
+msgid "can query only one param"
+msgstr "è possibile interrogare solo un parametro"
+
+#: ports/esp8266/modnetwork.c:469
+msgid "unknown config param"
+msgstr "parametro di configurazione sconosciuto"
+
+#: ports/nrf/common-hal/analogio/AnalogOut.c:37
+msgid "AnalogOut functionality not supported"
+msgstr "funzionalità AnalogOut non supportata"
+
+#: ports/nrf/common-hal/busio/I2C.c:95
+msgid "All I2C peripherals are in use"
+msgstr "Tutte le periferiche I2C sono in uso"
+
+#: ports/nrf/common-hal/busio/SPI.c:115
+msgid "All SPI peripherals are in use"
+msgstr "Tutte le periferiche SPI sono in uso"
+
+#: ports/nrf/common-hal/busio/UART.c:48
+#, c-format
+msgid "error = 0x%08lX"
+msgstr ""
+
+#: ports/nrf/common-hal/busio/UART.c:86
+#, fuzzy
+msgid "Invalid buffer size"
+msgstr "lunghezza del buffer non valida"
+
+#: ports/nrf/common-hal/busio/UART.c:90
+#, fuzzy
+msgid "Odd parity is not supported"
+msgstr "operazione I2C non supportata"
+
+#: ports/nrf/common-hal/busio/UART.c:322 ports/nrf/common-hal/busio/UART.c:326
+#: ports/nrf/common-hal/busio/UART.c:331 ports/nrf/common-hal/busio/UART.c:336
+#: ports/nrf/common-hal/busio/UART.c:342 ports/nrf/common-hal/busio/UART.c:347
+#: ports/nrf/common-hal/busio/UART.c:352 ports/nrf/common-hal/busio/UART.c:356
+#: ports/nrf/common-hal/busio/UART.c:364
+#, fuzzy
+msgid "busio.UART not available"
+msgstr "busio.UART non ancora implementato"
+
+#: ports/nrf/common-hal/microcontroller/Processor.c:49
+#, c-format
+msgid "Can not get temperature. status: 0x%02x"
+msgstr "Impossibile leggere la temperatura. status: 0x%02x"
+
+#: ports/nrf/common-hal/pulseio/PWMOut.c:162
+#, fuzzy
+msgid "All PWM peripherals are in use"
+msgstr "Tutte le periferiche SPI sono in uso"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:199
+msgid "Cannot apply GAP parameters."
+msgstr "Impossibile applicare i parametri GAP."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:213
+msgid "Cannot set PPCP parameters."
+msgstr "Impossibile impostare i parametri PPCP."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:245
+msgid "Can not query for the device address."
+msgstr "Non è possibile trovare l'indirizzo del dispositivo."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:264
+msgid "Can not add Vendor Specific 128-bit UUID."
+msgstr "Non è possibile aggiungere l'UUID del vendor specifico da 128-bit"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:284
+#: ports/nrf/drivers/bluetooth/ble_drv.c:298
+msgid "Can not add Service."
+msgstr "Non è possibile aggiungere Service."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:373
+msgid "Can not add Characteristic."
+msgstr "Non è possibile aggiungere Characteristic."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:400
+msgid "Can not apply device name in the stack."
+msgstr "Non è possibile inserire il nome del dipositivo nella lista."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:464
+#: ports/nrf/drivers/bluetooth/ble_drv.c:514
+msgid "Can not encode UUID, to check length."
+msgstr "Non è possibile codificare l'UUID, lunghezza da controllare."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:470
+#: ports/nrf/drivers/bluetooth/ble_drv.c:520
+msgid "Can encode UUID into the advertisement packet."
+msgstr "È possibile codificare l'UUID nel pacchetto di advertisement."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:545
+msgid "Can not fit data into the advertisement packet."
+msgstr "Impossibile inserire dati nel pacchetto di advertisement."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:558
+#: ports/nrf/drivers/bluetooth/ble_drv.c:604
+#, c-format
+msgid "Can not apply advertisement data. status: 0x%02x"
+msgstr "Impossible inserire dati advertisement. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:614
+#, c-format
+msgid "Can not start advertisement. status: 0x%02x"
+msgstr "Impossibile avviare advertisement. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:631
+#, c-format
+msgid "Can not stop advertisement. status: 0x%02x"
+msgstr "Impossibile fermare advertisement. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:650
+#: ports/nrf/drivers/bluetooth/ble_drv.c:726
+#, c-format
+msgid "Can not read attribute value. status: 0x%02x"
+msgstr "Impossibile leggere valore dell'attributo. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:667
+#: ports/nrf/drivers/bluetooth/ble_drv.c:756
+#, c-format
+msgid "Can not write attribute value. status: 0x%02x"
+msgstr "Impossibile scrivere valore dell'attributo. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:691
+#, c-format
+msgid "Can not notify attribute value. status: 0x%02x"
+msgstr "Impossibile notificare valore dell'attributo. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:784
+#, c-format
+msgid "Can not start scanning. status: 0x%02x"
+msgstr "Impossible iniziare la scansione. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:829
+#, c-format
+msgid "Can not connect. status: 0x%02x"
+msgstr "Impossibile connettersi. status: 0x%02x"
+
+#: ports/nrf/modules/ubluepy/ubluepy_characteristic.c:68
+#: ports/nrf/modules/ubluepy/ubluepy_service.c:80
+#: ports/nrf/modules/ubluepy/ubluepy_service.c:132
+#: ports/nrf/modules/ubluepy/ubluepy_uuid.c:137
+msgid "Invalid UUID parameter"
+msgstr "Parametro UUID non valido"
+
+#: ports/nrf/modules/ubluepy/ubluepy_service.c:73
+msgid "Invalid Service type"
+msgstr "Tipo di servizio non valido"
+
+#: ports/nrf/modules/ubluepy/ubluepy_uuid.c:127
+msgid "Invalid UUID string length"
+msgstr "Lunghezza della stringa UUID non valida"
+
+#: ports/unix/modffi.c:138
+msgid "Unknown type"
+msgstr "Tipo sconosciuto"
+
+#: ports/unix/modffi.c:207 ports/unix/modffi.c:265
+msgid "Error in ffi_prep_cif"
+msgstr "Errore in ffi_prep_cif"
+
+#: ports/unix/modffi.c:270
+msgid "ffi_prep_closure_loc"
+msgstr "ffi_prep_closure_loc"
+
+#: ports/unix/modffi.c:413
+msgid "Don't know how to pass object to native function"
+msgstr "Non so come passare l'oggetto alla funzione nativa"
+
+#: ports/unix/modusocket.c:474
+#, c-format
+msgid "[addrinfo error %d]"
+msgstr "[errore addrinfo %d]"
+
+#: py/argcheck.c:44
+msgid "function does not take keyword arguments"
+msgstr "la funzione non prende argomenti nominati"
+
+#: py/argcheck.c:54 py/bc.c:85 py/objnamedtuple.c:104
+#, c-format
+msgid "function takes %d positional arguments but %d were given"
+msgstr ""
+"la funzione prende %d argomenti posizionali ma ne sono stati forniti %d"
+
+#: py/argcheck.c:64
+#, c-format
+msgid "function missing %d required positional arguments"
+msgstr "mancano %d argomenti posizionali obbligatori alla funzione"
+
+#: py/argcheck.c:72
+#, c-format
+msgid "function expected at most %d arguments, got %d"
+msgstr "la funzione prevede al massimo %d argmoneti, ma ne ha ricevuti %d"
+
+#: py/argcheck.c:97
+msgid "'%q' argument required"
+msgstr "'%q' argomento richiesto"
+
+#: py/argcheck.c:122
+msgid "extra positional arguments given"
+msgstr "argomenti posizonali extra dati"
+
+#: py/argcheck.c:130
+msgid "extra keyword arguments given"
+msgstr "argomento nominato aggiuntivo fornito"
+
+#: py/argcheck.c:142
+msgid "argument num/types mismatch"
+msgstr "discrepanza di numero/tipo di argomenti"
+
+#: py/argcheck.c:147
+msgid "keyword argument(s) not yet implemented - use normal args instead"
+msgstr ""
+"argomento(i) nominati non ancora implementati - usare invece argomenti "
+"normali"
+
+#: py/bc.c:88 py/objnamedtuple.c:108
+msgid "%q() takes %d positional arguments but %d were given"
+msgstr "%q() prende %d argomenti posizionali ma ne sono stati forniti %d"
+
+#: py/bc.c:197 py/bc.c:215
+msgid "unexpected keyword argument"
+msgstr "argomento nominato inaspettato"
+
+#: py/bc.c:199
+msgid "keywords must be strings"
+msgstr "argomenti nominati devono essere stringhe"
+
+#: py/bc.c:206 py/objnamedtuple.c:138
+msgid "function got multiple values for argument '%q'"
+msgstr "la funzione ha ricevuto valori multipli per l'argomento '%q'"
+
+#: py/bc.c:218 py/objnamedtuple.c:130
+msgid "unexpected keyword argument '%q'"
+msgstr "argomento nominato '%q' inaspettato"
+
+#: py/bc.c:244
+#, c-format
+msgid "function missing required positional argument #%d"
+msgstr "mancante il #%d argomento posizonale obbligatorio della funzione"
+
+#: py/bc.c:260
+msgid "function missing required keyword argument '%q'"
+msgstr "argomento nominato '%q' mancante alla funzione"
+
+#: py/bc.c:269
+msgid "function missing keyword-only argument"
+msgstr "argomento nominato mancante alla funzione"
+
+#: py/binary.c:112
+msgid "bad typecode"
+msgstr ""
+
+#: py/builtinevex.c:99
+msgid "bad compile mode"
+msgstr ""
+
+#: py/builtinimport.c:338
+msgid "cannot perform relative import"
+msgstr "impossibile effettuare l'importazione relativa"
+
+#: py/builtinimport.c:422 py/builtinimport.c:534
+msgid "module not found"
+msgstr "modulo non trovato"
+
+#: py/builtinimport.c:425 py/builtinimport.c:537
+msgid "no module named '%q'"
+msgstr "nessun modulo chiamato '%q'"
+
+#: py/builtinimport.c:512
+msgid "relative import"
+msgstr "importazione relativa"
+
+#: py/compile.c:397 py/compile.c:542
+msgid "can't assign to expression"
+msgstr "impossibile assegnare all'espressione"
+
+#: py/compile.c:416
+msgid "multiple *x in assignment"
+msgstr "*x multipli nell'assegnamento"
+
+#: py/compile.c:642
+msgid "non-default argument follows default argument"
+msgstr "argomento non predefinito segue argmoento predfinito"
+
+#: py/compile.c:771 py/compile.c:789
+msgid "invalid micropython decorator"
+msgstr "decoratore non valido in micropython"
+
+#: py/compile.c:943
+msgid "can't delete expression"
+msgstr "impossibile cancellare l'espessione"
+
+#: py/compile.c:955
+msgid "'break' outside loop"
+msgstr "'break' al di fuori del ciclo"
+
+#: py/compile.c:958
+msgid "'continue' outside loop"
+msgstr "'continue' al di fuori del ciclo"
+
+#: py/compile.c:969
+msgid "'return' outside function"
+msgstr "'return' al di fuori della funzione"
+
+#: py/compile.c:1169
+msgid "identifier redefined as global"
+msgstr "identificatore ridefinito come globale"
+
+#: py/compile.c:1185
+msgid "no binding for nonlocal found"
+msgstr "nessun binding per nonlocal trovato"
+
+#: py/compile.c:1188
+msgid "identifier redefined as nonlocal"
+msgstr "identificatore ridefinito come nonlocal"
+
+#: py/compile.c:1197
+msgid "can't declare nonlocal in outer code"
+msgstr "impossibile dichiarare nonlocal nel codice esterno"
+
+#: py/compile.c:1542
+msgid "default 'except' must be last"
+msgstr "'except' predefinito deve essere ultimo"
+
+#: py/compile.c:2095
+msgid "*x must be assignment target"
+msgstr ""
+
+#: py/compile.c:2193
+msgid "super() can't find self"
+msgstr ""
+
+#: py/compile.c:2256
+msgid "can't have multiple *x"
+msgstr "impossibile usare *x multipli"
+
+#: py/compile.c:2263
+msgid "can't have multiple **x"
+msgstr "impossibile usare **x multipli"
+
+#: py/compile.c:2271
+msgid "LHS of keyword arg must be an id"
+msgstr ""
+
+#: py/compile.c:2287
+msgid "non-keyword arg after */**"
+msgstr "argomento non nominato dopo */**"
+
+#: py/compile.c:2291
+msgid "non-keyword arg after keyword arg"
+msgstr "argomento non nominato seguito da argomento nominato"
+
+#: py/compile.c:2463 py/compile.c:2473 py/compile.c:2712 py/compile.c:2742
+#: py/parse.c:1176
+msgid "invalid syntax"
+msgstr "sintassi non valida"
+
+#: py/compile.c:2465
+msgid "expecting key:value for dict"
+msgstr "chiave:valore atteso per dict"
+
+#: py/compile.c:2475
+msgid "expecting just a value for set"
+msgstr "un solo valore atteso per set"
+
+#: py/compile.c:2600
+msgid "'yield' outside function"
+msgstr "'yield' al di fuori della funzione"
+
+#: py/compile.c:2619
+msgid "'await' outside function"
+msgstr "'await' al di fuori della funzione"
+
+#: py/compile.c:2774
+msgid "name reused for argument"
+msgstr "nome riutilizzato come argomento"
+
+#: py/compile.c:2827
+msgid "parameter annotation must be an identifier"
+msgstr ""
+
+#: py/compile.c:2969 py/compile.c:3137
+msgid "return annotation must be an identifier"
+msgstr ""
+
+#: py/compile.c:3097
+msgid "inline assembler must be a function"
+msgstr "inline assembler deve essere una funzione"
+
+#: py/compile.c:3134
+msgid "unknown type"
+msgstr "tipo sconosciuto"
+
+#: py/compile.c:3154
+msgid "expecting an assembler instruction"
+msgstr "istruzione assembler attesa"
+
+#: py/compile.c:3184
+msgid "'label' requires 1 argument"
+msgstr "'label' richiede 1 argomento"
+
+#: py/compile.c:3190
+msgid "label redefined"
+msgstr "etichetta ridefinita"
+
+#: py/compile.c:3196
+msgid "'align' requires 1 argument"
+msgstr "'align' richiede 1 argomento"
+
+#: py/compile.c:3205
+msgid "'data' requires at least 2 arguments"
+msgstr "'data' richiede almeno 2 argomento"
+
+#: py/compile.c:3212
+msgid "'data' requires integer arguments"
+msgstr "'data' richiede argomenti interi"
+
+#: py/emitinlinethumb.c:102
+#, fuzzy
+msgid "can only have up to 4 parameters to Thumb assembly"
+msgstr "sono disponibili fino a 4 parametri per il Xtensa assembly"
+
+#: py/emitinlinethumb.c:107 py/emitinlinethumb.c:112
+#, fuzzy
+msgid "parameters must be registers in sequence r0 to r3"
+msgstr "parametri devono essere i registri in sequenza da a2 a a5"
+
+#: py/emitinlinethumb.c:188 py/emitinlinethumb.c:230
+#, fuzzy, c-format
+msgid "'%s' expects at most r%d"
+msgstr "'%s' aspetta un registro"
+
+#: py/emitinlinethumb.c:197 py/emitinlinextensa.c:162
+#, c-format
+msgid "'%s' expects a register"
+msgstr "'%s' aspetta un registro"
+
+#: py/emitinlinethumb.c:211
+#, fuzzy, c-format
+msgid "'%s' expects a special register"
+msgstr "'%s' aspetta un registro"
+
+#: py/emitinlinethumb.c:239
+#, fuzzy, c-format
+msgid "'%s' expects an FPU register"
+msgstr "'%s' aspetta un registro"
+
+#: py/emitinlinethumb.c:292
+#, fuzzy, c-format
+msgid "'%s' expects {r0, r1, ...}"
+msgstr "'%s' aspetta un registro"
+
+#: py/emitinlinethumb.c:299 py/emitinlinextensa.c:169
+#, c-format
+msgid "'%s' expects an integer"
+msgstr "'%s' aspetta un intero"
+
+#: py/emitinlinethumb.c:304
+#, fuzzy, c-format
+msgid "'%s' integer 0x%x does not fit in mask 0x%x"
+msgstr "intero '%s' non è nell'intervallo %d..%d"
+
+#: py/emitinlinethumb.c:328
+#, fuzzy, c-format
+msgid "'%s' expects an address of the form [a, b]"
+msgstr "'%s' aspetta un registro"
+
+#: py/emitinlinethumb.c:334 py/emitinlinextensa.c:182
+#, c-format
+msgid "'%s' expects a label"
+msgstr "'%s' aspetta una etichetta"
+
+#: py/emitinlinethumb.c:345 py/emitinlinextensa.c:193
+msgid "label '%q' not defined"
+msgstr "etichetta '%q' non definita"
+
+#: py/emitinlinethumb.c:806
+#, fuzzy, c-format
+msgid "unsupported Thumb instruction '%s' with %d arguments"
+msgstr "istruzione '%s' Xtensa non supportata con %d argomenti"
+
+#: py/emitinlinethumb.c:810
+#, fuzzy
+msgid "branch not in range"
+msgstr "argomento di chr() non è in range(256)"
+
+#: py/emitinlinextensa.c:86
+msgid "can only have up to 4 parameters to Xtensa assembly"
+msgstr "sono disponibili fino a 4 parametri per il Xtensa assembly"
+
+#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
+msgid "parameters must be registers in sequence a2 to a5"
+msgstr "parametri devono essere i registri in sequenza da a2 a a5"
+
+#: py/emitinlinextensa.c:174
+#, c-format
+msgid "'%s' integer %d is not within range %d..%d"
+msgstr "intero '%s' non è nell'intervallo %d..%d"
+
+#: py/emitinlinextensa.c:327
+#, c-format
+msgid "unsupported Xtensa instruction '%s' with %d arguments"
+msgstr "istruzione '%s' Xtensa non supportata con %d argomenti"
+
+#: py/emitnative.c:183
+msgid "unknown type '%q'"
+msgstr "tipo '%q' sconosciuto"
+
+#: py/emitnative.c:260
+msgid "Viper functions don't currently support more than 4 arguments"
+msgstr "Le funzioni Viper non supportano più di 4 argomenti al momento"
+
+#: py/emitnative.c:742
+msgid "conversion to object"
+msgstr "conversione in oggetto"
+
+#: py/emitnative.c:921
+msgid "local '%q' used before type known"
+msgstr "locla '%q' utilizzato prima che il tipo fosse noto"
+
+#: py/emitnative.c:1118 py/emitnative.c:1156
+msgid "can't load from '%q'"
+msgstr "impossibile caricare da '%q'"
+
+#: py/emitnative.c:1128
+msgid "can't load with '%q' index"
+msgstr "impossibile caricare con indice '%q'"
+
+#: py/emitnative.c:1188
+msgid "local '%q' has type '%q' but source is '%q'"
+msgstr "local '%q' ha tipo '%q' ma sorgente è '%q'"
+
+#: py/emitnative.c:1289 py/emitnative.c:1379
+msgid "can't store '%q'"
+msgstr "impossibile memorizzare '%q'"
+
+#: py/emitnative.c:1358 py/emitnative.c:1419
+msgid "can't store to '%q'"
+msgstr "impossibile memorizzare in '%q'"
+
+#: py/emitnative.c:1369
+msgid "can't store with '%q' index"
+msgstr "impossibile memorizzare con indice '%q'"
+
+#: py/emitnative.c:1540
+msgid "can't implicitly convert '%q' to 'bool'"
+msgstr "non è possibile convertire implicitamente '%q' in 'bool'"
+
+#: py/emitnative.c:1774
+msgid "unary op %q not implemented"
+msgstr "operazione unaria %q non implementata"
+
+#: py/emitnative.c:1930
+msgid "binary op %q not implemented"
+msgstr "operazione binaria %q non implementata"
+
+#: py/emitnative.c:1951
+msgid "can't do binary op between '%q' and '%q'"
+msgstr "impossibile eseguire operazione binaria tra '%q' e '%q'"
+
+#: py/emitnative.c:2126
+msgid "casting"
+msgstr "casting"
+
+#: py/emitnative.c:2173
+msgid "return expected '%q' but got '%q'"
+msgstr "return aspettava '%q' ma ha ottenuto '%q'"
+
+#: py/emitnative.c:2191
+msgid "must raise an object"
+msgstr "deve lanciare un oggetto"
+
+#: py/emitnative.c:2201
+msgid "native yield"
+msgstr "yield nativo"
+
+#: py/lexer.c:345
+msgid "unicode name escapes"
+msgstr ""
+
+#: py/modbuiltins.c:162
+msgid "chr() arg not in range(0x110000)"
+msgstr "argomento di chr() non è in range(0x110000)"
+
+#: py/modbuiltins.c:171
+msgid "chr() arg not in range(256)"
+msgstr "argomento di chr() non è in range(256)"
+
+#: py/modbuiltins.c:285
+msgid "arg is an empty sequence"
+msgstr "l'argomento è una sequenza vuota"
+
+#: py/modbuiltins.c:350
+msgid "ord expects a character"
+msgstr "ord() aspetta un carattere"
+
+#: py/modbuiltins.c:353
+#, c-format
+msgid "ord() expected a character, but string of length %d found"
+msgstr ""
+"ord() aspettava un carattere, ma ha ricevuto una stringa di lunghezza %d"
+
+#: py/modbuiltins.c:363
+msgid "3-arg pow() not supported"
+msgstr "pow() con tre argmomenti non supportata"
+
+#: py/modbuiltins.c:517
+msgid "must use keyword argument for key function"
+msgstr ""
+
+#: py/modmath.c:41 shared-bindings/math/__init__.c:53
+msgid "math domain error"
+msgstr "errore di dominio matematico"
+
+#: py/modmath.c:196 py/objfloat.c:270 py/objint_longlong.c:222
+#: py/objint_mpz.c:230 py/runtime.c:619 shared-bindings/math/__init__.c:346
+msgid "division by zero"
+msgstr "divisione per zero"
+
+#: py/modmicropython.c:155
+msgid "schedule stack full"
+msgstr ""
+
+#: py/modstruct.c:145 py/modstruct.c:153 py/modstruct.c:234 py/modstruct.c:244
+#: shared-bindings/struct/__init__.c:103 shared-bindings/struct/__init__.c:145
+#: shared-module/struct/__init__.c:91 shared-module/struct/__init__.c:175
+msgid "buffer too small"
+msgstr "buffer troppo piccolo"
+
+#: py/modthread.c:240
+msgid "expecting a dict for keyword args"
+msgstr "argomenti nominati necessitano un dizionario"
+
+#: py/moduerrno.c:143 py/moduerrno.c:146
+msgid "Permission denied"
+msgstr "Permesso negato"
+
+#: py/moduerrno.c:144
+msgid "No such file/directory"
+msgstr "Nessun file/directory esistente"
+
+#: py/moduerrno.c:145
+msgid "Input/output error"
+msgstr "Errore input/output"
+
+#: py/moduerrno.c:147
+msgid "File exists"
+msgstr "File esistente"
+
+#: py/moduerrno.c:148
+msgid "Unsupported operation"
+msgstr "Operazione non supportata"
+
+#: py/moduerrno.c:149
+msgid "Invalid argument"
+msgstr "Argomento non valido"
+
+#: py/obj.c:90
+msgid "Traceback (most recent call last):\n"
+msgstr "Traceback (chiamata più recente per ultima):\n"
+
+#: py/obj.c:94
+msgid " File \"%q\", line %d"
+msgstr " File \"%q\", riga %d"
+
+#: py/obj.c:96
+msgid " File \"%q\""
+msgstr " File \"%q\""
+
+#: py/obj.c:100
+msgid ", in %q\n"
+msgstr ", in %q\n"
+
+#: py/obj.c:257
+msgid "can't convert to int"
+msgstr "non è possibile convertire a int"
+
+#: py/obj.c:260
+#, c-format
+msgid "can't convert %s to int"
+msgstr "non è possibile convertire %s a int"
+
+#: py/obj.c:320
+msgid "can't convert to float"
+msgstr "non è possibile convertire a float"
+
+#: py/obj.c:323
+#, c-format
+msgid "can't convert %s to float"
+msgstr "non è possibile convertire %s a float"
+
+#: py/obj.c:353
+msgid "can't convert to complex"
+msgstr "non è possibile convertire a complex"
+
+#: py/obj.c:356
+#, c-format
+msgid "can't convert %s to complex"
+msgstr "non è possibile convertire a complex"
+
+#: py/obj.c:371
+msgid "expected tuple/list"
+msgstr "lista/tupla prevista"
+
+#: py/obj.c:374
+#, c-format
+msgid "object '%s' is not a tuple or list"
+msgstr "oggetto '%s' non è una tupla o una lista"
+
+#: py/obj.c:385
+msgid "tuple/list has wrong length"
+msgstr "tupla/lista ha la lunghezza sbagliata"
+
+#: py/obj.c:387
+#, c-format
+msgid "requested length %d but object has length %d"
+msgstr "lunghezza %d richiesta ma l'oggetto ha lunghezza %d"
+
+#: py/obj.c:400
+msgid "indices must be integers"
+msgstr "gli indici devono essere interi"
+
+#: py/obj.c:403
+msgid "%q indices must be integers, not %s"
+msgstr "gli indici %q devono essere interi, non %s"
+
+#: py/obj.c:423
+msgid "%q index out of range"
+msgstr "indice %q fuori intervallo"
+
+#: py/obj.c:455
+msgid "object has no len"
+msgstr "l'oggetto non ha lunghezza"
+
+#: py/obj.c:458
+#, c-format
+msgid "object of type '%s' has no len()"
+msgstr "l'oggetto di tipo '%s' non implementa len()"
+
+#: py/obj.c:496
+msgid "object does not support item deletion"
+msgstr ""
+
+#: py/obj.c:499
+#, c-format
+msgid "'%s' object does not support item deletion"
+msgstr ""
+
+#: py/obj.c:503
+msgid "object is not subscriptable"
+msgstr ""
+
+#: py/obj.c:506
+#, c-format
+msgid "'%s' object is not subscriptable"
+msgstr ""
+
+#: py/obj.c:510
+msgid "object does not support item assignment"
+msgstr ""
+
+#: py/obj.c:513
+#, c-format
+msgid "'%s' object does not support item assignment"
+msgstr ""
+
+#: py/obj.c:544
+msgid "object with buffer protocol required"
+msgstr ""
+
+#: py/objarray.c:413 py/objstr.c:427 py/objstrunicode.c:191 py/objtuple.c:187
+#: shared-bindings/nvm/ByteArray.c:85
+msgid "only slices with step=1 (aka None) are supported"
+msgstr "solo slice con step=1 (aka None) sono supportate"
+
+#: py/objarray.c:426
+msgid "lhs and rhs should be compatible"
+msgstr "lhs e rhs devono essere compatibili"
+
+#: py/objarray.c:444 shared-bindings/nvm/ByteArray.c:107
+msgid "array/bytes required on right side"
+msgstr ""
+
+#: py/objcomplex.c:203
+msgid "can't do truncated division of a complex number"
+msgstr "impossibile fare il modulo di un numero complesso"
+
+#: py/objcomplex.c:209
+msgid "complex division by zero"
+msgstr "complex divisione per zero"
+
+#: py/objcomplex.c:237
+msgid "0.0 to a complex power"
+msgstr "0.0 elevato alla potenza di un numero complesso"
+
+#: py/objdeque.c:107
+msgid "full"
+msgstr "pieno"
+
+#: py/objdeque.c:127
+msgid "empty"
+msgstr "vuoto"
+
+#: py/objdict.c:314
+msgid "popitem(): dictionary is empty"
+msgstr "popitem(): il dizionario è vuoto"
+
+#: py/objdict.c:357
+msgid "dict update sequence has wrong length"
+msgstr "sequanza di aggiornamento del dizionario ha la lunghezza errata"
+
+#: py/objfloat.c:308 py/parsenum.c:331
+msgid "complex values not supported"
+msgstr "valori complessi non supportai"
+
+#: py/objgenerator.c:108
+msgid "can't send non-None value to a just-started generator"
+msgstr ""
+
+#: py/objgenerator.c:126
+msgid "generator already executing"
+msgstr ""
+
+#: py/objgenerator.c:229
+msgid "generator ignored GeneratorExit"
+msgstr ""
+
+#: py/objgenerator.c:251
+msgid "can't pend throw to just-started generator"
+msgstr ""
+
+#: py/objint.c:144
+msgid "can't convert inf to int"
+msgstr "impossibile convertire inf in int"
+
+#: py/objint.c:146
+msgid "can't convert NaN to int"
+msgstr "impossibile convertire NaN in int"
+
+#: py/objint.c:163
+msgid "float too big"
+msgstr "float troppo grande"
+
+#: py/objint.c:328
+msgid "long int not supported in this build"
+msgstr "long int non supportata in questa build"
+
+#: py/objint.c:334 py/objint.c:340 py/objint.c:350 py/objint.c:358
+msgid "small int overflow"
+msgstr "small int overflow"
+
+#: py/objint_longlong.c:189 py/objint_mpz.c:283 py/runtime.c:486
+msgid "negative power with no float support"
+msgstr "potenza negativa senza supporto per float"
+
+#: py/objint_longlong.c:251
+msgid "ulonglong too large"
+msgstr "ulonglong troppo grande"
+
+#: py/objint_mpz.c:267 py/runtime.c:396 py/runtime.c:411
+msgid "negative shift count"
+msgstr ""
+
+#: py/objint_mpz.c:336
+msgid "pow() with 3 arguments requires integers"
+msgstr "pow() con 3 argomenti richiede interi"
+
+#: py/objint_mpz.c:347
+msgid "pow() 3rd argument cannot be 0"
+msgstr "il terzo argomento di pow() non può essere 0"
+
+#: py/objint_mpz.c:415
+msgid "overflow converting long int to machine word"
+msgstr "overflow convertendo long int in parola"
+
+#: py/objlist.c:273
+msgid "pop from empty list"
+msgstr "pop da una lista vuota"
+
+#: py/objnamedtuple.c:92
+msgid "can't set attribute"
+msgstr "impossibile impostare attributo"
+
+#: py/objobject.c:55
+msgid "__new__ arg must be a user-type"
+msgstr ""
+
+#: py/objrange.c:110
+msgid "zero step"
+msgstr "zero step"
+
+#: py/objset.c:371
+msgid "pop from an empty set"
+msgstr "pop da un set vuoto"
+
+#: py/objslice.c:66
+msgid "Length must be an int"
+msgstr "Length deve essere un intero"
+
+#: py/objslice.c:71
+msgid "Length must be non-negative"
+msgstr "Length deve essere non negativo"
+
+#: py/objslice.c:86 py/sequence.c:57
+msgid "slice step cannot be zero"
+msgstr "la step della slice non può essere zero"
+
+#: py/objslice.c:159
+msgid "Cannot subclass slice"
+msgstr "Impossibile subclasare slice"
+
+#: py/objstr.c:261
+msgid "bytes value out of range"
+msgstr "valore byte fuori intervallo"
+
+#: py/objstr.c:270
+msgid "wrong number of arguments"
+msgstr "numero di argomenti errato"
+
+#: py/objstr.c:467
+msgid "join expects a list of str/bytes objects consistent with self object"
+msgstr ""
+"join prende una lista di oggetti str/byte consistenti con l'oggetto stesso"
+
+#: py/objstr.c:542 py/objstr.c:647 py/objstr.c:1744
+msgid "empty separator"
+msgstr "separatore vuoto"
+
+#: py/objstr.c:641
+msgid "rsplit(None,n)"
+msgstr ""
+
+#: py/objstr.c:713
+msgid "substring not found"
+msgstr "sottostringa non trovata"
+
+#: py/objstr.c:770
+msgid "start/end indices"
+msgstr ""
+
+#: py/objstr.c:931
+msgid "bad format string"
+msgstr "stringa di formattazione scorretta"
+
+#: py/objstr.c:953
+msgid "single '}' encountered in format string"
+msgstr "'}' singolo presente nella stringa di formattazione"
+
+#: py/objstr.c:992
+msgid "bad conversion specifier"
+msgstr "specificatore di conversione scorretto"
+
+#: py/objstr.c:996
+msgid "end of format while looking for conversion specifier"
+msgstr ""
+
+#: py/objstr.c:998
+#, c-format
+msgid "unknown conversion specifier %c"
+msgstr "specificatore di conversione %s sconosciuto"
+
+#: py/objstr.c:1029
+msgid "unmatched '{' in format"
+msgstr "'{' spaiato nella stringa di formattazione"
+
+#: py/objstr.c:1036
+msgid "expected ':' after format specifier"
+msgstr "':' atteso dopo lo specificatore di formato"
+
+#: py/objstr.c:1050
+msgid ""
+"can't switch from automatic field numbering to manual field specification"
+msgstr ""
+
+#: py/objstr.c:1055 py/objstr.c:1083
+msgid "tuple index out of range"
+msgstr "indice della tupla fuori intervallo"
+
+#: py/objstr.c:1071
+msgid "attributes not supported yet"
+msgstr "attributi non ancora supportati"
+
+#: py/objstr.c:1079
+msgid ""
+"can't switch from manual field specification to automatic field numbering"
+msgstr ""
+
+#: py/objstr.c:1171
+msgid "invalid format specifier"
+msgstr "specificatore di formato non valido"
+
+#: py/objstr.c:1192
+msgid "sign not allowed in string format specifier"
+msgstr "segno non permesso nello spcificatore di formato della stringa"
+
+#: py/objstr.c:1200
+msgid "sign not allowed with integer format specifier 'c'"
+msgstr "segno non permesso nello spcificatore di formato 'c' della stringa"
+
+#: py/objstr.c:1259
+#, c-format
+msgid "unknown format code '%c' for object of type '%s'"
+msgstr "codice di formattaione '%c' sconosciuto per oggetto di tipo '%s'"
+
+#: py/objstr.c:1331
+#, c-format
+msgid "unknown format code '%c' for object of type 'float'"
+msgstr "codice di formattazione '%c' sconosciuto per oggetto di tipo 'float'"
+
+#: py/objstr.c:1343
+msgid "'=' alignment not allowed in string format specifier"
+msgstr ""
+
+#: py/objstr.c:1367
+#, c-format
+msgid "unknown format code '%c' for object of type 'str'"
+msgstr "codice di formattazione '%c' sconosciuto per oggetto di tipo 'str'"
+
+#: py/objstr.c:1415
+msgid "format requires a dict"
+msgstr "la formattazione richiede un dict"
+
+#: py/objstr.c:1424
+msgid "incomplete format key"
+msgstr ""
+
+#: py/objstr.c:1482
+msgid "incomplete format"
+msgstr "formato incompleto"
+
+#: py/objstr.c:1490
+msgid "not enough arguments for format string"
+msgstr "argomenti non sufficienti per la stringa di formattazione"
+
+#: py/objstr.c:1500
+#, c-format
+msgid "%%c requires int or char"
+msgstr "%%c necessita di int o char"
+
+#: py/objstr.c:1507
+msgid "integer required"
+msgstr "intero richiesto"
+
+#: py/objstr.c:1570
+#, c-format
+msgid "unsupported format character '%c' (0x%x) at index %d"
+msgstr "carattere di formattazione '%c' (0x%x) non supportato all indice %d"
+
+#: py/objstr.c:1577
+msgid "not all arguments converted during string formatting"
+msgstr ""
+"non tutti gli argomenti sono stati convertiti durante la formatazione in "
+"stringhe"
+
+#: py/objstr.c:2102
+msgid "can't convert to str implicitly"
+msgstr "impossibile convertire a stringa implicitamente"
+
+#: py/objstr.c:2106
+msgid "can't convert '%q' object to %q implicitly"
+msgstr "impossibile convertire l'oggetto '%q' implicitamente in %q"
+
+#: py/objstrunicode.c:134
+#, c-format
+msgid "string indices must be integers, not %s"
+msgstr "indici della stringa devono essere interi, non %s"
+
+#: py/objstrunicode.c:145 py/objstrunicode.c:164
+msgid "string index out of range"
+msgstr "indice della stringa fuori intervallo"
+
+#: py/objtype.c:358
+msgid "__init__() should return None"
+msgstr "__init__() deve ritornare None"
+
+#: py/objtype.c:360
+#, c-format
+msgid "__init__() should return None, not '%s'"
+msgstr "__init__() deve ritornare None, non '%s'"
+
+#: py/objtype.c:623 py/objtype.c:1275 py/runtime.c:1065
+msgid "unreadable attribute"
+msgstr "attributo non leggibile"
+
+#: py/objtype.c:868 py/runtime.c:653
+msgid "object not callable"
+msgstr ""
+
+#: py/objtype.c:870 py/runtime.c:655
+#, c-format
+msgid "'%s' object is not callable"
+msgstr ""
+
+#: py/objtype.c:978
+msgid "type takes 1 or 3 arguments"
+msgstr "tipo prende 1 o 3 argomenti"
+
+#: py/objtype.c:989
+msgid "cannot create instance"
+msgstr "impossibile creare un istanza"
+
+#: py/objtype.c:991
+msgid "cannot create '%q' instances"
+msgstr "creare '%q' istanze"
+
+#: py/objtype.c:1047
+msgid "can't add special method to already-subclassed class"
+msgstr ""
+
+#: py/objtype.c:1091 py/objtype.c:1097
+msgid "type is not an acceptable base type"
+msgstr "il tipo non è un tipo di base accettabile"
+
+#: py/objtype.c:1100
+msgid "type '%q' is not an acceptable base type"
+msgstr "il tipo '%q' non è un tipo di base accettabile"
+
+#: py/objtype.c:1137
+msgid "multiple inheritance not supported"
+msgstr "ereditarietà multipla non supportata"
+
+#: py/objtype.c:1164
+msgid "multiple bases have instance lay-out conflict"
+msgstr ""
+
+#: py/objtype.c:1205
+msgid "first argument to super() must be type"
+msgstr ""
+
+#: py/objtype.c:1370
+msgid "issubclass() arg 2 must be a class or a tuple of classes"
+msgstr ""
+"il secondo argomento di issubclass() deve essere una classe o una tupla di "
+"classi"
+
+#: py/objtype.c:1384
+msgid "issubclass() arg 1 must be a class"
+msgstr "il primo argomento di issubclass() deve essere una classe"
+
+#: py/parse.c:726
+msgid "constant must be an integer"
+msgstr "la costante deve essere un intero"
+
+#: py/parse.c:868
+msgid "Unable to init parser"
+msgstr "Inizilizzazione del parser non possibile"
+
+#: py/parse.c:1170
+msgid "unexpected indent"
+msgstr "indentazione inaspettata"
+
+#: py/parse.c:1173
+msgid "unindent does not match any outer indentation level"
+msgstr ""
+
+#: py/parsenum.c:60
+msgid "int() arg 2 must be >= 2 and <= 36"
+msgstr "il secondo argomanto di int() deve essere >= 2 e <= 36"
+
+#: py/parsenum.c:151
+msgid "invalid syntax for integer"
+msgstr "sintassi invalida per l'intero"
+
+#: py/parsenum.c:155
+#, c-format
+msgid "invalid syntax for integer with base %d"
+msgstr "sintassi invalida per l'intero con base %d"
+
+#: py/parsenum.c:339
+msgid "invalid syntax for number"
+msgstr "sintassi invalida per il numero"
+
+#: py/parsenum.c:342
+msgid "decimal numbers not supported"
+msgstr "numeri decimali non supportati"
+
+#: py/persistentcode.c:223
+msgid ""
+"Incompatible .mpy file. Please update all .mpy files. See http://adafru.it/"
+"mpy-update for more info."
+msgstr ""
+"File .mpy incompatibile. Aggiorna tutti i file .mpy. Vedi http://adafru.it/"
+"mpy-update per più informazioni."
+
+#: py/persistentcode.c:326
+msgid "can only save bytecode"
+msgstr "È possibile salvare solo bytecode"
+
+#: py/runtime.c:206
+msgid "name not defined"
+msgstr "nome non definito"
+
+#: py/runtime.c:209
+msgid "name '%q' is not defined"
+msgstr "nome '%q'non definito"
+
+#: py/runtime.c:304 py/runtime.c:611
+msgid "unsupported type for operator"
+msgstr "tipo non supportato per l'operando"
+
+#: py/runtime.c:307
+msgid "unsupported type for %q: '%s'"
+msgstr "tipo non supportato per %q: '%s'"
+
+#: py/runtime.c:614
+msgid "unsupported types for %q: '%s', '%s'"
+msgstr "tipi non supportati per %q: '%s', '%s'"
+
+#: py/runtime.c:881 py/runtime.c:888 py/runtime.c:945
+msgid "wrong number of values to unpack"
+msgstr "numero di valori da scompattare non corretto"
+
+#: py/runtime.c:883 py/runtime.c:947
+#, c-format
+msgid "need more than %d values to unpack"
+msgstr "necessari più di %d valori da scompattare"
+
+#: py/runtime.c:890
+#, c-format
+msgid "too many values to unpack (expected %d)"
+msgstr "troppi valori da scompattare (%d attesi)"
+
+#: py/runtime.c:984
+msgid "argument has wrong type"
+msgstr "il tipo dell'argomento è errato"
+
+#: py/runtime.c:986
+msgid "argument should be a '%q' not a '%q'"
+msgstr "l'argomento dovrebbe essere un '%q' e non un '%q'"
+
+#: py/runtime.c:1123 py/runtime.c:1197
+msgid "no such attribute"
+msgstr "attributo inesistente"
+
+#: py/runtime.c:1128
+msgid "type object '%q' has no attribute '%q'"
+msgstr "l'oggetto di tipo '%q' non ha l'attributo '%q'"
+
+#: py/runtime.c:1132 py/runtime.c:1200
+msgid "'%s' object has no attribute '%q'"
+msgstr "l'oggetto '%s' non ha l'attributo '%q'"
+
+#: py/runtime.c:1238
+msgid "object not iterable"
+msgstr "oggetto non iterabile"
+
+#: py/runtime.c:1241
+#, c-format
+msgid "'%s' object is not iterable"
+msgstr "l'oggetto '%s' non è iterabile"
+
+#: py/runtime.c:1260 py/runtime.c:1296
+msgid "object not an iterator"
+msgstr "l'oggetto non è un iteratore"
+
+#: py/runtime.c:1262 py/runtime.c:1298
+#, c-format
+msgid "'%s' object is not an iterator"
+msgstr "l'oggetto '%s' non è un iteratore"
+
+#: py/runtime.c:1401
+msgid "exceptions must derive from BaseException"
+msgstr "le eccezioni devono derivare da BaseException"
+
+#: py/runtime.c:1430
+msgid "cannot import name %q"
+msgstr "impossibile imporate il nome %q"
+
+#: py/runtime.c:1535
+msgid "memory allocation failed, heap is locked"
+msgstr "allocazione di memoria fallita, l'heap è bloccato"
+
+#: py/runtime.c:1539
+#, c-format
+msgid "memory allocation failed, allocating %u bytes"
+msgstr "allocazione di memoria fallita, allocando %u byte"
+
+#: py/runtime.c:1609
+msgid "maximum recursion depth exceeded"
+msgstr "profondità massima di ricorsione superata"
+
+#: py/sequence.c:264
+msgid "object not in sequence"
+msgstr "oggetto non in sequenza"
+
+#: py/stream.c:96
+msgid "stream operation not supported"
+msgstr "operazione di stream non supportata"
+
+#: py/vm.c:255
+msgid "local variable referenced before assignment"
+msgstr "variabile locale richiamata prima di un assegnamento"
+
+#: py/vm.c:1142
+msgid "no active exception to reraise"
+msgstr "nessuna eccezione attiva da rilanciare"
+
+#: py/vm.c:1284
+msgid "byte code not implemented"
+msgstr "byte code non implementato"
+
+#: shared-bindings/_stage/Layer.c:71
+msgid "graphic must be 2048 bytes long"
+msgstr "graphic deve essere lunga 2048 byte"
+
+#: shared-bindings/_stage/Layer.c:77 shared-bindings/_stage/Text.c:75
+msgid "palette must be 32 bytes long"
+msgstr "la palette deve essere lunga 32 byte"
+
+#: shared-bindings/_stage/Layer.c:84
+msgid "map buffer too small"
+msgstr "map buffer troppo piccolo"
+
+#: shared-bindings/_stage/Text.c:69
+msgid "font must be 2048 bytes long"
+msgstr "il font deve essere lungo 2048 byte"
+
+#: shared-bindings/_stage/Text.c:81
+msgid "chars buffer too small"
+msgstr "buffer dei caratteri troppo piccolo"
+
+#: shared-bindings/analogio/AnalogOut.c:118
+msgid "AnalogOut is only 16 bits. Value must be less than 65536."
+msgstr "AnalogOut ha solo 16 bit. Il valore deve essere meno di 65536."
+
+#: shared-bindings/audiobusio/I2SOut.c:225
+#: shared-bindings/audioio/AudioOut.c:223
+msgid "Not playing"
+msgstr "In pausa"
+
+#: shared-bindings/audiobusio/PDMIn.c:124
+msgid "Bit depth must be multiple of 8."
+msgstr "La profondità di bit deve essere multipla di 8."
+
+#: shared-bindings/audiobusio/PDMIn.c:128
+msgid "Oversample must be multiple of 8."
+msgstr "L'oversampling deve essere multiplo di 8."
+
+#: shared-bindings/audiobusio/PDMIn.c:136
+msgid "Microphone startup delay must be in range 0.0 to 1.0"
+msgstr ""
+"Il ritardo di avvio del microfono deve essere nell'intervallo tra 0.0 e 1.0"
+
+#: shared-bindings/audiobusio/PDMIn.c:193
+msgid "destination_length must be an int >= 0"
+msgstr "destination_length deve essere un int >= 0"
+
+#: shared-bindings/audiobusio/PDMIn.c:199
+msgid "Cannot record to a file"
+msgstr "Impossibile registrare in un file"
+
+#: shared-bindings/audiobusio/PDMIn.c:202
+msgid "Destination capacity is smaller than destination_length."
+msgstr "La capacità di destinazione è più piccola di destination_length."
+
+#: shared-bindings/audiobusio/PDMIn.c:206
+msgid "destination buffer must be an array of type 'H' for bit_depth = 16"
+msgstr ""
+"il buffer di destinazione deve essere un array di tipo 'H' con bit_depth = 16"
+
+#: shared-bindings/audiobusio/PDMIn.c:208
+msgid ""
+"destination buffer must be a bytearray or array of type 'B' for bit_depth = 8"
+msgstr ""
+"il buffer di destinazione deve essere un bytearray o un array di tipo 'B' "
+"con bit_depth = 8"
+
+#: shared-bindings/audioio/Mixer.c:94
+#, fuzzy
+msgid "Invalid voice count"
+msgstr "Tipo di servizio non valido"
+
+#: shared-bindings/audioio/Mixer.c:99
+#, fuzzy
+msgid "Invalid channel count"
+msgstr "Argomento non valido"
+
+#: shared-bindings/audioio/Mixer.c:103
+#, fuzzy
+msgid "Sample rate must be positive"
+msgstr "STA deve essere attiva"
+
+#: shared-bindings/audioio/Mixer.c:107
+#, fuzzy
+msgid "bits_per_sample must be 8 or 16"
+msgstr "i bit devono essere 7, 8 o 9"
+
+#: shared-bindings/audioio/RawSample.c:98
+msgid ""
+"sample_source buffer must be a bytearray or array of type 'h', 'H', 'b' or "
+"'B'"
+msgstr ""
+"il buffer sample_source deve essere un bytearray o un array di tipo 'h', "
+"'H', 'b' o 'B'"
+
+#: shared-bindings/audioio/RawSample.c:104
+msgid "buffer must be a bytes-like object"
+msgstr ""
+
+#: shared-bindings/audioio/WaveFile.c:78
+#: shared-bindings/displayio/OnDiskBitmap.c:85
+msgid "file must be a file opened in byte mode"
+msgstr ""
+
+#: shared-bindings/bitbangio/I2C.c:111 shared-bindings/bitbangio/SPI.c:121
+#: shared-bindings/busio/SPI.c:133
+msgid "Function requires lock"
+msgstr ""
+
+#: shared-bindings/bitbangio/I2C.c:195 shared-bindings/busio/I2C.c:210
+msgid "Buffer must be at least length 1"
+msgstr "Il buffer deve essere lungo almeno 1"
+
+#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:175
+msgid "Invalid polarity"
+msgstr "Polarità non valida"
+
+#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:179
+msgid "Invalid phase"
+msgstr "Fase non valida"
+
+#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:183
+msgid "Invalid number of bits"
+msgstr "Numero di bit non valido"
+
+#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:348
+msgid "buffer slices must be of equal length"
+msgstr "slice del buffer devono essere della stessa lunghezza"
+
+#: shared-bindings/busio/I2C.c:120
+msgid "Function requires lock."
+msgstr ""
+
+#: shared-bindings/busio/UART.c:102
+msgid "bits must be 7, 8 or 9"
+msgstr "i bit devono essere 7, 8 o 9"
+
+#: shared-bindings/busio/UART.c:114
+msgid "stop must be 1 or 2"
+msgstr ""
+
+#: shared-bindings/digitalio/DigitalInOut.c:211
+msgid "Invalid direction."
+msgstr "Direzione non valida."
+
+#: shared-bindings/digitalio/DigitalInOut.c:240
+msgid "Cannot set value when direction is input."
+msgstr ""
+
+#: shared-bindings/digitalio/DigitalInOut.c:266
+#: shared-bindings/digitalio/DigitalInOut.c:281
+msgid "Drive mode not used when direction is input."
+msgstr ""
+
+#: shared-bindings/digitalio/DigitalInOut.c:314
+#: shared-bindings/digitalio/DigitalInOut.c:331
+msgid "Pull not used when direction is output."
+msgstr ""
+
+#: shared-bindings/digitalio/DigitalInOut.c:340
+msgid "Unsupported pull value."
+msgstr "Valore di pull non supportato."
+
+#: shared-bindings/displayio/Bitmap.c:84
+msgid "y should be an int"
+msgstr "y dovrebbe essere un int"
+
+#: shared-bindings/displayio/Bitmap.c:89
+msgid "row buffer must be a bytearray or array of type 'b' or 'B'"
+msgstr "buffer di riga deve essere un bytearray o un array di tipo 'b' o 'B'"
+
+#: shared-bindings/displayio/Bitmap.c:94
+msgid "row data must be a buffer"
+msgstr "valori della riga devono essere un buffer"
+
+#: shared-bindings/displayio/ColorConverter.c:72
+msgid "color should be an int"
+msgstr "il colore deve essere un int"
+
+#: shared-bindings/displayio/FourWire.c:55
+#: shared-bindings/displayio/FourWire.c:64
+msgid "displayio is a work in progress"
+msgstr ""
+
+#: shared-bindings/displayio/Group.c:65
+msgid "Group must have size at least 1"
+msgstr "Il gruppo deve avere dimensione almeno 1"
+
+#: shared-bindings/displayio/Palette.c:96
+msgid "color buffer must be a bytearray or array of type 'b' or 'B'"
+msgstr ""
+"buffer del colore deve essere un bytearray o un array di tipo 'b' o 'B'"
+
+#: shared-bindings/displayio/Palette.c:102
+msgid "color buffer must be 3 bytes (RGB) or 4 bytes (RGB + pad byte)"
+msgstr ""
+"il buffer del colore deve esseer di 3 byte (RGB) o 4 byte (RGB + pad byte)"
+
+#: shared-bindings/displayio/Palette.c:106
+msgid "color must be between 0x000000 and 0xffffff"
+msgstr "il colore deve essere compreso tra 0x000000 e 0xffffff"
+
+#: shared-bindings/displayio/Palette.c:110
+msgid "color buffer must be a buffer or int"
+msgstr "il buffer del colore deve essere un buffer o un int"
+
+#: shared-bindings/displayio/Palette.c:123
+#: shared-bindings/displayio/Palette.c:137
+msgid "palette_index should be an int"
+msgstr "palette_index deve essere un int"
+
+#: shared-bindings/displayio/Sprite.c:48
+msgid "position must be 2-tuple"
+msgstr "position deve essere una 2-tuple"
+
+#: shared-bindings/displayio/Sprite.c:97
+msgid "unsupported bitmap type"
+msgstr "tipo di bitmap non supportato"
+
+#: shared-bindings/displayio/Sprite.c:162
+msgid "pixel_shader must be displayio.Palette or displayio.ColorConverter"
+msgstr "pixel_shader deve essere displayio.Palette o displayio.ColorConverter"
+
+#: shared-bindings/gamepad/GamePad.c:100
+msgid "too many arguments"
+msgstr "troppi argomenti"
+
+#: shared-bindings/gamepad/GamePad.c:104
+msgid "expected a DigitalInOut"
+msgstr "DigitalInOut atteso"
+
+#: shared-bindings/i2cslave/I2CSlave.c:98
+msgid "can't convert address to int"
+msgstr "impossible convertire indirizzo in int"
+
+#: shared-bindings/i2cslave/I2CSlave.c:101
+msgid "address out of bounds"
+msgstr "indirizzo fuori limite"
+
+#: shared-bindings/i2cslave/I2CSlave.c:107
+msgid "addresses is empty"
+msgstr "gli indirizzi sono vuoti"
+
+#: shared-bindings/microcontroller/Pin.c:89
+#: shared-bindings/neopixel_write/__init__.c:67
+#: shared-bindings/pulseio/PulseOut.c:75
+msgid "Expected a %q"
+msgstr "Atteso un %q"
+
+#: shared-bindings/microcontroller/Pin.c:100
+msgid "%q in use"
+msgstr "%q in uso"
+
+#: shared-bindings/microcontroller/__init__.c:126
+msgid "Invalid run mode."
+msgstr "Modalità di esecuzione non valida."
+
+#: shared-bindings/multiterminal/__init__.c:68
+msgid "Stream missing readinto() or write() method."
+msgstr "Metodi mancanti readinto() o write() allo stream."
+
+#: shared-bindings/nvm/ByteArray.c:99
+msgid "Slice and value different lengths."
+msgstr ""
+
+#: shared-bindings/nvm/ByteArray.c:104
+msgid "Array values should be single bytes."
+msgstr ""
+
+#: shared-bindings/nvm/ByteArray.c:111 shared-bindings/nvm/ByteArray.c:141
+msgid "Unable to write to nvm."
+msgstr "Imposibile scrivere su nvm."
+
+#: shared-bindings/nvm/ByteArray.c:137
+msgid "Bytes must be between 0 and 255."
+msgstr "I byte devono essere compresi tra 0 e 255"
+
+#: shared-bindings/os/__init__.c:200
+msgid "No hardware random available"
+msgstr "Nessun generatore hardware di numeri casuali disponibile"
+
+#: shared-bindings/pulseio/PWMOut.c:164
+msgid ""
+"PWM duty_cycle must be between 0 and 65535 inclusive (16 bit resolution)"
+msgstr ""
+"duty_cycle del PWM deve essere compresa tra 0 e 65535 inclusiva (risoluzione "
+"a 16 bit)"
+
+#: shared-bindings/pulseio/PWMOut.c:195
+#, fuzzy
+msgid ""
+"PWM frequency not writable when variable_frequency is False on construction."
+msgstr ""
+"frequenza PWM frequency non è scrivibile quando variable_frequency è "
+"impostato nel costruttore a False."
+
+#: shared-bindings/pulseio/PulseIn.c:275
+msgid "Cannot delete values"
+msgstr "Impossibile cancellare valori"
+
+#: shared-bindings/pulseio/PulseIn.c:281
+msgid "Slices not supported"
+msgstr "Slice non supportate"
+
+#: shared-bindings/pulseio/PulseIn.c:287
+msgid "index must be int"
+msgstr "l'indice deve essere int"
+
+#: shared-bindings/pulseio/PulseIn.c:293
+msgid "Read-only"
+msgstr "Sola lettura"
+
+#: shared-bindings/pulseio/PulseOut.c:134
+msgid "Array must contain halfwords (type 'H')"
+msgstr ""
+
+#: shared-bindings/random/__init__.c:92 shared-bindings/random/__init__.c:100
+msgid "stop not reachable from start"
+msgstr "stop non raggiungibile dall'inizio"
+
+#: shared-bindings/random/__init__.c:111
+msgid "step must be non-zero"
+msgstr "step deve essere non zero"
+
+#: shared-bindings/random/__init__.c:114
+msgid "invalid step"
+msgstr "step non valida"
+
+#: shared-bindings/random/__init__.c:146
+msgid "empty sequence"
+msgstr "sequenza vuota"
+
+#: shared-bindings/rtc/RTC.c:40 shared-bindings/rtc/RTC.c:44
+#: shared-bindings/time/__init__.c:190
+msgid "RTC is not supported on this board"
+msgstr "RTC non supportato su questa scheda"
+
+#: shared-bindings/rtc/RTC.c:52
+msgid "RTC calibration is not supported on this board"
+msgstr "calibrazione RTC non supportata su questa scheda"
+
+#: shared-bindings/storage/__init__.c:77
+msgid "filesystem must provide mount method"
+msgstr "il filesystem deve fornire un metodo di mount"
+
+#: shared-bindings/supervisor/__init__.c:93
+msgid "Brightness must be between 0 and 255"
+msgstr "La luminosità deve essere compreso tra 0 e 255"
+
+#: shared-bindings/supervisor/__init__.c:119
+msgid "Stack size must be at least 256"
+msgstr "La dimensione dello stack deve essere almeno 256"
+
+#: shared-bindings/time/__init__.c:78
+msgid "sleep length must be non-negative"
+msgstr "la lunghezza di sleed deve essere non negativa"
+
+#: shared-bindings/time/__init__.c:88
+msgid "time.struct_time() takes exactly 1 argument"
+msgstr "time.struct_time() prende esattamente un argomento"
+
+#: shared-bindings/time/__init__.c:91
+msgid "time.struct_time() takes a 9-sequence"
+msgstr ""
+
+#: shared-bindings/time/__init__.c:169 shared-bindings/time/__init__.c:250
+msgid "Tuple or struct_time argument required"
+msgstr "Tupla o struct_time richiesto come argomento"
+
+#: shared-bindings/time/__init__.c:174 shared-bindings/time/__init__.c:255
+msgid "function takes exactly 9 arguments"
+msgstr "la funzione prende esattamente 9 argomenti"
+
+#: shared-bindings/time/__init__.c:226 shared-bindings/time/__init__.c:259
+msgid "timestamp out of range for platform time_t"
+msgstr "timestamp è fuori intervallo per il time_t della piattaforma"
+
+#: shared-bindings/touchio/TouchIn.c:173
+msgid "threshold must be in the range 0-65536"
+msgstr "la soglia deve essere nell'intervallo 0-65536"
+
+#: shared-bindings/util.c:38
+msgid ""
+"Object has been deinitialized and can no longer be used. Create a new object."
+msgstr ""
+"L'oggetto è stato deinizializzato e non può essere più usato. Crea un nuovo "
+"oggetto."
+
+#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
+msgid "Couldn't allocate first buffer"
+msgstr "Impossibile allocare il primo buffer"
+
+#: shared-module/audioio/Mixer.c:53 shared-module/audioio/WaveFile.c:123
+msgid "Couldn't allocate second buffer"
+msgstr "Impossibile allocare il secondo buffer"
+
+#: shared-module/audioio/Mixer.c:82
+msgid "Voice index too high"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:85
+msgid "The sample's sample rate does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:88
+msgid "The sample's channel count does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:91
+msgid "The sample's bits_per_sample does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:100
+msgid "The sample's signedness does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/WaveFile.c:61
+msgid "Invalid wave file"
+msgstr "File wave non valido"
+
+#: shared-module/audioio/WaveFile.c:69
+msgid "Invalid format chunk size"
+msgstr ""
+
+#: shared-module/audioio/WaveFile.c:83
+msgid "Unsupported format"
+msgstr "Formato non supportato"
+
+#: shared-module/audioio/WaveFile.c:99
+msgid "Data chunk must follow fmt chunk"
+msgstr ""
+
+#: shared-module/audioio/WaveFile.c:107
+msgid "Invalid file"
+msgstr "File non valido"
+
+#: shared-module/bitbangio/I2C.c:58
+msgid "Clock stretch too long"
+msgstr ""
+
+#: shared-module/bitbangio/SPI.c:45
+msgid "Clock pin init failed."
+msgstr "Inizializzazione del pin di clock fallita."
+
+#: shared-module/bitbangio/SPI.c:51
+msgid "MOSI pin init failed."
+msgstr "inizializzazione del pin MOSI fallita."
+
+#: shared-module/bitbangio/SPI.c:62
+msgid "MISO pin init failed."
+msgstr "inizializzazione del pin MISO fallita."
+
+#: shared-module/bitbangio/SPI.c:122
+msgid "Cannot write without MOSI pin."
+msgstr "Impossibile scrivere senza pin MOSI."
+
+#: shared-module/bitbangio/SPI.c:177
+msgid "Cannot read without MISO pin."
+msgstr "Impossibile leggere senza pin MISO."
+
+#: shared-module/bitbangio/SPI.c:241
+msgid "Cannot transfer without MOSI and MISO pins."
+msgstr "Impossibile trasferire senza i pin MOSI e MISO."
+
+#: shared-module/displayio/Bitmap.c:49
+msgid "Only bit maps of 8 bit color or less are supported"
+msgstr "Sono supportate solo bitmap con colori a 8 bit o meno"
+
+#: shared-module/displayio/Bitmap.c:69
+msgid "row must be packed and word aligned"
+msgstr "la riga deve essere compattata e allineata alla parola"
+
+#: shared-module/displayio/Group.c:39
+msgid "Group full"
+msgstr "Gruppo pieno"
+
+#: shared-module/displayio/Group.c:48
+msgid "Group empty"
+msgstr "Gruppo vuoto"
+
+#: shared-module/displayio/OnDiskBitmap.c:49
+msgid "Invalid BMP file"
+msgstr "File BMP non valido"
+
+#: shared-module/displayio/OnDiskBitmap.c:59
+#, c-format
+msgid "Only Windows format, uncompressed BMP supported %d"
+msgstr "Formato solo di Windows, BMP non compresso supportato %d"
+
+#: shared-module/displayio/OnDiskBitmap.c:64
+#, c-format
+msgid "Only true color (24 bpp or higher) BMP supported %x"
+msgstr "Solo BMP true color (24 bpp o superiore) sono supportati %x"
+
+#: shared-module/struct/__init__.c:39
+msgid "'S' and 'O' are not supported format types"
+msgstr "'S' e 'O' non sono formati supportati"
+
+#: shared-module/struct/__init__.c:83
+msgid "too many arguments provided with the given format"
+msgstr "troppi argomenti forniti con il formato specificato"
diff --git a/locale/pt_BR.po b/locale/pt_BR.po
new file mode 100644
index 000000000..f3d055c08
--- /dev/null
+++ b/locale/pt_BR.po
@@ -0,0 +1,2463 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2018-10-09 20:51-0400\n"
+"PO-Revision-Date: 2018-10-02 21:14-0000\n"
+"Last-Translator: \n"
+"Language-Team: \n"
+"Language: pt_BR\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: extmod/machine_i2c.c:299
+msgid "invalid I2C peripheral"
+msgstr "periférico I2C inválido"
+
+#: extmod/machine_i2c.c:340 extmod/machine_i2c.c:354 extmod/machine_i2c.c:368
+#: extmod/machine_i2c.c:392
+msgid "I2C operation not supported"
+msgstr "I2C operação não suportada"
+
+#: extmod/machine_mem.c:45 ports/unix/modmachine.c:53
+#, c-format
+msgid "address %08x is not aligned to %d bytes"
+msgstr "endereço %08x não está alinhado com %d bytes"
+
+#: extmod/machine_spi.c:57
+msgid "invalid SPI peripheral"
+msgstr "periférico SPI inválido"
+
+#: extmod/machine_spi.c:124
+msgid "buffers must be the same length"
+msgstr "buffers devem ser o mesmo tamanho"
+
+#: extmod/machine_spi.c:207
+msgid "bits must be 8"
+msgstr "bits devem ser 8"
+
+#: extmod/machine_spi.c:210
+msgid "firstbit must be MSB"
+msgstr "firstbit devem ser MSB"
+
+#: extmod/machine_spi.c:215
+msgid "must specify all of sck/mosi/miso"
+msgstr "deve especificar todos sck/mosi/miso"
+
+#: extmod/modframebuf.c:299
+msgid "invalid format"
+msgstr "formato inválido"
+
+#: extmod/modubinascii.c:38 extmod/moduhashlib.c:102
+msgid "a bytes-like object is required"
+msgstr ""
+
+#: extmod/modubinascii.c:90
+msgid "odd-length string"
+msgstr ""
+
+#: extmod/modubinascii.c:101
+msgid "non-hex digit found"
+msgstr ""
+
+#: extmod/modubinascii.c:169
+msgid "incorrect padding"
+msgstr "preenchimento incorreto"
+
+#: extmod/moductypes.c:122
+msgid "syntax error in uctypes descriptor"
+msgstr ""
+
+#: extmod/moductypes.c:219
+msgid "Cannot unambiguously get sizeof scalar"
+msgstr ""
+
+#: extmod/moductypes.c:397
+msgid "struct: no fields"
+msgstr "struct: sem campos"
+
+#: extmod/moductypes.c:530
+msgid "struct: cannot index"
+msgstr "struct: não pode indexar"
+
+#: extmod/moductypes.c:544
+msgid "struct: index out of range"
+msgstr "struct: índice fora do intervalo"
+
+#: extmod/moduheapq.c:38
+msgid "heap must be a list"
+msgstr "heap deve ser uma lista"
+
+#: extmod/moduheapq.c:86 extmod/modutimeq.c:147 extmod/modutimeq.c:172
+msgid "empty heap"
+msgstr "heap vazia"
+
+#: extmod/modujson.c:281
+msgid "syntax error in JSON"
+msgstr "erro de sintaxe no JSON"
+
+#: extmod/modure.c:161
+msgid "Splitting with sub-captures"
+msgstr ""
+
+#: extmod/modure.c:207
+msgid "Error in regex"
+msgstr "Erro no regex"
+
+#: extmod/modussl_axtls.c:81
+msgid "invalid key"
+msgstr "chave inválida"
+
+#: extmod/modussl_axtls.c:87
+msgid "invalid cert"
+msgstr "certificado inválido"
+
+#: extmod/modutimeq.c:131
+msgid "queue overflow"
+msgstr "estouro de fila"
+
+#: extmod/moduzlib.c:98
+msgid "compression header"
+msgstr ""
+
+#: extmod/uos_dupterm.c:120
+msgid "invalid dupterm index"
+msgstr "Índice de dupterm inválido"
+
+#: extmod/vfs_fat.c:426 py/moduerrno.c:150
+msgid "Read-only filesystem"
+msgstr "Sistema de arquivos somente leitura"
+
+#: extmod/vfs_posix_file.c:48 ports/unix/file.c:50 py/objstringio.c:43
+msgid "I/O operation on closed file"
+msgstr "Operação I/O no arquivo fechado"
+
+#: lib/embed/abort_.c:8
+msgid "abort() called"
+msgstr "abort() chamado"
+
+#: lib/netutils/netutils.c:83
+msgid "invalid arguments"
+msgstr "argumentos inválidos"
+
+#: lib/utils/pyexec.c:97 py/builtinimport.c:253
+msgid "script compilation not supported"
+msgstr "compilação de script não suportada"
+
+#: main.c:143
+msgid " output:\n"
+msgstr " saída:\n"
+
+#: main.c:157 main.c:230
+msgid ""
+"Auto-reload is on. Simply save files over USB to run them or enter REPL to "
+"disable.\n"
+msgstr ""
+
+#: main.c:159
+msgid "Running in safe mode! Auto-reload is off.\n"
+msgstr "Rodando em modo seguro! Atualização automática está desligada.\n"
+
+#: main.c:161 main.c:232
+msgid "Auto-reload is off.\n"
+msgstr "A atualização automática está desligada.\n"
+
+#: main.c:175
+msgid "Running in safe mode! Not running saved code.\n"
+msgstr "Rodando em modo seguro! Não está executando o código salvo.\n"
+
+#: main.c:191
+msgid "WARNING: Your code filename has two extensions\n"
+msgstr "AVISO: Seu arquivo de código tem duas extensões\n"
+
+#: main.c:239
+msgid "You requested starting safe mode by "
+msgstr "Você solicitou o início do modo de segurança"
+
+#: main.c:242
+msgid "To exit, please reset the board without "
+msgstr "Para sair, por favor, reinicie a placa sem "
+
+#: main.c:249
+msgid ""
+"You are running in safe mode which means something really bad happened.\n"
+msgstr ""
+
+#: main.c:251
+msgid "Looks like our core CircuitPython code crashed hard. Whoops!\n"
+msgstr ""
+
+#: main.c:252
+msgid "Please file an issue here with the contents of your CIRCUITPY drive:\n"
+msgstr ""
+
+#: main.c:255
+msgid ""
+"The microcontroller's power dipped. Please make sure your power supply "
+"provides\n"
+msgstr ""
+
+#: main.c:256
+msgid ""
+"enough power for the whole circuit and press reset (after ejecting "
+"CIRCUITPY).\n"
+msgstr ""
+
+#: main.c:260
+msgid "Press any key to enter the REPL. Use CTRL-D to reload."
+msgstr ""
+
+#: main.c:416
+msgid "soft reboot\n"
+msgstr ""
+
+#: ports/atmel-samd/audio_dma.c:209
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:361
+msgid "All sync event channels in use"
+msgstr ""
+
+#: ports/atmel-samd/bindings/samd/Clock.c:135
+msgid "calibration is read only"
+msgstr "Calibração é somente leitura"
+
+#: ports/atmel-samd/bindings/samd/Clock.c:137
+msgid "calibration is out of range"
+msgstr "Calibração está fora do intervalo"
+
+#: ports/atmel-samd/board_busses.c:59 ports/nrf/board_busses.c:39
+msgid "No default I2C bus"
+msgstr "Nenhum barramento I2C padrão"
+
+#: ports/atmel-samd/board_busses.c:85 ports/nrf/board_busses.c:64
+msgid "No default SPI bus"
+msgstr "Nenhum barramento SPI padrão"
+
+#: ports/atmel-samd/board_busses.c:112 ports/nrf/board_busses.c:91
+msgid "No default UART bus"
+msgstr "Nenhum barramento UART padrão"
+
+#: ports/atmel-samd/common-hal/analogio/AnalogIn.c:63
+#: ports/nrf/common-hal/analogio/AnalogIn.c:39
+msgid "Pin does not have ADC capabilities"
+msgstr "O pino não tem recursos de ADC"
+
+#: ports/atmel-samd/common-hal/analogio/AnalogOut.c:49
+msgid "No DAC on chip"
+msgstr "Nenhum DAC no chip"
+
+#: ports/atmel-samd/common-hal/analogio/AnalogOut.c:56
+msgid "AnalogOut not supported on given pin"
+msgstr "Saída analógica não suportada no pino fornecido"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:147
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:150
+msgid "Invalid bit clock pin"
+msgstr "Pino de bit clock inválido"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:153
+msgid "Bit clock and word select must share a clock unit"
+msgstr ""
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:156
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:130
+msgid "Invalid data pin"
+msgstr "Pino de dados inválido"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:169
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:174
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:145
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:150
+msgid "Serializer in use"
+msgstr "Serializer em uso"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:230
+msgid "Clock unit in use"
+msgstr "Unidade de Clock em uso"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:240
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:172
+msgid "Unable to find free GCLK"
+msgstr "Não é possível encontrar GCLK livre"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:254
+msgid "Too many channels in sample."
+msgstr "Muitos canais na amostra."
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:305
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:339
+msgid "No DMA channel found"
+msgstr "Nenhum canal DMA encontrado"
+
+#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c:308
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:341
+msgid "Unable to allocate buffers for signed conversion"
+msgstr "Não é possível alocar buffers para conversão assinada"
+
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:109
+msgid "Invalid clock pin"
+msgstr "Pino do Clock inválido"
+
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:134
+msgid "Only 8 or 16 bit mono with "
+msgstr ""
+
+#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c:167
+msgid "sampling rate out of range"
+msgstr "Taxa de amostragem fora do intervalo"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:69
+msgid "DAC already in use"
+msgstr "DAC em uso"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:73
+msgid "Right channel unsupported"
+msgstr "Canal direito não suportado"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:76
+#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:116
+#: ports/atmel-samd/common-hal/touchio/TouchIn.c:65
+msgid "Invalid pin"
+msgstr "Pino inválido"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:84
+msgid "Invalid pin for left channel"
+msgstr "Pino inválido para canal esquerdo"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:88
+msgid "Invalid pin for right channel"
+msgstr "Pino inválido para canal direito"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:91
+msgid "Cannot output both channels on the same pin"
+msgstr ""
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:176
+#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:189
+#: ports/atmel-samd/common-hal/pulseio/PulseOut.c:110
+msgid "All timers in use"
+msgstr "Todos os temporizadores em uso"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:218
+msgid "All event channels in use"
+msgstr "Todos os canais de eventos em uso"
+
+#: ports/atmel-samd/common-hal/audioio/AudioOut.c:297
+#, c-format
+msgid "Sample rate too high. It must be less than %d"
+msgstr "Taxa de amostragem muito alta. Deve ser menor que %d"
+
+#: ports/atmel-samd/common-hal/busio/I2C.c:71
+msgid "Not enough pins available"
+msgstr "Não há pinos suficientes disponíveis"
+
+#: ports/atmel-samd/common-hal/busio/I2C.c:78
+#: ports/atmel-samd/common-hal/busio/SPI.c:132
+#: ports/atmel-samd/common-hal/busio/UART.c:119
+#: ports/atmel-samd/common-hal/i2cslave/I2CSlave.c:45
+#: ports/nrf/common-hal/busio/I2C.c:81
+msgid "Invalid pins"
+msgstr "Pinos inválidos"
+
+#: ports/atmel-samd/common-hal/busio/I2C.c:101
+msgid "SDA or SCL needs a pull up"
+msgstr "SDA ou SCL precisa de um pull up"
+
+#: ports/atmel-samd/common-hal/busio/I2C.c:121
+msgid "Unsupported baudrate"
+msgstr "Taxa de transmissão não suportada"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:66
+msgid "bytes > 8 bits not supported"
+msgstr "bytes > 8 bits não suportado"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:72
+#: ports/nrf/common-hal/busio/UART.c:82
+msgid "tx and rx cannot both be None"
+msgstr "TX e RX não podem ser ambos"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:145
+#: ports/nrf/common-hal/busio/UART.c:115
+msgid "Failed to allocate RX buffer"
+msgstr "Falha ao alocar buffer RX"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:153
+msgid "Could not initialize UART"
+msgstr "Não foi possível inicializar o UART"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:240
+#: ports/nrf/common-hal/busio/UART.c:149
+msgid "No RX pin"
+msgstr "Nenhum pino RX"
+
+#: ports/atmel-samd/common-hal/busio/UART.c:294
+#: ports/nrf/common-hal/busio/UART.c:195
+msgid "No TX pin"
+msgstr "Nenhum pino TX"
+
+#: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c:170
+#: ports/nrf/common-hal/digitalio/DigitalInOut.c:142
+msgid "Cannot get pull while in output mode"
+msgstr ""
+
+#: ports/atmel-samd/common-hal/microcontroller/__init__.c:74
+#: ports/esp8266/common-hal/microcontroller/__init__.c:64
+msgid "Cannot reset into bootloader because no bootloader is present."
+msgstr ""
+
+#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:120
+#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:369
+#: ports/nrf/common-hal/pulseio/PWMOut.c:120
+#: ports/nrf/common-hal/pulseio/PWMOut.c:232
+msgid "Invalid PWM frequency"
+msgstr "Frequência PWM inválida"
+
+#: ports/atmel-samd/common-hal/pulseio/PWMOut.c:187
+msgid "All timers for this pin are in use"
+msgstr "Todos os temporizadores para este pino estão em uso"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:110
+msgid "No hardware support on pin"
+msgstr "Nenhum suporte de hardware no pino"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:113
+msgid "EXTINT channel already in use"
+msgstr "Canal EXTINT em uso"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:118
+#: ports/esp8266/common-hal/pulseio/PulseIn.c:86
+#, c-format
+msgid "Failed to allocate RX buffer of %d bytes"
+msgstr "Falha ao alocar buffer RX de %d bytes"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:205
+#: ports/esp8266/common-hal/pulseio/PulseIn.c:151
+msgid "pop from an empty PulseIn"
+msgstr ""
+
+#: ports/atmel-samd/common-hal/pulseio/PulseIn.c:237
+#: ports/esp8266/common-hal/pulseio/PulseIn.c:182 py/obj.c:420
+msgid "index out of range"
+msgstr "Índice fora do intervalo"
+
+#: ports/atmel-samd/common-hal/pulseio/PulseOut.c:178
+msgid "Another send is already active"
+msgstr "Outro envio já está ativo"
+
+#: ports/atmel-samd/common-hal/rotaryio/IncrementalEncoder.c:38
+msgid "Both pins must support hardware interrupts"
+msgstr "Ambos os pinos devem suportar interrupções de hardware"
+
+#: ports/atmel-samd/common-hal/rotaryio/IncrementalEncoder.c:46
+msgid "A hardware interrupt channel is already in use"
+msgstr "Um canal de interrupção de hardware já está em uso"
+
+#: ports/atmel-samd/common-hal/rtc/RTC.c:101
+msgid "calibration value out of range +/-127"
+msgstr "Valor de calibração fora do intervalo +/- 127"
+
+#: ports/atmel-samd/common-hal/storage/__init__.c:48
+msgid "Cannot remount '/' when USB is active."
+msgstr "Não é possível remontar '/' enquanto o USB estiver ativo."
+
+#: ports/atmel-samd/common-hal/touchio/TouchIn.c:75
+msgid "No free GCLKs"
+msgstr "Não há GCLKs livre"
+
+#: ports/atmel-samd/common-hal/usb_hid/Device.c:78
+#: ports/nrf/common-hal/usb_hid/Device.c:45
+#, c-format
+msgid "Buffer incorrect size. Should be %d bytes."
+msgstr "Buffer de tamanho incorreto. Deve ser %d bytes."
+
+#: ports/atmel-samd/common-hal/usb_hid/Device.c:82
+#: ports/nrf/common-hal/usb_hid/Device.c:53
+msgid "USB Busy"
+msgstr "USB ocupada"
+
+#: ports/atmel-samd/common-hal/usb_hid/Device.c:82
+#: ports/nrf/common-hal/usb_hid/Device.c:59
+msgid "USB Error"
+msgstr "Erro na USB"
+
+#: ports/esp8266/common-hal/analogio/AnalogIn.c:43
+msgid "Pin %q does not have ADC capabilities"
+msgstr "Pino %q não tem recursos de ADC"
+
+#: ports/esp8266/common-hal/analogio/AnalogOut.c:39
+msgid "No hardware support for analog out."
+msgstr "Nenhum suporte de hardware para saída analógica."
+
+#: ports/esp8266/common-hal/busio/SPI.c:72
+msgid "Pins not valid for SPI"
+msgstr "Pinos não válidos para SPI"
+
+#: ports/esp8266/common-hal/busio/UART.c:45
+msgid "Only tx supported on UART1 (GPIO2)."
+msgstr "Apenas TX suportado no UART1 (GPIO2)."
+
+#: ports/esp8266/common-hal/busio/UART.c:67 ports/esp8266/machine_uart.c:108
+msgid "invalid data bits"
+msgstr "Bits de dados inválidos"
+
+#: ports/esp8266/common-hal/busio/UART.c:91 ports/esp8266/machine_uart.c:144
+msgid "invalid stop bits"
+msgstr "Bits de parada inválidos"
+
+#: ports/esp8266/common-hal/digitalio/DigitalInOut.c:200
+msgid "ESP8266 does not support pull down."
+msgstr "ESP8266 não suporta pull down."
+
+#: ports/esp8266/common-hal/digitalio/DigitalInOut.c:210
+msgid "GPIO16 does not support pull up."
+msgstr "GPIO16 não suporta pull up."
+
+#: ports/esp8266/common-hal/microcontroller/__init__.c:66
+msgid "ESP8226 does not support safe mode."
+msgstr "O ESP8226 não suporta o modo de segurança."
+
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:54
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:113
+#, c-format
+msgid "Maximum PWM frequency is %dhz."
+msgstr "A frequência máxima PWM é de %dhz."
+
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:57
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:116
+msgid "Minimum PWM frequency is 1hz."
+msgstr "A frequência mínima PWM é de 1hz"
+
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:68
+#, c-format
+msgid "Multiple PWM frequencies not supported. PWM already set to %dhz."
+msgstr "Múltiplas frequências PWM não suportadas. PWM já definido para %dhz."
+
+#: ports/esp8266/common-hal/pulseio/PWMOut.c:77 ports/esp8266/machine_pwm.c:70
+#, c-format
+msgid "PWM not supported on pin %d"
+msgstr "PWM não suportado no pino %d"
+
+#: ports/esp8266/common-hal/pulseio/PulseIn.c:78
+msgid "No PulseIn support for %q"
+msgstr "Não há suporte para PulseIn no pino %q"
+
+#: ports/esp8266/common-hal/storage/__init__.c:34
+msgid "Unable to remount filesystem"
+msgstr "Não é possível remontar o sistema de arquivos"
+
+#: ports/esp8266/common-hal/storage/__init__.c:38
+msgid "Use esptool to erase flash and re-upload Python instead"
+msgstr "Use o esptool para apagar o flash e recarregar o Python"
+
+#: ports/esp8266/esp_mphal.c:154
+msgid "C-level assert"
+msgstr ""
+
+#: ports/esp8266/machine_adc.c:57
+#, c-format
+msgid "not a valid ADC Channel: %d"
+msgstr "não é um canal ADC válido: %d"
+
+#: ports/esp8266/machine_hspi.c:131 ports/esp8266/machine_hspi.c:137
+msgid "impossible baudrate"
+msgstr "taxa de transmissão impossível"
+
+#: ports/esp8266/machine_pin.c:129
+msgid "expecting a pin"
+msgstr "esperando um pino"
+
+#: ports/esp8266/machine_pin.c:284
+msgid "Pin(16) doesn't support pull"
+msgstr "Pino (16) não suporta pull"
+
+#: ports/esp8266/machine_pin.c:323
+msgid "invalid pin"
+msgstr "Pino inválido"
+
+#: ports/esp8266/machine_pin.c:389
+msgid "pin does not have IRQ capabilities"
+msgstr "Pino não tem recursos de IRQ"
+
+#: ports/esp8266/machine_rtc.c:185
+msgid "buffer too long"
+msgstr "buffer muito longo"
+
+#: ports/esp8266/machine_rtc.c:209 ports/esp8266/machine_rtc.c:223
+#: ports/esp8266/machine_rtc.c:246
+msgid "invalid alarm"
+msgstr "Alarme inválido"
+
+#: ports/esp8266/machine_uart.c:169
+#, c-format
+msgid "UART(%d) does not exist"
+msgstr "UART(%d) não existe"
+
+#: ports/esp8266/machine_uart.c:219
+msgid "UART(1) can't read"
+msgstr "UART(1) não pode ler"
+
+#: ports/esp8266/modesp.c:119
+msgid "len must be multiple of 4"
+msgstr "len deve ser múltiplo de 4"
+
+#: ports/esp8266/modesp.c:274
+#, c-format
+msgid "memory allocation failed, allocating %u bytes for native code"
+msgstr "alocação de memória falhou, alocando %u bytes para código nativo"
+
+#: ports/esp8266/modesp.c:317
+msgid "flash location must be below 1MByte"
+msgstr "o local do flash deve estar abaixo de 1 MByte"
+
+#: ports/esp8266/modmachine.c:63
+msgid "frequency can only be either 80Mhz or 160MHz"
+msgstr "A frequência só pode ser 80Mhz ou 160MHz"
+
+#: ports/esp8266/modnetwork.c:61
+msgid "AP required"
+msgstr "AP requerido"
+
+#: ports/esp8266/modnetwork.c:61
+msgid "STA required"
+msgstr "STA requerido"
+
+#: ports/esp8266/modnetwork.c:87
+msgid "Cannot update i/f status"
+msgstr "Não é possível atualizar o status i/f"
+
+#: ports/esp8266/modnetwork.c:142
+msgid "Cannot set STA config"
+msgstr "Não é possível definir a configuração STA"
+
+#: ports/esp8266/modnetwork.c:144
+msgid "Cannot connect to AP"
+msgstr "Não é possível conectar-se ao AP"
+
+#: ports/esp8266/modnetwork.c:152
+msgid "Cannot disconnect from AP"
+msgstr "Não é possível desconectar do AP"
+
+#: ports/esp8266/modnetwork.c:173
+msgid "unknown status param"
+msgstr "parâmetro de status desconhecido"
+
+#: ports/esp8266/modnetwork.c:222
+msgid "STA must be active"
+msgstr "STA deve estar ativo"
+
+#: ports/esp8266/modnetwork.c:239
+msgid "scan failed"
+msgstr "varredura falhou"
+
+#: ports/esp8266/modnetwork.c:306
+msgid "wifi_set_ip_info() failed"
+msgstr "wifi_set_ip_info() falhou"
+
+#: ports/esp8266/modnetwork.c:319
+msgid "either pos or kw args are allowed"
+msgstr "pos ou kw args são permitidos"
+
+#: ports/esp8266/modnetwork.c:329
+msgid "can't get STA config"
+msgstr "não pode obter a configuração STA"
+
+#: ports/esp8266/modnetwork.c:331
+msgid "can't get AP config"
+msgstr "não pode obter configuração de AP"
+
+#: ports/esp8266/modnetwork.c:346
+msgid "invalid buffer length"
+msgstr "comprimento de buffer inválido"
+
+#: ports/esp8266/modnetwork.c:405
+msgid "can't set STA config"
+msgstr "não é possível definir a configuração STA"
+
+#: ports/esp8266/modnetwork.c:407
+msgid "can't set AP config"
+msgstr "não é possível definir a configuração do AP"
+
+#: ports/esp8266/modnetwork.c:416
+msgid "can query only one param"
+msgstr "pode consultar apenas um parâmetro"
+
+#: ports/esp8266/modnetwork.c:469
+msgid "unknown config param"
+msgstr "parâmetro configuração desconhecido"
+
+#: ports/nrf/common-hal/analogio/AnalogOut.c:37
+msgid "AnalogOut functionality not supported"
+msgstr "Funcionalidade AnalogOut não suportada"
+
+#: ports/nrf/common-hal/busio/I2C.c:95
+msgid "All I2C peripherals are in use"
+msgstr "Todos os periféricos I2C estão em uso"
+
+#: ports/nrf/common-hal/busio/SPI.c:115
+msgid "All SPI peripherals are in use"
+msgstr "Todos os periféricos SPI estão em uso"
+
+#: ports/nrf/common-hal/busio/UART.c:48
+#, c-format
+msgid "error = 0x%08lX"
+msgstr "erro = 0x%08lX"
+
+#: ports/nrf/common-hal/busio/UART.c:86
+#, fuzzy
+msgid "Invalid buffer size"
+msgstr "Arquivo inválido"
+
+#: ports/nrf/common-hal/busio/UART.c:90
+#, fuzzy
+msgid "Odd parity is not supported"
+msgstr "I2C operação não suportada"
+
+#: ports/nrf/common-hal/busio/UART.c:322 ports/nrf/common-hal/busio/UART.c:326
+#: ports/nrf/common-hal/busio/UART.c:331 ports/nrf/common-hal/busio/UART.c:336
+#: ports/nrf/common-hal/busio/UART.c:342 ports/nrf/common-hal/busio/UART.c:347
+#: ports/nrf/common-hal/busio/UART.c:352 ports/nrf/common-hal/busio/UART.c:356
+#: ports/nrf/common-hal/busio/UART.c:364
+msgid "busio.UART not available"
+msgstr "busio.UART não disponível"
+
+#: ports/nrf/common-hal/microcontroller/Processor.c:49
+#, c-format
+msgid "Can not get temperature. status: 0x%02x"
+msgstr "Não pode obter a temperatura. status: 0x%02x"
+
+#: ports/nrf/common-hal/pulseio/PWMOut.c:162
+#, fuzzy
+msgid "All PWM peripherals are in use"
+msgstr "Todos os temporizadores em uso"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:199
+msgid "Cannot apply GAP parameters."
+msgstr "Não é possível aplicar parâmetros GAP."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:213
+msgid "Cannot set PPCP parameters."
+msgstr "Não é possível definir parâmetros PPCP."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:245
+msgid "Can not query for the device address."
+msgstr "Não é possível consultar o endereço do dispositivo."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:264
+msgid "Can not add Vendor Specific 128-bit UUID."
+msgstr "Não é possível adicionar o UUID de 128 bits específico do fornecedor."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:284
+#: ports/nrf/drivers/bluetooth/ble_drv.c:298
+msgid "Can not add Service."
+msgstr "Não é possível adicionar o serviço."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:373
+msgid "Can not add Characteristic."
+msgstr "Não é possível adicionar Característica."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:400
+msgid "Can not apply device name in the stack."
+msgstr "Não é possível aplicar o nome do dispositivo na pilha."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:464
+#: ports/nrf/drivers/bluetooth/ble_drv.c:514
+msgid "Can not encode UUID, to check length."
+msgstr ""
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:470
+#: ports/nrf/drivers/bluetooth/ble_drv.c:520
+msgid "Can encode UUID into the advertisement packet."
+msgstr "Pode codificar o UUID no pacote de anúncios."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:545
+msgid "Can not fit data into the advertisement packet."
+msgstr "Não é possível ajustar dados no pacote de anúncios."
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:558
+#: ports/nrf/drivers/bluetooth/ble_drv.c:604
+#, c-format
+msgid "Can not apply advertisement data. status: 0x%02x"
+msgstr "Não é possível aplicar dados de anúncio. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:614
+#, c-format
+msgid "Can not start advertisement. status: 0x%02x"
+msgstr "Não é possível iniciar o anúncio. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:631
+#, c-format
+msgid "Can not stop advertisement. status: 0x%02x"
+msgstr "Não pode parar propaganda. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:650
+#: ports/nrf/drivers/bluetooth/ble_drv.c:726
+#, c-format
+msgid "Can not read attribute value. status: 0x%02x"
+msgstr "Não é possível ler o valor do atributo. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:667
+#: ports/nrf/drivers/bluetooth/ble_drv.c:756
+#, c-format
+msgid "Can not write attribute value. status: 0x%02x"
+msgstr "Não é possível gravar o valor do atributo. status: 0x%02x"
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:691
+#, c-format
+msgid "Can not notify attribute value. status: 0x%02x"
+msgstr ""
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:784
+#, c-format
+msgid "Can not start scanning. status: 0x%02x"
+msgstr ""
+
+#: ports/nrf/drivers/bluetooth/ble_drv.c:829
+#, c-format
+msgid "Can not connect. status: 0x%02x"
+msgstr ""
+
+#: ports/nrf/modules/ubluepy/ubluepy_characteristic.c:68
+#: ports/nrf/modules/ubluepy/ubluepy_service.c:80
+#: ports/nrf/modules/ubluepy/ubluepy_service.c:132
+#: ports/nrf/modules/ubluepy/ubluepy_uuid.c:137
+msgid "Invalid UUID parameter"
+msgstr "Parâmetro UUID inválido"
+
+#: ports/nrf/modules/ubluepy/ubluepy_service.c:73
+msgid "Invalid Service type"
+msgstr "Tipo de serviço inválido"
+
+#: ports/nrf/modules/ubluepy/ubluepy_uuid.c:127
+msgid "Invalid UUID string length"
+msgstr ""
+
+#: ports/unix/modffi.c:138
+msgid "Unknown type"
+msgstr "Tipo desconhecido"
+
+#: ports/unix/modffi.c:207 ports/unix/modffi.c:265
+msgid "Error in ffi_prep_cif"
+msgstr "Erro no ffi_prep_cif"
+
+#: ports/unix/modffi.c:270
+msgid "ffi_prep_closure_loc"
+msgstr "ffi_prep_closure_loc"
+
+#: ports/unix/modffi.c:413
+msgid "Don't know how to pass object to native function"
+msgstr "Não sabe como passar o objeto para a função nativa"
+
+#: ports/unix/modusocket.c:474
+#, c-format
+msgid "[addrinfo error %d]"
+msgstr ""
+
+#: py/argcheck.c:44
+msgid "function does not take keyword arguments"
+msgstr "função não aceita argumentos de palavras-chave"
+
+#: py/argcheck.c:54 py/bc.c:85 py/objnamedtuple.c:104
+#, c-format
+msgid "function takes %d positional arguments but %d were given"
+msgstr "função leva %d argumentos posicionais, mas apenas %d foram passadas"
+
+#: py/argcheck.c:64
+#, c-format
+msgid "function missing %d required positional arguments"
+msgstr "função ausente %d requer argumentos posicionais"
+
+#: py/argcheck.c:72
+#, c-format
+msgid "function expected at most %d arguments, got %d"
+msgstr "função esperada na maioria dos %d argumentos, obteve %d"
+
+#: py/argcheck.c:97
+msgid "'%q' argument required"
+msgstr "'%q' argumento(s) requerido(s)"
+
+#: py/argcheck.c:122
+msgid "extra positional arguments given"
+msgstr "argumentos extra posicionais passados"
+
+#: py/argcheck.c:130
+msgid "extra keyword arguments given"
+msgstr "argumentos extras de palavras-chave passados"
+
+#: py/argcheck.c:142
+msgid "argument num/types mismatch"
+msgstr ""
+
+#: py/argcheck.c:147
+msgid "keyword argument(s) not yet implemented - use normal args instead"
+msgstr ""
+
+#: py/bc.c:88 py/objnamedtuple.c:108
+msgid "%q() takes %d positional arguments but %d were given"
+msgstr ""
+
+#: py/bc.c:197 py/bc.c:215
+msgid "unexpected keyword argument"
+msgstr ""
+
+#: py/bc.c:199
+msgid "keywords must be strings"
+msgstr ""
+
+#: py/bc.c:206 py/objnamedtuple.c:138
+msgid "function got multiple values for argument '%q'"
+msgstr ""
+
+#: py/bc.c:218 py/objnamedtuple.c:130
+msgid "unexpected keyword argument '%q'"
+msgstr ""
+
+#: py/bc.c:244
+#, c-format
+msgid "function missing required positional argument #%d"
+msgstr ""
+
+#: py/bc.c:260
+msgid "function missing required keyword argument '%q'"
+msgstr ""
+
+#: py/bc.c:269
+msgid "function missing keyword-only argument"
+msgstr ""
+
+#: py/binary.c:112
+msgid "bad typecode"
+msgstr ""
+
+#: py/builtinevex.c:99
+msgid "bad compile mode"
+msgstr ""
+
+#: py/builtinimport.c:338
+msgid "cannot perform relative import"
+msgstr ""
+
+#: py/builtinimport.c:422 py/builtinimport.c:534
+msgid "module not found"
+msgstr ""
+
+#: py/builtinimport.c:425 py/builtinimport.c:537
+msgid "no module named '%q'"
+msgstr ""
+
+#: py/builtinimport.c:512
+msgid "relative import"
+msgstr ""
+
+#: py/compile.c:397 py/compile.c:542
+msgid "can't assign to expression"
+msgstr ""
+
+#: py/compile.c:416
+msgid "multiple *x in assignment"
+msgstr ""
+
+#: py/compile.c:642
+msgid "non-default argument follows default argument"
+msgstr ""
+
+#: py/compile.c:771 py/compile.c:789
+msgid "invalid micropython decorator"
+msgstr ""
+
+#: py/compile.c:943
+msgid "can't delete expression"
+msgstr ""
+
+#: py/compile.c:955
+msgid "'break' outside loop"
+msgstr ""
+
+#: py/compile.c:958
+msgid "'continue' outside loop"
+msgstr ""
+
+#: py/compile.c:969
+msgid "'return' outside function"
+msgstr ""
+
+#: py/compile.c:1169
+msgid "identifier redefined as global"
+msgstr ""
+
+#: py/compile.c:1185
+msgid "no binding for nonlocal found"
+msgstr ""
+
+#: py/compile.c:1188
+msgid "identifier redefined as nonlocal"
+msgstr ""
+
+#: py/compile.c:1197
+msgid "can't declare nonlocal in outer code"
+msgstr ""
+
+#: py/compile.c:1542
+msgid "default 'except' must be last"
+msgstr ""
+
+#: py/compile.c:2095
+msgid "*x must be assignment target"
+msgstr ""
+
+#: py/compile.c:2193
+msgid "super() can't find self"
+msgstr ""
+
+#: py/compile.c:2256
+msgid "can't have multiple *x"
+msgstr ""
+
+#: py/compile.c:2263
+msgid "can't have multiple **x"
+msgstr ""
+
+#: py/compile.c:2271
+msgid "LHS of keyword arg must be an id"
+msgstr ""
+
+#: py/compile.c:2287
+msgid "non-keyword arg after */**"
+msgstr ""
+
+#: py/compile.c:2291
+msgid "non-keyword arg after keyword arg"
+msgstr ""
+
+#: py/compile.c:2463 py/compile.c:2473 py/compile.c:2712 py/compile.c:2742
+#: py/parse.c:1176
+msgid "invalid syntax"
+msgstr ""
+
+#: py/compile.c:2465
+msgid "expecting key:value for dict"
+msgstr ""
+
+#: py/compile.c:2475
+msgid "expecting just a value for set"
+msgstr ""
+
+#: py/compile.c:2600
+msgid "'yield' outside function"
+msgstr ""
+
+#: py/compile.c:2619
+msgid "'await' outside function"
+msgstr ""
+
+#: py/compile.c:2774
+msgid "name reused for argument"
+msgstr ""
+
+#: py/compile.c:2827
+msgid "parameter annotation must be an identifier"
+msgstr ""
+
+#: py/compile.c:2969 py/compile.c:3137
+msgid "return annotation must be an identifier"
+msgstr ""
+
+#: py/compile.c:3097
+msgid "inline assembler must be a function"
+msgstr ""
+
+#: py/compile.c:3134
+msgid "unknown type"
+msgstr ""
+
+#: py/compile.c:3154
+msgid "expecting an assembler instruction"
+msgstr ""
+
+#: py/compile.c:3184
+msgid "'label' requires 1 argument"
+msgstr ""
+
+#: py/compile.c:3190
+msgid "label redefined"
+msgstr ""
+
+#: py/compile.c:3196
+msgid "'align' requires 1 argument"
+msgstr ""
+
+#: py/compile.c:3205
+msgid "'data' requires at least 2 arguments"
+msgstr ""
+
+#: py/compile.c:3212
+msgid "'data' requires integer arguments"
+msgstr ""
+
+#: py/emitinlinethumb.c:102
+msgid "can only have up to 4 parameters to Thumb assembly"
+msgstr ""
+
+#: py/emitinlinethumb.c:107 py/emitinlinethumb.c:112
+msgid "parameters must be registers in sequence r0 to r3"
+msgstr ""
+
+#: py/emitinlinethumb.c:188 py/emitinlinethumb.c:230
+#, c-format
+msgid "'%s' expects at most r%d"
+msgstr ""
+
+#: py/emitinlinethumb.c:197 py/emitinlinextensa.c:162
+#, c-format
+msgid "'%s' expects a register"
+msgstr ""
+
+#: py/emitinlinethumb.c:211
+#, c-format
+msgid "'%s' expects a special register"
+msgstr ""
+
+#: py/emitinlinethumb.c:239
+#, c-format
+msgid "'%s' expects an FPU register"
+msgstr ""
+
+#: py/emitinlinethumb.c:292
+#, c-format
+msgid "'%s' expects {r0, r1, ...}"
+msgstr ""
+
+#: py/emitinlinethumb.c:299 py/emitinlinextensa.c:169
+#, c-format
+msgid "'%s' expects an integer"
+msgstr ""
+
+#: py/emitinlinethumb.c:304
+#, c-format
+msgid "'%s' integer 0x%x does not fit in mask 0x%x"
+msgstr ""
+
+#: py/emitinlinethumb.c:328
+#, c-format
+msgid "'%s' expects an address of the form [a, b]"
+msgstr ""
+
+#: py/emitinlinethumb.c:334 py/emitinlinextensa.c:182
+#, c-format
+msgid "'%s' expects a label"
+msgstr ""
+
+#: py/emitinlinethumb.c:345 py/emitinlinextensa.c:193
+msgid "label '%q' not defined"
+msgstr ""
+
+#: py/emitinlinethumb.c:806
+#, c-format
+msgid "unsupported Thumb instruction '%s' with %d arguments"
+msgstr ""
+
+#: py/emitinlinethumb.c:810
+#, fuzzy
+msgid "branch not in range"
+msgstr "Calibração está fora do intervalo"
+
+#: py/emitinlinextensa.c:86
+msgid "can only have up to 4 parameters to Xtensa assembly"
+msgstr ""
+
+#: py/emitinlinextensa.c:91 py/emitinlinextensa.c:96
+msgid "parameters must be registers in sequence a2 to a5"
+msgstr ""
+
+#: py/emitinlinextensa.c:174
+#, c-format
+msgid "'%s' integer %d is not within range %d..%d"
+msgstr ""
+
+#: py/emitinlinextensa.c:327
+#, c-format
+msgid "unsupported Xtensa instruction '%s' with %d arguments"
+msgstr ""
+
+#: py/emitnative.c:183
+msgid "unknown type '%q'"
+msgstr ""
+
+#: py/emitnative.c:260
+msgid "Viper functions don't currently support more than 4 arguments"
+msgstr ""
+
+#: py/emitnative.c:742
+msgid "conversion to object"
+msgstr ""
+
+#: py/emitnative.c:921
+msgid "local '%q' used before type known"
+msgstr ""
+
+#: py/emitnative.c:1118 py/emitnative.c:1156
+msgid "can't load from '%q'"
+msgstr ""
+
+#: py/emitnative.c:1128
+msgid "can't load with '%q' index"
+msgstr ""
+
+#: py/emitnative.c:1188
+msgid "local '%q' has type '%q' but source is '%q'"
+msgstr ""
+
+#: py/emitnative.c:1289 py/emitnative.c:1379
+msgid "can't store '%q'"
+msgstr ""
+
+#: py/emitnative.c:1358 py/emitnative.c:1419
+msgid "can't store to '%q'"
+msgstr ""
+
+#: py/emitnative.c:1369
+msgid "can't store with '%q' index"
+msgstr ""
+
+#: py/emitnative.c:1540
+msgid "can't implicitly convert '%q' to 'bool'"
+msgstr ""
+
+#: py/emitnative.c:1774
+msgid "unary op %q not implemented"
+msgstr ""
+
+#: py/emitnative.c:1930
+msgid "binary op %q not implemented"
+msgstr ""
+
+#: py/emitnative.c:1951
+msgid "can't do binary op between '%q' and '%q'"
+msgstr ""
+
+#: py/emitnative.c:2126
+msgid "casting"
+msgstr ""
+
+#: py/emitnative.c:2173
+msgid "return expected '%q' but got '%q'"
+msgstr ""
+
+#: py/emitnative.c:2191
+msgid "must raise an object"
+msgstr ""
+
+#: py/emitnative.c:2201
+msgid "native yield"
+msgstr ""
+
+#: py/lexer.c:345
+msgid "unicode name escapes"
+msgstr ""
+
+#: py/modbuiltins.c:162
+msgid "chr() arg not in range(0x110000)"
+msgstr ""
+
+#: py/modbuiltins.c:171
+msgid "chr() arg not in range(256)"
+msgstr ""
+
+#: py/modbuiltins.c:285
+msgid "arg is an empty sequence"
+msgstr ""
+
+#: py/modbuiltins.c:350
+msgid "ord expects a character"
+msgstr ""
+
+#: py/modbuiltins.c:353
+#, c-format
+msgid "ord() expected a character, but string of length %d found"
+msgstr ""
+
+#: py/modbuiltins.c:363
+msgid "3-arg pow() not supported"
+msgstr ""
+
+#: py/modbuiltins.c:517
+msgid "must use keyword argument for key function"
+msgstr ""
+
+#: py/modmath.c:41 shared-bindings/math/__init__.c:53
+msgid "math domain error"
+msgstr ""
+
+#: py/modmath.c:196 py/objfloat.c:270 py/objint_longlong.c:222
+#: py/objint_mpz.c:230 py/runtime.c:619 shared-bindings/math/__init__.c:346
+msgid "division by zero"
+msgstr "divisão por zero"
+
+#: py/modmicropython.c:155
+msgid "schedule stack full"
+msgstr ""
+
+#: py/modstruct.c:145 py/modstruct.c:153 py/modstruct.c:234 py/modstruct.c:244
+#: shared-bindings/struct/__init__.c:103 shared-bindings/struct/__init__.c:145
+#: shared-module/struct/__init__.c:91 shared-module/struct/__init__.c:175
+msgid "buffer too small"
+msgstr ""
+
+#: py/modthread.c:240
+msgid "expecting a dict for keyword args"
+msgstr ""
+
+#: py/moduerrno.c:143 py/moduerrno.c:146
+msgid "Permission denied"
+msgstr "Permissão negada"
+
+#: py/moduerrno.c:144
+msgid "No such file/directory"
+msgstr ""
+
+#: py/moduerrno.c:145
+msgid "Input/output error"
+msgstr ""
+
+#: py/moduerrno.c:147
+msgid "File exists"
+msgstr "Arquivo já existe"
+
+#: py/moduerrno.c:148
+msgid "Unsupported operation"
+msgstr ""
+
+#: py/moduerrno.c:149
+msgid "Invalid argument"
+msgstr "Argumento inválido"
+
+#: py/obj.c:90
+msgid "Traceback (most recent call last):\n"
+msgstr ""
+
+#: py/obj.c:94
+msgid " File \"%q\", line %d"
+msgstr " Arquivo \"%q\", linha %d"
+
+#: py/obj.c:96
+msgid " File \"%q\""
+msgstr " Arquivo \"%q\""
+
+#: py/obj.c:100
+msgid ", in %q\n"
+msgstr ""
+
+#: py/obj.c:257
+msgid "can't convert to int"
+msgstr ""
+
+#: py/obj.c:260
+#, c-format
+msgid "can't convert %s to int"
+msgstr ""
+
+#: py/obj.c:320
+msgid "can't convert to float"
+msgstr ""
+
+#: py/obj.c:323
+#, c-format
+msgid "can't convert %s to float"
+msgstr ""
+
+#: py/obj.c:353
+msgid "can't convert to complex"
+msgstr ""
+
+#: py/obj.c:356
+#, c-format
+msgid "can't convert %s to complex"
+msgstr ""
+
+#: py/obj.c:371
+msgid "expected tuple/list"
+msgstr ""
+
+#: py/obj.c:374
+#, c-format
+msgid "object '%s' is not a tuple or list"
+msgstr ""
+
+#: py/obj.c:385
+msgid "tuple/list has wrong length"
+msgstr ""
+
+#: py/obj.c:387
+#, c-format
+msgid "requested length %d but object has length %d"
+msgstr ""
+
+#: py/obj.c:400
+msgid "indices must be integers"
+msgstr ""
+
+#: py/obj.c:403
+msgid "%q indices must be integers, not %s"
+msgstr ""
+
+#: py/obj.c:423
+msgid "%q index out of range"
+msgstr ""
+
+#: py/obj.c:455
+msgid "object has no len"
+msgstr ""
+
+#: py/obj.c:458
+#, c-format
+msgid "object of type '%s' has no len()"
+msgstr ""
+
+#: py/obj.c:496
+msgid "object does not support item deletion"
+msgstr ""
+
+#: py/obj.c:499
+#, c-format
+msgid "'%s' object does not support item deletion"
+msgstr ""
+
+#: py/obj.c:503
+msgid "object is not subscriptable"
+msgstr ""
+
+#: py/obj.c:506
+#, c-format
+msgid "'%s' object is not subscriptable"
+msgstr ""
+
+#: py/obj.c:510
+msgid "object does not support item assignment"
+msgstr ""
+
+#: py/obj.c:513
+#, c-format
+msgid "'%s' object does not support item assignment"
+msgstr ""
+
+#: py/obj.c:544
+msgid "object with buffer protocol required"
+msgstr ""
+
+#: py/objarray.c:413 py/objstr.c:427 py/objstrunicode.c:191 py/objtuple.c:187
+#: shared-bindings/nvm/ByteArray.c:85
+msgid "only slices with step=1 (aka None) are supported"
+msgstr ""
+
+#: py/objarray.c:426
+msgid "lhs and rhs should be compatible"
+msgstr ""
+
+#: py/objarray.c:444 shared-bindings/nvm/ByteArray.c:107
+msgid "array/bytes required on right side"
+msgstr ""
+
+#: py/objcomplex.c:203
+msgid "can't do truncated division of a complex number"
+msgstr ""
+
+#: py/objcomplex.c:209
+msgid "complex division by zero"
+msgstr ""
+
+#: py/objcomplex.c:237
+msgid "0.0 to a complex power"
+msgstr ""
+
+#: py/objdeque.c:107
+msgid "full"
+msgstr "cheio"
+
+#: py/objdeque.c:127
+msgid "empty"
+msgstr "vazio"
+
+#: py/objdict.c:314
+msgid "popitem(): dictionary is empty"
+msgstr ""
+
+#: py/objdict.c:357
+msgid "dict update sequence has wrong length"
+msgstr ""
+
+#: py/objfloat.c:308 py/parsenum.c:331
+msgid "complex values not supported"
+msgstr ""
+
+#: py/objgenerator.c:108
+msgid "can't send non-None value to a just-started generator"
+msgstr ""
+
+#: py/objgenerator.c:126
+msgid "generator already executing"
+msgstr ""
+
+#: py/objgenerator.c:229
+msgid "generator ignored GeneratorExit"
+msgstr ""
+
+#: py/objgenerator.c:251
+msgid "can't pend throw to just-started generator"
+msgstr ""
+
+#: py/objint.c:144
+msgid "can't convert inf to int"
+msgstr ""
+
+#: py/objint.c:146
+msgid "can't convert NaN to int"
+msgstr ""
+
+#: py/objint.c:163
+msgid "float too big"
+msgstr "float muito grande"
+
+#: py/objint.c:328
+msgid "long int not supported in this build"
+msgstr ""
+
+#: py/objint.c:334 py/objint.c:340 py/objint.c:350 py/objint.c:358
+msgid "small int overflow"
+msgstr ""
+
+#: py/objint_longlong.c:189 py/objint_mpz.c:283 py/runtime.c:486
+msgid "negative power with no float support"
+msgstr ""
+
+#: py/objint_longlong.c:251
+msgid "ulonglong too large"
+msgstr ""
+
+#: py/objint_mpz.c:267 py/runtime.c:396 py/runtime.c:411
+msgid "negative shift count"
+msgstr ""
+
+#: py/objint_mpz.c:336
+msgid "pow() with 3 arguments requires integers"
+msgstr ""
+
+#: py/objint_mpz.c:347
+msgid "pow() 3rd argument cannot be 0"
+msgstr ""
+
+#: py/objint_mpz.c:415
+msgid "overflow converting long int to machine word"
+msgstr ""
+
+#: py/objlist.c:273
+msgid "pop from empty list"
+msgstr ""
+
+#: py/objnamedtuple.c:92
+msgid "can't set attribute"
+msgstr ""
+
+#: py/objobject.c:55
+msgid "__new__ arg must be a user-type"
+msgstr ""
+
+#: py/objrange.c:110
+msgid "zero step"
+msgstr "passo zero"
+
+#: py/objset.c:371
+msgid "pop from an empty set"
+msgstr ""
+
+#: py/objslice.c:66
+msgid "Length must be an int"
+msgstr "Tamanho deve ser um int"
+
+#: py/objslice.c:71
+msgid "Length must be non-negative"
+msgstr ""
+
+#: py/objslice.c:86 py/sequence.c:57
+msgid "slice step cannot be zero"
+msgstr ""
+
+#: py/objslice.c:159
+msgid "Cannot subclass slice"
+msgstr ""
+
+#: py/objstr.c:261
+msgid "bytes value out of range"
+msgstr ""
+
+#: py/objstr.c:270
+msgid "wrong number of arguments"
+msgstr ""
+
+#: py/objstr.c:467
+msgid "join expects a list of str/bytes objects consistent with self object"
+msgstr ""
+
+#: py/objstr.c:542 py/objstr.c:647 py/objstr.c:1744
+msgid "empty separator"
+msgstr ""
+
+#: py/objstr.c:641
+msgid "rsplit(None,n)"
+msgstr ""
+
+#: py/objstr.c:713
+msgid "substring not found"
+msgstr ""
+
+#: py/objstr.c:770
+msgid "start/end indices"
+msgstr ""
+
+#: py/objstr.c:931
+msgid "bad format string"
+msgstr ""
+
+#: py/objstr.c:953
+msgid "single '}' encountered in format string"
+msgstr ""
+
+#: py/objstr.c:992
+msgid "bad conversion specifier"
+msgstr ""
+
+#: py/objstr.c:996
+msgid "end of format while looking for conversion specifier"
+msgstr ""
+
+#: py/objstr.c:998
+#, c-format
+msgid "unknown conversion specifier %c"
+msgstr ""
+
+#: py/objstr.c:1029
+msgid "unmatched '{' in format"
+msgstr ""
+
+#: py/objstr.c:1036
+msgid "expected ':' after format specifier"
+msgstr ""
+
+#: py/objstr.c:1050
+msgid ""
+"can't switch from automatic field numbering to manual field specification"
+msgstr ""
+
+#: py/objstr.c:1055 py/objstr.c:1083
+msgid "tuple index out of range"
+msgstr ""
+
+#: py/objstr.c:1071
+msgid "attributes not supported yet"
+msgstr "atributos ainda não suportados"
+
+#: py/objstr.c:1079
+msgid ""
+"can't switch from manual field specification to automatic field numbering"
+msgstr ""
+
+#: py/objstr.c:1171
+msgid "invalid format specifier"
+msgstr ""
+
+#: py/objstr.c:1192
+msgid "sign not allowed in string format specifier"
+msgstr ""
+
+#: py/objstr.c:1200
+msgid "sign not allowed with integer format specifier 'c'"
+msgstr ""
+
+#: py/objstr.c:1259
+#, c-format
+msgid "unknown format code '%c' for object of type '%s'"
+msgstr ""
+
+#: py/objstr.c:1331
+#, c-format
+msgid "unknown format code '%c' for object of type 'float'"
+msgstr ""
+
+#: py/objstr.c:1343
+msgid "'=' alignment not allowed in string format specifier"
+msgstr ""
+
+#: py/objstr.c:1367
+#, c-format
+msgid "unknown format code '%c' for object of type 'str'"
+msgstr ""
+
+#: py/objstr.c:1415
+msgid "format requires a dict"
+msgstr ""
+
+#: py/objstr.c:1424
+msgid "incomplete format key"
+msgstr ""
+
+#: py/objstr.c:1482
+msgid "incomplete format"
+msgstr "formato incompleto"
+
+#: py/objstr.c:1490
+msgid "not enough arguments for format string"
+msgstr ""
+
+#: py/objstr.c:1500
+#, c-format
+msgid "%%c requires int or char"
+msgstr "%%c requer int ou char"
+
+#: py/objstr.c:1507
+msgid "integer required"
+msgstr "inteiro requerido"
+
+#: py/objstr.c:1570
+#, c-format
+msgid "unsupported format character '%c' (0x%x) at index %d"
+msgstr ""
+
+#: py/objstr.c:1577
+msgid "not all arguments converted during string formatting"
+msgstr ""
+
+#: py/objstr.c:2102
+msgid "can't convert to str implicitly"
+msgstr ""
+
+#: py/objstr.c:2106
+msgid "can't convert '%q' object to %q implicitly"
+msgstr ""
+
+#: py/objstrunicode.c:134
+#, c-format
+msgid "string indices must be integers, not %s"
+msgstr ""
+
+#: py/objstrunicode.c:145 py/objstrunicode.c:164
+msgid "string index out of range"
+msgstr ""
+
+#: py/objtype.c:358
+msgid "__init__() should return None"
+msgstr ""
+
+#: py/objtype.c:360
+#, c-format
+msgid "__init__() should return None, not '%s'"
+msgstr ""
+
+#: py/objtype.c:623 py/objtype.c:1275 py/runtime.c:1065
+msgid "unreadable attribute"
+msgstr "atributo ilegível"
+
+#: py/objtype.c:868 py/runtime.c:653
+msgid "object not callable"
+msgstr ""
+
+#: py/objtype.c:870 py/runtime.c:655
+#, c-format
+msgid "'%s' object is not callable"
+msgstr ""
+
+#: py/objtype.c:978
+msgid "type takes 1 or 3 arguments"
+msgstr ""
+
+#: py/objtype.c:989
+msgid "cannot create instance"
+msgstr "não é possível criar instância"
+
+#: py/objtype.c:991
+msgid "cannot create '%q' instances"
+msgstr ""
+
+#: py/objtype.c:1047
+msgid "can't add special method to already-subclassed class"
+msgstr ""
+
+#: py/objtype.c:1091 py/objtype.c:1097
+msgid "type is not an acceptable base type"
+msgstr ""
+
+#: py/objtype.c:1100
+msgid "type '%q' is not an acceptable base type"
+msgstr ""
+
+#: py/objtype.c:1137
+msgid "multiple inheritance not supported"
+msgstr ""
+
+#: py/objtype.c:1164
+msgid "multiple bases have instance lay-out conflict"
+msgstr ""
+
+#: py/objtype.c:1205
+msgid "first argument to super() must be type"
+msgstr ""
+
+#: py/objtype.c:1370
+msgid "issubclass() arg 2 must be a class or a tuple of classes"
+msgstr ""
+
+#: py/objtype.c:1384
+msgid "issubclass() arg 1 must be a class"
+msgstr ""
+
+#: py/parse.c:726
+msgid "constant must be an integer"
+msgstr "constante deve ser um inteiro"
+
+#: py/parse.c:868
+msgid "Unable to init parser"
+msgstr ""
+
+#: py/parse.c:1170
+msgid "unexpected indent"
+msgstr ""
+
+#: py/parse.c:1173
+msgid "unindent does not match any outer indentation level"
+msgstr ""
+
+#: py/parsenum.c:60
+msgid "int() arg 2 must be >= 2 and <= 36"
+msgstr ""
+
+#: py/parsenum.c:151
+msgid "invalid syntax for integer"
+msgstr ""
+
+#: py/parsenum.c:155
+#, c-format
+msgid "invalid syntax for integer with base %d"
+msgstr ""
+
+#: py/parsenum.c:339
+msgid "invalid syntax for number"
+msgstr ""
+
+#: py/parsenum.c:342
+msgid "decimal numbers not supported"
+msgstr ""
+
+#: py/persistentcode.c:223
+msgid ""
+"Incompatible .mpy file. Please update all .mpy files. See http://adafru.it/"
+"mpy-update for more info."
+msgstr ""
+
+#: py/persistentcode.c:326
+msgid "can only save bytecode"
+msgstr ""
+
+#: py/runtime.c:206
+msgid "name not defined"
+msgstr "nome não definido"
+
+#: py/runtime.c:209
+msgid "name '%q' is not defined"
+msgstr ""
+
+#: py/runtime.c:304 py/runtime.c:611
+msgid "unsupported type for operator"
+msgstr ""
+
+#: py/runtime.c:307
+msgid "unsupported type for %q: '%s'"
+msgstr ""
+
+#: py/runtime.c:614
+msgid "unsupported types for %q: '%s', '%s'"
+msgstr ""
+
+#: py/runtime.c:881 py/runtime.c:888 py/runtime.c:945
+msgid "wrong number of values to unpack"
+msgstr ""
+
+#: py/runtime.c:883 py/runtime.c:947
+#, c-format
+msgid "need more than %d values to unpack"
+msgstr "precisa de mais de %d valores para desempacotar"
+
+#: py/runtime.c:890
+#, c-format
+msgid "too many values to unpack (expected %d)"
+msgstr ""
+
+#: py/runtime.c:984
+msgid "argument has wrong type"
+msgstr "argumento tem tipo errado"
+
+#: py/runtime.c:986
+msgid "argument should be a '%q' not a '%q'"
+msgstr ""
+
+#: py/runtime.c:1123 py/runtime.c:1197
+msgid "no such attribute"
+msgstr ""
+
+#: py/runtime.c:1128
+msgid "type object '%q' has no attribute '%q'"
+msgstr ""
+
+#: py/runtime.c:1132 py/runtime.c:1200
+msgid "'%s' object has no attribute '%q'"
+msgstr ""
+
+#: py/runtime.c:1238
+msgid "object not iterable"
+msgstr "objeto não iterável"
+
+#: py/runtime.c:1241
+#, c-format
+msgid "'%s' object is not iterable"
+msgstr ""
+
+#: py/runtime.c:1260 py/runtime.c:1296
+msgid "object not an iterator"
+msgstr ""
+
+#: py/runtime.c:1262 py/runtime.c:1298
+#, c-format
+msgid "'%s' object is not an iterator"
+msgstr ""
+
+#: py/runtime.c:1401
+msgid "exceptions must derive from BaseException"
+msgstr ""
+
+#: py/runtime.c:1430
+msgid "cannot import name %q"
+msgstr "não pode importar nome %q"
+
+#: py/runtime.c:1535
+msgid "memory allocation failed, heap is locked"
+msgstr ""
+
+#: py/runtime.c:1539
+#, c-format
+msgid "memory allocation failed, allocating %u bytes"
+msgstr ""
+
+#: py/runtime.c:1609
+msgid "maximum recursion depth exceeded"
+msgstr ""
+
+#: py/sequence.c:264
+msgid "object not in sequence"
+msgstr "objeto não em seqüência"
+
+#: py/stream.c:96
+msgid "stream operation not supported"
+msgstr ""
+
+#: py/vm.c:255
+msgid "local variable referenced before assignment"
+msgstr ""
+
+#: py/vm.c:1142
+msgid "no active exception to reraise"
+msgstr ""
+
+#: py/vm.c:1284
+msgid "byte code not implemented"
+msgstr ""
+
+#: shared-bindings/_stage/Layer.c:71
+msgid "graphic must be 2048 bytes long"
+msgstr ""
+
+#: shared-bindings/_stage/Layer.c:77 shared-bindings/_stage/Text.c:75
+msgid "palette must be 32 bytes long"
+msgstr ""
+
+#: shared-bindings/_stage/Layer.c:84
+msgid "map buffer too small"
+msgstr ""
+
+#: shared-bindings/_stage/Text.c:69
+msgid "font must be 2048 bytes long"
+msgstr ""
+
+#: shared-bindings/_stage/Text.c:81
+msgid "chars buffer too small"
+msgstr ""
+
+#: shared-bindings/analogio/AnalogOut.c:118
+msgid "AnalogOut is only 16 bits. Value must be less than 65536."
+msgstr ""
+
+#: shared-bindings/audiobusio/I2SOut.c:225
+#: shared-bindings/audioio/AudioOut.c:223
+msgid "Not playing"
+msgstr ""
+
+#: shared-bindings/audiobusio/PDMIn.c:124
+msgid "Bit depth must be multiple of 8."
+msgstr ""
+
+#: shared-bindings/audiobusio/PDMIn.c:128
+msgid "Oversample must be multiple of 8."
+msgstr ""
+
+#: shared-bindings/audiobusio/PDMIn.c:136
+msgid "Microphone startup delay must be in range 0.0 to 1.0"
+msgstr ""
+
+#: shared-bindings/audiobusio/PDMIn.c:193
+msgid "destination_length must be an int >= 0"
+msgstr "destination_length deve ser um int >= 0"
+
+#: shared-bindings/audiobusio/PDMIn.c:199
+msgid "Cannot record to a file"
+msgstr "Não é possível gravar em um arquivo"
+
+#: shared-bindings/audiobusio/PDMIn.c:202
+msgid "Destination capacity is smaller than destination_length."
+msgstr ""
+
+#: shared-bindings/audiobusio/PDMIn.c:206
+msgid "destination buffer must be an array of type 'H' for bit_depth = 16"
+msgstr ""
+
+#: shared-bindings/audiobusio/PDMIn.c:208
+msgid ""
+"destination buffer must be a bytearray or array of type 'B' for bit_depth = 8"
+msgstr ""
+
+#: shared-bindings/audioio/Mixer.c:94
+#, fuzzy
+msgid "Invalid voice count"
+msgstr "certificado inválido"
+
+#: shared-bindings/audioio/Mixer.c:99
+#, fuzzy
+msgid "Invalid channel count"
+msgstr "certificado inválido"
+
+#: shared-bindings/audioio/Mixer.c:103
+msgid "Sample rate must be positive"
+msgstr ""
+
+#: shared-bindings/audioio/Mixer.c:107
+#, fuzzy
+msgid "bits_per_sample must be 8 or 16"
+msgstr "bits devem ser 8"
+
+#: shared-bindings/audioio/RawSample.c:98
+msgid ""
+"sample_source buffer must be a bytearray or array of type 'h', 'H', 'b' or "
+"'B'"
+msgstr ""
+
+#: shared-bindings/audioio/RawSample.c:104
+msgid "buffer must be a bytes-like object"
+msgstr ""
+
+#: shared-bindings/audioio/WaveFile.c:78
+#: shared-bindings/displayio/OnDiskBitmap.c:85
+msgid "file must be a file opened in byte mode"
+msgstr ""
+
+#: shared-bindings/bitbangio/I2C.c:111 shared-bindings/bitbangio/SPI.c:121
+#: shared-bindings/busio/SPI.c:133
+msgid "Function requires lock"
+msgstr ""
+
+#: shared-bindings/bitbangio/I2C.c:195 shared-bindings/busio/I2C.c:210
+msgid "Buffer must be at least length 1"
+msgstr ""
+
+#: shared-bindings/bitbangio/SPI.c:151 shared-bindings/busio/SPI.c:175
+msgid "Invalid polarity"
+msgstr ""
+
+#: shared-bindings/bitbangio/SPI.c:155 shared-bindings/busio/SPI.c:179
+msgid "Invalid phase"
+msgstr "Fase Inválida"
+
+#: shared-bindings/bitbangio/SPI.c:159 shared-bindings/busio/SPI.c:183
+msgid "Invalid number of bits"
+msgstr "Número inválido de bits"
+
+#: shared-bindings/bitbangio/SPI.c:284 shared-bindings/busio/SPI.c:348
+msgid "buffer slices must be of equal length"
+msgstr ""
+
+#: shared-bindings/busio/I2C.c:120
+msgid "Function requires lock."
+msgstr ""
+
+#: shared-bindings/busio/UART.c:102
+msgid "bits must be 7, 8 or 9"
+msgstr ""
+
+#: shared-bindings/busio/UART.c:114
+msgid "stop must be 1 or 2"
+msgstr ""
+
+#: shared-bindings/digitalio/DigitalInOut.c:211
+msgid "Invalid direction."
+msgstr "Direção inválida"
+
+#: shared-bindings/digitalio/DigitalInOut.c:240
+msgid "Cannot set value when direction is input."
+msgstr ""
+
+#: shared-bindings/digitalio/DigitalInOut.c:266
+#: shared-bindings/digitalio/DigitalInOut.c:281
+msgid "Drive mode not used when direction is input."
+msgstr ""
+
+#: shared-bindings/digitalio/DigitalInOut.c:314
+#: shared-bindings/digitalio/DigitalInOut.c:331
+msgid "Pull not used when direction is output."
+msgstr ""
+
+#: shared-bindings/digitalio/DigitalInOut.c:340
+msgid "Unsupported pull value."
+msgstr ""
+
+#: shared-bindings/displayio/Bitmap.c:84
+msgid "y should be an int"
+msgstr "y deve ser um int"
+
+#: shared-bindings/displayio/Bitmap.c:89
+msgid "row buffer must be a bytearray or array of type 'b' or 'B'"
+msgstr ""
+
+#: shared-bindings/displayio/Bitmap.c:94
+msgid "row data must be a buffer"
+msgstr ""
+
+#: shared-bindings/displayio/ColorConverter.c:72
+msgid "color should be an int"
+msgstr "cor deve ser um int"
+
+#: shared-bindings/displayio/FourWire.c:55
+#: shared-bindings/displayio/FourWire.c:64
+msgid "displayio is a work in progress"
+msgstr ""
+
+#: shared-bindings/displayio/Group.c:65
+msgid "Group must have size at least 1"
+msgstr "Grupo deve ter tamanho pelo menos 1"
+
+#: shared-bindings/displayio/Palette.c:96
+msgid "color buffer must be a bytearray or array of type 'b' or 'B'"
+msgstr ""
+
+#: shared-bindings/displayio/Palette.c:102
+msgid "color buffer must be 3 bytes (RGB) or 4 bytes (RGB + pad byte)"
+msgstr ""
+
+#: shared-bindings/displayio/Palette.c:106
+msgid "color must be between 0x000000 and 0xffffff"
+msgstr "cor deve estar entre 0x000000 e 0xffffff"
+
+#: shared-bindings/displayio/Palette.c:110
+msgid "color buffer must be a buffer or int"
+msgstr ""
+
+#: shared-bindings/displayio/Palette.c:123
+#: shared-bindings/displayio/Palette.c:137
+msgid "palette_index should be an int"
+msgstr ""
+
+#: shared-bindings/displayio/Sprite.c:48
+msgid "position must be 2-tuple"
+msgstr ""
+
+#: shared-bindings/displayio/Sprite.c:97
+msgid "unsupported bitmap type"
+msgstr ""
+
+#: shared-bindings/displayio/Sprite.c:162
+msgid "pixel_shader must be displayio.Palette or displayio.ColorConverter"
+msgstr ""
+
+#: shared-bindings/gamepad/GamePad.c:100
+msgid "too many arguments"
+msgstr "muitos argumentos"
+
+#: shared-bindings/gamepad/GamePad.c:104
+msgid "expected a DigitalInOut"
+msgstr ""
+
+#: shared-bindings/i2cslave/I2CSlave.c:98
+msgid "can't convert address to int"
+msgstr ""
+
+#: shared-bindings/i2cslave/I2CSlave.c:101
+msgid "address out of bounds"
+msgstr ""
+
+#: shared-bindings/i2cslave/I2CSlave.c:107
+msgid "addresses is empty"
+msgstr ""
+
+#: shared-bindings/microcontroller/Pin.c:89
+#: shared-bindings/neopixel_write/__init__.c:67
+#: shared-bindings/pulseio/PulseOut.c:75
+msgid "Expected a %q"
+msgstr "Esperado um"
+
+#: shared-bindings/microcontroller/Pin.c:100
+msgid "%q in use"
+msgstr "%q em uso"
+
+#: shared-bindings/microcontroller/__init__.c:126
+msgid "Invalid run mode."
+msgstr ""
+
+#: shared-bindings/multiterminal/__init__.c:68
+msgid "Stream missing readinto() or write() method."
+msgstr ""
+
+#: shared-bindings/nvm/ByteArray.c:99
+msgid "Slice and value different lengths."
+msgstr ""
+
+#: shared-bindings/nvm/ByteArray.c:104
+msgid "Array values should be single bytes."
+msgstr ""
+
+#: shared-bindings/nvm/ByteArray.c:111 shared-bindings/nvm/ByteArray.c:141
+msgid "Unable to write to nvm."
+msgstr "Não é possível gravar no nvm."
+
+#: shared-bindings/nvm/ByteArray.c:137
+msgid "Bytes must be between 0 and 255."
+msgstr "Os bytes devem estar entre 0 e 255."
+
+#: shared-bindings/os/__init__.c:200
+msgid "No hardware random available"
+msgstr ""
+
+#: shared-bindings/pulseio/PWMOut.c:164
+msgid ""
+"PWM duty_cycle must be between 0 and 65535 inclusive (16 bit resolution)"
+msgstr ""
+
+#: shared-bindings/pulseio/PWMOut.c:195
+msgid ""
+"PWM frequency not writable when variable_frequency is False on construction."
+msgstr ""
+
+#: shared-bindings/pulseio/PulseIn.c:275
+msgid "Cannot delete values"
+msgstr "Não é possível excluir valores"
+
+#: shared-bindings/pulseio/PulseIn.c:281
+msgid "Slices not supported"
+msgstr ""
+
+#: shared-bindings/pulseio/PulseIn.c:287
+msgid "index must be int"
+msgstr "index deve ser int"
+
+#: shared-bindings/pulseio/PulseIn.c:293
+msgid "Read-only"
+msgstr "Somente leitura"
+
+#: shared-bindings/pulseio/PulseOut.c:134
+msgid "Array must contain halfwords (type 'H')"
+msgstr "Array deve conter meias palavras (tipo 'H')"
+
+#: shared-bindings/random/__init__.c:92 shared-bindings/random/__init__.c:100
+msgid "stop not reachable from start"
+msgstr ""
+
+#: shared-bindings/random/__init__.c:111
+msgid "step must be non-zero"
+msgstr "o passo deve ser diferente de zero"
+
+#: shared-bindings/random/__init__.c:114
+msgid "invalid step"
+msgstr "passo inválido"
+
+#: shared-bindings/random/__init__.c:146
+msgid "empty sequence"
+msgstr "seqüência vazia"
+
+#: shared-bindings/rtc/RTC.c:40 shared-bindings/rtc/RTC.c:44
+#: shared-bindings/time/__init__.c:190
+msgid "RTC is not supported on this board"
+msgstr "O RTC não é suportado nesta placa"
+
+#: shared-bindings/rtc/RTC.c:52
+msgid "RTC calibration is not supported on this board"
+msgstr "A calibração RTC não é suportada nesta placa"
+
+#: shared-bindings/storage/__init__.c:77
+msgid "filesystem must provide mount method"
+msgstr "sistema de arquivos deve fornecer método de montagem"
+
+#: shared-bindings/supervisor/__init__.c:93
+msgid "Brightness must be between 0 and 255"
+msgstr "O brilho deve estar entre 0 e 255"
+
+#: shared-bindings/supervisor/__init__.c:119
+msgid "Stack size must be at least 256"
+msgstr "O tamanho da pilha deve ser pelo menos 256"
+
+#: shared-bindings/time/__init__.c:78
+msgid "sleep length must be non-negative"
+msgstr ""
+
+#: shared-bindings/time/__init__.c:88
+msgid "time.struct_time() takes exactly 1 argument"
+msgstr ""
+
+#: shared-bindings/time/__init__.c:91
+msgid "time.struct_time() takes a 9-sequence"
+msgstr ""
+
+#: shared-bindings/time/__init__.c:169 shared-bindings/time/__init__.c:250
+msgid "Tuple or struct_time argument required"
+msgstr "Tuple or struct_time argument required"
+
+#: shared-bindings/time/__init__.c:174 shared-bindings/time/__init__.c:255
+msgid "function takes exactly 9 arguments"
+msgstr "função leva exatamente 9 argumentos"
+
+#: shared-bindings/time/__init__.c:226 shared-bindings/time/__init__.c:259
+msgid "timestamp out of range for platform time_t"
+msgstr "timestamp fora do intervalo para a plataforma time_t"
+
+#: shared-bindings/touchio/TouchIn.c:173
+msgid "threshold must be in the range 0-65536"
+msgstr "Limite deve estar no alcance de 0-65536"
+
+#: shared-bindings/util.c:38
+msgid ""
+"Object has been deinitialized and can no longer be used. Create a new object."
+msgstr ""
+"Objeto foi desinicializado e não pode ser mais usaado. Crie um novo objeto."
+
+#: shared-module/audioio/Mixer.c:47 shared-module/audioio/WaveFile.c:117
+msgid "Couldn't allocate first buffer"
+msgstr "Não pôde alocar primeiro buffer"
+
+#: shared-module/audioio/Mixer.c:53 shared-module/audioio/WaveFile.c:123
+msgid "Couldn't allocate second buffer"
+msgstr "Não pôde alocar segundo buffer"
+
+#: shared-module/audioio/Mixer.c:82
+msgid "Voice index too high"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:85
+msgid "The sample's sample rate does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:88
+msgid "The sample's channel count does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:91
+msgid "The sample's bits_per_sample does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/Mixer.c:100
+msgid "The sample's signedness does not match the mixer's"
+msgstr ""
+
+#: shared-module/audioio/WaveFile.c:61
+msgid "Invalid wave file"
+msgstr "Aqruivo de ondas inválido"
+
+#: shared-module/audioio/WaveFile.c:69
+msgid "Invalid format chunk size"
+msgstr "Tamanho do pedaço de formato inválido"
+
+#: shared-module/audioio/WaveFile.c:83
+msgid "Unsupported format"
+msgstr "Formato não suportado"
+
+#: shared-module/audioio/WaveFile.c:99
+msgid "Data chunk must follow fmt chunk"
+msgstr "Pedaço de dados deve seguir o pedaço de cortes"
+
+#: shared-module/audioio/WaveFile.c:107
+msgid "Invalid file"
+msgstr "Arquivo inválido"
+
+#: shared-module/bitbangio/I2C.c:58
+msgid "Clock stretch too long"
+msgstr "Clock se estendeu por tempo demais"
+
+#: shared-module/bitbangio/SPI.c:45
+msgid "Clock pin init failed."
+msgstr "Inicialização do pino de Clock falhou."
+
+#: shared-module/bitbangio/SPI.c:51
+msgid "MOSI pin init failed."
+msgstr "Inicialização do pino MOSI falhou."
+
+#: shared-module/bitbangio/SPI.c:62
+msgid "MISO pin init failed."
+msgstr "Inicialização do pino MISO falhou"
+
+#: shared-module/bitbangio/SPI.c:122
+msgid "Cannot write without MOSI pin."
+msgstr "Não é possível ler sem um pino MOSI"
+
+#: shared-module/bitbangio/SPI.c:177
+msgid "Cannot read without MISO pin."
+msgstr "Não é possível ler sem o pino MISO."
+
+#: shared-module/bitbangio/SPI.c:241
+msgid "Cannot transfer without MOSI and MISO pins."
+msgstr "Não é possível transferir sem os pinos MOSI e MISO."
+
+#: shared-module/displayio/Bitmap.c:49
+msgid "Only bit maps of 8 bit color or less are supported"
+msgstr "Apenas bit maps de cores de 8 bit ou menos são suportados"
+
+#: shared-module/displayio/Bitmap.c:69
+msgid "row must be packed and word aligned"
+msgstr "Linha deve ser comprimida e com as palavras alinhadas"
+
+#: shared-module/displayio/Group.c:39
+msgid "Group full"
+msgstr "Grupo cheio"
+
+#: shared-module/displayio/Group.c:48
+msgid "Group empty"
+msgstr "Grupo vazio"
+
+#: shared-module/displayio/OnDiskBitmap.c:49
+msgid "Invalid BMP file"
+msgstr "Arquivo BMP inválido"
+
+#: shared-module/displayio/OnDiskBitmap.c:59
+#, c-format
+msgid "Only Windows format, uncompressed BMP supported %d"
+msgstr "Apenas formato Windows, BMP descomprimido suportado"
+
+#: shared-module/displayio/OnDiskBitmap.c:64
+#, c-format
+msgid "Only true color (24 bpp or higher) BMP supported %x"
+msgstr "Apenas cores verdadeiras (24 bpp ou maior) BMP suportadas"
+
+#: shared-module/struct/__init__.c:39
+msgid "'S' and 'O' are not supported format types"
+msgstr "'S' e 'O' não são tipos de formato suportados"
+
+#: shared-module/struct/__init__.c:83
+msgid "too many arguments provided with the given format"
+msgstr "Muitos argumentos fornecidos com o formato dado"
+
+#~ msgid "Baud rate too high for this SPI peripheral"
+#~ msgstr "Taxa de transmissão muito alta para esse periférico SPI"
diff --git a/ports/atmel-samd/Makefile b/ports/atmel-samd/Makefile
index f8e5051c2..c8ade987d 100644
--- a/ports/atmel-samd/Makefile
+++ b/ports/atmel-samd/Makefile
@@ -407,6 +407,8 @@ ifneq ($(CHIP_VARIANT),SAMR21G18A)
audioio/__init__.c \
audioio/AudioOut.c
SRC_SHARED_MODULE += \
+ audioio/__init__.c \
+ audioio/Mixer.c \
audioio/RawSample.c \
audioio/WaveFile.c
endif
diff --git a/ports/atmel-samd/audio_dma.c b/ports/atmel-samd/audio_dma.c
index 45d698c17..68d6f182d 100644
--- a/ports/atmel-samd/audio_dma.c
+++ b/ports/atmel-samd/audio_dma.c
@@ -40,82 +40,6 @@ static audio_dma_t* audio_dma_state[AUDIO_DMA_CHANNEL_COUNT];
// This cannot be in audio_dma_state because it's volatile.
static volatile bool audio_dma_pending[AUDIO_DMA_CHANNEL_COUNT];
-uint32_t audiosample_sample_rate(mp_obj_t sample_obj) {
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
- audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
- return sample->sample_rate;
- }
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
- audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
- return file->sample_rate;
- }
- return 16000;
-}
-
-uint8_t audiosample_bits_per_sample(mp_obj_t sample_obj) {
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
- audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
- return sample->bits_per_sample;
- }
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
- audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
- return file->bits_per_sample;
- }
- return 8;
-}
-
-uint8_t audiosample_channel_count(mp_obj_t sample_obj) {
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
- audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
- return sample->channel_count;
- }
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
- audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
- return file->channel_count;
- }
- return 1;
-}
-
-static void audiosample_reset_buffer(mp_obj_t sample_obj, bool single_channel, uint8_t audio_channel) {
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
- audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
- audioio_rawsample_reset_buffer(sample, single_channel, audio_channel);
- }
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
- audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
- audioio_wavefile_reset_buffer(file, single_channel, audio_channel);
- }
-}
-
-static audioio_get_buffer_result_t audiosample_get_buffer(mp_obj_t sample_obj,
- bool single_channel,
- uint8_t channel,
- uint8_t** buffer, uint32_t* buffer_length) {
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
- audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
- return audioio_rawsample_get_buffer(sample, single_channel, channel, buffer, buffer_length);
- }
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
- audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
- return audioio_wavefile_get_buffer(file, single_channel, channel, buffer, buffer_length);
- }
- return GET_BUFFER_DONE;
-}
-
-static void audiosample_get_buffer_structure(mp_obj_t sample_obj, bool single_channel,
- bool* single_buffer, bool* samples_signed,
- uint32_t* max_buffer_length, uint8_t* spacing) {
- if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
- audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
- audioio_rawsample_get_buffer_structure(sample, single_channel, single_buffer,
- samples_signed, max_buffer_length, spacing);
- } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
- audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
- audioio_wavefile_get_buffer_structure(file, single_channel, single_buffer, samples_signed,
- max_buffer_length, spacing);
- }
-}
-
uint8_t find_free_audio_dma_channel(void) {
uint8_t channel;
for (channel = 0; channel < AUDIO_DMA_CHANNEL_COUNT; channel++) {
diff --git a/ports/atmel-samd/boards/trellis_m4_express/mpconfigboard.h b/ports/atmel-samd/boards/trellis_m4_express/mpconfigboard.h
index 117a8ae8e..05f2be0bc 100644
--- a/ports/atmel-samd/boards/trellis_m4_express/mpconfigboard.h
+++ b/ports/atmel-samd/boards/trellis_m4_express/mpconfigboard.h
@@ -3,7 +3,7 @@
#define CIRCUITPY_MCU_FAMILY samd51
-// This is for Rev A
+// This is for Rev D
#define MICROPY_HW_APA102_MOSI (&pin_PA01)
#define MICROPY_HW_APA102_SCK (&pin_PA00)
diff --git a/ports/atmel-samd/boards/trellis_m4_express/pins.c b/ports/atmel-samd/boards/trellis_m4_express/pins.c
index 57abfeba4..44ffc6eaf 100644
--- a/ports/atmel-samd/boards/trellis_m4_express/pins.c
+++ b/ports/atmel-samd/boards/trellis_m4_express/pins.c
@@ -15,6 +15,9 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
{ MP_OBJ_NEW_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_PB08) },
{ MP_OBJ_NEW_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_PB09) },
+ { MP_OBJ_NEW_QSTR(MP_QSTR_ACCELEROMETER_SDA), MP_ROM_PTR(&pin_PA12) },
+ { MP_OBJ_NEW_QSTR(MP_QSTR_ACCELEROMETER_SCL), MP_ROM_PTR(&pin_PA13) },
+
// Key Grid columns
{ MP_OBJ_NEW_QSTR(MP_QSTR_COL0), MP_ROM_PTR(&pin_PA14) },
{ MP_OBJ_NEW_QSTR(MP_QSTR_COL1), MP_ROM_PTR(&pin_PA15) },
diff --git a/ports/atmel-samd/common-hal/supervisor/Runtime.c b/ports/atmel-samd/common-hal/supervisor/Runtime.c
index 8efe7cb78..2636fe646 100755
--- a/ports/atmel-samd/common-hal/supervisor/Runtime.c
+++ b/ports/atmel-samd/common-hal/supervisor/Runtime.c
@@ -32,3 +32,7 @@ bool common_hal_get_serial_connected(void) {
return (bool) usb_connected();
}
+bool common_hal_get_serial_bytes_available(void) {
+ return (bool) usb_bytes_available();
+}
+
diff --git a/ports/atmel-samd/external_flash/devices.h b/ports/atmel-samd/external_flash/devices.h
index ea1b24a32..974936419 100644
--- a/ports/atmel-samd/external_flash/devices.h
+++ b/ports/atmel-samd/external_flash/devices.h
@@ -266,5 +266,23 @@ typedef struct {
}
+// Settings for the Winbond W25Q128JV-SQ 8MiB SPI flash. Note that JV-IM has a different .memory_type (0x70)
+// Datasheet: https://www.winbond.com/resource-files/w25q128jv%20revf%2003272018%20plus.pdf
+#define W25Q128JV_SQ {\
+ .total_size = (1 << 23), /* 16 MiB */ \
+ .start_up_time_us = 5000, \
+ .manufacturer_id = 0xef, \
+ .memory_type = 0x40, \
+ .capacity = 0x18, \
+ .max_clock_speed_mhz = 133, \
+ .has_sector_protection = false, \
+ .supports_fast_read = true, \
+ .supports_qspi = true, \
+ .has_quad_enable = true, \
+ .supports_qspi_writes = true, \
+ .write_status_register_split = false, \
+}
+
+
#endif // MICROPY_INCLUDED_ATMEL_SAMD_EXTERNAL_FLASH_DEVICES_H
diff --git a/ports/atmel-samd/mpconfigport.h b/ports/atmel-samd/mpconfigport.h
index 14f72ccfb..69a146c1f 100644
--- a/ports/atmel-samd/mpconfigport.h
+++ b/ports/atmel-samd/mpconfigport.h
@@ -207,7 +207,7 @@ extern const struct _mp_obj_module_t usb_hid_module;
#define MICROPY_PY_URE (1)
#define MICROPY_PY_MICROPYTHON_MEM_INFO (1)
#ifndef MICROPY_PY_FRAMEBUF
- #define MICROPY_PY_FRAMEBUF (1)
+ #define MICROPY_PY_FRAMEBUF (0)
#endif
#define MICROPY_BUILTIN_METHOD_CHECK_SELF_ARG (1)
diff --git a/ports/esp8266/README.md b/ports/esp8266/README.md
index f4dddd1ca..5f0ad8073 100644
--- a/ports/esp8266/README.md
+++ b/ports/esp8266/README.md
@@ -34,6 +34,14 @@ run `make` in its directory to build and install the SDK locally. Make sure
to add toolchain bin directory to your PATH. Read esp-open-sdk's README for
additional important information on toolchain setup.
+Travis builds, including releases are actually built using a specific
+esp-open-sdk binary. The location of the binary can be seen in the
+`.travis.yml` in the top-level directory of CircuitPython. This may be ahead
+of or behind the pfalcon repository, depending on the specific needs of
+CircuitPython. If your local system is binary-compatible with Travis
+(most Ubuntu and Debian based systems are), you can download the binary and
+skip building it locally.
+
Add the external dependencies to the MicroPython repository checkout:
```bash
$ git submodule update --init
diff --git a/ports/nrf/Makefile b/ports/nrf/Makefile
index 0e9d224be..93ca78376 100755
--- a/ports/nrf/Makefile
+++ b/ports/nrf/Makefile
@@ -91,7 +91,7 @@ SRC_NRFX = $(addprefix nrfx/,\
drivers/src/nrfx_power.c \
drivers/src/nrfx_spim.c \
drivers/src/nrfx_twim.c \
- drivers/src/nrfx_uart.c \
+ drivers/src/nrfx_uarte.c \
)
SRC_C += \
@@ -100,6 +100,7 @@ SRC_C += \
internal_flash.c \
mphalport.c \
tick.c \
+ board_busses.c \
boards/$(BOARD)/board.c \
boards/$(BOARD)/pins.c \
device/$(MCU_VARIANT)/startup_$(MCU_SUB_VARIANT).c \
diff --git a/ports/nrf/boards/feather_nrf52832/mpconfigboard.h b/ports/nrf/boards/feather_nrf52832/mpconfigboard.h
index 0da1abfc4..e751ec182 100644
--- a/ports/nrf/boards/feather_nrf52832/mpconfigboard.h
+++ b/ports/nrf/boards/feather_nrf52832/mpconfigboard.h
@@ -30,7 +30,6 @@
#define MICROPY_HW_UART_RX NRF_GPIO_PIN_MAP(0, 8)
#define MICROPY_HW_UART_TX NRF_GPIO_PIN_MAP(0, 6)
-#define MICROPY_HW_UART_HWFC (0)
#define PORT_HEAP_SIZE (32 * 1024)
#define CIRCUITPY_AUTORELOAD_DELAY_MS 500
diff --git a/ports/nrf/boards/feather_nrf52840_express/mpconfigboard.h b/ports/nrf/boards/feather_nrf52840_express/mpconfigboard.h
index 81818741d..bd6d4b244 100644
--- a/ports/nrf/boards/feather_nrf52840_express/mpconfigboard.h
+++ b/ports/nrf/boards/feather_nrf52840_express/mpconfigboard.h
@@ -67,5 +67,5 @@
#define DEFAULT_SPI_BUS_MOSI (&pin_P0_23)
#define DEFAULT_SPI_BUS_MISO (&pin_P0_22)
-#define DEFAULT_UART_BUS_RX (&pin_P1_0)
+#define DEFAULT_UART_BUS_RX (&pin_P1_00)
#define DEFAULT_UART_BUS_TX (&pin_P0_24)
diff --git a/ports/nrf/boards/pca10056/mpconfigboard.h b/ports/nrf/boards/pca10056/mpconfigboard.h
index de4545d62..00a73005c 100644
--- a/ports/nrf/boards/pca10056/mpconfigboard.h
+++ b/ports/nrf/boards/pca10056/mpconfigboard.h
@@ -28,17 +28,9 @@
#define MICROPY_HW_MCU_NAME "nRF52840"
#define MICROPY_PY_SYS_PLATFORM "nRF52840-DK"
-// See legend on bottom of board
-#define MICROPY_HW_UART_RX NRF_GPIO_PIN_MAP(0, 8)
-#define MICROPY_HW_UART_TX NRF_GPIO_PIN_MAP(0, 6)
-#define MICROPY_HW_UART_HWFC (0)
-
#define PORT_HEAP_SIZE (128 * 1024)
#define CIRCUITPY_AUTORELOAD_DELAY_MS 500
-// Temp (could be removed) 0: usb cdc (default), 1 : hwuart (jlink)
-#define CFG_HWUART_FOR_SERIAL 0
-
#define DEFAULT_I2C_BUS_SCL (&pin_P0_27)
#define DEFAULT_I2C_BUS_SDA (&pin_P0_26)
diff --git a/ports/nrf/boards/pca10056/pins.c b/ports/nrf/boards/pca10056/pins.c
index 1c208f89b..a57c9d1c9 100644
--- a/ports/nrf/boards/pca10056/pins.c
+++ b/ports/nrf/boards/pca10056/pins.c
@@ -124,6 +124,8 @@ STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
{ MP_ROM_QSTR(MP_QSTR_P1_15), MP_ROM_PTR(&pin_P1_15) },
{ MP_ROM_QSTR(MP_QSTR_D13), MP_ROM_PTR(&pin_P1_15) },
{ MP_ROM_QSTR(MP_QSTR_SCK), MP_ROM_PTR(&pin_P1_15) },
+
+ { MP_ROM_QSTR(MP_QSTR_UART), MP_ROM_PTR(&board_uart_obj) },
};
MP_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table);
diff --git a/ports/nrf/common-hal/busio/I2C.c b/ports/nrf/common-hal/busio/I2C.c
index ad789c8c1..c2a6cab70 100644
--- a/ports/nrf/common-hal/busio/I2C.c
+++ b/ports/nrf/common-hal/busio/I2C.c
@@ -54,7 +54,11 @@ STATIC twim_peripheral_t twim_peripherals[] = {
#endif
};
-#define INST_NO 0
+void i2c_reset(void) {
+ for (size_t i = 0 ; i < MP_ARRAY_SIZE(twim_peripherals); i++) {
+ twim_peripherals[i].in_use = false;
+ }
+}
static uint8_t twi_error_to_mp(const nrfx_err_t err) {
switch (err) {
diff --git a/ports/nrf/common-hal/busio/I2C.h b/ports/nrf/common-hal/busio/I2C.h
index 5606f46b0..c8ba84418 100644
--- a/ports/nrf/common-hal/busio/I2C.h
+++ b/ports/nrf/common-hal/busio/I2C.h
@@ -45,4 +45,6 @@ typedef struct {
uint8_t sda_pin_number;
} busio_i2c_obj_t;
+void i2c_reset(void);
+
#endif // MICROPY_INCLUDED_NRF_COMMON_HAL_BUSIO_I2C_H
diff --git a/ports/nrf/common-hal/busio/SPI.c b/ports/nrf/common-hal/busio/SPI.c
index 6e7f33dc7..f094b7f24 100644
--- a/ports/nrf/common-hal/busio/SPI.c
+++ b/ports/nrf/common-hal/busio/SPI.c
@@ -59,40 +59,46 @@ STATIC spim_peripheral_t spim_peripherals[] = {
#endif
};
-// Convert frequency to clock-speed-dependent value
-static nrf_spim_frequency_t baudrate_to_spim_frequency(const uint32_t baudrate) {
- if (baudrate <= 125000) {
- return NRF_SPIM_FREQ_125K;
- }
- if (baudrate <= 250000) {
- return NRF_SPIM_FREQ_250K;
- }
- if (baudrate <= 500000) {
- return NRF_SPIM_FREQ_500K;
- }
- if (baudrate <= 1000000) {
- return NRF_SPIM_FREQ_1M;
- }
- if (baudrate <= 2000000) {
- return NRF_SPIM_FREQ_2M;
- }
- if (baudrate <= 4000000) {
- return NRF_SPIM_FREQ_4M;
- }
- if (baudrate <= 8000000) {
- return NRF_SPIM_FREQ_8M;
- }
-#ifdef SPIM_FREQUENCY_FREQUENCY_M16
- if (baudrate <= 16000000) {
- return NRF_SPIM_FREQ_16M;
+void spi_reset(void) {
+ for (size_t i = 0 ; i < MP_ARRAY_SIZE(spim_peripherals); i++) {
+ nrf_spim_disable(spim_peripherals[i].spim.p_reg);
}
-#endif
+}
+
+// Convert frequency to clock-speed-dependent value. Choose the next lower baudrate if in between
+// available baudrates.
+static nrf_spim_frequency_t baudrate_to_spim_frequency(const uint32_t baudrate) {
+ static const struct {
+ const uint32_t boundary;
+ nrf_spim_frequency_t spim_frequency;
+ } baudrate_map[] = {
#ifdef SPIM_FREQUENCY_FREQUENCY_M32
- return NRF_SPIM_FREQ_32M;
-#else
- return NRF_SPIM_FREQ_8M;
+ { 32000000, NRF_SPIM_FREQ_32M },
#endif
+#ifdef SPIM_FREQUENCY_FREQUENCY_M16
+ { 16000000, NRF_SPIM_FREQ_16M },
+#endif
+ { 8000000, NRF_SPIM_FREQ_8M },
+ { 4000000, NRF_SPIM_FREQ_4M },
+ { 2000000, NRF_SPIM_FREQ_2M },
+ { 1000000, NRF_SPIM_FREQ_1M },
+ { 500000, NRF_SPIM_FREQ_500K },
+ { 250000, NRF_SPIM_FREQ_250K },
+ { 0, NRF_SPIM_FREQ_125K },
+ };
+
+ size_t i = 0;
+ uint32_t boundary;
+ do {
+ boundary = baudrate_map[i].boundary;
+ if (baudrate >= boundary) {
+ return baudrate_map[i].spim_frequency;
+ }
+ i++;
+ } while (boundary != 0);
+ // Should not get here.
+ return 0;
}
void common_hal_busio_spi_construct(busio_spi_obj_t *self, const mcu_pin_obj_t * clock, const mcu_pin_obj_t * mosi, const mcu_pin_obj_t * miso) {
@@ -162,26 +168,26 @@ void common_hal_busio_spi_deinit(busio_spi_obj_t *self) {
}
bool common_hal_busio_spi_configure(busio_spi_obj_t *self, uint32_t baudrate, uint8_t polarity, uint8_t phase, uint8_t bits) {
- // nrf52 does not support 16 bit
- if (bits != 8)
+ // nrf52 does not support 16 bit
+ if (bits != 8) {
return false;
+ }
- if (baudrate > self->spim_peripheral->max_frequency_MHz * 1000000) {
- mp_raise_ValueError(translate("Baud rate too high for this SPI peripheral"));
- return false;
- }
- nrf_spim_frequency_set(self->spim_peripheral->spim.p_reg, baudrate_to_spim_frequency(baudrate));
+ // Set desired frequency, rounding down, and don't go above available frequency for this SPIM.
+ nrf_spim_frequency_set(self->spim_peripheral->spim.p_reg,
+ baudrate_to_spim_frequency(MIN(baudrate,
+ self->spim_peripheral->max_frequency_MHz * 1000000)));
- nrf_spim_mode_t mode = NRF_SPIM_MODE_0;
- if (polarity) {
- mode = (phase) ? NRF_SPIM_MODE_3 : NRF_SPIM_MODE_2;
- } else {
- mode = (phase) ? NRF_SPIM_MODE_1 : NRF_SPIM_MODE_0;
- }
+ nrf_spim_mode_t mode = NRF_SPIM_MODE_0;
+ if (polarity) {
+ mode = (phase) ? NRF_SPIM_MODE_3 : NRF_SPIM_MODE_2;
+ } else {
+ mode = (phase) ? NRF_SPIM_MODE_1 : NRF_SPIM_MODE_0;
+ }
- nrf_spim_configure(self->spim_peripheral->spim.p_reg, mode, NRF_SPIM_BIT_ORDER_MSB_FIRST);
+ nrf_spim_configure(self->spim_peripheral->spim.p_reg, mode, NRF_SPIM_BIT_ORDER_MSB_FIRST);
- return true;
+ return true;
}
bool common_hal_busio_spi_try_lock(busio_spi_obj_t *self) {
diff --git a/ports/nrf/common-hal/busio/SPI.h b/ports/nrf/common-hal/busio/SPI.h
index c05fb1e18..1b0de8acf 100644
--- a/ports/nrf/common-hal/busio/SPI.h
+++ b/ports/nrf/common-hal/busio/SPI.h
@@ -45,4 +45,6 @@ typedef struct {
uint8_t MISO_pin_number;
} busio_spi_obj_t;
+void spi_reset(void);
+
#endif // MICROPY_INCLUDED_NRF_COMMON_HAL_BUSIO_SPI_H
diff --git a/ports/nrf/common-hal/busio/UART.c b/ports/nrf/common-hal/busio/UART.c
index 06a348b76..b2dbb56a1 100644
--- a/ports/nrf/common-hal/busio/UART.c
+++ b/ports/nrf/common-hal/busio/UART.c
@@ -35,58 +35,333 @@
#include "supervisor/shared/translate.h"
#include "tick.h"
+#include "nrfx_uarte.h"
+#include <string.h>
-void common_hal_busio_uart_construct(busio_uart_obj_t *self,
- const mcu_pin_obj_t * tx, const mcu_pin_obj_t * rx, uint32_t baudrate,
- uint8_t bits, uart_parity_t parity, uint8_t stop, uint32_t timeout,
- uint8_t receiver_buffer_size) {
- mp_raise_NotImplementedError(translate("busio.UART not yet implemented"));
+#ifdef NRF52840_XXAA
+
+// expression to examine, and return value in case of failing
+#define _VERIFY_ERR(_exp) \
+ do {\
+ uint32_t _err = (_exp);\
+ if (NRFX_SUCCESS != _err ) {\
+ mp_raise_msg_varg(&mp_type_RuntimeError, translate("error = 0x%08lX"), _err);\
+ }\
+ }while(0)
+
+static uint32_t get_nrf_baud (uint32_t baudrate);
+
+static void uart_callback_irq (const nrfx_uarte_event_t * event, void * context) {
+ busio_uart_obj_t* self = (busio_uart_obj_t*) context;
+
+ switch ( event->type ) {
+ case NRFX_UARTE_EVT_RX_DONE:
+ self->rx_count = event->data.rxtx.bytes;
+ break;
+
+ case NRFX_UARTE_EVT_TX_DONE:
+ break;
+
+ case NRFX_UARTE_EVT_ERROR:
+ if ( self->rx_count == -1 ) {
+ self->rx_count = 0;
+ }
+ break;
+
+ default:
+ break;
+ }
+}
+
+
+void common_hal_busio_uart_construct (busio_uart_obj_t *self,
+ const mcu_pin_obj_t * tx, const mcu_pin_obj_t * rx, uint32_t baudrate,
+ uint8_t bits, uart_parity_t parity, uint8_t stop, uint32_t timeout,
+ uint8_t receiver_buffer_size) {
+ if ( (tx == mp_const_none) && (rx == mp_const_none) ) {
+ mp_raise_ValueError(translate("tx and rx cannot both be None"));
+ }
+
+ if ( receiver_buffer_size == 0 ) {
+ mp_raise_ValueError(translate("Invalid buffer size"));
+ }
+
+ if ( parity == PARITY_ODD ) {
+ mp_raise_ValueError(translate("Odd parity is not supported"));
+ }
+
+ nrfx_uarte_config_t config = {
+ .pseltxd = (tx == mp_const_none) ? NRF_UARTE_PSEL_DISCONNECTED : tx->number,
+ .pselrxd = (rx == mp_const_none) ? NRF_UARTE_PSEL_DISCONNECTED : rx->number,
+ .pselcts = NRF_UARTE_PSEL_DISCONNECTED,
+ .pselrts = NRF_UARTE_PSEL_DISCONNECTED,
+ .p_context = self,
+ .hwfc = NRF_UARTE_HWFC_DISABLED,
+ .parity = (parity == PARITY_NONE) ? NRF_UARTE_PARITY_EXCLUDED : NRF_UARTE_PARITY_INCLUDED,
+ .baudrate = get_nrf_baud(baudrate),
+ .interrupt_priority = 7
+ };
+
+ // support only 1 instance for now
+ self->uarte = (nrfx_uarte_t ) NRFX_UARTE_INSTANCE(0);
+ nrfx_uarte_uninit(&self->uarte);
+ _VERIFY_ERR(nrfx_uarte_init(&self->uarte, &config, uart_callback_irq));
+
+ // Init buffer for rx
+ if ( rx != mp_const_none ) {
+ self->buffer = (uint8_t *) gc_alloc(receiver_buffer_size, false, false);
+ if ( !self->buffer ) {
+ nrfx_uarte_uninit(&self->uarte);
+ mp_raise_msg(&mp_type_MemoryError, translate("Failed to allocate RX buffer"));
+ }
+ self->bufsize = receiver_buffer_size;
+
+ claim_pin(rx);
+ }
+
+ if ( tx != mp_const_none ) {
+ claim_pin(tx);
+ }
+
+ self->baudrate = baudrate;
+ self->timeout_ms = timeout;
+
+ // queue 1-byte transfer for rx_characters_available()
+ self->rx_count = -1;
+ _VERIFY_ERR(nrfx_uarte_rx(&self->uarte, self->buffer, 1));
}
bool common_hal_busio_uart_deinited(busio_uart_obj_t *self) {
- mp_raise_NotImplementedError(translate("busio.UART not yet implemented"));
+ return (nrf_uarte_rx_pin_get(self->uarte.p_reg) == NRF_UARTE_PSEL_DISCONNECTED) &&
+ (nrf_uarte_tx_pin_get(self->uarte.p_reg) == NRF_UARTE_PSEL_DISCONNECTED);
}
void common_hal_busio_uart_deinit(busio_uart_obj_t *self) {
- mp_raise_NotImplementedError(translate("busio.UART not yet implemented"));
- if (common_hal_busio_uart_deinited(self)) {
- return;
+ if ( !common_hal_busio_uart_deinited(self) ) {
+ nrfx_uarte_uninit(&self->uarte);
+ gc_free(self->buffer);
}
- // Do deinit;
}
// Read characters.
size_t common_hal_busio_uart_read(busio_uart_obj_t *self, uint8_t *data, size_t len, int *errcode) {
- mp_raise_NotImplementedError(translate("busio.UART not yet implemented"));
- return 0;
+ if ( nrf_uarte_rx_pin_get(self->uarte.p_reg) == NRF_UARTE_PSEL_DISCONNECTED ) {
+ mp_raise_ValueError(translate("No RX pin"));
+ }
+
+ size_t remain = len;
+ uint64_t start_ticks = ticks_ms;
+
+ while ( 1 ) {
+ // Wait for on-going transfer to complete
+ while ( (self->rx_count == -1) && (ticks_ms - start_ticks < self->timeout_ms) ) {
+#ifdef MICROPY_VM_HOOK_LOOP
+ MICROPY_VM_HOOK_LOOP
+#endif
+ }
+
+ // copy received data
+ if ( self->rx_count > 0 ) {
+ memcpy(data, self->buffer, self->rx_count);
+ data += self->rx_count;
+ remain -= self->rx_count;
+
+ self->rx_count = 0;
+ }
+
+ // exit if complete or time up
+ if ( !remain || !(ticks_ms - start_ticks < self->timeout_ms) ) {
+ break;
+ }
+
+ // prepare next receiving
+ const size_t cnt = MIN(self->bufsize, remain);
+ self->rx_count = -1;
+ _VERIFY_ERR(nrfx_uarte_rx(&self->uarte, self->buffer, cnt));
+ }
+
+ // queue 1-byte transfer for rx_characters_available()
+ if ( self->rx_count == 0 ) {
+ self->rx_count = -1;
+ _VERIFY_ERR(nrfx_uarte_rx(&self->uarte, self->buffer, 1));
+ }
+
+ return len - remain;
}
// Write characters.
-size_t common_hal_busio_uart_write(busio_uart_obj_t *self, const uint8_t *data, size_t len, int *errcode) {
- mp_raise_NotImplementedError(translate("busio.UART not yet implemented"));
- return 0;
+size_t common_hal_busio_uart_write (busio_uart_obj_t *self, const uint8_t *data, size_t len, int *errcode) {
+ if ( nrf_uarte_tx_pin_get(self->uarte.p_reg) == NRF_UARTE_PSEL_DISCONNECTED ) {
+ mp_raise_ValueError(translate("No TX pin"));
+ }
+
+ if ( len == 0 ) return 0;
+
+ uint64_t start_ticks = ticks_ms;
+
+ // Wait for on-going transfer to complete
+ while ( nrfx_uarte_tx_in_progress(&self->uarte) && (ticks_ms - start_ticks < self->timeout_ms) ) {
+#ifdef MICROPY_VM_HOOK_LOOP
+ MICROPY_VM_HOOK_LOOP
+#endif
+ }
+
+ // Time up
+ if ( !(ticks_ms - start_ticks < self->timeout_ms) ) {
+ *errcode = MP_EAGAIN;
+ return MP_STREAM_ERROR;
+ }
+
+ // EasyDMA can only access SRAM
+ uint8_t * tx_buf = (uint8_t*) data;
+ if ( !nrfx_is_in_ram(data) ) {
+ tx_buf = (uint8_t *) gc_alloc(len, false, false);
+ memcpy(tx_buf, data, len);
+ }
+
+ (*errcode) = nrfx_uarte_tx(&self->uarte, tx_buf, len);
+ _VERIFY_ERR(*errcode);
+ (*errcode) = 0;
+
+ while ( nrfx_uarte_tx_in_progress(&self->uarte) && (ticks_ms - start_ticks < self->timeout_ms) ) {
+#ifdef MICROPY_VM_HOOK_LOOP
+ MICROPY_VM_HOOK_LOOP
+#endif
+ }
+
+ if ( !nrfx_is_in_ram(data) ) {
+ gc_free(tx_buf);
+ }
+
+ return len;
}
uint32_t common_hal_busio_uart_get_baudrate(busio_uart_obj_t *self) {
- mp_raise_NotImplementedError(translate("busio.UART not yet implemented"));
return self->baudrate;
}
void common_hal_busio_uart_set_baudrate(busio_uart_obj_t *self, uint32_t baudrate) {
- mp_raise_NotImplementedError(translate("busio.UART not yet implemented"));
self->baudrate = baudrate;
+ nrf_uarte_baudrate_set(self->uarte.p_reg, get_nrf_baud(baudrate));
}
uint32_t common_hal_busio_uart_rx_characters_available(busio_uart_obj_t *self) {
- mp_raise_NotImplementedError(translate("busio.UART not yet implemented"));
- return 0;
+ return (self->rx_count > 0) ? self->rx_count : 0;
}
void common_hal_busio_uart_clear_rx_buffer(busio_uart_obj_t *self) {
- mp_raise_NotImplementedError(translate("busio.UART not yet implemented"));
+ // Discard received byte, and queue 1-byte transfer for rx_characters_available()
+ if ( self->rx_count > 0 ) {
+ self->rx_count = -1;
+ _VERIFY_ERR(nrfx_uarte_rx(&self->uarte, self->buffer, 1));
+ }
}
bool common_hal_busio_uart_ready_to_tx(busio_uart_obj_t *self) {
- mp_raise_NotImplementedError(translate("busio.UART not yet implemented"));
+ return !nrfx_uarte_tx_in_progress(&self->uarte);
+}
+
+static uint32_t get_nrf_baud (uint32_t baudrate)
+{
+ if ( baudrate <= 1200 ) {
+ return NRF_UARTE_BAUDRATE_1200;
+ }
+ else if ( baudrate <= 2400 ) {
+ return NRF_UARTE_BAUDRATE_2400;
+ }
+ else if ( baudrate <= 4800 ) {
+ return NRF_UARTE_BAUDRATE_4800;
+ }
+ else if ( baudrate <= 9600 ) {
+ return NRF_UARTE_BAUDRATE_9600;
+ }
+ else if ( baudrate <= 14400 ) {
+ return NRF_UARTE_BAUDRATE_14400;
+ }
+ else if ( baudrate <= 19200 ) {
+ return NRF_UARTE_BAUDRATE_19200;
+ }
+ else if ( baudrate <= 28800 ) {
+ return NRF_UARTE_BAUDRATE_28800;
+ }
+ else if ( baudrate <= 38400 ) {
+ return NRF_UARTE_BAUDRATE_38400;
+ }
+ else if ( baudrate <= 57600 ) {
+ return NRF_UARTE_BAUDRATE_57600;
+ }
+ else if ( baudrate <= 76800 ) {
+ return NRF_UARTE_BAUDRATE_76800;
+ }
+ else if ( baudrate <= 115200 ) {
+ return NRF_UARTE_BAUDRATE_115200;
+ }
+ else if ( baudrate <= 230400 ) {
+ return NRF_UARTE_BAUDRATE_230400;
+ }
+ else if ( baudrate <= 250000 ) {
+ return NRF_UARTE_BAUDRATE_250000;
+ }
+ else if ( baudrate <= 460800 ) {
+ return NRF_UARTE_BAUDRATE_460800;
+ }
+ else if ( baudrate <= 921600 ) {
+ return NRF_UARTE_BAUDRATE_921600;
+ }
+ else {
+ return NRF_UARTE_BAUDRATE_1000000;
+ }
+}
+
+#else
+
+void common_hal_busio_uart_construct (busio_uart_obj_t *self,
+ const mcu_pin_obj_t * tx, const mcu_pin_obj_t * rx, uint32_t baudrate,
+ uint8_t bits, uart_parity_t parity, uint8_t stop, uint32_t timeout,
+ uint8_t receiver_buffer_size) {
+ mp_raise_NotImplementedError(translate("busio.UART not available"));
+}
+
+bool common_hal_busio_uart_deinited (busio_uart_obj_t *self) {
+ mp_raise_NotImplementedError(translate("busio.UART not available"));
+ return true;
+}
+
+void common_hal_busio_uart_deinit (busio_uart_obj_t *self) {
+ mp_raise_NotImplementedError(translate("busio.UART not available"));
+}
+
+// Read characters.
+size_t common_hal_busio_uart_read (busio_uart_obj_t *self, uint8_t *data, size_t len, int *errcode) {
+ mp_raise_NotImplementedError(translate("busio.UART not available"));
+ return 0;
+}
+
+// Write characters.
+size_t common_hal_busio_uart_write (busio_uart_obj_t *self, const uint8_t *data, size_t len, int *errcode) {
+ mp_raise_NotImplementedError(translate("busio.UART not available"));
+ return 0;
+}
+
+uint32_t common_hal_busio_uart_get_baudrate (busio_uart_obj_t *self) {
+ mp_raise_NotImplementedError(translate("busio.UART not available"));
+ return self->baudrate;
+}
+
+void common_hal_busio_uart_set_baudrate (busio_uart_obj_t *self, uint32_t baudrate) {
+ mp_raise_NotImplementedError(translate("busio.UART not available"));
+}
+
+uint32_t common_hal_busio_uart_rx_characters_available (busio_uart_obj_t *self) {
+ mp_raise_NotImplementedError(translate("busio.UART not available"));
+}
+
+void common_hal_busio_uart_clear_rx_buffer (busio_uart_obj_t *self) {
+
+}
+
+bool common_hal_busio_uart_ready_to_tx (busio_uart_obj_t *self) {
+ mp_raise_NotImplementedError(translate("busio.UART not available"));
return false;
}
+#endif
diff --git a/ports/nrf/common-hal/busio/UART.h b/ports/nrf/common-hal/busio/UART.h
index 7c0493e37..aef377f14 100644
--- a/ports/nrf/common-hal/busio/UART.h
+++ b/ports/nrf/common-hal/busio/UART.h
@@ -28,23 +28,22 @@
#define MICROPY_INCLUDED_NRF_COMMON_HAL_BUSIO_UART_H
#include "common-hal/microcontroller/Pin.h"
+#include "nrfx_uarte.h"
#include "py/obj.h"
+#include "py/ringbuf.h"
typedef struct {
mp_obj_base_t base;
- uint8_t rx_pin;
- uint8_t tx_pin;
- uint8_t character_bits;
- bool rx_error;
+
+ nrfx_uarte_t uarte;
+
uint32_t baudrate;
uint32_t timeout_ms;
- // Index of the oldest received character.
- uint32_t buffer_start;
- // Index of the next available spot to store a character.
- uint32_t buffer_size;
- uint32_t buffer_length;
+
uint8_t* buffer;
+ uint32_t bufsize;
+ volatile int32_t rx_count;
} busio_uart_obj_t;
#endif // MICROPY_INCLUDED_NRF_COMMON_HAL_BUSIO_UART_H
diff --git a/ports/nrf/common-hal/pulseio/PWMOut.c b/ports/nrf/common-hal/pulseio/PWMOut.c
index c3c51d566..5d94bab79 100644
--- a/ports/nrf/common-hal/pulseio/PWMOut.c
+++ b/ports/nrf/common-hal/pulseio/PWMOut.c
@@ -30,154 +30,159 @@
#include "py/runtime.h"
#include "common-hal/pulseio/PWMOut.h"
-#include "nrf_gpio.h"
#include "shared-bindings/pulseio/PWMOut.h"
#include "supervisor/shared/translate.h"
-#define PWM_MAX_MODULE 3
-#define PWM_MAX_CHANNEL 4
+#include "nrf_gpio.h"
#define PWM_MAX_FREQ (16000000)
-NRF_PWM_Type* const pwm_arr[PWM_MAX_MODULE] = { NRF_PWM0, NRF_PWM1, NRF_PWM2 };
-
-uint16_t _seq0[PWM_MAX_MODULE][PWM_MAX_CHANNEL];
-
-
-static int pin2channel(NRF_PWM_Type* pwm, uint8_t pin)
-{
- for(int i=0; i < PWM_MAX_CHANNEL; i++)
- {
- if ( pwm->PSEL.OUT[i] == ((uint32_t)pin) ) return i;
- }
-
- return -1;
-}
-
-static int find_free_channel(NRF_PWM_Type* pwm)
-{
- for(int i=0; i < PWM_MAX_CHANNEL; i++)
- {
- if (pwm->PSEL.OUT[i] == 0xFFFFFFFFUL)
- {
- return i;
+STATIC NRF_PWM_Type* pwms[] = {
+#if NRFX_CHECK(NRFX_PWM0_ENABLED)
+ NRF_PWM0,
+#endif
+#if NRFX_CHECK(NRFX_PWM1_ENABLED)
+ NRF_PWM1,
+#endif
+#if NRFX_CHECK(NRFX_PWM2_ENABLED)
+ NRF_PWM2,
+#endif
+#if NRFX_CHECK(NRFX_PWM3_ENABLED)
+ NRF_PWM3,
+#endif
+};
+
+#define CHANNELS_PER_PWM 4
+
+STATIC uint16_t pwm_seq[MP_ARRAY_SIZE(pwms)][CHANNELS_PER_PWM];
+
+void pwmout_reset(void) {
+ for(int i=0; i < MP_ARRAY_SIZE(pwms); i++) {
+ NRF_PWM_Type* pwm = pwms[i];
+
+ pwm->ENABLE = 0;
+ pwm->MODE = PWM_MODE_UPDOWN_Up;
+ pwm->DECODER = PWM_DECODER_LOAD_Individual;
+ pwm->LOOP = 0;
+ pwm->PRESCALER = PWM_PRESCALER_PRESCALER_DIV_1; // default is 500 hz
+ pwm->COUNTERTOP = (PWM_MAX_FREQ/500); // default is 500 hz
+
+ pwm->SEQ[0].PTR = (uint32_t) pwm_seq[i];
+ pwm->SEQ[0].CNT = CHANNELS_PER_PWM; // default mode is Individual --> count must be 4
+ pwm->SEQ[0].REFRESH = 0;
+ pwm->SEQ[0].ENDDELAY = 0;
+
+ pwm->SEQ[1].PTR = 0;
+ pwm->SEQ[1].CNT = 0;
+ pwm->SEQ[1].REFRESH = 0;
+ pwm->SEQ[1].ENDDELAY = 0;
+
+ for(int ch =0; ch < CHANNELS_PER_PWM; ch++) {
+ pwm_seq[i][ch] = (1 << 15); // polarity = 0
+ }
}
- }
-
- return -1;
}
-static bool pwm_is_unused(NRF_PWM_Type* pwm)
-{
- for(int i=0; i < PWM_MAX_CHANNEL; i++)
- {
- if (pwm->PSEL.OUT[i] != 0xFFFFFFFFUL)
- {
- return false;
+// Find the smallest prescaler value that will allow the divisor to be in range.
+// This allows the most accuracy.
+bool convert_frequency(uint32_t frequency, uint16_t *countertop, nrf_pwm_clk_t *base_clock) {
+ uint32_t divisor = 1;
+ // Use a 32-bit number so we don't overflow the uint16_t;
+ uint32_t tentative_countertop;
+ for (*base_clock = PWM_PRESCALER_PRESCALER_DIV_1;
+ *base_clock <= PWM_PRESCALER_PRESCALER_DIV_128;
+ (*base_clock)++) {
+ tentative_countertop = PWM_MAX_FREQ / divisor / frequency;
+ // COUNTERTOP must be 3..32767, according to datasheet, but 3 doesn't work. 4 does.
+ if (tentative_countertop <= 32767 && tentative_countertop >= 4) {
+ // In range, OK to return.
+ *countertop = tentative_countertop;
+ return true;
+ }
+ divisor *= 2;
}
- }
- return true;
+ return false;
}
-static void find_new_pwm(pulseio_pwmout_obj_t* self)
-{
- // First find unused PWM module
- for(int i=0; i<PWM_MAX_MODULE; i++)
- {
- if ( pwm_is_unused(pwm_arr[i]) )
- {
- self->pwm = pwm_arr[i];
- self->channel = 0;
- return;
- }
- }
-
- // Find available channel in a using PWM
- for(int i=0; i<PWM_MAX_MODULE; i++)
- {
- int ch = find_free_channel(pwm_arr[i]);
- if ( ch >= 0 )
- {
- self->pwm = pwm_arr[i];
- self->channel = (uint8_t) ch;
- return;
+void common_hal_pulseio_pwmout_construct(pulseio_pwmout_obj_t* self,
+ const mcu_pin_obj_t* pin,
+ uint16_t duty,
+ uint32_t frequency,
+ bool variable_frequency) {
+
+ // We don't use the nrfx driver here because we want to dynamically allocate channels
+ // as needed in an already-enabled PWM.
+
+ uint16_t countertop;
+ nrf_pwm_clk_t base_clock;
+ if (frequency == 0 || !convert_frequency(frequency, &countertop, &base_clock)) {
+ mp_raise_ValueError(translate("Invalid PWM frequency"));
}
- }
-}
-void pwmout_reset(void)
-{
- for(int i=0; i<PWM_MAX_MODULE; i++)
- {
- NRF_PWM_Type* pwm = pwm_arr[i];
-
- pwm->MODE = PWM_MODE_UPDOWN_Up;
- pwm->DECODER = PWM_DECODER_LOAD_Individual;
- pwm->LOOP = 0;
- pwm->PRESCALER = PWM_PRESCALER_PRESCALER_DIV_1; // default is 500 hz
- pwm->COUNTERTOP = (PWM_MAX_FREQ/500); // default is 500 hz
-
- pwm->SEQ[0].PTR = (uint32_t) _seq0[i];
- pwm->SEQ[0].CNT = PWM_MAX_CHANNEL; // default mode is Individual --> count must be 4
- pwm->SEQ[0].REFRESH = 0;
- pwm->SEQ[0].ENDDELAY = 0;
-
- pwm->SEQ[1].PTR = 0;
- pwm->SEQ[1].CNT = 0;
- pwm->SEQ[1].REFRESH = 0;
- pwm->SEQ[1].ENDDELAY = 0;
-
- for(int ch =0; ch < PWM_MAX_CHANNEL; ch++)
- {
- _seq0[i][ch] = (1UL << 15); // polarity = 0
+ self->pwm = NULL;
+ self->channel = CHANNELS_PER_PWM; // out-of-range value.
+ bool pwm_already_in_use;
+ NRF_PWM_Type* pwm;
+
+ for (size_t i = 0 ; i < MP_ARRAY_SIZE(pwms); i++) {
+ pwm = pwms[i];
+ pwm_already_in_use = pwm->ENABLE & SPIM_ENABLE_ENABLE_Msk;
+ if (pwm_already_in_use) {
+ if (variable_frequency) {
+ // Variable frequency requires exclusive use of a PWM, so try the next one.
+ continue;
+ }
+
+ // PWM is in use, but see if it's set to the same frequency we need. If so,
+ // look for a free channel.
+ if (pwm->COUNTERTOP == countertop && pwm->PRESCALER == base_clock) {
+ for (size_t chan = 0; chan < CHANNELS_PER_PWM; chan++) {
+ if (pwm->PSEL.OUT[chan] == 0xFFFFFFFF) {
+ // Channel is free.
+ self->pwm = pwm;
+ self->channel = chan;
+ break;
+ }
+ }
+ // Did we find a channel? If not, loop and check the next pwm.
+ if (self->pwm != NULL) {
+ break;
+ }
+ }
+ } else {
+ // PWM not yet in use, so we can start to use it. Use channel 0.
+ self->pwm = pwm;
+ self->channel = 0;
+ break;
+ }
}
- }
-}
-void common_hal_pulseio_pwmout_construct(pulseio_pwmout_obj_t* self,
- const mcu_pin_obj_t* pin,
- uint16_t duty,
- uint32_t frequency,
- bool variable_frequency) {
- self->pwm = NULL;
- self->pin = pin;
-
- // check if mapped to PWM channel already
- for(int i=0; i<PWM_MAX_MODULE; i++)
- {
- int ch = pin2channel(pwm_arr[i], pin->number);
- if ( ch >= 0 )
- {
- self->pwm = pwm_arr[i];
- self->channel = (uint8_t) ch;
- break;
+ if (self->pwm == NULL) {
+ mp_raise_ValueError(translate("All PWM peripherals are in use"));
}
- }
- // Haven't mapped before
- if ( !self->pwm )
- {
- find_new_pwm(self);
- }
+ self->pin_number = pin->number;
+ claim_pin(pin);
+
+ self->frequency = frequency;
+ self->variable_frequency = variable_frequency;
- if (self->pwm)
- {
- nrf_gpio_cfg_output(pin->number);
+ nrf_gpio_cfg_output(self->pin_number);
// disable before mapping pin channel
- self->pwm->ENABLE = 0;
+ nrf_pwm_disable(pwm);
- self->pwm->PSEL.OUT[self->channel] = pin->number;
+ if (!pwm_already_in_use) {
+ nrf_pwm_configure(pwm, base_clock, NRF_PWM_MODE_UP, countertop);
+ }
- self->pwm->COUNTERTOP = (PWM_MAX_FREQ/frequency);
- self->freq = frequency;
- self->variable_freq = variable_frequency;
+ // Connect channel to pin, without disturbing other channels.
+ pwm->PSEL.OUT[self->channel] = pin->number;
- self->pwm->ENABLE = 1;
+ nrf_pwm_enable(pwm);
common_hal_pulseio_pwmout_set_duty_cycle(self, duty);
- }
}
bool common_hal_pulseio_pwmout_deinited(pulseio_pwmout_obj_t* self) {
@@ -185,57 +190,60 @@ bool common_hal_pulseio_pwmout_deinited(pulseio_pwmout_obj_t* self) {
}
void common_hal_pulseio_pwmout_deinit(pulseio_pwmout_obj_t* self) {
- if (common_hal_pulseio_pwmout_deinited(self)) {
- return;
- }
+ if (common_hal_pulseio_pwmout_deinited(self)) {
+ return;
+ }
- self->pwm->ENABLE = 0;
+ nrf_gpio_cfg_default(self->pin_number);
- self->pwm->PSEL.OUT[self->channel] = 0xFFFFFFFFUL;
+ NRF_PWM_Type* pwm = self->pwm;
+ self->pwm = NULL;
- // re-enable PWM module if there is other active channel
- for(int i=0; i < PWM_MAX_CHANNEL; i++)
- {
- if (self->pwm->PSEL.OUT[i] != 0xFFFFFFFFUL)
- {
- self->pwm->ENABLE = 1;
- break;
- }
- }
+ // Disconnect pin from channel.
+ pwm->PSEL.OUT[self->channel] = 0xFFFFFFFF;
- nrf_gpio_cfg_default(self->pin->number);
+ for(int i=0; i < CHANNELS_PER_PWM; i++) {
+ if (self->pwm->PSEL.OUT[i] != 0xFFFFFFFF) {
+ // Some channel is still being used, so don't disable.
+ return;
+ }
+ }
- self->pwm = NULL;
- self->pin = mp_const_none;
+ nrf_pwm_disable(pwm);
}
-void common_hal_pulseio_pwmout_set_duty_cycle(pulseio_pwmout_obj_t* self, uint16_t duty) {
- self->duty = duty;
+void common_hal_pulseio_pwmout_set_duty_cycle(pulseio_pwmout_obj_t* self, uint16_t duty_cycle) {
+ self->duty_cycle = duty_cycle;
- uint16_t* p_value = ((uint16_t*)self->pwm->SEQ[0].PTR) + self->channel;
- *p_value = ((duty * self->pwm->COUNTERTOP) / 0xFFFF) | (1 << 15);
+ uint16_t* p_value = ((uint16_t*)self->pwm->SEQ[0].PTR) + self->channel;
+ *p_value = ((duty_cycle * self->pwm->COUNTERTOP) / 0xFFFF) | (1 << 15);
- self->pwm->TASKS_SEQSTART[0] = 1;
+ self->pwm->TASKS_SEQSTART[0] = 1;
}
uint16_t common_hal_pulseio_pwmout_get_duty_cycle(pulseio_pwmout_obj_t* self) {
- return self->duty;
+ return self->duty_cycle;
}
void common_hal_pulseio_pwmout_set_frequency(pulseio_pwmout_obj_t* self, uint32_t frequency) {
- if (frequency == 0 || frequency > 16000000) {
- mp_raise_ValueError(translate("Invalid PWM frequency"));
- }
+ // COUNTERTOP is 3..32767, so highest available frequency is PWM_MAX_FREQ / 3.
+ uint16_t countertop;
+ nrf_pwm_clk_t base_clock;
+ if (frequency == 0 || !convert_frequency(frequency, &countertop, &base_clock)) {
+ mp_raise_ValueError(translate("Invalid PWM frequency"));
+ }
+ self->frequency = frequency;
- self->freq = frequency;
- self->pwm->COUNTERTOP = (PWM_MAX_FREQ/frequency);
- self->pwm->TASKS_SEQSTART[0] = 1;
+ nrf_pwm_configure(self->pwm, base_clock, NRF_PWM_MODE_UP, countertop);
+ // Set the duty cycle again, because it depends on COUNTERTOP, which probably changed.
+ // Setting the duty cycle will also do a SEQSTART.
+ common_hal_pulseio_pwmout_set_duty_cycle(self, self->duty_cycle);
}
uint32_t common_hal_pulseio_pwmout_get_frequency(pulseio_pwmout_obj_t* self) {
- return self->freq;
+ return self->frequency;
}
bool common_hal_pulseio_pwmout_get_variable_frequency(pulseio_pwmout_obj_t* self) {
- return self->variable_freq;
+ return self->variable_frequency;
}
diff --git a/ports/nrf/common-hal/pulseio/PWMOut.h b/ports/nrf/common-hal/pulseio/PWMOut.h
index 9de127ac7..a4e58dc1a 100644
--- a/ports/nrf/common-hal/pulseio/PWMOut.h
+++ b/ports/nrf/common-hal/pulseio/PWMOut.h
@@ -27,19 +27,17 @@
#ifndef MICROPY_INCLUDED_NRF_COMMON_HAL_PULSEIO_PWMOUT_H
#define MICROPY_INCLUDED_NRF_COMMON_HAL_PULSEIO_PWMOUT_H
-#include "common-hal/microcontroller/Pin.h"
-
+#include "nrfx_pwm.h"
#include "py/obj.h"
typedef struct {
mp_obj_base_t base;
- const mcu_pin_obj_t *pin;
NRF_PWM_Type* pwm;
-
- uint8_t channel;
- bool variable_freq;
- uint16_t duty;
- uint32_t freq;
+ uint8_t pin_number;
+ uint8_t channel: 7;
+ bool variable_frequency: 1;
+ uint16_t duty_cycle;
+ uint32_t frequency;
} pulseio_pwmout_obj_t;
void pwmout_reset(void);
diff --git a/ports/nrf/common-hal/supervisor/Runtime.c b/ports/nrf/common-hal/supervisor/Runtime.c
index b73a94a1b..feab6987d 100755
--- a/ports/nrf/common-hal/supervisor/Runtime.c
+++ b/ports/nrf/common-hal/supervisor/Runtime.c
@@ -32,3 +32,7 @@ bool common_hal_get_serial_connected(void) {
return (bool) serial_connected();
}
+bool common_hal_get_serial_bytes_available(void) {
+ return (bool) serial_bytes_available();
+}
+
diff --git a/ports/nrf/drivers/bluetooth/ble_drv.c b/ports/nrf/drivers/bluetooth/ble_drv.c
index 7e95c2eab..3f21f8c49 100644
--- a/ports/nrf/drivers/bluetooth/ble_drv.c
+++ b/ports/nrf/drivers/bluetooth/ble_drv.c
@@ -467,7 +467,7 @@ bool ble_drv_advertise_data(ubluepy_advertise_data_t * p_adv_params) {
// do encoding into the adv buffer
if (sd_ble_uuid_encode(&uuid, &encoded_size, &adv_data[byte_pos]) != 0) {
nlr_raise(mp_obj_new_exception_msg_varg(&mp_type_OSError,
- translate("Can encode UUID into the advertisment packet.")));
+ translate("Can encode UUID into the advertisement packet.")));
}
BLE_DRIVER_LOG("encoded uuid for service %u: ", 0);
@@ -517,7 +517,7 @@ bool ble_drv_advertise_data(ubluepy_advertise_data_t * p_adv_params) {
// do encoding into the adv buffer
if (sd_ble_uuid_encode(&uuid, &encoded_size, &adv_data[byte_pos]) != 0) {
nlr_raise(mp_obj_new_exception_msg_varg(&mp_type_OSError,
- translate("Can encode UUID into the advertisment packet.")));
+ translate("Can encode UUID into the advertisement packet.")));
}
BLE_DRIVER_LOG("encoded uuid for service %u: ", 0);
@@ -542,7 +542,7 @@ bool ble_drv_advertise_data(ubluepy_advertise_data_t * p_adv_params) {
if ((p_adv_params->data_len > 0) && (p_adv_params->p_data != NULL)) {
if (p_adv_params->data_len + byte_pos > BLE_GAP_ADV_MAX_SIZE) {
nlr_raise(mp_obj_new_exception_msg_varg(&mp_type_OSError,
- translate("Can not fit data into the advertisment packet.")));
+ translate("Can not fit data into the advertisement packet.")));
}
memcpy(adv_data, p_adv_params->p_data, p_adv_params->data_len);
@@ -555,7 +555,7 @@ bool ble_drv_advertise_data(ubluepy_advertise_data_t * p_adv_params) {
if ((err_code = sd_ble_gap_adv_data_set(adv_data, byte_pos, NULL, 0)) != 0) {
nlr_raise(mp_obj_new_exception_msg_varg(&mp_type_OSError,
- translate("Can not apply advertisment data. status: 0x%02x"), (uint16_t)err_code));
+ translate("Can not apply advertisement data. status: 0x%02x"), (uint16_t)err_code));
}
BLE_DRIVER_LOG("Set Adv data size: " UINT_FMT "\n", byte_pos);
#endif
@@ -586,7 +586,7 @@ bool ble_drv_advertise_data(ubluepy_advertise_data_t * p_adv_params) {
m_adv_params.primary_phy = BLE_GAP_PHY_1MBPS;
#else
m_adv_params.fp = BLE_GAP_ADV_FP_ANY;
- m_adv_params.timeout = 0; // infinite advertisment
+ m_adv_params.timeout = 0; // infinite advertisement
#endif
ble_drv_advertise_stop();
@@ -601,7 +601,7 @@ bool ble_drv_advertise_data(ubluepy_advertise_data_t * p_adv_params) {
if ((err_code = sd_ble_gap_adv_set_configure(&m_adv_handle, &ble_gap_adv_data, &m_adv_params)) != 0) {
nlr_raise(mp_obj_new_exception_msg_varg(&mp_type_OSError,
- translate("Can not apply advertisment data. status: 0x%02x"), (uint16_t)err_code));
+ translate("Can not apply advertisement data. status: 0x%02x"), (uint16_t)err_code));
}
err_code = sd_ble_gap_adv_start(m_adv_handle, BLE_CONN_CFG_TAG_DEFAULT);
#elif (BLUETOOTH_SD == 132 && BLE_API_VERSION == 4)
@@ -611,7 +611,7 @@ bool ble_drv_advertise_data(ubluepy_advertise_data_t * p_adv_params) {
#endif
if (err_code != 0) {
nlr_raise(mp_obj_new_exception_msg_varg(&mp_type_OSError,
- translate("Can not start advertisment. status: 0x%02x"), (uint16_t)err_code));
+ translate("Can not start advertisement. status: 0x%02x"), (uint16_t)err_code));
}
m_adv_in_progress = true;
@@ -628,7 +628,7 @@ void ble_drv_advertise_stop(void) {
if ((err_code = sd_ble_gap_adv_stop()) != 0) {
#endif
nlr_raise(mp_obj_new_exception_msg_varg(&mp_type_OSError,
- translate("Can not stop advertisment. status: 0x%02x"), (uint16_t)err_code));
+ translate("Can not stop advertisement. status: 0x%02x"), (uint16_t)err_code));
}
}
m_adv_in_progress = false;
diff --git a/ports/nrf/examples/ubluepy_eddystone.py b/ports/nrf/examples/ubluepy_eddystone.py
index c8abd5aea..baf25ba4b 100644
--- a/ports/nrf/examples/ubluepy_eddystone.py
+++ b/ports/nrf/examples/ubluepy_eddystone.py
@@ -44,7 +44,7 @@ def generate_eddystone_adv_packet(url):
service_data = uuid + eddystone_data
packet_service_data = gen_ad_type_content(constants.ad_types.AD_TYPE_SERVICE_DATA, service_data)
- # generate advertisment packet
+ # generate advertisement packet
packet = bytearray([])
packet.extend(packet_flags)
packet.extend(packet_uuid16)
diff --git a/ports/nrf/examples/ubluepy_temp.py b/ports/nrf/examples/ubluepy_temp.py
index fac091bc1..e5c157dbb 100644
--- a/ports/nrf/examples/ubluepy_temp.py
+++ b/ports/nrf/examples/ubluepy_temp.py
@@ -41,7 +41,7 @@ def event_handler(id, handle, data):
rtc.stop()
# indicate 'disconnected'
LED(1).off()
- # restart advertisment
+ # restart advertisement
periph.advertise(device_name="micr_temp", services=[serv_env_sense])
elif id == constants.EVT_GATTS_WRITE:
diff --git a/ports/nrf/modules/ubluepy/ubluepy_peripheral.c b/ports/nrf/modules/ubluepy/ubluepy_peripheral.c
index 48e467374..7b6b315a9 100644
--- a/ports/nrf/modules/ubluepy/ubluepy_peripheral.c
+++ b/ports/nrf/modules/ubluepy/ubluepy_peripheral.c
@@ -166,7 +166,7 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_2(ubluepy_peripheral_set_conn_handler_obj, periph
#if MICROPY_PY_UBLUEPY_PERIPHERAL
/// \method advertise(device_name, [service=[service1, service2, ...]], [data=bytearray], [connectable=True])
-/// Start advertising. Connectable advertisment type by default.
+/// Start advertising. Connectable advertisement type by default.
///
STATIC mp_obj_t peripheral_advertise(mp_uint_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) {
static const mp_arg_t allowed_args[] = {
@@ -236,7 +236,7 @@ STATIC mp_obj_t peripheral_advertise(mp_uint_t n_args, const mp_obj_t *pos_args,
STATIC MP_DEFINE_CONST_FUN_OBJ_KW(ubluepy_peripheral_advertise_obj, 0, peripheral_advertise);
/// \method advertise_stop()
-/// Stop advertisment if any onging advertisment.
+/// Stop advertisement if any onging advertisement.
///
STATIC mp_obj_t peripheral_advertise_stop(mp_obj_t self_in) {
ubluepy_peripheral_obj_t *self = MP_OBJ_TO_PTR(self_in);
diff --git a/ports/nrf/mphalport.c b/ports/nrf/mphalport.c
index 1e1ebf32e..27ed57bf3 100644
--- a/ports/nrf/mphalport.c
+++ b/ports/nrf/mphalport.c
@@ -27,36 +27,40 @@
#include <string.h>
-#include "mphalport.h"
+#include "py/mphal.h"
#include "py/mpstate.h"
-
+#include "py/gc.h"
#if (MICROPY_PY_BLE_NUS == 0)
-#if !defined( NRF52840_XXAA) || ( defined(CFG_HWUART_FOR_SERIAL) && CFG_HWUART_FOR_SERIAL == 1 )
+#if !defined( NRF52840_XXAA)
int mp_hal_stdin_rx_chr(void) {
- uint8_t data = 0;
-
- while (!nrfx_uart_rx_ready(&serial_instance));
-
- const nrfx_err_t err = nrfx_uart_rx(&serial_instance, &data, sizeof(data));
- if (err == NRFX_SUCCESS)
- NRFX_ASSERT(err);
-
+ uint8_t data;
+ nrfx_uarte_rx(&serial_instance, &data, 1);
return data;
}
bool mp_hal_stdin_any(void) {
- return nrfx_uart_rx_ready(&serial_instance);
+ return nrf_uarte_event_check(serial_instance.p_reg, NRF_UARTE_EVENT_RXDRDY);
}
void mp_hal_stdout_tx_strn(const char *str, mp_uint_t len) {
- if (len == 0)
+ if (len == 0) {
return;
+ }
- const nrfx_err_t err = nrfx_uart_tx(&serial_instance, (uint8_t*)str, len);
- if (err == NRFX_SUCCESS)
- NRFX_ASSERT(err);
+ // EasyDMA can only access SRAM
+ uint8_t * tx_buf = (uint8_t*) str;
+ if ( !nrfx_is_in_ram(str) ) {
+ tx_buf = (uint8_t *) gc_alloc(len, false, false);
+ memcpy(tx_buf, str, len);
+ }
+
+ nrfx_uarte_tx(&serial_instance, tx_buf, len);
+
+ if ( !nrfx_is_in_ram(str) ) {
+ gc_free(tx_buf);
+ }
}
#else
diff --git a/ports/nrf/mphalport.h b/ports/nrf/mphalport.h
index f283cf38d..a1929a4ac 100644
--- a/ports/nrf/mphalport.h
+++ b/ports/nrf/mphalport.h
@@ -31,21 +31,16 @@
#include <stdint.h>
#include "lib/utils/interrupt_char.h"
-#include "nrfx_uart.h"
+#include "nrfx_uarte.h"
#include "py/mpconfig.h"
-extern nrfx_uart_t serial_instance;
+extern nrfx_uarte_t serial_instance;
extern volatile uint64_t ticks_ms;
-static inline mp_uint_t mp_hal_ticks_ms(void) {
- return ticks_ms;
-}
+#define mp_hal_ticks_ms() ((mp_uint_t) ticks_ms)
+#define mp_hal_delay_us(us) NRFX_DELAY_US((uint32_t) (us))
-int mp_hal_stdin_rx_chr(void);
-void mp_hal_stdout_tx_str(const char *str);
bool mp_hal_stdin_any(void);
-void mp_hal_delay_ms(mp_uint_t ms);
-#define mp_hal_delay_us(us) NRFX_DELAY_US((uint32_t) (us))
#endif
diff --git a/ports/nrf/nrfx b/ports/nrf/nrfx
-Subproject 293f553ed9551c1fdfd05eac48e75bbdeb4e729
+Subproject d4ebe15f58de1442e3eed93b40d13930e778590
diff --git a/ports/nrf/nrfx_config.h b/ports/nrf/nrfx_config.h
index cc4d19327..f217cb053 100644
--- a/ports/nrf/nrfx_config.h
+++ b/ports/nrf/nrfx_config.h
@@ -45,13 +45,8 @@
#define NRFX_TWIM_DEFAULT_CONFIG_HOLD_BUS_UNINIT 0
// UART
-#define NRFX_UART_ENABLED 1
-#define NRFX_UART0_ENABLED 1
-
-#define NRFX_UART_DEFAULT_CONFIG_IRQ_PRIORITY 7
-#define NRFX_UART_DEFAULT_CONFIG_HWFC NRF_UART_HWFC_DISABLED
-#define NRFX_UART_DEFAULT_CONFIG_PARITY NRF_UART_PARITY_EXCLUDED
-#define NRFX_UART_DEFAULT_CONFIG_BAUDRATE NRF_UART_BAUDRATE_115200
+#define NRFX_UARTE_ENABLED 1
+#define NRFX_UARTE0_ENABLED 1
// PWM
#define NRFX_PWM0_ENABLED 1
diff --git a/ports/nrf/supervisor/filesystem.c b/ports/nrf/supervisor/filesystem.c
index 1a3165a2d..b6611417d 100644
--- a/ports/nrf/supervisor/filesystem.c
+++ b/ports/nrf/supervisor/filesystem.c
@@ -36,7 +36,7 @@ static mp_vfs_mount_t _mp_vfs;
static fs_user_mount_t _internal_vfs;
-void filesystem_init(bool create_allowed) {
+void filesystem_init(bool create_allowed, bool force_create) {
// init the vfs object
fs_user_mount_t *int_vfs = &_internal_vfs;
int_vfs->flags = 0;
@@ -45,7 +45,7 @@ void filesystem_init(bool create_allowed) {
// try to mount the flash
FRESULT res = f_mount(&int_vfs->fatfs);
- if (res == FR_NO_FILESYSTEM && create_allowed) {
+ if ((res == FR_NO_FILESYSTEM && create_allowed) || force_create) {
// no filesystem so create a fresh one
uint8_t working_buf[_MAX_SS];
res = f_mkfs(&int_vfs->fatfs, FM_FAT | FM_SFD, 4096, working_buf, sizeof(working_buf));
diff --git a/ports/nrf/supervisor/port.c b/ports/nrf/supervisor/port.c
index e6bb25458..c858a3648 100644
--- a/ports/nrf/supervisor/port.c
+++ b/ports/nrf/supervisor/port.c
@@ -34,6 +34,8 @@
#include "shared-module/gamepad/__init__.h"
#include "common-hal/microcontroller/Pin.h"
+#include "common-hal/busio/I2C.h"
+#include "common-hal/busio/SPI.h"
#include "common-hal/pulseio/PWMOut.h"
#include "tick.h"
@@ -72,11 +74,14 @@ safe_mode_t port_init(void) {
}
void reset_port(void) {
- #ifdef CIRCUITPY_GAMEPAD_TICKS
- gamepad_reset();
- #endif
+#ifdef CIRCUITPY_GAMEPAD_TICKS
+ gamepad_reset();
+#endif
+ i2c_reset();
+ spi_reset();
pwmout_reset();
+
reset_all_pins();
}
diff --git a/ports/nrf/supervisor/serial.c b/ports/nrf/supervisor/serial.c
index da7fe07fd..cfbcc4b31 100644
--- a/ports/nrf/supervisor/serial.c
+++ b/ports/nrf/supervisor/serial.c
@@ -24,19 +24,19 @@
* THE SOFTWARE.
*/
-#include "mphalport.h"
+#include "py/mphal.h"
#if MICROPY_PY_BLE_NUS
#include "ble_uart.h"
#else
#include "nrf_gpio.h"
+#include "nrfx_uarte.h"
#endif
-#if !defined( NRF52840_XXAA) || ( defined(CFG_HWUART_FOR_SERIAL) && CFG_HWUART_FOR_SERIAL == 1 )
+#if !defined(NRF52840_XXAA)
-#define INST_NO 0
-
-nrfx_uart_t serial_instance = NRFX_UART_INSTANCE(INST_NO);
+uint8_t serial_received_char;
+nrfx_uarte_t serial_instance = NRFX_UARTE_INSTANCE(0);
void serial_init(void) {
#if MICROPY_PY_BLE_NUS
@@ -45,22 +45,27 @@ void serial_init(void) {
;
}
#else
- nrfx_uart_config_t config = NRFX_UART_DEFAULT_CONFIG;
- config.pseltxd = MICROPY_HW_UART_TX;
- config.pselrxd = MICROPY_HW_UART_RX;
- config.hwfc = MICROPY_HW_UART_HWFC ? NRF_UART_HWFC_ENABLED : NRF_UART_HWFC_DISABLED;
-#ifdef MICROPY_HW_UART_CTS
- config.pselcts = MICROPY_HW_UART_CTS;
-#endif
-#ifdef MICROPY_HW_UART_RTS
- config.pselrts = MICROPY_HW_UART_RTS;
-#endif
-
- const nrfx_err_t err = nrfx_uart_init(&serial_instance, &config, NULL);
- if (err == NRFX_SUCCESS)
+ nrfx_uarte_config_t config = {
+ .pseltxd = MICROPY_HW_UART_TX,
+ .pselrxd = MICROPY_HW_UART_RX,
+ .pselcts = NRF_UARTE_PSEL_DISCONNECTED,
+ .pselrts = NRF_UARTE_PSEL_DISCONNECTED,
+ .p_context = NULL,
+ .hwfc = NRF_UARTE_HWFC_DISABLED,
+ .parity = NRF_UARTE_PARITY_EXCLUDED,
+ .baudrate = NRF_UARTE_BAUDRATE_115200,
+ .interrupt_priority = 7
+ };
+
+ nrfx_uarte_uninit(&serial_instance);
+ const nrfx_err_t err = nrfx_uarte_init(&serial_instance, &config, NULL); // no callback for blocking mode
+
+ if (err != NRFX_SUCCESS) {
NRFX_ASSERT(err);
+ }
- nrfx_uart_rx_enable(&serial_instance);
+ // enabled receiving
+ nrf_uarte_task_trigger(serial_instance.p_reg, NRF_UARTE_TASK_STARTRX);
#endif
}
diff --git a/py/emitinlinethumb.c b/py/emitinlinethumb.c
index 577f65672..7f0ec6659 100644
--- a/py/emitinlinethumb.c
+++ b/py/emitinlinethumb.c
@@ -59,7 +59,7 @@ struct _emit_inline_asm_t {
qstr *label_lookup;
};
-STATIC void emit_inline_thumb_error_msg(emit_inline_asm_t *emit, const char *msg) {
+STATIC void emit_inline_thumb_error_msg(emit_inline_asm_t *emit, const compressed_string_t *msg) {
*emit->error_slot = mp_obj_new_exception_msg(&mp_type_SyntaxError, msg);
}
@@ -99,17 +99,17 @@ STATIC void emit_inline_thumb_end_pass(emit_inline_asm_t *emit, mp_uint_t type_s
STATIC mp_uint_t emit_inline_thumb_count_params(emit_inline_asm_t *emit, mp_uint_t n_params, mp_parse_node_t *pn_params) {
if (n_params > 4) {
- emit_inline_thumb_error_msg(emit, "can only have up to 4 parameters to Thumb assembly");
+ emit_inline_thumb_error_msg(emit, translate("can only have up to 4 parameters to Thumb assembly"));
return 0;
}
for (mp_uint_t i = 0; i < n_params; i++) {
if (!MP_PARSE_NODE_IS_ID(pn_params[i])) {
- emit_inline_thumb_error_msg(emit, "parameters must be registers in sequence r0 to r3");
+ emit_inline_thumb_error_msg(emit, translate("parameters must be registers in sequence r0 to r3"));
return 0;
}
const char *p = qstr_str(MP_PARSE_NODE_LEAF_ARG(pn_params[i]));
if (!(strlen(p) == 2 && p[0] == 'r' && p[1] == '0' + i)) {
- emit_inline_thumb_error_msg(emit, "parameters must be registers in sequence r0 to r3");
+ emit_inline_thumb_error_msg(emit, translate("parameters must be registers in sequence r0 to r3"));
return 0;
}
}
@@ -185,7 +185,7 @@ STATIC mp_uint_t get_arg_reg(emit_inline_asm_t *emit, const char *op, mp_parse_n
if (r->reg > max_reg) {
emit_inline_thumb_error_exc(emit,
mp_obj_new_exception_msg_varg(&mp_type_SyntaxError,
- "'%s' expects at most r%d", op, max_reg));
+ translate("'%s' expects at most r%d"), op, max_reg));
return 0;
} else {
return r->reg;
@@ -194,7 +194,7 @@ STATIC mp_uint_t get_arg_reg(emit_inline_asm_t *emit, const char *op, mp_parse_n
}
emit_inline_thumb_error_exc(emit,
mp_obj_new_exception_msg_varg(&mp_type_SyntaxError,
- "'%s' expects a register", op));
+ translate("'%s' expects a register"), op));
return 0;
}
@@ -208,7 +208,7 @@ STATIC mp_uint_t get_arg_special_reg(emit_inline_asm_t *emit, const char *op, mp
}
emit_inline_thumb_error_exc(emit,
mp_obj_new_exception_msg_varg(&mp_type_SyntaxError,
- "'%s' expects a special register", op));
+ translate("'%s' expects a special register"), op));
return 0;
}
@@ -227,7 +227,7 @@ STATIC mp_uint_t get_arg_vfpreg(emit_inline_asm_t *emit, const char *op, mp_pars
if (regno > 31) {
emit_inline_thumb_error_exc(emit,
mp_obj_new_exception_msg_varg(&mp_type_SyntaxError,
- "'%s' expects at most r%d", op, 31));
+ translate("'%s' expects at most r%d"), op, 31));
return 0;
} else {
return regno;
@@ -236,7 +236,7 @@ STATIC mp_uint_t get_arg_vfpreg(emit_inline_asm_t *emit, const char *op, mp_pars
malformed:
emit_inline_thumb_error_exc(emit,
mp_obj_new_exception_msg_varg(&mp_type_SyntaxError,
- "'%s' expects an FPU register", op));
+ translate("'%s' expects an FPU register"), op));
return 0;
}
#endif
@@ -289,19 +289,19 @@ STATIC mp_uint_t get_arg_reglist(emit_inline_asm_t *emit, const char *op, mp_par
return reglist;
bad_arg:
- emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, "'%s' expects {r0, r1, ...}", op));
+ emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, translate("'%s' expects {r0, r1, ...}"), op));
return 0;
}
STATIC uint32_t get_arg_i(emit_inline_asm_t *emit, const char *op, mp_parse_node_t pn, uint32_t fit_mask) {
mp_obj_t o;
if (!mp_parse_node_get_int_maybe(pn, &o)) {
- emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, "'%s' expects an integer", op));
+ emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, translate("'%s' expects an integer"), op));
return 0;
}
uint32_t i = mp_obj_get_int_truncated(o);
if ((i & (~fit_mask)) != 0) {
- emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, "'%s' integer 0x%x does not fit in mask 0x%x", op, i, fit_mask));
+ emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, translate("'%s' integer 0x%x does not fit in mask 0x%x"), op, i, fit_mask));
return 0;
}
return i;
@@ -325,13 +325,13 @@ STATIC bool get_arg_addr(emit_inline_asm_t *emit, const char *op, mp_parse_node_
return true;
bad_arg:
- emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, "'%s' expects an address of the form [a, b]", op));
+ emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, translate("'%s' expects an address of the form [a, b]"), op));
return false;
}
STATIC int get_arg_label(emit_inline_asm_t *emit, const char *op, mp_parse_node_t pn) {
if (!MP_PARSE_NODE_IS_ID(pn)) {
- emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, "'%s' expects a label", op));
+ emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, translate("'%s' expects a label"), op));
return 0;
}
qstr label_qstr = MP_PARSE_NODE_LEAF_ARG(pn);
@@ -342,7 +342,7 @@ STATIC int get_arg_label(emit_inline_asm_t *emit, const char *op, mp_parse_node_
}
// only need to have the labels on the last pass
if (emit->pass == MP_PASS_EMIT) {
- emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, "label '%q' not defined", label_qstr));
+ emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, translate("label '%q' not defined"), label_qstr));
}
return 0;
}
@@ -803,11 +803,11 @@ STATIC void emit_inline_thumb_op(emit_inline_asm_t *emit, qstr op, mp_uint_t n_a
return;
unknown_op:
- emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, "unsupported Thumb instruction '%s' with %d arguments", op_str, n_args));
+ emit_inline_thumb_error_exc(emit, mp_obj_new_exception_msg_varg(&mp_type_SyntaxError, translate("unsupported Thumb instruction '%s' with %d arguments"), op_str, n_args));
return;
branch_not_in_range:
- emit_inline_thumb_error_msg(emit, "branch not in range");
+ emit_inline_thumb_error_msg(emit, translate("branch not in range"));
return;
}
diff --git a/shared-bindings/audioio/Mixer.c b/shared-bindings/audioio/Mixer.c
new file mode 100644
index 000000000..dc7a12ebc
--- /dev/null
+++ b/shared-bindings/audioio/Mixer.c
@@ -0,0 +1,249 @@
+/*
+ * This file is part of the Micro Python project, http://micropython.org/
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2018 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 "shared-bindings/audioio/Mixer.h"
+
+#include <stdint.h>
+
+#include "lib/utils/context_manager_helpers.h"
+#include "py/binary.h"
+#include "py/objproperty.h"
+#include "py/runtime.h"
+#include "shared-bindings/microcontroller/Pin.h"
+#include "shared-bindings/audioio/RawSample.h"
+#include "shared-bindings/util.h"
+#include "supervisor/shared/translate.h"
+
+//| .. currentmodule:: audioio
+//|
+//| :class:`Mixer` -- Mixes one or more audio samples together
+//| ===========================================================
+//|
+//| Mixer mixes multiple samples into one sample.
+//|
+//| .. class:: Mixer(channel_count=2, buffer_size=1024)
+//|
+//| Create a Mixer object that can mix multiple channels with the same sample rate.
+//|
+//| :param int channel_count: The maximum number of samples to mix at once
+//| :param int buffer_size: The total size in bytes of the buffers to mix into
+//|
+//| Playing a wave file from flash::
+//|
+//| import board
+//| import audioio
+//| import digitalio
+//|
+//| # Required for CircuitPlayground Express
+//| speaker_enable = digitalio.DigitalInOut(board.SPEAKER_ENABLE)
+//| speaker_enable.switch_to_output(value=True)
+//|
+//| music = audioio.WaveFile(open("cplay-5.1-16bit-16khz.wav", "rb"))
+//| drum = audioio.WaveFile(open("drum.wav", "rb"))
+//| mixer = audioio.Mixer(voice_count=2, sample_rate=16000, channel_count=1, bits_per_sample=16, samples_signed=True)
+//| a = audioio.AudioOut(board.A0)
+//|
+//| print("playing")
+//| a.play(mixer)
+//| mixer.play(music, voice=0)
+//| while mixer.playing:
+//| mixer.play(drum, voice=1)
+//| time.sleep(1)
+//| print("stopped")
+//|
+STATIC mp_obj_t audioio_mixer_make_new(const mp_obj_type_t *type, size_t n_args, size_t n_kw, const mp_obj_t *pos_args) {
+ mp_arg_check_num(n_args, n_kw, 0, 2, true);
+ mp_map_t kw_args;
+ mp_map_init_fixed_table(&kw_args, n_kw, pos_args + n_args);
+ enum { ARG_voice_count, ARG_buffer_size, ARG_channel_count, ARG_bits_per_sample, ARG_samples_signed, ARG_sample_rate };
+ static const mp_arg_t allowed_args[] = {
+ { MP_QSTR_voice_count, MP_ARG_INT | MP_ARG_KW_ONLY, {.u_int = 2} },
+ { MP_QSTR_buffer_size, MP_ARG_INT | MP_ARG_KW_ONLY, {.u_int = 1024} },
+ { MP_QSTR_channel_count, MP_ARG_INT | MP_ARG_KW_ONLY, {.u_int = 2} },
+ { MP_QSTR_bits_per_sample, MP_ARG_INT | MP_ARG_KW_ONLY, {.u_int = 16} },
+ { MP_QSTR_samples_signed, MP_ARG_BOOL | MP_ARG_KW_ONLY, {.u_bool = true} },
+ { MP_QSTR_sample_rate, MP_ARG_INT | MP_ARG_KW_ONLY, {.u_int = 8000} },
+ };
+ mp_arg_val_t args[MP_ARRAY_SIZE(allowed_args)];
+ mp_arg_parse_all(n_args, pos_args, &kw_args, MP_ARRAY_SIZE(allowed_args), allowed_args, args);
+
+ mp_int_t voice_count = args[ARG_voice_count].u_int;
+ if (voice_count < 1 || voice_count > 255) {
+ mp_raise_ValueError(translate("Invalid voice count"));
+ }
+
+ mp_int_t channel_count = args[ARG_channel_count].u_int;
+ if (channel_count < 1 || channel_count > 2) {
+ mp_raise_ValueError(translate("Invalid channel count"));
+ }
+ mp_int_t sample_rate = args[ARG_sample_rate].u_int;
+ if (sample_rate < 1) {
+ mp_raise_ValueError(translate("Sample rate must be positive"));
+ }
+ mp_int_t bits_per_sample = args[ARG_bits_per_sample].u_int;
+ if (bits_per_sample != 8 && bits_per_sample != 16) {
+ mp_raise_ValueError(translate("bits_per_sample must be 8 or 16"));
+ }
+ audioio_mixer_obj_t *self = m_new_obj_var(audioio_mixer_obj_t, audioio_mixer_voice_t, voice_count);
+ self->base.type = &audioio_mixer_type;
+ common_hal_audioio_mixer_construct(self, voice_count, args[ARG_buffer_size].u_int, bits_per_sample, args[ARG_samples_signed].u_bool, channel_count, sample_rate);
+
+ return MP_OBJ_FROM_PTR(self);
+}
+
+//| .. method:: deinit()
+//|
+//| Deinitialises the Mixer and releases any hardware resources for reuse.
+//|
+STATIC mp_obj_t audioio_mixer_deinit(mp_obj_t self_in) {
+ audioio_mixer_obj_t *self = MP_OBJ_TO_PTR(self_in);
+ common_hal_audioio_mixer_deinit(self);
+ return mp_const_none;
+}
+STATIC MP_DEFINE_CONST_FUN_OBJ_1(audioio_mixer_deinit_obj, audioio_mixer_deinit);
+
+//| .. method:: __enter__()
+//|
+//| No-op used by Context Managers.
+//|
+// Provided by context manager helper.
+
+//| .. method:: __exit__()
+//|
+//| Automatically deinitializes the hardware when exiting a context. See
+//| :ref:`lifetime-and-contextmanagers` for more info.
+//|
+STATIC mp_obj_t audioio_mixer_obj___exit__(size_t n_args, const mp_obj_t *args) {
+ (void)n_args;
+ common_hal_audioio_mixer_deinit(args[0]);
+ return mp_const_none;
+}
+STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(audioio_mixer___exit___obj, 4, 4, audioio_mixer_obj___exit__);
+
+
+//| .. method:: play(sample, *, voice=0, loop=False)
+//|
+//| Plays the sample once when loop=False and continuously when loop=True.
+//| Does not block. Use `playing` to block.
+//|
+//| Sample must be an `audioio.WaveFile`, `audioio.Mixer` or `audioio.RawSample`.
+//|
+//| The sample must match the Mixer's encoding settings given in the constructor.
+//|
+STATIC mp_obj_t audioio_mixer_obj_play(size_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) {
+ enum { ARG_sample, ARG_voice, ARG_loop };
+ static const mp_arg_t allowed_args[] = {
+ { MP_QSTR_sample, MP_ARG_OBJ | MP_ARG_REQUIRED },
+ { MP_QSTR_voice, MP_ARG_INT | MP_ARG_KW_ONLY, {.u_int = 0} },
+ { MP_QSTR_loop, MP_ARG_BOOL | MP_ARG_KW_ONLY, {.u_bool = false} },
+ };
+ audioio_mixer_obj_t *self = MP_OBJ_TO_PTR(pos_args[0]);
+ raise_error_if_deinited(common_hal_audioio_mixer_deinited(self));
+ mp_arg_val_t args[MP_ARRAY_SIZE(allowed_args)];
+ mp_arg_parse_all(n_args - 1, pos_args + 1, kw_args, MP_ARRAY_SIZE(allowed_args), allowed_args, args);
+
+ mp_obj_t sample = args[ARG_sample].u_obj;
+ common_hal_audioio_mixer_play(self, sample, args[ARG_voice].u_int, args[ARG_loop].u_bool);
+
+ return mp_const_none;
+}
+MP_DEFINE_CONST_FUN_OBJ_KW(audioio_mixer_play_obj, 1, audioio_mixer_obj_play);
+
+//| .. method:: stop_voice(voice=0)
+//|
+//| Stops playback of the sample on the given voice.
+//|
+STATIC mp_obj_t audioio_mixer_obj_stop_voice(size_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) {
+ enum { ARG_voice };
+ static const mp_arg_t allowed_args[] = {
+ { MP_QSTR_voice, MP_ARG_INT, {.u_int = 0} },
+ };
+ audioio_mixer_obj_t *self = MP_OBJ_TO_PTR(pos_args[0]);
+ raise_error_if_deinited(common_hal_audioio_mixer_deinited(self));
+ mp_arg_val_t args[MP_ARRAY_SIZE(allowed_args)];
+ mp_arg_parse_all(n_args - 1, pos_args + 1, kw_args, MP_ARRAY_SIZE(allowed_args), allowed_args, args);
+
+ common_hal_audioio_mixer_stop_voice(self, args[ARG_voice].u_int);
+ return mp_const_none;
+}
+MP_DEFINE_CONST_FUN_OBJ_KW(audioio_mixer_stop_voice_obj, 1, audioio_mixer_obj_stop_voice);
+
+//| .. attribute:: playing
+//|
+//| True when any voice is being output. (read-only)
+//|
+STATIC mp_obj_t audioio_mixer_obj_get_playing(mp_obj_t self_in) {
+ audioio_mixer_obj_t *self = MP_OBJ_TO_PTR(self_in);
+ raise_error_if_deinited(common_hal_audioio_mixer_deinited(self));
+ return mp_obj_new_bool(common_hal_audioio_mixer_get_playing(self));
+}
+MP_DEFINE_CONST_FUN_OBJ_1(audioio_mixer_get_playing_obj, audioio_mixer_obj_get_playing);
+
+const mp_obj_property_t audioio_mixer_playing_obj = {
+ .base.type = &mp_type_property,
+ .proxy = {(mp_obj_t)&audioio_mixer_get_playing_obj,
+ (mp_obj_t)&mp_const_none_obj,
+ (mp_obj_t)&mp_const_none_obj},
+};
+
+//| .. attribute:: sample_rate
+//|
+//| 32 bit value that dictates how quickly samples are played in Hertz (cycles per second).
+//|
+STATIC mp_obj_t audioio_mixer_obj_get_sample_rate(mp_obj_t self_in) {
+ audioio_mixer_obj_t *self = MP_OBJ_TO_PTR(self_in);
+ raise_error_if_deinited(common_hal_audioio_mixer_deinited(self));
+ return MP_OBJ_NEW_SMALL_INT(common_hal_audioio_mixer_get_sample_rate(self));
+}
+MP_DEFINE_CONST_FUN_OBJ_1(audioio_mixer_get_sample_rate_obj, audioio_mixer_obj_get_sample_rate);
+
+
+const mp_obj_property_t audioio_mixer_sample_rate_obj = {
+ .base.type = &mp_type_property,
+ .proxy = {(mp_obj_t)&audioio_mixer_get_sample_rate_obj,
+ (mp_obj_t)&mp_const_none_obj,
+ (mp_obj_t)&mp_const_none_obj},
+};
+
+STATIC const mp_rom_map_elem_t audioio_mixer_locals_dict_table[] = {
+ // Methods
+ { MP_ROM_QSTR(MP_QSTR_deinit), MP_ROM_PTR(&audioio_mixer_deinit_obj) },
+ { MP_ROM_QSTR(MP_QSTR___enter__), MP_ROM_PTR(&default___enter___obj) },
+ { MP_ROM_QSTR(MP_QSTR___exit__), MP_ROM_PTR(&audioio_mixer___exit___obj) },
+ { MP_ROM_QSTR(MP_QSTR_play), MP_ROM_PTR(&audioio_mixer_play_obj) },
+ { MP_ROM_QSTR(MP_QSTR_stop_voice), MP_ROM_PTR(&audioio_mixer_stop_voice_obj) },
+
+ // Properties
+ { MP_ROM_QSTR(MP_QSTR_playing), MP_ROM_PTR(&audioio_mixer_playing_obj) },
+ { MP_ROM_QSTR(MP_QSTR_sample_rate), MP_ROM_PTR(&audioio_mixer_sample_rate_obj) },
+};
+STATIC MP_DEFINE_CONST_DICT(audioio_mixer_locals_dict, audioio_mixer_locals_dict_table);
+
+const mp_obj_type_t audioio_mixer_type = {
+ { &mp_type_type },
+ .name = MP_QSTR_Mixer,
+ .make_new = audioio_mixer_make_new,
+ .locals_dict = (mp_obj_dict_t*)&audioio_mixer_locals_dict,
+};
diff --git a/shared-bindings/audioio/Mixer.h b/shared-bindings/audioio/Mixer.h
new file mode 100644
index 000000000..832072b8f
--- /dev/null
+++ b/shared-bindings/audioio/Mixer.h
@@ -0,0 +1,52 @@
+/*
+ * This file is part of the Micro Python project, http://micropython.org/
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2018 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.
+ */
+
+#ifndef MICROPY_INCLUDED_SHARED_BINDINGS_AUDIOIO_MIXER_H
+#define MICROPY_INCLUDED_SHARED_BINDINGS_AUDIOIO_MIXER_H
+
+#include "common-hal/microcontroller/Pin.h"
+#include "shared-module/audioio/Mixer.h"
+#include "shared-bindings/audioio/RawSample.h"
+
+extern const mp_obj_type_t audioio_mixer_type;
+
+void common_hal_audioio_mixer_construct(audioio_mixer_obj_t* self,
+ uint8_t voice_count,
+ uint32_t buffer_size,
+ uint8_t bits_per_sample,
+ bool samples_signed,
+ uint8_t channel_count,
+ uint32_t sample_rate);
+
+void common_hal_audioio_mixer_deinit(audioio_mixer_obj_t* self);
+bool common_hal_audioio_mixer_deinited(audioio_mixer_obj_t* self);
+void common_hal_audioio_mixer_play(audioio_mixer_obj_t* self, mp_obj_t sample, uint8_t voice, bool loop);
+void common_hal_audioio_mixer_stop_voice(audioio_mixer_obj_t* self, uint8_t voice);
+
+bool common_hal_audioio_mixer_get_playing(audioio_mixer_obj_t* self);
+uint32_t common_hal_audioio_mixer_get_sample_rate(audioio_mixer_obj_t* self);
+
+#endif // MICROPY_INCLUDED_SHARED_BINDINGS_AUDIOIO_MIXER_H
diff --git a/shared-bindings/audioio/__init__.c b/shared-bindings/audioio/__init__.c
index 8a00b43d8..4786b6425 100644
--- a/shared-bindings/audioio/__init__.c
+++ b/shared-bindings/audioio/__init__.c
@@ -32,6 +32,8 @@
#include "shared-bindings/microcontroller/Pin.h"
#include "shared-bindings/audioio/__init__.h"
#include "shared-bindings/audioio/AudioOut.h"
+#include "shared-bindings/audioio/Mixer.h"
+#include "shared-bindings/audioio/RawSample.h"
#include "shared-bindings/audioio/WaveFile.h"
//| :mod:`audioio` --- Support for audio input and output
@@ -49,6 +51,7 @@
//| :maxdepth: 3
//|
//| AudioOut
+//| Mixer
//| RawSample
//| WaveFile
//|
@@ -61,6 +64,7 @@
STATIC const mp_rom_map_elem_t audioio_module_globals_table[] = {
{ MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_audioio) },
{ MP_ROM_QSTR(MP_QSTR_AudioOut), MP_ROM_PTR(&audioio_audioout_type) },
+ { MP_ROM_QSTR(MP_QSTR_Mixer), MP_ROM_PTR(&audioio_mixer_type) },
{ MP_ROM_QSTR(MP_QSTR_RawSample), MP_ROM_PTR(&audioio_rawsample_type) },
{ MP_ROM_QSTR(MP_QSTR_WaveFile), MP_ROM_PTR(&audioio_wavefile_type) },
};
diff --git a/shared-bindings/busio/SPI.c b/shared-bindings/busio/SPI.c
index 7983a3a56..d30bbbe06 100644
--- a/shared-bindings/busio/SPI.c
+++ b/shared-bindings/busio/SPI.c
@@ -136,19 +136,26 @@ static void check_lock(busio_spi_obj_t *self) {
//| .. method:: SPI.configure(\*, baudrate=100000, polarity=0, phase=0, bits=8)
//|
-//| Configures the SPI bus. Only valid when locked.
+//| Configures the SPI bus. The SPI object must be locked.
//|
//| :param int baudrate: the desired clock rate in Hertz. The actual clock rate may be higher or lower
//| due to the granularity of available clock settings.
//| Check the `frequency` attribute for the actual clock rate.
-//| **Note:** on the SAMD21, it is possible to set the baud rate to 24 MHz, but that
-//| speed is not guaranteed to work. 12 MHz is the next available lower speed, and is
-//| within spec for the SAMD21.
//| :param int polarity: the base state of the clock line (0 or 1)
//| :param int phase: the edge of the clock that data is captured. First (0)
//| or second (1). Rising or falling depends on clock polarity.
//| :param int bits: the number of bits per word
//|
+//| .. note:: On the SAMD21, it is possible to set the baudrate to 24 MHz, but that
+//| speed is not guaranteed to work. 12 MHz is the next available lower speed, and is
+//| within spec for the SAMD21.
+//|
+//| .. note:: On the nRF52832, these baudrates are available: 125kHz, 250kHz, 1MHz, 2MHz, 4MHz,
+//| and 8MHz. On the nRF52840, 16MHz and 32MHz are also available, but only on the first
+//| `busio.SPI` object you create. Two more ``busio.SPI`` objects can be created, but they are restricted
+//| to 8MHz maximum. This is a hardware restriction: there is only one high-speed SPI peripheral.
+//| If you pick a a baudrate other than one of these, the nearest lower
+//| baudrate will be chosen, with a minimum of 125kHz.
STATIC mp_obj_t busio_spi_configure(size_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) {
enum { ARG_baudrate, ARG_polarity, ARG_phase, ARG_bits };
static const mp_arg_t allowed_args[] = {
diff --git a/shared-bindings/pulseio/PWMOut.c b/shared-bindings/pulseio/PWMOut.c
index 9b7094b4e..362b8123d 100644
--- a/shared-bindings/pulseio/PWMOut.c
+++ b/shared-bindings/pulseio/PWMOut.c
@@ -192,7 +192,7 @@ STATIC mp_obj_t pulseio_pwmout_obj_set_frequency(mp_obj_t self_in, mp_obj_t freq
raise_error_if_deinited(common_hal_pulseio_pwmout_deinited(self));
if (!common_hal_pulseio_pwmout_get_variable_frequency(self)) {
mp_raise_AttributeError(translate(
- "PWM frequency not writeable when variable_frequency is False on "
+ "PWM frequency not writable when variable_frequency is False on "
"construction."));
}
common_hal_pulseio_pwmout_set_frequency(self, mp_obj_get_int(frequency));
diff --git a/shared-bindings/supervisor/Runtime.c b/shared-bindings/supervisor/Runtime.c
index b061595cf..5ba2198e1 100755
--- a/shared-bindings/supervisor/Runtime.c
+++ b/shared-bindings/supervisor/Runtime.c
@@ -80,8 +80,34 @@ const mp_obj_property_t supervisor_serial_connected_obj = {
(mp_obj_t)&mp_const_none_obj},
};
+
+//| .. attribute:: runtime.serial_bytes_available
+//|
+//| Returns the whether any bytes are available to read
+//| on the USB serial input. Allows for polling to see whether
+//| to call the built-in input() or wait. (read-only)
+//|
+STATIC mp_obj_t supervisor_get_serial_bytes_available(mp_obj_t self){
+ if (!common_hal_get_serial_bytes_available()) {
+ return mp_const_false;
+ }
+ else {
+ return mp_const_true;
+ }
+}
+MP_DEFINE_CONST_FUN_OBJ_1(supervisor_get_serial_bytes_available_obj, supervisor_get_serial_bytes_available);
+
+const mp_obj_property_t supervisor_serial_bytes_available_obj = {
+ .base.type = &mp_type_property,
+ .proxy = {(mp_obj_t)&supervisor_get_serial_bytes_available_obj,
+ (mp_obj_t)&mp_const_none_obj,
+ (mp_obj_t)&mp_const_none_obj},
+};
+
+
STATIC const mp_rom_map_elem_t supervisor_runtime_locals_dict_table[] = {
{ MP_ROM_QSTR(MP_QSTR_serial_connected), MP_ROM_PTR(&supervisor_serial_connected_obj) },
+ { MP_ROM_QSTR(MP_QSTR_serial_bytes_available), MP_ROM_PTR(&supervisor_serial_bytes_available_obj) },
};
STATIC MP_DEFINE_CONST_DICT(supervisor_runtime_locals_dict, supervisor_runtime_locals_dict_table);
diff --git a/shared-bindings/supervisor/Runtime.h b/shared-bindings/supervisor/Runtime.h
index 4a67925ec..864b070cd 100755
--- a/shared-bindings/supervisor/Runtime.h
+++ b/shared-bindings/supervisor/Runtime.h
@@ -35,6 +35,8 @@ const mp_obj_type_t supervisor_runtime_type;
bool common_hal_get_serial_connected(void);
+bool common_hal_get_serial_bytes_available(void);
+
//TODO: placeholders for future functions
//bool common_hal_get_repl_active(void);
//bool common_hal_get_usb_enumerated(void);
diff --git a/shared-module/audioio/Mixer.c b/shared-module/audioio/Mixer.c
new file mode 100644
index 000000000..8020a621e
--- /dev/null
+++ b/shared-module/audioio/Mixer.c
@@ -0,0 +1,341 @@
+/*
+ * This file is part of the Micro Python project, http://micropython.org/
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2018 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 "shared-bindings/audioio/Mixer.h"
+
+#include <stdint.h>
+
+#include "py/runtime.h"
+#include "shared-module/audioio/__init__.h"
+#include "shared-module/audioio/RawSample.h"
+
+void common_hal_audioio_mixer_construct(audioio_mixer_obj_t* self,
+ uint8_t voice_count,
+ uint32_t buffer_size,
+ uint8_t bits_per_sample,
+ bool samples_signed,
+ uint8_t channel_count,
+ uint32_t sample_rate) {
+ self->len = buffer_size / 2 / sizeof(uint32_t) * sizeof(uint32_t);
+
+ self->first_buffer = m_malloc(self->len, false);
+ if (self->first_buffer == NULL) {
+ common_hal_audioio_mixer_deinit(self);
+ mp_raise_msg(&mp_type_MemoryError, translate("Couldn't allocate first buffer"));
+ }
+
+ self->second_buffer = m_malloc(self->len, false);
+ if (self->second_buffer == NULL) {
+ common_hal_audioio_mixer_deinit(self);
+ mp_raise_msg(&mp_type_MemoryError, translate("Couldn't allocate second buffer"));
+ }
+
+ self->bits_per_sample = bits_per_sample;
+ self->samples_signed = samples_signed;
+ self->channel_count = channel_count;
+ self->sample_rate = sample_rate;
+ self->voice_count = voice_count;
+
+ for (uint8_t i = 0; i < self->voice_count; i++) {
+ self->voice[i].sample = NULL;
+ }
+}
+
+void common_hal_audioio_mixer_deinit(audioio_mixer_obj_t* self) {
+ self->first_buffer = NULL;
+ self->second_buffer = NULL;
+}
+
+bool common_hal_audioio_mixer_deinited(audioio_mixer_obj_t* self) {
+ return self->first_buffer == NULL;
+}
+
+uint32_t common_hal_audioio_mixer_get_sample_rate(audioio_mixer_obj_t* self) {
+ return self->sample_rate;
+}
+
+void common_hal_audioio_mixer_play(audioio_mixer_obj_t* self, mp_obj_t sample, uint8_t v, bool loop) {
+ if (v >= self->voice_count) {
+ mp_raise_ValueError(translate("Voice index too high"));
+ }
+ if (audiosample_sample_rate(sample) != self->sample_rate) {
+ mp_raise_ValueError(translate("The sample's sample rate does not match the mixer's"));
+ }
+ if (audiosample_channel_count(sample) != self->channel_count) {
+ mp_raise_ValueError(translate("The sample's channel count does not match the mixer's"));
+ }
+ if (audiosample_bits_per_sample(sample) != self->bits_per_sample) {
+ mp_raise_ValueError(translate("The sample's bits_per_sample does not match the mixer's"));
+ }
+ bool single_buffer;
+ bool samples_signed;
+ uint32_t max_buffer_length;
+ uint8_t spacing;
+ audiosample_get_buffer_structure(sample, false, &single_buffer, &samples_signed,
+ &max_buffer_length, &spacing);
+ if (samples_signed != self->samples_signed) {
+ mp_raise_ValueError(translate("The sample's signedness does not match the mixer's"));
+ }
+ audioio_mixer_voice_t* voice = &self->voice[v];
+ voice->sample = sample;
+ voice->loop = loop;
+
+ audiosample_reset_buffer(sample, false, 0);
+ audioio_get_buffer_result_t result = audiosample_get_buffer(sample, false, 0, (uint8_t**) &voice->remaining_buffer, &voice->buffer_length);
+ // Track length in terms of words.
+ voice->buffer_length /= sizeof(uint32_t);
+ voice->more_data = result == GET_BUFFER_MORE_DATA;
+}
+
+void common_hal_audioio_mixer_stop_voice(audioio_mixer_obj_t* self, uint8_t voice) {
+ self->voice[voice].sample = NULL;
+}
+
+bool common_hal_audioio_mixer_get_playing(audioio_mixer_obj_t* self) {
+ for (int32_t v = 0; v < self->voice_count; v++) {
+ if (self->voice[v].sample != NULL) {
+ return true;
+ }
+ }
+ return false;
+}
+
+void audioio_mixer_reset_buffer(audioio_mixer_obj_t* self,
+ bool single_channel,
+ uint8_t channel) {
+ for (int32_t i = 0; i < self->voice_count; i++) {
+ self->voice[i].sample = NULL;
+ }
+}
+
+uint32_t add8signed(uint32_t a, uint32_t b) {
+ #if (defined (__ARM_FEATURE_DSP) && (__ARM_FEATURE_DSP == 1))
+ return __QADD8(a, b);
+ #else
+ uint32_t result = 0;
+ for (int8_t i = 0; i < 4; i++) {
+ int8_t ai = a >> (sizeof(int8_t) * 8 * i);
+ int8_t bi = b >> (sizeof(int8_t) * 8 * i);
+ int32_t intermediate = (int32_t) ai + bi;
+ if (intermediate > CHAR_MAX) {
+ intermediate = CHAR_MAX;
+ } else if (intermediate < CHAR_MIN) {
+ //intermediate = CHAR_MIN;
+ }
+ result |= (((uint32_t) intermediate) & 0xff) << (sizeof(int8_t) * 8 * i);
+ }
+ return result;
+ #endif
+}
+
+uint32_t add8unsigned(uint32_t a, uint32_t b) {
+ #if (defined (__ARM_FEATURE_DSP) && (__ARM_FEATURE_DSP == 1))
+ // Subtract out the DC offset, add and then shift back.
+ a = __USUB8(a, 0x80808080);
+ b = __USUB8(b, 0x80808080);
+ uint32_t sum = __QADD8(a, b);
+ return __UADD8(sum, 0x80808080);
+ #else
+ uint32_t result = 0;
+ for (int8_t i = 0; i < 4; i++) {
+ int8_t ai = (a >> (sizeof(uint8_t) * 8 * i)) - 128;
+ int8_t bi = (b >> (sizeof(uint8_t) * 8 * i)) - 128;
+ int32_t intermediate = (int32_t) ai + bi;
+ if (intermediate > UCHAR_MAX) {
+ intermediate = UCHAR_MAX;
+ }
+ result |= ((uint8_t) intermediate + 128) << (sizeof(uint8_t) * 8 * i);
+ }
+ return result;
+ #endif
+}
+
+uint32_t add16signed(uint32_t a, uint32_t b) {
+ #if (defined (__ARM_FEATURE_DSP) && (__ARM_FEATURE_DSP == 1))
+ return __QADD16(a, b);
+ #else
+ uint32_t result = 0;
+ for (int8_t i = 0; i < 2; i++) {
+ int16_t ai = a >> (sizeof(int16_t) * 8 * i);
+ int16_t bi = b >> (sizeof(int16_t) * 8 * i);
+ int32_t intermediate = (int32_t) ai + bi;
+ if (intermediate > SHRT_MAX) {
+ intermediate = SHRT_MAX;
+ } else if (intermediate < SHRT_MIN) {
+ intermediate = SHRT_MIN;
+ }
+ result |= (((uint32_t) intermediate) & 0xffff) << (sizeof(int16_t) * 8 * i);
+ }
+ return result;
+ #endif
+}
+
+uint32_t add16unsigned(uint32_t a, uint32_t b) {
+ #if (defined (__ARM_FEATURE_DSP) && (__ARM_FEATURE_DSP == 1))
+ // Subtract out the DC offset, add and then shift back.
+ a = __USUB16(a, 0x80008000);
+ b = __USUB16(b, 0x80008000);
+ uint32_t sum = __QADD16(a, b);
+ return __UADD16(sum, 0x80008000);
+ #else
+ uint32_t result = 0;
+ for (int8_t i = 0; i < 2; i++) {
+ int16_t ai = (a >> (sizeof(uint16_t) * 8 * i)) - 0x8000;
+ int16_t bi = (b >> (sizeof(uint16_t) * 8 * i)) - 0x8000;
+ int32_t intermediate = (int32_t) ai + bi;
+ if (intermediate > USHRT_MAX) {
+ intermediate = USHRT_MAX;
+ }
+ result |= ((uint16_t) intermediate + 0x8000) << (sizeof(int16_t) * 8 * i);
+ }
+ return result;
+ #endif
+}
+
+audioio_get_buffer_result_t audioio_mixer_get_buffer(audioio_mixer_obj_t* self,
+ bool single_channel,
+ uint8_t channel,
+ uint8_t** buffer,
+ uint32_t* buffer_length) {
+ if (!single_channel) {
+ channel = 0;
+ }
+
+ uint32_t channel_read_count = self->left_read_count;
+ if (channel == 1) {
+ channel_read_count = self->right_read_count;
+ }
+ *buffer_length = self->len;
+
+ bool need_more_data = self->read_count == channel_read_count;
+ if (need_more_data) {
+ uint32_t* word_buffer;
+ if (self->use_first_buffer) {
+ *buffer = (uint8_t*) self->first_buffer;
+ word_buffer = self->first_buffer;
+ } else {
+ *buffer = (uint8_t*) self->second_buffer;
+ word_buffer = self->second_buffer;
+ }
+ self->use_first_buffer = !self->use_first_buffer;
+ bool voices_active = false;
+ for (int32_t v = 0; v < self->voice_count; v++) {
+ audioio_mixer_voice_t* voice = &self->voice[v];
+
+ uint32_t j = 0;
+ bool voice_done = voice->sample == NULL;
+ for (uint32_t i = 0; i < self->len / sizeof(uint32_t); i++) {
+ if (!voice_done && j >= voice->buffer_length) {
+ if (!voice->more_data) {
+ if (voice->loop) {
+ audiosample_reset_buffer(voice->sample, false, 0);
+ } else {
+ voice->sample = NULL;
+ voice_done = true;
+ }
+ }
+ if (!voice_done) {
+ // Load another buffer
+ audioio_get_buffer_result_t result = audiosample_get_buffer(voice->sample, false, 0, (uint8_t**) &voice->remaining_buffer, &voice->buffer_length);
+ // Track length in terms of words.
+ voice->buffer_length /= sizeof(uint32_t);
+ voice->more_data = result == GET_BUFFER_MORE_DATA;
+ j = 0;
+ }
+ }
+ // First active voice gets copied over verbatim.
+ uint32_t sample_value;
+ if (voice_done) {
+ // Exit early if another voice already set all samples once.
+ if (voices_active) {
+ continue;
+ }
+ sample_value = 0;
+ if (!self->samples_signed) {
+ if (self->bits_per_sample == 8) {
+ sample_value = 0x7f7f7f7f;
+ } else {
+ sample_value = 0x7fff7fff;
+ }
+ }
+ } else {
+ sample_value = voice->remaining_buffer[j];
+ }
+
+ if (!voices_active) {
+ word_buffer[i] = sample_value;
+ } else {
+ if (self->bits_per_sample == 8) {
+ if (self->samples_signed) {
+ word_buffer[i] = add8signed(word_buffer[i], sample_value);
+ } else {
+ word_buffer[i] = add8unsigned(word_buffer[i], sample_value);
+ }
+ } else {
+ if (self->samples_signed) {
+ word_buffer[i] = add16signed(word_buffer[i], sample_value);
+ } else {
+ word_buffer[i] = add16unsigned(word_buffer[i], sample_value);
+ }
+ }
+ }
+ j++;
+ }
+ voice->buffer_length -= j;
+ voice->remaining_buffer += j;
+
+ voices_active = true;
+ }
+
+ self->read_count += 1;
+ } else if (!self->use_first_buffer) {
+ *buffer = (uint8_t*) self->first_buffer;
+ } else {
+ *buffer = (uint8_t*) self->second_buffer;
+ }
+
+
+ if (channel == 0) {
+ self->left_read_count += 1;
+ } else if (channel == 1) {
+ self->right_read_count += 1;
+ *buffer = *buffer + self->bits_per_sample / 8;
+ }
+ return GET_BUFFER_MORE_DATA;
+}
+
+void audioio_mixer_get_buffer_structure(audioio_mixer_obj_t* self, bool single_channel,
+ bool* single_buffer, bool* samples_signed,
+ uint32_t* max_buffer_length, uint8_t* spacing) {
+ *single_buffer = false;
+ *samples_signed = self->samples_signed;
+ *max_buffer_length = self->len;
+ if (single_channel) {
+ *spacing = self->channel_count;
+ } else {
+ *spacing = 1;
+ }
+}
diff --git a/shared-module/audioio/Mixer.h b/shared-module/audioio/Mixer.h
new file mode 100644
index 000000000..6a88fe0bd
--- /dev/null
+++ b/shared-module/audioio/Mixer.h
@@ -0,0 +1,75 @@
+/*
+ * This file is part of the MicroPython project, http://micropython.org/
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2018 Scott Shawcroft
+ *
+ * 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_SHARED_MODULE_AUDIOIO_MIXER_H
+#define MICROPY_INCLUDED_SHARED_MODULE_AUDIOIO_MIXER_H
+
+#include "py/obj.h"
+
+#include "shared-module/audioio/__init__.h"
+
+typedef struct {
+ mp_obj_t sample;
+ bool loop;
+ bool more_data;
+ uint32_t* remaining_buffer;
+ uint32_t buffer_length;
+} audioio_mixer_voice_t;
+
+typedef struct {
+ mp_obj_base_t base;
+ uint32_t* first_buffer;
+ uint32_t* second_buffer;
+ uint32_t len; // in words
+ uint8_t bits_per_sample;
+ bool use_first_buffer;
+ bool samples_signed;
+ uint8_t channel_count;
+ uint32_t sample_rate;
+
+ uint32_t read_count;
+ uint32_t left_read_count;
+ uint32_t right_read_count;
+
+ uint8_t voice_count;
+ audioio_mixer_voice_t voice[];
+} audioio_mixer_obj_t;
+
+
+// These are not available from Python because it may be called in an interrupt.
+void audioio_mixer_reset_buffer(audioio_mixer_obj_t* self,
+ bool single_channel,
+ uint8_t channel);
+audioio_get_buffer_result_t audioio_mixer_get_buffer(audioio_mixer_obj_t* self,
+ bool single_channel,
+ uint8_t channel,
+ uint8_t** buffer,
+ uint32_t* buffer_length); // length in bytes
+void audioio_mixer_get_buffer_structure(audioio_mixer_obj_t* self, bool single_channel,
+ bool* single_buffer, bool* samples_signed,
+ uint32_t* max_buffer_length, uint8_t* spacing);
+
+#endif // MICROPY_INCLUDED_SHARED_MODULE_AUDIOIO_MIXER_H
diff --git a/shared-module/audioio/WaveFile.c b/shared-module/audioio/WaveFile.c
index 7efad05e0..e5a7b1a3b 100644
--- a/shared-module/audioio/WaveFile.c
+++ b/shared-module/audioio/WaveFile.c
@@ -200,13 +200,29 @@ audioio_get_buffer_result_t audioio_wavefile_get_buffer(audioio_wavefile_obj_t*
if (f_read(&self->file->fp, *buffer, num_bytes_to_load, &length_read) != FR_OK) {
return GET_BUFFER_ERROR;
}
+ self->bytes_remaining -= length_read;
+ // Pad the last buffer to word align it.
+ if (self->bytes_remaining == 0 && length_read % sizeof(uint32_t) != 0) {
+ uint32_t pad = length_read % sizeof(uint32_t);
+ length_read += pad;
+ if (self->bits_per_sample == 8) {
+ for (uint32_t i = 0; i < pad; i++) {
+ ((uint8_t*) (*buffer))[length_read / sizeof(uint8_t) - i - 1] = 0x80;
+ }
+ } else if (self->bits_per_sample == 16) {
+ // We know the buffer is aligned because we allocated it onto the heap ourselves.
+ #pragma GCC diagnostic push
+ #pragma GCC diagnostic ignored "-Wcast-align"
+ ((int16_t*) (*buffer))[length_read / sizeof(int16_t) - 1] = 0;
+ #pragma GCC diagnostic pop
+ }
+ }
*buffer_length = length_read;
if (self->buffer_index % 2 == 1) {
self->second_buffer_length = length_read;
} else {
self->buffer_length = length_read;
}
- self->bytes_remaining -= length_read;
self->buffer_index += 1;
self->read_count += 1;
}
diff --git a/shared-module/audioio/__init__.c b/shared-module/audioio/__init__.c
new file mode 100644
index 000000000..b87b06a83
--- /dev/null
+++ b/shared-module/audioio/__init__.c
@@ -0,0 +1,125 @@
+/*
+ * This file is part of the MicroPython project, http://micropython.org/
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2018 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 "shared-module/audioio/__init__.h"
+
+#include "py/obj.h"
+#include "shared-bindings/audioio/Mixer.h"
+#include "shared-bindings/audioio/RawSample.h"
+#include "shared-bindings/audioio/WaveFile.h"
+#include "shared-module/audioio/Mixer.h"
+#include "shared-module/audioio/RawSample.h"
+#include "shared-module/audioio/WaveFile.h"
+
+uint32_t audiosample_sample_rate(mp_obj_t sample_obj) {
+ if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
+ audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
+ return sample->sample_rate;
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
+ audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
+ return file->sample_rate;
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_mixer_type)) {
+ audioio_mixer_obj_t* mixer = MP_OBJ_TO_PTR(sample_obj);
+ return mixer->sample_rate;
+ }
+ return 16000;
+}
+
+uint8_t audiosample_bits_per_sample(mp_obj_t sample_obj) {
+ if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
+ audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
+ return sample->bits_per_sample;
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
+ audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
+ return file->bits_per_sample;
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_mixer_type)) {
+ audioio_mixer_obj_t* mixer = MP_OBJ_TO_PTR(sample_obj);
+ return mixer->bits_per_sample;
+ }
+ return 8;
+}
+
+uint8_t audiosample_channel_count(mp_obj_t sample_obj) {
+ if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
+ audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
+ return sample->channel_count;
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
+ audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
+ return file->channel_count;
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_mixer_type)) {
+ audioio_mixer_obj_t* mixer = MP_OBJ_TO_PTR(sample_obj);
+ return mixer->channel_count;
+ }
+ return 1;
+}
+
+void audiosample_reset_buffer(mp_obj_t sample_obj, bool single_channel, uint8_t audio_channel) {
+ if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
+ audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
+ audioio_rawsample_reset_buffer(sample, single_channel, audio_channel);
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
+ audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
+ audioio_wavefile_reset_buffer(file, single_channel, audio_channel);
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_mixer_type)) {
+ audioio_mixer_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
+ audioio_mixer_reset_buffer(file, single_channel, audio_channel);
+ }
+}
+
+audioio_get_buffer_result_t audiosample_get_buffer(mp_obj_t sample_obj,
+ bool single_channel,
+ uint8_t channel,
+ uint8_t** buffer, uint32_t* buffer_length) {
+ if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
+ audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
+ return audioio_rawsample_get_buffer(sample, single_channel, channel, buffer, buffer_length);
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
+ audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
+ return audioio_wavefile_get_buffer(file, single_channel, channel, buffer, buffer_length);
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_mixer_type)) {
+ audioio_mixer_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
+ return audioio_mixer_get_buffer(file, single_channel, channel, buffer, buffer_length);
+ }
+ return GET_BUFFER_DONE;
+}
+
+void audiosample_get_buffer_structure(mp_obj_t sample_obj, bool single_channel,
+ bool* single_buffer, bool* samples_signed,
+ uint32_t* max_buffer_length, uint8_t* spacing) {
+ if (MP_OBJ_IS_TYPE(sample_obj, &audioio_rawsample_type)) {
+ audioio_rawsample_obj_t* sample = MP_OBJ_TO_PTR(sample_obj);
+ audioio_rawsample_get_buffer_structure(sample, single_channel, single_buffer,
+ samples_signed, max_buffer_length, spacing);
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_wavefile_type)) {
+ audioio_wavefile_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
+ audioio_wavefile_get_buffer_structure(file, single_channel, single_buffer, samples_signed,
+ max_buffer_length, spacing);
+ } else if (MP_OBJ_IS_TYPE(sample_obj, &audioio_mixer_type)) {
+ audioio_mixer_obj_t* file = MP_OBJ_TO_PTR(sample_obj);
+ audioio_mixer_get_buffer_structure(file, single_channel, single_buffer, samples_signed,
+ max_buffer_length, spacing);
+ }
+}
diff --git a/shared-module/audioio/__init__.h b/shared-module/audioio/__init__.h
index 2491beb12..c805f3116 100644
--- a/shared-module/audioio/__init__.h
+++ b/shared-module/audioio/__init__.h
@@ -27,10 +27,27 @@
#ifndef MICROPY_INCLUDED_SHARED_MODULE_AUDIOIO__INIT__H
#define MICROPY_INCLUDED_SHARED_MODULE_AUDIOIO__INIT__H
+#include <stdbool.h>
+#include <stdint.h>
+
+#include "py/obj.h"
+
typedef enum {
GET_BUFFER_DONE, // No more data to read
GET_BUFFER_MORE_DATA, // More data to read.
GET_BUFFER_ERROR, // Error while reading data.
} audioio_get_buffer_result_t;
+uint32_t audiosample_sample_rate(mp_obj_t sample_obj);
+uint8_t audiosample_bits_per_sample(mp_obj_t sample_obj);
+uint8_t audiosample_channel_count(mp_obj_t sample_obj);
+void audiosample_reset_buffer(mp_obj_t sample_obj, bool single_channel, uint8_t audio_channel);
+audioio_get_buffer_result_t audiosample_get_buffer(mp_obj_t sample_obj,
+ bool single_channel,
+ uint8_t channel,
+ uint8_t** buffer, uint32_t* buffer_length);
+void audiosample_get_buffer_structure(mp_obj_t sample_obj, bool single_channel,
+ bool* single_buffer, bool* samples_signed,
+ uint32_t* max_buffer_length, uint8_t* spacing);
+
#endif // MICROPY_INCLUDED_SHARED_MODULE_AUDIOIO__INIT__H
diff --git a/shared-module/displayio/Sprite.c b/shared-module/displayio/Sprite.c
index 4fe8d1ff6..87600f721 100644
--- a/shared-module/displayio/Sprite.c
+++ b/shared-module/displayio/Sprite.c
@@ -68,7 +68,7 @@ bool displayio_sprite_get_pixel(displayio_sprite_t *self, int16_t x, int16_t y,
if (y < 0 || y >= self->height || x >= self->width || x < 0) {
return false;
}
- uint32_t value;
+ uint32_t value = 0;
if (MP_OBJ_IS_TYPE(self->bitmap, &displayio_bitmap_type)) {
value = common_hal_displayio_bitmap_get_pixel(self->bitmap, x, y);
} else if (MP_OBJ_IS_TYPE(self->bitmap, &displayio_ondiskbitmap_type)) {
diff --git a/tools/preprocess_frozen_modules.py b/tools/preprocess_frozen_modules.py
index d157deeee..bb6959f0d 100755
--- a/tools/preprocess_frozen_modules.py
+++ b/tools/preprocess_frozen_modules.py
@@ -33,7 +33,7 @@ def copy_and_process(in_dir, out_dir):
for root, subdirs, files in os.walk(in_dir):
# Skip library examples directories.
- if Path(root).name in ['examples', 'docs']:
+ if Path(root).name in ['examples', 'docs', 'tests']:
continue
for file in files: