diff options
| author | DavePutz <dwputz@gmail.com> | 2021-02-08 10:39:26 -0600 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-02-08 10:39:26 -0600 |
| commit | cec921f3747beccff10c2d2dfbc237c305083f62 (patch) | |
| tree | 4fb9ed7d2dc50123b1d858a86f3556b4784405fa | |
| parent | 6043fdf94085bf2ec00e9f95149a74fb7eb0c7c4 (diff) | |
| parent | 482e58307756bfec3cb7d4c0c8d73ffae0ec228d (diff) | |
Merge pull request #40 from adafruit/main
Update from adafruit main
169 files changed, 6414 insertions, 1619 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index cc5ad4f7b..34e0b0821 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -304,6 +304,7 @@ jobs: - "seeeduino_xiao" - "serpente" - "shirtty" + - "silicognition-m4-shim" - "simmel" - "snekboard" - "sparkfun_lumidrive" @@ -443,6 +444,7 @@ jobs: - "espressif_kaluga_1" - "espressif_saola_1_wroom" - "espressif_saola_1_wrover" + - "lilygo_ttgo_t8_s2_st7789" - "microdev_micro_s2" - "muselab_nanoesp32_s2" - "targett_module_clip_wroom" @@ -462,12 +464,12 @@ jobs: - run: git fetch --recurse-submodules=no https://github.com/adafruit/circuitpython refs/tags/*:refs/tags/* - name: CircuitPython version run: git describe --dirty --tags - - uses: actions/cache@v1 + - uses: actions/cache@v2 name: Fetch IDF tool cache id: idf-cache with: path: ${{ github.workspace }}/.idf_tools - key: ${{ runner.os }}-idf-tools-${{ hashFiles('.git/modules/ports/esp32s2/esp-idf/HEAD') }}-20210121 + key: ${{ runner.os }}-idf-tools-${{ hashFiles('.git/modules/ports/esp32s2/esp-idf/HEAD') }}-20210128 - name: Clone IDF submodules run: | (cd $IDF_PATH && git submodule update --init) diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml index af62072c8..76bfd7786 100644 --- a/.github/workflows/pre-commit.yml +++ b/.github/workflows/pre-commit.yml @@ -21,7 +21,7 @@ jobs: run: git submodule update --init extmod/ulab - name: set PY run: echo >>$GITHUB_ENV PY="$(python -c 'import hashlib, sys;print(hashlib.sha256(sys.version.encode()+sys.executable.encode()).hexdigest())')" - - uses: actions/cache@v1 + - uses: actions/cache@v2 with: path: ~/.cache/pre-commit key: pre-commit|${{ env.PY }}|${{ hashFiles('.pre-commit-config.yaml') }} @@ -40,17 +40,18 @@ ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(BASEOPTS) # the i18n builder cannot share the environment and doctrees with the others I18NSPHINXOPTS = $(BASEOPTS) -TRANSLATE_SOURCES = extmod lib main.c ports/atmel-samd ports/cxd56 ports/esp32s2 ports/mimxrt10xx ports/nrf ports/stm py shared-bindings shared-module supervisor +TRANSLATE_SOURCES = extmod lib main.c ports/atmel-samd ports/cxd56 ports/esp32s2 ports/mimxrt10xx ports/nrf ports/raspberrypi ports/stm py shared-bindings shared-module supervisor # Paths to exclude from TRANSLATE_SOURCES # Each must be preceded by "-path"; if any wildcards, enclose in quotes. # Separate by "-o" (Find's "or" operand) TRANSLATE_SOURCES_EXC = -path "ports/*/build-*" \ -o -path "ports/*/build" \ - -o -path ports/esp32s2/esp-idf \ - -o -path ports/cxd56/spresense-exported-sdk \ - -o -path ports/stm/st_driver \ -o -path ports/atmel-samd/asf4 \ + -o -path ports/cxd56/spresense-exported-sdk \ + -o -path ports/esp32s2/esp-idf \ -o -path ports/mimxrt10xx/sdk \ + -o -path ports/raspberrypi/sdk \ + -o -path ports/stm/st_driver \ -o -path lib/tinyusb \ -o -path lib/lwip \ diff --git a/README.rst b/README.rst index 19992d284..f14cf41ff 100644 --- a/README.rst +++ b/README.rst @@ -125,7 +125,7 @@ Behavior get back into normal mode. - RGB status LED indicating CircuitPython state, and errors through a sequence of colored flashes. - Re-runs ``code.py`` or other main file after file system writes over USB mass storage. (Disable with - ``samd.disable_autoreload()``) + ``supervisor.disable_autoreload()``) - Entering the REPL after the main code is finished requires a key press which enters the REPL and disables autoreload. - Main is one of these: ``code.txt``, ``code.py``, ``main.py``, diff --git a/WEBUSB_README.md b/WEBUSB_README.md new file mode 100644 index 000000000..a257d5259 --- /dev/null +++ b/WEBUSB_README.md @@ -0,0 +1,94 @@ +<!-- +SPDX-FileCopyrightText: 2014 MicroPython & CircuitPython contributors (https://github.com/adafruit/circuitpython/graphs/contributors) + +SPDX-License-Identifier: MIT +--> + +# WebUSB Serial Support + +To date, this has only been tested on one port (esp32s2), on one board (espressif_kaluga_1). + +## What it does + +If you have ever used CircuitPython on a platform with a graphical LCD display, you have probably +already seen multiple "consoles" in use (although the LCD console is "output only"). + +New compile-time option CIRCUITPY_USB_VENDOR enables an additional "console" that can be used in +parallel with the original (CDC) serial console. + +Web pages that support the WebUSB standard can connect to the "vendor" interface and activate +this WebUSB serial console at any time. + +You can type into either console, and CircuitPython output is sent to all active consoles. + +One example of a web page you can use to test drive this feature can be found at: + +https://adafruit.github.io/Adafruit_TinyUSB_Arduino/examples/webusb-serial/index.html + +## How to enable + +Update your platform's mpconfigboard.mk file to enable and disable specific types of USB interfaces. + +CIRCUITPY_USB_HID = xxx +CIRCUITPY_USB_MIDI = xxx +CIRCUITPY_USB_VENDOR = xxx + +On at least some of the hardware platforms, the maximum number of USB endpoints is fixed. +For example, on the ESP32S2, you must pick only one of the above 3 interfaces to be enabled. + +Original espressif_kaluga_1 mpconfigboard.mk settings: + +CIRCUITPY_USB_HID = 1 +CIRCUITPY_USB_MIDI = 0 +CIRCUITPY_USB_VENDOR = 0 + +Settings to enable WebUSB instead: + +CIRCUITPY_USB_HID = 0 +CIRCUITPY_USB_MIDI = 0 +CIRCUITPY_USB_VENDOR = 1 + +Notice that to enable VENDOR on ESP32-S2, we had to give up HID. There may be platforms that can have both, or even all three. + +## Implementation Notes + +CircuitPython uses the tinyusb library. + +The tinyusb library already has support for WebUSB serial. +The tinyusb examples already include a "WebUSB serial" example. + + Sidenote - The use of the term "vendor" instead of "WebUSB" was done to match tinyusb. + +Basically, this feature was ported into CircuitPython by pulling code snippets out of the +tinyusb example, and putting them where they best belonged in the CircuitPython codebase. + +There was one complication: + +tinyusb uses C preprocessor macros to define things like USB descriptors. + +CircuitPython uses a Python program (tools/gen_usb_descriptor.py) to create USB descriptors (etc.) +using "helper objects" from another repo (adafruit_usb_descriptor). This means some of the example +code had to be adapted to the new programing model, and gen_usb_descriptor gained new command-line +options to control the generated code. + +The generated files go into the "build" directory, look for autogen_usb_descriptor.c and +genhdr/autogen_usb_descriptor.h. + + +Also worth pointing out - the re-use of the CDC connect/disconnect mechanism is not actually part +of the WebUSB standard, it's more of "common idiom". We make use of it here because we need to know +when we should be paying attention to the WebUSB serial interface, and when we should ignore it.. + +## Possible future work areas + +The current code uses the existing Python infrastructure to create the Interface descriptor, but +simply outputs the code snippets from the original tinyusb demo code to create the WEBUSB_URL, +BOS, and MS_OS_20 descriptors. I suppose additional work could be done to add these to the +adafruit_usb_descriptor project, and then gen_usb_descriptor.py could be modified to make use +of them. + +Program gen_usb_descriptor.py creates objects for most interface types, regardless of whether or +not they are actually enabled. This increases the size of a generated string table. I made the +new vendor-interface-related code not do this (because some of the ARM platforms would no longer +build), but I did not go back and do this for the other interface types (CDC, MIDI, HID, etc.) +Some FLASH savings are probably possible if this is done. diff --git a/docs/design_guide.rst b/docs/design_guide.rst index 75825893a..7a8c76b50 100644 --- a/docs/design_guide.rst +++ b/docs/design_guide.rst @@ -520,7 +520,9 @@ properties. +-----------------------+-----------------------+-------------------------------------------------------------------------+ | ``temperature`` | float | degrees centigrade | +-----------------------+-----------------------+-------------------------------------------------------------------------+ -| ``eCO2`` | float | equivalent CO2 in ppm | +| ``CO2`` | float | measured CO2 in ppm | ++-----------------------+-----------------------+-------------------------------------------------------------------------+ +| ``eCO2`` | float | equivalent/estimated CO2 in ppm (estimated from some other measurement) | +-----------------------+-----------------------+-------------------------------------------------------------------------+ | ``TVOC`` | float | Total Volatile Organic Compounds in ppb | +-----------------------+-----------------------+-------------------------------------------------------------------------+ diff --git a/docs/index.rst b/docs/index.rst index 6dadddfc1..3ee76fdd8 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -46,6 +46,7 @@ Full Table of Contents ../BUILDING ../CODE_OF_CONDUCT ../license.rst + ../WEBUSB_README Indices and tables ================== diff --git a/docs/library/uerrno.rst b/docs/library/errno.rst index 72f71f0aa..96777b205 100644 --- a/docs/library/uerrno.rst +++ b/docs/library/errno.rst @@ -1,9 +1,7 @@ -:mod:`uerrno` -- system error codes +:mod:`errno` -- system error codes =================================== -.. include:: ../templates/unsupported_in_circuitpython.inc - -.. module:: uerrno +.. module:: errno :synopsis: system error codes |see_cpython_module| :mod:`cpython:errno`. @@ -22,7 +20,7 @@ Constants try: os.mkdir("my_dir") except OSError as exc: - if exc.args[0] == uerrno.EEXIST: + if exc.args[0] == errno.EEXIST: print("Directory already exists") .. data:: errorcode @@ -30,5 +28,5 @@ Constants Dictionary mapping numeric error codes to strings with symbolic error code (see above):: - >>> print(uerrno.errorcode[uerrno.EEXIST]) + >>> print(errno.errorcode[uerrno.EEXIST]) EEXIST diff --git a/docs/library/esp.rst b/docs/library/esp.rst deleted file mode 100644 index 125aaa890..000000000 --- a/docs/library/esp.rst +++ /dev/null @@ -1,85 +0,0 @@ -:mod:`esp` --- functions related to the ESP8266 -=============================================== - -.. include:: ../templates/unsupported_in_circuitpython.inc - -.. module:: esp - :synopsis: functions related to the ESP8266 - -The ``esp`` module contains specific functions related to the ESP8266 module. - - -Functions ---------- - -.. function:: sleep_type([sleep_type]) - - Get or set the sleep type. - - If the *sleep_type* parameter is provided, sets the sleep type to its - value. If the function is called without parameters, returns the current - sleep type. - - The possible sleep types are defined as constants: - - * ``SLEEP_NONE`` -- all functions enabled, - * ``SLEEP_MODEM`` -- modem sleep, shuts down the WiFi Modem circuit. - * ``SLEEP_LIGHT`` -- light sleep, shuts down the WiFi Modem circuit - and suspends the processor periodically. - - The system enters the set sleep mode automatically when possible. - -.. function:: deepsleep(time=0) - - Enter deep sleep. - - The whole module powers down, except for the RTC clock circuit, which can - be used to restart the module after the specified time if the pin 16 is - connected to the reset pin. Otherwise the module will sleep until manually - reset. - -.. function:: flash_id() - - Read the device ID of the flash memory. - -.. function:: flash_read(byte_offset, length_or_buffer) - -.. function:: flash_write(byte_offset, bytes) - -.. function:: flash_erase(sector_no) - -.. function:: set_native_code_location(start, length) - - Set the location that native code will be placed for execution after it is - compiled. Native code is emitted when the ``@micropython.native``, - ``@micropython.viper`` and ``@micropython.asm_xtensa`` decorators are applied - to a function. The ESP8266 must execute code from either iRAM or the lower - 1MByte of flash (which is memory mapped), and this function controls the - location. - - If *start* and *length* are both ``None`` then the native code location is - set to the unused portion of memory at the end of the iRAM1 region. The - size of this unused portion depends on the firmware and is typically quite - small (around 500 bytes), and is enough to store a few very small - functions. The advantage of using this iRAM1 region is that it does not - get worn out by writing to it. - - If neither *start* nor *length* are ``None`` then they should be integers. - *start* should specify the byte offset from the beginning of the flash at - which native code should be stored. *length* specifies how many bytes of - flash from *start* can be used to store native code. *start* and *length* - should be multiples of the sector size (being 4096 bytes). The flash will - be automatically erased before writing to it so be sure to use a region of - flash that is not otherwise used, for example by the firmware or the - filesystem. - - When using the flash to store native code *start+length* must be less - than or equal to 1MByte. Note that the flash can be worn out if repeated - erasures (and writes) are made so use this feature sparingly. - In particular, native code needs to be recompiled and rewritten to flash - on each boot (including wake from deepsleep). - - In both cases above, using iRAM1 or flash, if there is no more room left - in the specified region then the use of a native decorator on a function - will lead to `MemoryError` exception being raised during compilation of - that function. diff --git a/docs/library/index.rst b/docs/library/index.rst index e91387242..181ff0109 100644 --- a/docs/library/index.rst +++ b/docs/library/index.rst @@ -6,35 +6,21 @@ MicroPython libraries Python standard libraries and micro-libraries --------------------------------------------- -These libraries are inherited from MicroPython. -They are similar to the standard Python libraries with the same name -or with the "u" prefix dropped. +The libraries below are inherited from MicroPython. +They are similar to the standard Python libraries with the same name. They implement a subset of or a variant of the corresponding standard Python library. -.. warning:: - - Though these MicroPython-based libraries are available in CircuitPython, - their functionality may change in the future, perhaps significantly. - As CircuitPython continues to develop, new versions of these libraries will - be created that are more compliant with the standard Python libraries. - You may need to change your code later if you rely - on any non-standard functionality they currently provide. - CircuitPython's long-term goal is that code written in CircuitPython using Python standard libraries will be runnable on CPython without changes. -Some libraries below are not enabled on CircuitPython builds with +These libraries are not enabled on CircuitPython builds with limited flash memory, usually on non-Express builds: -``uerrno``, ``ure``. - -Some libraries are not currently enabled in any CircuitPython build, but may be in the future: -``uio``, ``ujson``, ``uzlib``. +``binascii``, ``errno``, ``json``, ``re``. -Some libraries are only enabled only WiFi-capable ports (ESP8266, nRF) -because they are typically used for network software: -``binascii``, ``hashlib``, ``uheapq``, ``uselect``, ``ussl``. -Not all of these are enabled on all WiFi-capable ports. +These libraries are not currently enabled in any CircuitPython build, but may be in the future, +with the ``u`` prefix dropped: +``uctypes``, ``uhashlib``, ``uzlib``. .. toctree:: :maxdepth: 1 @@ -44,13 +30,14 @@ Not all of these are enabled on all WiFi-capable ports. array.rst binascii.rst collections.rst + errno.rst gc.rst hashlib.rst + io.rst + json.rst + re.rst sys.rst - uerrno.rst - uio.rst - ujson.rst - ure.rst + uctypes.rst uselect.rst usocket.rst ussl.rst @@ -59,8 +46,8 @@ Not all of these are enabled on all WiFi-capable ports. Omitted functions in the ``string`` library ------------------------------------------- -A few string operations are not enabled on CircuitPython -M0 non-Express builds, due to limited flash memory: +A few string operations are not enabled on small builds +(usually non-Express), due to limited flash memory: ``string.center()``, ``string.partition()``, ``string.splitlines()``, ``string.reversed()``. @@ -78,15 +65,3 @@ versions of CircuitPython. btree.rst framebuf.rst micropython.rst - network.rst - uctypes.rst - -Libraries specific to the ESP8266 ---------------------------------- - -The following libraries are specific to the ESP8266. - -.. toctree:: - :maxdepth: 2 - - esp.rst diff --git a/docs/library/uio.rst b/docs/library/io.rst index d1f7c111f..37e3eb7c9 100644 --- a/docs/library/uio.rst +++ b/docs/library/io.rst @@ -1,9 +1,7 @@ -:mod:`uio` -- input/output streams +:mod:`io` -- input/output streams ================================== -.. include:: ../templates/unsupported_in_circuitpython.inc - -.. module:: uio +.. module:: io :synopsis: input/output streams |see_cpython_module| :mod:`cpython:io`. diff --git a/docs/library/ujson.rst b/docs/library/json.rst index 4ed91f053..21574e556 100644 --- a/docs/library/ujson.rst +++ b/docs/library/json.rst @@ -1,9 +1,7 @@ -:mod:`ujson` -- JSON encoding and decoding +:mod:`json` -- JSON encoding and decoding ========================================== -.. include:: ../templates/unsupported_in_circuitpython.inc - -.. module:: ujson +.. module:: json :synopsis: JSON encoding and decoding |see_cpython_module| :mod:`cpython:json`. diff --git a/docs/library/network.rst b/docs/library/network.rst deleted file mode 100644 index 3bd41150d..000000000 --- a/docs/library/network.rst +++ /dev/null @@ -1,278 +0,0 @@ -**************************************** -:mod:`network` --- network configuration -**************************************** - -.. include:: ../templates/unsupported_in_circuitpython.inc - -.. module:: network - :noindex: - :synopsis: network configuration - -This module provides network drivers and routing configuration. To use this -module, a MicroPython variant/build with network capabilities must be installed. -Network drivers for specific hardware are available within this module and are -used to configure hardware network interface(s). Network services provided -by configured interfaces are then available for use via the :mod:`usocket` -module. - -For example:: - - # connect/ show IP config a specific network interface - # see below for examples of specific drivers - import network - import utime - nic = network.Driver(...) - if not nic.isconnected(): - nic.connect() - print("Waiting for connection...") - while not nic.isconnected(): - utime.sleep(1) - print(nic.ifconfig()) - - # now use usocket as usual - import usocket as socket - addr = socket.getaddrinfo('micropython.org', 80)[0][-1] - s = socket.socket() - s.connect(addr) - s.send(b'GET / HTTP/1.1\r\nHost: micropython.org\r\n\r\n') - data = s.recv(1000) - s.close() - -Common network adapter interface -================================ - -This section describes an (implied) abstract base class for all network -interface classes implemented by ``MicroPython ports <MicroPython port>`` -for different hardware. This means that MicroPython does not actually -provide ``AbstractNIC`` class, but any actual NIC class, as described -in the following sections, implements methods as described here. - -.. class:: AbstractNIC(id=None, ...) - -Instantiate a network interface object. Parameters are network interface -dependent. If there are more than one interface of the same type, the first -parameter should be `id`. - - .. method:: active([is_active]) - - Activate ("up") or deactivate ("down") the network interface, if - a boolean argument is passed. Otherwise, query current state if - no argument is provided. Most other methods require an active - interface (behavior of calling them on inactive interface is - undefined). - - .. method:: connect([service_id, key=None, \*, ...]) - - Connect the interface to a network. This method is optional, and - available only for interfaces which are not "always connected". - If no parameters are given, connect to the default (or the only) - service. If a single parameter is given, it is the primary identifier - of a service to connect to. It may be accompanied by a key - (password) required to access said service. There can be further - arbitrary keyword-only parameters, depending on the networking medium - type and/or particular device. Parameters can be used to: a) - specify alternative service identifier types; b) provide additional - connection parameters. For various medium types, there are different - sets of predefined/recommended parameters, among them: - - * WiFi: *bssid* keyword to connect to a specific BSSID (MAC address) - - .. method:: disconnect() - - Disconnect from network. - - .. method:: isconnected() - - Returns ``True`` if connected to network, otherwise returns ``False``. - - .. method:: scan(\*, ...) - - Scan for the available network services/connections. Returns a - list of tuples with discovered service parameters. For various - network media, there are different variants of predefined/ - recommended tuple formats, among them: - - * WiFi: (ssid, bssid, channel, RSSI, authmode, hidden). There - may be further fields, specific to a particular device. - - The function may accept additional keyword arguments to filter scan - results (e.g. scan for a particular service, on a particular channel, - for services of a particular set, etc.), and to affect scan - duration and other parameters. Where possible, parameter names - should match those in connect(). - - .. method:: status() - - Return detailed status of the interface, values are dependent - on the network medium/technology. - - .. method:: ifconfig([(ip, subnet, gateway, dns)]) - - Get/set IP-level network interface parameters: IP address, subnet mask, - gateway and DNS server. When called with no arguments, this method returns - a 4-tuple with the above information. To set the above values, pass a - 4-tuple with the required information. For example:: - - nic.ifconfig(('192.168.0.4', '255.255.255.0', '192.168.0.1', '8.8.8.8')) - - .. method:: config('param') - config(param=value, ...) - - Get or set general network interface parameters. These methods allow to work - with additional parameters beyond standard IP configuration (as dealt with by - `ifconfig()`). These include network-specific and hardware-specific - parameters and status values. For setting parameters, the keyword argument - syntax should be used, and multiple parameters can be set at once. For - querying, a parameter name should be quoted as a string, and only one - parameter can be queried at a time:: - - # Set WiFi access point name (formally known as ESSID) and WiFi channel - ap.config(essid='My AP', channel=11) - # Query params one by one - print(ap.config('essid')) - print(ap.config('channel')) - # Extended status information also available this way - print(sta.config('rssi')) - -.. _network.WLAN: - -Functions -========= - -.. function:: phy_mode([mode]) - - Get or set the PHY mode. - - If the *mode* parameter is provided, sets the mode to its value. If - the function is called without parameters, returns the current mode. - - The possible modes are defined as constants: - * ``MODE_11B`` -- IEEE 802.11b, - * ``MODE_11G`` -- IEEE 802.11g, - * ``MODE_11N`` -- IEEE 802.11n. - -class WLAN -========== - -This class provides a driver for WiFi network processor in the ESP8266. Example usage:: - - import network - # enable station interface and connect to WiFi access point - nic = network.WLAN(network.STA_IF) - nic.active(True) - nic.connect('your-ssid', 'your-password') - # now use sockets as usual - -Constructors ------------- -.. class:: WLAN(interface_id) - -Create a WLAN network interface object. Supported interfaces are -``network.STA_IF`` (station aka client, connects to upstream WiFi access -points) and ``network.AP_IF`` (access point, allows other WiFi clients to -connect). Availability of the methods below depends on interface type. -For example, only STA interface may `connect()` to an access point. - -Methods -------- - -.. method:: wlan.active([is_active]) - - Activate ("up") or deactivate ("down") network interface, if boolean - argument is passed. Otherwise, query current state if no argument is - provided. Most other methods require active interface. - -.. method:: wlan.connect(ssid=None, password=None, \*, bssid=None) - - Connect to the specified wireless network, using the specified password. - If *bssid* is given then the connection will be restricted to the - access-point with that MAC address (the *ssid* must also be specified - in this case). - -.. method:: wlan.disconnect() - - Disconnect from the currently connected wireless network. - -.. method:: wlan.scan() - - Scan for the available wireless networks. - - Scanning is only possible on STA interface. Returns list of tuples with - the information about WiFi access points: - - (ssid, bssid, channel, RSSI, authmode, hidden) - - *bssid* is hardware address of an access point, in binary form, returned as - bytes object. You can use `binascii.hexlify()` to convert it to ASCII form. - - There are five values for authmode: - - * 0 -- open - * 1 -- WEP - * 2 -- WPA-PSK - * 3 -- WPA2-PSK - * 4 -- WPA/WPA2-PSK - - and two for hidden: - - * 0 -- visible - * 1 -- hidden - -.. method:: wlan.status() - - Return the current status of the wireless connection. - - The possible statuses are defined as constants: - - * ``STAT_IDLE`` -- no connection and no activity, - * ``STAT_CONNECTING`` -- connecting in progress, - * ``STAT_WRONG_PASSWORD`` -- failed due to incorrect password, - * ``STAT_NO_AP_FOUND`` -- failed because no access point replied, - * ``STAT_CONNECT_FAIL`` -- failed due to other problems, - * ``STAT_GOT_IP`` -- connection successful. - -.. method:: wlan.isconnected() - - In case of STA mode, returns ``True`` if connected to a WiFi access - point and has a valid IP address. In AP mode returns ``True`` when a - station is connected. Returns ``False`` otherwise. - -.. method:: wlan.ifconfig([(ip, subnet, gateway, dns)]) - - Get/set IP-level network interface parameters: IP address, subnet mask, - gateway and DNS server. When called with no arguments, this method returns - a 4-tuple with the above information. To set the above values, pass a - 4-tuple with the required information. For example:: - - nic.ifconfig(('192.168.0.4', '255.255.255.0', '192.168.0.1', '8.8.8.8')) - -.. method:: wlan.config('param') - wlan.config(param=value, ...) - - Get or set general network interface parameters. These methods allow to work - with additional parameters beyond standard IP configuration (as dealt with by - `wlan.ifconfig()`). These include network-specific and hardware-specific - parameters. For setting parameters, keyword argument syntax should be used, - multiple parameters can be set at once. For querying, parameters name should - be quoted as a string, and only one parameter can be queries at time:: - - # Set WiFi access point name (formally known as ESSID) and WiFi channel - ap.config(essid='My AP', channel=11) - # Query params one by one - print(ap.config('essid')) - print(ap.config('channel')) - - Following are commonly supported parameters (availability of a specific parameter - depends on network technology type, driver, and ``MicroPython port``). - - ============= =========== - Parameter Description - ============= =========== - mac MAC address (bytes) - essid WiFi access point name (string) - channel WiFi channel (integer) - hidden Whether ESSID is hidden (boolean) - authmode Authentication mode supported (enumeration, see module constants) - password Access password (string) - dhcp_hostname The DHCP hostname to use - ============= =========== diff --git a/docs/library/ure.rst b/docs/library/re.rst index 4af182b01..bdcc9f52c 100644 --- a/docs/library/ure.rst +++ b/docs/library/re.rst @@ -1,9 +1,7 @@ -:mod:`ure` -- simple regular expressions +:mod:`re` -- simple regular expressions ======================================== -.. include:: ../templates/unsupported_in_circuitpython.inc - -.. module:: ure +.. module:: re :synopsis: regular expressions |see_cpython_module| :mod:`cpython:re`. @@ -77,7 +75,7 @@ Regex objects ------------- Compiled regular expression. Instances of this class are created using -`ure.compile()`. +`re.compile()`. .. method:: regex.match(string) regex.search(string) diff --git a/docs/shared_bindings_matrix.py b/docs/shared_bindings_matrix.py index f38c0b64a..e62b1d218 100644 --- a/docs/shared_bindings_matrix.py +++ b/docs/shared_bindings_matrix.py @@ -30,7 +30,7 @@ import sys from concurrent.futures import ThreadPoolExecutor -SUPPORTED_PORTS = ['atmel-samd', 'esp32s2', 'litex', 'mimxrt10xx', 'nrf', 'stm'] +SUPPORTED_PORTS = ['atmel-samd', 'cxd56', 'esp32s2', 'litex', 'mimxrt10xx', 'nrf', 'raspberrypi', 'stm'] def get_circuitpython_root_dir(): """ The path to the root './circuitpython' directory @@ -44,7 +44,7 @@ def get_shared_bindings(): """ Get a list of modules in shared-bindings based on folder names """ shared_bindings_dir = get_circuitpython_root_dir() / "shared-bindings" - return [item.name for item in shared_bindings_dir.iterdir()] + ["ulab"] + return [item.name for item in shared_bindings_dir.iterdir()] + ["binascii", "errno", "json", "re", "ulab"] def read_mpconfig(): diff --git a/extmod/ulab b/extmod/ulab -Subproject 8b804f3bcd8c5a3ac1b3e09e0ff7faf8270751d +Subproject 743d86487c83e42024ed508ed50499ad0a527d5 diff --git a/lib/protomatter b/lib/protomatter -Subproject 902c16f49197a8baf5e71ec924a812a86e733a7 +Subproject 5e925cea7a55273e375a6129761cb29b4e750d4 diff --git a/lib/tinyusb b/lib/tinyusb -Subproject 388abe9d9cc0a7c360fd902e01461a53bb7b3f4 +Subproject 045674745afa59028fbeed6dac5cb5a9c4a6033 diff --git a/locale/ID.po b/locale/ID.po index d0c9bbe30..c592acf9f 100644 --- a/locale/ID.po +++ b/locale/ID.po @@ -48,6 +48,10 @@ msgstr " File \"%q\"" msgid " File \"%q\", line %d" msgstr " File \"%q\", baris %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr "output:\n" @@ -59,8 +63,9 @@ msgstr "%%c harus int atau char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" -msgstr "pin alamat %d dan pin rgb %d menunjukkan tinggi %d, bukan %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" +msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c msgid "%q failure: %d" @@ -339,6 +344,10 @@ msgstr "Semua perangkat UART sedang digunakan" msgid "All event channels in use" msgstr "Semua channel event sedang digunakan" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "Semua channel event yang disinkronisasi sedang digunakan" @@ -387,6 +396,7 @@ msgstr "AnalogIn tidak didukung pada pin yang diberikan" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "fungsionalitas AnalogOut tidak didukung" @@ -519,7 +529,6 @@ msgstr "Panjang buffer harus kelipatan 512" msgid "Buffer must be a multiple of 512 bytes" msgstr "" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "Penyangga harus memiliki panjang setidaknya 1" @@ -534,6 +543,7 @@ msgid "Buffer too short by %d bytes" msgstr "Buffer terlalu pendek untuk %d byte" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -588,6 +598,7 @@ msgstr "Tidak dapat menghapus nilai" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "Tidak bisa mendapatkan pull pada saat mode output" @@ -631,6 +642,10 @@ msgstr "" "Tidak dapat melakukan reset ke bootloader karena tidak ada bootloader yang " "terisi" +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "Tidak dapat menetapkan nilai saat arah input." @@ -814,6 +829,10 @@ msgstr "DAC sudah digunakan" msgid "Data 0 pin must be byte aligned" msgstr "Data 0 pin harus byte disejajarkan" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "Potongan data harus mengikuti fmt chunk" @@ -869,7 +888,12 @@ msgstr "Channel EXTINT sedang digunakan" msgid "Error in regex" msgstr "Error pada regex" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -923,7 +947,7 @@ msgstr "FFT didefinisikan hanya untuk ndarrays" msgid "FFT is implemented for linear arrays only" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "" @@ -1051,6 +1075,10 @@ msgstr "operasi I/O pada file tertutup" msgid "I2C Init Error" msgstr "Gagal Inisialisasi I2C" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "" @@ -1076,6 +1104,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "Ukuran penyangga salah" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "" @@ -1088,6 +1120,31 @@ msgstr "" msgid "Input/output error" msgstr "Kesalahan input/output" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "Otentikasi tidak cukup" @@ -1139,7 +1196,7 @@ msgstr "Pin DAC yang diberikan tidak valid" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Frekuensi PWM tidak valid" @@ -1233,6 +1290,8 @@ msgstr "Pin untuk channel kanan tidak valid" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "Pin-pin tidak valid" @@ -1261,6 +1320,10 @@ msgstr "security_mode tidak valid" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1342,6 +1405,36 @@ msgstr "Penundaan mulai mikrofon harus dalam kisaran 0,0 hingga 1,0" msgid "Missing MISO or MOSI Pin" msgstr "Tidak menemukan Pin MISO atau MOSI" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "Harus berupa subclass %q." @@ -1395,14 +1488,14 @@ msgstr "Tidak ada Pin MOSI" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Tidak pin RX" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Tidak ada pin TX" @@ -1459,6 +1552,16 @@ msgstr "Tidak ada lagi penghitung waktu yang tersedia pada pin ini." msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "Tidak ada pull-down pada pin; 1Mohm direkomendasikan" @@ -1516,6 +1619,10 @@ msgstr "Parity ganjil tidak didukung" msgid "Only 8 or 16 bit mono with " msgstr "Hanya 8 atau 16 bit mono dengan " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1593,8 +1700,8 @@ msgstr "" "Frekuensi PWM tidak dapat ditulis ketika variabel_frequency Salah pada " "konstruksi." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "ParallelBus belum didukung" @@ -1607,11 +1714,20 @@ msgstr "" msgid "Permission denied" msgstr "Izin ditolak" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "Pin tidak mempunya kemampuan untuk ADC (Analog Digital Converter)" @@ -1675,10 +1791,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "Pull tidak digunakan saat arah output." +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "Kesalahan DeInit RNG" @@ -1687,6 +1827,10 @@ msgstr "Kesalahan DeInit RNG" msgid "RNG Init Error" msgstr "Kesalahan Init RNG" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1694,6 +1838,7 @@ msgstr "Pembalikan RS485 ditentukan saat tidak dalam mode RS485" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "Kalibrasi RTC tidak didukung pada board ini" @@ -1702,7 +1847,7 @@ msgid "RTC is not supported on this board" msgstr "RTC tidak didukung di board ini" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "RTS/CTS/RS485 Belum didukung pada perangkat ini" @@ -1760,11 +1905,6 @@ msgstr "" msgid "SD card CSD format not supported" msgstr "" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDA atau SCL membutuhkan pull up" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1783,6 +1923,10 @@ msgstr "Kesalahan Init SPI" msgid "SPI Re-initialization error" msgstr "Kesalahan Inisialisasi ulang SPI" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "Tingkat sampel harus positif" @@ -1813,6 +1957,14 @@ msgstr "Serializer sedang digunakan" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "" @@ -1985,6 +2137,10 @@ msgstr "Kesalahan Init UART" msgid "UART Re-init error" msgstr "Kesalahan Re-init UART" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "Kesalahan penulisan UART" @@ -2048,7 +2204,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "Tipe urf nrfx tak sesuai" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2091,7 +2247,8 @@ msgstr "" "perangkat lain ditolak atau diabaikan." #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "Baudrate tidak didukung" @@ -2143,6 +2300,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "PERINGATAN: Nama file kode anda mempunyai dua ekstensi\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2355,7 +2513,7 @@ msgstr "" msgid "buffer too small" msgstr "" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -3343,6 +3501,10 @@ msgstr "" msgid "number of points must be at least 2" msgstr "" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "" @@ -3528,6 +3690,7 @@ msgstr "" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3545,6 +3708,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "antrian meluap (overflow)" @@ -3738,12 +3909,17 @@ msgstr "sintaksis error pada pendeskripsi uctypes" msgid "threshold must be in the range 0-65536" msgstr "" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" @@ -3959,6 +4135,10 @@ msgstr "" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "" @@ -4023,6 +4203,12 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDA atau SCL membutuhkan pull up" + +#~ msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +#~ msgstr "pin alamat %d dan pin rgb %d menunjukkan tinggi %d, bukan %d" + #~ msgid "" #~ "\n" #~ "Code done running. Waiting for reload.\n" diff --git a/locale/circuitpython.pot b/locale/circuitpython.pot index 434684e13..529bc6d52 100644 --- a/locale/circuitpython.pot +++ b/locale/circuitpython.pot @@ -43,6 +43,10 @@ msgstr "" msgid " File \"%q\", line %d" msgstr "" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr "" @@ -54,7 +58,8 @@ msgstr "" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c @@ -334,6 +339,10 @@ msgstr "" msgid "All event channels in use" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "" @@ -382,6 +391,7 @@ msgstr "" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "" @@ -512,7 +522,6 @@ msgstr "" msgid "Buffer must be a multiple of 512 bytes" msgstr "" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "" @@ -527,6 +536,7 @@ msgid "Buffer too short by %d bytes" msgstr "" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -581,6 +591,7 @@ msgstr "" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "" @@ -618,6 +629,10 @@ msgstr "" msgid "Cannot reset into bootloader because no bootloader is present." msgstr "" +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "" @@ -796,6 +811,10 @@ msgstr "" msgid "Data 0 pin must be byte aligned" msgstr "" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "" @@ -850,7 +869,12 @@ msgstr "" msgid "Error in regex" msgstr "" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -904,7 +928,7 @@ msgstr "" msgid "FFT is implemented for linear arrays only" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "" @@ -1032,6 +1056,10 @@ msgstr "" msgid "I2C Init Error" msgstr "" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "" @@ -1055,6 +1083,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "" @@ -1067,6 +1099,31 @@ msgstr "" msgid "Input/output error" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "" @@ -1118,7 +1175,7 @@ msgstr "" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "" @@ -1212,6 +1269,8 @@ msgstr "" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "" @@ -1240,6 +1299,10 @@ msgstr "" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1321,6 +1384,36 @@ msgstr "" msgid "Missing MISO or MOSI Pin" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "" @@ -1374,14 +1467,14 @@ msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "" @@ -1438,6 +1531,16 @@ msgstr "" msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "" @@ -1493,6 +1596,10 @@ msgstr "" msgid "Only 8 or 16 bit mono with " msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1564,8 +1671,8 @@ msgid "" "PWM frequency not writable when variable_frequency is False on construction." msgstr "" -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "" @@ -1578,11 +1685,20 @@ msgstr "" msgid "Permission denied" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "" @@ -1643,10 +1759,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "" +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "" @@ -1655,6 +1795,10 @@ msgstr "" msgid "RNG Init Error" msgstr "" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1662,6 +1806,7 @@ msgstr "" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "" @@ -1670,7 +1815,7 @@ msgid "RTC is not supported on this board" msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "" @@ -1727,11 +1872,6 @@ msgstr "" msgid "SD card CSD format not supported" msgstr "" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1750,6 +1890,10 @@ msgstr "" msgid "SPI Re-initialization error" msgstr "" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "" @@ -1780,6 +1924,14 @@ msgstr "" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "" @@ -1944,6 +2096,10 @@ msgstr "" msgid "UART Re-init error" msgstr "" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "" @@ -2007,7 +2163,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2048,7 +2204,8 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "" @@ -2099,6 +2256,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2304,7 +2462,7 @@ msgstr "" msgid "buffer too small" msgstr "" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -3292,6 +3450,10 @@ msgstr "" msgid "number of points must be at least 2" msgstr "" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "" @@ -3476,6 +3638,7 @@ msgstr "" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3493,6 +3656,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "" @@ -3686,12 +3857,17 @@ msgstr "" msgid "threshold must be in the range 0-65536" msgstr "" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" @@ -3906,6 +4082,10 @@ msgstr "" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "" diff --git a/locale/cs.po b/locale/cs.po index bc5bca31f..870b82c73 100644 --- a/locale/cs.po +++ b/locale/cs.po @@ -46,6 +46,10 @@ msgstr " Soubor \"%q\"" msgid " File \"%q\", line %d" msgstr " Soubor \"%q\", řádek %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr " výstup:\n" @@ -57,8 +61,9 @@ msgstr "%%c vyžaduje int nebo char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" -msgstr "%d adresní piny a %d rgb piny označují výšku %d, nikoli %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" +msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c msgid "%q failure: %d" @@ -337,6 +342,10 @@ msgstr "" msgid "All event channels in use" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "" @@ -385,6 +394,7 @@ msgstr "" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "" @@ -515,7 +525,6 @@ msgstr "" msgid "Buffer must be a multiple of 512 bytes" msgstr "" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "" @@ -530,6 +539,7 @@ msgid "Buffer too short by %d bytes" msgstr "" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -584,6 +594,7 @@ msgstr "" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "" @@ -621,6 +632,10 @@ msgstr "" msgid "Cannot reset into bootloader because no bootloader is present." msgstr "" +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "" @@ -799,6 +814,10 @@ msgstr "" msgid "Data 0 pin must be byte aligned" msgstr "" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "" @@ -853,7 +872,12 @@ msgstr "" msgid "Error in regex" msgstr "" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -907,7 +931,7 @@ msgstr "" msgid "FFT is implemented for linear arrays only" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "" @@ -1035,6 +1059,10 @@ msgstr "" msgid "I2C Init Error" msgstr "" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "" @@ -1058,6 +1086,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "" @@ -1070,6 +1102,31 @@ msgstr "" msgid "Input/output error" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "" @@ -1121,7 +1178,7 @@ msgstr "" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "" @@ -1215,6 +1272,8 @@ msgstr "" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "" @@ -1243,6 +1302,10 @@ msgstr "" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1324,6 +1387,36 @@ msgstr "" msgid "Missing MISO or MOSI Pin" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "" @@ -1377,14 +1470,14 @@ msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "" @@ -1441,6 +1534,16 @@ msgstr "" msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "" @@ -1496,6 +1599,10 @@ msgstr "" msgid "Only 8 or 16 bit mono with " msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1567,8 +1674,8 @@ msgid "" "PWM frequency not writable when variable_frequency is False on construction." msgstr "" -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "" @@ -1581,11 +1688,20 @@ msgstr "" msgid "Permission denied" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "" @@ -1646,10 +1762,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "" +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "" @@ -1658,6 +1798,10 @@ msgstr "" msgid "RNG Init Error" msgstr "" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1665,6 +1809,7 @@ msgstr "" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "" @@ -1673,7 +1818,7 @@ msgid "RTC is not supported on this board" msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "" @@ -1730,11 +1875,6 @@ msgstr "" msgid "SD card CSD format not supported" msgstr "" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1753,6 +1893,10 @@ msgstr "" msgid "SPI Re-initialization error" msgstr "" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "" @@ -1783,6 +1927,14 @@ msgstr "" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "" @@ -1947,6 +2099,10 @@ msgstr "" msgid "UART Re-init error" msgstr "" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "" @@ -2010,7 +2166,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2051,7 +2207,8 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "" @@ -2102,6 +2259,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2307,7 +2465,7 @@ msgstr "" msgid "buffer too small" msgstr "" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -3295,6 +3453,10 @@ msgstr "" msgid "number of points must be at least 2" msgstr "" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "" @@ -3479,6 +3641,7 @@ msgstr "" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3496,6 +3659,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "" @@ -3689,12 +3860,17 @@ msgstr "" msgid "threshold must be in the range 0-65536" msgstr "" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" @@ -3909,6 +4085,10 @@ msgstr "" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "" @@ -3973,6 +4153,9 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +#~ msgstr "%d adresní piny a %d rgb piny označují výšku %d, nikoli %d" + #~ msgid "" #~ "\n" #~ "Code done running. Waiting for reload.\n" diff --git a/locale/de_DE.po b/locale/de_DE.po index 31163c141..11e743aa5 100644 --- a/locale/de_DE.po +++ b/locale/de_DE.po @@ -6,14 +6,14 @@ msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-01-04 12:55-0600\n" -"PO-Revision-Date: 2021-01-07 18:01+0000\n" -"Last-Translator: Dennis Schweer <dennis.schweer@ruhr-uni-bochum.de>\n" +"PO-Revision-Date: 2021-02-05 15:41+0000\n" +"Last-Translator: Jeff Epler <jepler@gmail.com>\n" "Language: de_DE\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 4.4.1-dev\n" +"X-Generator: Weblate 4.5-dev\n" #: main.c msgid "" @@ -47,6 +47,10 @@ msgstr " Datei \"%q\"" msgid " File \"%q\", line %d" msgstr " Datei \"%q\", Zeile %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr " Ausgabe:\n" @@ -58,8 +62,9 @@ msgstr "%%c erwartet int oder char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" -msgstr "%d Adress-Pins und %d rgb-Pins zeigen eine Höhe von %d, nicht von %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" +msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c msgid "%q failure: %d" @@ -115,7 +120,8 @@ msgstr "%q sollte ein integer sein" #: py/bc.c py/objnamedtuple.c msgid "%q() takes %d positional arguments but %d were given" -msgstr "%q() nimmt %d Argumente ohne Keyword an, aber es wurden %d angegeben" +msgstr "" +"%q() nimmt %d Argumente ohne Schlüsselwort an, aber es wurden %d angegeben" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c #, c-format @@ -230,7 +236,7 @@ msgstr "'await' außerhalb einer Funktion" #: py/compile.c msgid "'await', 'async for' or 'async with' outside async function" -msgstr "" +msgstr "'await', 'async for' oder 'async with' außerhalb einer async Funktion" #: py/compile.c msgid "'break' outside loop" @@ -262,7 +268,7 @@ msgstr "'return' außerhalb einer Funktion" #: py/compile.c msgid "'yield from' inside async function" -msgstr "" +msgstr "'yield from' innerhalb einer async Funktion" #: py/compile.c msgid "'yield' outside function" @@ -308,7 +314,7 @@ msgstr "Adresstyp außerhalb des zulässigen Bereichs" #: ports/esp32s2/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" -msgstr "" +msgstr "Alle CAN Schnittstellen sind in Benutzung" #: ports/esp32s2/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c msgid "All I2C peripherals are in use" @@ -324,7 +330,7 @@ msgstr "Alle PCNT Einheiten sind in Benutzung" #: ports/esp32s2/common-hal/canio/Listener.c #: ports/stm/common-hal/canio/Listener.c msgid "All RX FIFOs in use" -msgstr "" +msgstr "Alle RX FIFOs sind in Benutzung" #: ports/esp32s2/common-hal/busio/SPI.c ports/nrf/common-hal/busio/SPI.c msgid "All SPI peripherals are in use" @@ -338,6 +344,10 @@ msgstr "Alle UART-Peripheriegeräte sind in Benutzung" msgid "All event channels in use" msgstr "Alle event Kanäle werden benutzt" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "Alle sync event Kanäle werden benutzt" @@ -386,6 +396,7 @@ msgstr "AnalogIn ist an diesem Pin nicht unterstützt" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "AnalogOut-Funktion wird nicht unterstützt" @@ -520,7 +531,6 @@ msgstr "Die Pufferlänge muss ein vielfaches von 512 sein" msgid "Buffer must be a multiple of 512 bytes" msgstr "Der Puffer muss ein vielfaches von 512 bytes sein" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "Der Puffer muss eine Mindestenslänge von 1 haben" @@ -532,9 +542,10 @@ msgstr "Puffer zu groß und kann nicht reserviert werden" #: shared-bindings/_bleio/PacketBuffer.c #, c-format msgid "Buffer too short by %d bytes" -msgstr "Buffer um %d Bytes zu kurz" +msgstr "Puffer um %d Bytes zu kurz" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -589,6 +600,7 @@ msgstr "Kann Werte nicht löschen" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "Pull up im Ausgabemodus nicht möglich" @@ -627,6 +639,10 @@ msgstr "Kann '/' nicht remounten when USB aktiv ist." msgid "Cannot reset into bootloader because no bootloader is present." msgstr "Reset zum bootloader nicht möglich da bootloader nicht vorhanden." +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "Der Wert kann nicht gesetzt werden, wenn die Richtung input ist." @@ -680,7 +696,7 @@ msgstr "" #: supervisor/shared/safe_mode.c msgid "CircuitPython was unable to allocate the heap.\n" -msgstr "" +msgstr "CircuitPython war es nicht möglich heap-Speicher zu allozieren.\n" #: shared-module/bitbangio/SPI.c msgid "Clock pin init failed." @@ -758,7 +774,7 @@ msgstr "PWM konnte nicht neu gestartet werden" #: ports/esp32s2/common-hal/neopixel_write/__init__.c msgid "Could not retrieve clock" -msgstr "" +msgstr "Clock konnte nicht ermittelt werden" #: shared-bindings/_bleio/Adapter.c msgid "Could not set address" @@ -796,7 +812,7 @@ msgstr "Absturz in den HardFault_Handler." #: ports/stm/common-hal/analogio/AnalogOut.c msgid "DAC Channel Init Error" -msgstr "DAC Kanal Intialisierungs Fehler" +msgstr "DAC Kanal Initialisierungsfehler" #: ports/stm/common-hal/analogio/AnalogOut.c msgid "DAC Device Init Error" @@ -811,6 +827,10 @@ msgstr "DAC wird schon benutzt" msgid "Data 0 pin must be byte aligned" msgstr "Data 0 pin muss am Byte ausgerichtet sein" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "Dem fmt Block muss ein Datenblock folgen" @@ -865,7 +885,12 @@ msgstr "EXTINT Kanal ist schon in Benutzung" msgid "Error in regex" msgstr "Fehler in regex" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -920,7 +945,7 @@ msgstr "FFT ist nur für ndarrays definiert" msgid "FFT is implemented for linear arrays only" msgstr "FFT ist nur für lineare Arrays implementiert" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "SSL Handshake fehlgeschlagen" @@ -953,7 +978,7 @@ msgstr "Zuweisung des Wifi Speichers ist fehlgeschlagen" #: ports/esp32s2/common-hal/wifi/ScannedNetworks.c msgid "Failed to allocate wifi scan memory" -msgstr "" +msgstr "Zuweisung des Wifi Scan Speichers ist fehlgeschlagen" #: ports/nrf/common-hal/_bleio/Adapter.c msgid "Failed to connect: internal error" @@ -969,7 +994,7 @@ msgstr "Wifi Initialisierung ist fehlgeschlagen" #: shared-module/audiomp3/MP3Decoder.c msgid "Failed to parse MP3 file" -msgstr "Parsen der MP3 Datei fehlgeschlagen" +msgstr "MP3-Datei konnte nicht analysiert werden" #: ports/nrf/sd_mutex.c #, c-format @@ -992,7 +1017,7 @@ msgstr "Filter zu komplex" #: ports/esp32s2/common-hal/dualbank/__init__.c msgid "Firmware image is invalid" -msgstr "" +msgstr "Firmware Image ist ungültig" #: ports/cxd56/common-hal/camera/Camera.c msgid "Format not supported" @@ -1050,6 +1075,10 @@ msgstr "Lese/Schreibe-operation an geschlossener Datei" msgid "I2C Init Error" msgstr "I2C-Init-Fehler" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "I2SOut nicht verfügbar" @@ -1075,6 +1104,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "Inkorrekte Puffergröße" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "Initialisierung aufgrund von Speichermangel fehlgeschlagen" @@ -1087,6 +1120,31 @@ msgstr "" msgid "Input/output error" msgstr "Eingabe-/Ausgabefehler" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "Unzureichende Authentifizierung" @@ -1138,7 +1196,7 @@ msgstr "Ungültiger DAC-Pin angegeben" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Ungültige PWM Frequenz" @@ -1232,6 +1290,8 @@ msgstr "Ungültiger Pin für rechten Kanal" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "Ungültige Pins" @@ -1260,6 +1320,10 @@ msgstr "Ungültiger security_mode" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1343,6 +1407,36 @@ msgstr "" msgid "Missing MISO or MOSI Pin" msgstr "Fehlender MISO- oder MOSI-Pin" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "Muss eine %q Unterklasse sein." @@ -1396,14 +1490,14 @@ msgstr "Kein MOSI Pin" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Kein RX Pin" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Kein TX Pin" @@ -1460,6 +1554,16 @@ msgstr "An diesem Pin sind keine Timer mehr verfügbar." msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "Kein Pulldown Widerstand am Pin; 1Mohm wird vorgeschlagen" @@ -1517,6 +1621,10 @@ msgstr "Eine ungerade Parität wird nicht unterstützt" msgid "Only 8 or 16 bit mono with " msgstr "Nur 8 oder 16 bit mono mit " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1592,8 +1700,8 @@ msgid "" "PWM frequency not writable when variable_frequency is False on construction." msgstr "Die PWM-Frequenz ist nicht schreibbar wenn variable_Frequenz = False." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "ParallelBus wird noch nicht unterstützt" @@ -1606,11 +1714,20 @@ msgstr "" msgid "Permission denied" msgstr "Zugang verweigert" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "Pin hat keine ADC Funktionalität" @@ -1674,10 +1791,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "Pull wird nicht verwendet, wenn die Richtung output ist." +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "RNG DeInit-Fehler" @@ -1686,6 +1827,10 @@ msgstr "RNG DeInit-Fehler" msgid "RNG Init Error" msgstr "RNG Init Fehler" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1693,6 +1838,7 @@ msgstr "RS485-Inversion angegeben, wenn nicht im RS485-Modus" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "Die RTC-Kalibrierung wird auf diesem Board nicht unterstützt" @@ -1701,7 +1847,7 @@ msgid "RTC is not supported on this board" msgstr "Eine RTC wird auf diesem Board nicht unterstützt" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "RTS / CTS / RS485 Wird von diesem Gerät noch nicht unterstützt" @@ -1758,11 +1904,6 @@ msgstr "" msgid "SD card CSD format not supported" msgstr "" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDA oder SCL brauchen pull up" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1781,6 +1922,10 @@ msgstr "SPI-Init-Fehler" msgid "SPI Re-initialization error" msgstr "SPI-Neuinitialisierungsfehler" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "Abtastrate muss positiv sein" @@ -1811,6 +1956,14 @@ msgstr "Serializer wird benutzt" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "" @@ -1989,6 +2142,10 @@ msgstr "UART Init Fehler" msgid "UART Re-init error" msgstr "UART Re-Init-Fehler" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "UART-Schreibfehler" @@ -2052,7 +2209,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "Unerwarteter nrfx uuid-Typ" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2097,7 +2254,8 @@ msgstr "" "Eingabeaufforderung auf dem anderen Gerät abgelehnt oder ignoriert." #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "Baudrate wird nicht unterstützt" @@ -2149,6 +2307,7 @@ msgstr "" "WARNUNG: Der Dateiname deines Programms hat zwei Dateityperweiterungen\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2364,7 +2523,7 @@ msgstr "Puffersegmente müssen gleich lang sein" msgid "buffer too small" msgstr "Der Puffer ist zu klein" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -2745,7 +2904,7 @@ msgstr "erwarte tuple/list" #: py/modthread.c msgid "expecting a dict for keyword args" -msgstr "erwarte ein dict als Keyword-Argumente" +msgstr "erwarte ein dict als Schlüsselwort-Argumente" #: py/compile.c msgid "expecting an assembler instruction" @@ -2765,11 +2924,11 @@ msgstr "" #: py/argcheck.c msgid "extra keyword arguments given" -msgstr "Es wurden zusätzliche Keyword-Argumente angegeben" +msgstr "Es wurden zusätzliche Schlüsselwort-Argumente angegeben" #: py/argcheck.c msgid "extra positional arguments given" -msgstr "Es wurden zusätzliche Argumente ohne Keyword angegeben" +msgstr "Es wurden zusätzliche Argumente ohne Schlüsselwort angegeben" #: py/parse.c msgid "f-string expression part cannot include a '#'" @@ -2850,7 +3009,7 @@ msgstr "voll" #: py/argcheck.c msgid "function does not take keyword arguments" -msgstr "Funktion akzeptiert keine Keyword-Argumente" +msgstr "Funktion akzeptiert keine Schlüsselwort-Argumente" #: py/argcheck.c #, c-format @@ -2872,26 +3031,27 @@ msgstr "" #: py/argcheck.c #, c-format msgid "function missing %d required positional arguments" -msgstr "Funktion vermisst %d benötigte Argumente ohne Keyword" +msgstr "Funktion vermisst %d benötigte Argumente ohne Schlüsselwort" #: py/bc.c msgid "function missing keyword-only argument" -msgstr "Funktion vermisst Keyword-only-Argument" +msgstr "Funktion vermisst Nur-Schlüsselwort-Argument" #: py/bc.c msgid "function missing required keyword argument '%q'" -msgstr "Funktion vermisst benötigtes Keyword-Argumente '%q'" +msgstr "Funktion vermisst benötigtes Schlüsselwort-Argumente '%q'" #: py/bc.c #, c-format msgid "function missing required positional argument #%d" -msgstr "Funktion vermisst benötigtes Argumente ohne Keyword #%d" +msgstr "Funktion vermisst benötigtes Argumente ohne Schlüsselwort #%d" #: py/argcheck.c py/bc.c py/objnamedtuple.c shared-bindings/time/__init__.c #, c-format msgid "function takes %d positional arguments but %d were given" msgstr "" -"Funktion nimmt %d Argumente ohne Keyword an, aber es wurden %d angegeben" +"Funktion nimmt %d Argumente ohne Schlüsselwort an, aber es wurden %d " +"angegeben" #: shared-bindings/time/__init__.c msgid "function takes exactly 9 arguments" @@ -3121,8 +3281,8 @@ msgstr "" #: py/argcheck.c msgid "keyword argument(s) not yet implemented - use normal args instead" msgstr "" -"Keyword-Argument(e) noch nicht implementiert - verwenden Sie stattdessen " -"normale Argumente" +"Schlüsselwort-Argument(e) noch nicht implementiert - verwenden Sie " +"stattdessen normale Argumente" #: py/bc.c msgid "keywords must be strings" @@ -3372,6 +3532,10 @@ msgstr "Nicht genügend Argumente für den Formatierungs-String" msgid "number of points must be at least 2" msgstr "Die Anzahl der Punkte muss mindestens 2 betragen" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "" @@ -3559,6 +3723,7 @@ msgstr "pow () mit 3 Argumenten erfordert Integer" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3576,6 +3741,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "Warteschlangenüberlauf" @@ -3772,12 +3945,17 @@ msgstr "Syntaxfehler in uctypes Deskriptor" msgid "threshold must be in the range 0-65536" msgstr "threshold muss im Intervall 0-65536 liegen" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "time.struct_time() nimmt eine 9-Sequenz an" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "Das Zeitlimit hat den maximal zulässigen Wert überschritten" @@ -3894,11 +4072,11 @@ msgstr "" #: py/bc.c msgid "unexpected keyword argument" -msgstr "unerwartetes Keyword-Argument" +msgstr "unerwartetes Schlüsselwort-Argument" #: py/bc.c py/objnamedtuple.c msgid "unexpected keyword argument '%q'" -msgstr "unerwartetes Keyword-Argument '%q'" +msgstr "unerwartetes Schlüsselwort-Argument '%q'" #: py/lexer.c msgid "unicode name escapes" @@ -3996,6 +4174,10 @@ msgstr "" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "Fenster muss <= Intervall sein" @@ -4060,6 +4242,13 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDA oder SCL brauchen pull up" + +#~ msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +#~ msgstr "" +#~ "%d Adress-Pins und %d rgb-Pins zeigen eine Höhe von %d, nicht von %d" + #~ msgid "input argument must be an integer or a 2-tuple" #~ msgstr "Das Eingabeargument muss eine Ganzzahl oder ein 2-Tupel sein" diff --git a/locale/el.po b/locale/el.po index 0a56d4748..fe281db4e 100644 --- a/locale/el.po +++ b/locale/el.po @@ -43,6 +43,10 @@ msgstr "" msgid " File \"%q\", line %d" msgstr "" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr "" @@ -54,7 +58,8 @@ msgstr "" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c @@ -334,6 +339,10 @@ msgstr "" msgid "All event channels in use" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "" @@ -382,6 +391,7 @@ msgstr "" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "" @@ -512,7 +522,6 @@ msgstr "" msgid "Buffer must be a multiple of 512 bytes" msgstr "" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "" @@ -527,6 +536,7 @@ msgid "Buffer too short by %d bytes" msgstr "" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -581,6 +591,7 @@ msgstr "" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "" @@ -618,6 +629,10 @@ msgstr "" msgid "Cannot reset into bootloader because no bootloader is present." msgstr "" +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "" @@ -796,6 +811,10 @@ msgstr "" msgid "Data 0 pin must be byte aligned" msgstr "" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "" @@ -850,7 +869,12 @@ msgstr "" msgid "Error in regex" msgstr "" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -904,7 +928,7 @@ msgstr "" msgid "FFT is implemented for linear arrays only" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "" @@ -1032,6 +1056,10 @@ msgstr "" msgid "I2C Init Error" msgstr "" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "" @@ -1055,6 +1083,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "" @@ -1067,6 +1099,31 @@ msgstr "" msgid "Input/output error" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "" @@ -1118,7 +1175,7 @@ msgstr "" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "" @@ -1212,6 +1269,8 @@ msgstr "" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "" @@ -1240,6 +1299,10 @@ msgstr "" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1321,6 +1384,36 @@ msgstr "" msgid "Missing MISO or MOSI Pin" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "" @@ -1374,14 +1467,14 @@ msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "" @@ -1438,6 +1531,16 @@ msgstr "" msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "" @@ -1493,6 +1596,10 @@ msgstr "" msgid "Only 8 or 16 bit mono with " msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1564,8 +1671,8 @@ msgid "" "PWM frequency not writable when variable_frequency is False on construction." msgstr "" -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "" @@ -1578,11 +1685,20 @@ msgstr "" msgid "Permission denied" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "" @@ -1643,10 +1759,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "" +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "" @@ -1655,6 +1795,10 @@ msgstr "" msgid "RNG Init Error" msgstr "" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1662,6 +1806,7 @@ msgstr "" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "" @@ -1670,7 +1815,7 @@ msgid "RTC is not supported on this board" msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "" @@ -1727,11 +1872,6 @@ msgstr "" msgid "SD card CSD format not supported" msgstr "" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1750,6 +1890,10 @@ msgstr "" msgid "SPI Re-initialization error" msgstr "" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "" @@ -1780,6 +1924,14 @@ msgstr "" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "" @@ -1944,6 +2096,10 @@ msgstr "" msgid "UART Re-init error" msgstr "" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "" @@ -2007,7 +2163,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2048,7 +2204,8 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "" @@ -2099,6 +2256,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2304,7 +2462,7 @@ msgstr "" msgid "buffer too small" msgstr "" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -3292,6 +3450,10 @@ msgstr "" msgid "number of points must be at least 2" msgstr "" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "" @@ -3476,6 +3638,7 @@ msgstr "" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3493,6 +3656,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "" @@ -3686,12 +3857,17 @@ msgstr "" msgid "threshold must be in the range 0-65536" msgstr "" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" @@ -3906,6 +4082,10 @@ msgstr "" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "" diff --git a/locale/es.po b/locale/es.po index 63ec6d012..0a02df3b5 100644 --- a/locale/es.po +++ b/locale/es.po @@ -48,6 +48,10 @@ msgstr " Archivo \"%q\"" msgid " File \"%q\", line %d" msgstr " Archivo \"%q\", línea %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr " salida:\n" @@ -59,9 +63,9 @@ msgstr "%%c requiere int o char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" -"%d pines de dirección y %d pines rgb indican una altura de %d, no de %d" #: ports/atmel-samd/common-hal/sdioio/SDCard.c msgid "%q failure: %d" @@ -340,6 +344,10 @@ msgstr "Todos los periféricos UART están siendo usados" msgid "All event channels in use" msgstr "Todos los canales de eventos estan siendo usados" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "" @@ -390,6 +398,7 @@ msgstr "El pin proporcionado no soporta AnalogIn" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "Funcionalidad AnalogOut no soportada" @@ -524,7 +533,6 @@ msgstr "El tamaño del búfer debe ser múltiplo de 512" msgid "Buffer must be a multiple of 512 bytes" msgstr "Búfer deber ser un múltiplo de 512 bytes" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "Buffer debe ser de longitud 1 como minimo" @@ -539,6 +547,7 @@ msgid "Buffer too short by %d bytes" msgstr "Búffer muy corto por %d bytes" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -593,6 +602,7 @@ msgstr "No se puede eliminar valores" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "No puede ser pull mientras este en modo de salida" @@ -632,6 +642,10 @@ msgstr "No se puede volver a montar '/' cuando el USB esta activo." msgid "Cannot reset into bootloader because no bootloader is present." msgstr "No se puede reiniciar a bootloader porque no hay bootloader presente." +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "No se puede asignar un valor cuando la dirección es input." @@ -814,6 +828,10 @@ msgstr "DAC ya está siendo utilizado" msgid "Data 0 pin must be byte aligned" msgstr "El pin Data 0 debe estar alineado a bytes" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "Trozo de datos debe seguir fmt chunk" @@ -868,7 +886,12 @@ msgstr "El canal EXTINT ya está siendo utilizado" msgid "Error in regex" msgstr "Error en regex" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -922,7 +945,7 @@ msgstr "FFT se define solo para ndarrays" msgid "FFT is implemented for linear arrays only" msgstr "FFT solo esta implementado para arrays lineales" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "Fallo en saludo SSL" @@ -1051,6 +1074,10 @@ msgstr "Operación I/O en archivo cerrado" msgid "I2C Init Error" msgstr "I2C Error de inicio" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "I2SOut no disponible" @@ -1076,6 +1103,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "Tamaño incorrecto del buffer" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "Inicializacion fallida por falta de memoria" @@ -1088,6 +1119,31 @@ msgstr "La entrada está durando mucho tiempo" msgid "Input/output error" msgstr "error Input/output" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "Autenticación insuficiente" @@ -1139,7 +1195,7 @@ msgstr "Pin suministrado inválido para DAC" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Frecuencia PWM inválida" @@ -1233,6 +1289,8 @@ msgstr "Pin inválido para canal derecho" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "pines inválidos" @@ -1261,6 +1319,10 @@ msgstr "'security_mode' no válido" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1342,6 +1404,36 @@ msgstr "Micrófono demora de inicio debe estar en el rango 0.0 a 1.0" msgid "Missing MISO or MOSI Pin" msgstr "Falta el pin MISO o MOSI" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "Debe de ser una subclase de %q." @@ -1395,14 +1487,14 @@ msgstr "Sin pin MOSI" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Sin pin RX" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Sin pin TX" @@ -1459,6 +1551,16 @@ msgstr "No hay más temporizadores disponibles en este pin." msgid "No network with that ssid" msgstr "No hay una red con ese ssid" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "No hay pulldown en el pin; 1Mohm recomendado" @@ -1516,6 +1618,10 @@ msgstr "Paridad impar no soportada" msgid "Only 8 or 16 bit mono with " msgstr "Solo mono de 8 ó 16 bit con " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "Solo hay capacidad para direcciones IPv4" @@ -1593,8 +1699,8 @@ msgstr "" "La frecuencia de PWM no se puede escribir variable_frequency es False en la " "construcción." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "ParallelBus todavía no soportado" @@ -1607,11 +1713,20 @@ msgstr "" msgid "Permission denied" msgstr "Permiso denegado" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "Pin no tiene capacidad ADC" @@ -1679,10 +1794,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "Pull no se usa cuando la dirección es output." +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "Error de desinicialización de RNG" @@ -1691,6 +1830,10 @@ msgstr "Error de desinicialización de RNG" msgid "RNG Init Error" msgstr "Error de inicialización de RNG" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1698,6 +1841,7 @@ msgstr "Se especifica inversión de RS485 si no está en modo RS485" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "Calibración de RTC no es soportada en esta placa" @@ -1706,7 +1850,7 @@ msgid "RTC is not supported on this board" msgstr "RTC no soportado en esta placa" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "Sin capacidad de RTS/CTS/RS485 para este dispositivo" @@ -1763,11 +1907,6 @@ msgstr "¡Corriendo en modo seguro! " msgid "SD card CSD format not supported" msgstr "Sin capacidad para formato CSD para tarjeta SD" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDA o SCL necesitan una pull up" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1786,6 +1925,10 @@ msgstr "Error de inicio de SPI" msgid "SPI Re-initialization error" msgstr "Error de reinicialización de SPI" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "Sample rate debe ser positivo" @@ -1816,6 +1959,14 @@ msgstr "Serializer está siendo utilizado" msgid "Server side context cannot have hostname" msgstr "El contexto del lado del servidor no puede tener un hostname" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "Sin capacidades para el tamaño" @@ -1994,6 +2145,10 @@ msgstr "Error de inicialización de UART" msgid "UART Re-init error" msgstr "Error de reinicialización de UART" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "Error de escritura UART" @@ -2057,7 +2212,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "Tipo de uuid nrfx inesperado" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "Error no manejado de ESP TLS %d %d %x %d" @@ -2100,7 +2255,8 @@ msgstr "" "dispositivo fue denegada o ignorada." #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "Baudrate no soportado" @@ -2151,6 +2307,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "ADVERTENCIA: El nombre de archivo de tu código tiene dos extensiones\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" "WatchDogTimer no se puede desinicializar luego de definirse en modo RESET" @@ -2365,7 +2522,7 @@ msgstr "Las secciones del buffer necesitan tener longitud igual" msgid "buffer too small" msgstr "buffer demasiado pequeño" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "búfer muy pequeño para los bytes solicitados" @@ -3366,6 +3523,10 @@ msgstr "no suficientes argumentos para format string" msgid "number of points must be at least 2" msgstr "el número de puntos debe ser al menos 2" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "objeto '%q' no es tupla o lista" @@ -3550,6 +3711,7 @@ msgstr "pow() con 3 argumentos requiere enteros" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3567,6 +3729,14 @@ msgstr "presionando botón de arranque al inicio.\n" msgid "pressing both buttons at start up.\n" msgstr "presionando ambos botones al inicio.\n" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "desbordamiento de cola(queue)" @@ -3762,12 +3932,17 @@ msgstr "error de sintaxis en el descriptor uctypes" msgid "threshold must be in the range 0-65536" msgstr "limite debe ser en el rango 0-65536" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "time.struct_time() toma un sequencio 9" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" "la duración de tiempo de espera ha excedido la capacidad máxima del valor" @@ -3983,6 +4158,10 @@ msgstr "el tiempo de espera del perro guardián debe ser mayor a 0" msgid "width must be greater than zero" msgstr "el ancho debe ser mayor que cero" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "la ventana debe ser <= intervalo" @@ -4047,6 +4226,13 @@ msgstr "zi debe ser de tipo flotante" msgid "zi must be of shape (n_section, 2)" msgstr "zi debe ser una forma (n_section,2)" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDA o SCL necesitan una pull up" + +#~ msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +#~ msgstr "" +#~ "%d pines de dirección y %d pines rgb indican una altura de %d, no de %d" + #~ msgid "Unknown failure" #~ msgstr "Fallo desconocido" diff --git a/locale/fil.po b/locale/fil.po index 9b635da18..71d5ef8f1 100644 --- a/locale/fil.po +++ b/locale/fil.po @@ -42,6 +42,10 @@ msgstr " File \"%q\"" msgid " File \"%q\", line %d" msgstr " File \"%q\", line %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr " output:\n" @@ -53,7 +57,8 @@ msgstr "%%c nangangailangan ng int o char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c @@ -337,6 +342,10 @@ msgstr "Lahat ng I2C peripherals ginagamit" msgid "All event channels in use" msgstr "Lahat ng event channels ginagamit" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "Lahat ng sync event channels ay ginagamit" @@ -385,6 +394,7 @@ msgstr "" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "Hindi supportado ang AnalogOut" @@ -517,7 +527,6 @@ msgstr "" msgid "Buffer must be a multiple of 512 bytes" msgstr "" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "Buffer dapat ay hindi baba sa 1 na haba" @@ -532,6 +541,7 @@ msgid "Buffer too short by %d bytes" msgstr "" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, fuzzy, c-format msgid "Bus pin %d is already in use" @@ -587,6 +597,7 @@ msgstr "Hindi mabura ang values" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "Hindi makakakuha ng pull habang nasa output mode" @@ -625,6 +636,10 @@ msgstr "Hindi ma-remount '/' kapag aktibo ang USB." msgid "Cannot reset into bootloader because no bootloader is present." msgstr "Hindi ma-reset sa bootloader dahil walang bootloader." +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "Hindi ma i-set ang value kapag ang direksyon ay input." @@ -805,6 +820,10 @@ msgstr "Ginagamit na ang DAC" msgid "Data 0 pin must be byte aligned" msgstr "graphic ay dapat 2048 bytes ang haba" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "Dapat sunurin ng Data chunk ang fmt chunk" @@ -861,7 +880,12 @@ msgstr "Ginagamit na ang EXTINT channel" msgid "Error in regex" msgstr "May pagkakamali sa REGEX" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -917,7 +941,7 @@ msgstr "" msgid "FFT is implemented for linear arrays only" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "" @@ -1045,6 +1069,10 @@ msgstr "I/O operasyon sa saradong file" msgid "I2C Init Error" msgstr "" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "" @@ -1070,6 +1098,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "" @@ -1082,6 +1114,31 @@ msgstr "" msgid "Input/output error" msgstr "May mali sa Input/Output" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "" @@ -1133,7 +1190,7 @@ msgstr "" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Mali ang PWM frequency" @@ -1227,6 +1284,8 @@ msgstr "Mali ang pin para sa kanang channel" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "Mali ang pins" @@ -1255,6 +1314,10 @@ msgstr "" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1336,6 +1399,36 @@ msgstr "Ang delay ng startup ng mikropono ay dapat na nasa 0.0 hanggang 1.0" msgid "Missing MISO or MOSI Pin" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "" @@ -1389,14 +1482,14 @@ msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Walang RX pin" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Walang TX pin" @@ -1453,6 +1546,16 @@ msgstr "" msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "" @@ -1511,6 +1614,10 @@ msgstr "Odd na parity ay hindi supportado" msgid "Only 8 or 16 bit mono with " msgstr "Tanging 8 o 16 na bit mono na may " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1583,8 +1690,8 @@ msgid "" msgstr "" "PWM frequency hindi writable kapag variable_frequency ay False sa pag buo." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "" @@ -1597,11 +1704,20 @@ msgstr "" msgid "Permission denied" msgstr "Walang pahintulot" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "Ang pin ay walang kakayahan sa ADC" @@ -1662,10 +1778,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "Pull hindi ginagamit kapag ang direksyon ay output." +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "" @@ -1674,6 +1814,10 @@ msgstr "" msgid "RNG Init Error" msgstr "" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1681,6 +1825,7 @@ msgstr "" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "RTC calibration ay hindi supportado ng board na ito" @@ -1689,7 +1834,7 @@ msgid "RTC is not supported on this board" msgstr "Hindi supportado ang RTC sa board na ito" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "" @@ -1747,11 +1892,6 @@ msgstr "" msgid "SD card CSD format not supported" msgstr "" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "Kailangan ng pull up resistors ang SDA o SCL" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1770,6 +1910,10 @@ msgstr "" msgid "SPI Re-initialization error" msgstr "" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "Sample rate ay dapat positibo" @@ -1800,6 +1944,14 @@ msgstr "Serializer ginagamit" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "" @@ -1964,6 +2116,10 @@ msgstr "" msgid "UART Re-init error" msgstr "" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "" @@ -2028,7 +2184,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "hindi inaasahang indent" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2069,7 +2225,8 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "Hindi supportadong baudrate" @@ -2123,6 +2280,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "BABALA: Ang pangalan ng file ay may dalawang extension\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2335,7 +2493,7 @@ msgstr "aarehas na haba dapat ang buffer slices" msgid "buffer too small" msgstr "masyadong maliit ang buffer" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -3339,6 +3497,10 @@ msgstr "kulang sa arguments para sa format string" msgid "number of points must be at least 2" msgstr "" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "" @@ -3525,6 +3687,7 @@ msgstr "pow() na may 3 argumento kailangan ng integers" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3542,6 +3705,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "puno na ang pila (overflow)" @@ -3738,12 +3909,17 @@ msgstr "may pagkakamali sa sintaks sa uctypes descriptor" msgid "threshold must be in the range 0-65536" msgstr "ang threshold ay dapat sa range 0-65536" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "time.struct_time() kumukuha ng 9-sequence" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" @@ -3959,6 +4135,10 @@ msgstr "" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "" @@ -4025,6 +4205,9 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "Kailangan ng pull up resistors ang SDA o SCL" + #~ msgid "tuple index out of range" #~ msgstr "indeks ng tuple wala sa sakop" diff --git a/locale/fr.po b/locale/fr.po index eccfcc1a0..895c87f5e 100644 --- a/locale/fr.po +++ b/locale/fr.po @@ -8,8 +8,8 @@ msgstr "" "Project-Id-Version: 0.1\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-01-04 12:55-0600\n" -"PO-Revision-Date: 2021-01-17 12:55+0000\n" -"Last-Translator: Hugo Dahl <hugo@code-jedi.com>\n" +"PO-Revision-Date: 2021-01-30 02:32+0000\n" +"Last-Translator: Antonin ENFRUN <antonin.e@me.com>\n" "Language: fr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=utf-8\n" @@ -52,6 +52,10 @@ msgstr " Fichier \"%q\"" msgid " File \"%q\", line %d" msgstr " Fichier \"%q\", ligne %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr " est de type %q\n" + #: main.c msgid " output:\n" msgstr " sortie :\n" @@ -63,10 +67,11 @@ msgstr "%%c nécessite un chiffre entier 'int' ou un caractère 'char'" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" -"Les broches d'adresse %d et les broches RVB %d indiquent une hauteur de %d, " -"pas %d" +"%d broches d'adresse, %d broches RGB et %d pour tile indique une hauteur de " +"%d, et non %d" #: ports/atmel-samd/common-hal/sdioio/SDCard.c msgid "%q failure: %d" @@ -345,6 +350,10 @@ msgstr "Tous les périphériques UART sont utilisés" msgid "All event channels in use" msgstr "Tous les canaux d'événements sont utilisés" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "Tous les canaux d'événements sync (sync event channels) sont utilisés" @@ -393,6 +402,7 @@ msgstr "'AnalogOut' n'est pas supporté sur la broche indiquée" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "Fonctionnalité AnalogOut non supportée" @@ -529,7 +539,6 @@ msgstr "La longueur de la mémoire tampon doit être un multiple de 512" msgid "Buffer must be a multiple of 512 bytes" msgstr "La mémoire tampon doit être un multiple de 512" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "Le tampon doit être de longueur au moins 1" @@ -544,6 +553,7 @@ msgid "Buffer too short by %d bytes" msgstr "Tampon trop court de %d octets" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -603,6 +613,7 @@ msgstr "Impossible de supprimer les valeurs" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "Ne peut être tiré ('pull') en mode sortie ('output')" @@ -643,6 +654,10 @@ msgid "Cannot reset into bootloader because no bootloader is present." msgstr "" "Ne peut être redémarré vers le bootloader car il n'y a pas de bootloader." +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "" @@ -827,6 +842,10 @@ msgstr "DAC déjà utilisé" msgid "Data 0 pin must be byte aligned" msgstr "La broche 'Data 0' doit être aligné sur l'octet" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "La broche Data 0 doit être aligné sur l'octet." + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "Un bloc de données doit suivre un bloc fmt" @@ -882,7 +901,12 @@ msgstr "Canal EXTINT déjà utilisé" msgid "Error in regex" msgstr "Erreur dans l'expression régulière" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "Erreur : Impossible de lier" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -937,7 +961,7 @@ msgstr "La FFT est définie uniquement pour les ndarrays" msgid "FFT is implemented for linear arrays only" msgstr "FFT n'est implémenté que pour les tableaux linéaires" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "Échec du handshake SSL" @@ -1067,6 +1091,10 @@ msgstr "Opération d'E/S sur un fichier fermé" msgid "I2C Init Error" msgstr "Erreur d'initialisation I2C" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "I2SOut n'est pas disponible" @@ -1092,6 +1120,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "Taille de tampon incorrecte" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "Échec d'initialisation par manque de mémoire" @@ -1104,6 +1136,31 @@ msgstr "L'entrée prend trop de temps" msgid "Input/output error" msgstr "Erreur d'entrée/sortie" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "Authentification insuffisante" @@ -1155,7 +1212,7 @@ msgstr "Broche DAC non valide fournie" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Fréquence de PWM invalide" @@ -1249,6 +1306,8 @@ msgstr "Broche invalide pour le canal droit" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "Broches invalides" @@ -1277,6 +1336,10 @@ msgstr "'security_mode' invalide" msgid "Invalid size" msgstr "Taille invalide" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "Socket non valide pour TLS" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "État invalide" @@ -1358,6 +1421,36 @@ msgstr "Le délais au démarrage du micro doit être entre 0.0 et 1.0" msgid "Missing MISO or MOSI Pin" msgstr "Broche MISO ou MOSI manquante" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "Doit être une sous-classe de %q." @@ -1411,14 +1504,14 @@ msgstr "Pas de broche MOSI" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Pas de broche RX" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Pas de broche TX" @@ -1475,6 +1568,16 @@ msgstr "Plus de minuteurs disponibles sur cette broche." msgid "No network with that ssid" msgstr "Aucun réseau avec ce ssid" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "Pas de pulldown sur la broche ; 1Mohm recommandé" @@ -1532,6 +1635,10 @@ msgstr "Parité impaire non supportée" msgid "Only 8 or 16 bit mono with " msgstr "Uniquement 8 ou 16 bit mono avec " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "Seulement les adresses IPv4 sont supportées" @@ -1611,8 +1718,8 @@ msgstr "" "La fréquence de PWM n'est pas modifiable quand variable_frequency est False " "à la construction." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "ParallelBus pas encore supporté" @@ -1625,11 +1732,20 @@ msgstr "Périphérique en utilisation" msgid "Permission denied" msgstr "Permission refusée" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "La broche 'pin' ne supporte pas les capacitées ADC" @@ -1700,10 +1816,34 @@ msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" "Feinte de someil profond jusqu'à l'alarme, CTRL-C ou écriture au fichier.\n" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "Le tirage 'pull' n'est pas utilisé quand la direction est 'output'." +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "Erreur de désinitiation du RNG (RNG DeInit)" @@ -1712,6 +1852,10 @@ msgstr "Erreur de désinitiation du RNG (RNG DeInit)" msgid "RNG Init Error" msgstr "Erreur d'initialisation du RNG (RNG Init)" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1719,6 +1863,7 @@ msgstr "Inversion RS485 spécifiée sans être en mode RS485" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "La calibration du RTC non supportée sur cette carte" @@ -1727,7 +1872,7 @@ msgid "RTC is not supported on this board" msgstr "RTC non supporté sur cette carte" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "RTS / CTS / RS485 Pas encore supporté sur cet appareil" @@ -1784,11 +1929,6 @@ msgstr "Exécution en mode sécurisé! " msgid "SD card CSD format not supported" msgstr "Le format de carte SD CSD n'est pas supporté" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDA ou SCL a besoin d'une résistance de tirage ('pull up')" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1807,6 +1947,10 @@ msgstr "Erreur d'initialisation SPI" msgid "SPI Re-initialization error" msgstr "Erreur de réinitialisation SPI" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "Le taux d'échantillonage doit être positif" @@ -1837,6 +1981,14 @@ msgstr "Sérialiseur en cours d'utilisation" msgid "Server side context cannot have hostname" msgstr "Un contexte niveau serveur ne peut avoir de hostname" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "Taille n'est pas supportée" @@ -2013,6 +2165,10 @@ msgstr "Erreur d'initialisation UART" msgid "UART Re-init error" msgstr "Erreur de réinitialisation UART" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "Erreur d'écriture UART" @@ -2079,7 +2235,7 @@ msgstr "Écriture impossible vers sleep_memory." msgid "Unexpected nrfx uuid type" msgstr "Type inattendu pour l'uuid nrfx" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "Erreur ESP TLS non gérée %d %d %x %d" @@ -2123,7 +2279,8 @@ msgstr "" "appareil ait été refusée ou ignorée." #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "Débit en bauds non supporté" @@ -2175,6 +2332,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "ATTENTION : le nom de fichier de votre code a deux extensions\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" "WatchDogTimer ne peut pas être désinitialisé une fois que le mode est réglé " @@ -2389,7 +2547,7 @@ msgstr "les tranches de tampon doivent être de longueurs égales" msgid "buffer too small" msgstr "tampon trop petit" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "tampon trop petit pour le nombre d'octets demandé" @@ -3399,6 +3557,10 @@ msgstr "pas assez d'arguments pour la chaîne de format" msgid "number of points must be at least 2" msgstr "le nombre de points doit être d'au moins 2" +#: py/builtinhelp.c +msgid "object " +msgstr "objet " + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "l'objet '%q' n'est pas un tuple ou une list" @@ -3586,6 +3748,7 @@ msgstr "pow() avec 3 arguments nécessite des entiers" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3603,6 +3766,14 @@ msgstr "bouton boot appuyé lors du démarrage.\n" msgid "pressing both buttons at start up.\n" msgstr "les deux boutons appuyés lors du démarrage.\n" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "dépassement de file" @@ -3799,12 +3970,17 @@ msgstr "erreur de syntaxe dans le descripteur d'uctypes" msgid "threshold must be in the range 0-65536" msgstr "le seuil doit être dans la portée 0-65536" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "tile doit être plus que zéro" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "time.struct_time() prend une séquence de longueur 9" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "le délai d'expiration a dépassé la valeur maximale prise en charge" @@ -4017,7 +4193,11 @@ msgstr "watchdog timeout doit être supérieur à 0" #: shared-bindings/rgbmatrix/RGBMatrix.c msgid "width must be greater than zero" -msgstr "width doit être plus grand que zero" +msgstr "width doit être plus que zero" + +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "wifi n’est pas activé" #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" @@ -4083,6 +4263,20 @@ msgstr "zi doit être de type float" msgid "zi must be of shape (n_section, 2)" msgstr "zi doit être de forme (n_section, 2)" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDA ou SCL a besoin d'une résistance de tirage ('pull up')" + +#~ msgid "Invalid use of TLS Socket" +#~ msgstr "Utilisation incorrecte de socket TLS" + +#~ msgid "Issue setting SO_REUSEADDR" +#~ msgstr "Problème en activant SO_REUSEADDR" + +#~ msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +#~ msgstr "" +#~ "Les broches d'adresse %d et les broches RVB %d indiquent une hauteur de " +#~ "%d, pas %d" + #~ msgid "Unknown failure" #~ msgstr "Echec inconnu" diff --git a/locale/hi.po b/locale/hi.po index 4dfb35b36..fe7782133 100644 --- a/locale/hi.po +++ b/locale/hi.po @@ -43,6 +43,10 @@ msgstr "" msgid " File \"%q\", line %d" msgstr "" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr "" @@ -54,7 +58,8 @@ msgstr "" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c @@ -334,6 +339,10 @@ msgstr "" msgid "All event channels in use" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "" @@ -382,6 +391,7 @@ msgstr "" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "" @@ -512,7 +522,6 @@ msgstr "" msgid "Buffer must be a multiple of 512 bytes" msgstr "" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "" @@ -527,6 +536,7 @@ msgid "Buffer too short by %d bytes" msgstr "" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -581,6 +591,7 @@ msgstr "" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "" @@ -618,6 +629,10 @@ msgstr "" msgid "Cannot reset into bootloader because no bootloader is present." msgstr "" +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "" @@ -796,6 +811,10 @@ msgstr "" msgid "Data 0 pin must be byte aligned" msgstr "" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "" @@ -850,7 +869,12 @@ msgstr "" msgid "Error in regex" msgstr "" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -904,7 +928,7 @@ msgstr "" msgid "FFT is implemented for linear arrays only" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "" @@ -1032,6 +1056,10 @@ msgstr "" msgid "I2C Init Error" msgstr "" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "" @@ -1055,6 +1083,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "" @@ -1067,6 +1099,31 @@ msgstr "" msgid "Input/output error" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "" @@ -1118,7 +1175,7 @@ msgstr "" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "" @@ -1212,6 +1269,8 @@ msgstr "" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "" @@ -1240,6 +1299,10 @@ msgstr "" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1321,6 +1384,36 @@ msgstr "" msgid "Missing MISO or MOSI Pin" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "" @@ -1374,14 +1467,14 @@ msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "" @@ -1438,6 +1531,16 @@ msgstr "" msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "" @@ -1493,6 +1596,10 @@ msgstr "" msgid "Only 8 or 16 bit mono with " msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1564,8 +1671,8 @@ msgid "" "PWM frequency not writable when variable_frequency is False on construction." msgstr "" -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "" @@ -1578,11 +1685,20 @@ msgstr "" msgid "Permission denied" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "" @@ -1643,10 +1759,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "" +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "" @@ -1655,6 +1795,10 @@ msgstr "" msgid "RNG Init Error" msgstr "" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1662,6 +1806,7 @@ msgstr "" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "" @@ -1670,7 +1815,7 @@ msgid "RTC is not supported on this board" msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "" @@ -1727,11 +1872,6 @@ msgstr "" msgid "SD card CSD format not supported" msgstr "" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1750,6 +1890,10 @@ msgstr "" msgid "SPI Re-initialization error" msgstr "" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "" @@ -1780,6 +1924,14 @@ msgstr "" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "" @@ -1944,6 +2096,10 @@ msgstr "" msgid "UART Re-init error" msgstr "" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "" @@ -2007,7 +2163,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2048,7 +2204,8 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "" @@ -2099,6 +2256,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2304,7 +2462,7 @@ msgstr "" msgid "buffer too small" msgstr "" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -3292,6 +3450,10 @@ msgstr "" msgid "number of points must be at least 2" msgstr "" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "" @@ -3476,6 +3638,7 @@ msgstr "" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3493,6 +3656,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "" @@ -3686,12 +3857,17 @@ msgstr "" msgid "threshold must be in the range 0-65536" msgstr "" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" @@ -3906,6 +4082,10 @@ msgstr "" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "" diff --git a/locale/it_IT.po b/locale/it_IT.po index b65638c9d..1c91b0892 100644 --- a/locale/it_IT.po +++ b/locale/it_IT.po @@ -42,6 +42,10 @@ msgstr " File \"%q\"" msgid " File \"%q\", line %d" msgstr " File \"%q\", riga %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr " output:\n" @@ -53,7 +57,8 @@ msgstr "%%c necessita di int o char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c @@ -336,6 +341,10 @@ msgstr "Tutte le periferiche I2C sono in uso" msgid "All event channels in use" msgstr "Tutti i canali eventi utilizati" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "Tutti i canali di eventi sincronizzati in uso" @@ -384,6 +393,7 @@ msgstr "" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "funzionalità AnalogOut non supportata" @@ -517,7 +527,6 @@ msgstr "" msgid "Buffer must be a multiple of 512 bytes" msgstr "" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "Il buffer deve essere lungo almeno 1" @@ -532,6 +541,7 @@ msgid "Buffer too short by %d bytes" msgstr "" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, fuzzy, c-format msgid "Bus pin %d is already in use" @@ -587,6 +597,7 @@ msgstr "Impossibile cancellare valori" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "non si può tirare quando nella modalita output" @@ -626,6 +637,10 @@ msgid "Cannot reset into bootloader because no bootloader is present." msgstr "" "Impossibile resettare nel bootloader poiché nessun bootloader è presente." +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "non si può impostare un valore quando direzione è input" @@ -806,6 +821,10 @@ msgstr "DAC già in uso" msgid "Data 0 pin must be byte aligned" msgstr "graphic deve essere lunga 2048 byte" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "" @@ -861,7 +880,12 @@ msgstr "Canale EXTINT già in uso" msgid "Error in regex" msgstr "Errore nella regex" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -917,7 +941,7 @@ msgstr "" msgid "FFT is implemented for linear arrays only" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "" @@ -1045,6 +1069,10 @@ msgstr "operazione I/O su file chiuso" msgid "I2C Init Error" msgstr "" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "" @@ -1070,6 +1098,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "" @@ -1082,6 +1114,31 @@ msgstr "" msgid "Input/output error" msgstr "Errore input/output" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "" @@ -1133,7 +1190,7 @@ msgstr "" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Frequenza PWM non valida" @@ -1229,6 +1286,8 @@ msgstr "Pin non valido per il canale destro" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "Pin non validi" @@ -1257,6 +1316,10 @@ msgstr "" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1340,6 +1403,36 @@ msgstr "" msgid "Missing MISO or MOSI Pin" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "" @@ -1393,14 +1486,14 @@ msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Nessun pin RX" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Nessun pin TX" @@ -1457,6 +1550,16 @@ msgstr "" msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "" @@ -1516,6 +1619,10 @@ msgstr "operazione I2C non supportata" msgid "Only 8 or 16 bit mono with " msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1592,8 +1699,8 @@ msgstr "" "frequenza PWM frequency non è scrivibile quando variable_frequency è " "impostato nel costruttore a False." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "" @@ -1606,11 +1713,20 @@ msgstr "" msgid "Permission denied" msgstr "Permesso negato" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "Il pin non ha capacità di ADC" @@ -1672,10 +1788,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "" +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "" @@ -1684,6 +1824,10 @@ msgstr "" msgid "RNG Init Error" msgstr "" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1691,6 +1835,7 @@ msgstr "" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "calibrazione RTC non supportata su questa scheda" @@ -1699,7 +1844,7 @@ msgid "RTC is not supported on this board" msgstr "RTC non supportato su questa scheda" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "" @@ -1757,11 +1902,6 @@ msgstr "" msgid "SD card CSD format not supported" msgstr "" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDA o SCL necessitano un pull-up" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1780,6 +1920,10 @@ msgstr "" msgid "SPI Re-initialization error" msgstr "" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c #, fuzzy msgid "Sample rate must be positive" @@ -1812,6 +1956,14 @@ msgstr "Serializer in uso" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "" @@ -1976,6 +2128,10 @@ msgstr "" msgid "UART Re-init error" msgstr "" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "" @@ -2040,7 +2196,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "indentazione inaspettata" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2081,7 +2237,8 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "baudrate non supportato" @@ -2133,6 +2290,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "ATTENZIONE: Il nome del sorgente ha due estensioni\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2341,7 +2499,7 @@ msgstr "slice del buffer devono essere della stessa lunghezza" msgid "buffer too small" msgstr "buffer troppo piccolo" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -3345,6 +3503,10 @@ msgstr "argomenti non sufficienti per la stringa di formattazione" msgid "number of points must be at least 2" msgstr "" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "" @@ -3533,6 +3695,7 @@ msgstr "pow() con 3 argomenti richiede interi" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3550,6 +3713,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "overflow della coda" @@ -3746,12 +3917,17 @@ msgstr "errore di sintassi nel descrittore uctypes" msgid "threshold must be in the range 0-65536" msgstr "la soglia deve essere nell'intervallo 0-65536" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" @@ -3967,6 +4143,10 @@ msgstr "" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "" @@ -4033,6 +4213,9 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDA o SCL necessitano un pull-up" + #~ msgid "tuple index out of range" #~ msgstr "indice della tupla fuori intervallo" diff --git a/locale/ja.po b/locale/ja.po index ca13d8a9c..0fb8a6f48 100644 --- a/locale/ja.po +++ b/locale/ja.po @@ -48,6 +48,10 @@ msgstr " ファイル \"%q\"" msgid " File \"%q\", line %d" msgstr " ファイル \"%q\", 行 %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr " 出力:\n" @@ -59,7 +63,8 @@ msgstr "%%c にはintまたはcharが必要" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c @@ -339,6 +344,10 @@ msgstr "全てのUART周辺機器が使用中" msgid "All event channels in use" msgstr "全てのイベントチャネルが使用中" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "全ての同期イベントチャネルが使用中" @@ -387,6 +396,7 @@ msgstr "指定のピンはAnalogInに対応していません" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "AnalogOut機能に対応していません" @@ -519,7 +529,6 @@ msgstr "バッファ長は512の倍数でなければなりません" msgid "Buffer must be a multiple of 512 bytes" msgstr "バッファは512の倍数でなければなりません" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "バッファ長は少なくとも1以上でなければなりません" @@ -534,6 +543,7 @@ msgid "Buffer too short by %d bytes" msgstr "バッファが %d バイト足りません" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -590,6 +600,7 @@ msgstr "値を削除できません" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "出力モード時はpullを取得できません" @@ -627,6 +638,10 @@ msgstr "USBがアクティブの時に'/'を再マウントできません" msgid "Cannot reset into bootloader because no bootloader is present." msgstr "ブートローダが存在しないためブートローダへとリセットできません" +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "方向がinputのときは値を設定できません" @@ -807,6 +822,10 @@ msgstr "DACはすでに使用中" msgid "Data 0 pin must be byte aligned" msgstr "Data 0 ピンは、バイト整列されていなければなりません" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "fmtチャンクの後にdataチャンクが続かなければなりません" @@ -861,7 +880,12 @@ msgstr "EXTINTチャネルはすでに使用されています" msgid "Error in regex" msgstr "正規表現にエラーがあります" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -915,7 +939,7 @@ msgstr "FFTはndarrayでのみ使えます" msgid "FFT is implemented for linear arrays only" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "" @@ -1043,6 +1067,10 @@ msgstr "閉じられたファイルへのI/O操作" msgid "I2C Init Error" msgstr "I2C初期化エラー" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "I2SOutが利用できません" @@ -1068,6 +1096,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "バッファサイズが正しくありません" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "" @@ -1080,6 +1112,31 @@ msgstr "" msgid "Input/output error" msgstr "入力/出力エラー" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "認証が不十分" @@ -1131,7 +1188,7 @@ msgstr "不正なDACピンが与えられました" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "無効なPWM周波数" @@ -1225,6 +1282,8 @@ msgstr "右チャネルのピンが不正" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "ピンが不正" @@ -1253,6 +1312,10 @@ msgstr "不正なsecurity_mode" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1334,6 +1397,36 @@ msgstr "マイクのスタートアップディレイは 0.0 から 1.0 の間 msgid "Missing MISO or MOSI Pin" msgstr "MISOまたはMOSIピンがありません" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "%q のサブクラスでなければなりません" @@ -1387,14 +1480,14 @@ msgstr "MOSIピンがありません" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "RXピンがありません" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "TXピンがありません" @@ -1451,6 +1544,16 @@ msgstr "このピンには使えるタイマーがもうありません" msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "ピンにプルダウンがありません。1Mオーム推奨" @@ -1508,6 +1611,10 @@ msgstr "奇数パリティには対応していません" msgid "Only 8 or 16 bit mono with " msgstr "8または16ビットの " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1580,8 +1687,8 @@ msgid "" "PWM frequency not writable when variable_frequency is False on construction." msgstr "PWM周波数は生成時のvariable_frequencyがFalseのとき書き換え不可" -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "ParallelBusにはまだ対応していません" @@ -1594,11 +1701,20 @@ msgstr "" msgid "Permission denied" msgstr "パーミッション拒否" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "ピンにADCの能力がありません" @@ -1659,10 +1775,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "方向がoutputのときpullは使われません" +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "RNG解体エラー" @@ -1671,6 +1811,10 @@ msgstr "RNG解体エラー" msgid "RNG Init Error" msgstr "乱数生成器の初期化エラー" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1678,6 +1822,7 @@ msgstr "" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "このボードはRTCのキャリブレーションに非対応" @@ -1686,7 +1831,7 @@ msgid "RTC is not supported on this board" msgstr "このボードはRTCに対応していません" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "RTS/CTS/RS485はこのデバイスでは未対応" @@ -1743,11 +1888,6 @@ msgstr "セーフモードで実行中! " msgid "SD card CSD format not supported" msgstr "SDカードのCSDフォーマットは非対応" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDAとSCLにプルアップが必要" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1766,6 +1906,10 @@ msgstr "SPI初期化エラー" msgid "SPI Re-initialization error" msgstr "SPI再初期化エラー" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "サンプルレートは正数でなければなりません" @@ -1796,6 +1940,14 @@ msgstr "シリアライザは使用中" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "サイズは対応していません" @@ -1966,6 +2118,10 @@ msgstr "UARTの初期化エラー" msgid "UART Re-init error" msgstr "UARTの再初期化エラー" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "UART書き込みエラー" @@ -2030,7 +2186,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "想定されていないnrfx UUID型" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2071,7 +2227,8 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "非対応のbaudrate" @@ -2122,6 +2279,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2327,7 +2485,7 @@ msgstr "バッファのスライスは同じ長さでなければなりません msgid "buffer too small" msgstr "" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -3320,6 +3478,10 @@ msgstr "書式化文字列への引数が足りません" msgid "number of points must be at least 2" msgstr "" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "オブジェクト'%q'がタプルやリストでありません" @@ -3506,6 +3668,7 @@ msgstr "pow()の第3引数には整数が必要" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3523,6 +3686,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "キューがオーバーフローしました" @@ -3717,12 +3888,17 @@ msgstr "uctypedディスクリプタの構文エラー" msgid "threshold must be in the range 0-65536" msgstr "threshouldは0から65536まで" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "time.struct_time()は9要素のシーケンスを受け取ります" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "タイムアウト長は対応する最大値を超えています" @@ -3937,6 +4113,10 @@ msgstr "watchdogのtimeoutは0以上でなければなりません" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "windowはinterval以下でなければなりません" @@ -4001,6 +4181,9 @@ msgstr "ziはfloat値でなければなりません" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDAとSCLにプルアップが必要" + #~ msgid "" #~ "\n" #~ "Code done running. Waiting for reload.\n" diff --git a/locale/ko.po b/locale/ko.po index c645d12ae..ce662ad5f 100644 --- a/locale/ko.po +++ b/locale/ko.po @@ -44,6 +44,10 @@ msgstr " 파일 \"%q\"" msgid " File \"%q\", line %d" msgstr " 파일 \"%q\", 라인 %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr " 산출:\n" @@ -55,7 +59,8 @@ msgstr "%%c 전수(int)또는 캐릭터(char)필요합니다" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c @@ -335,6 +340,10 @@ msgstr "사용중인 모든 UART주변 기기" msgid "All event channels in use" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "" @@ -383,6 +392,7 @@ msgstr "" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "" @@ -515,7 +525,6 @@ msgstr "" msgid "Buffer must be a multiple of 512 bytes" msgstr "" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "잘못된 크기의 버퍼. >1 여야합니다" @@ -530,6 +539,7 @@ msgid "Buffer too short by %d bytes" msgstr "" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -584,6 +594,7 @@ msgstr "값을 삭제할 수 없습니다" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "" @@ -621,6 +632,10 @@ msgstr "" msgid "Cannot reset into bootloader because no bootloader is present." msgstr "" +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "" @@ -799,6 +814,10 @@ msgstr "DAC가 현재 사용 중입니다" msgid "Data 0 pin must be byte aligned" msgstr "" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "" @@ -853,7 +872,12 @@ msgstr "" msgid "Error in regex" msgstr "Regex에 오류가 있습니다." -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -907,7 +931,7 @@ msgstr "" msgid "FFT is implemented for linear arrays only" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "" @@ -1035,6 +1059,10 @@ msgstr "" msgid "I2C Init Error" msgstr "" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "" @@ -1058,6 +1086,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "" @@ -1070,6 +1102,31 @@ msgstr "" msgid "Input/output error" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "" @@ -1121,7 +1178,7 @@ msgstr "" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "" @@ -1215,6 +1272,8 @@ msgstr "오른쪽 채널 핀이 잘못되었습니다" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "핀이 유효하지 않습니다" @@ -1243,6 +1302,10 @@ msgstr "" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1324,6 +1387,36 @@ msgstr "" msgid "Missing MISO or MOSI Pin" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "" @@ -1377,14 +1470,14 @@ msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "" @@ -1441,6 +1534,16 @@ msgstr "" msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "" @@ -1496,6 +1599,10 @@ msgstr "" msgid "Only 8 or 16 bit mono with " msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1567,8 +1674,8 @@ msgid "" "PWM frequency not writable when variable_frequency is False on construction." msgstr "" -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "" @@ -1581,11 +1688,20 @@ msgstr "" msgid "Permission denied" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "" @@ -1646,10 +1762,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "" +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "" @@ -1658,6 +1798,10 @@ msgstr "" msgid "RNG Init Error" msgstr "" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1665,6 +1809,7 @@ msgstr "" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "" @@ -1673,7 +1818,7 @@ msgid "RTC is not supported on this board" msgstr "" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "" @@ -1730,11 +1875,6 @@ msgstr "" msgid "SD card CSD format not supported" msgstr "" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1753,6 +1893,10 @@ msgstr "" msgid "SPI Re-initialization error" msgstr "" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "" @@ -1783,6 +1927,14 @@ msgstr "" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "" @@ -1947,6 +2099,10 @@ msgstr "" msgid "UART Re-init error" msgstr "" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "" @@ -2011,7 +2167,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2052,7 +2208,8 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "" @@ -2103,6 +2260,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2308,7 +2466,7 @@ msgstr "" msgid "buffer too small" msgstr "" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -3296,6 +3454,10 @@ msgstr "" msgid "number of points must be at least 2" msgstr "" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "" @@ -3480,6 +3642,7 @@ msgstr "" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3497,6 +3660,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "" @@ -3690,12 +3861,17 @@ msgstr "" msgid "threshold must be in the range 0-65536" msgstr "" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" @@ -3910,6 +4086,10 @@ msgstr "" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "" diff --git a/locale/nl.po b/locale/nl.po index 1435e8634..821f338ca 100644 --- a/locale/nl.po +++ b/locale/nl.po @@ -46,6 +46,10 @@ msgstr " Bestand" msgid " File \"%q\", line %d" msgstr " Bestand \"%q\", regel %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr " uitvoer:\n" @@ -57,8 +61,9 @@ msgstr "%%c vereist een int of char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" -msgstr "%d adres pins en %d RGB pins geven een hoogte van %d aan, niet %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" +msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c msgid "%q failure: %d" @@ -337,6 +342,10 @@ msgstr "Alle UART peripherals zijn in gebruik" msgid "All event channels in use" msgstr "Alle event kanalen zijn in gebruik" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "Alle sync event kanalen zijn in gebruik" @@ -385,6 +394,7 @@ msgstr "AnalogIn niet ondersteund door gegeven pin" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "AnalogOut functionaliteit niet ondersteund" @@ -517,7 +527,6 @@ msgstr "Buffer lengte moet een veelvoud van 512 zijn" msgid "Buffer must be a multiple of 512 bytes" msgstr "Buffer moet een veelvoud van 512 bytes zijn" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "Buffer moet op zijn minst lengte 1 zijn" @@ -532,6 +541,7 @@ msgid "Buffer too short by %d bytes" msgstr "Buffer is %d bytes te klein" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -586,6 +596,7 @@ msgstr "Kan waardes niet verwijderen" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "get pull kan niet gedurende output mode" @@ -625,6 +636,10 @@ msgid "Cannot reset into bootloader because no bootloader is present." msgstr "" "Kan niet resetten naar bootloader omdat er geen bootloader aanwezig is." +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "Kan de waarde niet toewijzen als de richting input is." @@ -807,6 +822,10 @@ msgstr "DAC al in gebruik" msgid "Data 0 pin must be byte aligned" msgstr "Data 0 pin moet byte uitgelijnd zijn" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "Data chunk moet gevolgd worden door fmt chunk" @@ -861,7 +880,12 @@ msgstr "EXTINT kanaal al in gebruik" msgid "Error in regex" msgstr "Fout in regex" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -915,7 +939,7 @@ msgstr "FFT alleen voor ndarrays gedefineerd" msgid "FFT is implemented for linear arrays only" msgstr "FFT is alleen geïmplementeerd voor lineaire arrays" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "SSL handdruk mislukt" @@ -1044,6 +1068,10 @@ msgstr "I/O actie op gesloten bestand" msgid "I2C Init Error" msgstr "I2C Init Fout" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "I2SOut is niet beschikbaar" @@ -1069,6 +1097,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "Incorrecte buffer grootte" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "De initialisatie is mislukt vanwege een gebrek aan geheugen" @@ -1081,6 +1113,31 @@ msgstr "Invoer duurt te lang" msgid "Input/output error" msgstr "Input/Output fout" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "Onvoldoende authenticatie" @@ -1132,7 +1189,7 @@ msgstr "Ongeldige DAC pin opgegeven" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Ongeldige PWM frequentie" @@ -1226,6 +1283,8 @@ msgstr "Ongeldige pin voor rechter kanaal" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "Ongeldige pinnen" @@ -1254,6 +1313,10 @@ msgstr "Ongeldige security_mode" msgid "Invalid size" msgstr "" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "" @@ -1335,6 +1398,36 @@ msgstr "Microfoon opstart vertraging moet in bereik van 0.0 tot 1.0 zijn" msgid "Missing MISO or MOSI Pin" msgstr "Ontbrekende MISO of MOSI Pin" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "%q moet een subklasse zijn." @@ -1388,14 +1481,14 @@ msgstr "Geen MOSI pin" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Geen RX pin" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Geen TX pin" @@ -1452,6 +1545,16 @@ msgstr "Geen timers meer beschikbaar op deze pin." msgid "No network with that ssid" msgstr "Geen netwerk met dat SSID gevonden" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "Geen pulldown op pin; 1MOhm aangeraden" @@ -1509,6 +1612,10 @@ msgstr "Oneven pariteit is niet ondersteund" msgid "Only 8 or 16 bit mono with " msgstr "Alleen 8 of 16 bit mono met " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "Alleen IPv4 adressen worden ondersteund" @@ -1587,8 +1694,8 @@ msgstr "" "PWM frequentie is niet schrijfbaar wanneer de variable_frequency False is " "tijdens constructie." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "ParallelBus nog niet ondersteund" @@ -1601,11 +1708,20 @@ msgstr "" msgid "Permission denied" msgstr "Toegang geweigerd" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "Pin heeft geen ADC mogelijkheden" @@ -1675,10 +1791,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "Pull niet gebruikt wanneer de richting output is." +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "RNG DeInit Fout" @@ -1687,6 +1827,10 @@ msgstr "RNG DeInit Fout" msgid "RNG Init Error" msgstr "RNG Init Fout" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1694,6 +1838,7 @@ msgstr "RS485 inversie gespecificeerd terwijl niet in RS485 modus" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "RTC calibratie niet ondersteund door dit board" @@ -1702,7 +1847,7 @@ msgid "RTC is not supported on this board" msgstr "RTC is niet ondersteund door dit board" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "RTS/CTS/RS485 Nog niet ondersteund door dit apparaat" @@ -1759,11 +1904,6 @@ msgstr "Veilige modus wordt uitgevoerd! " msgid "SD card CSD format not supported" msgstr "SD kaart CSD formaat niet ondersteund" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDA of SCL hebben een pullup nodig" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1782,6 +1922,10 @@ msgstr "SPI Init Fout" msgid "SPI Re-initialization error" msgstr "SPI Herinitialisatie Fout" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "Sample rate moet positief zijn" @@ -1812,6 +1956,14 @@ msgstr "Serializer in gebruik" msgid "Server side context cannot have hostname" msgstr "Context aan de serverkant kan geen hostnaam hebben" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "Afmeting niet ondersteund" @@ -1986,6 +2138,10 @@ msgstr "UART Init Fout" msgid "UART Re-init error" msgstr "UART Re-init Fout" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "UART schrijf fout" @@ -2049,7 +2205,7 @@ msgstr "Kan niet naar sleep_memory schrijven." msgid "Unexpected nrfx uuid type" msgstr "Onverwacht mrfx uuid type" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "Niet behandelde ESP TLS fout %d %d %x %d" @@ -2092,7 +2248,8 @@ msgstr "" "apparaat geweigerd of genegeerd werd." #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "Niet-ondersteunde baudsnelheid" @@ -2143,6 +2300,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "WAARSCHUWING: De bestandsnaam van de code heeft twee extensies\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" "WatchDogTimer kan niet worden gedeïnitialiseerd zodra de modus in ingesteld " @@ -2357,7 +2515,7 @@ msgstr "buffer slices moeten van gelijke grootte zijn" msgid "buffer too small" msgstr "buffer te klein" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "buffer te klein voor gevraagde bytes" @@ -3353,6 +3511,10 @@ msgstr "niet genoeg argumenten om string te formatteren" msgid "number of points must be at least 2" msgstr "aantal punten moet minimaal 2 zijn" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "object '%q' is geen tuple of lijst" @@ -3538,6 +3700,7 @@ msgstr "pow() met 3 argumenten vereist integers" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3555,6 +3718,14 @@ msgstr "druk bootknop in bij opstarten.\n" msgid "pressing both buttons at start up.\n" msgstr "druk beide knoppen in bij opstarten.\n" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "wachtrij overloop" @@ -3750,12 +3921,17 @@ msgstr "syntaxisfout in uctypes aanduiding" msgid "threshold must be in the range 0-65536" msgstr "drempelwaarde moet in het bereik 0-65536 liggen" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "time.struct_time() accepteert een 9-rij" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "time-outduur is groter dan de ondersteunde maximale waarde" @@ -3970,6 +4146,10 @@ msgstr "watchdog time-out moet groter zijn dan 0" msgid "width must be greater than zero" msgstr "breedte moet groter dan nul zijn" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "window moet <= interval zijn" @@ -4034,6 +4214,12 @@ msgstr "zi moet van type float zijn" msgid "zi must be of shape (n_section, 2)" msgstr "zi moet vorm (n_section, 2) hebben" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDA of SCL hebben een pullup nodig" + +#~ msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +#~ msgstr "%d adres pins en %d RGB pins geven een hoogte van %d aan, niet %d" + #~ msgid "Unknown failure" #~ msgstr "Onbekende fout" diff --git a/locale/pl.po b/locale/pl.po index 8ba0c3d71..67eb28816 100644 --- a/locale/pl.po +++ b/locale/pl.po @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-01-04 12:55-0600\n" -"PO-Revision-Date: 2021-01-20 02:40+0000\n" +"PO-Revision-Date: 2021-01-27 01:31+0000\n" "Last-Translator: Maciej Stankiewicz <tawezik@gmail.com>\n" "Language-Team: pl\n" "Language: pl\n" @@ -48,6 +48,10 @@ msgstr " Plik \"%q\"" msgid " File \"%q\", line %d" msgstr " Plik \"%q\", linia %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr "" + #: main.c msgid " output:\n" msgstr " wyjście:\n" @@ -59,7 +63,8 @@ msgstr "%%c wymaga int lub char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" #: ports/atmel-samd/common-hal/sdioio/SDCard.c @@ -339,6 +344,10 @@ msgstr "Wszystkie peryferia UART w użyciu" msgid "All event channels in use" msgstr "Wszystkie kanały zdarzeń w użyciu" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "Wszystkie kanały zdarzeń synchronizacji w użyciu" @@ -387,6 +396,7 @@ msgstr "AnalogIn nie jest obsługiwany na danym pinie" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "AnalogOut jest niewspierane" @@ -519,7 +529,6 @@ msgstr "Długość bufora musi być wielokrotnością 512" msgid "Buffer must be a multiple of 512 bytes" msgstr "Bufor musi być wielokrotnością 512 bajtów" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "Bufor musi mieć długość 1 lub więcej" @@ -534,6 +543,7 @@ msgid "Buffer too short by %d bytes" msgstr "Bufor za krótki o %d bajtów" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -588,6 +598,7 @@ msgstr "Nie można usunąć" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "Nie ma podciągnięcia w trybie wyjścia" @@ -625,6 +636,10 @@ msgstr "Nie można przemontować '/' gdy USB działa." msgid "Cannot reset into bootloader because no bootloader is present." msgstr "Nie można zrestartować -- nie ma bootloadera." +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "Nie można ustawić wartości w trybie wejścia." @@ -807,6 +822,10 @@ msgstr "DAC w użyciu" msgid "Data 0 pin must be byte aligned" msgstr "Nóżka data 0 musi być wyrównana do bajtu" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "" + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "Fragment danych musi następować po fragmencie fmt" @@ -861,7 +880,12 @@ msgstr "Kanał EXTINT w użyciu" msgid "Error in regex" msgstr "Błąd w regex" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -915,7 +939,7 @@ msgstr "" msgid "FFT is implemented for linear arrays only" msgstr "" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "" @@ -1043,6 +1067,10 @@ msgstr "Operacja I/O na zamkniętym pliku" msgid "I2C Init Error" msgstr "Błąd inicjalizacji I2C" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "I2SOut niedostępne" @@ -1068,6 +1096,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "Niewłaściwa wielkość bufora" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "Inicjalizacja nie powiodła się z powodu braku pamięci" @@ -1080,6 +1112,31 @@ msgstr "" msgid "Input/output error" msgstr "Błąd I/O" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "Niewystarczające uwierzytelnienie" @@ -1131,7 +1188,7 @@ msgstr "" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Zła częstotliwość PWM" @@ -1225,6 +1282,8 @@ msgstr "Zła nóżka dla prawego kanału" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "Złe nóżki" @@ -1253,6 +1312,10 @@ msgstr "Nieprawidłowy security_mode" msgid "Invalid size" msgstr "Nieprawidłowy rozmiar" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "Nieprawidłowy stan" @@ -1335,6 +1398,36 @@ msgstr "Opóźnienie włączenia mikrofonu musi być w zakresie od 0.0 do 1.0" msgid "Missing MISO or MOSI Pin" msgstr "Brak pinu MISO lub MOSI" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "" @@ -1388,14 +1481,14 @@ msgstr "Brak pinu MOSI" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Brak nóżki RX" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Brak nóżki TX" @@ -1452,6 +1545,16 @@ msgstr "" msgid "No network with that ssid" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "" @@ -1507,6 +1610,10 @@ msgstr "Nieparzysta parzystość nie jest wspierana" msgid "Only 8 or 16 bit mono with " msgstr "Tylko 8 lub 16 bitów mono z " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "" @@ -1578,8 +1685,8 @@ msgid "" "PWM frequency not writable when variable_frequency is False on construction." msgstr "Nie można zmienić częstotliwości PWM gdy variable_frequency=False." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "ParallelBus nie jest jeszcze obsługiwany" @@ -1592,11 +1699,20 @@ msgstr "" msgid "Permission denied" msgstr "Odmowa dostępu" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "Nóżka nie obsługuje ADC" @@ -1657,10 +1773,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "Podciągnięcie nieużywane w trybie wyjścia." +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "" @@ -1669,6 +1809,10 @@ msgstr "" msgid "RNG Init Error" msgstr "" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1676,6 +1820,7 @@ msgstr "" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "Brak obsługi kalibracji RTC" @@ -1684,7 +1829,7 @@ msgid "RTC is not supported on this board" msgstr "Brak obsługi RTC" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "" @@ -1741,11 +1886,6 @@ msgstr "" msgid "SD card CSD format not supported" msgstr "" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDA lub SCL wymagają podciągnięcia" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1764,6 +1904,10 @@ msgstr "Błąd inicjowania SPI" msgid "SPI Re-initialization error" msgstr "Błąd ponownej inicjalizacji SPI" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "Częstotliwość próbkowania musi być dodatnia" @@ -1794,6 +1938,14 @@ msgstr "Serializator w użyciu" msgid "Server side context cannot have hostname" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "" @@ -1958,6 +2110,10 @@ msgstr "" msgid "UART Re-init error" msgstr "" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "Błąd zapisu UART" @@ -2021,7 +2177,7 @@ msgstr "" msgid "Unexpected nrfx uuid type" msgstr "Nieoczekiwany typ nrfx uuid" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "" @@ -2062,7 +2218,8 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "Zła szybkość transmisji" @@ -2113,6 +2270,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "UWAGA: Nazwa pliku ma dwa rozszerzenia\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" @@ -2324,7 +2482,7 @@ msgstr "fragmenty bufora muszą mieć tę samą długość" msgid "buffer too small" msgstr "zbyt mały bufor" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "" @@ -3114,7 +3272,7 @@ msgstr "" #: py/parse.c msgid "malformed f-string" -msgstr "" +msgstr "źle sformatowany f-string" #: shared-bindings/_stage/Layer.c msgid "map buffer too small" @@ -3313,6 +3471,10 @@ msgstr "nie dość argumentów przy formatowaniu" msgid "number of points must be at least 2" msgstr "liczba punktów musi wynosić co najmniej 2" +#: py/builtinhelp.c +msgid "object " +msgstr "" + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "" @@ -3379,11 +3541,11 @@ msgstr "offset poza zakresem" #: ports/nrf/common-hal/audiobusio/PDMIn.c msgid "only bit_depth=16 is supported" -msgstr "" +msgstr "obsługiwane jest tylko bit_depth=16" #: ports/nrf/common-hal/audiobusio/PDMIn.c msgid "only sample_rate=16000 is supported" -msgstr "" +msgstr "obsługiwane jest tylko sample_rate=16000" #: py/objarray.c py/objstr.c py/objstrunicode.c py/objtuple.c #: shared-bindings/alarm/SleepMemory.c shared-bindings/nvm/ByteArray.c @@ -3498,6 +3660,7 @@ msgstr "trzyargumentowe pow() wymaga liczb całkowitych" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3515,6 +3678,14 @@ msgstr "" msgid "pressing both buttons at start up.\n" msgstr "" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "przepełnienie kolejki" @@ -3709,12 +3880,17 @@ msgstr "błąd składni w deskryptorze uctypes" msgid "threshold must be in the range 0-65536" msgstr "threshold musi być w zakresie 0-65536" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "time.struct_time() wymaga 9-elementowej sekwencji" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" @@ -3929,6 +4105,10 @@ msgstr "" msgid "width must be greater than zero" msgstr "" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "" @@ -3993,6 +4173,9 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDA lub SCL wymagają podciągnięcia" + #~ msgid "tuple index out of range" #~ msgstr "indeks krotki poza zakresem" diff --git a/locale/pt_BR.po b/locale/pt_BR.po index d3f57a58a..9826ac757 100644 --- a/locale/pt_BR.po +++ b/locale/pt_BR.po @@ -6,7 +6,7 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-01-04 12:55-0600\n" -"PO-Revision-Date: 2021-01-17 12:55+0000\n" +"PO-Revision-Date: 2021-02-05 15:41+0000\n" "Last-Translator: Wellington Terumi Uemura <wellingtonuemura@gmail.com>\n" "Language-Team: \n" "Language: pt_BR\n" @@ -50,6 +50,10 @@ msgstr " Arquivo \"%q\"" msgid " File \"%q\", line %d" msgstr " Arquivo \"%q\", linha %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr " é do tipo %q\n" + #: main.c msgid " output:\n" msgstr " saída:\n" @@ -61,8 +65,11 @@ msgstr "%%c requer int ou char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" -msgstr "%d endereços dos pinos e %d pinos rgb indicam uma altura do %d, não %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" +msgstr "" +"%d pinos de endereço, %d pinos rgb e %d blocos indicam uma altura com %d, " +"não %d" #: ports/atmel-samd/common-hal/sdioio/SDCard.c msgid "%q failure: %d" @@ -345,6 +352,10 @@ msgstr "Todos os periféricos UART estão em uso" msgid "All event channels in use" msgstr "Todos os canais de eventos em uso" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "O estado de todas as máquinas em uso" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "Todos os canais dos eventos de sincronização em uso" @@ -393,6 +404,7 @@ msgstr "O AnalogIn não é compatível no pino informado" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "Funcionalidade AnalogOut não suportada" @@ -529,7 +541,6 @@ msgstr "O comprimento do Buffer deve ser um múltiplo de 512" msgid "Buffer must be a multiple of 512 bytes" msgstr "O buffer deve ser um múltiplo de 512 bytes" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "O comprimento do buffer deve ter pelo menos 1" @@ -544,6 +555,7 @@ msgid "Buffer too short by %d bytes" msgstr "O buffer é muito curto em %d bytes" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -601,6 +613,7 @@ msgstr "Não é possível excluir valores" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "Não é possível obter (pull) enquanto estiver no modo saída" @@ -641,6 +654,10 @@ msgid "Cannot reset into bootloader because no bootloader is present." msgstr "" "Não é possível redefinir para o bootloader porque o mesmo não está presente." +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "Não foi possível definir as opções do socket" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "Não é possível definir o valor quando a direção é inserida." @@ -823,6 +840,10 @@ msgstr "DAC em uso" msgid "Data 0 pin must be byte aligned" msgstr "O pino de dados 0 deve ser alinhado por bytes" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "O pino de dados 0 deve ser alinhado por bytes." + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "Pedaço de dados deve seguir o pedaço de cortes" @@ -877,7 +898,12 @@ msgstr "Canal EXTINT em uso" msgid "Error in regex" msgstr "Erro no regex" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "Erro: Falha na vinculação" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -931,7 +957,7 @@ msgstr "O FFT é definido apenas para ndarrays" msgid "FFT is implemented for linear arrays only" msgstr "O FFT é implementado apenas para matrizes lineares" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "Houve uma falha no handshake do SSL" @@ -1060,6 +1086,10 @@ msgstr "Operação I/O no arquivo fechado" msgid "I2C Init Error" msgstr "Erro de inicialização do I2C" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "Periférico I2C em uso" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "O I2SOut não está disponível" @@ -1085,6 +1115,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "O tamanho do buffer está incorreto" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "O tamanho do programa Init é inválido" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "A inicialização falhou devido à falta de memória" @@ -1097,6 +1131,31 @@ msgstr "A entrada está demorando demais" msgid "Input/output error" msgstr "Erro de entrada/saída" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "A instrução %d salta no pino" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "A instrução %d muda com mais bits do que a quantidade dos pinos" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "A instrução %d desloca mais bits do que a quantidade dos pinos" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "A instrução %d usa um pino extra" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "A instrução %d aguarda a entrada de fora da contagem" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "Autenticação insuficiente" @@ -1148,7 +1207,7 @@ msgstr "O pino DAC informado é inválido" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Frequência PWM inválida" @@ -1242,6 +1301,8 @@ msgstr "Pino inválido para canal direito" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "Pinos inválidos" @@ -1270,6 +1331,10 @@ msgstr "O Security_mode é inválido" msgid "Invalid size" msgstr "Tamanho inválido" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "Soquete inválido para o TLS" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "Estado inválido" @@ -1351,6 +1416,36 @@ msgstr "O atraso na inicialização do microfone deve estar entre 0,0 e 1,0" msgid "Missing MISO or MOSI Pin" msgstr "O pino MISO ou MOSI está ausente" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "Faltando first_in_pin. A instrução %d lê pinos(s)" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "Faltando first_in_pin. A instrução %d muda a partir do(s) pino(s)" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "Faltando first_in_pin. A instrução %d aguarda com base no pino" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "Faltando first_out_pin. A instrução %d muda para o(s) pinos(s)" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "Faltando first_out_pin. A instrução %d escreve nos pinos(s)" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "Faltando first_set_pin. A instrução %d define os pinos(s)" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "Deve ser uma subclasse %q." @@ -1404,14 +1499,14 @@ msgstr "Nenhum pino MOSI" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Nenhum pino RX" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Nenhum pino TX" @@ -1468,6 +1563,18 @@ msgstr "Não há mais temporizadores disponíveis neste pino." msgid "No network with that ssid" msgstr "Não há rede com este ssid" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "Sem saída no programa" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" +"Nenhum pull up foi encontrado no SDA ou no SCL; verifique o fio das suas " +"conexões" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "Não há pulldown no pino; É recomendável utilizar um resistor de 1M ohm" @@ -1524,6 +1631,10 @@ msgstr "A paridade ímpar não é compatível" msgid "Only 8 or 16 bit mono with " msgstr "Apenas mono com 8 ou 16 bits com " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "Somente IN/OUT de até 8 suportados" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "Somente os endereços IPv4 são suportados" @@ -1603,8 +1714,8 @@ msgstr "" "A frequência do PWM não pode ser gravada quando variable_frequency for False " "na construção." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "O ParallelBus ainda não é compatível" @@ -1617,11 +1728,20 @@ msgstr "O periférico está em uso" msgid "Permission denied" msgstr "Permissão negada" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "A contagem dos pinos deve ser com pelo menos 1" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "A contagem dos pinos é muito grande" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "O pino não tem recursos de ADC" @@ -1694,10 +1814,34 @@ msgstr "" "Tentando entrar no deep sleep até o alarme, pressione CTRL-C ou grave o " "arquivo.\n" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "O programa faz IN sem carregar o ISR" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "O programa faz OUT sem carregar o OSR" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "O programa deve conter pelo menos uma instrução com 16 bits." + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "O tamanho do programa é inválido" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "O programa é muito grande" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "O Pull não foi usado quando a direção for gerada." +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "O modo RAISE não foi implementado" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "Erro DeInit RNG" @@ -1706,6 +1850,10 @@ msgstr "Erro DeInit RNG" msgid "RNG Init Error" msgstr "Houve um erro na inicialização do RNG" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "Ainda não há suporte para o RS485 neste dispositivo" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1713,6 +1861,7 @@ msgstr "A definição da inversão do RS485 quando não está no modo RS485" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "A calibração RTC não é suportada nesta placa" @@ -1721,7 +1870,7 @@ msgid "RTC is not supported on this board" msgstr "O RTC não é suportado nesta placa" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "RTS/CTS/RS485 Ainda não é compatível neste dispositivo" @@ -1778,11 +1927,6 @@ msgstr "Executando no modo de segurança! " msgid "SD card CSD format not supported" msgstr "O formato CSD do Cartão SD não é compatível" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDA ou SCL precisa de um pull up" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1801,6 +1945,10 @@ msgstr "Houve um erro na inicialização SPI" msgid "SPI Re-initialization error" msgstr "Houve um erro na reinicialização SPI" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "O periférico SPI está em uso" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "A taxa de amostragem deve ser positiva" @@ -1831,6 +1979,15 @@ msgstr "Serializer em uso" msgid "Server side context cannot have hostname" msgstr "O contexto do lado do servidor não pode ter nome de host" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "A definição da contagem dos pinos deve estar entre 1 e 5" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "" +"A definição da contagem dos pinos do conjunto lateral deve estar entre 1 e 5" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "O tamanho não é suportado" @@ -2009,6 +2166,10 @@ msgstr "Houve um erro na inicialização do UART" msgid "UART Re-init error" msgstr "Houve um erro na reinicialização do UART" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "O UART ainda não é suportado" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "Houve um erro na gravação UART" @@ -2072,7 +2233,7 @@ msgstr "Não foi possível escrever no sleep_memory." msgid "Unexpected nrfx uuid type" msgstr "Tipo uuid nrfx inesperado" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "Erro não tratado do ESP TLS %d %d %x %d" @@ -2115,7 +2276,8 @@ msgstr "" "dispositivo tenha sido recusado ou ignorado." #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "Taxa de transmissão não suportada" @@ -2166,6 +2328,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "AVISO: Seu arquivo de código tem duas extensões\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "" "O WatchDogTimer não pode ser não-inicializado uma vez que o modo é definido " @@ -2381,7 +2544,7 @@ msgstr "as fatias do buffer devem ter o mesmo comprimento" msgid "buffer too small" msgstr "o buffer é muito pequeno" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "o buffer é pequeno demais para os bytes requisitados" @@ -3384,6 +3547,10 @@ msgstr "argumentos insuficientes para o formato da string" msgid "number of points must be at least 2" msgstr "a quantidade dos pontos deve ser pelo menos 2" +#: py/builtinhelp.c +msgid "object " +msgstr "objeto " + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "o objeto '%q' não é uma tupla ou uma lista" @@ -3573,6 +3740,7 @@ msgstr "o pow() com 3 argumentos requer números inteiros" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3590,6 +3758,14 @@ msgstr "pressionando o botão de boot na inicialização.\n" msgid "pressing both buttons at start up.\n" msgstr "pressionando ambos os botões durante a inicialização.\n" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "O pull_threshold deve ser entre 1 e 32" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "O pull_threshold deve ser entre 1 e 32" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "estouro de fila" @@ -3785,12 +3961,17 @@ msgstr "houve um erro de sintaxe no descritor uctypes" msgid "threshold must be in the range 0-65536" msgstr "Limite deve estar no alcance de 0-65536" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "o bloco deve ser maior que zero" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "time.struct_time() leva uma sequência com 9" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "a duração do tempo limite excedeu o valor máximo suportado" @@ -4005,6 +4186,10 @@ msgstr "o tempo limite do watchdog deve ser maior que 0" msgid "width must be greater than zero" msgstr "a largura deve ser maior que zero" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "o wifi não está ativo" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "a janela deve ser <= intervalo" @@ -4069,6 +4254,19 @@ msgstr "zi deve ser de um tipo float" msgid "zi must be of shape (n_section, 2)" msgstr "zi deve estar na forma (n_section, 2)" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDA ou SCL precisa de um pull up" + +#~ msgid "Invalid use of TLS Socket" +#~ msgstr "Uso inválido do soquete TLS" + +#~ msgid "Issue setting SO_REUSEADDR" +#~ msgstr "Problema na configuração do SO_REUSEADDR" + +#~ msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +#~ msgstr "" +#~ "%d endereços dos pinos e %d pinos rgb indicam uma altura do %d, não %d" + #~ msgid "Unknown failure" #~ msgstr "Falha desconhecida" diff --git a/locale/sv.po b/locale/sv.po index 6c58ff01e..2ec0499c5 100644 --- a/locale/sv.po +++ b/locale/sv.po @@ -6,7 +6,7 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-01-04 12:55-0600\n" -"PO-Revision-Date: 2021-01-17 12:55+0000\n" +"PO-Revision-Date: 2021-02-05 19:47+0000\n" "Last-Translator: Jonny Bergdahl <jonny@bergdahl.it>\n" "Language-Team: LANGUAGE <LL@li.org>\n" "Language: sv\n" @@ -50,6 +50,10 @@ msgstr " Filen \"%q\"" msgid " File \"%q\", line %d" msgstr " Fil \"%q\", rad %d" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr " är av typen %q\n" + #: main.c msgid " output:\n" msgstr " utdata:\n" @@ -61,8 +65,10 @@ msgstr "%%c kräver int eller char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" -msgstr "%d adresspinnar och %d RGB-pinnar indikerar en höjd av %d, inte %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" +msgstr "" +"%d adresspinnar, %d rgb-stift och %d brickor anger en höjd på %d, inte %d" #: ports/atmel-samd/common-hal/sdioio/SDCard.c msgid "%q failure: %d" @@ -341,6 +347,10 @@ msgstr "Alla UART-kringutrustning används" msgid "All event channels in use" msgstr "Alla händelsekanaler används" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "Alla tillståndsmaskiner används" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "Alla händelsekanaler används" @@ -389,6 +399,7 @@ msgstr "AnalogIn stöds inte på angiven pinne" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "AnalogOut-funktionalitet stöds inte" @@ -521,7 +532,6 @@ msgstr "Buffertlängd måste vara en multipel av 512" msgid "Buffer must be a multiple of 512 bytes" msgstr "Bufferten måste vara en multipel av 512 byte" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "Bufferten måste ha minst längd 1" @@ -536,6 +546,7 @@ msgid "Buffer too short by %d bytes" msgstr "Buffert är %d bytes för kort" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -591,6 +602,7 @@ msgstr "Kan inte radera värden" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "Kan inte ange pull i output-läge" @@ -630,6 +642,10 @@ msgid "Cannot reset into bootloader because no bootloader is present." msgstr "" "Det går inte att återställa till bootloader eftersom bootloader saknas." +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "Det går inte att ange socketalternativ" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "Kan inte sätta värde när riktning är input." @@ -812,6 +828,10 @@ msgstr "DAC används redan" msgid "Data 0 pin must be byte aligned" msgstr "Datapinne 0 måste vara bytejusterad" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "Datapinne 0 måste vara byte-justerad." + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "Datasegmentet måste följa fmt-segmentet" @@ -866,7 +886,12 @@ msgstr "EXTINT-kanalen används redan" msgid "Error in regex" msgstr "Fel i regex" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "Fel: Bind misslyckades" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -920,7 +945,7 @@ msgstr "FFT är enbart definierade för ndarrays" msgid "FFT is implemented for linear arrays only" msgstr "FTT är enbart implementerad för linjära matriser" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "Misslyckad SSL-handskakning" @@ -1048,6 +1073,10 @@ msgstr "I/O-operation på stängd fil" msgid "I2C Init Error" msgstr "I2C init-fel" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "I2C-enhet används redan" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "I2SOut är inte tillgängligt" @@ -1073,6 +1102,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "Fel buffertstorlek" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "Storlek på init-program ogiltigt" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "Initieringen misslyckades på grund av minnesbrist" @@ -1085,6 +1118,31 @@ msgstr "Indata tar för lång tid" msgid "Input/output error" msgstr "Indata-/utdatafel" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "Instruktion %d hoppar på pinne" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "Instruktion %d skiftar fler bitar än antalet pinnar" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "Instruktion %d skiftar fler bitar än antal pinnar" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "Instruktion %d använder extra pinne" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "Instruktion %d väntar på inmatning utanför intervallet" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "Otillräcklig autentisering" @@ -1136,7 +1194,7 @@ msgstr "Ogiltig DAC-pinne angiven" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Ogiltig PWM-frekvens" @@ -1230,6 +1288,8 @@ msgstr "Ogiltig pinne för höger kanal" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "Ogiltiga pinnar" @@ -1258,6 +1318,10 @@ msgstr "Ogiltigt säkerhetsläge" msgid "Invalid size" msgstr "Ogiltig storlek" +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "Ogiltig socket för TLS" + #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" msgstr "Ogiltigt tillstånd" @@ -1340,6 +1404,36 @@ msgstr "" msgid "Missing MISO or MOSI Pin" msgstr "MISO- eller MOSI-pinne saknas" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "Saknad first_in_pin. Instruktion %d läser pinnar" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "Saknad first_in_pin. Instruktion %d skiftar in från pinnar" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "Saknad first_in_pin. Instruktion %d väntar baserat på pinne" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "Saknad first_out_pin. Instruktion %d skiftar ut till pinnar" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "Saknad first_out_pin. Instruktion %d skriver till pinnar" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "Saknad first_set_pin. Instruktion %d sätter pinnar" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "Måste vara en %q-subklass." @@ -1393,14 +1487,14 @@ msgstr "Ingen MOSI-pinne" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Ingen RX-pinne" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Ingen TX-pinne" @@ -1457,6 +1551,16 @@ msgstr "Inga fler timers tillgängliga på denna pinne." msgid "No network with that ssid" msgstr "Inget nätverk med sådant ssid" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "Inget out i programmet" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "Ingen pull-up hittades på SDA eller SCL; kontrollera inkopplingen" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "Ingen pulldown på pinnen; 1Mohm rekommenderas" @@ -1514,6 +1618,10 @@ msgstr "Udda paritet stöds inte" msgid "Only 8 or 16 bit mono with " msgstr "Endast 8 eller 16 bitars mono med " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "Endast IN/OUT på upp till 8 stöds" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "Endast IPv4-adresser stöds" @@ -1590,8 +1698,8 @@ msgstr "" "PWM-frekvensen är inte skrivbar när variable_frequency är falsk vid " "skapandet." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "ParallelBus stöds ännu inte" @@ -1604,11 +1712,20 @@ msgstr "Periferi i bruk" msgid "Permission denied" msgstr "Åtkomst nekad" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "Antalet pinnar måste vara minst 1" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "Antal pinnar för stort" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "Pinnen har inte ADC-funktionalitet" @@ -1678,10 +1795,34 @@ msgstr "" msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "Fingerar djup sömn tills larm, Ctrl-C eller filskrivning.\n" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "Program gör IN utan att ladda ISR" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "Program gör OUT utan att läsa in OSR" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "Programmet måste innehålla minst en 16-bitars instruktion." + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "Programstorlek ogiltig" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "Programmet är för stort" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "Pull används inte när riktningen är output." +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "RAISE-läge är inte implementerat" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "RNG DeInit-fel" @@ -1690,6 +1831,10 @@ msgstr "RNG DeInit-fel" msgid "RNG Init Error" msgstr "RNG Init-fel" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "RS485 stöds ännu inte på den här enheten" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1697,6 +1842,7 @@ msgstr "RS485-inversion specificerad när den inte är i RS485-läge" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "RTC-kalibrering stöds inte av detta kort" @@ -1705,7 +1851,7 @@ msgid "RTC is not supported on this board" msgstr "RTC stöds inte av detta kort" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "RTS/CTS/RS485 Stöds ännu inte på den här enheten" @@ -1762,11 +1908,6 @@ msgstr "Kör i säkert läge! " msgid "SD card CSD format not supported" msgstr "SD-kort CSD-format stöds inte" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDA eller SCL behöver en pullup" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1785,6 +1926,10 @@ msgstr "SPI Init-fel" msgid "SPI Re-initialization error" msgstr "SPI reinitialiseringsfel" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "SPI-enhet används redan" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "Samplingsfrekvensen måste vara positiv" @@ -1815,6 +1960,14 @@ msgstr "Serializern används redan" msgid "Server side context cannot have hostname" msgstr "Serversidans kontext kan inte ha värdnamn" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "Inställt antal pinnar måste vara mellan 1 och 5" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "Sido-setets antal pinnar måste vara mellan 1 och 5" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "Storleken stöds inte" @@ -1989,6 +2142,10 @@ msgstr "UART Init-fel" msgid "UART Re-init error" msgstr "UART reinit-fel" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "UART stöds ännu inte" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "UART skrivfel" @@ -2052,7 +2209,7 @@ msgstr "Det gick inte att skriva till sleep_memory." msgid "Unexpected nrfx uuid type" msgstr "Oväntad nrfx uuid-typ" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "Ej hanterat ESP TLS-fel %d-%d-%x-%d" @@ -2095,7 +2252,8 @@ msgstr "" "eller ignorerades." #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "Baudrate stöd inte" @@ -2146,6 +2304,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "VARNING: Ditt filnamn för kod har två tillägg\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "WatchDogTimer kan inte avinitialiseras när läget är inställt på RESET" @@ -2357,7 +2516,7 @@ msgstr "buffertsegmenten måste vara lika långa" msgid "buffer too small" msgstr "buffert för liten" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "buffert för liten för begärd längd" @@ -3353,6 +3512,10 @@ msgstr "inte tillräckligt med argument för formatsträng" msgid "number of points must be at least 2" msgstr "antal punkter måste vara minst 2" +#: py/builtinhelp.c +msgid "object " +msgstr "objekt " + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "objektet '%q' är inte en tuple eller list" @@ -3538,6 +3701,7 @@ msgstr "pow() med 3 argument kräver heltal" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3555,6 +3719,14 @@ msgstr "trycka på startknappen vid start.\n" msgid "pressing both buttons at start up.\n" msgstr "trycka båda knapparna vid uppstart.\n" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "pull_threshold måste vara mellan 1 och 32" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "push_threshold måste vara mellan 1 och 32" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "köstorlek överskreds" @@ -3750,12 +3922,17 @@ msgstr "syntaxfel i uctypes deskriptor" msgid "threshold must be in the range 0-65536" msgstr "tröskelvärdet måste ligga i intervallet 0-65536" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "tile måste vara större än noll" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "time.struct_time() kräver en 9-sekvens" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "timeout-längd överskred det maximala värde som stöds" @@ -3970,6 +4147,10 @@ msgstr "watchdog timeout måste vara större än 0" msgid "width must be greater than zero" msgstr "width måste vara större än noll" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "wifi är inte aktiverat" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "window måste vara <= interval" @@ -4034,6 +4215,18 @@ msgstr "zi måste vara av typ float" msgid "zi must be of shape (n_section, 2)" msgstr "zi måste vara i formen (n_section, 2)" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDA eller SCL behöver en pullup" + +#~ msgid "Invalid use of TLS Socket" +#~ msgstr "Ogiltig användning av TLS Socket" + +#~ msgid "Issue setting SO_REUSEADDR" +#~ msgstr "Misslyckades att sätta SO_REUSEADDR" + +#~ msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +#~ msgstr "%d adresspinnar och %d RGB-pinnar indikerar en höjd av %d, inte %d" + #~ msgid "Unknown failure" #~ msgstr "Okänt fel" diff --git a/locale/zh_Latn_pinyin.po b/locale/zh_Latn_pinyin.po index f073c7317..fa175ca57 100644 --- a/locale/zh_Latn_pinyin.po +++ b/locale/zh_Latn_pinyin.po @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: circuitpython-cn\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-01-04 12:55-0600\n" -"PO-Revision-Date: 2020-11-19 01:28+0000\n" +"PO-Revision-Date: 2021-02-02 03:38+0000\n" "Last-Translator: hexthat <hexthat@gmail.com>\n" "Language-Team: Chinese Hanyu Pinyin\n" "Language: zh_Latn_pinyin\n" @@ -15,19 +15,23 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" -"X-Generator: Weblate 4.4-dev\n" +"X-Generator: Weblate 4.5-dev\n" #: main.c msgid "" "\n" "Code done running.\n" msgstr "" +"\n" +"Dàimǎ yùnxíng wánbì.\n" #: main.c msgid "" "\n" "Code stopped by auto-reload.\n" msgstr "" +"\n" +"zì dòng chóng xīn jiā zǎi tíng zhǐ de dài mǎ.\n" #: supervisor/shared/safe_mode.c msgid "" @@ -47,6 +51,10 @@ msgstr " Wénjiàn \"%q\"" msgid " File \"%q\", line %d" msgstr " Wénjiàn \"%q\", dì %d xíng" +#: py/builtinhelp.c +msgid " is of type %q\n" +msgstr " shì %q lèi xíng\n" + #: main.c msgid " output:\n" msgstr " shūchū:\n" @@ -58,9 +66,11 @@ msgstr "%%c xūyào zhěngshù huò char" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format -msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +msgid "" +"%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" -"%d dìzhǐ yǐn jiǎo hé %d rgb yǐn jiǎo jiāng gāodù biǎoshì wèi %d, ér bùshì %d" +"%d de zhǐ yǐn jiǎo , %d rgb yǐn jiǎo hé %d qiē piàn biǎo shì %d de gāo dù, " +"ér bù shì %d" #: ports/atmel-samd/common-hal/sdioio/SDCard.c msgid "%q failure: %d" @@ -121,7 +131,7 @@ msgstr "%q() cǎiyòng %d wèizhì cānshù, dàn gěi chū %d" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c #, c-format msgid "%s error 0x%x" -msgstr "" +msgstr "%s cuò wù 0x%x" #: py/argcheck.c msgid "'%q' argument required" @@ -287,7 +297,7 @@ msgstr "bù zhīchí 3-arg pow ()" #: shared-module/msgpack/__init__.c msgid "64 bit types" -msgstr "" +msgstr "64 wèi lèi xíng" #: ports/atmel-samd/common-hal/countio/Counter.c #: ports/atmel-samd/common-hal/rotaryio/IncrementalEncoder.c @@ -339,6 +349,10 @@ msgstr "Suǒyǒu UART wàiwéi zhèngzài shǐyòng" msgid "All event channels in use" msgstr "Suǒyǒu shǐyòng de shìjiàn píndào" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "All state machines in use" +msgstr "suǒ yǒu zhèng zài shǐ yòng de zhuàng tài jī" + #: ports/atmel-samd/audio_dma.c ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "All sync event channels in use" msgstr "Suǒyǒu tóngbù shìjiàn píndào shǐyòng" @@ -387,6 +401,7 @@ msgstr "Gěi dìng de yǐn jiǎo bù zhīchí AnalogIn" #: ports/cxd56/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/analogio/AnalogOut.c msgid "AnalogOut functionality not supported" msgstr "Bù zhīchí AnalogOut gōngnéng" @@ -519,7 +534,6 @@ msgstr "Huǎn chōng qū cháng dù bì xū wéi 512 de bèi shù" msgid "Buffer must be a multiple of 512 bytes" msgstr "Huǎn chōng qū bì xū shì 512 zì jié de bèi shù" -#: shared-bindings/adafruit_bus_device/I2CDevice.c #: shared-bindings/bitbangio/I2C.c shared-bindings/busio/I2C.c msgid "Buffer must be at least length 1" msgstr "Huǎnchōng qū bìxū zhìshǎo chángdù 1" @@ -534,6 +548,7 @@ msgid "Buffer too short by %d bytes" msgstr "Huǎn chōng qū tài duǎn , àn %d zì jié" #: ports/atmel-samd/common-hal/displayio/ParallelBus.c +#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/nrf/common-hal/displayio/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" @@ -553,7 +568,7 @@ msgstr "CBC kuài bì xū shì 16 zì jié de bèi shù" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "CRC or checksum was invalid" -msgstr "" +msgstr "CRC huò jiào yàn hé wú xiào" #: py/objtype.c msgid "Call super().__init__() before accessing native object." @@ -561,15 +576,17 @@ msgstr "Zài fǎngwèn běn jī wùjiàn zhīqián diàoyòng super().__init__() #: ports/esp32s2/common-hal/alarm/pin/PinAlarm.c msgid "Can only alarm on RTC IO from deep sleep." -msgstr "" +msgstr "zhǐ néng zài RTC Io shàng cóng shēn dù shuì mián zhōng bào jǐng." #: ports/esp32s2/common-hal/alarm/pin/PinAlarm.c msgid "Can only alarm on one low pin while others alarm high from deep sleep." msgstr "" +"Zhǐ néng zài yīgè dī diàn píng yǐn jiǎo shàng fāchū jǐngbào, ér qítā yǐn " +"jiǎo cóng shēndù shuìmián zhōng fāchū gāo diàn píng jǐngbào." #: ports/esp32s2/common-hal/alarm/pin/PinAlarm.c msgid "Can only alarm on two low pins from deep sleep." -msgstr "" +msgstr "zhǐ néng cóng shēn dù shuì mián zhōng bào jǐng liǎng gè dī yǐn jiǎo." #: ports/nrf/common-hal/_bleio/Characteristic.c msgid "Can't set CCCD on local Characteristic" @@ -588,6 +605,7 @@ msgstr "Wúfǎ shānchú zhí" #: ports/atmel-samd/common-hal/digitalio/DigitalInOut.c #: ports/mimxrt10xx/common-hal/digitalio/DigitalInOut.c #: ports/nrf/common-hal/digitalio/DigitalInOut.c +#: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" msgstr "Zài shūchū móshì xià wúfǎ huòqǔ lādòng" @@ -605,7 +623,7 @@ msgstr "Wúfǎ shūchū tóng yīgè yǐn jiǎo shàng de liǎng gè píndào" #: ports/esp32s2/common-hal/alarm/pin/PinAlarm.c msgid "Cannot pull on input-only pin." -msgstr "" +msgstr "wú fǎ lā dòng jǐn shū rù yǐn jiǎo." #: shared-module/bitbangio/SPI.c msgid "Cannot read without MISO pin." @@ -625,6 +643,10 @@ msgstr "USB jīhuó shí wúfǎ chóngxīn bǎng ding '/'." msgid "Cannot reset into bootloader because no bootloader is present." msgstr "Wúfǎ chóng zhì wèi bootloader, yīnwèi méiyǒu bootloader cúnzài." +#: ports/esp32s2/common-hal/socketpool/Socket.c +msgid "Cannot set socket options" +msgstr "" + #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." msgstr "Dāng fāngxiàng xiàng nèi shí, bùnéng shèzhì gāi zhí." @@ -652,7 +674,7 @@ msgstr "Wúfǎ gēnggǎi yǐ zài shǐyòng de jìshí qì shàng de pínlǜ" #: ports/esp32s2/common-hal/alarm/pin/PinAlarm.c msgid "Cannot wake on pin edge. Only level." -msgstr "" +msgstr "wú fǎ zài yǐn jiǎo biān yuán huàn xǐng. jǐn jí bié." #: shared-module/bitbangio/SPI.c msgid "Cannot write without MOSI pin." @@ -805,6 +827,10 @@ msgstr "Fā yuán huì yǐjīng shǐyòng" msgid "Data 0 pin must be byte aligned" msgstr "Shùjù 0 de yǐn jiǎo bìxū shì zì jié duìqí" +#: ports/esp32s2/common-hal/displayio/ParallelBus.c +msgid "Data 0 pin must be byte aligned." +msgstr "shù jù 0 yǐn jiǎo bì xū àn zì jié duì qí." + #: shared-module/audiocore/WaveFile.c msgid "Data chunk must follow fmt chunk" msgstr "Shùjù kuài bìxū zūnxún fmt qū kuài" @@ -859,7 +885,12 @@ msgstr "EXTINT píndào yǐjīng shǐyòng" msgid "Error in regex" msgstr "Zhèngzé biǎodá shì cuòwù" -#: py/enum.c shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c +msgid "Error: Failure to bind" +msgstr "cuò wù: bǎng dìng shī bài" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c py/enum.c +#: shared-bindings/_bleio/__init__.c shared-bindings/aesio/aes.c #: shared-bindings/busio/SPI.c shared-bindings/microcontroller/Pin.c #: shared-bindings/neopixel_write/__init__.c #: shared-bindings/terminalio/Terminal.c @@ -894,7 +925,7 @@ msgstr "Qídài yīgè dìzhǐ" #: shared-bindings/alarm/__init__.c msgid "Expected an alarm" -msgstr "" +msgstr "yù qī yǒu jǐng bào" #: shared-module/_pixelbuf/PixelBuf.c #, c-format @@ -911,9 +942,9 @@ msgstr "FFT jǐn wéi ndarrays dìng yì" #: extmod/ulab/code/fft/fft.c msgid "FFT is implemented for linear arrays only" -msgstr "" +msgstr "FFT jǐn shì yòng yú xiàn xìng zhèn liè" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" msgstr "SSL wòshǒu shībài" @@ -985,7 +1016,7 @@ msgstr "guò lǜ qì tài fù zá" #: ports/esp32s2/common-hal/dualbank/__init__.c msgid "Firmware image is invalid" -msgstr "" +msgstr "gù jiàn yìng xiàng wú xiào" #: ports/cxd56/common-hal/camera/Camera.c msgid "Format not supported" @@ -1007,7 +1038,7 @@ msgstr "Hánshù xūyào suǒdìng" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Generic Failure" -msgstr "" +msgstr "tōng yòng gù zhàng" #: shared-bindings/displayio/Display.c #: shared-bindings/displayio/EPaperDisplay.c @@ -1041,13 +1072,17 @@ msgstr "Wénjiàn shàng de I/ O cāozuò" msgid "I2C Init Error" msgstr "I2C chūshǐhuà cuòwù" +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "I2C peripheral in use" +msgstr "I2C wài shè zhèng zài shǐ yòng zhōng" + #: shared-bindings/audiobusio/I2SOut.c msgid "I2SOut not available" msgstr "I2SOut bù kě yòng" #: ports/esp32s2/common-hal/alarm/pin/__init__.c msgid "IOs 0, 2 & 4 do not support internal pullup in sleep" -msgstr "" +msgstr "IOS 0, 2 + 4 bù zhī chí shuì mián zhōng de nèi bù shàng lā" #: shared-bindings/aesio/aes.c #, c-format @@ -1066,6 +1101,10 @@ msgstr "" msgid "Incorrect buffer size" msgstr "Huǎnchōng qū dàxiǎo bù zhèngquè" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Init program size invalid" +msgstr "Init chéng xù dà xiǎo wú xiào" + #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" msgstr "yóu yú nèi cún bù zú, chū shǐ huà shī bài" @@ -1078,6 +1117,31 @@ msgstr "Shūrù shíjiānguò zhǎng" msgid "Input/output error" msgstr "Shūrù/shūchū cuòwù" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d jumps on pin" +msgstr "zhǐ lìng %d zài yǐn jiǎo shàng tiào zhuǎn" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts in more bits than pin count" +msgstr "zhǐ lìng %d yí wèi chāo guò yǐn jiǎo jì shù" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d shifts out more bits than pin count" +msgstr "zhǐ lìng %d yí chū de wèi bǐ yǐn jiǎo shù duō" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d uses extra pin" +msgstr "zhǐ lìng %d shǐ yòng é wài de yǐn jiǎo" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Instruction %d waits on input outside of count" +msgstr "zhǐ lìng %d děng dài jì shù zhī wài de shū rù" + #: ports/nrf/common-hal/_bleio/__init__.c msgid "Insufficient authentication" msgstr "Rènzhèng bùzú" @@ -1129,13 +1193,13 @@ msgstr "Tí gōng liǎo wúxiào de DAC yǐn jiǎo" #: ports/atmel-samd/common-hal/pwmio/PWMOut.c #: ports/cxd56/common-hal/pwmio/PWMOut.c ports/nrf/common-hal/pwmio/PWMOut.c -#: shared-bindings/pwmio/PWMOut.c +#: ports/raspberrypi/common-hal/pwmio/PWMOut.c shared-bindings/pwmio/PWMOut.c msgid "Invalid PWM frequency" msgstr "Wúxiào de PWM pínlǜ" #: ports/esp32s2/common-hal/analogio/AnalogIn.c msgid "Invalid Pin" -msgstr "" +msgstr "wú xiào yǐn jiǎo" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c #: py/moduerrno.c shared-module/rgbmatrix/RGBMatrix.c @@ -1223,6 +1287,8 @@ msgstr "Yòuxián tōngdào yǐn jiǎo wúxiào" #: ports/mimxrt10xx/common-hal/busio/I2C.c #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/SPI.c msgid "Invalid pins" msgstr "Wúxiào de yǐn jiǎo" @@ -1249,11 +1315,15 @@ msgstr "Ānquán móshì wúxiào" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid size" -msgstr "" +msgstr "dà xiǎo wú xiào" + +#: ports/esp32s2/common-hal/ssl/SSLContext.c +msgid "Invalid socket for TLS" +msgstr "TLS de chā zuò wú xiào" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Invalid state" -msgstr "" +msgstr "wú xiào zhuàng tài" #: shared-bindings/audiomixer/Mixer.c msgid "Invalid voice" @@ -1297,7 +1367,7 @@ msgstr "Chángdù bìxū shìfēi fùshù" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "MAC address was invalid" -msgstr "" +msgstr "MAC dì zhǐ wú xiào" #: shared-module/bitbangio/SPI.c msgid "MISO pin init failed." @@ -1332,6 +1402,37 @@ msgstr "Màikèfēng qǐdòng yánchí bìxū zài 0.0 Dào 1.0 De fànwéi nèi msgid "Missing MISO or MOSI Pin" msgstr "Quēshǎo MISO huò MOSI yǐn jiǎo" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d reads pin(s)" +msgstr "shǒu xiān zài yǐn jiǎo zhōng quē shī. zhǐ lìng %d dú qǔ yǐn jiǎo" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d shifts in from pin(s)" +msgstr "shǒu xiān zài yǐn jiǎo zhōng quē shī. zhǐ lìng %d cóng yǐn jiǎo yí wèi" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_in_pin. Instruction %d waits based on pin" +msgstr "" +"shǒu xiān zài yǐn jiǎo zhōng quē shī. jī yú yǐn jiǎo de zhǐ lìng %d děng dài" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d shifts out to pin(s)" +msgstr "xiān lòu chū yǐn jiǎo. zhǐ lìng %d yí chū dào yǐn jiǎo" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_out_pin. Instruction %d writes pin(s)" +msgstr "xiān lòu chū yǐn jiǎo. zhǐ lìng %d xiě rù yǐn jiǎo" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +#, c-format +msgid "Missing first_set_pin. Instruction %d sets pin(s)" +msgstr "quē shǎo dì yī zǔ yǐn jiǎo. zhǐ lìng %d shè zhì yǐn jiǎo" + #: shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "Bìxū shì %q zi lèi." @@ -1347,7 +1448,7 @@ msgstr "bì xū shǐ yòng 6 RGB yǐn jiǎo de bèi shù, ér bù shì %d" #: ports/esp32s2/common-hal/nvm/ByteArray.c msgid "NVS Error" -msgstr "" +msgstr "NVS cuò wù" #: py/parse.c msgid "Name too long" @@ -1370,7 +1471,7 @@ msgstr "Wèi zhǎodào DMA píndào" #: shared-module/adafruit_bus_device/I2CDevice.c #, c-format msgid "No I2C device at address: %x" -msgstr "" +msgstr "dì zhǐ wú I2C shè bèi: %x" #: ports/esp32s2/common-hal/busio/SPI.c ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/stm/common-hal/busio/SPI.c @@ -1385,14 +1486,14 @@ msgstr "Méiyǒu MOSI yǐn jiǎo" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No RX pin" msgstr "Wèi zhǎodào RX yǐn jiǎo" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c -#: ports/stm/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c msgid "No TX pin" msgstr "Wèi zhǎodào TX yǐn jiǎo" @@ -1449,6 +1550,16 @@ msgstr "Gāi yǐn jiǎo shàng méiyǒu kěyòng de dìngshí qì." msgid "No network with that ssid" msgstr "Méiyǒu wǎngluò yǔ gāi ssid" +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "No out in program" +msgstr "chéng xù zhōng wèi tuì chū" + +#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c +#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c +#: ports/raspberrypi/common-hal/busio/I2C.c +msgid "No pull up found on SDA or SCL; check your wiring" +msgstr "" + #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" msgstr "Yǐn jiǎo shàng méiyǒu xiàlā; 1Mohm tuījiàn" @@ -1505,13 +1616,17 @@ msgstr "Bù zhīchí jīshù" msgid "Only 8 or 16 bit mono with " msgstr "Zhǐyǒu 8 huò 16 wèi dānwèi " +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Only IN/OUT of up to 8 supported" +msgstr "jǐn zhī chí zuì duō 8 gè IN/OUT" + #: ports/esp32s2/common-hal/wifi/__init__.c msgid "Only IPv4 addresses supported" msgstr "Jǐn zhīchí IPv4 dìzhǐ" #: ports/esp32s2/common-hal/socketpool/SocketPool.c msgid "Only IPv4 sockets supported" -msgstr "" +msgstr "jǐn zhī chí IPv4 tào jiē zì" #: shared-module/displayio/OnDiskBitmap.c #, c-format @@ -1532,11 +1647,11 @@ msgstr "" #: ports/esp32s2/common-hal/alarm/touch/TouchAlarm.c msgid "Only one TouchAlarm can be set in deep sleep." -msgstr "" +msgstr "zhǐ yǒu yí gè chù mō bì kě yǐ shè zhì zài shēn dù shuì mián." #: ports/esp32s2/common-hal/alarm/time/TimeAlarm.c msgid "Only one alarm.time alarm can be set." -msgstr "" +msgstr "zhǐ néng shè zhì yí gè bào jǐng." #: shared-module/displayio/ColorConverter.c msgid "Only one color can be transparent at a time" @@ -1548,15 +1663,15 @@ msgstr "Ip jǐn zhīchí raw int" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Operation or feature not supported" -msgstr "" +msgstr "bù zhī chí cāo zuò huò gōng néng" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Operation timed out" -msgstr "" +msgstr "cāo zuò yǐ fēn shí" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Out of memory" -msgstr "" +msgstr "nèi cún bù zú" #: ports/esp32s2/common-hal/socketpool/SocketPool.c msgid "Out of sockets" @@ -1568,7 +1683,7 @@ msgstr "Guò cǎiyàng bìxū shì 8 de bèishù." #: shared-bindings/audiobusio/PDMIn.c msgid "PDMIn not available" -msgstr "" +msgstr "PDMIn bù kě yòng" #: shared-bindings/pwmio/PWMOut.c msgid "" @@ -1581,25 +1696,34 @@ msgid "" "PWM frequency not writable when variable_frequency is False on construction." msgstr "Dāng biànliàng_pínlǜ shì False zài jiànzhú shí PWM pínlǜ bùkě xiě." -#: ports/esp32s2/common-hal/displayio/ParallelBus.c #: ports/mimxrt10xx/common-hal/displayio/ParallelBus.c +#: ports/raspberrypi/common-hal/displayio/ParallelBus.c #: ports/stm/common-hal/displayio/ParallelBus.c msgid "ParallelBus not yet supported" msgstr "Shàng bù zhīchí ParallelBus" #: ports/esp32s2/common-hal/audiobusio/__init__.c msgid "Peripheral in use" -msgstr "" +msgstr "shǐ yòng zhōng de wài shè" #: py/moduerrno.c msgid "Permission denied" msgstr "Quánxiàn bèi jùjué" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Pin count must be at least 1" +msgstr "yǐn jiǎo jì shù bì xū zhì shǎo wéi 1" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Pin count too large" +msgstr "yǐn jiǎo jì shù tài dà" + #: ports/atmel-samd/common-hal/analogio/AnalogIn.c #: ports/cxd56/common-hal/analogio/AnalogIn.c #: ports/esp32s2/common-hal/analogio/AnalogIn.c #: ports/mimxrt10xx/common-hal/analogio/AnalogIn.c #: ports/nrf/common-hal/analogio/AnalogIn.c +#: ports/raspberrypi/common-hal/analogio/AnalogIn.c #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Pin does not have ADC capabilities" msgstr "Pin méiyǒu ADC nénglì" @@ -1658,16 +1782,42 @@ msgstr "Qiánzhuì huǎnchōng qū bìxū zài duī shàng" #: main.c msgid "Press any key to enter the REPL. Use CTRL-D to reload.\n" -msgstr "" +msgstr "àn rèn hé jiàn jìn rù REPL. shǐ yòng CTRL-D zhòng xīn jiā zǎi .\n" #: main.c msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" msgstr "" +"jiǎ zhuāng shēn dù shuì mián , zhí dào bào jǐng , CTRL-C huò wén jiàn xiě " +"rù .\n" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does IN without loading ISR" +msgstr "chéng xù zài bù jiā zǎi ISR de qíng kuàng xià wán chéng" + +#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c +msgid "Program does OUT without loading OSR" +msgstr "chéng xù zài bù jiā zǎi Osr de qíng kuàng xià zhí xíng OUT" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program must contain at least one 16-bit instruction." +msgstr "chéng xù bì xū zhì shǎo bāo hán yí gè 16 wèi zhǐ lìng ." + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program size invalid" +msgstr "chéng xù dà xiǎo wú xiào" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Program too large" +msgstr "chéng xù tài dà" #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." msgstr "Fāngxiàng shūchū shí Pull méiyǒu shǐyòng." +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c +msgid "RAISE mode is not implemented" +msgstr "wèi shí xiàn tí shēng mó shì" + #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" msgstr "RNG qǔxiāo chūshǐhuà cuòwù" @@ -1676,6 +1826,10 @@ msgstr "RNG qǔxiāo chūshǐhuà cuòwù" msgid "RNG Init Error" msgstr "RNG chūshǐhuà cuòwù" +#: ports/nrf/common-hal/busio/UART.c +msgid "RS485 Not yet supported on this device" +msgstr "" + #: ports/esp32s2/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" @@ -1683,6 +1837,7 @@ msgstr "Wèi chǔyú RS485 móshì shí zhǐdìngle RS485 fǎn zhuǎn" #: ports/cxd56/common-hal/rtc/RTC.c ports/esp32s2/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/rtc/RTC.c +#: ports/raspberrypi/common-hal/rtc/RTC.c msgid "RTC calibration is not supported on this board" msgstr "Cǐ bǎn bù zhīchí RTC jiàozhǔn" @@ -1691,7 +1846,7 @@ msgid "RTC is not supported on this board" msgstr "Cǐ bǎn bù zhīchí RTC" #: ports/atmel-samd/common-hal/busio/UART.c ports/cxd56/common-hal/busio/UART.c -#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c +#: ports/stm/common-hal/busio/UART.c msgid "RTS/CTS/RS485 Not yet supported on this device" msgstr "RTS/CTS/RS485 gāi shèbèi shàng bù zhīchí" @@ -1714,7 +1869,7 @@ msgstr "Zhǐ dú duìxiàng" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Received response was invalid" -msgstr "" +msgstr "shōu dào de xiǎng yìng wú xiào" #: shared-bindings/displayio/EPaperDisplay.c msgid "Refresh too soon" @@ -1730,7 +1885,7 @@ msgstr "Qǐngqiú de AES móshì bù shòu zhīchí" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Requested resource not found" -msgstr "" +msgstr "wèi zhǎo dào qǐng qiú de zī yuán" #: ports/atmel-samd/common-hal/audioio/AudioOut.c msgid "Right channel unsupported" @@ -1748,11 +1903,6 @@ msgstr "Zài ānquán móshì xià yùnxíng! " msgid "SD card CSD format not supported" msgstr "Bù zhīchí SD kǎ CSD géshì" -#: ports/atmel-samd/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/I2C.c -#: ports/mimxrt10xx/common-hal/busio/I2C.c ports/nrf/common-hal/busio/I2C.c -msgid "SDA or SCL needs a pull up" -msgstr "SDA huò SCL xūyào lādòng" - #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" @@ -1771,6 +1921,10 @@ msgstr "SPI chūshǐhuà cuòwù" msgid "SPI Re-initialization error" msgstr "SPI chóngxīn chūshǐhuà cuòwù" +#: ports/raspberrypi/common-hal/busio/SPI.c +msgid "SPI peripheral in use" +msgstr "SPI wài shè zhèng zài shǐ yòng zhōng" + #: shared-bindings/audiomixer/Mixer.c msgid "Sample rate must be positive" msgstr "Cǎiyàng lǜ bìxū wèi zhèng shù" @@ -1801,6 +1955,14 @@ msgstr "Xùliè huà yǐjīng shǐyòngguò" msgid "Server side context cannot have hostname" msgstr "Fúwùqì duān shàngxiàwén bùnéng jùyǒu zhǔjī míng" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Set pin count must be between 1 and 5" +msgstr "shè zhì yǐn jiǎo shù bì xū jiè yú 1 hé 5 zhī jiān" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "Side set pin count must be between 1 and 5" +msgstr "cè miàn shè zhì yǐn jiǎo shù bì xū jiè yú 1 hé 5 zhī jiān" + #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" msgstr "bù zhī chí dà xiǎo" @@ -1842,7 +2004,7 @@ msgstr "Dìngyì zhìshǎo yīgè UART yǐn jiǎo" #: shared-bindings/alarm/time/TimeAlarm.c msgid "Supply one of monotonic_time or epoch_time" -msgstr "" +msgstr "tí gòng qí zhōng yī monotonic_time huò epoch_time" #: shared-bindings/gnss/GNSS.c msgid "System entry must be gnss.SatelliteSystem" @@ -1916,7 +2078,7 @@ msgstr "Píng pū kuāndù bìxū huàfēn wèi tú kuāndù" #: shared-bindings/alarm/time/TimeAlarm.c msgid "Time is in the past." -msgstr "" +msgstr "shí jiān yǐ jīng guò qù." #: ports/nrf/common-hal/_bleio/Adapter.c #, c-format @@ -1974,6 +2136,10 @@ msgstr "UART chūshǐhuà cuòwù" msgid "UART Re-init error" msgstr "UART chóngxīn chūshǐhuà cuòwù" +#: ports/raspberrypi/common-hal/busio/UART.c +msgid "UART not yet supported" +msgstr "UART shàng wèi shòu zhī chí" + #: ports/stm/common-hal/busio/UART.c msgid "UART write error" msgstr "UART xiě cuòwù" @@ -2031,13 +2197,13 @@ msgstr "Wúfǎ xiě rù nvm." #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." -msgstr "" +msgstr "wú fǎ xiě rù sleep_memory。" #: ports/nrf/common-hal/_bleio/UUID.c msgid "Unexpected nrfx uuid type" msgstr "Yìwài de nrfx uuid lèixíng" -#: ports/esp32s2/common-hal/socketpool/Socket.c +#: ports/esp32s2/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" msgstr "Wèi chǔlǐ de ESP TLS cuòwù %d %d %x %d" @@ -2045,7 +2211,7 @@ msgstr "Wèi chǔlǐ de ESP TLS cuòwù %d %d %x %d" #: shared-bindings/wifi/Radio.c #, c-format msgid "Unknown failure %d" -msgstr "" +msgstr "wèi zhī gù zhàng %d" #: ports/nrf/common-hal/_bleio/__init__.c #, c-format @@ -2080,7 +2246,8 @@ msgstr "" "huò hūlüè." #: ports/atmel-samd/common-hal/busio/I2C.c ports/cxd56/common-hal/busio/I2C.c -#: ports/esp32s2/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c +#: ports/esp32s2/common-hal/busio/UART.c +#: ports/raspberrypi/common-hal/busio/I2C.c ports/stm/common-hal/busio/I2C.c msgid "Unsupported baudrate" msgstr "Bù zhīchí de baudrate" @@ -2102,7 +2269,7 @@ msgstr "Bù zhīchí de lādòng zhí." #: ports/esp32s2/common-hal/dualbank/__init__.c msgid "Update Failed" -msgstr "" +msgstr "gēng xīn shī bài" #: ports/nrf/common-hal/_bleio/Characteristic.c #: ports/nrf/common-hal/_bleio/Descriptor.c @@ -2116,7 +2283,7 @@ msgstr "Zhí chángdù > zuìdà chángdù" #: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c msgid "Version was invalid" -msgstr "" +msgstr "bǎn běn wú xiào" #: py/emitnative.c msgid "Viper functions don't currently support more than 4 arguments" @@ -2131,6 +2298,7 @@ msgid "WARNING: Your code filename has two extensions\n" msgstr "Jǐnggào: Nǐ de dàimǎ wénjiàn míng yǒu liǎng gè kuòzhǎn míng\n" #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "WatchDogTimer cannot be deinitialized once mode is set to RESET" msgstr "Yīdàn jiāng móshì shèzhì wèi RESET, jiù wúfǎ chūshǐhuà WatchDog Timer" @@ -2173,7 +2341,7 @@ msgstr "WiFi mìmǎ bìxū jiè yú 8 dào 63 gè zìfú zhī jiān" #: main.c msgid "Woken up by alarm.\n" -msgstr "" +msgstr "bèi jǐng bào chǎo xǐng.\n" #: ports/nrf/common-hal/_bleio/PacketBuffer.c msgid "Writes not supported on Characteristic" @@ -2230,7 +2398,7 @@ msgstr "argsort cānshù bìxū shì ndarray" #: extmod/ulab/code/numerical/numerical.c msgid "argsort is not implemented for flattened arrays" -msgstr "" +msgstr "wèi wéi pīn hé shù zǔ shí xiàn argsort" #: py/runtime.c msgid "argument has wrong type" @@ -2255,7 +2423,7 @@ msgstr "cānshù bìxū shì ndarrays" #: extmod/ulab/code/ndarray.c msgid "array and index length must be equal" -msgstr "" +msgstr "shù zǔ hé suǒ yǐn cháng dù bì xū xiāng děng" #: py/objarray.c shared-bindings/alarm/SleepMemory.c #: shared-bindings/nvm/ByteArray.c @@ -2264,7 +2432,7 @@ msgstr "yòu cè xūyào shùzǔ/zì jié" #: extmod/ulab/code/numerical/numerical.c msgid "attempt to get (arg)min/(arg)max of empty sequence" -msgstr "" +msgstr "cháng shì huò qǔ (arg) zuì xiǎo zhí /(arg) zuì dà kōng xù liè" #: extmod/ulab/code/numerical/numerical.c msgid "attempt to get argmin/argmax of an empty sequence" @@ -2276,15 +2444,15 @@ msgstr "shǔxìng shàngwèi zhīchí" #: extmod/ulab/code/numerical/numerical.c msgid "axis is out of bounds" -msgstr "" +msgstr "zhóu chāo chū biān jiè" #: extmod/ulab/code/numerical/numerical.c msgid "axis must be None, or an integer" -msgstr "" +msgstr "zhóu bì xū wéi \" wú \" huò zhěng shù" #: extmod/ulab/code/numerical/numerical.c msgid "axis too long" -msgstr "" +msgstr "zhóu tài cháng" #: py/builtinevex.c msgid "bad compile mode" @@ -2320,7 +2488,7 @@ msgstr "fēnzhī bùzài fànwéi nèi" #: extmod/ulab/code/ulab_create.c msgid "buffer is smaller than requested size" -msgstr "" +msgstr "huǎn chōng qū xiǎo yú qǐng qiú de dà xiǎo" #: shared-bindings/audiocore/RawSample.c msgid "buffer must be a bytes-like object" @@ -2328,7 +2496,7 @@ msgstr "huǎnchōng qū bìxū shì zì jié lèi duìxiàng" #: extmod/ulab/code/ulab_create.c msgid "buffer size must be a multiple of element size" -msgstr "" +msgstr "huǎn chōng qū dà xiǎo bì xū shì yuán sù dà xiǎo de bèi shù" #: shared-module/struct/__init__.c msgid "buffer size must match format" @@ -2343,7 +2511,7 @@ msgstr "huǎnchōng qū qiēpiàn bìxū chángdù xiāngděng" msgid "buffer too small" msgstr "huǎnchōng qū tài xiǎo" -#: shared-bindings/socketpool/Socket.c +#: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" msgstr "huǎn chōng qū tài xiǎo, duì yú qǐng qiú de zì jié" @@ -2498,6 +2666,7 @@ msgstr "wúfǎ cóng shǒudòng zìduàn guīgé qiēhuàn dào zìdòng zìduà #: extmod/ulab/code/ndarray_operators.c msgid "cannot cast output with casting rule" msgstr "" +"wú fǎ shǐ yòng qiáng zhì zhuǎn huàn guī zé qiáng zhì zhuǎn huàn shū chū" #: py/objtype.c msgid "cannot create '%q' instances" @@ -2537,7 +2706,7 @@ msgstr "quānzi zhǐ néng zài yī wèi jiāzhǎng zhōng zhùcè" #: shared-bindings/msgpack/ExtType.c msgid "code outside range 0~127" -msgstr "" +msgstr "dài mǎ chāo chū fàn wéi 0~127" #: shared-bindings/displayio/Palette.c msgid "color buffer must be 3 bytes (RGB) or 4 bytes (RGB + pad byte)" @@ -2604,7 +2773,7 @@ msgstr "wúfǎ quèdìng SD kǎ bǎnběn" #: extmod/ulab/code/numerical/numerical.c msgid "cross is defined for 1D arrays of length 3" -msgstr "" +msgstr "duì yú cháng dù wéi 3 de 1D shù zǔ dìng yì cross" #: extmod/ulab/code/approx/approx.c msgid "data must be iterable" @@ -2616,7 +2785,7 @@ msgstr "shùjù chángdù bìxū xiāngděng" #: extmod/ulab/code/ndarray.c msgid "data type not understood" -msgstr "" +msgstr "wèi lǐ jiě de shù jù lèi xíng" #: py/parsenum.c msgid "decimal numbers not supported" @@ -2628,7 +2797,7 @@ msgstr "mòrèn 'except' bìxū shì zuìhòu yīgè" #: shared-bindings/msgpack/__init__.c msgid "default is not a function" -msgstr "" +msgstr "mò rèn zhí bú shì hán shù" #: shared-bindings/audiobusio/PDMIn.c msgid "" @@ -2655,7 +2824,7 @@ msgstr "bùtóng de cānshù bìxū shì ndarray" #: extmod/ulab/code/numerical/numerical.c msgid "differentiation order out of range" -msgstr "" +msgstr "chā yì shùn xù fàn wéi" #: py/modmath.c py/objfloat.c py/objint_longlong.c py/objint_mpz.c py/runtime.c #: shared-bindings/math/__init__.c @@ -2688,7 +2857,7 @@ msgstr "jiéwěi_x yīnggāi shì yīgè zhěngshù" #: shared-bindings/alarm/time/TimeAlarm.c msgid "epoch_time not supported on this board" -msgstr "" +msgstr "epoch_time bǎn bù zhī chí cǐ bǎn běn" #: ports/nrf/common-hal/busio/UART.c #, c-format @@ -2733,7 +2902,7 @@ msgstr "qídài guānjiàn: Zìdiǎn de jiàzhí" #: shared-bindings/msgpack/__init__.c msgid "ext_hook is not a function" -msgstr "" +msgstr "ext_hook bú shì hán shù" #: py/argcheck.c msgid "extra keyword arguments given" @@ -2782,7 +2951,7 @@ msgstr "dì yīgè cānshù bìxū shì yī gè hánshù" #: extmod/ulab/code/ulab_create.c msgid "first argument must be a tuple of ndarrays" -msgstr "" +msgstr "dì yī gè cān shù bì xū shì yí gè yuán zǔ ndarrays" #: extmod/ulab/code/ndarray.c msgid "first argument must be an iterable" @@ -2839,7 +3008,7 @@ msgstr "hánshù zài jiàngé mòwěi jùyǒu xiāngtóng de fúhào" #: extmod/ulab/code/ndarray.c msgid "function is defined for ndarrays only" -msgstr "" +msgstr "hán shù jǐn wéi ndarrays dìng yì" #: py/argcheck.c #, c-format @@ -2935,11 +3104,11 @@ msgstr "nèi lián jíhé bìxū shì yīgè hánshù" #: extmod/ulab/code/ndarray.c msgid "input and output shapes are not compatible" -msgstr "" +msgstr "shū rù hé shū chū xíng zhuàng bù jiān róng" #: extmod/ulab/code/ulab_create.c msgid "input argument must be an integer, a tuple, or a list" -msgstr "" +msgstr "shū rù cān shù bì xū shì zhěng shù, yuán zǔ huò liè biǎo" #: extmod/ulab/code/fft/fft.c msgid "input array length must be power of 2" @@ -2947,7 +3116,7 @@ msgstr "shūrù shùzǔ de chángdù bìxū shì 2 de mì" #: extmod/ulab/code/ulab_create.c msgid "input arrays are not compatible" -msgstr "" +msgstr "shū rù shù zǔ bù jiān róng" #: extmod/ulab/code/poly/poly.c msgid "input data must be an iterable" @@ -2963,19 +3132,19 @@ msgstr "shūrù jǔzhèn shì qíyì de" #: extmod/ulab/code/user/user.c msgid "input must be a dense ndarray" -msgstr "" +msgstr "shū rù bì xū shì mì jí de ndarray" #: extmod/ulab/code/ulab_create.c msgid "input must be a tensor of rank 2" -msgstr "" +msgstr "shū rù bì xū shì děng jí 2 de zhāng liàng" #: extmod/ulab/code/ulab_create.c extmod/ulab/code/user/user.c msgid "input must be an ndarray" -msgstr "" +msgstr "shū rù bì xū shì ndarray" #: extmod/ulab/code/filter/filter.c msgid "input must be one-dimensional" -msgstr "" +msgstr "shū rù bì xū shì yì wéi de" #: extmod/ulab/code/linalg/linalg.c msgid "input must be square matrix" @@ -2991,7 +3160,7 @@ msgstr "shūrù xiàngliàng de chángdù bìxū xiāngděng" #: extmod/ulab/code/poly/poly.c msgid "inputs are not iterable" -msgstr "" +msgstr "shū rù bù kě yí dòng" #: py/parsenum.c msgid "int() arg 2 must be >= 2 and <= 36" @@ -3065,7 +3234,7 @@ msgstr "wúxiào de hàomǎ yǔfǎ" #: ports/esp32s2/common-hal/alarm/pin/__init__.c msgid "io must be rtc io" -msgstr "" +msgstr "IO bì xū shì RTC IO" #: py/objtype.c msgid "issubclass() arg 1 must be a class" @@ -3164,11 +3333,11 @@ msgstr "Dāng gùdìng chángdù wèi %s shí, zuìdà chángdù bìxū wèi 0-% #: shared-bindings/_bleio/Characteristic.c shared-bindings/_bleio/Descriptor.c msgid "max_length must be >= 0" -msgstr "" +msgstr "zuì dà cháng dù bì xū >= 0" #: extmod/ulab/code/ndarray.c msgid "maximum number of dimensions is 4" -msgstr "" +msgstr "zuì dà chǐ cùn shù wéi 4" #: py/runtime.c msgid "maximum recursion depth exceeded" @@ -3184,7 +3353,7 @@ msgstr "maxiter yìng wéi > 0" #: extmod/ulab/code/numerical/numerical.c msgid "median argument must be an ndarray" -msgstr "" +msgstr "zhōng wèi shù cān shù bì xū shì ndarray" #: py/runtime.c #, c-format @@ -3270,7 +3439,7 @@ msgstr "zhǎo bù dào fēi běndì de bǎng dìng" #: shared-module/msgpack/__init__.c msgid "no default packer" -msgstr "" +msgstr "wú mò rèn bāo zhuāng jī" #: py/builtinimport.c msgid "no module named '%q'" @@ -3311,15 +3480,15 @@ msgstr "guānjiàn zì cānshù zhīhòu de fēi guānjiàn zì cānshù" #: ports/nrf/common-hal/_bleio/Adapter.c msgid "non-zero timeout must be > 0.01" -msgstr "" +msgstr "fēi líng chāo shí bì xū > 0.01" #: shared-bindings/_bleio/Adapter.c msgid "non-zero timeout must be >= interval" -msgstr "" +msgstr "fēi líng chāo shí bì xū wéi >= jiàn gé" #: extmod/ulab/code/linalg/linalg.c msgid "norm is defined for 1D and 2D arrays" -msgstr "" +msgstr "wéi 1D hé 2D shù zǔ dìng yì guī fàn" #: shared-bindings/_bleio/UUID.c msgid "not a 128-bit UUID" @@ -3337,6 +3506,10 @@ msgstr "géshì zìfú chuàn cān shǔ bùzú" msgid "number of points must be at least 2" msgstr "diǎnshù bìxū zhìshǎo wèi 2" +#: py/builtinhelp.c +msgid "object " +msgstr "duì xiàng " + #: py/obj.c msgid "object '%q' is not a tuple or list" msgstr "duìxiàng '%q' bùshì yuán zǔ huò lièbiǎo" @@ -3387,15 +3560,15 @@ msgstr "jīshù zìfú chuàn" #: extmod/ulab/code/ulab_create.c msgid "offset is too large" -msgstr "" +msgstr "piān yí tài dà" #: shared-bindings/dualbank/__init__.c msgid "offset must be >= 0" -msgstr "" +msgstr "piān yí liàng bì xū >= 0" #: extmod/ulab/code/ulab_create.c msgid "offset must be non-negative and no greater than buffer length" -msgstr "" +msgstr "piān yí liàng bì xū wéi fēi fù shù qiě bù dà yú huǎn chōng qū cháng dù" #: py/objstr.c py/objstrunicode.c msgid "offset out of bounds" @@ -3421,7 +3594,7 @@ msgstr "cāozuò shǔ bùnéng yīqǐ guǎngbò" #: extmod/ulab/code/ndarray.c msgid "operation is implemented for 1D Boolean arrays only" -msgstr "" +msgstr "jǐn duì 1D bù ěr shù zǔ shí xiàn cāo zuò" #: extmod/ulab/code/numerical/numerical.c msgid "operation is not implemented on ndarrays" @@ -3521,6 +3694,7 @@ msgstr "pow() yǒu 3 cānshù xūyào zhěngshù" #: ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wroom/mpconfigboard.h #: ports/esp32s2/boards/espressif_saola_1_wrover/mpconfigboard.h +#: ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h #: ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h #: ports/esp32s2/boards/muselab_nanoesp32_s2/mpconfigboard.h #: ports/esp32s2/boards/targett_module_clip_wroom/mpconfigboard.h @@ -3538,6 +3712,14 @@ msgstr "Zài qǐdòng shí àn qǐdòng ànniǔ.\n" msgid "pressing both buttons at start up.\n" msgstr "zài qǐdòng shí tóngshí àn xià liǎng gè ànniǔ.\n" +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "pull_threshold must be between 1 and 32" +msgstr "lā lì yù zhí bì xū jiè yú 1 hé 32 zhī jiān" + +#: ports/raspberrypi/bindings/rp2pio/StateMachine.c +msgid "push_threshold must be between 1 and 32" +msgstr "tuī sòng yù zhí bì xū jiè yú 1 hé 32 zhī jiān" + #: extmod/modutimeq.c msgid "queue overflow" msgstr "duìliè yìchū" @@ -3561,7 +3743,7 @@ msgstr "qǐngqiú chángdù %d dàn duìxiàng chángdù %d" #: extmod/ulab/code/ndarray_operators.c msgid "results cannot be cast to specified type" -msgstr "" +msgstr "wú fǎ jiāng jié guǒ qiáng zhì zhuǎn huàn dào zhǐ dìng lèi xíng" #: py/compile.c msgid "return annotation must be an identifier" @@ -3583,7 +3765,7 @@ msgstr "rgb_pins[%d] yǔ shízhōng bùzài tóng yīgè duānkǒu shàng" #: extmod/ulab/code/numerical/numerical.c msgid "roll argument must be an ndarray" -msgstr "" +msgstr "gǔn dòng cān shù bì xū shì ndarray" #: py/objstr.c msgid "rsplit(None,n)" @@ -3611,11 +3793,11 @@ msgstr "bù zhīchí jiǎoběn biānyì" #: extmod/ulab/code/ndarray.c msgid "shape must be a tuple" -msgstr "" +msgstr "xíng zhuàng bì xū shì yí gè yuán zǔ" #: shared-module/msgpack/__init__.c msgid "short read" -msgstr "" +msgstr "duǎn dú" #: py/objstr.c msgid "sign not allowed in string format specifier" @@ -3733,12 +3915,17 @@ msgstr "uctypes miáoshù fú zhōng de yǔfǎ cuòwù" msgid "threshold must be in the range 0-65536" msgstr "yùzhí bìxū zài fànwéi 0-65536" +#: shared-bindings/rgbmatrix/RGBMatrix.c +msgid "tile must be greater than zero" +msgstr "cí tiē bì xū dà yú líng" + #: shared-bindings/time/__init__.c msgid "time.struct_time() takes a 9-sequence" msgstr "time.struct_time() xūyào 9 xùliè" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c #: ports/nrf/common-hal/watchdog/WatchDogTimer.c +#: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "chāoshí shíjiān chāoguò zuìdà zhīchí zhí" @@ -3748,7 +3935,7 @@ msgstr "Chāo shí shíjiān bìxū wèi 0.0 Dào 100.0 Miǎo" #: ports/nrf/common-hal/_bleio/Adapter.c msgid "timeout must be < 655.35 secs" -msgstr "" +msgstr "chāo shí bì xū < 655.35 miǎo" #: shared-bindings/_bleio/CharacteristicBuffer.c msgid "timeout must be >= 0.0" @@ -3768,7 +3955,7 @@ msgstr "time_t shíjiān chuō chāochū píngtái fànwéi" #: extmod/ulab/code/ndarray.c msgid "tobytes can be invoked for dense arrays only" -msgstr "" +msgstr "tobytes zhǐ néng duì mì jí shù zǔ diào yòng" #: shared-module/struct/__init__.c msgid "too many arguments provided with the given format" @@ -3776,7 +3963,7 @@ msgstr "tígōng jǐ dìng géshì de cānshù tài duō" #: extmod/ulab/code/ulab_create.c msgid "too many dimensions" -msgstr "" +msgstr "chǐ cùn tài duō" #: extmod/ulab/code/ndarray.c msgid "too many indices" @@ -3789,7 +3976,7 @@ msgstr "dǎkāi tài duō zhí (yùqí %d)" #: extmod/ulab/code/approx/approx.c msgid "trapz is defined for 1D arrays" -msgstr "" +msgstr "wéi 1D shù zǔ dìng yì xiàn jǐng" #: extmod/ulab/code/approx/approx.c msgid "trapz is defined for 1D arrays of equal length" @@ -3797,7 +3984,7 @@ msgstr "Trapz shì wèi děng zhǎng de 1D shùzǔ dìngyì de" #: ports/esp32s2/common-hal/alarm/pin/__init__.c msgid "trigger level must be 0 or 1" -msgstr "" +msgstr "chù fā jí bié bì xū wéi 0 huò 1" #: py/obj.c msgid "tuple/list has wrong length" @@ -3939,7 +4126,7 @@ msgstr "xiàngliàng bìxū jùyǒu xiāngtóng de chángdù" #: ports/esp32s2/common-hal/alarm/pin/__init__.c msgid "wakeup conflict" -msgstr "" +msgstr "huàn xǐng chōng tū" #: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c msgid "watchdog not initialized" @@ -3953,17 +4140,21 @@ msgstr "kān mén gǒu chāoshí bìxū dàyú 0" msgid "width must be greater than zero" msgstr "kuāndù bìxū dàyú líng" +#: ports/esp32s2/common-hal/wifi/Radio.c +msgid "wifi is not enabled" +msgstr "wèi qǐ yòng WIFI" + #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" msgstr "Chuāngkǒu bìxū shì <= jiàngé" #: extmod/ulab/code/numerical/numerical.c msgid "wrong axis index" -msgstr "" +msgstr "cuò wù de zhóu suǒ yǐn" #: extmod/ulab/code/ulab_create.c msgid "wrong axis specified" -msgstr "" +msgstr "zhǐ dìng de zhóu cuò wù" #: extmod/ulab/code/vector/vectorise.c msgid "wrong input type" @@ -3991,7 +4182,7 @@ msgstr "x zhí chāochū biānjiè" #: ports/esp32s2/common-hal/audiobusio/__init__.c msgid "xTaskCreate failed" -msgstr "" +msgstr "xTaskCreate shī bài" #: shared-bindings/displayio/Shape.c msgid "y should be an int" @@ -4017,6 +4208,20 @@ msgstr "zi bìxū wèi fú diǎn xíng" msgid "zi must be of shape (n_section, 2)" msgstr "zi bìxū jùyǒu xíngzhuàng (n_section,2)" +#~ msgid "SDA or SCL needs a pull up" +#~ msgstr "SDA huò SCL xūyào lādòng" + +#~ msgid "Invalid use of TLS Socket" +#~ msgstr "TLS tào jiē zì de wú xiào shǐ yòng" + +#~ msgid "Issue setting SO_REUSEADDR" +#~ msgstr "wèn tí shè zhì SO_REUSEADDR" + +#~ msgid "%d address pins and %d rgb pins indicate a height of %d, not %d" +#~ msgstr "" +#~ "%d dìzhǐ yǐn jiǎo hé %d rgb yǐn jiǎo jiāng gāodù biǎoshì wèi %d, ér bùshì " +#~ "%d" + #~ msgid "Unknown failure" #~ msgstr "Wèizhī gùzhàng" @@ -184,6 +184,7 @@ STATIC void stop_mp(void) { #endif background_callback_reset(); + usb_background(); gc_deinit(); } diff --git a/ports/atmel-samd/boards/8086_commander/mpconfigboard.mk b/ports/atmel-samd/boards/8086_commander/mpconfigboard.mk index b5a4bc735..f976dfe78 100644 --- a/ports/atmel-samd/boards/8086_commander/mpconfigboard.mk +++ b/ports/atmel-samd/boards/8086_commander/mpconfigboard.mk @@ -22,7 +22,6 @@ CIRCUITPY_GAMEPAD = 1 CIRCUITPY_BUSDEVICE = 1 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_HID FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_SD #FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_ADXL34x diff --git a/ports/atmel-samd/boards/arduino_mkr1300/mpconfigboard.mk b/ports/atmel-samd/boards/arduino_mkr1300/mpconfigboard.mk index d31d1f54a..36d463697 100644 --- a/ports/atmel-samd/boards/arduino_mkr1300/mpconfigboard.mk +++ b/ports/atmel-samd/boards/arduino_mkr1300/mpconfigboard.mk @@ -10,3 +10,4 @@ INTERNAL_FLASH_FILESYSTEM = 1 LONGINT_IMPL = NONE CIRCUITPY_FULL_BUILD = 0 SUPEROPT_GC = 0 +SUPEROPT_VM = 0 diff --git a/ports/atmel-samd/boards/arduino_mkrzero/mpconfigboard.mk b/ports/atmel-samd/boards/arduino_mkrzero/mpconfigboard.mk index 7eb83a123..20307fc05 100644 --- a/ports/atmel-samd/boards/arduino_mkrzero/mpconfigboard.mk +++ b/ports/atmel-samd/boards/arduino_mkrzero/mpconfigboard.mk @@ -11,3 +11,5 @@ LONGINT_IMPL = NONE CIRCUITPY_FULL_BUILD = 0 SUPEROPT_GC = 0 +SUPEROPT_VM = 0 +CFLAGS_INLINE_LIMIT = 40 diff --git a/ports/atmel-samd/boards/arduino_zero/mpconfigboard.mk b/ports/atmel-samd/boards/arduino_zero/mpconfigboard.mk index a5722c9ad..697ec02c3 100644 --- a/ports/atmel-samd/boards/arduino_zero/mpconfigboard.mk +++ b/ports/atmel-samd/boards/arduino_zero/mpconfigboard.mk @@ -11,3 +11,4 @@ LONGINT_IMPL = NONE CIRCUITPY_FULL_BUILD = 0 SUPEROPT_GC = 0 +SUPEROPT_VM = 0 diff --git a/ports/atmel-samd/boards/circuitbrains_basic_m0/mpconfigboard.mk b/ports/atmel-samd/boards/circuitbrains_basic_m0/mpconfigboard.mk index 178258b6c..2ace30fb5 100755 --- a/ports/atmel-samd/boards/circuitbrains_basic_m0/mpconfigboard.mk +++ b/ports/atmel-samd/boards/circuitbrains_basic_m0/mpconfigboard.mk @@ -16,6 +16,7 @@ CIRCUITPY_COUNTIO = 0 CIRCUITPY_FREQUENCYIO = 0 CIRCUITPY_I2CPERIPHERAL = 0 CIRCUITPY_VECTORIO = 0 +CIRCUITPY_BUSDEVICE = 0 MICROPY_PY_ASYNC_AWAIT = 0 SUPEROPT_GC = 0 diff --git a/ports/atmel-samd/boards/circuitplayground_express/mpconfigboard.mk b/ports/atmel-samd/boards/circuitplayground_express/mpconfigboard.mk index 505f5c145..0b150a5fb 100644 --- a/ports/atmel-samd/boards/circuitplayground_express/mpconfigboard.mk +++ b/ports/atmel-samd/boards/circuitplayground_express/mpconfigboard.mk @@ -22,7 +22,6 @@ SUPEROPT_GC = 0 CFLAGS_INLINE_LIMIT = 55 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_CircuitPlayground FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_HID FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_LIS3DH diff --git a/ports/atmel-samd/boards/circuitplayground_express_crickit/mpconfigboard.mk b/ports/atmel-samd/boards/circuitplayground_express_crickit/mpconfigboard.mk index c3be33134..ae0b6837c 100644 --- a/ports/atmel-samd/boards/circuitplayground_express_crickit/mpconfigboard.mk +++ b/ports/atmel-samd/boards/circuitplayground_express_crickit/mpconfigboard.mk @@ -22,11 +22,10 @@ CIRCUITPY_ROTARYIO = 0 CIRCUITPY_RTC = 0 SUPEROPT_GC = 0 -CFLAGS_INLINE_LIMIT = 50 +CFLAGS_INLINE_LIMIT = 40 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_CircuitPlayground FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_Crickit FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_LIS3DH diff --git a/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.h b/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.h index 4b0c324fa..1586a3289 100644 --- a/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.h +++ b/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.h @@ -43,5 +43,3 @@ // USB is always used internally so skip the pin objects for it. #define IGNORE_PIN_PA24 1 #define IGNORE_PIN_PA25 1 - -#define MICROPY_PY_URE 0 diff --git a/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.mk b/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.mk index 51e9b05af..aace5c0cb 100644 --- a/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.mk +++ b/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.mk @@ -18,6 +18,7 @@ CIRCUITPY_FREQUENCYIO = 0 CIRCUITPY_I2CPERIPHERAL = 0 CIRCUITPY_MSGPACK = 0 CIRCUITPY_PIXELBUF = 0 +CIRCUITPY_RE = 0 CIRCUITPY_ROTARYIO = 0 CIRCUITPY_RTC = 0 # So not all of displayio, sorry! @@ -27,7 +28,6 @@ SUPEROPT_GC = 0 CFLAGS_INLINE_LIMIT = 55 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_CircuitPlayground FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_LIS3DH FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/atmel-samd/boards/feather_m0_adalogger/mpconfigboard.mk b/ports/atmel-samd/boards/feather_m0_adalogger/mpconfigboard.mk index 143910318..ab6c4ed99 100644 --- a/ports/atmel-samd/boards/feather_m0_adalogger/mpconfigboard.mk +++ b/ports/atmel-samd/boards/feather_m0_adalogger/mpconfigboard.mk @@ -11,3 +11,4 @@ LONGINT_IMPL = NONE CIRCUITPY_FULL_BUILD = 0 SUPEROPT_GC = 0 +SUPEROPT_VM = 0 diff --git a/ports/atmel-samd/boards/feather_m0_express_crickit/mpconfigboard.mk b/ports/atmel-samd/boards/feather_m0_express_crickit/mpconfigboard.mk index f06163b84..309563ff4 100644 --- a/ports/atmel-samd/boards/feather_m0_express_crickit/mpconfigboard.mk +++ b/ports/atmel-samd/boards/feather_m0_express_crickit/mpconfigboard.mk @@ -21,7 +21,6 @@ CFLAGS_INLINE_LIMIT = 50 CIRCUITPY_MSGPACK = 0 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_Crickit FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_Motor FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/atmel-samd/boards/feather_m0_rfm69/mpconfigboard.mk b/ports/atmel-samd/boards/feather_m0_rfm69/mpconfigboard.mk index 6e089bb90..6ea21ed82 100644 --- a/ports/atmel-samd/boards/feather_m0_rfm69/mpconfigboard.mk +++ b/ports/atmel-samd/boards/feather_m0_rfm69/mpconfigboard.mk @@ -28,5 +28,4 @@ CFLAGS_INLINE_LIMIT = 35 SUPEROPT_GC = 0 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_RFM69 diff --git a/ports/atmel-samd/boards/feather_m0_rfm9x/mpconfigboard.mk b/ports/atmel-samd/boards/feather_m0_rfm9x/mpconfigboard.mk index 383b6a6df..76a6be2e3 100644 --- a/ports/atmel-samd/boards/feather_m0_rfm9x/mpconfigboard.mk +++ b/ports/atmel-samd/boards/feather_m0_rfm9x/mpconfigboard.mk @@ -29,5 +29,4 @@ CFLAGS_INLINE_LIMIT = 35 SUPEROPT_GC = 0 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_RFM9x diff --git a/ports/atmel-samd/boards/gemma_m0/mpconfigboard.mk b/ports/atmel-samd/boards/gemma_m0/mpconfigboard.mk index 0345417a9..e1c0f4b9a 100644 --- a/ports/atmel-samd/boards/gemma_m0/mpconfigboard.mk +++ b/ports/atmel-samd/boards/gemma_m0/mpconfigboard.mk @@ -20,4 +20,5 @@ endif ifeq ($(TRANSLATION), de_DE) RELEASE_NEEDS_CLEAN_BUILD = 1 CFLAGS_INLINE_LIMIT = 35 +SUPEROPT_VM = 0 endif diff --git a/ports/atmel-samd/boards/hallowing_m0_express/mpconfigboard.mk b/ports/atmel-samd/boards/hallowing_m0_express/mpconfigboard.mk index 1931ceb9a..2b211abd4 100644 --- a/ports/atmel-samd/boards/hallowing_m0_express/mpconfigboard.mk +++ b/ports/atmel-samd/boards/hallowing_m0_express/mpconfigboard.mk @@ -27,7 +27,6 @@ CFLAGS_INLINE_LIMIT = 55 SUPEROPT_GC = 0 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_LIS3DH FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/atmel-samd/boards/metro_m4_airlift_lite/mpconfigboard.mk b/ports/atmel-samd/boards/metro_m4_airlift_lite/mpconfigboard.mk index 4895cda77..58d4e4980 100644 --- a/ports/atmel-samd/boards/metro_m4_airlift_lite/mpconfigboard.mk +++ b/ports/atmel-samd/boards/metro_m4_airlift_lite/mpconfigboard.mk @@ -10,3 +10,5 @@ QSPI_FLASH_FILESYSTEM = 1 EXTERNAL_FLASH_DEVICE_COUNT = 3 EXTERNAL_FLASH_DEVICES = "S25FL116K, S25FL216K, GD25Q16C" LONGINT_IMPL = MPZ + +CIRCUITPY__EVE = 1 diff --git a/ports/atmel-samd/boards/pycubed/mpconfigboard.mk b/ports/atmel-samd/boards/pycubed/mpconfigboard.mk index b7b8073ab..a82362b8d 100644 --- a/ports/atmel-samd/boards/pycubed/mpconfigboard.mk +++ b/ports/atmel-samd/boards/pycubed/mpconfigboard.mk @@ -21,7 +21,6 @@ CIRCUITPY_GAMEPAD = 0 CIRCUITPY_RGBMATRIX = 0 CIRCUITPY_PS2IO = 0 -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_Register FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_SD diff --git a/ports/atmel-samd/boards/pycubed_mram/mpconfigboard.mk b/ports/atmel-samd/boards/pycubed_mram/mpconfigboard.mk index f49bb3fef..3bf42d705 100644 --- a/ports/atmel-samd/boards/pycubed_mram/mpconfigboard.mk +++ b/ports/atmel-samd/boards/pycubed_mram/mpconfigboard.mk @@ -21,7 +21,6 @@ CIRCUITPY_GAMEPAD = 0 CIRCUITPY_RGBMATRIX = 0 CIRCUITPY_PS2IO = 0 -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_Register FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_SD diff --git a/ports/atmel-samd/boards/qtpy_m0/mpconfigboard.mk b/ports/atmel-samd/boards/qtpy_m0/mpconfigboard.mk index 964cbe643..e100e2da6 100644 --- a/ports/atmel-samd/boards/qtpy_m0/mpconfigboard.mk +++ b/ports/atmel-samd/boards/qtpy_m0/mpconfigboard.mk @@ -11,14 +11,6 @@ LONGINT_IMPL = NONE CIRCUITPY_FULL_BUILD = 0 SUPEROPT_GC = 0 +SUPEROPT_VM = 0 CFLAGS_BOARD = --param max-inline-insns-auto=15 -ifeq ($(TRANSLATION), zh_Latn_pinyin) -RELEASE_NEEDS_CLEAN_BUILD = 1 -CFLAGS_INLINE_LIMIT = 35 -endif -ifeq ($(TRANSLATION), de_DE) -RELEASE_NEEDS_CLEAN_BUILD = 1 -CFLAGS_INLINE_LIMIT = 35 -SUPEROPT_VM = 0 -endif diff --git a/ports/atmel-samd/boards/sam32/mpconfigboard.mk b/ports/atmel-samd/boards/sam32/mpconfigboard.mk index 1dc686ef8..9ac24a014 100644 --- a/ports/atmel-samd/boards/sam32/mpconfigboard.mk +++ b/ports/atmel-samd/boards/sam32/mpconfigboard.mk @@ -13,5 +13,4 @@ LONGINT_IMPL = MPZ CIRCUITPY_AUDIOBUSIO = 0 CIRCUITPY_USTACK = 1 -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/atmel-samd/boards/seeeduino_xiao/mpconfigboard.mk b/ports/atmel-samd/boards/seeeduino_xiao/mpconfigboard.mk index bedec87f4..6bbd84235 100644 --- a/ports/atmel-samd/boards/seeeduino_xiao/mpconfigboard.mk +++ b/ports/atmel-samd/boards/seeeduino_xiao/mpconfigboard.mk @@ -11,3 +11,4 @@ LONGINT_IMPL = NONE CIRCUITPY_FULL_BUILD = 0 SUPEROPT_GC = 0 +SUPEROPT_VM = 0 diff --git a/ports/atmel-samd/boards/serpente/mpconfigboard.mk b/ports/atmel-samd/boards/serpente/mpconfigboard.mk index 6e953adf7..09036875f 100644 --- a/ports/atmel-samd/boards/serpente/mpconfigboard.mk +++ b/ports/atmel-samd/boards/serpente/mpconfigboard.mk @@ -14,6 +14,7 @@ LONGINT_IMPL = NONE CIRCUITPY_AUDIOBUSIO = 0 CIRCUITPY_FREQUENCYIO = 0 CIRCUITPY_GAMEPAD = 0 +CIRCUITPY_BUSDEVICE = 0 SUPEROPT_GC = 0 diff --git a/ports/atmel-samd/boards/silicognition-m4-shim/board.c b/ports/atmel-samd/boards/silicognition-m4-shim/board.c new file mode 100644 index 000000000..5fca974e9 --- /dev/null +++ b/ports/atmel-samd/boards/silicognition-m4-shim/board.c @@ -0,0 +1,38 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2017 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 "supervisor/board.h" +#include "mpconfigboard.h" + +void board_init(void) { +} + +bool board_requests_safe_mode(void) { + return false; +} + +void reset_board(void) { +} diff --git a/ports/atmel-samd/boards/silicognition-m4-shim/mpconfigboard.h b/ports/atmel-samd/boards/silicognition-m4-shim/mpconfigboard.h new file mode 100644 index 000000000..5028679ed --- /dev/null +++ b/ports/atmel-samd/boards/silicognition-m4-shim/mpconfigboard.h @@ -0,0 +1,33 @@ +#define MICROPY_HW_BOARD_NAME "Silicognition LLC M4-Shim" +#define MICROPY_HW_MCU_NAME "samd51j19" + +#define CIRCUITPY_MCU_FAMILY samd51 + +// Rev E + +#define MICROPY_HW_LED_STATUS (&pin_PA23) +#define MICROPY_HW_NEOPIXEL (&pin_PB03) + +// These are pins not to reset. +// QSPI Data pins +#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) +// QSPI CS, QSPI SCK and NeoPixel pin +#define MICROPY_PORT_B (PORT_PB03 | PORT_PB10 | PORT_PB11) +#define MICROPY_PORT_C (0) +#define MICROPY_PORT_D (0) + +#define BOARD_HAS_CRYSTAL 1 + +#define DEFAULT_I2C_BUS_SCL (&pin_PA13) +#define DEFAULT_I2C_BUS_SDA (&pin_PA12) + +#define DEFAULT_SPI_BUS_SCK (&pin_PA17) +#define DEFAULT_SPI_BUS_MOSI (&pin_PB23) +#define DEFAULT_SPI_BUS_MISO (&pin_PB22) + +#define DEFAULT_UART_BUS_RX (&pin_PB17) +#define DEFAULT_UART_BUS_TX (&pin_PB16) + +// USB is always used internally so skip the pin objects for it. +#define IGNORE_PIN_PA24 1 +#define IGNORE_PIN_PA25 1 diff --git a/ports/atmel-samd/boards/silicognition-m4-shim/mpconfigboard.mk b/ports/atmel-samd/boards/silicognition-m4-shim/mpconfigboard.mk new file mode 100644 index 000000000..bf88cd52d --- /dev/null +++ b/ports/atmel-samd/boards/silicognition-m4-shim/mpconfigboard.mk @@ -0,0 +1,14 @@ +USB_VID = 0x1209 +USB_PID = 0xF500 +USB_PRODUCT = "M4-Shim" +USB_MANUFACTURER = "Silicognition LLC" + +CHIP_VARIANT = SAMD51J19A +CHIP_FAMILY = samd51 + +QSPI_FLASH_FILESYSTEM = 1 +EXTERNAL_FLASH_DEVICE_COUNT = 1 +EXTERNAL_FLASH_DEVICES = GD25Q16C +LONGINT_IMPL = MPZ + +CIRCUITPY_VECTORIO = 1 diff --git a/ports/atmel-samd/boards/silicognition-m4-shim/pins.c b/ports/atmel-samd/boards/silicognition-m4-shim/pins.c new file mode 100644 index 000000000..b7afd044e --- /dev/null +++ b/ports/atmel-samd/boards/silicognition-m4-shim/pins.c @@ -0,0 +1,54 @@ +#include "shared-bindings/board/__init__.h" + +STATIC const mp_rom_map_elem_t board_global_dict_table[] = { + { MP_ROM_QSTR(MP_QSTR_A0), MP_ROM_PTR(&pin_PA02) }, + { MP_ROM_QSTR(MP_QSTR_D14), MP_ROM_PTR(&pin_PA02) }, + + { MP_ROM_QSTR(MP_QSTR_A1), MP_ROM_PTR(&pin_PA05) }, + { MP_ROM_QSTR(MP_QSTR_D15), MP_ROM_PTR(&pin_PA05) }, + + { MP_ROM_QSTR(MP_QSTR_A2), MP_ROM_PTR(&pin_PB08) }, + { MP_ROM_QSTR(MP_QSTR_D16), MP_ROM_PTR(&pin_PB08) }, + + { MP_ROM_QSTR(MP_QSTR_A3), MP_ROM_PTR(&pin_PB09) }, + { MP_ROM_QSTR(MP_QSTR_D17), MP_ROM_PTR(&pin_PB09) }, + + { MP_ROM_QSTR(MP_QSTR_A4), MP_ROM_PTR(&pin_PA04) }, + { MP_ROM_QSTR(MP_QSTR_D18), MP_ROM_PTR(&pin_PA04) }, + + { MP_ROM_QSTR(MP_QSTR_A5), MP_ROM_PTR(&pin_PA06) }, + { MP_ROM_QSTR(MP_QSTR_D19), MP_ROM_PTR(&pin_PA06) }, + + { MP_ROM_QSTR(MP_QSTR_SCK), MP_ROM_PTR(&pin_PA17) }, + { MP_ROM_QSTR(MP_QSTR_D25), MP_ROM_PTR(&pin_PA17) }, + + { MP_ROM_QSTR(MP_QSTR_MOSI), MP_ROM_PTR(&pin_PB23) }, + { MP_ROM_QSTR(MP_QSTR_D24), MP_ROM_PTR(&pin_PB23) }, + + { MP_ROM_QSTR(MP_QSTR_MISO), MP_ROM_PTR(&pin_PB22) }, + { MP_ROM_QSTR(MP_QSTR_D23), MP_ROM_PTR(&pin_PB22) }, + + { MP_ROM_QSTR(MP_QSTR_D0), MP_ROM_PTR(&pin_PB17) }, + { MP_ROM_QSTR(MP_QSTR_RX), MP_ROM_PTR(&pin_PB17) }, + + { MP_ROM_QSTR(MP_QSTR_D1), MP_ROM_PTR(&pin_PB16) }, + { MP_ROM_QSTR(MP_QSTR_TX), MP_ROM_PTR(&pin_PB16) }, + + { MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_PA12) }, + { MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_PA13) }, + { MP_ROM_QSTR(MP_QSTR_D4), MP_ROM_PTR(&pin_PA14) }, + { MP_ROM_QSTR(MP_QSTR_D5), MP_ROM_PTR(&pin_PA16) }, + { MP_ROM_QSTR(MP_QSTR_D6), MP_ROM_PTR(&pin_PA18) }, + { MP_ROM_QSTR(MP_QSTR_D9), MP_ROM_PTR(&pin_PA19) }, + { MP_ROM_QSTR(MP_QSTR_D10), MP_ROM_PTR(&pin_PA20) }, + { MP_ROM_QSTR(MP_QSTR_D11), MP_ROM_PTR(&pin_PA21) }, + { MP_ROM_QSTR(MP_QSTR_D12), MP_ROM_PTR(&pin_PA22) }, + { MP_ROM_QSTR(MP_QSTR_D13), MP_ROM_PTR(&pin_PA23) }, + + { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_PB03) }, + + { MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&board_i2c_obj) }, + { MP_ROM_QSTR(MP_QSTR_SPI), MP_ROM_PTR(&board_spi_obj) }, + { MP_ROM_QSTR(MP_QSTR_UART), MP_ROM_PTR(&board_uart_obj) }, +}; +MP_DEFINE_CONST_DICT(board_module_globals, board_global_dict_table); diff --git a/ports/atmel-samd/boards/sparkfun_lumidrive/mpconfigboard.mk b/ports/atmel-samd/boards/sparkfun_lumidrive/mpconfigboard.mk index e71bb0739..2e15bc042 100755 --- a/ports/atmel-samd/boards/sparkfun_lumidrive/mpconfigboard.mk +++ b/ports/atmel-samd/boards/sparkfun_lumidrive/mpconfigboard.mk @@ -14,6 +14,7 @@ LONGINT_IMPL = MPZ CIRCUITPY_AUDIOIO = 0 CIRCUITPY_AUDIOBUSIO = 0 CIRCUITPY_VECTORIO = 0 +CIRCUITPY_BUSDEVICE = 0 FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_DotStar diff --git a/ports/atmel-samd/boards/trinket_m0/mpconfigboard.mk b/ports/atmel-samd/boards/trinket_m0/mpconfigboard.mk index 735d42297..1f88fbead 100644 --- a/ports/atmel-samd/boards/trinket_m0/mpconfigboard.mk +++ b/ports/atmel-samd/boards/trinket_m0/mpconfigboard.mk @@ -11,14 +11,5 @@ LONGINT_IMPL = NONE CIRCUITPY_FULL_BUILD = 0 SUPEROPT_GC = 0 - -CFLAGS_BOARD = --param max-inline-insns-auto=15 -ifeq ($(TRANSLATION), zh_Latn_pinyin) -RELEASE_NEEDS_CLEAN_BUILD = 1 -CFLAGS_INLINE_LIMIT = 35 -endif -ifeq ($(TRANSLATION), de_DE) -RELEASE_NEEDS_CLEAN_BUILD = 1 -CFLAGS_INLINE_LIMIT = 35 SUPEROPT_VM = 0 -endif +CFLAGS_INLINE_LIMIT = 45 diff --git a/ports/atmel-samd/boards/ugame10/mpconfigboard.mk b/ports/atmel-samd/boards/ugame10/mpconfigboard.mk index b1242d206..640d421e8 100644 --- a/ports/atmel-samd/boards/ugame10/mpconfigboard.mk +++ b/ports/atmel-samd/boards/ugame10/mpconfigboard.mk @@ -28,6 +28,7 @@ CIRCUITPY_RTC = 0 CIRCUITPY_TOUCHIO = 0 CIRCUITPY_USB_HID = 0 CIRCUITPY_USB_MIDI = 0 +CIRCUITPY_BUSDEVICE = 0 FROZEN_MPY_DIRS += $(TOP)/frozen/circuitpython-stage/ugame10 diff --git a/ports/atmel-samd/boards/xinabox_cc03/mpconfigboard.mk b/ports/atmel-samd/boards/xinabox_cc03/mpconfigboard.mk index 3562228c7..d6f333b5b 100644 --- a/ports/atmel-samd/boards/xinabox_cc03/mpconfigboard.mk +++ b/ports/atmel-samd/boards/xinabox_cc03/mpconfigboard.mk @@ -24,4 +24,3 @@ CIRCUITPY_TOUCHIO=0 CIRCUITPY_BUSDEVICE=1 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice diff --git a/ports/atmel-samd/boards/xinabox_cs11/mpconfigboard.mk b/ports/atmel-samd/boards/xinabox_cs11/mpconfigboard.mk index 53908293f..fd2fa044a 100644 --- a/ports/atmel-samd/boards/xinabox_cs11/mpconfigboard.mk +++ b/ports/atmel-samd/boards/xinabox_cs11/mpconfigboard.mk @@ -27,5 +27,4 @@ CIRCUITPY_COUNTIO=0 CIRCUITPY_BUSDEVICE=1 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BusDevice FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_SD diff --git a/ports/atmel-samd/common-hal/busio/I2C.c b/ports/atmel-samd/common-hal/busio/I2C.c index ffe74a274..2551f7bf1 100644 --- a/ports/atmel-samd/common-hal/busio/I2C.c +++ b/ports/atmel-samd/common-hal/busio/I2C.c @@ -97,7 +97,7 @@ void common_hal_busio_i2c_construct(busio_i2c_obj_t *self, if (!gpio_get_pin_level(sda->number) || !gpio_get_pin_level(scl->number)) { reset_pin_number(sda->number); reset_pin_number(scl->number); - mp_raise_RuntimeError(translate("SDA or SCL needs a pull up")); + mp_raise_RuntimeError(translate("No pull up found on SDA or SCL; check your wiring")); } #endif diff --git a/ports/atmel-samd/mpconfigport.h b/ports/atmel-samd/mpconfigport.h index bce89e0b9..d2a529485 100644 --- a/ports/atmel-samd/mpconfigport.h +++ b/ports/atmel-samd/mpconfigport.h @@ -45,11 +45,7 @@ #define MICROPY_PY_BUILTINS_COMPLEX (0) #define MICROPY_PY_BUILTINS_NOTIMPLEMENTED (0) #define MICROPY_PY_FUNCTION_ATTRS (0) -// MICROPY_PY_UJSON depends on MICROPY_PY_IO -#define MICROPY_PY_IO (0) #define MICROPY_PY_REVERSE_SPECIAL_METHODS (0) -#define MICROPY_PY_UBINASCII (0) -#define MICROPY_PY_UJSON (0) #define MICROPY_PY_COLLECTIONS_ORDEREDDICT (0) #define MICROPY_PY_UERRNO_LIST \ X(EPERM) \ @@ -84,9 +80,6 @@ #define SPI_FLASH_MAX_BAUDRATE 24000000 #define MICROPY_PY_BUILTINS_NOTIMPLEMENTED (1) #define MICROPY_PY_FUNCTION_ATTRS (1) -// MICROPY_PY_UJSON depends on MICROPY_PY_IO -#define MICROPY_PY_IO (1) -#define MICROPY_PY_UJSON (1) // MICROPY_PY_UERRNO_LIST - Use the default #endif // SAM_D5X_E5X diff --git a/ports/atmel-samd/mpconfigport.mk b/ports/atmel-samd/mpconfigport.mk index 17e3995bf..fb9cdf2e6 100644 --- a/ports/atmel-samd/mpconfigport.mk +++ b/ports/atmel-samd/mpconfigport.mk @@ -20,26 +20,16 @@ endif # Put samd21-only choices here. ifeq ($(CHIP_FAMILY),samd21) -# frequencyio not yet verified as working on SAMD21, though make it possible to override. -ifndef CIRCUITPY_AUDIOMIXER -CIRCUITPY_AUDIOMIXER = 0 -endif - -ifndef CIRCUITPY_AUDIOMP3 -CIRCUITPY_AUDIOMP3 = 0 -endif - -ifndef CIRCUITPY_BUILTINS_POW3 -CIRCUITPY_BUILTINS_POW3 = 0 -endif -ifndef CIRCUITPY_FREQUENCYIO -CIRCUITPY_FREQUENCYIO = 0 -endif +# The ?='s allow overriding in mpconfigboard.mk. -ifndef CIRCUITPY_TOUCHIO_USE_NATIVE -CIRCUITPY_TOUCHIO_USE_NATIVE = 1 -endif +CIRCUITPY_AUDIOMIXER ?= 0 +CIRCUITPY_BINASCII ?= 0 +CIRCUITPY_AUDIOMP3 ?= 0 +CIRCUITPY_BUILTINS_POW3 ?= 0 +CIRCUITPY_FREQUENCYIO ?= 0 +CIRCUITPY_JSON ?= 0 +CIRCUITPY_TOUCHIO_USE_NATIVE ?= 1 # No room for HCI _bleio on SAMD21. CIRCUITPY_BLEIO_HCI = 0 @@ -71,27 +61,13 @@ ifeq ($(CHIP_FAMILY),samd51) # No native touchio on SAMD51. CIRCUITPY_TOUCHIO_USE_NATIVE = 0 -# The ifndef's allow overriding in mpconfigboard.mk. - -ifndef CIRCUITPY_NETWORK -CIRCUITPY_NETWORK = 0 -endif - -ifndef CIRCUITPY_PS2IO -CIRCUITPY_PS2IO = 1 -endif - -ifndef CIRCUITPY_SAMD -CIRCUITPY_SAMD = 1 -endif - -ifndef CIRCUITPY_RGBMATRIX -CIRCUITPY_RGBMATRIX = $(CIRCUITPY_FULL_BUILD) -endif +# The ?='s allow overriding in mpconfigboard.mk. -ifndef CIRCUITPY_FRAMEBUFFERIO -CIRCUITPY_FRAMEBUFFERIO = $(CIRCUITPY_FULL_BUILD) -endif +CIRCUITPY_NETWORK ?= 0 +CIRCUITPY_PS2IO ?= 1 +CIRCUITPY_SAMD ?= 1 +CIRCUITPY_RGBMATRIX ?= $(CIRCUITPY_FULL_BUILD) +CIRCUITPY_FRAMEBUFFERIO ?= $(CIRCUITPY_FULL_BUILD) endif # samd51 diff --git a/ports/cxd56/README.md b/ports/cxd56/README.md index 7fa439aac..c399b8a4d 100644 --- a/ports/cxd56/README.md +++ b/ports/cxd56/README.md @@ -75,7 +75,7 @@ Bootloader information: * You have to accept the End User License Agreement to be able to download and use the Spresense bootloader binary. -Download the spresense binaries zip archive from: [Spresense firmware v2-0-000](https://developer.sony.com/file/download/download-spresense-firmware-v2-0-000) +Download the spresense binaries zip archive from: [Spresense firmware v2-0-002](https://developer.sony.com/file/download/download-spresense-firmware-v2-0-002) Extract spresense binaries in your PC to ports/spresense/spresense-exported-sdk/firmware/ diff --git a/ports/cxd56/configs/circuitpython/defconfig b/ports/cxd56/configs/circuitpython/defconfig index a97f821df..096b53b80 100644 --- a/ports/cxd56/configs/circuitpython/defconfig +++ b/ports/cxd56/configs/circuitpython/defconfig @@ -165,6 +165,7 @@ CONFIG_USBDEV=y CONFIG_USBDEV_DMA=y CONFIG_USBDEV_DUALSPEED=y CONFIG_USEC_PER_TICK=1000 +CONFIG_USERMAIN_STACKSIZE=8192 CONFIG_USER_ENTRYPOINT="spresense_main" CONFIG_VIDEO_ISX012=y CONFIG_VIDEO_STREAM=y diff --git a/ports/cxd56/spresense-exported-sdk b/ports/cxd56/spresense-exported-sdk -Subproject 752c4cd56dd0a270a559c28272ceb61ddcb7806 +Subproject 2ec2a1538362696118dc3fdf56f33dacaf8f406 diff --git a/ports/cxd56/supervisor/internal_flash.c b/ports/cxd56/supervisor/internal_flash.c index 2726fa4a2..9c103fb19 100644 --- a/ports/cxd56/supervisor/internal_flash.c +++ b/ports/cxd56/supervisor/internal_flash.c @@ -30,10 +30,10 @@ /* Prototypes for Remote API */ -int FM_RawWrite(uint32_t offset, const void *buf, uint32_t size); -int FM_RawVerifyWrite(uint32_t offset, const void *buf, uint32_t size); -int FM_RawRead(uint32_t offset, void *buf, uint32_t size); -int FM_RawEraseSector(uint32_t sector); +int fw_fm_rawwrite(uint32_t offset, const void *buf, uint32_t size); +int fw_fm_rawverifywrite(uint32_t offset, const void *buf, uint32_t size); +int fw_fm_rawread(uint32_t offset, void *buf, uint32_t size); +int fw_fm_rawerasesector(uint32_t sector); #define CXD56_SPIFLASHSIZE (16 * 1024 * 1024) @@ -64,8 +64,8 @@ void port_internal_flash_flush(void) { return; } - FM_RawEraseSector(flash_sector); - FM_RawWrite(flash_sector << SECTOR_SHIFT, flash_cache, SECTOR_SIZE); + fw_fm_rawerasesector(flash_sector); + fw_fm_rawwrite(flash_sector << SECTOR_SHIFT, flash_cache, SECTOR_SIZE); flash_sector = NO_SECTOR; } @@ -73,7 +73,7 @@ void port_internal_flash_flush(void) { mp_uint_t supervisor_flash_read_blocks(uint8_t *dest, uint32_t block, uint32_t num_blocks) { supervisor_flash_flush(); - if (FM_RawRead(block << PAGE_SHIFT, dest, num_blocks << PAGE_SHIFT) < 0) { + if (fw_fm_rawread(block << PAGE_SHIFT, dest, num_blocks << PAGE_SHIFT) < 0) { return 1; } @@ -92,7 +92,7 @@ mp_uint_t supervisor_flash_write_blocks(const uint8_t *src, uint32_t lba, uint32 if (sector != flash_sector) { supervisor_flash_flush(); - if (FM_RawRead(sector << SECTOR_SHIFT, flash_cache, SECTOR_SIZE) < 0) { + if (fw_fm_rawread(sector << SECTOR_SHIFT, flash_cache, SECTOR_SIZE) < 0) { return 1; } diff --git a/ports/esp32s2/Makefile b/ports/esp32s2/Makefile index aac934782..b4ff0612b 100644 --- a/ports/esp32s2/Makefile +++ b/ports/esp32s2/Makefile @@ -164,7 +164,9 @@ LIBS += -lm endif # TinyUSB defines -CFLAGS += -DCFG_TUSB_MCU=OPT_MCU_ESP32S2 -DCFG_TUSB_OS=OPT_OS_FREERTOS -DCFG_TUD_CDC_RX_BUFSIZE=1024 -DCFG_TUD_CDC_TX_BUFSIZE=1024 -DCFG_TUD_MSC_BUFSIZE=4096 -DCFG_TUD_MIDI_RX_BUFSIZE=128 -DCFG_TUD_MIDI_TX_BUFSIZE=128 +CFLAGS += -DCFG_TUSB_MCU=OPT_MCU_ESP32S2 -DCFG_TUSB_OS=OPT_OS_FREERTOS -DCFG_TUD_CDC_RX_BUFSIZE=1024 -DCFG_TUD_CDC_TX_BUFSIZE=1024 +CFLAGS += -DCFG_TUD_MSC_BUFSIZE=4096 -DCFG_TUD_MIDI_RX_BUFSIZE=128 -DCFG_TUD_MIDI_TX_BUFSIZE=128 +CFLAGS += -DCFG_TUD_VENDOR_RX_BUFSIZE=128 -DCFG_TUD_VENDOR_TX_BUFSIZE=128 ###################################### diff --git a/ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.mk b/ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.mk index 2dce03881..52c63cb9c 100644 --- a/ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.mk +++ b/ports/esp32s2/boards/espressif_kaluga_1/mpconfigboard.mk @@ -14,4 +14,10 @@ CIRCUITPY_ESP_FLASH_MODE=dio CIRCUITPY_ESP_FLASH_FREQ=80m CIRCUITPY_ESP_FLASH_SIZE=4MB +# We only have enough endpoints available in hardware to +# enable ONE of these at a time. +CIRCUITPY_USB_MIDI = 1 +CIRCUITPY_USB_HID = 0 +CIRCUITPY_USB_VENDOR = 0 + CIRCUITPY_MODULE=wrover diff --git a/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/board.c b/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/board.c new file mode 100644 index 000000000..aaef97c7d --- /dev/null +++ b/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/board.c @@ -0,0 +1,52 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2020 Scott Shawcroft for Adafruit Industries + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#include "supervisor/board.h" +#include "mpconfigboard.h" +#include "shared-bindings/microcontroller/Pin.h" + +void board_init(void) { + // USB + common_hal_never_reset_pin(&pin_GPIO19); + common_hal_never_reset_pin(&pin_GPIO20); + + // Debug UART +#ifdef DEBUG + common_hal_never_reset_pin(&pin_GPIO43); + common_hal_never_reset_pin(&pin_GPIO44); +#endif /* DEBUG */ +} + +bool board_requests_safe_mode(void) { + return false; +} + +void reset_board(void) { + +} + +void board_deinit(void) { +} diff --git a/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h b/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h new file mode 100644 index 000000000..c9020c200 --- /dev/null +++ b/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.h @@ -0,0 +1,36 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2019 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. + */ + +//Micropython setup + +#define MICROPY_HW_BOARD_NAME "LILYGO TTGO T8 ESP32-S2 w/Display" +#define MICROPY_HW_MCU_NAME "ESP32S2" + +#define CIRCUITPY_BOOT_BUTTON (&pin_GPIO0) + +#define BOARD_USER_SAFE_MODE_ACTION translate("pressing boot button at start up.\n") + +#define AUTORESET_DELAY_MS 500 diff --git a/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.mk b/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.mk new file mode 100644 index 000000000..38a7ed1fb --- /dev/null +++ b/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.mk @@ -0,0 +1,18 @@ +USB_VID = 0x303a +USB_PID = 0x8007 +USB_PRODUCT = "TTGO T8 ESP32-S2" +USB_MANUFACTURER = "LILYGO" +USB_DEVICES = "CDC,MSC,HID" + +INTERNAL_FLASH_FILESYSTEM = 1 +LONGINT_IMPL = MPZ + +# The default queue depth of 16 overflows on release builds, +# so increase it to 32. +CFLAGS += -DCFG_TUD_TASK_QUEUE_SZ=32 + +CIRCUITPY_ESP_FLASH_MODE = dio +CIRCUITPY_ESP_FLASH_FREQ = 40m +CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_MODULE = wroom diff --git a/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/pins.c b/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/pins.c new file mode 100644 index 000000000..bda0fd227 --- /dev/null +++ b/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/pins.c @@ -0,0 +1,55 @@ +#include "shared-bindings/board/__init__.h" + +STATIC const mp_rom_map_elem_t board_global_dict_table[] = { + { MP_ROM_QSTR(MP_QSTR_IO0), MP_ROM_PTR(&pin_GPIO0) }, + { MP_ROM_QSTR(MP_QSTR_IO1), MP_ROM_PTR(&pin_GPIO1) }, + { MP_ROM_QSTR(MP_QSTR_IO2), MP_ROM_PTR(&pin_GPIO2) }, + { MP_ROM_QSTR(MP_QSTR_IO3), MP_ROM_PTR(&pin_GPIO3) }, + { MP_ROM_QSTR(MP_QSTR_IO4), MP_ROM_PTR(&pin_GPIO4) }, + { MP_ROM_QSTR(MP_QSTR_IO5), MP_ROM_PTR(&pin_GPIO5) }, + { MP_ROM_QSTR(MP_QSTR_IO6), MP_ROM_PTR(&pin_GPIO6) }, + { MP_ROM_QSTR(MP_QSTR_IO7), MP_ROM_PTR(&pin_GPIO7) }, + { MP_ROM_QSTR(MP_QSTR_IO8), MP_ROM_PTR(&pin_GPIO8) }, + + { MP_ROM_QSTR(MP_QSTR_IO11), MP_ROM_PTR(&pin_GPIO11) }, + { MP_ROM_QSTR(MP_QSTR_IO12), MP_ROM_PTR(&pin_GPIO12) }, + { MP_ROM_QSTR(MP_QSTR_IO13), MP_ROM_PTR(&pin_GPIO13) }, + { MP_ROM_QSTR(MP_QSTR_IO15), MP_ROM_PTR(&pin_GPIO15) }, + { MP_ROM_QSTR(MP_QSTR_IO16), MP_ROM_PTR(&pin_GPIO16) }, + { MP_ROM_QSTR(MP_QSTR_IO17), MP_ROM_PTR(&pin_GPIO17) }, + { MP_ROM_QSTR(MP_QSTR_IO18), MP_ROM_PTR(&pin_GPIO18) }, + { MP_ROM_QSTR(MP_QSTR_IO19), MP_ROM_PTR(&pin_GPIO19) }, + { MP_ROM_QSTR(MP_QSTR_IO20), MP_ROM_PTR(&pin_GPIO20) }, + { MP_ROM_QSTR(MP_QSTR_IO21), MP_ROM_PTR(&pin_GPIO21) }, + + { MP_ROM_QSTR(MP_QSTR_IO39), MP_ROM_PTR(&pin_GPIO39) }, + { MP_ROM_QSTR(MP_QSTR_IO40), MP_ROM_PTR(&pin_GPIO40) }, + { MP_ROM_QSTR(MP_QSTR_IO41), MP_ROM_PTR(&pin_GPIO41) }, + { MP_ROM_QSTR(MP_QSTR_IO42), MP_ROM_PTR(&pin_GPIO42) }, + { MP_ROM_QSTR(MP_QSTR_IO45), MP_ROM_PTR(&pin_GPIO45) }, + { MP_ROM_QSTR(MP_QSTR_IO46), MP_ROM_PTR(&pin_GPIO46) }, + + { MP_ROM_QSTR(MP_QSTR_TX), MP_ROM_PTR(&pin_GPIO43) }, + { MP_ROM_QSTR(MP_QSTR_RX), MP_ROM_PTR(&pin_GPIO44) }, + { MP_ROM_QSTR(MP_QSTR_TX1), MP_ROM_PTR(&pin_GPIO17) }, + { MP_ROM_QSTR(MP_QSTR_RX1), MP_ROM_PTR(&pin_GPIO18) }, + + // SD Card + { MP_ROM_QSTR(MP_QSTR_SD_MISO), MP_ROM_PTR(&pin_GPIO13) }, + { MP_ROM_QSTR(MP_QSTR_SD_MOSI), MP_ROM_PTR(&pin_GPIO11) }, + { MP_ROM_QSTR(MP_QSTR_SD_CLK), MP_ROM_PTR(&pin_GPIO12) }, + { MP_ROM_QSTR(MP_QSTR_SD_CS), MP_ROM_PTR(&pin_GPIO10) }, + + // 1.14 inch LCD ST7789 + { MP_ROM_QSTR(MP_QSTR_LCD_MISO), MP_ROM_PTR(&pin_GPIO4) }, + { MP_ROM_QSTR(MP_QSTR_LCD_MOSI), MP_ROM_PTR(&pin_GPIO35) }, + { MP_ROM_QSTR(MP_QSTR_LCD_CLK), MP_ROM_PTR(&pin_GPIO36) }, + { MP_ROM_QSTR(MP_QSTR_LCD_CS), MP_ROM_PTR(&pin_GPIO34) }, + { MP_ROM_QSTR(MP_QSTR_LCD_RST), MP_ROM_PTR(&pin_GPIO38) }, + { MP_ROM_QSTR(MP_QSTR_LCD_BCKL), MP_ROM_PTR(&pin_GPIO33) }, + { MP_ROM_QSTR(MP_QSTR_LCD_D_C), MP_ROM_PTR(&pin_GPIO37) }, + + // Peripheral Power control + { MP_ROM_QSTR(MP_QSTR_PE_POWER), MP_ROM_PTR(&pin_GPIO14) }, +}; +MP_DEFINE_CONST_DICT(board_module_globals, board_global_dict_table); diff --git a/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/sdkconfig b/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/sdkconfig new file mode 100644 index 000000000..ce6fe832b --- /dev/null +++ b/ports/esp32s2/boards/lilygo_ttgo_t8_s2_st7789/sdkconfig @@ -0,0 +1,31 @@ +CONFIG_ESP32S2_SPIRAM_SUPPORT=y + +# +# SPI RAM config +# +CONFIG_SPIRAM_TYPE_ESPPSRAM64=y +CONFIG_SPIRAM_SIZE=8388608 + +# +# PSRAM clock and cs IO for ESP32S2 +# +CONFIG_DEFAULT_PSRAM_CLK_IO=30 +CONFIG_DEFAULT_PSRAM_CS_IO=26 +# end of PSRAM clock and cs IO for ESP32S2 + +CONFIG_SPIRAM_SPIWP_SD3_PIN=28 +CONFIG_SPIRAM_SPEED_40M=y +CONFIG_SPIRAM=y +CONFIG_SPIRAM_BOOT_INIT=y +CONFIG_SPIRAM_USE_MALLOC=y +CONFIG_SPIRAM_MEMTEST=y +CONFIG_SPIRAM_MALLOC_ALWAYSINTERNAL=16384 +CONFIG_SPIRAM_MALLOC_RESERVE_INTERNAL=32768 +# end of SPI RAM config + +# +# LWIP +# +CONFIG_LWIP_LOCAL_HOSTNAME="TTGO-T8-ESP32-S2" +CONFIG_LWIP_DNS_SUPPORT_MDNS_QUERIES=y +# end of LWIP diff --git a/ports/esp32s2/common-hal/audiobusio/I2SOut.c b/ports/esp32s2/common-hal/audiobusio/I2SOut.c index 86322be86..eb9b6f8e1 100644 --- a/ports/esp32s2/common-hal/audiobusio/I2SOut.c +++ b/ports/esp32s2/common-hal/audiobusio/I2SOut.c @@ -63,6 +63,9 @@ void common_hal_audiobusio_i2sout_construct(audiobusio_i2sout_obj_t* self, self->bit_clock = bit_clock; self->word_select = word_select; self->data = data; + claim_pin(bit_clock); + claim_pin(word_select); + claim_pin(data); } bool common_hal_audiobusio_i2sout_deinited(audiobusio_i2sout_obj_t* self) { diff --git a/ports/esp32s2/common-hal/busio/I2C.c b/ports/esp32s2/common-hal/busio/I2C.c index 772262d0a..8372eb8c3 100644 --- a/ports/esp32s2/common-hal/busio/I2C.c +++ b/ports/esp32s2/common-hal/busio/I2C.c @@ -85,7 +85,7 @@ void common_hal_busio_i2c_construct(busio_i2c_obj_t *self, if (gpio_get_level(sda->number) == 0 || gpio_get_level(scl->number) == 0) { reset_pin_number(sda->number); reset_pin_number(scl->number); - mp_raise_RuntimeError(translate("SDA or SCL needs a pull up")); + mp_raise_RuntimeError(translate("No pull up found on SDA or SCL; check your wiring")); } #endif diff --git a/ports/esp32s2/common-hal/displayio/ParallelBus.c b/ports/esp32s2/common-hal/displayio/ParallelBus.c index d0c98f361..f77b37b57 100644 --- a/ports/esp32s2/common-hal/displayio/ParallelBus.c +++ b/ports/esp32s2/common-hal/displayio/ParallelBus.c @@ -33,35 +33,196 @@ #include "shared-bindings/digitalio/DigitalInOut.h" #include "shared-bindings/microcontroller/__init__.h" +/* + * Current pin limitations for ESP32-S2 ParallelBus: + * - data0 pin must be byte aligned + */ + void common_hal_displayio_parallelbus_construct(displayio_parallelbus_obj_t* self, const mcu_pin_obj_t* data0, const mcu_pin_obj_t* command, const mcu_pin_obj_t* chip_select, const mcu_pin_obj_t* write, const mcu_pin_obj_t* read, const mcu_pin_obj_t* reset) { - mp_raise_NotImplementedError(translate("ParallelBus not yet supported")); + uint8_t data_pin = data0->number; + if (data_pin % 8 != 0) { + mp_raise_ValueError(translate("Data 0 pin must be byte aligned.")); + } + + for (uint8_t i = 0; i < 8; i++) { + if (!pin_number_is_free(data_pin + i)) { + mp_raise_ValueError_varg(translate("Bus pin %d is already in use"), i); + } + } + + gpio_dev_t *g = &GPIO; // this is the GPIO registers, see "extern gpio_dev_t GPIO" from file:gpio_struct.h + + // Setup the pins as "Simple GPIO outputs" see section 19.3.3 of the ESP32-S2 Reference Manual + // Enable pins with "enable_w1ts" + + for (uint8_t i = 0; i < 8; i++) { + g->enable_w1ts = (0x1 << (data_pin + i)); + g->func_out_sel_cfg[data_pin + i].val= 256; /* setup output pin for simple GPIO Output, (0x100 = 256) */ + + } + + /* From my understanding, there is a limitation of the ESP32-S2 that does not allow single-byte writes + * into the GPIO registers. See section 10.3.3 regarding "non-aligned writes" into the registers. + */ + + + if (data_pin < 31) { + self->bus = (uint32_t*) &g->out; //pointer to GPIO output register (for pins 0-31) + } else { + self->bus = (uint32_t*) &g->out1.val; //pointer to GPIO output register (for pins >= 32) + } + + /* SNIP - common setup of command, chip select, write and read pins, same as from SAMD and NRF ports */ + self->command.base.type = &digitalio_digitalinout_type; + common_hal_digitalio_digitalinout_construct(&self->command, command); + common_hal_digitalio_digitalinout_switch_to_output(&self->command, true, DRIVE_MODE_PUSH_PULL); + + self->chip_select.base.type = &digitalio_digitalinout_type; + common_hal_digitalio_digitalinout_construct(&self->chip_select, chip_select); + common_hal_digitalio_digitalinout_switch_to_output(&self->chip_select, true, DRIVE_MODE_PUSH_PULL); + + self->write.base.type = &digitalio_digitalinout_type; + common_hal_digitalio_digitalinout_construct(&self->write, write); + common_hal_digitalio_digitalinout_switch_to_output(&self->write, true, DRIVE_MODE_PUSH_PULL); + + self->read.base.type = &digitalio_digitalinout_type; + common_hal_digitalio_digitalinout_construct(&self->read, read); + common_hal_digitalio_digitalinout_switch_to_output(&self->read, true, DRIVE_MODE_PUSH_PULL); + + self->data0_pin = data_pin; + + if (write->number < 32) { + self->write_clear_register = (uint32_t*) &g->out_w1tc; + self->write_set_register = (uint32_t*) &g->out_w1ts; + } else { + self->write_clear_register = (uint32_t*) &g->out1_w1tc.val; + self->write_set_register = (uint32_t*) &g->out1_w1ts.val; + } + + // Check to see if the data and write pins are on the same register: + if ( ( ((self->data0_pin < 32) && (write->number < 32)) ) || + ( ((self->data0_pin > 31) && (write->number > 31)) ) ) { + self->data_write_same_register = true; // data pins and write pin are on the same register + } else { + self->data_write_same_register = false; // data pins and write pins are on different registers + } + + + self->write_mask = 1 << (write->number % 32); /* the write pin triggers the LCD to latch the data */ + + /* SNIP - common setup of the reset pin, same as from SAMD and NRF ports */ + self->reset.base.type = &mp_type_NoneType; + if (reset != NULL) { + self->reset.base.type = &digitalio_digitalinout_type; + common_hal_digitalio_digitalinout_construct(&self->reset, reset); + common_hal_digitalio_digitalinout_switch_to_output(&self->reset, true, DRIVE_MODE_PUSH_PULL); + never_reset_pin_number(reset->number); + common_hal_displayio_parallelbus_reset(self); + } + + never_reset_pin_number(command->number); + never_reset_pin_number(chip_select->number); + never_reset_pin_number(write->number); + never_reset_pin_number(read->number); + for (uint8_t i = 0; i < 8; i++) { + never_reset_pin_number(data_pin + i); + } + } void common_hal_displayio_parallelbus_deinit(displayio_parallelbus_obj_t* self) { + /* SNIP - same as from SAMD and NRF ports */ + for (uint8_t i = 0; i < 8; i++) { + reset_pin_number(self->data0_pin + i); + } + reset_pin_number(self->command.pin->number); + reset_pin_number(self->chip_select.pin->number); + reset_pin_number(self->write.pin->number); + reset_pin_number(self->read.pin->number); + reset_pin_number(self->reset.pin->number); } bool common_hal_displayio_parallelbus_reset(mp_obj_t obj) { - return false; + /* SNIP - same as from SAMD and NRF ports */ + displayio_parallelbus_obj_t* self = MP_OBJ_TO_PTR(obj); + if (self->reset.base.type == &mp_type_NoneType) { + return false; + } + + common_hal_digitalio_digitalinout_set_value(&self->reset, false); + common_hal_mcu_delay_us(4); + common_hal_digitalio_digitalinout_set_value(&self->reset, true); + return true; + } bool common_hal_displayio_parallelbus_bus_free(mp_obj_t obj) { - return false; + /* SNIP - same as from SAMD and NRF ports */ + return true; } bool common_hal_displayio_parallelbus_begin_transaction(mp_obj_t obj) { - - return false; + /* SNIP - same as from SAMD and NRF ports */ + displayio_parallelbus_obj_t* self = MP_OBJ_TO_PTR(obj); + common_hal_digitalio_digitalinout_set_value(&self->chip_select, false); + return true; } void common_hal_displayio_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type, - display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length) { + display_chip_select_behavior_t chip_select, const uint8_t *data, uint32_t data_length) { + displayio_parallelbus_obj_t* self = MP_OBJ_TO_PTR(obj); + common_hal_digitalio_digitalinout_set_value(&self->command, byte_type == DISPLAY_DATA); + + uint32_t* clear_write = self->write_clear_register; + uint32_t* set_write = self->write_set_register; + + const uint32_t mask = self->write_mask; + + /* Setup structures for data writing. The ESP32-S2 port differs from the SAMD and NRF ports + * because I have not found a way to write a single byte into the ESP32-S2 registers. + * For the ESP32-S2, I create a 32-bit data_buffer that is used to transfer the data bytes. + */ + + *clear_write = mask; // Clear the write pin to prepare the registers before storing the + // register value into data_buffer + + const uint32_t data_buffer = *self->bus; // store the initial output register values into the data output buffer + uint8_t* data_address = ((uint8_t*) &data_buffer) + (self->data0_pin / 8); /* address inside data_buffer where + * each data byte will be written to the data pin registers + */ + + + if ( self->data_write_same_register ) { // data and write pins are on the same register + for (uint32_t i = 0; i < data_length; i++) { + + /* Note: If the write pin and data pins are controlled by the same GPIO register, we can eliminate + * the "clear_write" step below, since the write pin is cleared when the data_buffer is written + * to the bus. + */ + + *(data_address) = data[i]; // stuff the data byte into the data_buffer at the correct offset byte location + *self->bus = data_buffer; // write the data to the output register + *set_write = mask; // set the write pin + } + } + else { // data and write pins are on different registers + for (uint32_t i = 0; i < data_length; i++) { + *clear_write = mask; // clear the write pin (See comment above, this may not be necessary). + *(data_address) = data[i]; // stuff the data byte into the data_buffer at the correct offset byte location + *self->bus = data_buffer; // write the data to the output register + *set_write = mask; // set the write pin + + } + } } void common_hal_displayio_parallelbus_end_transaction(mp_obj_t obj) { - + /* SNIP - same as from SAMD and NRF ports */ + displayio_parallelbus_obj_t* self = MP_OBJ_TO_PTR(obj); + common_hal_digitalio_digitalinout_set_value(&self->chip_select, true); } diff --git a/ports/esp32s2/common-hal/displayio/ParallelBus.h b/ports/esp32s2/common-hal/displayio/ParallelBus.h index cd636921d..84302118b 100644 --- a/ports/esp32s2/common-hal/displayio/ParallelBus.h +++ b/ports/esp32s2/common-hal/displayio/ParallelBus.h @@ -31,6 +31,17 @@ typedef struct { mp_obj_base_t base; + uint32_t* bus; // pointer where 8 bits of data are written to the display + digitalio_digitalinout_obj_t command; + digitalio_digitalinout_obj_t chip_select; + digitalio_digitalinout_obj_t reset; + digitalio_digitalinout_obj_t write; + digitalio_digitalinout_obj_t read; + uint8_t data0_pin; // pin number for the lowest number data pin. Must be 8-bit aligned + bool data_write_same_register; // if data and write pins are in the sare + uint32_t* write_set_register; // pointer to the write group for setting the write bit to latch the data on the LCD + uint32_t* write_clear_register; // pointer to the write group for clearing the write bit to latch the data on the LCD + uint32_t write_mask; // bit mask for the single bit for the write pin register } displayio_parallelbus_obj_t; #endif // MICROPY_INCLUDED_ESP32S2_COMMON_HAL_DISPLAYIO_PARALLELBUS_H diff --git a/ports/esp32s2/common-hal/socketpool/Socket.c b/ports/esp32s2/common-hal/socketpool/Socket.c index 5e943f8fd..1cdbc9058 100644 --- a/ports/esp32s2/common-hal/socketpool/Socket.c +++ b/ports/esp32s2/common-hal/socketpool/Socket.c @@ -3,7 +3,7 @@ * * The MIT License (MIT) * - * Copyright (c) 2020 Scott Shawcroft for Adafruit Industries + * Copyright (c) 2020 Lucian Copeland for Adafruit Industries * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -37,140 +37,168 @@ #include "components/lwip/lwip/src/include/lwip/sys.h" #include "components/lwip/lwip/src/include/lwip/netdb.h" -void common_hal_socketpool_socket_settimeout(socketpool_socket_obj_t* self, mp_uint_t timeout_ms) { - self->timeout_ms = timeout_ms; -} +STATIC socketpool_socket_obj_t * open_socket_handles[CONFIG_LWIP_MAX_SOCKETS]; -bool common_hal_socketpool_socket_connect(socketpool_socket_obj_t* self, const char* host, mp_uint_t hostlen, mp_int_t port) { - // For simplicity we use esp_tls for all TCP connections. If it's not SSL, ssl_context will be - // NULL and should still work. This makes regular TCP connections more memory expensive but TLS - // should become more and more common. Therefore, we optimize for the TLS case. - - esp_tls_cfg_t* tls_config = NULL; - if (self->ssl_context != NULL) { - tls_config = &self->ssl_context->ssl_config; - } - int result = esp_tls_conn_new_sync(host, hostlen, port, tls_config, self->tcp); - self->connected = result >= 0; - if (result < 0) { - int esp_tls_code; - int flags; - esp_err_t err = esp_tls_get_and_clear_last_error(self->tcp->error_handle, &esp_tls_code, &flags); - - if (err == ESP_ERR_MBEDTLS_SSL_SETUP_FAILED) { - mp_raise_espidf_MemoryError(); - } else if (ESP_ERR_MBEDTLS_SSL_HANDSHAKE_FAILED) { - mp_raise_OSError_msg_varg(translate("Failed SSL handshake")); - } else { - mp_raise_OSError_msg_varg(translate("Unhandled ESP TLS error %d %d %x %d"), esp_tls_code, flags, err, result); +void socket_reset(void) { + for (size_t i = 0; i < MP_ARRAY_SIZE(open_socket_handles); i++) { + if (open_socket_handles[i]) { + if (open_socket_handles[i]->num > 0) { + // Close automatically clears socket handle + common_hal_socketpool_socket_close(open_socket_handles[i]); + } else { + open_socket_handles[i] = NULL; + } } - } else { - // Connection successful, set the timeout on the underlying socket. We can't rely on the IDF - // to do it because the config structure is only used for TLS connections. Generally, we - // shouldn't hit this timeout because we try to only read available data. However, there is - // always a chance that we try to read something that is used internally. - int fd; - esp_tls_get_conn_sockfd(self->tcp, &fd); - struct timeval tv; - tv.tv_sec = 2 * 60; // Two minutes - tv.tv_usec = 0; - setsockopt(fd, SOL_SOCKET, SO_RCVTIMEO, &tv, sizeof(tv)); - setsockopt(fd, SOL_SOCKET, SO_SNDTIMEO, &tv, sizeof(tv)); } - - return self->connected; } -bool common_hal_socketpool_socket_get_connected(socketpool_socket_obj_t* self) { - return self->connected; -} - -mp_uint_t common_hal_socketpool_socket_send(socketpool_socket_obj_t* self, const uint8_t* buf, mp_uint_t len) { - size_t sent = esp_tls_conn_write(self->tcp, buf, len); - - if (sent < 0) { - mp_raise_OSError(MP_ENOTCONN); +bool register_open_socket(socketpool_socket_obj_t* self) { + for (size_t i = 0; i < MP_ARRAY_SIZE(open_socket_handles); i++) { + if (open_socket_handles[i] == NULL) { + open_socket_handles[i] = self; + return true; + } } - return sent; + return false; } -mp_uint_t common_hal_socketpool_socket_recv_into(socketpool_socket_obj_t* self, const uint8_t* buf, mp_uint_t len) { - size_t received = 0; - int status = 0; +socketpool_socket_obj_t* common_hal_socketpool_socket_accept(socketpool_socket_obj_t* self, + uint8_t* ip, uint *port) { + struct sockaddr_in accept_addr; + socklen_t socklen = sizeof(accept_addr); + int newsoc = -1; + bool timed_out = false; uint64_t start_ticks = supervisor_ticks_ms64(); - int sockfd; - esp_err_t err = esp_tls_get_conn_sockfd(self->tcp, &sockfd); - if (err != ESP_OK) { - mp_raise_OSError(MP_EBADF); - } - while (received == 0 && - status >= 0 && - (self->timeout_ms == 0 || supervisor_ticks_ms64() - start_ticks <= self->timeout_ms) && + + // Allow timeouts and interrupts + while (newsoc == -1 && + !timed_out && !mp_hal_is_interrupted()) { - RUN_BACKGROUND_TASKS; - size_t available = esp_tls_get_bytes_avail(self->tcp); - if (available == 0) { - // This reads the raw socket buffer and is used for non-TLS connections - // and between encrypted TLS blocks. - status = lwip_ioctl(sockfd, FIONREAD, &available); + if (self->timeout_ms != (uint)-1 && self->timeout_ms != 0) { + timed_out = supervisor_ticks_ms64() - start_ticks >= self->timeout_ms; } - size_t remaining = len - received; - if (available > remaining) { - available = remaining; + RUN_BACKGROUND_TASKS; + newsoc = lwip_accept(self->num, (struct sockaddr *)&accept_addr, &socklen); + // In non-blocking mode, fail instead of timing out + if (newsoc == -1 && self->timeout_ms == 0) { + mp_raise_OSError(MP_EAGAIN); } - if (available > 0) { - status = esp_tls_conn_read(self->tcp, (void*) buf + received, available); - if (status == 0) { - // Reading zero when something is available indicates a closed - // connection. (The available bytes could have been TLS internal.) - break; - } - if (status > 0) { - received += status; - } + } + + if (!timed_out) { + // harmless on failure but avoiding memcpy is faster + memcpy((void *)ip, (void*)&accept_addr.sin_addr.s_addr, sizeof(accept_addr.sin_addr.s_addr)); + *port = accept_addr.sin_port; + } else { + mp_raise_OSError(ETIMEDOUT); + } + + if (newsoc > 0) { + // Create the socket + socketpool_socket_obj_t *sock = m_new_obj_with_finaliser(socketpool_socket_obj_t); + sock->base.type = &socketpool_socket_type; + sock->num = newsoc; + sock->pool = self->pool; + + if (!register_open_socket(sock)) { + mp_raise_OSError(MP_EBADF); } + + lwip_fcntl(newsoc, F_SETFL, O_NONBLOCK); + return sock; + } else { + mp_raise_OSError(MP_EBADF); + return NULL; } +} - if (received == 0) { - // socket closed - common_hal_socketpool_socket_close(self); +bool common_hal_socketpool_socket_bind(socketpool_socket_obj_t* self, + const char* host, size_t hostlen, uint8_t port) { + struct sockaddr_in bind_addr; + bind_addr.sin_addr.s_addr = inet_addr(host); + bind_addr.sin_family = AF_INET; + bind_addr.sin_port = htons(port); + + int opt = 1; + int err = lwip_setsockopt(self->num, SOL_SOCKET, SO_REUSEADDR, &opt, sizeof(opt)); + if (err != 0) { + mp_raise_RuntimeError(translate("Cannot set socket options")); } - return received; + int result = lwip_bind(self->num, (struct sockaddr *)&bind_addr, sizeof(bind_addr)) == 0; + return result; } -mp_uint_t common_hal_socketpool_socket_sendto(socketpool_socket_obj_t* self, - const char* host, size_t hostlen, uint8_t port, const uint8_t* buf, mp_uint_t len) { +void common_hal_socketpool_socket_close(socketpool_socket_obj_t* self) { + self->connected = false; + if (self->num >= 0) { + lwip_shutdown(self->num, 0); + lwip_close(self->num); + self->num = -1; + } + // Remove socket record + for (size_t i = 0; i < MP_ARRAY_SIZE(open_socket_handles); i++) { + if (open_socket_handles[i] == self) { + open_socket_handles[i] = NULL; + } + } +} - // Get the IP address string +bool common_hal_socketpool_socket_connect(socketpool_socket_obj_t* self, + const char* host, mp_uint_t hostlen, mp_int_t port) { const struct addrinfo hints = { .ai_family = AF_INET, .ai_socktype = SOCK_STREAM, }; - struct addrinfo *result; - int error = lwip_getaddrinfo(host, NULL, &hints, &result); - if (error != 0 || result == NULL) { - return 0; + struct addrinfo *result_i; + int error = lwip_getaddrinfo(host, NULL, &hints, &result_i); + if (error != 0 || result_i == NULL) { + mp_raise_OSError(EHOSTUNREACH); } + + // Set parameters + struct sockaddr_in dest_addr; #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wcast-align" - struct in_addr *addr = &((struct sockaddr_in *)result->ai_addr)->sin_addr; + dest_addr.sin_addr.s_addr = ((struct sockaddr_in *)result_i->ai_addr)->sin_addr.s_addr; #pragma GCC diagnostic pop - char ip_str[IP4ADDR_STRLEN_MAX]; - inet_ntoa_r(*addr, ip_str, IP4ADDR_STRLEN_MAX); - freeaddrinfo(result); + freeaddrinfo(result_i); - // Set parameters - struct sockaddr_in dest_addr; - dest_addr.sin_addr.s_addr = inet_addr((const char *)ip_str); dest_addr.sin_family = AF_INET; dest_addr.sin_port = htons(port); - int bytes_sent = lwip_sendto(self->num, buf, len, 0, (struct sockaddr *)&dest_addr, sizeof(dest_addr)); - if (bytes_sent < 0) { - mp_raise_BrokenPipeError(); - return 0; + // Replace above with function call ----- + + // Switch to blocking mode for this one call + int opts; + opts = lwip_fcntl(self->num,F_GETFL,0); + opts = opts & (~O_NONBLOCK); + lwip_fcntl(self->num, F_SETFL, opts); + + int result = -1; + result = lwip_connect(self->num, (struct sockaddr *)&dest_addr, sizeof(struct sockaddr_in)); + + // Switch back once complete + opts = opts | O_NONBLOCK; + lwip_fcntl(self->num, F_SETFL, opts); + + if (result >= 0) { + self->connected = true; + return true; + } else { + mp_raise_OSError(errno); } - return bytes_sent; +} + +bool common_hal_socketpool_socket_get_closed(socketpool_socket_obj_t* self) { + return self->num < 0; +} + +bool common_hal_socketpool_socket_get_connected(socketpool_socket_obj_t* self) { + return self->connected; +} + +bool common_hal_socketpool_socket_listen(socketpool_socket_obj_t* self, int backlog) { + return lwip_listen(self->num, backlog) == 0; } mp_uint_t common_hal_socketpool_socket_recvfrom_into(socketpool_socket_obj_t* self, @@ -178,37 +206,122 @@ mp_uint_t common_hal_socketpool_socket_recvfrom_into(socketpool_socket_obj_t* se struct sockaddr_in source_addr; socklen_t socklen = sizeof(source_addr); - int bytes_received = lwip_recvfrom(self->num, buf, len, 0, (struct sockaddr *)&source_addr, &socklen); - memcpy((void *)ip, (void*)&source_addr.sin_addr.s_addr, sizeof source_addr.sin_addr.s_addr); - *port = source_addr.sin_port; + // LWIP Socket + uint64_t start_ticks = supervisor_ticks_ms64(); + int received = -1; + bool timed_out = false; + while (received == -1 && + !timed_out && + !mp_hal_is_interrupted()) { + if (self->timeout_ms != (uint)-1 && self->timeout_ms != 0) { + timed_out = supervisor_ticks_ms64() - start_ticks >= self->timeout_ms; + } + RUN_BACKGROUND_TASKS; + received = lwip_recvfrom(self->num, buf, len, 0, (struct sockaddr *)&source_addr, &socklen); - if (bytes_received < 0) { + // In non-blocking mode, fail instead of looping + if (received == -1 && self->timeout_ms == 0) { + mp_raise_OSError(MP_EAGAIN); + } + } + + if (!timed_out) { + memcpy((void *)ip, (void*)&source_addr.sin_addr.s_addr, sizeof(source_addr.sin_addr.s_addr)); + *port = source_addr.sin_port; + } else { + mp_raise_OSError(ETIMEDOUT); + } + + if (received < 0) { mp_raise_BrokenPipeError(); return 0; } - return bytes_received; + return received; } -void common_hal_socketpool_socket_close(socketpool_socket_obj_t* self) { - self->connected = false; - if (self->tcp != NULL) { - esp_tls_conn_destroy(self->tcp); - self->tcp = NULL; +mp_uint_t common_hal_socketpool_socket_recv_into(socketpool_socket_obj_t* self, const uint8_t* buf, mp_uint_t len) { + int received = 0; + bool timed_out = false; + + if (self->num != -1) { + // LWIP Socket + uint64_t start_ticks = supervisor_ticks_ms64(); + received = -1; + while (received == -1 && + !timed_out && + !mp_hal_is_interrupted()) { + if (self->timeout_ms != (uint)-1 && self->timeout_ms != 0) { + timed_out = supervisor_ticks_ms64() - start_ticks >= self->timeout_ms; + } + RUN_BACKGROUND_TASKS; + received = lwip_recv(self->num, (void*) buf, len, 0); + + // In non-blocking mode, fail instead of looping + if (received == -1 && self->timeout_ms == 0) { + mp_raise_OSError(MP_EAGAIN); + } + } + } else { + mp_raise_OSError(MP_EBADF); } - if (self->num >= 0) { - lwip_shutdown(self->num, 0); - lwip_close(self->num); - self->num = -1; + + if (timed_out) { + mp_raise_OSError(ETIMEDOUT); } + return received; } -bool common_hal_socketpool_socket_get_closed(socketpool_socket_obj_t* self) { - return self->tcp == NULL && self->num < 0; +mp_uint_t common_hal_socketpool_socket_send(socketpool_socket_obj_t* self, const uint8_t* buf, mp_uint_t len) { + int sent = -1; + if (self->num != -1) { + // LWIP Socket + // TODO: deal with potential failure/add timeout? + sent = lwip_send(self->num, buf, len, 0); + } else { + mp_raise_OSError(MP_EBADF); + } + + if (sent < 0) { + mp_raise_OSError(errno); + } + return sent; } +mp_uint_t common_hal_socketpool_socket_sendto(socketpool_socket_obj_t* self, + const char* host, size_t hostlen, uint8_t port, const uint8_t* buf, mp_uint_t len) { + + // Set parameters + const struct addrinfo hints = { + .ai_family = AF_INET, + .ai_socktype = SOCK_STREAM, + }; + struct addrinfo *result_i; + int error = lwip_getaddrinfo(host, NULL, &hints, &result_i); + if (error != 0 || result_i == NULL) { + mp_raise_OSError(EHOSTUNREACH); + } + + // Set parameters + struct sockaddr_in dest_addr; + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wcast-align" + dest_addr.sin_addr.s_addr = ((struct sockaddr_in *)result_i->ai_addr)->sin_addr.s_addr; + #pragma GCC diagnostic pop + freeaddrinfo(result_i); + + dest_addr.sin_family = AF_INET; + dest_addr.sin_port = htons(port); -mp_uint_t common_hal_socketpool_socket_get_hash(socketpool_socket_obj_t* self) { - return self->num; + int bytes_sent = lwip_sendto(self->num, buf, len, 0, (struct sockaddr *)&dest_addr, sizeof(dest_addr)); + if (bytes_sent < 0) { + mp_raise_BrokenPipeError(); + return 0; + } + return bytes_sent; +} + +void common_hal_socketpool_socket_settimeout(socketpool_socket_obj_t* self, mp_uint_t timeout_ms) { + self->timeout_ms = timeout_ms; } diff --git a/ports/esp32s2/common-hal/socketpool/Socket.h b/ports/esp32s2/common-hal/socketpool/Socket.h index 62b5ded58..b86f5597c 100644 --- a/ports/esp32s2/common-hal/socketpool/Socket.h +++ b/ports/esp32s2/common-hal/socketpool/Socket.h @@ -37,11 +37,15 @@ typedef struct { mp_obj_base_t base; int num; + int type; + int family; + int ipproto; bool connected; - esp_tls_t* tcp; - ssl_sslcontext_obj_t* ssl_context; socketpool_socketpool_obj_t* pool; mp_uint_t timeout_ms; } socketpool_socket_obj_t; +void socket_reset(void); +bool register_open_socket(socketpool_socket_obj_t* self); + #endif // MICROPY_INCLUDED_ESP32S2_COMMON_HAL_SOCKETPOOL_SOCKET_H diff --git a/ports/esp32s2/common-hal/socketpool/SocketPool.c b/ports/esp32s2/common-hal/socketpool/SocketPool.c index 3bec5f337..fbd6dca7a 100644 --- a/ports/esp32s2/common-hal/socketpool/SocketPool.c +++ b/ports/esp32s2/common-hal/socketpool/SocketPool.c @@ -25,6 +25,7 @@ */ #include "shared-bindings/socketpool/SocketPool.h" +#include "common-hal/socketpool/Socket.h" #include "py/runtime.h" #include "shared-bindings/wifi/__init__.h" @@ -65,27 +66,23 @@ socketpool_socket_obj_t* common_hal_socketpool_socket(socketpool_socketpool_obj_ mp_raise_NotImplementedError(translate("Only IPv4 sockets supported")); } + socketpool_socket_obj_t *sock = m_new_obj_with_finaliser(socketpool_socket_obj_t); + sock->base.type = &socketpool_socket_type; + sock->type = socket_type; + sock->family = addr_family; + sock->ipproto = ipproto; + sock->pool = self; + sock->timeout_ms = (uint)-1; + + // Create LWIP socket int socknum = -1; - esp_tls_t* tcp_handle = NULL; - if (socket_type == SOCK_DGRAM || socket_type == SOCK_RAW) { - socknum = lwip_socket(addr_family, socket_type, ipproto); - } else { - tcp_handle = esp_tls_init(); - - if (tcp_handle == NULL) { - mp_raise_espidf_MemoryError(); - } - } - if (socknum < 0 && tcp_handle == NULL) { + socknum = lwip_socket(sock->family, sock->type, sock->ipproto); + if (socknum < 0 || !register_open_socket(sock)) { mp_raise_RuntimeError(translate("Out of sockets")); } - - socketpool_socket_obj_t *sock = m_new_obj_with_finaliser(socketpool_socket_obj_t); - sock->base.type = &socketpool_socket_type; sock->num = socknum; - sock->tcp = tcp_handle; - sock->ssl_context = NULL; - sock->pool = self; + // Sockets should be nonblocking in most cases + lwip_fcntl(socknum, F_SETFL, O_NONBLOCK); return sock; } diff --git a/ports/esp32s2/common-hal/ssl/SSLContext.c b/ports/esp32s2/common-hal/ssl/SSLContext.c index e24fd338b..afc3ecce2 100644 --- a/ports/esp32s2/common-hal/ssl/SSLContext.c +++ b/ports/esp32s2/common-hal/ssl/SSLContext.c @@ -25,6 +25,9 @@ */ #include "shared-bindings/ssl/SSLContext.h" +#include "shared-bindings/ssl/SSLSocket.h" + +#include "bindings/espidf/__init__.h" #include "py/runtime.h" @@ -32,10 +35,26 @@ void common_hal_ssl_sslcontext_construct(ssl_sslcontext_obj_t* self) { } -socketpool_socket_obj_t* common_hal_ssl_sslcontext_wrap_socket(ssl_sslcontext_obj_t* self, +ssl_sslsocket_obj_t* common_hal_ssl_sslcontext_wrap_socket(ssl_sslcontext_obj_t* self, socketpool_socket_obj_t* socket, bool server_side, const char* server_hostname) { - socket->ssl_context = self; + if (socket->type != SOCK_STREAM) { + mp_raise_RuntimeError(translate("Invalid socket for TLS")); + } + + ssl_sslsocket_obj_t *sock = m_new_obj_with_finaliser(ssl_sslsocket_obj_t); + sock->base.type = &ssl_sslsocket_type; + sock->ssl_context = self; + sock->sock = socket; + + esp_tls_t* tls_handle = esp_tls_init(); + if (tls_handle == NULL) { + mp_raise_espidf_MemoryError(); + } + sock->tls = tls_handle; + + // TODO: do something with the original socket? Don't call a close on the internal LWIP. + // Should we store server hostname on the socket in case connect is called with an ip? - return socket; + return sock; } diff --git a/ports/esp32s2/common-hal/ssl/SSLSocket.c b/ports/esp32s2/common-hal/ssl/SSLSocket.c new file mode 100644 index 000000000..33507e0f4 --- /dev/null +++ b/ports/esp32s2/common-hal/ssl/SSLSocket.c @@ -0,0 +1,176 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2020 Scott Shawcroft for Adafruit Industries + * Copyright (c) 2021 Lucian Copeland for Adafruit Industries + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#include "shared-bindings/ssl/SSLSocket.h" +#include "shared-bindings/socketpool/Socket.h" +#include "shared-bindings/ssl/SSLContext.h" + +#include "bindings/espidf/__init__.h" +#include "lib/utils/interrupt_char.h" +#include "py/mperrno.h" +#include "py/runtime.h" +#include "supervisor/shared/tick.h" + +void common_hal_ssl_sslsocket_settimeout(ssl_sslsocket_obj_t* self, mp_uint_t timeout_ms) { + self->sock->timeout_ms = timeout_ms; +} + +ssl_sslsocket_obj_t* common_hal_ssl_sslsocket_accept(ssl_sslsocket_obj_t* self, + uint8_t* ip, uint *port) { + socketpool_socket_obj_t * sock = common_hal_socketpool_socket_accept(self->sock, ip, port); + ssl_sslsocket_obj_t * sslsock = common_hal_ssl_sslcontext_wrap_socket(self->ssl_context, sock, false, NULL); + return sslsock; +} + +bool common_hal_ssl_sslsocket_bind(ssl_sslsocket_obj_t* self, + const char* host, size_t hostlen, uint8_t port) { + return common_hal_socketpool_socket_bind(self->sock, host, hostlen, port); +} + +void common_hal_ssl_sslsocket_close(ssl_sslsocket_obj_t* self) { + common_hal_socketpool_socket_close(self->sock); + esp_tls_conn_destroy(self->tls); + self->tls = NULL; +} + +bool common_hal_ssl_sslsocket_connect(ssl_sslsocket_obj_t* self, + const char* host, mp_uint_t hostlen, mp_int_t port) { + esp_tls_cfg_t* tls_config = NULL; + tls_config = &self->ssl_context->ssl_config; + int result = esp_tls_conn_new_sync(host, hostlen, port, tls_config, self->tls); + self->sock->connected = result >= 0; + if (result < 0) { + int esp_tls_code; + int flags; + esp_err_t err = esp_tls_get_and_clear_last_error(self->tls->error_handle, &esp_tls_code, &flags); + + if (err == ESP_ERR_MBEDTLS_SSL_SETUP_FAILED) { + mp_raise_espidf_MemoryError(); + } else if (ESP_ERR_MBEDTLS_SSL_HANDSHAKE_FAILED) { + mp_raise_OSError_msg_varg(translate("Failed SSL handshake")); + } else { + mp_raise_OSError_msg_varg(translate("Unhandled ESP TLS error %d %d %x %d"), esp_tls_code, flags, err, result); + } + } else { + // Connection successful, set the timeout on the underlying socket. We can't rely on the IDF + // to do it because the config structure is only used for TLS connections. Generally, we + // shouldn't hit this timeout because we try to only read available data. However, there is + // always a chance that we try to read something that is used internally. + int fd; + esp_tls_get_conn_sockfd(self->tls, &fd); + struct timeval tv; + tv.tv_sec = 2 * 60; // Two minutes + tv.tv_usec = 0; + setsockopt(fd, SOL_SOCKET, SO_RCVTIMEO, &tv, sizeof(tv)); + setsockopt(fd, SOL_SOCKET, SO_SNDTIMEO, &tv, sizeof(tv)); + } + + return self->sock->connected; +} + +bool common_hal_ssl_sslsocket_get_closed(ssl_sslsocket_obj_t* self) { + return self->tls == NULL && self->sock->num < 0; +} + +bool common_hal_ssl_sslsocket_get_connected(ssl_sslsocket_obj_t* self) { + return self->sock->connected; +} + +bool common_hal_ssl_sslsocket_listen(ssl_sslsocket_obj_t* self, int backlog) { + return common_hal_socketpool_socket_listen(self->sock, backlog); +} + +mp_uint_t common_hal_ssl_sslsocket_recv_into(ssl_sslsocket_obj_t* self, const uint8_t* buf, mp_uint_t len) { + int received = 0; + bool timed_out = false; + int status = 0; + uint64_t start_ticks = supervisor_ticks_ms64(); + int sockfd; + esp_err_t err = esp_tls_get_conn_sockfd(self->tls, &sockfd); + if (err != ESP_OK) { + mp_raise_OSError(MP_EBADF); + } + while (received == 0 && + status >= 0 && + !timed_out && + !mp_hal_is_interrupted()) { + if (self->sock->timeout_ms != (uint)-1 && self->sock->timeout_ms != 0) { + timed_out = self->sock->timeout_ms == 0 || supervisor_ticks_ms64() - start_ticks >= self->sock->timeout_ms; + } + RUN_BACKGROUND_TASKS; + size_t available = esp_tls_get_bytes_avail(self->tls); + if (available == 0) { + // This reads the raw socket buffer and is used for non-TLS connections + // and between encrypted TLS blocks. + status = lwip_ioctl(sockfd, FIONREAD, &available); + } + size_t remaining = len - received; + if (available > remaining) { + available = remaining; + } + if (available > 0) { + status = esp_tls_conn_read(self->tls, (void*) buf + received, available); + if (status == 0) { + // Reading zero when something is available indicates a closed + // connection. (The available bytes could have been TLS internal.) + break; + } + if (status > 0) { + received += status; + } + } + // In non-blocking mode, fail instead of timing out + if (received==0 && self->sock->timeout_ms == 0) { + mp_raise_OSError(MP_EAGAIN); + } + } + + if (timed_out) { + mp_raise_OSError(ETIMEDOUT); + } + return received; +} + +mp_uint_t common_hal_ssl_sslsocket_send(ssl_sslsocket_obj_t* self, const uint8_t* buf, mp_uint_t len) { + int sent = -1; + sent = esp_tls_conn_write(self->tls, buf, len); + + if (sent < 0) { + int esp_tls_code; + int flags; + esp_err_t err = esp_tls_get_and_clear_last_error(self->tls->error_handle, &esp_tls_code, &flags); + + if (err == ESP_ERR_MBEDTLS_SSL_SETUP_FAILED) { + mp_raise_espidf_MemoryError(); + } else if (ESP_ERR_MBEDTLS_SSL_HANDSHAKE_FAILED) { + mp_raise_OSError_msg_varg(translate("Failed SSL handshake")); + } else { + mp_raise_OSError_msg_varg(translate("Unhandled ESP TLS error %d %d %x %d"), esp_tls_code, flags, err, sent); + } + } + return sent; +} diff --git a/ports/esp32s2/common-hal/ssl/SSLSocket.h b/ports/esp32s2/common-hal/ssl/SSLSocket.h new file mode 100644 index 000000000..e9e5bff06 --- /dev/null +++ b/ports/esp32s2/common-hal/ssl/SSLSocket.h @@ -0,0 +1,44 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2021 Lucian Copeland for Adafruit Industries + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#ifndef MICROPY_INCLUDED_ESP32S2_COMMON_HAL_SSL_SSLSOCKET_H +#define MICROPY_INCLUDED_ESP32S2_COMMON_HAL_SSL_SSLSOCKET_H + +#include "py/obj.h" + +#include "common-hal/ssl/SSLContext.h" +#include "common-hal/socketpool/Socket.h" + +#include "components/esp-tls/esp_tls.h" + +typedef struct { + mp_obj_base_t base; + socketpool_socket_obj_t * sock; + esp_tls_t* tls; + ssl_sslcontext_obj_t* ssl_context; +} ssl_sslsocket_obj_t; + +#endif // MICROPY_INCLUDED_ESP32S2_COMMON_HAL_SSL_SSLSOCKET_H diff --git a/ports/esp32s2/common-hal/wifi/Radio.c b/ports/esp32s2/common-hal/wifi/Radio.c index 930230088..574bab0a1 100644 --- a/ports/esp32s2/common-hal/wifi/Radio.c +++ b/ports/esp32s2/common-hal/wifi/Radio.c @@ -72,7 +72,7 @@ void common_hal_wifi_radio_set_enabled(wifi_radio_obj_t *self, bool enabled) { } if (!self->started && enabled) { // esp_wifi_start() would default to soft-AP, thus setting it to station - ESP_ERROR_CHECK(esp_wifi_set_mode(WIFI_MODE_STA)); + start_station(self); ESP_ERROR_CHECK(esp_wifi_start()); self->started = true; return; @@ -89,7 +89,9 @@ mp_obj_t common_hal_wifi_radio_start_scanning_networks(wifi_radio_obj_t *self) { if (self->current_scan != NULL) { mp_raise_RuntimeError(translate("Already scanning for wifi networks")); } - // check enabled + if (!common_hal_wifi_radio_get_enabled(self)) { + mp_raise_RuntimeError(translate("wifi is not enabled")); + } start_station(self); wifi_scannednetworks_obj_t *scan = m_new_obj(wifi_scannednetworks_obj_t); @@ -126,7 +128,25 @@ void common_hal_wifi_radio_set_hostname(wifi_radio_obj_t *self, const char *host } wifi_radio_error_t common_hal_wifi_radio_connect(wifi_radio_obj_t *self, uint8_t* ssid, size_t ssid_len, uint8_t* password, size_t password_len, uint8_t channel, mp_float_t timeout, uint8_t* bssid, size_t bssid_len) { - // check enabled + if (!common_hal_wifi_radio_get_enabled(self)) { + mp_raise_RuntimeError(translate("wifi is not enabled")); + } + + EventBits_t bits; + // can't block since both bits are false after wifi_init + // both bits are true after an existing connection stops + bits = xEventGroupWaitBits(self->event_group_handle, + WIFI_CONNECTED_BIT | WIFI_DISCONNECTED_BIT, + pdTRUE, + pdTRUE, + 0); + if (((bits & WIFI_CONNECTED_BIT) != 0) && + !((bits & WIFI_DISCONNECTED_BIT) != 0)) { + return WIFI_RADIO_ERROR_NONE; + } + // explicitly clear bits since xEventGroupWaitBits may have timed out + xEventGroupClearBits(self->event_group_handle, WIFI_CONNECTED_BIT); + xEventGroupClearBits(self->event_group_handle, WIFI_DISCONNECTED_BIT); start_station(self); wifi_config_t* config = &self->sta_config; @@ -157,7 +177,6 @@ wifi_radio_error_t common_hal_wifi_radio_connect(wifi_radio_obj_t *self, uint8_t self->retries_left = 5; esp_wifi_connect(); - EventBits_t bits; do { RUN_BACKGROUND_TASKS; bits = xEventGroupWaitBits(self->event_group_handle, diff --git a/ports/esp32s2/mpconfigport.h b/ports/esp32s2/mpconfigport.h index 9c0fd9da3..0cf695bc9 100644 --- a/ports/esp32s2/mpconfigport.h +++ b/ports/esp32s2/mpconfigport.h @@ -30,7 +30,6 @@ #define MICROPY_NLR_THUMB (0) -#define MICROPY_PY_UJSON (1) #define MICROPY_USE_INTERNAL_PRINTF (0) #define MICROPY_PY_SYS_PLATFORM "Espressif ESP32-S2" diff --git a/ports/esp32s2/mpconfigport.mk b/ports/esp32s2/mpconfigport.mk index 562c60998..b273c02ee 100644 --- a/ports/esp32s2/mpconfigport.mk +++ b/ports/esp32s2/mpconfigport.mk @@ -29,7 +29,10 @@ CIRCUITPY_I2CPERIPHERAL = 0 CIRCUITPY_ROTARYIO = 1 CIRCUITPY_NVM = 1 # We don't have enough endpoints to include MIDI. -CIRCUITPY_USB_MIDI = 0 +CIRCUITPY_USB_MIDI ?= 0 +CIRCUITPY_USB_HID ?= 1 +# We have borrowed the VENDOR nomenclature from tinyusb. VENDOR AKA WEBUSB +CIRCUITPY_USB_VENDOR ?= 0 CIRCUITPY_WIFI = 1 CIRCUITPY_WATCHDOG ?= 1 CIRCUITPY_ESPIDF = 1 diff --git a/ports/esp32s2/supervisor/port.c b/ports/esp32s2/supervisor/port.c index 21a8868b5..534f7f71b 100644 --- a/ports/esp32s2/supervisor/port.c +++ b/ports/esp32s2/supervisor/port.c @@ -46,6 +46,7 @@ #include "common-hal/pulseio/PulseIn.h" #include "common-hal/pwmio/PWMOut.h" #include "common-hal/watchdog/WatchDogTimer.h" +#include "common-hal/socketpool/Socket.h" #include "common-hal/wifi/__init__.h" #include "supervisor/memory.h" #include "supervisor/shared/tick.h" @@ -222,6 +223,10 @@ void reset_port(void) { #if CIRCUITPY_WIFI wifi_reset(); #endif + +#if CIRCUITPY_SOCKETPOOL + socket_reset(); +#endif } void reset_to_bootloader(void) { diff --git a/ports/litex/mpconfigport.h b/ports/litex/mpconfigport.h index a7caf8526..5f739e49e 100644 --- a/ports/litex/mpconfigport.h +++ b/ports/litex/mpconfigport.h @@ -31,8 +31,6 @@ #define CIRCUITPY_INTERNAL_NVM_SIZE (0) #define MICROPY_NLR_THUMB (0) #define MICROPY_PY_REVERSE_SPECIAL_METHODS (1) -#define MICROPY_PY_UBINASCII (1) -#define MICROPY_PY_UJSON (1) #include "py/circuitpy_mpconfig.h" diff --git a/ports/mimxrt10xx/common-hal/busio/I2C.c b/ports/mimxrt10xx/common-hal/busio/I2C.c index aaa2549a8..c8daddc4b 100644 --- a/ports/mimxrt10xx/common-hal/busio/I2C.c +++ b/ports/mimxrt10xx/common-hal/busio/I2C.c @@ -110,7 +110,7 @@ void common_hal_busio_i2c_construct(busio_i2c_obj_t *self, if( !GPIO_PinRead(sda->gpio, sda->number) || !GPIO_PinRead(scl->gpio, scl->number)) { common_hal_reset_pin(sda); common_hal_reset_pin(scl); - mp_raise_RuntimeError(translate("SDA or SCL needs a pull up")); + mp_raise_RuntimeError(translate("No pull up found on SDA or SCL; check your wiring")); } #endif diff --git a/ports/mimxrt10xx/mpconfigport.h b/ports/mimxrt10xx/mpconfigport.h index 7496256d0..51e0ef9ff 100644 --- a/ports/mimxrt10xx/mpconfigport.h +++ b/ports/mimxrt10xx/mpconfigport.h @@ -41,8 +41,6 @@ extern uint8_t _ld_default_stack_size; #define CIRCUITPY_DEFAULT_STACK_SIZE ((uint32_t) &_ld_default_stack_size) #define MICROPY_PY_BUILTINS_NOTIMPLEMENTED (0) #define MICROPY_PY_FUNCTION_ATTRS (0) -#define MICROPY_PY_IO (1) -#define MICROPY_PY_UJSON (1) #define MICROPY_PY_REVERSE_SPECIAL_METHODS (1) diff --git a/ports/nrf/boards/pca10100/mpconfigboard.mk b/ports/nrf/boards/pca10100/mpconfigboard.mk index 76d15e608..c8cba2877 100644 --- a/ports/nrf/boards/pca10100/mpconfigboard.mk +++ b/ports/nrf/boards/pca10100/mpconfigboard.mk @@ -25,6 +25,7 @@ CIRCUITPY_RTC = 1 CIRCUITPY_SDCARDIO = 0 CIRCUITPY_TOUCHIO = 0 CIRCUITPY_ULAB = 0 +CIRCUITPY_BUSDEVICE = 0 MICROPY_PY_ASYNC_AWAIT = 0 SUPEROPT_GC = 0 diff --git a/ports/nrf/boards/simmel/mpconfigboard.mk b/ports/nrf/boards/simmel/mpconfigboard.mk index 4eb6c98c7..6bc05a7f0 100644 --- a/ports/nrf/boards/simmel/mpconfigboard.mk +++ b/ports/nrf/boards/simmel/mpconfigboard.mk @@ -3,6 +3,8 @@ USB_PID = 0xc051 USB_PRODUCT = "Simmel" USB_MANUFACTURER = "Betrusted" +CIRCUITPY_DEVICES="CDC,MSC,HID" + MCU_CHIP = nrf52833 # SPI_FLASH_FILESYSTEM = 1 @@ -13,11 +15,13 @@ INTERNAL_FLASH_FILESYSTEM = 1 CIRCUITPY_AESIO = 1 CIRCUITPY_AUDIOMP3 = 0 +CIRCUITPY_BUSDEVICE = 0 CIRCUITPY_BUSIO = 1 CIRCUITPY_DISPLAYIO = 0 +CIRCUITPY_ERRNO = 0 CIRCUITPY_FRAMEBUFFERIO = 0 -CIRCUITPY_MSGPACK = 0 CIRCUITPY_GAMEPAD = 0 +CIRCUITPY_MSGPACK = 0 CIRCUITPY_NEOPIXEL_WRITE = 0 CIRCUITPY_NVM = 0 CIRCUITPY_PIXELBUF = 0 @@ -27,8 +31,8 @@ CIRCUITPY_RTC = 1 CIRCUITPY_SDCARDIO = 0 CIRCUITPY_TOUCHIO = 0 CIRCUITPY_ULAB = 0 +CIRCUITPY_USB_MIDI = 0 CIRCUITPY_WATCHDOG = 1 -CIRCUITPY_BUSDEVICE = 0 # Enable micropython.native #CIRCUITPY_ENABLE_MPY_NATIVE = 1 diff --git a/ports/nrf/common-hal/busio/I2C.c b/ports/nrf/common-hal/busio/I2C.c index 37cb192df..654fa857f 100644 --- a/ports/nrf/common-hal/busio/I2C.c +++ b/ports/nrf/common-hal/busio/I2C.c @@ -131,7 +131,7 @@ void common_hal_busio_i2c_construct(busio_i2c_obj_t *self, const mcu_pin_obj_t * if (!nrf_gpio_pin_read(sda->number) || !nrf_gpio_pin_read(scl->number)) { reset_pin_number(sda->number); reset_pin_number(scl->number); - mp_raise_RuntimeError(translate("SDA or SCL needs a pull up")); + mp_raise_RuntimeError(translate("No pull up found on SDA or SCL; check your wiring")); } #endif diff --git a/ports/nrf/common-hal/busio/UART.c b/ports/nrf/common-hal/busio/UART.c index 012ebc3b5..6ecf7e0ba 100644 --- a/ports/nrf/common-hal/busio/UART.c +++ b/ports/nrf/common-hal/busio/UART.c @@ -36,6 +36,7 @@ #include "supervisor/shared/translate.h" #include "nrfx_uarte.h" +#include "nrf_gpio.h" #include <string.h> // expression to examine, and return value in case of failing @@ -98,10 +99,16 @@ static void uart_callback_irq (const nrfx_uarte_event_t * event, void * context) switch ( event->type ) { case NRFX_UARTE_EVT_RX_DONE: - ringbuf_put_n(&self->ringbuf, event->data.rxtx.p_data, event->data.rxtx.bytes); + if (ringbuf_num_empty(&self->ringbuf) >= event->data.rxtx.bytes) { + ringbuf_put_n(&self->ringbuf, event->data.rxtx.p_data, event->data.rxtx.bytes); + // keep receiving + (void) nrfx_uarte_rx(self->uarte, &self->rx_char, 1); + } else { + // receive buffer full, suspend + self->rx_paused = true; + nrf_gpio_pin_write(self->rts_pin_number, true); + } - // keep receiving - (void) nrfx_uarte_rx(self->uarte, &self->rx_char, 1); break; case NRFX_UARTE_EVT_TX_DONE: @@ -137,8 +144,8 @@ void common_hal_busio_uart_construct(busio_uart_obj_t *self, mp_float_t timeout, uint16_t receiver_buffer_size, byte* receiver_buffer, bool sigint_enabled) { - if ((rts != NULL) || (cts != NULL) || (rs485_dir != NULL) || (rs485_invert)) { - mp_raise_ValueError(translate("RTS/CTS/RS485 Not yet supported on this device")); + if ((rs485_dir != NULL) || (rs485_invert)) { + mp_raise_ValueError(translate("RS485 Not yet supported on this device")); } // Find a free UART peripheral. @@ -166,16 +173,18 @@ void common_hal_busio_uart_construct(busio_uart_obj_t *self, mp_raise_ValueError(translate("Odd parity is not supported")); } + bool hwfc = rts != NULL || cts != NULL; + nrfx_uarte_config_t config = { .pseltxd = (tx == NULL) ? NRF_UARTE_PSEL_DISCONNECTED : tx->number, .pselrxd = (rx == NULL) ? NRF_UARTE_PSEL_DISCONNECTED : rx->number, - .pselcts = NRF_UARTE_PSEL_DISCONNECTED, - .pselrts = NRF_UARTE_PSEL_DISCONNECTED, + .pselcts = (cts == NULL) ? NRF_UARTE_PSEL_DISCONNECTED : cts->number, + .pselrts = (rts == NULL) ? NRF_UARTE_PSEL_DISCONNECTED : rts->number, .p_context = self, .baudrate = get_nrf_baud(baudrate), .interrupt_priority = 7, .hal_cfg = { - .hwfc = NRF_UARTE_HWFC_DISABLED, + .hwfc = hwfc ? NRF_UARTE_HWFC_ENABLED : NRF_UARTE_HWFC_DISABLED, .parity = (parity == BUSIO_UART_PARITY_NONE) ? NRF_UARTE_PARITY_EXCLUDED : NRF_UARTE_PARITY_INCLUDED } }; @@ -207,9 +216,25 @@ void common_hal_busio_uart_construct(busio_uart_obj_t *self, self->tx_pin_number = NO_PIN; } + if ( rts != NULL ) { + self->rts_pin_number = rts->number; + claim_pin(rts); + } else { + self->rts_pin_number = NO_PIN; + } + + if ( cts != NULL ) { + self->cts_pin_number = cts->number; + claim_pin(cts); + } else { + self->cts_pin_number = NO_PIN; + } + self->baudrate = baudrate; self->timeout_ms = timeout * 1000; + self->rx_paused = false; + // Initial wait for incoming byte _VERIFY_ERR(nrfx_uarte_rx(self->uarte, &self->rx_char, 1)); } @@ -223,8 +248,12 @@ void common_hal_busio_uart_deinit(busio_uart_obj_t *self) { nrfx_uarte_uninit(self->uarte); reset_pin_number(self->tx_pin_number); reset_pin_number(self->rx_pin_number); + reset_pin_number(self->rts_pin_number); + reset_pin_number(self->cts_pin_number); self->tx_pin_number = NO_PIN; self->rx_pin_number = NO_PIN; + self->rts_pin_number = NO_PIN; + self->cts_pin_number = NO_PIN; ringbuf_free(&self->ringbuf); } } @@ -237,6 +266,13 @@ size_t common_hal_busio_uart_read(busio_uart_obj_t *self, uint8_t *data, size_t uint64_t start_ticks = supervisor_ticks_ms64(); + // check removed to reduce code size + /* + if (len > ringbuf_capacity(&self->ringbuf)) { + mp_raise_ValueError(translate("Reading >receiver_buffer_size bytes is not supported")); + } + */ + // Wait for all bytes received or timeout while ( (ringbuf_num_filled(&self->ringbuf) < len) && (supervisor_ticks_ms64() - start_ticks < self->timeout_ms) ) { RUN_BACKGROUND_TASKS; @@ -252,6 +288,16 @@ size_t common_hal_busio_uart_read(busio_uart_obj_t *self, uint8_t *data, size_t // Copy as much received data as available, up to len bytes. size_t rx_bytes = ringbuf_get_n(&self->ringbuf, data, len); + // restart reader, if stopped + if (self->rx_paused) { + // the character that did not fit in ringbuf is in rx_char + ringbuf_put_n(&self->ringbuf, &self->rx_char, 1); + // keep receiving + (void) nrfx_uarte_rx(self->uarte, &self->rx_char, 1); + nrf_gpio_pin_write(self->rts_pin_number, false); + self->rx_paused = false; + } + NVIC_EnableIRQ(nrfx_get_irq_number(self->uarte->p_reg)); return rx_bytes; diff --git a/ports/nrf/common-hal/busio/UART.h b/ports/nrf/common-hal/busio/UART.h index a25116291..2eaf58440 100644 --- a/ports/nrf/common-hal/busio/UART.h +++ b/ports/nrf/common-hal/busio/UART.h @@ -42,10 +42,13 @@ typedef struct { uint32_t timeout_ms; ringbuf_t ringbuf; - uint8_t rx_char; // EasyDMA buf + uint8_t rx_char; // EasyDMA buf + bool rx_paused; // set by irq if no space in rbuf uint8_t tx_pin_number; uint8_t rx_pin_number; + uint8_t cts_pin_number; + uint8_t rts_pin_number; } busio_uart_obj_t; void uart_reset(void); diff --git a/ports/nrf/mpconfigport.h b/ports/nrf/mpconfigport.h index 4ed42cd82..3ac41a5e4 100644 --- a/ports/nrf/mpconfigport.h +++ b/ports/nrf/mpconfigport.h @@ -35,11 +35,8 @@ #include "peripherals/nrf/nvm.h" // for FLASH_PAGE_SIZE #define MICROPY_PY_FUNCTION_ATTRS (1) -#define MICROPY_PY_IO (1) #define MICROPY_PY_REVERSE_SPECIAL_METHODS (1) #define MICROPY_PY_SYS_STDIO_BUFFER (1) -#define MICROPY_PY_UBINASCII (1) -#define MICROPY_PY_UJSON (1) // 24kiB stack #define CIRCUITPY_DEFAULT_STACK_SIZE (24*1024) diff --git a/ports/raspberrypi/Makefile b/ports/raspberrypi/Makefile index a604acb47..e1169ce7d 100644 --- a/ports/raspberrypi/Makefile +++ b/ports/raspberrypi/Makefile @@ -84,6 +84,7 @@ INC += -I. \ -isystem sdk/src/rp2_common/hardware_pio/include/ \ -isystem sdk/src/rp2_common/hardware_pll/include/ \ -isystem sdk/src/rp2_common/hardware_resets/include/ \ + -isystem sdk/src/rp2_common/hardware_rtc/include/ \ -isystem sdk/src/rp2_common/hardware_spi/include/ \ -isystem sdk/src/rp2_common/hardware_sync/include/ \ -isystem sdk/src/rp2_common/hardware_timer/include/ \ @@ -98,6 +99,7 @@ INC += -I. \ -isystem sdk/src/rp2_common/pico_platform/include/ \ -isystem sdk/src/rp2_common/pico_runtime/printf/include/ \ -isystem sdk/src/rp2_common/pico_bootrom/include/ \ + -isystem sdk/src/rp2_common/pico_unique_id/include/ \ -Isdk_config \ -I../../lib/tinyusb/src \ -I../../supervisor/shared/usb \ @@ -166,6 +168,7 @@ SRC_SDK := \ src/rp2_common/hardware_irq/irq.c \ src/rp2_common/hardware_pio/pio.c \ src/rp2_common/hardware_pll/pll.c \ + src/rp2_common/hardware_rtc/rtc.c \ src/rp2_common/hardware_spi/spi.c \ src/rp2_common/hardware_sync/sync.c \ src/rp2_common/hardware_timer/timer.c \ @@ -182,6 +185,7 @@ SRC_SDK := \ src/rp2_common/pico_printf/printf.c \ src/rp2_common/pico_runtime/runtime.c \ src/rp2_common/pico_stdio/stdio.c \ + src/rp2_common/pico_unique_id/unique_id.c \ SRC_SDK := $(addprefix sdk/, $(SRC_SDK)) diff --git a/ports/raspberrypi/background.c b/ports/raspberrypi/background.c index c85b83b41..52f2e4fb4 100644 --- a/ports/raspberrypi/background.c +++ b/ports/raspberrypi/background.c @@ -25,20 +25,11 @@ */ #include "background.h" -#include "supervisor/filesystem.h" -#include "supervisor/shared/tick.h" -#include "supervisor/usb.h" - #include "py/runtime.h" -#include "shared-module/network/__init__.h" -#include "supervisor/shared/stack.h" #include "supervisor/port.h" -#if CIRCUITPY_DISPLAYIO -#include "shared-module/displayio/__init__.h" -#endif - void port_start_background_task(void) {} void port_finish_background_task(void) {} -void port_background_task(void) {} +void port_background_task(void) { +} diff --git a/ports/raspberrypi/boards/raspberry_pi_pico/mpconfigboard.mk b/ports/raspberrypi/boards/raspberry_pi_pico/mpconfigboard.mk index 69ff56fef..54c130660 100644 --- a/ports/raspberrypi/boards/raspberry_pi_pico/mpconfigboard.mk +++ b/ports/raspberrypi/boards/raspberry_pi_pico/mpconfigboard.mk @@ -7,3 +7,5 @@ CHIP_VARIANT = RP2040 CHIP_FAMILY = rp2 INTERNAL_FLASH_FILESYSTEM = 1 + +CIRCUITPY__EVE = 1 diff --git a/ports/raspberrypi/boards/raspberry_pi_pico/pins.c b/ports/raspberrypi/boards/raspberry_pi_pico/pins.c index 38ec75c4a..e1927bc80 100644 --- a/ports/raspberrypi/boards/raspberry_pi_pico/pins.c +++ b/ports/raspberrypi/boards/raspberry_pi_pico/pins.c @@ -16,6 +16,7 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = { { MP_ROM_QSTR(MP_QSTR_GP12), MP_ROM_PTR(&pin_GPIO12) }, { MP_ROM_QSTR(MP_QSTR_GP13), MP_ROM_PTR(&pin_GPIO13) }, { MP_ROM_QSTR(MP_QSTR_GP14), MP_ROM_PTR(&pin_GPIO14) }, + { MP_ROM_QSTR(MP_QSTR_GP15), MP_ROM_PTR(&pin_GPIO15) }, { MP_ROM_QSTR(MP_QSTR_GP16), MP_ROM_PTR(&pin_GPIO16) }, { MP_ROM_QSTR(MP_QSTR_GP17), MP_ROM_PTR(&pin_GPIO17) }, { MP_ROM_QSTR(MP_QSTR_GP18), MP_ROM_PTR(&pin_GPIO18) }, @@ -23,6 +24,7 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = { { MP_ROM_QSTR(MP_QSTR_GP20), MP_ROM_PTR(&pin_GPIO20) }, { MP_ROM_QSTR(MP_QSTR_GP21), MP_ROM_PTR(&pin_GPIO21) }, { MP_ROM_QSTR(MP_QSTR_GP22), MP_ROM_PTR(&pin_GPIO22) }, + { MP_ROM_QSTR(MP_QSTR_SMPS_MODE), MP_ROM_PTR(&pin_GPIO23) }, { MP_ROM_QSTR(MP_QSTR_LED), MP_ROM_PTR(&pin_GPIO25) }, { MP_ROM_QSTR(MP_QSTR_GP25), MP_ROM_PTR(&pin_GPIO25) }, { MP_ROM_QSTR(MP_QSTR_GP26_A0), MP_ROM_PTR(&pin_GPIO26) }, @@ -34,5 +36,7 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = { { MP_ROM_QSTR(MP_QSTR_GP28_A2), MP_ROM_PTR(&pin_GPIO28) }, { MP_ROM_QSTR(MP_QSTR_GP28), MP_ROM_PTR(&pin_GPIO28) }, { MP_ROM_QSTR(MP_QSTR_A2), MP_ROM_PTR(&pin_GPIO28) }, + { MP_ROM_QSTR(MP_QSTR_A3), MP_ROM_PTR(&pin_GPIO29) }, + { MP_ROM_QSTR(MP_QSTR_VOLTAGE_MONITOR), MP_ROM_PTR(&pin_GPIO29) }, }; MP_DEFINE_CONST_DICT(board_module_globals, board_global_dict_table); diff --git a/ports/raspberrypi/bs2_default_padded_checksummed.S b/ports/raspberrypi/bs2_default_padded_checksummed.S index d77f4867c..6b7074e3b 100644 --- a/ports/raspberrypi/bs2_default_padded_checksummed.S +++ b/ports/raspberrypi/bs2_default_padded_checksummed.S @@ -1,20 +1,23 @@ -// Padded and checksummed version of: /Users/graham/dev/mu/pico_sdk/cmake-build-debug-mu/src/rp2_common/boot_stage2/bs2_default.bin +// Padded and checksummed version of: /home/pi/pico/pico-examples/build/pico-sdk/src/rp2_common/boot_stage2/bs2_default.bin -.section .boot2, "a" +.cpu cortex-m0plus +.thumb -.byte 0x00, 0xb5, 0x2f, 0x4b, 0x21, 0x20, 0x58, 0x60, 0x98, 0x68, 0x02, 0x21, 0x88, 0x43, 0x98, 0x60 -.byte 0xd8, 0x60, 0x18, 0x61, 0x58, 0x61, 0x2b, 0x4b, 0x00, 0x21, 0x99, 0x60, 0x02, 0x21, 0x59, 0x61 -.byte 0x01, 0x21, 0xf0, 0x22, 0x99, 0x50, 0x28, 0x49, 0x19, 0x60, 0x01, 0x21, 0x99, 0x60, 0x35, 0x20 -.byte 0x00, 0xf0, 0x3e, 0xf8, 0x02, 0x22, 0x90, 0x42, 0x14, 0xd0, 0x06, 0x21, 0x19, 0x66, 0x00, 0xf0 -.byte 0x2e, 0xf8, 0x19, 0x6e, 0x01, 0x21, 0x19, 0x66, 0x00, 0x20, 0x18, 0x66, 0x1a, 0x66, 0x00, 0xf0 -.byte 0x26, 0xf8, 0x19, 0x6e, 0x19, 0x6e, 0x19, 0x6e, 0x05, 0x20, 0x00, 0xf0, 0x29, 0xf8, 0x01, 0x21 -.byte 0x08, 0x42, 0xf9, 0xd1, 0x00, 0x21, 0x99, 0x60, 0x18, 0x49, 0x19, 0x60, 0x00, 0x21, 0x59, 0x60 -.byte 0x17, 0x49, 0x18, 0x48, 0x01, 0x60, 0x01, 0x21, 0x99, 0x60, 0xeb, 0x21, 0x19, 0x66, 0xa0, 0x21 -.byte 0x19, 0x66, 0x00, 0xf0, 0x0c, 0xf8, 0x00, 0x21, 0x99, 0x60, 0x13, 0x49, 0x11, 0x48, 0x01, 0x60 -.byte 0x01, 0x21, 0x99, 0x60, 0x01, 0xbc, 0x00, 0x28, 0x00, 0xd1, 0x10, 0x48, 0x00, 0x47, 0x03, 0xb5 -.byte 0x99, 0x6a, 0x04, 0x20, 0x01, 0x42, 0xfb, 0xd0, 0x01, 0x20, 0x01, 0x42, 0xf8, 0xd1, 0x03, 0xbd -.byte 0x02, 0xb5, 0x18, 0x66, 0x18, 0x66, 0xff, 0xf7, 0xf2, 0xff, 0x18, 0x6e, 0x18, 0x6e, 0x02, 0xbd -.byte 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x07, 0x00, 0x00, 0x03, 0x5f, 0x00 -.byte 0x21, 0x22, 0x00, 0x00, 0xf4, 0x00, 0x00, 0x18, 0x22, 0x20, 0x00, 0xa0, 0x01, 0x01, 0x00, 0x10 -.byte 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 -.byte 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x27, 0x2a, 0x60 +.section .boot2, "ax" + +.byte 0x00, 0xb5, 0x32, 0x4b, 0x21, 0x20, 0x58, 0x60, 0x98, 0x68, 0x02, 0x21, 0x88, 0x43, 0x98, 0x60 +.byte 0xd8, 0x60, 0x18, 0x61, 0x58, 0x61, 0x2e, 0x4b, 0x00, 0x21, 0x99, 0x60, 0x02, 0x21, 0x59, 0x61 +.byte 0x01, 0x21, 0xf0, 0x22, 0x99, 0x50, 0x2b, 0x49, 0x19, 0x60, 0x01, 0x21, 0x99, 0x60, 0x35, 0x20 +.byte 0x00, 0xf0, 0x44, 0xf8, 0x02, 0x22, 0x90, 0x42, 0x14, 0xd0, 0x06, 0x21, 0x19, 0x66, 0x00, 0xf0 +.byte 0x34, 0xf8, 0x19, 0x6e, 0x01, 0x21, 0x19, 0x66, 0x00, 0x20, 0x18, 0x66, 0x1a, 0x66, 0x00, 0xf0 +.byte 0x2c, 0xf8, 0x19, 0x6e, 0x19, 0x6e, 0x19, 0x6e, 0x05, 0x20, 0x00, 0xf0, 0x2f, 0xf8, 0x01, 0x21 +.byte 0x08, 0x42, 0xf9, 0xd1, 0x00, 0x21, 0x99, 0x60, 0x1b, 0x49, 0x19, 0x60, 0x00, 0x21, 0x59, 0x60 +.byte 0x1a, 0x49, 0x1b, 0x48, 0x01, 0x60, 0x01, 0x21, 0x99, 0x60, 0xeb, 0x21, 0x19, 0x66, 0xa0, 0x21 +.byte 0x19, 0x66, 0x00, 0xf0, 0x12, 0xf8, 0x00, 0x21, 0x99, 0x60, 0x16, 0x49, 0x14, 0x48, 0x01, 0x60 +.byte 0x01, 0x21, 0x99, 0x60, 0x01, 0xbc, 0x00, 0x28, 0x00, 0xd0, 0x00, 0x47, 0x12, 0x48, 0x13, 0x49 +.byte 0x08, 0x60, 0x03, 0xc8, 0x80, 0xf3, 0x08, 0x88, 0x08, 0x47, 0x03, 0xb5, 0x99, 0x6a, 0x04, 0x20 +.byte 0x01, 0x42, 0xfb, 0xd0, 0x01, 0x20, 0x01, 0x42, 0xf8, 0xd1, 0x03, 0xbd, 0x02, 0xb5, 0x18, 0x66 +.byte 0x18, 0x66, 0xff, 0xf7, 0xf2, 0xff, 0x18, 0x6e, 0x18, 0x6e, 0x02, 0xbd, 0x00, 0x00, 0x02, 0x40 +.byte 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x07, 0x00, 0x00, 0x03, 0x5f, 0x00, 0x21, 0x22, 0x00, 0x00 +.byte 0xf4, 0x00, 0x00, 0x18, 0x22, 0x20, 0x00, 0xa0, 0x00, 0x01, 0x00, 0x10, 0x08, 0xed, 0x00, 0xe0 +.byte 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x74, 0xb2, 0x4e, 0x7a diff --git a/ports/raspberrypi/common-hal/busio/I2C.c b/ports/raspberrypi/common-hal/busio/I2C.c index fa49e375e..26a7f3807 100644 --- a/ports/raspberrypi/common-hal/busio/I2C.c +++ b/ports/raspberrypi/common-hal/busio/I2C.c @@ -90,7 +90,7 @@ void common_hal_busio_i2c_construct(busio_i2c_obj_t *self, if (!gpio_get(sda->number) || !gpio_get(scl->number)) { reset_pin_number(sda->number); reset_pin_number(scl->number); - mp_raise_RuntimeError(translate("SDA or SCL needs a pull up")); + mp_raise_RuntimeError(translate("No pull up found on SDA or SCL; check your wiring")); } #endif diff --git a/ports/raspberrypi/common-hal/busio/UART.c b/ports/raspberrypi/common-hal/busio/UART.c index 71da6cadd..f9a75b499 100644 --- a/ports/raspberrypi/common-hal/busio/UART.c +++ b/ports/raspberrypi/common-hal/busio/UART.c @@ -54,6 +54,7 @@ void common_hal_busio_uart_construct(busio_uart_obj_t *self, uint32_t baudrate, uint8_t bits, busio_uart_parity_t parity, uint8_t stop, mp_float_t timeout, uint16_t receiver_buffer_size, byte* receiver_buffer, bool sigint_enabled) { + mp_raise_NotImplementedError(translate("UART not yet supported")); // Sercom* sercom = NULL; // uint8_t sercom_index = 255; // Unset index diff --git a/ports/raspberrypi/common-hal/digitalio/DigitalInOut.c b/ports/raspberrypi/common-hal/digitalio/DigitalInOut.c index 06f0cfdd2..b0bc1b96e 100644 --- a/ports/raspberrypi/common-hal/digitalio/DigitalInOut.c +++ b/ports/raspberrypi/common-hal/digitalio/DigitalInOut.c @@ -76,8 +76,7 @@ digitalinout_result_t common_hal_digitalio_digitalinout_switch_to_output( digitalio_drive_mode_t drive_mode) { const uint8_t pin = self->pin->number; gpio_set_dir(pin, GPIO_OUT); - // Turn on "strong" pin driving (more current available). See DRVSTR doc in datasheet. - // hri_port_set_PINCFG_DRVSTR_bit(PORT, (enum gpio_port)GPIO_PORT(pin), GPIO_PIN(pin)); + // TODO: Turn on "strong" pin driving (more current available). self->output = true; common_hal_digitalio_digitalinout_set_drive_mode(self, drive_mode); @@ -140,18 +139,16 @@ void common_hal_digitalio_digitalinout_set_pull( digitalio_pull_t common_hal_digitalio_digitalinout_get_pull( digitalio_digitalinout_obj_t* self) { - // uint32_t pin = self->pin->number; - // if (self->output) { - // mp_raise_AttributeError(translate("Cannot get pull while in output mode")); - // return PULL_NONE; - // } else { - // if (hri_port_get_PINCFG_PULLEN_bit(PORT, GPIO_PORT(pin), GPIO_PIN(pin)) == 0) { - // return PULL_NONE; - // } if (hri_port_get_OUT_reg(PORT, GPIO_PORT(pin), 1U << GPIO_PIN(pin)) > 0) { - // return PULL_UP; - // } else { - // return PULL_DOWN; - // } - // } + uint32_t pin = self->pin->number; + if (self->output) { + mp_raise_AttributeError(translate("Cannot get pull while in output mode")); + return PULL_NONE; + } else { + if (gpio_is_pulled_up(pin)) { + return PULL_UP; + } else if (gpio_is_pulled_down(pin)) { + return PULL_DOWN; + } + } return PULL_NONE; } diff --git a/ports/raspberrypi/common-hal/microcontroller/Pin.c b/ports/raspberrypi/common-hal/microcontroller/Pin.c index 90c327406..ca5cf5a04 100644 --- a/ports/raspberrypi/common-hal/microcontroller/Pin.c +++ b/ports/raspberrypi/common-hal/microcontroller/Pin.c @@ -26,6 +26,7 @@ #include "py/runtime.h" +#include "common-hal/microcontroller/__init__.h" #include "shared-bindings/microcontroller/Pin.h" #include "supervisor/shared/rgb_led_status.h" @@ -46,7 +47,7 @@ bool speaker_enable_in_use; STATIC uint32_t never_reset_pins; void reset_all_pins(void) { - for (size_t i = 0; i < 30; i++) { + for (size_t i = 0; i < TOTAL_GPIO_COUNT; i++) { if ((never_reset_pins & (1 << i)) != 0) { continue; } @@ -55,7 +56,7 @@ void reset_all_pins(void) { } void never_reset_pin_number(uint8_t pin_number) { - if (pin_number >= 32) { + if (pin_number >= TOTAL_GPIO_COUNT) { return; } @@ -63,12 +64,7 @@ void never_reset_pin_number(uint8_t pin_number) { } void reset_pin_number(uint8_t pin_number) { - if (pin_number >= 32 -#if TUD_OPT_RP2040_USB_DEVICE_ENUMERATION_FIX - // Pin 15 is used for Errata so we don't mess with it. - || pin_number == 15 -#endif - ) { + if (pin_number >= TOTAL_GPIO_COUNT) { return; } @@ -139,15 +135,10 @@ void claim_pin(const mcu_pin_obj_t* pin) { } bool pin_number_is_free(uint8_t pin_number) { - if (pin_number >= 30) { + if (pin_number >= TOTAL_GPIO_COUNT) { return false; } -#if TUD_OPT_RP2040_USB_DEVICE_ENUMERATION_FIX - // Pin 15 is used for Errata so we don't mess with it. - if (pin_number == 15) { - return true; - } -#endif + uint32_t pad_state = padsbank0_hw->io[pin_number]; return (pad_state & PADS_BANK0_GPIO0_IE_BITS) == 0 && (pad_state & PADS_BANK0_GPIO0_OD_BITS) != 0; diff --git a/ports/raspberrypi/common-hal/microcontroller/Processor.c b/ports/raspberrypi/common-hal/microcontroller/Processor.c index 0ad3a51e2..e22286ca3 100644 --- a/ports/raspberrypi/common-hal/microcontroller/Processor.c +++ b/ports/raspberrypi/common-hal/microcontroller/Processor.c @@ -25,6 +25,7 @@ */ #include <math.h> +#include <string.h> #include "py/mphal.h" #include "common-hal/microcontroller/Processor.h" @@ -53,12 +54,9 @@ uint32_t common_hal_mcu_processor_get_frequency(void) { } void common_hal_mcu_processor_get_uid(uint8_t raw_id[]) { - // TODO: get the unique id from the flash. The chip itself doesn't have one. - // for (int i=0; i<4; i++) { - // for (int k=0; k<4; k++) { - // raw_id[4 * i + k] = (*(id_addresses[i]) >> k * 8) & 0xff; - // } - // } + pico_unique_board_id_t retrieved_id; + pico_get_unique_board_id(&retrieved_id); + memcpy(raw_id, retrieved_id.id, COMMON_HAL_MCU_PROCESSOR_UID_LENGTH); } mcu_reset_reason_t common_hal_mcu_processor_get_reset_reason(void) { diff --git a/ports/raspberrypi/common-hal/microcontroller/Processor.h b/ports/raspberrypi/common-hal/microcontroller/Processor.h index b7c86e850..afb43f9bd 100644 --- a/ports/raspberrypi/common-hal/microcontroller/Processor.h +++ b/ports/raspberrypi/common-hal/microcontroller/Processor.h @@ -27,7 +27,9 @@ #ifndef MICROPY_INCLUDED_RASPBERRYPI_COMMON_HAL_MICROCONTROLLER_PROCESSOR_H #define MICROPY_INCLUDED_RASPBERRYPI_COMMON_HAL_MICROCONTROLLER_PROCESSOR_H -#define COMMON_HAL_MCU_PROCESSOR_UID_LENGTH 16 +#include "src/rp2_common/pico_unique_id/include/pico/unique_id.h" + +#define COMMON_HAL_MCU_PROCESSOR_UID_LENGTH PICO_UNIQUE_BOARD_ID_SIZE_BYTES #include "py/obj.h" diff --git a/ports/raspberrypi/common-hal/microcontroller/__init__.c b/ports/raspberrypi/common-hal/microcontroller/__init__.c index e454ffa1b..bfea8b2d9 100644 --- a/ports/raspberrypi/common-hal/microcontroller/__init__.c +++ b/ports/raspberrypi/common-hal/microcontroller/__init__.c @@ -35,12 +35,16 @@ #include "shared-bindings/microcontroller/__init__.h" #include "shared-bindings/microcontroller/Pin.h" #include "shared-bindings/microcontroller/Processor.h" +#include "supervisor/filesystem.h" +#include "supervisor/port.h" #include "supervisor/shared/safe_mode.h" #include "supervisor/shared/translate.h" #include "src/rp2040/hardware_structs/include/hardware/structs/sio.h" #include "src/rp2_common/hardware_sync/include/hardware/sync.h" +#include "hardware/watchdog.h" + void common_hal_mcu_delay_us(uint32_t delay) { mp_hal_delay_us(delay); } @@ -66,8 +70,11 @@ void common_hal_mcu_enable_interrupts(void) { asm volatile ("cpsie i" : : : "memory"); } +static bool next_reset_to_bootloader = false; + void common_hal_mcu_on_next_reset(mcu_runmode_t runmode) { if (runmode == RUNMODE_BOOTLOADER) { + next_reset_to_bootloader = true; } else { } if (runmode == RUNMODE_SAFE_MODE) { @@ -76,10 +83,17 @@ void common_hal_mcu_on_next_reset(mcu_runmode_t runmode) { } void common_hal_mcu_reset(void) { + filesystem_flush(); + if (next_reset_to_bootloader) { + reset_to_bootloader(); + } else { + reset_cpu(); + } } // The singleton microcontroller.Processor object, bound to microcontroller.cpu // It currently only has properties, and no state. +#if CIRCUITPY_PROCESSOR_COUNT > 1 static const mcu_processor_obj_t processor0 = { .base = { .type = &mcu_processor_type, @@ -92,7 +106,7 @@ static const mcu_processor_obj_t processor1 = { }, }; -const mp_rom_obj_tuple_t common_hal_mcu_processor_obj = { +const mp_rom_obj_tuple_t common_hal_multi_processor_obj = { {&mp_type_tuple}, CIRCUITPY_PROCESSOR_COUNT, { @@ -100,6 +114,13 @@ const mp_rom_obj_tuple_t common_hal_mcu_processor_obj = { MP_ROM_PTR(&processor1) } }; +#endif + +const mcu_processor_obj_t common_hal_mcu_processor_obj = { + .base = { + .type = &mcu_processor_type, + }, +}; #if CIRCUITPY_NVM && CIRCUITPY_INTERNAL_NVM_SIZE > 0 // The singleton nvm.ByteArray object. @@ -112,6 +133,17 @@ const nvm_bytearray_obj_t common_hal_mcu_nvm_obj = { }; #endif +#if CIRCUITPY_WATCHDOG +// The singleton watchdog.WatchDogTimer object. +watchdog_watchdogtimer_obj_t common_hal_mcu_watchdogtimer_obj = { + .base = { + .type = &watchdog_watchdogtimer_type, + }, + .timeout = 0.0f, + .mode = WATCHDOGMODE_NONE, +}; +#endif + // This maps MCU pin names to pin objects. const mp_rom_map_elem_t mcu_pin_global_dict_table[TOTAL_GPIO_COUNT] = { { MP_ROM_QSTR(MP_QSTR_GPIO0), MP_ROM_PTR(&pin_GPIO0) }, diff --git a/ports/raspberrypi/common-hal/rtc/RTC.c b/ports/raspberrypi/common-hal/rtc/RTC.c new file mode 100644 index 000000000..89c23fc19 --- /dev/null +++ b/ports/raspberrypi/common-hal/rtc/RTC.c @@ -0,0 +1,81 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright 2020 microDev + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ +#include "shared-bindings/rtc/RTC.h" + +#include <sys/time.h> + +#include "py/runtime.h" +#include "src/rp2_common/hardware_rtc/include/hardware/rtc.h" + +void common_hal_rtc_init(void) { + rtc_init(); +} + +void common_hal_rtc_get_time(timeutils_struct_time_t *tm) { + datetime_t t; + rtc_get_datetime(&t); + + tm->tm_year = t.year; + tm->tm_mon = t.month; + tm->tm_mday = t.day; + tm->tm_wday = t.dotw; + tm->tm_hour = t.hour; + tm->tm_min = t.min; + tm->tm_sec = t.sec; + + if (tm->tm_wday == 0) { + tm->tm_wday = 6; + } else { + tm->tm_wday-=1; + } +} + +void common_hal_rtc_set_time(timeutils_struct_time_t *tm) { + if (tm->tm_wday == 6) { + tm->tm_wday = 0; + } else { + tm->tm_wday+=1; + } + + datetime_t t = { + .year = tm->tm_year, + .month = tm->tm_mon, + .day = tm->tm_mday, + .dotw = tm->tm_wday, + .hour = tm->tm_hour, + .min = tm->tm_min, + .sec = tm->tm_sec + }; + rtc_set_datetime(&t); +} + +int common_hal_rtc_get_calibration(void) { + return 0; +} + +void common_hal_rtc_set_calibration(int calibration) { + mp_raise_NotImplementedError(translate("RTC calibration is not supported on this board")); +} diff --git a/ports/raspberrypi/common-hal/rtc/RTC.h b/ports/raspberrypi/common-hal/rtc/RTC.h new file mode 100644 index 000000000..426a4ec7a --- /dev/null +++ b/ports/raspberrypi/common-hal/rtc/RTC.h @@ -0,0 +1,32 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2020 microDev + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#ifndef MICROPY_INCLUDED_RASPBERRYPI_COMMON_HAL_RTC_RTC_H +#define MICROPY_INCLUDED_RASPBERRYPI_COMMON_HAL_RTC_RTC_H + +extern void common_hal_rtc_init(void); + +#endif // MICROPY_INCLUDED_RASPBERRYPI_COMMON_HAL_RTC_RTC_H diff --git a/ports/raspberrypi/common-hal/rtc/__init__.c b/ports/raspberrypi/common-hal/rtc/__init__.c new file mode 100644 index 000000000..f5e6b6bdd --- /dev/null +++ b/ports/raspberrypi/common-hal/rtc/__init__.c @@ -0,0 +1 @@ +// No RTC module functions diff --git a/ports/raspberrypi/common-hal/watchdog/WatchDogMode.c b/ports/raspberrypi/common-hal/watchdog/WatchDogMode.c new file mode 100644 index 000000000..fc4e0e008 --- /dev/null +++ b/ports/raspberrypi/common-hal/watchdog/WatchDogMode.c @@ -0,0 +1 @@ +// No watchdog module functions. diff --git a/ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c b/ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c new file mode 100644 index 000000000..f23ccda77 --- /dev/null +++ b/ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c @@ -0,0 +1,83 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2020 microDev + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#include "py/runtime.h" +#include "common-hal/watchdog/WatchDogTimer.h" + +#include "shared-bindings/watchdog/__init__.h" +#include "shared-bindings/microcontroller/__init__.h" + +#include "src/rp2_common/hardware_watchdog/include/hardware/watchdog.h" + +void common_hal_watchdog_feed(watchdog_watchdogtimer_obj_t *self) { + watchdog_update(); +} + +void common_hal_watchdog_deinit(watchdog_watchdogtimer_obj_t *self) { + if (self->mode == WATCHDOGMODE_RESET) { + mp_raise_RuntimeError(translate("WatchDogTimer cannot be deinitialized once mode is set to RESET")); + } else { + self->mode = WATCHDOGMODE_NONE; + } +} + +/* +void watchdog_reset(void) { + common_hal_watchdog_deinit(&common_hal_mcu_watchdogtimer_obj); +} +*/ + +mp_float_t common_hal_watchdog_get_timeout(watchdog_watchdogtimer_obj_t *self) { + return self->timeout; +} + +void common_hal_watchdog_set_timeout(watchdog_watchdogtimer_obj_t *self, mp_float_t new_timeout) { + // max timeout is 8.388607 sec + // this is rounded down to 8.388 sec + uint64_t timeout = new_timeout * 1000; + if (timeout > 8388) { + mp_raise_ValueError(translate("timeout duration exceeded the maximum supported value")); + } + if ((uint16_t)self->timeout != timeout) { + watchdog_enable(timeout, false); + self->timeout = new_timeout; + } +} + +watchdog_watchdogmode_t common_hal_watchdog_get_mode(watchdog_watchdogtimer_obj_t *self) { + return self->mode; +} + +void common_hal_watchdog_set_mode(watchdog_watchdogtimer_obj_t *self, watchdog_watchdogmode_t new_mode) { + if (self->mode != new_mode) { + if (new_mode == WATCHDOGMODE_RAISE) { + mp_raise_NotImplementedError(translate("RAISE mode is not implemented")); + } else if (new_mode == WATCHDOGMODE_NONE) { + common_hal_watchdog_deinit(self); + } + self->mode = new_mode; + } +} diff --git a/ports/raspberrypi/common-hal/watchdog/WatchDogTimer.h b/ports/raspberrypi/common-hal/watchdog/WatchDogTimer.h new file mode 100644 index 000000000..ec1e2f659 --- /dev/null +++ b/ports/raspberrypi/common-hal/watchdog/WatchDogTimer.h @@ -0,0 +1,43 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2020 microDev + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#ifndef MICROPY_INCLUDED_RASPBERRYPI_COMMON_HAL_WATCHDOG_WATCHDOGTIMER_H +#define MICROPY_INCLUDED_RASPBERRYPI_COMMON_HAL_WATCHDOG_WATCHDOGTIMER_H + +#include "py/obj.h" +#include "shared-bindings/watchdog/WatchDogMode.h" +#include "shared-bindings/watchdog/WatchDogTimer.h" + +struct _watchdog_watchdogtimer_obj_t { + mp_obj_base_t base; + mp_float_t timeout; + watchdog_watchdogmode_t mode; +}; + +// This needs to be called in order to disable the watchdog +// void watchdog_reset(void); + +#endif // MICROPY_INCLUDED_RASPBERRYPI_COMMON_HAL_WATCHDOG_WATCHDOGTIMER_H diff --git a/ports/raspberrypi/common-hal/watchdog/__init__.c b/ports/raspberrypi/common-hal/watchdog/__init__.c new file mode 100644 index 000000000..fc4e0e008 --- /dev/null +++ b/ports/raspberrypi/common-hal/watchdog/__init__.c @@ -0,0 +1 @@ +// No watchdog module functions. diff --git a/ports/raspberrypi/link.ld b/ports/raspberrypi/link.ld index d642fd680..b83299dee 100644 --- a/ports/raspberrypi/link.ld +++ b/ports/raspberrypi/link.ld @@ -59,12 +59,11 @@ SECTIONS */ .text : { - __reset_start = .; - KEEP (*(.reset)) - . = ALIGN(256); - __reset_end = .; - ASSERT(__reset_end - __reset_start == 256, "ERROR: reset section should only be 256 bytes"); + __logical_binary_start = .; KEEP (*(.vectors)) + KEEP (*(.binary_info_header)) + __binary_info_header_end = .; + KEEP (*(.reset)) /* TODO revisit this now memset/memcpy/float in ROM */ /* bit of a hack right now to exclude all floating point and time critical (e.g. memset, memcpy) code from * FLASH ... we will include any thing excluded here in .data below by default */ @@ -246,5 +245,7 @@ SECTIONS /* Check if data + heap + stack exceeds RAM limit */ ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed") + + ASSERT( __binary_info_header_end - __logical_binary_start <= 256, "Binary info must be in first 256 bytes of the binary") /* todo assert on extra code */ } diff --git a/ports/raspberrypi/mpconfigport.h b/ports/raspberrypi/mpconfigport.h index 3fdc8febb..77d1ff080 100644 --- a/ports/raspberrypi/mpconfigport.h +++ b/ports/raspberrypi/mpconfigport.h @@ -27,7 +27,7 @@ #ifndef __INCLUDED_MPCONFIGPORT_H #define __INCLUDED_MPCONFIGPORT_H -#define MICROPY_PY_UJSON (1) +#define MICROPY_PY_SYS_PLATFORM "RP2040" #define CIRCUITPY_INTERNAL_NVM_SIZE 0 diff --git a/ports/raspberrypi/mpconfigport.mk b/ports/raspberrypi/mpconfigport.mk index a6211be73..8681e2994 100644 --- a/ports/raspberrypi/mpconfigport.mk +++ b/ports/raspberrypi/mpconfigport.mk @@ -14,6 +14,9 @@ ifeq ($(LONGINT_IMPL),LONGLONG) MPY_TOOL_LONGINT_IMPL = -mlongint-impl=longlong endif +# All raspberrypi ports have longints. +LONGINT_IMPL = MPZ + ifndef CIRCUITPY_RP2PIO CIRCUITPY_RP2PIO = 1 else @@ -32,13 +35,13 @@ CIRCUITPY_I2CPERIPHERAL = 0 CIRCUITPY_NVM = 0 CIRCUITPY_PULSEIO = 0 # Use PIO interally CIRCUITPY_ROTARYIO = 0 # Use PIO interally -CIRCUITPY_RTC = 0 +CIRCUITPY_WATCHDOG = 1 # Things that are unsupported by the hardware. CIRCUITPY_AUDIOIO = 0 INTERNAL_LIBM = 1 -USB_SERIAL_NUMBER_LENGTH = 32 +USB_SERIAL_NUMBER_LENGTH = 16 USB_NUM_EP = 8 diff --git a/ports/raspberrypi/sdk b/ports/raspberrypi/sdk -Subproject 26653ea81e340cacee55025d110c3e014a252a8 +Subproject 55346c953012ef5b32f392fea3b42814db8df2a diff --git a/ports/raspberrypi/supervisor/port.c b/ports/raspberrypi/supervisor/port.c index b2f73c7b4..7c503514a 100644 --- a/ports/raspberrypi/supervisor/port.c +++ b/ports/raspberrypi/supervisor/port.c @@ -52,6 +52,8 @@ #include "tusb.h" +#include "pico/bootrom.h" +#include "hardware/watchdog.h" extern volatile bool mp_msc_enabled; @@ -94,25 +96,33 @@ void reset_port(void) { reset_spi(); #endif + #if CIRCUITPY_PWMIO + pwmout_reset(); + #endif + #if CIRCUITPY_RP2PIO reset_rp2pio_statemachine(); #endif - #if CIRCUITPY_PWMIO - pwmout_reset(); + #if CIRCUITPY_RTC + rtc_reset(); #endif reset_all_pins(); } void reset_to_bootloader(void) { - // reset(); + reset_usb_boot(0, 0); while (true) {} } void reset_cpu(void) { - // reset(); - while (true) {} + watchdog_reboot(0, SRAM_END, 0); + watchdog_start_tick(12); + + while (true) { + __wfi(); + } } bool port_has_fixed_stack(void) { diff --git a/ports/stm/boards/espruino_pico/mpconfigboard.mk b/ports/stm/boards/espruino_pico/mpconfigboard.mk index 14f9323fd..81c3772e7 100644 --- a/ports/stm/boards/espruino_pico/mpconfigboard.mk +++ b/ports/stm/boards/espruino_pico/mpconfigboard.mk @@ -20,5 +20,6 @@ LD_FILE = boards/STM32F401xd_fs.ld # lto for this port, and if other stuff hasn't been added in the # meantime CIRCUITPY_ULAB = 0 +CIRCUITPY_BUSDEVICE = 0 SUPEROPT_GC = 0 diff --git a/ports/stm/mpconfigport.h b/ports/stm/mpconfigport.h index 9489b4765..7cdab04f6 100644 --- a/ports/stm/mpconfigport.h +++ b/ports/stm/mpconfigport.h @@ -31,9 +31,7 @@ #include <stdint.h> #define MICROPY_PY_FUNCTION_ATTRS (1) -#define MICROPY_PY_IO (1) #define MICROPY_PY_REVERSE_SPECIAL_METHODS (1) -#define MICROPY_PY_UJSON (1) extern uint8_t _ld_default_stack_size; diff --git a/py/builtinhelp.c b/py/builtinhelp.c index d12e088d6..e1dcb6096 100644 --- a/py/builtinhelp.c +++ b/py/builtinhelp.c @@ -152,9 +152,18 @@ STATIC void mp_help_print_obj(const mp_obj_t obj) { mp_obj_type_t *type = mp_obj_get_type(obj); // try to print something sensible about the given object - mp_print_str(MP_PYTHON_PRINTER, "object "); + const compressed_string_t* compressed = translate("object "); + char decompressed_object[decompress_length(compressed)]; + decompress(compressed, decompressed_object); + + mp_print_str(MP_PYTHON_PRINTER, decompressed_object); mp_obj_print(obj, PRINT_STR); - mp_printf(MP_PYTHON_PRINTER, " is of type %q\n", type->name); + + compressed = translate(" is of type %q\n"); + char decompressed_typestring[decompress_length(compressed)]; + decompress(compressed, decompressed_typestring); + + mp_printf(MP_PYTHON_PRINTER, decompressed_typestring, type->name); mp_map_t *map = NULL; if (type == &mp_type_module) { diff --git a/py/circuitpy_defns.mk b/py/circuitpy_defns.mk index 3ce7c0117..f907bf7ae 100644 --- a/py/circuitpy_defns.mk +++ b/py/circuitpy_defns.mk @@ -292,6 +292,9 @@ endif ifeq ($(CIRCUITPY_USB_MIDI),1) SRC_PATTERNS += usb_midi/% endif +ifeq ($(CIRCUITPY_USB_VENDOR),1) +SRC_PATTERNS += usb_vendor/% +endif ifeq ($(CIRCUITPY_USTACK),1) SRC_PATTERNS += ustack/% endif @@ -388,6 +391,7 @@ SRC_COMMON_HAL_ALL = \ socketpool/Socket.c \ ssl/__init__.c \ ssl/SSLContext.c \ + ssl/SSLSocket.c \ supervisor/Runtime.c \ supervisor/__init__.c \ watchdog/WatchDogMode.c \ diff --git a/py/circuitpy_mpconfig.h b/py/circuitpy_mpconfig.h index 35f1227a9..ee23c7156 100644 --- a/py/circuitpy_mpconfig.h +++ b/py/circuitpy_mpconfig.h @@ -195,21 +195,12 @@ typedef long mp_off_t; #define MICROPY_PY_BUILTINS_STR_CENTER (CIRCUITPY_FULL_BUILD) #define MICROPY_PY_BUILTINS_STR_PARTITION (CIRCUITPY_FULL_BUILD) #define MICROPY_PY_BUILTINS_STR_SPLITLINES (CIRCUITPY_FULL_BUILD) -#define MICROPY_PY_UERRNO (CIRCUITPY_FULL_BUILD) #ifndef MICROPY_PY_COLLECTIONS_ORDEREDDICT #define MICROPY_PY_COLLECTIONS_ORDEREDDICT (CIRCUITPY_FULL_BUILD) #endif -#ifndef MICROPY_PY_UBINASCII -#define MICROPY_PY_UBINASCII (CIRCUITPY_FULL_BUILD) -#endif -// Opposite setting is deliberate. -#define MICROPY_PY_UERRNO_ERRORCODE (!CIRCUITPY_FULL_BUILD) -#ifndef MICROPY_PY_URE -#define MICROPY_PY_URE (CIRCUITPY_FULL_BUILD) -#endif -#define MICROPY_PY_URE_MATCH_GROUPS (CIRCUITPY_FULL_BUILD) -#define MICROPY_PY_URE_MATCH_SPAN_START_END (CIRCUITPY_FULL_BUILD) -#define MICROPY_PY_URE_SUB (CIRCUITPY_FULL_BUILD) +#define MICROPY_PY_URE_MATCH_GROUPS (CIRCUITPY_RE) +#define MICROPY_PY_URE_MATCH_SPAN_START_END (CIRCUITPY_RE) +#define MICROPY_PY_URE_SUB (CIRCUITPY_RE) // LONGINT_IMPL_xxx are defined in the Makefile. // @@ -301,6 +292,13 @@ extern const struct _mp_obj_module_t audiopwmio_module; #define AUDIOPWMIO_MODULE #endif +#if CIRCUITPY_BINASCII +#define MICROPY_PY_UBINASCII CIRCUITPY_BINASCII +#define BINASCII_MODULE { MP_ROM_QSTR(MP_QSTR_binascii), MP_ROM_PTR(&mp_module_ubinascii) }, +#else +#define BINASCII_MODULE +#endif + #if CIRCUITPY_BITBANGIO #define BITBANGIO_MODULE { MP_OBJ_NEW_QSTR(MP_QSTR_bitbangio), (mp_obj_t)&bitbangio_module }, extern const struct _mp_obj_module_t bitbangio_module; @@ -399,6 +397,16 @@ extern const struct _mp_obj_module_t terminalio_module; #define TERMINALIO_MODULE #endif +#if CIRCUITPY_ERRNO +#define MICROPY_PY_UERRNO (1) +// Uses about 80 bytes. +#define MICROPY_PY_UERRNO_ERRORCODE (1) +#define ERRNO_MODULE { MP_ROM_QSTR(MP_QSTR_errno), MP_ROM_PTR(&mp_module_uerrno) }, +#else +#define ERRNO_MODULE +# +#endif + #if CIRCUITPY_ESPIDF extern const struct _mp_obj_module_t espidf_module; #define ESPIDF_MODULE { MP_OBJ_NEW_QSTR(MP_QSTR_espidf),(mp_obj_t)&espidf_module }, @@ -470,6 +478,18 @@ extern const struct _mp_obj_module_t ipaddress_module; #define IPADDRESS_MODULE #endif +#if CIRCUITPY_JSON +#define MICROPY_PY_UJSON (1) +#define MICROPY_PY_IO (1) +#define JSON_MODULE { MP_ROM_QSTR(MP_QSTR_json), MP_ROM_PTR(&mp_module_ujson) }, +#else +#ifndef MICROPY_PY_IO +// We don't need MICROPY_PY_IO unless someone else wants it. +#define MICROPY_PY_IO (0) +#endif +#define JSON_MODULE +#endif + #if CIRCUITPY_MATH extern const struct _mp_obj_module_t math_module; #define MATH_MODULE { MP_OBJ_NEW_QSTR(MP_QSTR_math), (mp_obj_t)&math_module }, @@ -588,6 +608,13 @@ extern const struct _mp_obj_module_t random_module; #define RANDOM_MODULE #endif +#if CIRCUITPY_RE +#define MICROPY_PY_URE (1) +#define RE_MODULE { MP_ROM_QSTR(MP_QSTR_re), MP_ROM_PTR(&mp_module_ure) }, +#else +#define RE_MODULE +#endif + #if CIRCUITPY_RGBMATRIX extern const struct _mp_obj_module_t rgbmatrix_module; #define RGBMATRIX_MODULE { MP_OBJ_NEW_QSTR(MP_QSTR_rgbmatrix),(mp_obj_t)&rgbmatrix_module }, @@ -730,25 +757,6 @@ extern const struct _mp_obj_module_t ustack_module; #define USTACK_MODULE #endif -// These modules are not yet in shared-bindings, but we prefer the non-uxxx names. -#if MICROPY_PY_UBINASCII -#define BINASCII_MODULE { MP_ROM_QSTR(MP_QSTR_binascii), MP_ROM_PTR(&mp_module_ubinascii) }, -#else -#define BINASCII_MODULE -#endif - -#if MICROPY_PY_UERRNO -#define ERRNO_MODULE { MP_ROM_QSTR(MP_QSTR_errno), MP_ROM_PTR(&mp_module_uerrno) }, -#else -#define ERRNO_MODULE -#endif - -#if MICROPY_PY_UJSON -#define JSON_MODULE { MP_ROM_QSTR(MP_QSTR_json), MP_ROM_PTR(&mp_module_ujson) }, -#else -#define JSON_MODULE -#endif - #if defined(CIRCUITPY_ULAB) && CIRCUITPY_ULAB // ulab requires reverse special methods #if defined(MICROPY_PY_REVERSE_SPECIAL_METHODS) && !MICROPY_PY_REVERSE_SPECIAL_METHODS @@ -760,12 +768,6 @@ extern const struct _mp_obj_module_t ustack_module; #define ULAB_MODULE #endif -#if MICROPY_PY_URE -#define RE_MODULE { MP_ROM_QSTR(MP_QSTR_re), MP_ROM_PTR(&mp_module_ure) }, -#else -#define RE_MODULE -#endif - // This is not a top-level module; it's microcontroller.watchdog. #if CIRCUITPY_WATCHDOG extern const struct _mp_obj_module_t watchdog_module; diff --git a/py/circuitpy_mpconfig.mk b/py/circuitpy_mpconfig.mk index 9c9b17f4b..d9c7c0d33 100644 --- a/py/circuitpy_mpconfig.mk +++ b/py/circuitpy_mpconfig.mk @@ -86,6 +86,9 @@ endif endif CFLAGS += -DCIRCUITPY_AUDIOMP3=$(CIRCUITPY_AUDIOMP3) +CIRCUITPY_BINASCII ?= $(CIRCUITPY_FULL_BUILD) +CFLAGS += -DCIRCUITPY_BINASCII=$(CIRCUITPY_BINASCII) + CIRCUITPY_BITBANGIO ?= $(CIRCUITPY_FULL_BUILD) CFLAGS += -DCIRCUITPY_BITBANGIO=$(CIRCUITPY_BITBANGIO) @@ -100,7 +103,7 @@ CFLAGS += -DCIRCUITPY_BLEIO=$(CIRCUITPY_BLEIO) CIRCUITPY_BOARD ?= 1 CFLAGS += -DCIRCUITPY_BOARD=$(CIRCUITPY_BOARD) -CIRCUITPY_BUSDEVICE = 0 +CIRCUITPY_BUSDEVICE ?= $(CIRCUITPY_FULL_BUILD) CFLAGS += -DCIRCUITPY_BUSDEVICE=$(CIRCUITPY_BUSDEVICE) CIRCUITPY_BUILTINS_POW3 ?= $(CIRCUITPY_FULL_BUILD) @@ -124,6 +127,9 @@ CFLAGS += -DCIRCUITPY_COUNTIO=$(CIRCUITPY_COUNTIO) CIRCUITPY_DISPLAYIO ?= $(CIRCUITPY_FULL_BUILD) CFLAGS += -DCIRCUITPY_DISPLAYIO=$(CIRCUITPY_DISPLAYIO) +CIRCUITPY_ERRNO ?= $(CIRCUITPY_FULL_BUILD) +CFLAGS += -DCIRCUITPY_ERRNO=$(CIRCUITPY_ERRNO) + # CIRCUITPY_ESPIDF is handled in the esp32s2 tree. # Only for ESP32S chips. # Assume not a ESP build. @@ -158,6 +164,9 @@ CFLAGS += -DCIRCUITPY_I2CPERIPHERAL=$(CIRCUITPY_I2CPERIPHERAL) CIRCUITPY_IPADDRESS ?= $(CIRCUITPY_WIFI) CFLAGS += -DCIRCUITPY_IPADDRESS=$(CIRCUITPY_IPADDRESS) +CIRCUITPY_JSON ?= $(CIRCUITPY_FULL_BUILD) +CFLAGS += -DCIRCUITPY_JSON=$(CIRCUITPY_JSON) + CIRCUITPY_MATH ?= 1 CFLAGS += -DCIRCUITPY_MATH=$(CIRCUITPY_MATH) @@ -204,6 +213,9 @@ CFLAGS += -DCIRCUITPY_PWMIO=$(CIRCUITPY_PWMIO) CIRCUITPY_RANDOM ?= 1 CFLAGS += -DCIRCUITPY_RANDOM=$(CIRCUITPY_RANDOM) +CIRCUITPY_RE ?= $(CIRCUITPY_FULL_BUILD) +CFLAGS += -DCIRCUITPY_RE=$(CIRCUITPY_RE) + # CIRCUITPY_RP2PIO is handled in the raspberrypi tree. # Only for rp2 chips. # Assume not a rp2 build. @@ -276,6 +288,12 @@ CFLAGS += -DCIRCUITPY_USB_HID=$(CIRCUITPY_USB_HID) CIRCUITPY_USB_MIDI ?= 1 CFLAGS += -DCIRCUITPY_USB_MIDI=$(CIRCUITPY_USB_MIDI) +# Defaulting this to OFF initially because it has only been tested on a +# limited number of platforms, and the other platforms do not have this +# setting in their mpconfigport.mk and/or mpconfigboard.mk files yet. +CIRCUITPY_USB_VENDOR ?= 0 +CFLAGS += -DCIRCUITPY_USB_VENDOR=$(CIRCUITPY_USB_VENDOR) + CIRCUITPY_PEW ?= 0 CFLAGS += -DCIRCUITPY_PEW=$(CIRCUITPY_PEW) diff --git a/shared-bindings/_eve/__init__.c b/shared-bindings/_eve/__init__.c index 0f628b6fb..c043aa5fa 100644 --- a/shared-bindings/_eve/__init__.c +++ b/shared-bindings/_eve/__init__.c @@ -604,22 +604,6 @@ STATIC mp_obj_t _jump(mp_obj_t self, mp_obj_t a0) { } STATIC MP_DEFINE_CONST_FUN_OBJ_2(jump_obj, _jump); -//| def LineWidth(self, width: int) -> None: -//| """Set the width of rasterized lines -//| -//| :param int width: line width in :math:`1/16` pixel. Range 0-4095. The initial value is 16 -//| -//| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.""" -//| ... -//| - -STATIC mp_obj_t _linewidth(mp_obj_t self, mp_obj_t a0) { - uint32_t width = mp_obj_get_int_truncated(a0); - common_hal__eve_LineWidth(EVEHAL(self), width); - return mp_const_none; -} -STATIC MP_DEFINE_CONST_FUN_OBJ_2(linewidth_obj, _linewidth); - //| def Macro(self, m: int) -> None: //| """Execute a single command from a macro register //| @@ -662,22 +646,6 @@ STATIC mp_obj_t _palettesource(mp_obj_t self, mp_obj_t a0) { } STATIC MP_DEFINE_CONST_FUN_OBJ_2(palettesource_obj, _palettesource); -//| def PointSize(self, size: int) -> None: -//| """Set the radius of rasterized points -//| -//| :param int size: point radius in :math:`1/16` pixel. Range 0-8191. The initial value is 16 -//| -//| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.""" -//| ... -//| - -STATIC mp_obj_t _pointsize(mp_obj_t self, mp_obj_t a0) { - uint32_t size = mp_obj_get_int_truncated(a0); - common_hal__eve_PointSize(EVEHAL(self), size); - return mp_const_none; -} -STATIC MP_DEFINE_CONST_FUN_OBJ_2(pointsize_obj, _pointsize); - //| def RestoreContext(self) -> None: //| """Restore the current graphics context from the context stack""" //| ... @@ -836,48 +804,6 @@ STATIC mp_obj_t _tag(mp_obj_t self, mp_obj_t a0) { } STATIC MP_DEFINE_CONST_FUN_OBJ_2(tag_obj, _tag); -//| def VertexTranslateX(self, x: int) -> None: -//| """Set the vertex transformation's x translation component -//| -//| :param int x: signed x-coordinate in :math:`1/16` pixel. Range 0-131071. The initial value is 0 -//| -//| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.""" -//| ... -//| - -STATIC mp_obj_t _vertextranslatex(mp_obj_t self, mp_obj_t a0) { - uint32_t x = mp_obj_get_int_truncated(a0); - common_hal__eve_VertexTranslateX(EVEHAL(self), x); - return mp_const_none; -} -STATIC MP_DEFINE_CONST_FUN_OBJ_2(vertextranslatex_obj, _vertextranslatex); - -//| def VertexTranslateY(self, y: int) -> None: -//| """Set the vertex transformation's y translation component -//| -//| :param int y: signed y-coordinate in :math:`1/16` pixel. Range 0-131071. The initial value is 0 -//| -//| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.""" -//| ... -//| - - -STATIC mp_obj_t _vertextranslatey(mp_obj_t self, mp_obj_t a0) { - uint32_t y = mp_obj_get_int_truncated(a0); - common_hal__eve_VertexTranslateY(EVEHAL(self), y); - return mp_const_none; -} -STATIC MP_DEFINE_CONST_FUN_OBJ_2(vertextranslatey_obj, _vertextranslatey); - -//| def VertexFormat(self, frac: int) -> None: -//| """Set the precision of vertex2f coordinates -//| -//| :param int frac: Number of fractional bits in X,Y coordinates, 0-4. Range 0-7. The initial value is 4 -//| -//| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.""" -//| ... -//| - STATIC mp_obj_t _vertexformat(mp_obj_t self, mp_obj_t a0) { uint32_t frac = mp_obj_get_int_truncated(a0); common_hal__eve_VertexFormat(EVEHAL(self), frac); @@ -975,6 +901,82 @@ STATIC mp_obj_t _vertex2f(mp_obj_t self, mp_obj_t a0, mp_obj_t a1) { } STATIC MP_DEFINE_CONST_FUN_OBJ_3(vertex2f_obj, _vertex2f); +//| def LineWidth(self, width: float) -> None: +//| """Set the width of rasterized lines +//| +//| :param float width: line width in pixels. Range 0-511. The initial value is 1 +//| +//| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.""" +//| ... +//| + +STATIC mp_obj_t _linewidth(mp_obj_t self, mp_obj_t a0) { + mp_float_t width = mp_obj_get_float(a0); + common_hal__eve_LineWidth(EVEHAL(self), width); + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(linewidth_obj, _linewidth); + +//| def PointSize(self, size: float) -> None: +//| """Set the diameter of rasterized points +//| +//| :param float size: point diameter in pixels. Range 0-1023. The initial value is 1 +//| +//| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.""" +//| ... +//| + +STATIC mp_obj_t _pointsize(mp_obj_t self, mp_obj_t a0) { + mp_float_t size = mp_obj_get_float(a0); + common_hal__eve_PointSize(EVEHAL(self), size); + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(pointsize_obj, _pointsize); + +//| def VertexTranslateX(self, x: float) -> None: +//| """Set the vertex transformation's x translation component +//| +//| :param float x: signed x-coordinate in pixels. Range ±4095. The initial value is 0 +//| +//| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.""" +//| ... +//| + +STATIC mp_obj_t _vertextranslatex(mp_obj_t self, mp_obj_t a0) { + mp_float_t x = mp_obj_get_float(a0); + common_hal__eve_VertexTranslateX(EVEHAL(self), x); + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(vertextranslatex_obj, _vertextranslatex); + +//| def VertexTranslateY(self, y: float) -> None: +//| """Set the vertex transformation's y translation component +//| +//| :param float y: signed y-coordinate in pixels. Range ±4095. The initial value is 0 +//| +//| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.""" +//| ... +//| + + +STATIC mp_obj_t _vertextranslatey(mp_obj_t self, mp_obj_t a0) { + mp_float_t y = mp_obj_get_float(a0); + common_hal__eve_VertexTranslateY(EVEHAL(self), y); + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(vertextranslatey_obj, _vertextranslatey); + +//| def VertexFormat(self, frac: int) -> None: +//| """Set the precision of vertex2f coordinates +//| +//| :param int frac: Number of fractional bits in X,Y coordinates, 0-4. Range 0-7. The initial value is 4 +//| +//| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.""" +//| ... +//| + +//} + // Append an object x to the FIFO #define ADD_X(self, x) \ common_hal__eve_add(EVEHAL(self), sizeof(x), &(x)); diff --git a/shared-bindings/_eve/__init__.h b/shared-bindings/_eve/__init__.h index 759a629bb..883b1a15b 100644 --- a/shared-bindings/_eve/__init__.h +++ b/shared-bindings/_eve/__init__.h @@ -61,11 +61,11 @@ void common_hal__eve_ColorRGB(common_hal__eve_t *eve, uint32_t red, uint32_t gre void common_hal__eve_Display(common_hal__eve_t *eve); void common_hal__eve_End(common_hal__eve_t *eve); void common_hal__eve_Jump(common_hal__eve_t *eve, uint32_t dest); -void common_hal__eve_LineWidth(common_hal__eve_t *eve, uint32_t width); +void common_hal__eve_LineWidth(common_hal__eve_t *eve, mp_float_t width); void common_hal__eve_Macro(common_hal__eve_t *eve, uint32_t m); void common_hal__eve_Nop(common_hal__eve_t *eve); void common_hal__eve_PaletteSource(common_hal__eve_t *eve, uint32_t addr); -void common_hal__eve_PointSize(common_hal__eve_t *eve, uint32_t size); +void common_hal__eve_PointSize(common_hal__eve_t *eve, mp_float_t size); void common_hal__eve_RestoreContext(common_hal__eve_t *eve); void common_hal__eve_Return(common_hal__eve_t *eve); void common_hal__eve_SaveContext(common_hal__eve_t *eve); @@ -76,8 +76,8 @@ void common_hal__eve_StencilMask(common_hal__eve_t *eve, uint32_t mask); void common_hal__eve_StencilOp(common_hal__eve_t *eve, uint32_t sfail, uint32_t spass); void common_hal__eve_TagMask(common_hal__eve_t *eve, uint32_t mask); void common_hal__eve_Tag(common_hal__eve_t *eve, uint32_t s); -void common_hal__eve_VertexTranslateX(common_hal__eve_t *eve, uint32_t x); -void common_hal__eve_VertexTranslateY(common_hal__eve_t *eve, uint32_t y); +void common_hal__eve_VertexTranslateX(common_hal__eve_t *eve, mp_float_t x); +void common_hal__eve_VertexTranslateY(common_hal__eve_t *eve, mp_float_t y); void common_hal__eve_VertexFormat(common_hal__eve_t *eve, uint32_t frac); void common_hal__eve_Vertex2ii(common_hal__eve_t *eve, uint32_t x, uint32_t y, uint32_t handle, uint32_t cell); diff --git a/shared-bindings/adafruit_bus_device/I2CDevice.c b/shared-bindings/adafruit_bus_device/I2CDevice.c index a4c04e198..e6ec8c147 100644 --- a/shared-bindings/adafruit_bus_device/I2CDevice.c +++ b/shared-bindings/adafruit_bus_device/I2CDevice.c @@ -35,6 +35,7 @@ #include "lib/utils/buffer_helper.h" #include "lib/utils/context_manager_helpers.h" #include "py/runtime.h" +#include "py/smallint.h" #include "supervisor/shared/translate.h" @@ -76,7 +77,7 @@ STATIC mp_obj_t adafruit_bus_device_i2cdevice_make_new(const mp_obj_type_t *type 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); - busio_i2c_obj_t* i2c = args[ARG_i2c].u_obj; + mp_obj_t* i2c = args[ARG_i2c].u_obj; common_hal_adafruit_bus_device_i2cdevice_construct(MP_OBJ_TO_PTR(self), i2c, args[ARG_device_address].u_int); if (args[ARG_probe].u_bool == true) { @@ -107,7 +108,7 @@ STATIC mp_obj_t adafruit_bus_device_i2cdevice_obj___exit__(size_t n_args, const } STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(adafruit_bus_device_i2cdevice___exit___obj, 4, 4, adafruit_bus_device_i2cdevice_obj___exit__); -//| def readinto(self, buf: WriteableBuffer, *, start: int = 0, end: int = 0) -> None: +//| def readinto(self, buf: WriteableBuffer, *, start: int = 0, end: Optional[int] = None) -> None: //| """Read into ``buf`` from the device. The number of bytes read will be the //| length of ``buf``. //| If ``start`` or ``end`` is provided, then the buffer will be sliced @@ -118,22 +119,6 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(adafruit_bus_device_i2cdevice___exit_ //| :param int end: Index to write up to but not include; if None, use ``len(buf)``""" //| ... //| -STATIC void readinto(adafruit_bus_device_i2cdevice_obj_t *self, mp_obj_t buffer, int32_t start, mp_int_t end) { - mp_buffer_info_t bufinfo; - mp_get_buffer_raise(buffer, &bufinfo, MP_BUFFER_WRITE); - - size_t length = bufinfo.len; - normalize_buffer_bounds(&start, end, &length); - if (length == 0) { - mp_raise_ValueError(translate("Buffer must be at least length 1")); - } - - uint8_t status = common_hal_adafruit_bus_device_i2cdevice_readinto(MP_OBJ_TO_PTR(self), ((uint8_t*)bufinfo.buf) + start, length); - if (status != 0) { - mp_raise_OSError(status); - } -} - STATIC mp_obj_t adafruit_bus_device_i2cdevice_readinto(size_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) { enum { ARG_buffer, ARG_start, ARG_end }; static const mp_arg_t allowed_args[] = { @@ -147,12 +132,27 @@ STATIC mp_obj_t adafruit_bus_device_i2cdevice_readinto(size_t n_args, const mp_o 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); - readinto(self, args[ARG_buffer].u_obj, args[ARG_start].u_int, args[ARG_end].u_int); + mp_obj_t dest[8]; + uint8_t num_kws = 1; + + mp_load_method(self->i2c, MP_QSTR_readfrom_into, dest); + dest[2] = MP_OBJ_NEW_SMALL_INT(self->device_address); + dest[3] = args[ARG_buffer].u_obj; + //dest[4] = mp_obj_new_str("start", 5); + dest[4] = MP_OBJ_NEW_QSTR(MP_QSTR_start); + dest[5] = MP_OBJ_NEW_SMALL_INT(args[ARG_start].u_int); + if (args[ARG_end].u_int != INT_MAX) { + dest[6] = MP_OBJ_NEW_QSTR(MP_QSTR_end); + dest[7] = MP_OBJ_NEW_SMALL_INT(args[ARG_end].u_int); + num_kws++; + } + mp_call_method_n_kw(2, num_kws, dest); + return mp_const_none; } STATIC MP_DEFINE_CONST_FUN_OBJ_KW(adafruit_bus_device_i2cdevice_readinto_obj, 2, adafruit_bus_device_i2cdevice_readinto); -//| def write(self, buf: ReadableBuffer, *, start: int = 0, end: int = 0) -> None: +//| def write(self, buf: ReadableBuffer, *, start: int = 0, end: Optional[int] = None) -> None: //| """Write the bytes from ``buffer`` to the device, then transmit a stop bit. //| If ``start`` or ``end`` is provided, then the buffer will be sliced //| as if ``buffer[start:end]``. This will not cause an allocation like @@ -163,22 +163,6 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_KW(adafruit_bus_device_i2cdevice_readinto_obj, 2, //| """ //| ... //| -STATIC void write(adafruit_bus_device_i2cdevice_obj_t *self, mp_obj_t buffer, int32_t start, mp_int_t end, bool transmit_stop_bit) { - mp_buffer_info_t bufinfo; - mp_get_buffer_raise(buffer, &bufinfo, MP_BUFFER_READ); - - size_t length = bufinfo.len; - normalize_buffer_bounds(&start, end, &length); - if (length == 0) { - mp_raise_ValueError(translate("Buffer must be at least length 1")); - } - - uint8_t status = common_hal_adafruit_bus_device_i2cdevice_write(MP_OBJ_TO_PTR(self), ((uint8_t*)bufinfo.buf) + start, length, transmit_stop_bit); - if (status != 0) { - mp_raise_OSError(status); - } -} - STATIC mp_obj_t adafruit_bus_device_i2cdevice_write(size_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) { enum { ARG_buffer, ARG_start, ARG_end }; static const mp_arg_t allowed_args[] = { @@ -191,13 +175,28 @@ STATIC mp_obj_t adafruit_bus_device_i2cdevice_write(size_t n_args, const mp_obj_ 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); - write(self, args[ARG_buffer].u_obj, args[ARG_start].u_int, args[ARG_end].u_int, true); + mp_obj_t dest[8]; + uint8_t num_kws = 1; + + mp_load_method(self->i2c, MP_QSTR_writeto, dest); + dest[2] = MP_OBJ_NEW_SMALL_INT(self->device_address); + dest[3] = args[ARG_buffer].u_obj; + dest[4] = MP_OBJ_NEW_QSTR(MP_QSTR_start); + dest[5] = MP_OBJ_NEW_SMALL_INT(args[ARG_start].u_int); + if (args[ARG_end].u_int != INT_MAX) { + dest[6] = MP_OBJ_NEW_QSTR(MP_QSTR_end); + dest[7] = MP_OBJ_NEW_SMALL_INT(args[ARG_end].u_int); + num_kws++; + } + + mp_call_method_n_kw(2, num_kws, dest); + return mp_const_none; } MP_DEFINE_CONST_FUN_OBJ_KW(adafruit_bus_device_i2cdevice_write_obj, 2, adafruit_bus_device_i2cdevice_write); -//| def write_then_readinto(self, out_buffer: WriteableBuffer, in_buffer: ReadableBuffer, *, out_start: int = 0, out_end: int = 0, in_start: int = 0, in_end: int = 0) -> None: +//| def write_then_readinto(self, out_buffer: WriteableBuffer, in_buffer: ReadableBuffer, *, out_start: int = 0, out_end: Optional[int] = None, in_start: int = 0, in_end: Optional[int] = None) -> None: //| """Write the bytes from ``out_buffer`` to the device, then immediately //| reads into ``in_buffer`` from the device. The number of bytes read //| will be the length of ``in_buffer``. @@ -233,9 +232,30 @@ STATIC mp_obj_t adafruit_bus_device_i2cdevice_write_then_readinto(size_t n_args, 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); - write(self, args[ARG_out_buffer].u_obj, args[ARG_out_start].u_int, args[ARG_out_end].u_int, false); + mp_obj_t dest[13]; + uint8_t num_kws = 2; + uint8_t index = 2; + + mp_load_method(self->i2c, MP_QSTR_writeto_then_readfrom, dest); + dest[index++] = MP_OBJ_NEW_SMALL_INT(self->device_address); + dest[index++] = args[ARG_out_buffer].u_obj; + dest[index++] = args[ARG_in_buffer].u_obj; + dest[index++] = MP_OBJ_NEW_QSTR(MP_QSTR_out_start); + dest[index++] = MP_OBJ_NEW_SMALL_INT(args[ARG_out_start].u_int); + if (args[ARG_out_end].u_int != INT_MAX) { + dest[index++] = MP_OBJ_NEW_QSTR(MP_QSTR_out_end); + dest[index++] = MP_OBJ_NEW_SMALL_INT(args[ARG_out_end].u_int); + num_kws++; + } + dest[index++] = MP_OBJ_NEW_QSTR(MP_QSTR_in_start); + dest[index++] = MP_OBJ_NEW_SMALL_INT(args[ARG_in_start].u_int); + if (args[ARG_in_end].u_int != INT_MAX) { + dest[index++] = MP_OBJ_NEW_QSTR(MP_QSTR_in_end); + dest[index++] = MP_OBJ_NEW_SMALL_INT(args[ARG_in_end].u_int); + num_kws++; + } - readinto(self, args[ARG_in_buffer].u_obj, args[ARG_in_start].u_int, args[ARG_in_end].u_int); + mp_call_method_n_kw(3, num_kws, dest); return mp_const_none; } diff --git a/shared-bindings/adafruit_bus_device/I2CDevice.h b/shared-bindings/adafruit_bus_device/I2CDevice.h index cf7b1321a..82ef1feb8 100644 --- a/shared-bindings/adafruit_bus_device/I2CDevice.h +++ b/shared-bindings/adafruit_bus_device/I2CDevice.h @@ -43,9 +43,7 @@ extern const mp_obj_type_t adafruit_bus_device_i2cdevice_type; // Initializes the hardware peripheral. -extern void common_hal_adafruit_bus_device_i2cdevice_construct(adafruit_bus_device_i2cdevice_obj_t *self, busio_i2c_obj_t *i2c, uint8_t device_address); -extern uint8_t common_hal_adafruit_bus_device_i2cdevice_readinto(adafruit_bus_device_i2cdevice_obj_t *self, mp_obj_t buffer, size_t length); -extern uint8_t common_hal_adafruit_bus_device_i2cdevice_write(adafruit_bus_device_i2cdevice_obj_t *self, mp_obj_t buffer, size_t length, bool transmit_stop_bit); +extern void common_hal_adafruit_bus_device_i2cdevice_construct(adafruit_bus_device_i2cdevice_obj_t *self, mp_obj_t *i2c, uint8_t device_address); extern void common_hal_adafruit_bus_device_i2cdevice_lock(adafruit_bus_device_i2cdevice_obj_t *self); extern void common_hal_adafruit_bus_device_i2cdevice_unlock(adafruit_bus_device_i2cdevice_obj_t *self); extern void common_hal_adafruit_bus_device_i2cdevice_probe_for_device(adafruit_bus_device_i2cdevice_obj_t *self); diff --git a/shared-bindings/adafruit_bus_device/SPIDevice.c b/shared-bindings/adafruit_bus_device/SPIDevice.c index e127e39b8..e37f88368 100644 --- a/shared-bindings/adafruit_bus_device/SPIDevice.c +++ b/shared-bindings/adafruit_bus_device/SPIDevice.c @@ -34,6 +34,7 @@ #include "lib/utils/buffer_helper.h" #include "lib/utils/context_manager_helpers.h" +#include "py/objproperty.h" #include "py/runtime.h" #include "supervisor/shared/translate.h" @@ -100,22 +101,51 @@ STATIC mp_obj_t adafruit_bus_device_spidevice_make_new(const mp_obj_type_t *type return (mp_obj_t)self; } +//| def __enter__(self) -> busio.SPI: +//| """Starts a SPI transaction by configuring the SPI and asserting chip select.""" +//| ... +//| STATIC mp_obj_t adafruit_bus_device_spidevice_obj___enter__(mp_obj_t self_in) { adafruit_bus_device_spidevice_obj_t *self = MP_OBJ_TO_PTR(self_in); - common_hal_adafruit_bus_device_spidevice_enter(self); - return self->spi; + return common_hal_adafruit_bus_device_spidevice_enter(self); } STATIC MP_DEFINE_CONST_FUN_OBJ_1(adafruit_bus_device_spidevice___enter___obj, adafruit_bus_device_spidevice_obj___enter__); + +//| def __exit__(self) -> None: +//| """Ends a SPI transaction by deasserting chip select. See +//| :ref:`lifetime-and-contextmanagers` for more info.""" +//| ... +//| STATIC mp_obj_t adafruit_bus_device_spidevice_obj___exit__(size_t n_args, const mp_obj_t *args) { common_hal_adafruit_bus_device_spidevice_exit(MP_OBJ_TO_PTR(args[0])); return mp_const_none; } STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(adafruit_bus_device_spidevice___exit___obj, 4, 4, adafruit_bus_device_spidevice_obj___exit__); +//| spi: busio.SPI +//| """The underlying SPI bus. Useful for weird uses like clocking an SD card without chip select. +//| +//| You shouldn't normally need this.""" +//| +STATIC mp_obj_t adafruit_bus_device_spidevice_obj_get_spi(mp_obj_t self_in) { + adafruit_bus_device_spidevice_obj_t *self = MP_OBJ_TO_PTR(self_in); + return common_hal_adafruit_bus_device_spidevice_get_spi(self); +} +MP_DEFINE_CONST_FUN_OBJ_1(adafruit_bus_device_spidevice_get_spi_obj, adafruit_bus_device_spidevice_obj_get_spi); + +const mp_obj_property_t adafruit_bus_device_spidevice_spi_obj = { + .base.type = &mp_type_property, + .proxy = {(mp_obj_t)&adafruit_bus_device_spidevice_get_spi_obj, + (mp_obj_t)&mp_const_none_obj, + (mp_obj_t)&mp_const_none_obj}, +}; + STATIC const mp_rom_map_elem_t adafruit_bus_device_spidevice_locals_dict_table[] = { { MP_ROM_QSTR(MP_QSTR___enter__), MP_ROM_PTR(&adafruit_bus_device_spidevice___enter___obj) }, { MP_ROM_QSTR(MP_QSTR___exit__), MP_ROM_PTR(&adafruit_bus_device_spidevice___exit___obj) }, + + { MP_ROM_QSTR(MP_QSTR_spi), MP_ROM_PTR(&adafruit_bus_device_spidevice_spi_obj) }, }; STATIC MP_DEFINE_CONST_DICT(adafruit_bus_device_spidevice_locals_dict, adafruit_bus_device_spidevice_locals_dict_table); diff --git a/shared-bindings/adafruit_bus_device/SPIDevice.h b/shared-bindings/adafruit_bus_device/SPIDevice.h index 5596b157f..baa9ec464 100644 --- a/shared-bindings/adafruit_bus_device/SPIDevice.h +++ b/shared-bindings/adafruit_bus_device/SPIDevice.h @@ -44,7 +44,8 @@ extern const mp_obj_type_t adafruit_bus_device_spidevice_type; // Initializes the hardware peripheral. extern void common_hal_adafruit_bus_device_spidevice_construct(adafruit_bus_device_spidevice_obj_t *self, busio_spi_obj_t *spi, digitalio_digitalinout_obj_t *cs, uint32_t baudrate, uint8_t polarity, uint8_t phase, uint8_t extra_clocks); -extern void common_hal_adafruit_bus_device_spidevice_enter(adafruit_bus_device_spidevice_obj_t *self); +extern mp_obj_t common_hal_adafruit_bus_device_spidevice_enter(adafruit_bus_device_spidevice_obj_t *self); extern void common_hal_adafruit_bus_device_spidevice_exit(adafruit_bus_device_spidevice_obj_t *self); +extern mp_obj_t common_hal_adafruit_bus_device_spidevice_get_spi(adafruit_bus_device_spidevice_obj_t *self); #endif // MICROPY_INCLUDED_SHARED_BINDINGS_BUSDEVICE_SPIDEVICE_H diff --git a/shared-bindings/microcontroller/Processor.c b/shared-bindings/microcontroller/Processor.c index 90cc02fe3..67001c831 100644 --- a/shared-bindings/microcontroller/Processor.c +++ b/shared-bindings/microcontroller/Processor.c @@ -41,7 +41,15 @@ //| //| import microcontroller //| print(microcontroller.cpu.frequency) -//| print(microcontroller.cpu.temperature)""" +//| print(microcontroller.cpu.temperature) +//| +//| Note that on chips with more than one cpu (such as the RP2040) +//| microcontroller.cpu will return the value for CPU 0. +//| To get values from other CPUs use microcontroller.cpus indexed by +//| the number of the desired cpu. i.e. +//| +//| print(microcontroller.cpus[0].temperature) +//| print(microcontroller.cpus[1].frequency)""" //| //| def __init__(self) -> None: diff --git a/shared-bindings/microcontroller/__init__.c b/shared-bindings/microcontroller/__init__.c index 035587c30..dba66fa4f 100644 --- a/shared-bindings/microcontroller/__init__.c +++ b/shared-bindings/microcontroller/__init__.c @@ -53,7 +53,13 @@ //| cpu: Processor //| """CPU information and control, such as ``cpu.temperature`` and ``cpu.frequency`` //| (clock frequency). -//| This object is the sole instance of `microcontroller.Processor`.""" +//| This object is an instance of `microcontroller.Processor`.""" +//| + +//| cpus: Processor +//| """CPU information and control, such as ``cpus[0].temperature`` and ``cpus[1].frequency`` +//| (clock frequency) on chips with more than 1 cpu. The index selects which cpu. +//| This object is an instance of `microcontroller.Processor`.""" //| //| def delay_us(delay: int) -> None: @@ -155,6 +161,9 @@ const mp_obj_module_t mcu_pin_module = { STATIC const mp_rom_map_elem_t mcu_module_globals_table[] = { { MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_microcontroller) }, { MP_ROM_QSTR(MP_QSTR_cpu), MP_ROM_PTR(&common_hal_mcu_processor_obj) }, +#if CIRCUITPY_PROCESSOR_COUNT > 1 + { MP_ROM_QSTR(MP_QSTR_cpus), MP_ROM_PTR(&common_hal_multi_processor_obj) }, +#endif { MP_ROM_QSTR(MP_QSTR_delay_us), MP_ROM_PTR(&mcu_delay_us_obj) }, { MP_ROM_QSTR(MP_QSTR_disable_interrupts), MP_ROM_PTR(&mcu_disable_interrupts_obj) }, { MP_ROM_QSTR(MP_QSTR_enable_interrupts), MP_ROM_PTR(&mcu_enable_interrupts_obj) }, diff --git a/shared-bindings/microcontroller/__init__.h b/shared-bindings/microcontroller/__init__.h index 39d3e718b..733127d56 100644 --- a/shared-bindings/microcontroller/__init__.h +++ b/shared-bindings/microcontroller/__init__.h @@ -48,7 +48,8 @@ extern const mp_obj_dict_t mcu_pin_globals; #if CIRCUITPY_PROCESSOR_COUNT == 1 extern const mcu_processor_obj_t common_hal_mcu_processor_obj; #elif CIRCUITPY_PROCESSOR_COUNT > 1 -extern const mp_rom_obj_tuple_t common_hal_mcu_processor_obj; +extern const mcu_processor_obj_t common_hal_mcu_processor_obj; +extern const mp_rom_obj_tuple_t common_hal_multi_processor_obj; #else #error "Invalid processor count" #endif diff --git a/shared-bindings/rgbmatrix/RGBMatrix.c b/shared-bindings/rgbmatrix/RGBMatrix.c index 5f5ea4fae..30b72dffd 100644 --- a/shared-bindings/rgbmatrix/RGBMatrix.c +++ b/shared-bindings/rgbmatrix/RGBMatrix.c @@ -132,11 +132,11 @@ STATIC void preflight_pins_or_throw(uint8_t clock_pin, uint8_t *rgb_pins, uint8_ } } -//| def __init__(self, *, width: int, bit_depth: int, rgb_pins: Sequence[digitalio.DigitalInOut], addr_pins: Sequence[digitalio.DigitalInOut], clock_pin: digitalio.DigitalInOut, latch_pin: digitalio.DigitalInOut, output_enable_pin: digitalio.DigitalInOut, doublebuffer: bool = True, framebuffer: Optional[WriteableBuffer] = None, height: int = 0) -> None: +//| def __init__(self, *, width: int, bit_depth: int, rgb_pins: Sequence[digitalio.DigitalInOut], addr_pins: Sequence[digitalio.DigitalInOut], clock_pin: digitalio.DigitalInOut, latch_pin: digitalio.DigitalInOut, output_enable_pin: digitalio.DigitalInOut, doublebuffer: bool = True, framebuffer: Optional[WriteableBuffer] = None, height: int = 0, tile: int = 1, serpentine: bool = True) -> None: //| """Create a RGBMatrix object with the given attributes. The height of -//| the display is determined by the number of rgb and address pins: -//| len(rgb_pins) // 3 * 2 ** len(address_pins). With 6 RGB pins and 4 -//| address lines, the display will be 32 pixels tall. If the optional height +//| the display is determined by the number of rgb and address pins and the number of tiles: +//| ``len(rgb_pins) // 3 * 2 ** len(address_pins) * abs(tile)``. With 6 RGB pins, 4 +//| address lines, and a single matrix, the display will be 32 pixels tall. If the optional height //| parameter is specified and is not 0, it is checked against the calculated //| height. //| @@ -172,7 +172,7 @@ STATIC void preflight_pins_or_throw(uint8_t clock_pin, uint8_t *rgb_pins, uint8_ STATIC mp_obj_t rgbmatrix_rgbmatrix_make_new(const mp_obj_type_t *type, size_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) { enum { ARG_width, ARG_bit_depth, ARG_rgb_list, ARG_addr_list, - ARG_clock_pin, ARG_latch_pin, ARG_output_enable_pin, ARG_doublebuffer, ARG_framebuffer, ARG_height }; + ARG_clock_pin, ARG_latch_pin, ARG_output_enable_pin, ARG_doublebuffer, ARG_framebuffer, ARG_height, ARG_tile, ARG_serpentine }; static const mp_arg_t allowed_args[] = { { MP_QSTR_width, MP_ARG_INT | MP_ARG_REQUIRED | MP_ARG_KW_ONLY }, { MP_QSTR_bit_depth, MP_ARG_INT | MP_ARG_REQUIRED | MP_ARG_KW_ONLY }, @@ -184,6 +184,8 @@ STATIC mp_obj_t rgbmatrix_rgbmatrix_make_new(const mp_obj_type_t *type, size_t n { MP_QSTR_doublebuffer, MP_ARG_BOOL | MP_ARG_KW_ONLY, { .u_bool = true } }, { MP_QSTR_framebuffer, MP_ARG_OBJ | MP_ARG_KW_ONLY, { .u_obj = mp_const_none } }, { MP_QSTR_height, MP_ARG_INT | MP_ARG_KW_ONLY, { .u_int = 0 } }, + { MP_QSTR_tile, MP_ARG_INT | MP_ARG_KW_ONLY, { .u_int = 1 } }, + { MP_QSTR_serpentine, MP_ARG_BOOL | MP_ARG_KW_ONLY, { .u_bool = true } }, }; 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); @@ -210,12 +212,18 @@ STATIC mp_obj_t rgbmatrix_rgbmatrix_make_new(const mp_obj_type_t *type, size_t n mp_raise_ValueError_varg(translate("Must use a multiple of 6 rgb pins, not %d"), rgb_count); } - // TODO(@jepler) Use fewer than all rows of pixels if height < computed_height + int tile = args[ARG_tile].u_int; + + if (tile <= 0) { + mp_raise_ValueError_varg( + translate("tile must be greater than zero")); + } + + int computed_height = (rgb_count / 3) * (1 << (addr_count)) * tile; if (args[ARG_height].u_int != 0) { - int computed_height = (rgb_count / 3) << (addr_count); if (computed_height != args[ARG_height].u_int) { mp_raise_ValueError_varg( - translate("%d address pins and %d rgb pins indicate a height of %d, not %d"), addr_count, rgb_count, computed_height, args[ARG_height].u_int); + translate("%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d"), addr_count, rgb_count, tile, computed_height, args[ARG_height].u_int); } } @@ -228,7 +236,7 @@ STATIC mp_obj_t rgbmatrix_rgbmatrix_make_new(const mp_obj_type_t *type, size_t n mp_obj_t framebuffer = args[ARG_framebuffer].u_obj; if (framebuffer == mp_const_none) { int width = args[ARG_width].u_int; - int bufsize = 2 * width * rgb_count / 3 * (1 << addr_count); + int bufsize = 2 * width * computed_height; framebuffer = mp_obj_new_bytearray_of_zeros(bufsize); } @@ -239,7 +247,7 @@ STATIC mp_obj_t rgbmatrix_rgbmatrix_make_new(const mp_obj_type_t *type, size_t n addr_count, addr_pins, clock_pin, latch_pin, output_enable_pin, args[ARG_doublebuffer].u_bool, - framebuffer, NULL); + framebuffer, tile, args[ARG_serpentine].u_bool, NULL); claim_and_never_reset_pins(args[ARG_rgb_list].u_obj); claim_and_never_reset_pins(args[ARG_addr_list].u_obj); diff --git a/shared-bindings/rgbmatrix/RGBMatrix.h b/shared-bindings/rgbmatrix/RGBMatrix.h index bfe37c340..4eb3c04b2 100644 --- a/shared-bindings/rgbmatrix/RGBMatrix.h +++ b/shared-bindings/rgbmatrix/RGBMatrix.h @@ -31,7 +31,7 @@ extern const mp_obj_type_t rgbmatrix_RGBMatrix_type; -void common_hal_rgbmatrix_rgbmatrix_construct(rgbmatrix_rgbmatrix_obj_t* self, int width, int bit_depth, uint8_t rgb_count, uint8_t* rgb_pins, uint8_t addr_count, uint8_t* addr_pins, uint8_t clock_pin, uint8_t latch_pin, uint8_t oe_pin, bool doublebuffer, mp_obj_t framebuffer, void* timer); +void common_hal_rgbmatrix_rgbmatrix_construct(rgbmatrix_rgbmatrix_obj_t* self, int width, int bit_depth, uint8_t rgb_count, uint8_t* rgb_pins, uint8_t addr_count, uint8_t* addr_pins, uint8_t clock_pin, uint8_t latch_pin, uint8_t oe_pin, bool doublebuffer, mp_obj_t framebuffer, int8_t tile, bool serpentine, void* timer); void common_hal_rgbmatrix_rgbmatrix_deinit(rgbmatrix_rgbmatrix_obj_t*); void rgbmatrix_rgbmatrix_collect_ptrs(rgbmatrix_rgbmatrix_obj_t*); void common_hal_rgbmatrix_rgbmatrix_reconstruct(rgbmatrix_rgbmatrix_obj_t* self, mp_obj_t framebuffer); diff --git a/shared-bindings/rtc/RTC.h b/shared-bindings/rtc/RTC.h index 76510bd72..02bf54f50 100644 --- a/shared-bindings/rtc/RTC.h +++ b/shared-bindings/rtc/RTC.h @@ -30,6 +30,7 @@ #include <stdint.h> #include <stdbool.h> +#include "py/obj.h" #include "lib/timeutils/timeutils.h" extern void common_hal_rtc_get_time(timeutils_struct_time_t *tm); diff --git a/shared-bindings/socketpool/Socket.c b/shared-bindings/socketpool/Socket.c index 0e6968d5f..27440487a 100644 --- a/shared-bindings/socketpool/Socket.c +++ b/shared-bindings/socketpool/Socket.c @@ -3,8 +3,8 @@ * * The MIT License (MIT) * - * SPDX-FileCopyrightText: Copyright (c) 2014 Damien P. George - * 2018 Nick Moore for Adafruit Industries + * Copyright (c) 2020 Scott Shawcroft for Adafruit Industries + * Copyright (c) 2021 Lucian Copeland for Adafruit Industries * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -64,94 +64,49 @@ STATIC mp_obj_t socketpool_socket___exit__(size_t n_args, const mp_obj_t *args) } STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(socketpool_socket___exit___obj, 4, 4, socketpool_socket___exit__); -// //| def bind(self, address: tuple) -> None: -// //| """Bind a socket to an address -// //| -// //| :param ~tuple address: tuple of (remote_address, remote_port)""" -// //| ... -// //| - -// STATIC mp_obj_t socketpool_socket_bind(mp_obj_t self_in, mp_obj_t addr_in) { -// // mod_network_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); - -// // // get address -// // uint8_t ip[MOD_NETWORK_IPADDR_BUF_SIZE]; -// // mp_uint_t port = netutils_parse_inet_addr(addr_in, ip, NETUTILS_BIG); - -// // // check if we need to select a NIC -// // socket_select_nic(self, ip); - -// // // call the NIC to bind the socket -// // int _errno; -// // if (self->nic_type->bind(self, ip, port, &_errno) != 0) { -// // mp_raise_OSError(_errno); -// // } - -// return mp_const_none; -// } -// STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_bind_obj, socketpool_socket_bind); - -// //| def listen(self, backlog: int) -> None: -// //| """Set socket to listen for incoming connections -// //| -// //| :param ~int backlog: length of backlog queue for waiting connetions""" -// //| ... -// //| - -// STATIC mp_obj_t socketpool_socket_listen(mp_obj_t self_in, mp_obj_t backlog) { -// // mod_network_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); - -// // if (self->nic == MP_OBJ_NULL) { -// // // not connected -// // // TODO I think we can listen even if not bound... -// // mp_raise_OSError(MP_ENOTCONN); -// // } - -// // int _errno; -// // if (self->nic_type->listen(self, mp_obj_get_int(backlog), &_errno) != 0) { -// // mp_raise_OSError(_errno); -// // } +//| def accept(self) -> Tuple[Socket, Tuple[str, int]]: +//| """Accept a connection on a listening socket of type SOCK_STREAM, +//| creating a new socket of type SOCK_STREAM. +//| Returns a tuple of (new_socket, remote_address)""" +//| +STATIC mp_obj_t socketpool_socket_accept(mp_obj_t self_in) { + socketpool_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); + uint8_t ip[4]; + uint port; -// return mp_const_none; -// } -// STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_listen_obj, socketpool_socket_listen); + socketpool_socket_obj_t * sock = common_hal_socketpool_socket_accept(self, ip, &port); -// //| def accept(self) -> tuple: -// //| """Accept a connection on a listening socket of type SOCK_STREAM, -// //| creating a new socket of type SOCK_STREAM. -// //| Returns a tuple of (new_socket, remote_address)""" -// //| - -// STATIC mp_obj_t socketpool_socket_accept(mp_obj_t self_in) { -// // mod_network_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); + mp_obj_t tuple_contents[2]; + tuple_contents[0] = MP_OBJ_FROM_PTR(sock); + tuple_contents[1] = netutils_format_inet_addr(ip, port, NETUTILS_BIG); + return mp_obj_new_tuple(2, tuple_contents); +} +STATIC MP_DEFINE_CONST_FUN_OBJ_1(socketpool_socket_accept_obj, socketpool_socket_accept); -// // // create new socket object -// // // starts with empty NIC so that finaliser doesn't run close() method if accept() fails -// // mod_network_socket_obj_t *socket2 = m_new_obj_with_finaliser(mod_network_socket_obj_t); -// // socket2->base.type = &socket_type; -// // socket2->nic = MP_OBJ_NULL; -// // socket2->nic_type = NULL; +//| def bind(self, address: Tuple[str, int]) -> None: +//| """Bind a socket to an address +//| +//| :param ~tuple address: tuple of (remote_address, remote_port)""" +//| ... +//| +STATIC mp_obj_t socketpool_socket_bind(mp_obj_t self_in, mp_obj_t addr_in) { + socketpool_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); -// // // accept incoming connection -// // uint8_t ip[MOD_NETWORK_IPADDR_BUF_SIZE]; -// // mp_uint_t port; -// // int _errno; -// // if (self->nic_type->accept(self, socket2, ip, &port, &_errno) != 0) { -// // mp_raise_OSError(_errno); -// // } + mp_obj_t *addr_items; + mp_obj_get_array_fixed_n(addr_in, 2, &addr_items); -// // // new socket has valid state, so set the NIC to the same as parent -// // socket2->nic = self->nic; -// // socket2->nic_type = self->nic_type; + size_t hostlen; + const char* host = mp_obj_str_get_data(addr_items[0], &hostlen); + mp_int_t port = mp_obj_get_int(addr_items[1]); -// // // make the return value -// // mp_obj_tuple_t *client = MP_OBJ_TO_PTR(mp_obj_new_tuple(2, NULL)); -// // client->items[0] = MP_OBJ_FROM_PTR(socket2); -// // client->items[1] = netutils_format_inet_addr(ip, port, NETUTILS_BIG); + bool ok = common_hal_socketpool_socket_bind(self, host, hostlen, port); + if (!ok) { + mp_raise_ValueError(translate("Error: Failure to bind")); + } -// return mp_const_none; -// } -// STATIC MP_DEFINE_CONST_FUN_OBJ_1(socketpool_socket_accept_obj, socketpool_socket_accept); + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_bind_obj, socketpool_socket_bind); //| def close(self) -> None: //| """Closes this Socket and makes its resources available to its SocketPool.""" @@ -169,7 +124,6 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_1(socketpool_socket_close_obj, socketpool_socket_ //| :param ~tuple address: tuple of (remote_address, remote_port)""" //| ... //| - STATIC mp_obj_t socketpool_socket_connect(mp_obj_t self_in, mp_obj_t addr_in) { socketpool_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); @@ -189,45 +143,47 @@ STATIC mp_obj_t socketpool_socket_connect(mp_obj_t self_in, mp_obj_t addr_in) { } STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_connect_obj, socketpool_socket_connect); -//| def send(self, bytes: ReadableBuffer) -> int: -//| """Send some bytes to the connected remote address. -//| Suits sockets of type SOCK_STREAM +//| def listen(self, backlog: int) -> None: +//| """Set socket to listen for incoming connections //| -//| :param ~bytes bytes: some bytes to send""" +//| :param ~int backlog: length of backlog queue for waiting connetions""" //| ... //| - -STATIC mp_obj_t socketpool_socket_send(mp_obj_t self_in, mp_obj_t buf_in) { +STATIC mp_obj_t socketpool_socket_listen(mp_obj_t self_in, mp_obj_t backlog_in) { socketpool_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); - if (common_hal_socketpool_socket_get_closed(self)) { - // Bad file number. - mp_raise_OSError(MP_EBADF); - } - if (!common_hal_socketpool_socket_get_connected(self)) { - mp_raise_BrokenPipeError(); - } - mp_buffer_info_t bufinfo; - mp_get_buffer_raise(buf_in, &bufinfo, MP_BUFFER_READ); - mp_int_t ret = common_hal_socketpool_socket_send(self, bufinfo.buf, bufinfo.len); - if (ret == -1) { - mp_raise_BrokenPipeError(); - } - return mp_obj_new_int_from_uint(ret); -} -STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_send_obj, socketpool_socket_send); + int backlog = mp_obj_get_int(backlog_in); -// helper function for socket_recv and socket_recv_into to handle common operations of both -// STATIC mp_int_t _socket_recv_into(mod_network_socket_obj_t *sock, byte *buf, mp_int_t len) { -// mp_int_t ret = 0; -// // int _errno; -// // mp_int_t ret = sock->nic_type->recv(sock, buf, len, &_errno); -// // if (ret == -1) { -// // mp_raise_OSError(_errno); -// // } -// return ret; -// } + common_hal_socketpool_socket_listen(self, backlog); + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_listen_obj, socketpool_socket_listen); + +//| def recvfrom_into(self, buffer: WriteableBuffer) -> Tuple[int, Tuple[str, int]]: +//| """Reads some bytes from a remote address. +//| +//| Returns a tuple containing +//| * the number of bytes received into the given buffer +//| * a remote_address, which is a tuple of ip address and port number +//| +//| :param object buffer: buffer to read into""" +//| ... +//| +STATIC mp_obj_t socketpool_socket_recvfrom_into(mp_obj_t self_in, mp_obj_t data_in) { + socketpool_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); + mp_buffer_info_t bufinfo; + mp_get_buffer_raise(data_in, &bufinfo, MP_BUFFER_WRITE); + byte ip[4]; + mp_uint_t port; + mp_int_t ret = common_hal_socketpool_socket_recvfrom_into(self, + (byte*)bufinfo.buf, bufinfo.len, ip, &port); + mp_obj_t tuple_contents[2]; + tuple_contents[0] = mp_obj_new_int_from_uint(ret); + tuple_contents[1] = netutils_format_inet_addr(ip, port, NETUTILS_BIG); + return mp_obj_new_tuple(2, tuple_contents); +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_recvfrom_into_obj, socketpool_socket_recvfrom_into); //| def recv_into(self, buffer: WriteableBuffer, bufsize: int) -> int: //| """Reads some bytes from the connected remote address, writing @@ -243,17 +199,16 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_send_obj, socketpool_socket_s //| :param int bufsize: optionally, a maximum number of bytes to read.""" //| ... //| - STATIC mp_obj_t socketpool_socket_recv_into(size_t n_args, const mp_obj_t *args) { socketpool_socket_obj_t *self = MP_OBJ_TO_PTR(args[0]); if (common_hal_socketpool_socket_get_closed(self)) { // Bad file number. mp_raise_OSError(MP_EBADF); } - if (!common_hal_socketpool_socket_get_connected(self)) { - // not connected - mp_raise_OSError(MP_ENOTCONN); - } + // if (!common_hal_socketpool_socket_get_connected(self)) { + // // not connected + // mp_raise_OSError(MP_ENOTCONN); + // } mp_buffer_info_t bufinfo; mp_get_buffer_raise(args[1], &bufinfo, MP_BUFFER_WRITE); mp_int_t len = bufinfo.len; @@ -276,6 +231,32 @@ STATIC mp_obj_t socketpool_socket_recv_into(size_t n_args, const mp_obj_t *args) } STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(socketpool_socket_recv_into_obj, 2, 3, socketpool_socket_recv_into); +//| def send(self, bytes: ReadableBuffer) -> int: +//| """Send some bytes to the connected remote address. +//| Suits sockets of type SOCK_STREAM +//| +//| :param ~bytes bytes: some bytes to send""" +//| ... +//| +STATIC mp_obj_t socketpool_socket_send(mp_obj_t self_in, mp_obj_t buf_in) { + socketpool_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); + if (common_hal_socketpool_socket_get_closed(self)) { + // Bad file number. + mp_raise_OSError(MP_EBADF); + } + if (!common_hal_socketpool_socket_get_connected(self)) { + mp_raise_BrokenPipeError(); + } + mp_buffer_info_t bufinfo; + mp_get_buffer_raise(buf_in, &bufinfo, MP_BUFFER_READ); + mp_int_t ret = common_hal_socketpool_socket_send(self, bufinfo.buf, bufinfo.len); + if (ret == -1) { + mp_raise_BrokenPipeError(); + } + return mp_obj_new_int_from_uint(ret); +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_send_obj, socketpool_socket_send); + //| def sendto(self, bytes: ReadableBuffer, address: Tuple[str, int]) -> int: //| """Send some bytes to a specific address. //| Suits sockets of type SOCK_DGRAM @@ -284,7 +265,6 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(socketpool_socket_recv_into_obj, 2, 3 //| :param ~tuple address: tuple of (remote_address, remote_port)""" //| ... //| - STATIC mp_obj_t socketpool_socket_sendto(mp_obj_t self_in, mp_obj_t data_in, mp_obj_t addr_in) { socketpool_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); @@ -308,37 +288,28 @@ STATIC mp_obj_t socketpool_socket_sendto(mp_obj_t self_in, mp_obj_t data_in, mp_ } STATIC MP_DEFINE_CONST_FUN_OBJ_3(socketpool_socket_sendto_obj, socketpool_socket_sendto); -//| def recvfrom_into(self, buffer: WriteableBuffer) -> Tuple[int, Tuple[str, int]]: -//| """Reads some bytes from a remote address. +//| def setblocking(self, flag: bool) -> Optional[int]: +//| """Set the blocking behaviour of this socket. //| -//| Returns a tuple containing -//| * the number of bytes received into the given buffer -//| * a remote_address, which is a tuple of ip address and port number -//| -//| :param object buffer: buffer to read into""" +//| :param ~bool flag: False means non-blocking, True means block indefinitely.""" //| ... //| -STATIC mp_obj_t socketpool_socket_recvfrom_into(mp_obj_t self_in, mp_obj_t data_in) { +// method socket.setblocking(flag) +STATIC mp_obj_t socketpool_socket_setblocking(mp_obj_t self_in, mp_obj_t blocking) { socketpool_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); - mp_buffer_info_t bufinfo; - mp_get_buffer_raise(data_in, &bufinfo, MP_BUFFER_WRITE); - - byte ip[4]; - mp_uint_t port; - mp_int_t ret = common_hal_socketpool_socket_recvfrom_into(self, - (byte*)bufinfo.buf, bufinfo.len, ip, &port); - mp_obj_t tuple_contents[2]; - tuple_contents[0] = mp_obj_new_int_from_uint(ret); - tuple_contents[1] = netutils_format_inet_addr(ip, port, NETUTILS_BIG); - return mp_obj_new_tuple(2, tuple_contents); + if (mp_obj_is_true(blocking)) { + common_hal_socketpool_socket_settimeout(self, -1); + } else { + common_hal_socketpool_socket_settimeout(self, 0); + } + return mp_const_none; } -STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_recvfrom_into_obj, socketpool_socket_recvfrom_into); +STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_setblocking_obj, socketpool_socket_setblocking); // //| def setsockopt(self, level: int, optname: int, value: int) -> None: // //| """Sets socket options""" // //| ... // //| - // STATIC mp_obj_t socketpool_socket_setsockopt(size_t n_args, const mp_obj_t *args) { // // mod_network_socket_obj_t *self = MP_OBJ_TO_PTR(args[0]); @@ -368,13 +339,13 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_recvfrom_into_obj, socketpool // } // STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(socketpool_socket_setsockopt_obj, 4, 4, socketpool_socket_setsockopt); + //| def settimeout(self, value: int) -> None: //| """Set the timeout value for this socket. //| //| :param ~int value: timeout in seconds. 0 means non-blocking. None means block indefinitely.""" //| ... //| - STATIC mp_obj_t socketpool_socket_settimeout(mp_obj_t self_in, mp_obj_t timeout_in) { socketpool_socket_obj_t *self = MP_OBJ_TO_PTR(self_in); mp_uint_t timeout_ms; @@ -392,24 +363,6 @@ STATIC mp_obj_t socketpool_socket_settimeout(mp_obj_t self_in, mp_obj_t timeout_ } STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_settimeout_obj, socketpool_socket_settimeout); -// //| def setblocking(self, flag: bool) -> Optional[int]: -// //| """Set the blocking behaviour of this socket. -// //| -// //| :param ~bool flag: False means non-blocking, True means block indefinitely.""" -// //| ... -// //| - -// // method socket.setblocking(flag) -// STATIC mp_obj_t socketpool_socket_setblocking(mp_obj_t self_in, mp_obj_t blocking) { -// // if (mp_obj_is_true(blocking)) { -// // return socket_settimeout(self_in, mp_const_none); -// // } else { -// // return socket_settimeout(self_in, MP_OBJ_NEW_SMALL_INT(0)); -// // } -// return mp_const_none; -// } -// STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_setblocking_obj, socketpool_socket_setblocking); - //| def __hash__(self) -> int: //| """Returns a hash for the Socket.""" //| ... @@ -417,7 +370,7 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_2(socketpool_socket_settimeout_obj, socketpool_so STATIC mp_obj_t socketpool_socket_unary_op(mp_unary_op_t op, mp_obj_t self_in) { switch (op) { case MP_UNARY_OP_HASH: { - return MP_OBJ_NEW_SMALL_INT(common_hal_socketpool_socket_get_hash(MP_OBJ_TO_PTR(self_in))); + return mp_obj_id(self_in); } default: return MP_OBJ_NULL; // op not supported @@ -428,19 +381,19 @@ STATIC const mp_rom_map_elem_t socketpool_socket_locals_dict_table[] = { { MP_ROM_QSTR(MP_QSTR___enter__), MP_ROM_PTR(&default___enter___obj) }, { MP_ROM_QSTR(MP_QSTR___exit__), MP_ROM_PTR(&socketpool_socket___exit___obj) }, { MP_ROM_QSTR(MP_QSTR___del__), MP_ROM_PTR(&socketpool_socket_close_obj) }, - { MP_ROM_QSTR(MP_QSTR_close), MP_ROM_PTR(&socketpool_socket_close_obj) }, - // { MP_ROM_QSTR(MP_QSTR_bind), MP_ROM_PTR(&socketpool_socket_bind_obj) }, - // { MP_ROM_QSTR(MP_QSTR_listen), MP_ROM_PTR(&socketpool_socket_listen_obj) }, - // { MP_ROM_QSTR(MP_QSTR_accept), MP_ROM_PTR(&socketpool_socket_accept_obj) }, + { MP_ROM_QSTR(MP_QSTR_accept), MP_ROM_PTR(&socketpool_socket_accept_obj) }, + { MP_ROM_QSTR(MP_QSTR_bind), MP_ROM_PTR(&socketpool_socket_bind_obj) }, + { MP_ROM_QSTR(MP_QSTR_close), MP_ROM_PTR(&socketpool_socket_close_obj) }, { MP_ROM_QSTR(MP_QSTR_connect), MP_ROM_PTR(&socketpool_socket_connect_obj) }, - { MP_ROM_QSTR(MP_QSTR_send), MP_ROM_PTR(&socketpool_socket_send_obj) }, - { MP_ROM_QSTR(MP_QSTR_sendto), MP_ROM_PTR(&socketpool_socket_sendto_obj) }, + { MP_ROM_QSTR(MP_QSTR_listen), MP_ROM_PTR(&socketpool_socket_listen_obj) }, { MP_ROM_QSTR(MP_QSTR_recvfrom_into), MP_ROM_PTR(&socketpool_socket_recvfrom_into_obj) }, { MP_ROM_QSTR(MP_QSTR_recv_into), MP_ROM_PTR(&socketpool_socket_recv_into_obj) }, + { MP_ROM_QSTR(MP_QSTR_send), MP_ROM_PTR(&socketpool_socket_send_obj) }, + { MP_ROM_QSTR(MP_QSTR_sendto), MP_ROM_PTR(&socketpool_socket_sendto_obj) }, + { MP_ROM_QSTR(MP_QSTR_setblocking), MP_ROM_PTR(&socketpool_socket_setblocking_obj) }, // { MP_ROM_QSTR(MP_QSTR_setsockopt), MP_ROM_PTR(&socketpool_socket_setsockopt_obj) }, { MP_ROM_QSTR(MP_QSTR_settimeout), MP_ROM_PTR(&socketpool_socket_settimeout_obj) }, - // { MP_ROM_QSTR(MP_QSTR_setblocking), MP_ROM_PTR(&socketpool_socket_setblocking_obj) }, }; STATIC MP_DEFINE_CONST_DICT(socketpool_socket_locals_dict, socketpool_socket_locals_dict_table); diff --git a/shared-bindings/socketpool/Socket.h b/shared-bindings/socketpool/Socket.h index 54fbe59b2..637a7a214 100644 --- a/shared-bindings/socketpool/Socket.h +++ b/shared-bindings/socketpool/Socket.h @@ -31,17 +31,20 @@ extern const mp_obj_type_t socketpool_socket_type; -void common_hal_socketpool_socket_settimeout(socketpool_socket_obj_t* self, mp_uint_t timeout_ms); +socketpool_socket_obj_t * common_hal_socketpool_socket_accept(socketpool_socket_obj_t* self, uint8_t* ip, uint *port); +bool common_hal_socketpool_socket_bind(socketpool_socket_obj_t* self, const char* host, size_t hostlen, uint8_t port); +void common_hal_socketpool_socket_close(socketpool_socket_obj_t* self); bool common_hal_socketpool_socket_connect(socketpool_socket_obj_t* self, const char* host, size_t hostlen, mp_int_t port); -mp_uint_t common_hal_socketpool_socket_send(socketpool_socket_obj_t* self, const uint8_t* buf, mp_uint_t len); +bool common_hal_socketpool_socket_get_closed(socketpool_socket_obj_t* self); +bool common_hal_socketpool_socket_get_connected(socketpool_socket_obj_t* self); +mp_uint_t common_hal_socketpool_socket_get_timeout(socketpool_socket_obj_t* self); +bool common_hal_socketpool_socket_listen(socketpool_socket_obj_t* self, int backlog); +mp_uint_t common_hal_socketpool_socket_recvfrom_into(socketpool_socket_obj_t* self, + uint8_t* buf, mp_uint_t len, uint8_t* ip, uint *port); mp_uint_t common_hal_socketpool_socket_recv_into(socketpool_socket_obj_t* self, const uint8_t* buf, mp_uint_t len); +mp_uint_t common_hal_socketpool_socket_send(socketpool_socket_obj_t* self, const uint8_t* buf, mp_uint_t len); mp_uint_t common_hal_socketpool_socket_sendto(socketpool_socket_obj_t* self, const char* host, size_t hostlen, uint8_t port, const uint8_t* buf, mp_uint_t len); -mp_uint_t common_hal_socketpool_socket_recvfrom_into(socketpool_socket_obj_t* self, - uint8_t* buf, mp_uint_t len, uint8_t* ip, uint *port); -void common_hal_socketpool_socket_close(socketpool_socket_obj_t* self); -bool common_hal_socketpool_socket_get_closed(socketpool_socket_obj_t* self); -bool common_hal_socketpool_socket_get_connected(socketpool_socket_obj_t* self); -mp_uint_t common_hal_socketpool_socket_get_hash(socketpool_socket_obj_t* self); +void common_hal_socketpool_socket_settimeout(socketpool_socket_obj_t* self, mp_uint_t timeout_ms); #endif // MICROPY_INCLUDED_SHARED_BINDINGS_SOCKETPOOL_SOCKET_H diff --git a/shared-bindings/socketpool/SocketPool.c b/shared-bindings/socketpool/SocketPool.c index 73eeed265..6ff6d5f98 100644 --- a/shared-bindings/socketpool/SocketPool.c +++ b/shared-bindings/socketpool/SocketPool.c @@ -3,8 +3,7 @@ * * The MIT License (MIT) * - * SPDX-FileCopyrightText: Copyright (c) 2014 Damien P. George - * 2018 Nick Moore for Adafruit Industries + * Copyright (c) 2020 Scott Shawcroft for Adafruit Industries * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -62,14 +61,12 @@ STATIC mp_obj_t socketpool_socketpool_make_new(const mp_obj_type_t *type, size_t //| SOCK_STREAM: int //| SOCK_DGRAM: int //| SOCK_RAW: int -//| IPPROTO_TCP: int //| -//| def socket(self, family: int = AF_INET, type: int = SOCK_STREAM, proto: int = IPPROTO_TCP) -> socketpool.Socket: +//| def socket(self, family: int = AF_INET, type: int = SOCK_STREAM) -> socketpool.Socket: //| """Create a new socket //| //| :param ~int family: AF_INET or AF_INET6 -//| :param ~int type: SOCK_STREAM, SOCK_DGRAM or SOCK_RAW -//| :param ~int proto: IPPROTO_TCP, IPPROTO_UDP or IPPROTO_RAW (ignored)""" +//| :param ~int type: SOCK_STREAM, SOCK_DGRAM or SOCK_RAW""" //| ... //| diff --git a/shared-bindings/ssl/SSLContext.c b/shared-bindings/ssl/SSLContext.c index 9d4df7261..44e9e6bbf 100644 --- a/shared-bindings/ssl/SSLContext.c +++ b/shared-bindings/ssl/SSLContext.c @@ -51,7 +51,7 @@ STATIC mp_obj_t ssl_sslcontext_make_new(const mp_obj_type_t *type, size_t n_args return MP_OBJ_FROM_PTR(s); } -//| def wrap_socket(sock: socketpool.Socket, *, server_side: bool = False, server_hostname: Optional[str] = None) -> socketpool.Socket: +//| def wrap_socket(sock: socketpool.Socket, *, server_side: bool = False, server_hostname: Optional[str] = None) -> ssl.SSLSocket: //| """Wraps the socket into a socket-compatible class that handles SSL negotiation. //| The socket must be of type SOCK_STREAM.""" //| ... diff --git a/shared-bindings/ssl/SSLContext.h b/shared-bindings/ssl/SSLContext.h index f7f985af7..ad4d7e6a8 100644 --- a/shared-bindings/ssl/SSLContext.h +++ b/shared-bindings/ssl/SSLContext.h @@ -30,12 +30,13 @@ #include "common-hal/ssl/SSLContext.h" #include "shared-bindings/socketpool/Socket.h" +#include "shared-bindings/ssl/SSLSocket.h" extern const mp_obj_type_t ssl_sslcontext_type; void common_hal_ssl_sslcontext_construct(ssl_sslcontext_obj_t* self); -socketpool_socket_obj_t* common_hal_ssl_sslcontext_wrap_socket(ssl_sslcontext_obj_t* self, +ssl_sslsocket_obj_t* common_hal_ssl_sslcontext_wrap_socket(ssl_sslcontext_obj_t* self, socketpool_socket_obj_t* sock, bool server_side, const char* server_hostname); #endif // MICROPY_INCLUDED_SHARED_BINDINGS_SSL_SSLCONTEXT_H diff --git a/shared-bindings/ssl/SSLSocket.c b/shared-bindings/ssl/SSLSocket.c new file mode 100644 index 000000000..a937952a5 --- /dev/null +++ b/shared-bindings/ssl/SSLSocket.c @@ -0,0 +1,320 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2021 Lucian Copeland for Adafruit Industries + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#include "shared-bindings/ssl/SSLSocket.h" + +#include <stdio.h> +#include <string.h> + +#include "lib/utils/context_manager_helpers.h" +#include "py/objtuple.h" +#include "py/objlist.h" +#include "py/runtime.h" +#include "py/mperrno.h" + +#include "lib/netutils/netutils.h" + +//| class SSLSocket: +//| """Implements TLS security on a subset of `socketpool.Socket` functions. Cannot be created +//| directly. Instead, call `wrap_socket` on an existing socket object. +//| +//| Provides a subset of CPython's `ssl.SSLSocket` API. It only implements the versions of +//| recv that do not allocate bytes objects.""" +//| + +//| def __enter__(self) -> SSLSocket: +//| """No-op used by Context Managers.""" +//| ... +//| +// Provided by context manager helper. + +//| def __exit__(self) -> None: +//| """Automatically closes the Socket when exiting a context. See +//| :ref:`lifetime-and-contextmanagers` for more info.""" +//| ... +//| +STATIC mp_obj_t ssl_sslsocket___exit__(size_t n_args, const mp_obj_t *args) { + (void)n_args; + common_hal_ssl_sslsocket_close(args[0]); + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(ssl_sslsocket___exit___obj, 4, 4, ssl_sslsocket___exit__); + +//| def accept(self) -> Tuple[SSLSocket, Tuple[str, int]]: +//| """Accept a connection on a listening socket of type SOCK_STREAM, +//| creating a new socket of type SOCK_STREAM. +//| Returns a tuple of (new_socket, remote_address)""" +//| +STATIC mp_obj_t ssl_sslsocket_accept(mp_obj_t self_in) { + ssl_sslsocket_obj_t *self = MP_OBJ_TO_PTR(self_in); + uint8_t ip[4]; + uint port; + + ssl_sslsocket_obj_t * sslsock = common_hal_ssl_sslsocket_accept(self, ip, &port); + + mp_obj_t tuple_contents[2]; + tuple_contents[0] = MP_OBJ_FROM_PTR(sslsock); + tuple_contents[1] = netutils_format_inet_addr(ip, port, NETUTILS_BIG); + return mp_obj_new_tuple(2, tuple_contents); +} +STATIC MP_DEFINE_CONST_FUN_OBJ_1(ssl_sslsocket_accept_obj, ssl_sslsocket_accept); + +//| def bind(self, address: Tuple[str, int]) -> None: +//| """Bind a socket to an address +//| +//| :param ~tuple address: tuple of (remote_address, remote_port)""" +//| ... +//| +STATIC mp_obj_t ssl_sslsocket_bind(mp_obj_t self_in, mp_obj_t addr_in) { + ssl_sslsocket_obj_t *self = MP_OBJ_TO_PTR(self_in); + + mp_obj_t *addr_items; + mp_obj_get_array_fixed_n(addr_in, 2, &addr_items); + + size_t hostlen; + const char* host = mp_obj_str_get_data(addr_items[0], &hostlen); + mp_int_t port = mp_obj_get_int(addr_items[1]); + + bool ok = common_hal_ssl_sslsocket_bind(self, host, hostlen, port); + if (!ok) { + mp_raise_ValueError(translate("Error: Failure to bind")); + } + + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(ssl_sslsocket_bind_obj, ssl_sslsocket_bind); + +//| def close(self) -> None: +//| """Closes this Socket""" +//| +STATIC mp_obj_t ssl_sslsocket_close(mp_obj_t self_in) { + ssl_sslsocket_obj_t *self = MP_OBJ_TO_PTR(self_in); + common_hal_ssl_sslsocket_close(self); + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_1(ssl_sslsocket_close_obj, ssl_sslsocket_close); + +//| def connect(self, address: Tuple[str, int]) -> None: +//| """Connect a socket to a remote address +//| +//| :param ~tuple address: tuple of (remote_address, remote_port)""" +//| ... +//| +STATIC mp_obj_t ssl_sslsocket_connect(mp_obj_t self_in, mp_obj_t addr_in) { + ssl_sslsocket_obj_t *self = MP_OBJ_TO_PTR(self_in); + + mp_obj_t *addr_items; + mp_obj_get_array_fixed_n(addr_in, 2, &addr_items); + + size_t hostlen; + const char* host = mp_obj_str_get_data(addr_items[0], &hostlen); + mp_int_t port = mp_obj_get_int(addr_items[1]); + + bool ok = common_hal_ssl_sslsocket_connect(self, host, hostlen, port); + if (!ok) { + mp_raise_OSError(0); + } + + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(ssl_sslsocket_connect_obj, ssl_sslsocket_connect); + +//| def listen(self, backlog: int) -> None: +//| """Set socket to listen for incoming connections +//| +//| :param ~int backlog: length of backlog queue for waiting connetions""" +//| ... +//| +STATIC mp_obj_t ssl_sslsocket_listen(mp_obj_t self_in, mp_obj_t backlog_in) { + ssl_sslsocket_obj_t *self = MP_OBJ_TO_PTR(self_in); + + int backlog = mp_obj_get_int(backlog_in); + + common_hal_ssl_sslsocket_listen(self, backlog); + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(ssl_sslsocket_listen_obj, ssl_sslsocket_listen); + +//| def recv_into(self, buffer: WriteableBuffer, bufsize: int) -> int: +//| """Reads some bytes from the connected remote address, writing +//| into the provided buffer. If bufsize <= len(buffer) is given, +//| a maximum of bufsize bytes will be read into the buffer. If no +//| valid value is given for bufsize, the default is the length of +//| the given buffer. +//| +//| Suits sockets of type SOCK_STREAM +//| Returns an int of number of bytes read. +//| +//| :param bytearray buffer: buffer to receive into +//| :param int bufsize: optionally, a maximum number of bytes to read.""" +//| ... +//| +STATIC mp_obj_t ssl_sslsocket_recv_into(size_t n_args, const mp_obj_t *args) { + ssl_sslsocket_obj_t *self = MP_OBJ_TO_PTR(args[0]); + if (common_hal_ssl_sslsocket_get_closed(self)) { + // Bad file number. + mp_raise_OSError(MP_EBADF); + } + // if (!common_hal_ssl_sslsocket_get_connected(self)) { + // // not connected + // mp_raise_OSError(MP_ENOTCONN); + // } + mp_buffer_info_t bufinfo; + mp_get_buffer_raise(args[1], &bufinfo, MP_BUFFER_WRITE); + mp_int_t len = bufinfo.len; + if (n_args == 3) { + mp_int_t given_len = mp_obj_get_int(args[2]); + if (given_len > len) { + mp_raise_ValueError(translate("buffer too small for requested bytes")); + } + if (given_len > 0 && given_len < len) { + len = given_len; + } + } + + if (len == 0) { + return MP_OBJ_NEW_SMALL_INT(0); + } + + mp_int_t ret = common_hal_ssl_sslsocket_recv_into(self, (byte*)bufinfo.buf, len); + return mp_obj_new_int_from_uint(ret); +} +STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(ssl_sslsocket_recv_into_obj, 2, 3, ssl_sslsocket_recv_into); + +//| def send(self, bytes: ReadableBuffer) -> int: +//| """Send some bytes to the connected remote address. +//| Suits sockets of type SOCK_STREAM +//| +//| :param ~bytes bytes: some bytes to send""" +//| ... +//| +STATIC mp_obj_t ssl_sslsocket_send(mp_obj_t self_in, mp_obj_t buf_in) { + ssl_sslsocket_obj_t *self = MP_OBJ_TO_PTR(self_in); + if (common_hal_ssl_sslsocket_get_closed(self)) { + // Bad file number. + mp_raise_OSError(MP_EBADF); + } + if (!common_hal_ssl_sslsocket_get_connected(self)) { + mp_raise_BrokenPipeError(); + } + mp_buffer_info_t bufinfo; + mp_get_buffer_raise(buf_in, &bufinfo, MP_BUFFER_READ); + mp_int_t ret = common_hal_ssl_sslsocket_send(self, bufinfo.buf, bufinfo.len); + if (ret == -1) { + mp_raise_BrokenPipeError(); + } + return mp_obj_new_int_from_uint(ret); +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(ssl_sslsocket_send_obj, ssl_sslsocket_send); + +// //| def setsockopt(self, level: int, optname: int, value: int) -> None: +// //| """Sets socket options""" +// //| ... +// //| +// STATIC mp_obj_t ssl_sslsocket_setsockopt(size_t n_args, const mp_obj_t *args) { +// } +// STATIC MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(ssl_sslsocket_setsockopt_obj, 4, 4, ssl_sslsocket_setsockopt); + +//| def settimeout(self, value: int) -> None: +//| """Set the timeout value for this socket. +//| +//| :param ~int value: timeout in seconds. 0 means non-blocking. None means block indefinitely.""" +//| ... +//| +STATIC mp_obj_t ssl_sslsocket_settimeout(mp_obj_t self_in, mp_obj_t timeout_in) { + ssl_sslsocket_obj_t *self = MP_OBJ_TO_PTR(self_in); + mp_uint_t timeout_ms; + if (timeout_in == mp_const_none) { + timeout_ms = -1; + } else { + #if MICROPY_PY_BUILTINS_FLOAT + timeout_ms = 1000 * mp_obj_get_float(timeout_in); + #else + timeout_ms = 1000 * mp_obj_get_int(timeout_in); + #endif + } + common_hal_ssl_sslsocket_settimeout(self, timeout_ms); + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(ssl_sslsocket_settimeout_obj, ssl_sslsocket_settimeout); + +//| def setblocking(self, flag: bool) -> Optional[int]: +//| """Set the blocking behaviour of this socket. +//| +//| :param ~bool flag: False means non-blocking, True means block indefinitely.""" +//| ... +//| +// method socket.setblocking(flag) +STATIC mp_obj_t ssl_sslsocket_setblocking(mp_obj_t self_in, mp_obj_t blocking) { + ssl_sslsocket_obj_t *self = MP_OBJ_TO_PTR(self_in); + if (mp_obj_is_true(blocking)) { + common_hal_ssl_sslsocket_settimeout(self, -1); + } else { + common_hal_ssl_sslsocket_settimeout(self, 0); + } + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_2(ssl_sslsocket_setblocking_obj, ssl_sslsocket_setblocking); + +//| def __hash__(self) -> int: +//| """Returns a hash for the Socket.""" +//| ... +//| +STATIC mp_obj_t ssl_sslsocket_unary_op(mp_unary_op_t op, mp_obj_t self_in) { + switch (op) { + case MP_UNARY_OP_HASH: { + return mp_obj_id(self_in); + } + default: + return MP_OBJ_NULL; // op not supported + } +} + +STATIC const mp_rom_map_elem_t ssl_sslsocket_locals_dict_table[] = { + { MP_ROM_QSTR(MP_QSTR___enter__), MP_ROM_PTR(&default___enter___obj) }, + { MP_ROM_QSTR(MP_QSTR___exit__), MP_ROM_PTR(&ssl_sslsocket___exit___obj) }, + { MP_ROM_QSTR(MP_QSTR___del__), MP_ROM_PTR(&ssl_sslsocket_close_obj) }, + + { MP_ROM_QSTR(MP_QSTR_accept), MP_ROM_PTR(&ssl_sslsocket_accept_obj) }, + { MP_ROM_QSTR(MP_QSTR_bind), MP_ROM_PTR(&ssl_sslsocket_bind_obj) }, + { MP_ROM_QSTR(MP_QSTR_close), MP_ROM_PTR(&ssl_sslsocket_close_obj) }, + { MP_ROM_QSTR(MP_QSTR_connect), MP_ROM_PTR(&ssl_sslsocket_connect_obj) }, + { MP_ROM_QSTR(MP_QSTR_listen), MP_ROM_PTR(&ssl_sslsocket_listen_obj) }, + { MP_ROM_QSTR(MP_QSTR_recv_into), MP_ROM_PTR(&ssl_sslsocket_recv_into_obj) }, + { MP_ROM_QSTR(MP_QSTR_send), MP_ROM_PTR(&ssl_sslsocket_send_obj) }, + { MP_ROM_QSTR(MP_QSTR_setblocking), MP_ROM_PTR(&ssl_sslsocket_setblocking_obj) }, + // { MP_ROM_QSTR(MP_QSTR_setsockopt), MP_ROM_PTR(&ssl_sslsocket_setsockopt_obj) }, + { MP_ROM_QSTR(MP_QSTR_settimeout), MP_ROM_PTR(&ssl_sslsocket_settimeout_obj) }, +}; + +STATIC MP_DEFINE_CONST_DICT(ssl_sslsocket_locals_dict, ssl_sslsocket_locals_dict_table); + +const mp_obj_type_t ssl_sslsocket_type = { + { &mp_type_type }, + .name = MP_QSTR_SSLSocket, + .locals_dict = (mp_obj_dict_t*)&ssl_sslsocket_locals_dict, + .unary_op = ssl_sslsocket_unary_op, +}; diff --git a/shared-bindings/ssl/SSLSocket.h b/shared-bindings/ssl/SSLSocket.h new file mode 100644 index 000000000..b1f2c513d --- /dev/null +++ b/shared-bindings/ssl/SSLSocket.h @@ -0,0 +1,45 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2020 Lucian Copeland for Adafruit Industries + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#ifndef MICROPY_INCLUDED_SHARED_BINDINGS_SSL_SSLSOCKET_H +#define MICROPY_INCLUDED_SHARED_BINDINGS_SSL_SSLSOCKET_H + +#include "common-hal/ssl/SSLSocket.h" + +extern const mp_obj_type_t ssl_sslsocket_type; + +ssl_sslsocket_obj_t * common_hal_ssl_sslsocket_accept(ssl_sslsocket_obj_t* self, uint8_t* ip, uint *port); +bool common_hal_ssl_sslsocket_bind(ssl_sslsocket_obj_t* self, const char* host, size_t hostlen, uint8_t port); +void common_hal_ssl_sslsocket_close(ssl_sslsocket_obj_t* self); +bool common_hal_ssl_sslsocket_connect(ssl_sslsocket_obj_t* self, const char* host, size_t hostlen, mp_int_t port); +bool common_hal_ssl_sslsocket_get_closed(ssl_sslsocket_obj_t* self); +bool common_hal_ssl_sslsocket_get_connected(ssl_sslsocket_obj_t* self); +bool common_hal_ssl_sslsocket_listen(ssl_sslsocket_obj_t* self, int backlog); +mp_uint_t common_hal_ssl_sslsocket_recv_into(ssl_sslsocket_obj_t* self, const uint8_t* buf, mp_uint_t len); +mp_uint_t common_hal_ssl_sslsocket_send(ssl_sslsocket_obj_t* self, const uint8_t* buf, mp_uint_t len); +void common_hal_ssl_sslsocket_settimeout(ssl_sslsocket_obj_t* self, mp_uint_t timeout_ms); + +#endif // MICROPY_INCLUDED_SHARED_BINDINGS_SSL_SSLSOCKET_H diff --git a/shared-bindings/support_matrix.rst b/shared-bindings/support_matrix.rst index 1b75e0256..a2fb7987d 100644 --- a/shared-bindings/support_matrix.rst +++ b/shared-bindings/support_matrix.rst @@ -1,7 +1,7 @@ .. _module-support-matrix: -Support Matrix -=============== +Module Support Matrix - Which Modules Are Available on Which Boards +=================================================================== The following table lists the available built-in modules for each CircuitPython capable board. diff --git a/shared-module/_eve/__init__.c b/shared-module/_eve/__init__.c index d95c777dc..579729d42 100644 --- a/shared-module/_eve/__init__.c +++ b/shared-module/_eve/__init__.c @@ -226,8 +226,9 @@ void common_hal__eve_Jump(common_hal__eve_t *eve, uint32_t dest) { } -void common_hal__eve_LineWidth(common_hal__eve_t *eve, uint32_t width) { - C4(eve, ((14 << 24) | ((width & 4095)))); +void common_hal__eve_LineWidth(common_hal__eve_t *eve, mp_float_t width) { + int16_t iw = (int)(8 * width); + C4(eve, ((14 << 24) | ((iw & 4095)))); } @@ -246,8 +247,9 @@ void common_hal__eve_PaletteSource(common_hal__eve_t *eve, uint32_t addr) { } -void common_hal__eve_PointSize(common_hal__eve_t *eve, uint32_t size) { - C4(eve, ((13 << 24) | ((size & 8191)))); +void common_hal__eve_PointSize(common_hal__eve_t *eve, mp_float_t size) { + int16_t is = (int)(8 * size); + C4(eve, ((13 << 24) | ((is & 8191)))); } @@ -301,13 +303,15 @@ void common_hal__eve_Tag(common_hal__eve_t *eve, uint32_t s) { } -void common_hal__eve_VertexTranslateX(common_hal__eve_t *eve, uint32_t x) { - C4(eve, ((43 << 24) | (((x) & 131071)))); +void common_hal__eve_VertexTranslateX(common_hal__eve_t *eve, mp_float_t x) { + int16_t ix = (int)(16 * x); + C4(eve, ((43 << 24) | (ix & 131071))); } -void common_hal__eve_VertexTranslateY(common_hal__eve_t *eve, uint32_t y) { - C4(eve, ((44 << 24) | (((y) & 131071)))); +void common_hal__eve_VertexTranslateY(common_hal__eve_t *eve, mp_float_t y) { + int16_t iy = (int)(16 * y); + C4(eve, ((44 << 24) | (iy & 131071))); } diff --git a/shared-module/adafruit_bus_device/I2CDevice.c b/shared-module/adafruit_bus_device/I2CDevice.c index 83abe80d6..6d80cf599 100644 --- a/shared-module/adafruit_bus_device/I2CDevice.c +++ b/shared-module/adafruit_bus_device/I2CDevice.c @@ -31,48 +31,60 @@ #include "py/runtime.h" #include "lib/utils/interrupt_char.h" -void common_hal_adafruit_bus_device_i2cdevice_construct(adafruit_bus_device_i2cdevice_obj_t *self, busio_i2c_obj_t *i2c, uint8_t device_address) { +void common_hal_adafruit_bus_device_i2cdevice_construct(adafruit_bus_device_i2cdevice_obj_t *self, mp_obj_t *i2c, uint8_t device_address) { self->i2c = i2c; self->device_address = device_address; } void common_hal_adafruit_bus_device_i2cdevice_lock(adafruit_bus_device_i2cdevice_obj_t *self) { - bool success = common_hal_busio_i2c_try_lock(self->i2c); + mp_obj_t dest[2]; + mp_load_method(self->i2c, MP_QSTR_try_lock, dest); - while (!success) { + mp_obj_t success = mp_call_method_n_kw(0, 0, dest); + + while (!mp_obj_is_true(success)) { RUN_BACKGROUND_TASKS; if (mp_hal_is_interrupted()) { break; } - success = common_hal_busio_i2c_try_lock(self->i2c); + success = mp_call_method_n_kw(0, 0, dest); } } void common_hal_adafruit_bus_device_i2cdevice_unlock(adafruit_bus_device_i2cdevice_obj_t *self) { - common_hal_busio_i2c_unlock(self->i2c); -} - -uint8_t common_hal_adafruit_bus_device_i2cdevice_readinto(adafruit_bus_device_i2cdevice_obj_t *self, mp_obj_t buffer, size_t length) { - return common_hal_busio_i2c_read(self->i2c, self->device_address, buffer, length); -} - -uint8_t common_hal_adafruit_bus_device_i2cdevice_write(adafruit_bus_device_i2cdevice_obj_t *self, mp_obj_t buffer, size_t length, bool transmit_stop_bit) { - return common_hal_busio_i2c_write(self->i2c, self->device_address, buffer, length, transmit_stop_bit); + mp_obj_t dest[2]; + mp_load_method(self->i2c, MP_QSTR_unlock, dest); + mp_call_method_n_kw(0, 0, dest); } void common_hal_adafruit_bus_device_i2cdevice_probe_for_device(adafruit_bus_device_i2cdevice_obj_t *self) { common_hal_adafruit_bus_device_i2cdevice_lock(self); - mp_buffer_info_t bufinfo; - mp_obj_t buffer = mp_obj_new_bytearray_of_zeros(1); + mp_buffer_info_t write_bufinfo; + mp_obj_t write_buffer = mp_obj_new_bytearray_of_zeros(0); + mp_get_buffer_raise(write_buffer, &write_bufinfo, MP_BUFFER_READ); - mp_get_buffer_raise(buffer, &bufinfo, MP_BUFFER_WRITE); + mp_obj_t dest[4]; - uint8_t status = common_hal_adafruit_bus_device_i2cdevice_readinto(self, (uint8_t*)bufinfo.buf, 1); - if (status != 0) { + /* catch exceptions that may be thrown while probing for the device */ + nlr_buf_t nlr; + if (nlr_push(&nlr) == 0) { + mp_load_method(self->i2c, MP_QSTR_writeto, dest); + dest[2] = MP_OBJ_NEW_SMALL_INT(self->device_address); + dest[3] = write_buffer; + mp_call_method_n_kw(2, 0, dest); + nlr_pop(); + } else { common_hal_adafruit_bus_device_i2cdevice_unlock(self); - mp_raise_ValueError_varg(translate("No I2C device at address: %x"), self->device_address); + + if (mp_obj_is_subclass_fast(MP_OBJ_FROM_PTR(((mp_obj_base_t*)nlr.ret_val)->type), MP_OBJ_FROM_PTR(&mp_type_OSError))) { + mp_raise_ValueError_varg(translate("No I2C device at address: %x"), self->device_address); + } + else { + /* In case we receive an unrelated exception pass it up */ + nlr_raise(MP_OBJ_FROM_PTR(nlr.ret_val)); + } } common_hal_adafruit_bus_device_i2cdevice_unlock(self); diff --git a/shared-module/adafruit_bus_device/I2CDevice.h b/shared-module/adafruit_bus_device/I2CDevice.h index d06adb9f5..b76bafb2c 100644 --- a/shared-module/adafruit_bus_device/I2CDevice.h +++ b/shared-module/adafruit_bus_device/I2CDevice.h @@ -32,7 +32,7 @@ typedef struct { mp_obj_base_t base; - busio_i2c_obj_t *i2c; + mp_obj_t *i2c; uint8_t device_address; } adafruit_bus_device_i2cdevice_obj_t; diff --git a/shared-module/adafruit_bus_device/SPIDevice.c b/shared-module/adafruit_bus_device/SPIDevice.c index e489fc7c0..5c1a69b12 100644 --- a/shared-module/adafruit_bus_device/SPIDevice.c +++ b/shared-module/adafruit_bus_device/SPIDevice.c @@ -41,7 +41,7 @@ void common_hal_adafruit_bus_device_spidevice_construct(adafruit_bus_device_spid self->chip_select = cs; } -void common_hal_adafruit_bus_device_spidevice_enter(adafruit_bus_device_spidevice_obj_t *self) { +mp_obj_t common_hal_adafruit_bus_device_spidevice_enter(adafruit_bus_device_spidevice_obj_t *self) { bool success = false; while (!success) { success = common_hal_busio_spi_try_lock(self->spi); @@ -54,6 +54,7 @@ void common_hal_adafruit_bus_device_spidevice_enter(adafruit_bus_device_spidevic if (self->chip_select != MP_OBJ_NULL) { common_hal_digitalio_digitalinout_set_value(MP_OBJ_TO_PTR(self->chip_select), false); } + return self->spi; } void common_hal_adafruit_bus_device_spidevice_exit(adafruit_bus_device_spidevice_obj_t *self) { @@ -83,3 +84,7 @@ void common_hal_adafruit_bus_device_spidevice_exit(adafruit_bus_device_spidevice common_hal_busio_spi_unlock(self->spi); } + +mp_obj_t common_hal_adafruit_bus_device_spidevice_get_spi(adafruit_bus_device_spidevice_obj_t *self) { + return self->spi; +} diff --git a/shared-module/rgbmatrix/RGBMatrix.c b/shared-module/rgbmatrix/RGBMatrix.c index a09767b62..b8db0d893 100644 --- a/shared-module/rgbmatrix/RGBMatrix.c +++ b/shared-module/rgbmatrix/RGBMatrix.c @@ -42,7 +42,7 @@ extern Protomatter_core *_PM_protoPtr; -void common_hal_rgbmatrix_rgbmatrix_construct(rgbmatrix_rgbmatrix_obj_t *self, int width, int bit_depth, uint8_t rgb_count, uint8_t *rgb_pins, uint8_t addr_count, uint8_t *addr_pins, uint8_t clock_pin, uint8_t latch_pin, uint8_t oe_pin, bool doublebuffer, mp_obj_t framebuffer, void *timer) { +void common_hal_rgbmatrix_rgbmatrix_construct(rgbmatrix_rgbmatrix_obj_t *self, int width, int bit_depth, uint8_t rgb_count, uint8_t *rgb_pins, uint8_t addr_count, uint8_t *addr_pins, uint8_t clock_pin, uint8_t latch_pin, uint8_t oe_pin, bool doublebuffer, mp_obj_t framebuffer, int8_t tile, bool serpentine, void *timer) { self->width = width; self->bit_depth = bit_depth; self->rgb_count = rgb_count; @@ -53,6 +53,8 @@ void common_hal_rgbmatrix_rgbmatrix_construct(rgbmatrix_rgbmatrix_obj_t *self, i self->oe_pin = oe_pin; self->latch_pin = latch_pin; self->doublebuffer = doublebuffer; + self->tile = tile; + self->serpentine = serpentine; self->timer = timer ? timer : common_hal_rgbmatrix_timer_allocate(); if (self->timer == NULL) { @@ -60,7 +62,7 @@ void common_hal_rgbmatrix_rgbmatrix_construct(rgbmatrix_rgbmatrix_obj_t *self, i } self->width = width; - self->bufsize = 2 * width * rgb_count / 3 * (1 << addr_count); + self->bufsize = 2 * width * common_hal_rgbmatrix_rgbmatrix_get_height(self); common_hal_rgbmatrix_rgbmatrix_reconstruct(self, framebuffer); } @@ -95,7 +97,8 @@ void common_hal_rgbmatrix_rgbmatrix_reconstruct(rgbmatrix_rgbmatrix_obj_t* self, self->rgb_count/6, self->rgb_pins, self->addr_count, self->addr_pins, self->clock_pin, self->latch_pin, self->oe_pin, - self->doublebuffer, self->timer); + self->doublebuffer, self->serpentine ? -self->tile : self->tile, + self->timer); if (stat == PROTOMATTER_OK) { _PM_protoPtr = &self->protomatter; @@ -209,7 +212,7 @@ int common_hal_rgbmatrix_rgbmatrix_get_width(rgbmatrix_rgbmatrix_obj_t* self) { } int common_hal_rgbmatrix_rgbmatrix_get_height(rgbmatrix_rgbmatrix_obj_t* self) { - int computed_height = (self->rgb_count / 3) << (self->addr_count); + int computed_height = (self->rgb_count / 3) * (1 << (self->addr_count)) * self->tile; return computed_height; } diff --git a/shared-module/rgbmatrix/RGBMatrix.h b/shared-module/rgbmatrix/RGBMatrix.h index 6dbc6fd41..4a0e9235e 100644 --- a/shared-module/rgbmatrix/RGBMatrix.h +++ b/shared-module/rgbmatrix/RGBMatrix.h @@ -44,4 +44,6 @@ typedef struct { bool core_is_initialized; bool paused; bool doublebuffer; + bool serpentine; + int8_t tile; } rgbmatrix_rgbmatrix_obj_t; diff --git a/supervisor/shared/background_callback.c b/supervisor/shared/background_callback.c index 288c9a4df..68a0a9667 100644 --- a/supervisor/shared/background_callback.c +++ b/supervisor/shared/background_callback.c @@ -33,7 +33,7 @@ #include "supervisor/shared/tick.h" #include "shared-bindings/microcontroller/__init__.h" -STATIC volatile background_callback_t *callback_head, *callback_tail; +STATIC volatile background_callback_t * volatile callback_head, * volatile callback_tail; #define CALLBACK_CRITICAL_BEGIN (common_hal_mcu_disable_interrupts()) #define CALLBACK_CRITICAL_END (common_hal_mcu_enable_interrupts()) @@ -50,7 +50,6 @@ void background_callback_add_core(background_callback_t *cb) { cb->prev = (background_callback_t*)callback_tail; if (callback_tail) { callback_tail->next = cb; - cb->prev = (background_callback_t*)callback_tail; } if (!callback_head) { callback_head = cb; diff --git a/supervisor/shared/serial.c b/supervisor/shared/serial.c index 303f89e75..b9feb04f2 100644 --- a/supervisor/shared/serial.c +++ b/supervisor/shared/serial.c @@ -47,6 +47,10 @@ busio_uart_obj_t debug_uart; byte buf_array[64]; #endif +#if CIRCUITPY_USB_VENDOR +bool tud_vendor_connected(void); +#endif + void serial_early_init(void) { #if defined(DEBUG_UART_TX) && defined(DEBUG_UART_RX) debug_uart.base.type = &busio_uart_type; @@ -66,6 +70,12 @@ void serial_init(void) { } bool serial_connected(void) { +#if CIRCUITPY_USB_VENDOR + if (tud_vendor_connected()) { + return true; + } +#endif + #if defined(DEBUG_UART_TX) && defined(DEBUG_UART_RX) return true; #else @@ -74,6 +84,14 @@ bool serial_connected(void) { } char serial_read(void) { +#if CIRCUITPY_USB_VENDOR + if (tud_vendor_connected() && tud_vendor_available() > 0) { + char tiny_buffer; + tud_vendor_read(&tiny_buffer, 1); + return tiny_buffer; + } +#endif + #if defined(DEBUG_UART_TX) && defined(DEBUG_UART_RX) if (tud_cdc_connected() && tud_cdc_available() > 0) { return (char) tud_cdc_read_char(); @@ -88,6 +106,12 @@ char serial_read(void) { } bool serial_bytes_available(void) { +#if CIRCUITPY_USB_VENDOR + if (tud_vendor_connected() && tud_vendor_available() > 0) { + return true; + } +#endif + #if defined(DEBUG_UART_TX) && defined(DEBUG_UART_RX) return common_hal_busio_uart_rx_characters_available(&debug_uart) || (tud_cdc_available() > 0); #else @@ -104,6 +128,12 @@ void serial_write_substring(const char* text, uint32_t length) { common_hal_terminalio_terminal_write(&supervisor_terminal, (const uint8_t*) text, length, &errcode); #endif +#if CIRCUITPY_USB_VENDOR + if (tud_vendor_connected()) { + tud_vendor_write(text, length); + } +#endif + uint32_t count = 0; while (count < length && tud_cdc_connected()) { count += tud_cdc_write(text + count, length - count); diff --git a/supervisor/shared/usb/tusb_config.h b/supervisor/shared/usb/tusb_config.h index 15d9fabaf..d3a35f537 100644 --- a/supervisor/shared/usb/tusb_config.h +++ b/supervisor/shared/usb/tusb_config.h @@ -68,6 +68,7 @@ #define CFG_TUD_MSC 1 #define CFG_TUD_HID CIRCUITPY_USB_HID #define CFG_TUD_MIDI CIRCUITPY_USB_MIDI +#define CFG_TUD_VENDOR CIRCUITPY_USB_VENDOR #define CFG_TUD_CUSTOM_CLASS 0 /*------------------------------------------------------------------*/ diff --git a/supervisor/shared/usb/usb.c b/supervisor/shared/usb/usb.c index 07c6aee6c..43564d5d5 100644 --- a/supervisor/shared/usb/usb.c +++ b/supervisor/shared/usb/usb.c @@ -37,6 +37,19 @@ #include "tusb.h" +#if CIRCUITPY_USB_VENDOR +#include "genhdr/autogen_usb_descriptor.h" + +// The WebUSB support being conditionally added to this file is based on the +// tinyusb demo examples/device/webusb_serial. + +extern const tusb_desc_webusb_url_t desc_webusb_url; + +static bool web_serial_connected = false; +#endif + + + // Serial number as hex characters. This writes directly to the USB // descriptor. extern uint16_t usb_serial_number[1 + COMMON_HAL_MCU_PROCESSOR_UID_LENGTH * 2]; @@ -98,9 +111,14 @@ static void usb_background_do(void* unused) { usb_background(); } +void usb_background_schedule(void) +{ + background_callback_add(&usb_callback, usb_background_do, NULL); +} + void usb_irq_handler(void) { tud_int_handler(0); - background_callback_add(&usb_callback, usb_background_do, NULL); + usb_background_schedule(); } //--------------------------------------------------------------------+ @@ -145,6 +163,62 @@ void tud_cdc_line_state_cb(uint8_t itf, bool dtr, bool rts) { } } +#if CIRCUITPY_USB_VENDOR +//--------------------------------------------------------------------+ +// WebUSB use vendor class +//--------------------------------------------------------------------+ + +bool tud_vendor_connected(void) +{ + return web_serial_connected; +} + +// Invoked when a control transfer occurred on an interface of this class +// Driver response accordingly to the request and the transfer stage (setup/data/ack) +// return false to stall control endpoint (e.g unsupported request) +bool tud_vendor_control_xfer_cb(uint8_t rhport, uint8_t stage, tusb_control_request_t const * request) +{ + // nothing to with DATA & ACK stage + if (stage != CONTROL_STAGE_SETUP ) return true; + + switch (request->bRequest) + { + case VENDOR_REQUEST_WEBUSB: + // match vendor request in BOS descriptor + // Get landing page url + return tud_control_xfer(rhport, request, (void*) &desc_webusb_url, desc_webusb_url.bLength); + + case VENDOR_REQUEST_MICROSOFT: + if ( request->wIndex == 7 ) + { + // Get Microsoft OS 2.0 compatible descriptor + uint16_t total_len; + memcpy(&total_len, desc_ms_os_20+8, 2); + + return tud_control_xfer(rhport, request, (void*) desc_ms_os_20, total_len); + } else + { + return false; + } + + case 0x22: + // Webserial simulate the CDC_REQUEST_SET_CONTROL_LINE_STATE (0x22) to + // connect and disconnect. + web_serial_connected = (request->wValue != 0); + + // response with status OK + return tud_control_status(rhport, request); + + default: + // stall unknown request + return false; + } + + return true; +} +#endif CIRCUITPY_USB_VENDOR + + #if MICROPY_KBD_EXCEPTION /** diff --git a/supervisor/supervisor.mk b/supervisor/supervisor.mk index a59e99e3d..f559e004e 100644 --- a/supervisor/supervisor.mk +++ b/supervisor/supervisor.mk @@ -102,6 +102,11 @@ else shared-module/usb_midi/PortOut.c endif + ifeq ($(CIRCUITPY_USB_VENDOR), 1) + SRC_SUPERVISOR += \ + lib/tinyusb/src/class/vendor/vendor_device.c + endif + CFLAGS += -DUSB_AVAILABLE endif @@ -119,6 +124,12 @@ ifndef USB_INTERFACE_NAME USB_INTERFACE_NAME = "CircuitPython" endif +# In the following URL, don't include the https:// prefix. +# It gets added automatically. +ifndef USB_WEBUSB_URL +USB_WEBUSB_URL = "circuitpython.org" +endif + USB_DEVICES_COMPUTED := CDC,MSC ifeq ($(CIRCUITPY_USB_MIDI),1) USB_DEVICES_COMPUTED := $(USB_DEVICES_COMPUTED),AUDIO @@ -126,6 +137,9 @@ endif ifeq ($(CIRCUITPY_USB_HID),1) USB_DEVICES_COMPUTED := $(USB_DEVICES_COMPUTED),HID endif +ifeq ($(CIRCUITPY_USB_VENDOR),1) +USB_DEVICES_COMPUTED := $(USB_DEVICES_COMPUTED),VENDOR +endif USB_DEVICES ?= "$(USB_DEVICES_COMPUTED)" ifndef USB_HID_DEVICES @@ -198,6 +212,12 @@ USB_DESCRIPTOR_ARGS = \ --output_c_file $(BUILD)/autogen_usb_descriptor.c\ --output_h_file $(BUILD)/genhdr/autogen_usb_descriptor.h +ifeq ($(CIRCUITPY_USB_VENDOR), 1) +USB_DESCRIPTOR_ARGS += \ + --vendor_ep_num_out 0 --vendor_ep_num_in 0 \ + --webusb_url $(USB_WEBUSB_URL) +endif + ifeq ($(USB_RENUMBER_ENDPOINTS), 0) USB_DESCRIPTOR_ARGS += --no-renumber_endpoints endif diff --git a/supervisor/usb.h b/supervisor/usb.h index ccb35470c..1c709926a 100644 --- a/supervisor/usb.h +++ b/supervisor/usb.h @@ -35,6 +35,9 @@ // it may be necessary to call it directly. void usb_background(void); +// Schedule usb background +void usb_background_schedule(void); + // Ports must call this from their particular USB IRQ handler void usb_irq_handler(void); diff --git a/tools/build_board_info.py b/tools/build_board_info.py index 7b556ee5d..70d5e2bc7 100644 --- a/tools/build_board_info.py +++ b/tools/build_board_info.py @@ -271,6 +271,7 @@ def generate_download_info(): info = current_info[board] for version in info["versions"]: previous_releases.add(version["version"]) + previous_languages.update(version["languages"]) if version["stable"] == new_stable or ( new_stable and version["version"].startswith(this_version) ): diff --git a/tools/gen_display_resources.py b/tools/gen_display_resources.py index 6657b6a27..141e6ee2a 100644 --- a/tools/gen_display_resources.py +++ b/tools/gen_display_resources.py @@ -8,8 +8,8 @@ import os import struct import sys -sys.path.append("bitmap_font") -sys.path.append("../../tools/bitmap_font") +sys.path.insert(0, "bitmap_font") +sys.path.insert(0, "../../tools/bitmap_font") from adafruit_bitmap_font import bitmap_font diff --git a/tools/gen_usb_descriptor.py b/tools/gen_usb_descriptor.py index 672f09c88..80dddeb00 100644 --- a/tools/gen_usb_descriptor.py +++ b/tools/gen_usb_descriptor.py @@ -13,7 +13,7 @@ from adafruit_usb_descriptor import audio, audio10, cdc, hid, midi, msc, standar import hid_report_descriptors DEFAULT_INTERFACE_NAME = 'CircuitPython' -ALL_DEVICES='CDC,MSC,AUDIO,HID' +ALL_DEVICES='CDC,MSC,AUDIO,HID,VENDOR' ALL_DEVICES_SET=frozenset(ALL_DEVICES.split(',')) DEFAULT_DEVICES='CDC,MSC,AUDIO,HID' @@ -22,6 +22,9 @@ ALL_HID_DEVICES_SET=frozenset(ALL_HID_DEVICES.split(',')) # Digitizer works on Linux but conflicts with mouse, so omit it. DEFAULT_HID_DEVICES='KEYBOARD,MOUSE,CONSUMER,GAMEPAD' +# In the following URL, don't include the https:// because that prefix gets added automatically +DEFAULT_WEBUSB_URL = 'circuitpython.org' # In the future, this may become a specific landing page + parser = argparse.ArgumentParser(description='Generate USB descriptors.') parser.add_argument('--highspeed', default=False, action='store_true', help='descriptor for highspeed device') @@ -62,6 +65,13 @@ parser.add_argument('--midi_ep_num_out', type=int, default=0, help='endpoint number of MIDI OUT') parser.add_argument('--midi_ep_num_in', type=int, default=0, help='endpoint number of MIDI IN') +parser.add_argument('--webusb_url', type=str, + help='The URL to include in the WebUSB URL Descriptor', + default=DEFAULT_WEBUSB_URL) +parser.add_argument('--vendor_ep_num_out', type=int, default=0, + help='endpoint number of VENDOR OUT') +parser.add_argument('--vendor_ep_num_in', type=int, default=0, + help='endpoint number of VENDOR IN') parser.add_argument('--max_ep', type=int, default=0, help='total number of endpoints available') parser.add_argument('--output_c_file', type=argparse.FileType('w', encoding='UTF-8'), required=True) @@ -89,21 +99,27 @@ if not args.renumber_endpoints: if 'MSC' in args.devices: if args.msc_ep_num_out == 0: raise ValueError("MSC endpoint OUT number must not be 0") - elif args.msc_ep_num_in == 0: + elif args.msc_ep_num_in == 0: raise ValueError("MSC endpoint IN number must not be 0") if 'HID' in args.devices: if args.args.hid_ep_num_out == 0: raise ValueError("HID endpoint OUT number must not be 0") - elif args.hid_ep_num_in == 0: + elif args.hid_ep_num_in == 0: raise ValueError("HID endpoint IN number must not be 0") if 'AUDIO' in args.devices: if args.args.midi_ep_num_out == 0: raise ValueError("MIDI endpoint OUT number must not be 0") - elif args.midi_ep_num_in == 0: + elif args.midi_ep_num_in == 0: raise ValueError("MIDI endpoint IN number must not be 0") + if 'VENDOR' in args.devices: + if args.vendor_ep_num_out == 0: + raise ValueError("VENDOR endpoint OUT number must not be 0") + elif args.vendor_ep_num_in == 0: + raise ValueError("VENDOR endpoint IN number must not be 0") + class StringIndex: """Assign a monotonically increasing index to each unique string. Start with 0.""" string_to_index = {} @@ -359,6 +375,35 @@ audio_control_interface = standard.InterfaceDescriptor( # Audio streaming interfaces must occur before MIDI ones. audio_interfaces = [audio_control_interface] + cs_ac_interface.audio_streaming_interfaces + cs_ac_interface.midi_streaming_interfaces +# Vendor-specific interface, for example WebUSB +vendor_endpoint_in_descriptor = standard.EndpointDescriptor( + description="VENDOR in", + bEndpointAddress=args.vendor_ep_num_in | standard.EndpointDescriptor.DIRECTION_IN, + bmAttributes=standard.EndpointDescriptor.TYPE_BULK, + bInterval=16) + +vendor_endpoint_out_descriptor = standard.EndpointDescriptor( + description="VENDOR out", + bEndpointAddress=args.vendor_ep_num_out | standard.EndpointDescriptor.DIRECTION_OUT, + bmAttributes=standard.EndpointDescriptor.TYPE_BULK, + bInterval=16) + +# We do the following conditionally to avoid adding unused entries to the StringIndex table +if 'VENDOR' in args.devices: + vendor_interface = standard.InterfaceDescriptor( + description="VENDOR", + bInterfaceClass=0xff, # Vendor-specific + bInterfaceSubClass=0x00, + bInterfaceProtocol=0x00, + iInterface=StringIndex.index("{} VENDOR".format(args.interface_name)), + subdescriptors=[ + vendor_endpoint_in_descriptor, + vendor_endpoint_out_descriptor, + ] + ) + + vendor_interfaces = [vendor_interface] + interfaces_to_join = [] if 'CDC' in args.devices: @@ -373,6 +418,9 @@ if 'HID' in args.devices: if 'AUDIO' in args.devices: interfaces_to_join.append(audio_interfaces) +if 'VENDOR' in args.devices: + interfaces_to_join.append(vendor_interfaces) + # util.join_interfaces() will renumber the endpoints to make them unique across descriptors, # and renumber the interfaces in order. But we still need to fix up certain # interface cross-references. @@ -425,6 +473,9 @@ if 'AUDIO' in args.devices: # correct ordering. descriptor_list.append(audio_control_interface) +if 'VENDOR' in args.devices: + descriptor_list.extend(vendor_interfaces) + # Finally, build the composite descriptor. configuration = standard.ConfigurationDescriptor( @@ -444,6 +495,7 @@ h_file = args.output_h_file c_file.write("""\ #include <stdint.h> +#include "tusb.h" #include "py/objtuple.h" #include "shared-bindings/usb_hid/Device.h" #include "{H_FILE_NAME}" @@ -550,7 +602,7 @@ c_file.write("\n") hid_descriptor_length = len(bytes(combined_hid_report_descriptor)) -# Now we values we need for the .h file. +# Now the values we need for the .h file. h_file.write("""\ #ifndef MICROPY_INCLUDED_AUTOGEN_USB_DESCRIPTOR_H #define MICROPY_INCLUDED_AUTOGEN_USB_DESCRIPTOR_H @@ -586,7 +638,27 @@ extern const uint8_t hid_report_descriptor[{hid_report_descriptor_length}]; msc_vendor=args.manufacturer[:8], msc_product=args.product[:16])) +if 'VENDOR' in args.devices: + h_file.write("""\ +enum +{ + VENDOR_REQUEST_WEBUSB = 1, + VENDOR_REQUEST_MICROSOFT = 2 +}; + +extern uint8_t const desc_ms_os_20[]; + +// Currently getting compile-time errors in files like tusb_fifo.c +// if we try do define this here (TODO figure this out!) +//extern const tusb_desc_webusb_url_t desc_webusb_url; + +""") + +h_file.write("""\ +#endif // MICROPY_INCLUDED_AUTOGEN_USB_DESCRIPTOR_H +""") # Write out the report descriptor and info + c_file.write("""\ const uint8_t hid_report_descriptor[{HID_DESCRIPTOR_LENGTH}] = {{ """.format(HID_DESCRIPTOR_LENGTH=hid_descriptor_length)) @@ -655,6 +727,96 @@ c_file.write("""\ }; """) -h_file.write("""\ -#endif // MICROPY_INCLUDED_AUTOGEN_USB_DESCRIPTOR_H -""") +if 'VENDOR' in args.devices: + # Mimic what the tinyusb webusb demo does in it's main.c file + c_file.write(""" +#define URL "{webusb_url}" + +const tusb_desc_webusb_url_t desc_webusb_url = +{{ + .bLength = 3 + sizeof(URL) - 1, + .bDescriptorType = 3, // WEBUSB URL type + .bScheme = 1, // 0: http, 1: https, 255: "" + .url = URL +}}; + +// These next two hardcoded descriptors were pulled from the usb_descriptor.c file +// of the tinyusb webusb_serial demo. TODO - this is probably something else to +// integrate into the adafruit_usb_descriptors project... + +//--------------------------------------------------------------------+ +// BOS Descriptor +//--------------------------------------------------------------------+ + +/* Microsoft OS 2.0 registry property descriptor +Per MS requirements https://msdn.microsoft.com/en-us/library/windows/hardware/hh450799(v=vs.85).aspx +device should create DeviceInterfaceGUIDs. It can be done by driver and +in case of real PnP solution device should expose MS "Microsoft OS 2.0 +registry property descriptor". Such descriptor can insert any record +into Windows registry per device/configuration/interface. In our case it +will insert "DeviceInterfaceGUIDs" multistring property. + +GUID is freshly generated and should be OK to use. + +https://developers.google.com/web/fundamentals/native-hardware/build-for-webusb/ +(Section Microsoft OS compatibility descriptors) +*/ + +#define BOS_TOTAL_LEN (TUD_BOS_DESC_LEN + TUD_BOS_WEBUSB_DESC_LEN + TUD_BOS_MICROSOFT_OS_DESC_LEN) + +#define MS_OS_20_DESC_LEN 0xB2 + +// BOS Descriptor is required for webUSB +uint8_t const desc_bos[] = +{{ + // total length, number of device caps + TUD_BOS_DESCRIPTOR(BOS_TOTAL_LEN, 2), + + // Vendor Code, iLandingPage + TUD_BOS_WEBUSB_DESCRIPTOR(VENDOR_REQUEST_WEBUSB, 1), + + // Microsoft OS 2.0 descriptor + TUD_BOS_MS_OS_20_DESCRIPTOR(MS_OS_20_DESC_LEN, VENDOR_REQUEST_MICROSOFT) +}}; + +uint8_t const * tud_descriptor_bos_cb(void) +{{ + return desc_bos; +}} + + +#define ITF_NUM_VENDOR {webusb_interface} // used in this next descriptor + +uint8_t const desc_ms_os_20[] = +{{ + // Set header: length, type, windows version, total length + U16_TO_U8S_LE(0x000A), U16_TO_U8S_LE(MS_OS_20_SET_HEADER_DESCRIPTOR), U32_TO_U8S_LE(0x06030000), U16_TO_U8S_LE(MS_OS_20_DESC_LEN), + + // Configuration subset header: length, type, configuration index, reserved, configuration total length + U16_TO_U8S_LE(0x0008), U16_TO_U8S_LE(MS_OS_20_SUBSET_HEADER_CONFIGURATION), 0, 0, U16_TO_U8S_LE(MS_OS_20_DESC_LEN-0x0A), + + // Function Subset header: length, type, first interface, reserved, subset length + U16_TO_U8S_LE(0x0008), U16_TO_U8S_LE(MS_OS_20_SUBSET_HEADER_FUNCTION), ITF_NUM_VENDOR, 0, U16_TO_U8S_LE(MS_OS_20_DESC_LEN-0x0A-0x08), + + // MS OS 2.0 Compatible ID descriptor: length, type, compatible ID, sub compatible ID + U16_TO_U8S_LE(0x0014), U16_TO_U8S_LE(MS_OS_20_FEATURE_COMPATBLE_ID), 'W', 'I', 'N', 'U', 'S', 'B', 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // sub-compatible + + // MS OS 2.0 Registry property descriptor: length, type + U16_TO_U8S_LE(MS_OS_20_DESC_LEN-0x0A-0x08-0x08-0x14), U16_TO_U8S_LE(MS_OS_20_FEATURE_REG_PROPERTY), + U16_TO_U8S_LE(0x0007), U16_TO_U8S_LE(0x002A), // wPropertyDataType, wPropertyNameLength and PropertyName "DeviceInterfaceGUIDs\0" in UTF-16 + 'D', 0x00, 'e', 0x00, 'v', 0x00, 'i', 0x00, 'c', 0x00, 'e', 0x00, 'I', 0x00, 'n', 0x00, 't', 0x00, 'e', 0x00, + 'r', 0x00, 'f', 0x00, 'a', 0x00, 'c', 0x00, 'e', 0x00, 'G', 0x00, 'U', 0x00, 'I', 0x00, 'D', 0x00, 's', 0x00, 0x00, 0x00, + U16_TO_U8S_LE(0x0050), // wPropertyDataLength + //bPropertyData: “{{975F44D9-0D08-43FD-8B3E-127CA8AFFF9D}}”. + '{{', 0x00, '9', 0x00, '7', 0x00, '5', 0x00, 'F', 0x00, '4', 0x00, '4', 0x00, 'D', 0x00, '9', 0x00, '-', 0x00, + '0', 0x00, 'D', 0x00, '0', 0x00, '8', 0x00, '-', 0x00, '4', 0x00, '3', 0x00, 'F', 0x00, 'D', 0x00, '-', 0x00, + '8', 0x00, 'B', 0x00, '3', 0x00, 'E', 0x00, '-', 0x00, '1', 0x00, '2', 0x00, '7', 0x00, 'C', 0x00, 'A', 0x00, + '8', 0x00, 'A', 0x00, 'F', 0x00, 'F', 0x00, 'F', 0x00, '9', 0x00, 'D', 0x00, '}}', 0x00, 0x00, 0x00, 0x00, 0x00 +}}; + +TU_VERIFY_STATIC(sizeof(desc_ms_os_20) == MS_OS_20_DESC_LEN, "Incorrect size"); + +// End of section about desc_ms_os_20 + +""".format(webusb_url=args.webusb_url, webusb_interface=vendor_interface.bInterfaceNumber)) |
