diff --git a/.devcontainer/cortex-m/on-create.sh b/.devcontainer/cortex-m/on-create.sh index 8c4bd0cfed..3db1ff3f38 100755 --- a/.devcontainer/cortex-m/on-create.sh +++ b/.devcontainer/cortex-m/on-create.sh @@ -34,7 +34,7 @@ rm -fr /workspaces/dosfstools-4.2 /workspaces/dosfstools-4.2.tar.gz # prepare source-code tree cd /workspaces/circuitpython/ echo -e "[on-create.sh] fetching submodules" -make fetch-submodules +make fetch-all-submodules echo -e "[on-create.sh] fetching tags" git fetch --tags --recurse-submodules=no --shallow-since="2021-07-01" https://github.com/adafruit/circuitpython HEAD diff --git a/.github/actions/deps/external/action.yml b/.github/actions/deps/external/action.yml index a26579b53d..2d6f65eeff 100644 --- a/.github/actions/deps/external/action.yml +++ b/.github/actions/deps/external/action.yml @@ -37,11 +37,7 @@ runs: - name: Install IDF tools if: inputs.port == 'espressif' run: | - echo "Installing ESP-IDF tools" - $IDF_PATH/tools/idf_tools.py --non-interactive install required - $IDF_PATH/tools/idf_tools.py --non-interactive install cmake - echo "Installing Python environment and packages" - $IDF_PATH/tools/idf_tools.py --non-interactive install-python-env + $IDF_PATH/install.sh rm -rf $IDF_TOOLS_PATH/dist shell: bash - name: Set environment diff --git a/.gitmodules b/.gitmodules index 5c29c41b9f..75f1d5f233 100644 --- a/.gitmodules +++ b/.gitmodules @@ -143,10 +143,14 @@ [submodule "ports/espressif/esp-idf"] path = ports/espressif/esp-idf url = https://github.com/adafruit/esp-idf.git - branch = release/v4.4-circuitpython -[submodule "ports/espressif/certificates/nina-fw"] - path = lib/certificates/nina-fw - url = https://github.com/adafruit/nina-fw.git + branch = circuitpython-v5.1 +[submodule "ports/espressif/esp-protocols"] + path = ports/espressif/esp-protocols + url = https://github.com/espressif/esp-protocols.git +[submodule "ports/espressif/esp-camera"] + path = ports/espressif/esp-camera + url = https://github.com/adafruit/esp32-camera.git + branch = circuitpython [submodule "frozen/Adafruit_CircuitPython_ST7789"] path = frozen/Adafruit_CircuitPython_ST7789 url = https://github.com/adafruit/Adafruit_CircuitPython_ST7789 @@ -300,10 +304,6 @@ [submodule "frozen/circuitpython_picoed"] path = frozen/circuitpython_picoed url = https://github.com/elecfreaks/circuitpython_picoed.git -[submodule "ports/espressif/esp32-camera"] - path = ports/espressif/esp32-camera - url = https://github.com/adafruit/esp32-camera/ - branch = circuitpython [submodule "ports/raspberrypi/lib/cyw43-driver"] path = ports/raspberrypi/lib/cyw43-driver url = https://github.com/georgerobotics/cyw43-driver.git @@ -340,8 +340,11 @@ url = https://github.com/bablokb/circuitpython-pcf85063a [submodule "frozen/Adafruit_CircuitPython_Wave"] path = frozen/Adafruit_CircuitPython_Wave - url = http://github.com/adafruit/Adafruit_CircuitPython_Wave.git + url = https://github.com/adafruit/Adafruit_CircuitPython_Wave.git [submodule "ports/raspberrypi/lib/Pico-PIO-USB"] path = ports/raspberrypi/lib/Pico-PIO-USB url = https://github.com/sekigon-gonnoc/Pico-PIO-USB.git branch = main +[submodule "lib/certificates"] + path = lib/certificates + url = https://github.com/adafruit/certificates diff --git a/lib/certificates b/lib/certificates new file mode 160000 index 0000000000..cbb33c111f --- /dev/null +++ b/lib/certificates @@ -0,0 +1 @@ +Subproject commit cbb33c111f245411370c1e571012472323df3f07 diff --git a/lib/certificates/README.md b/lib/certificates/README.md deleted file mode 100644 index dd5cf25b00..0000000000 --- a/lib/certificates/README.md +++ /dev/null @@ -1,3 +0,0 @@ -We share root certificates with the nina-fw to ensure they both use the same roots. - -https://github.com/adafruit/nina-fw diff --git a/lib/certificates/nina-fw b/lib/certificates/nina-fw deleted file mode 160000 index 21205e4005..0000000000 --- a/lib/certificates/nina-fw +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 21205e400515a698266abaaea902bd1ea897bb5d diff --git a/lib/protomatter b/lib/protomatter index ed2e701871..c9c1189e9d 160000 --- a/lib/protomatter +++ b/lib/protomatter @@ -1 +1 @@ -Subproject commit ed2e7018718caebba2b7550517b556e7734357ef +Subproject commit c9c1189e9d6200bb09bf4a87d84be9459cae481b diff --git a/locale/ID.po b/locale/ID.po index 19484df074..73369c3774 100644 --- a/locale/ID.po +++ b/locale/ID.po @@ -92,13 +92,17 @@ msgstr "" "%d pin alamat, %d rgb pin dan %d ubin menunjukkan ketinggian %d, bukan %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -446,10 +450,6 @@ msgstr "pow() 3-arg tidak didukung" msgid "A hardware interrupt channel is already in use" msgstr "Sebuah channel hardware interrupt sedang digunakan" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 sedang digunakan oleh WiFi" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -461,9 +461,14 @@ msgstr "Alamat harus sepanjang %d byte" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "" @@ -1234,6 +1239,7 @@ msgid "Invalid %q" msgstr "" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1388,6 +1394,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "Harus berupa subclass %q." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Harus menyediakan pin MISO atau MOSI" @@ -2151,6 +2161,10 @@ msgstr "String UUID bukan 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" msgid "UUID value is not str, int or byte buffer" msgstr "Nilai UUID bukan str, int atau byte buffer" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2162,11 +2176,6 @@ msgstr "Tidak dapat mengalokasikan buffer untuk signed conversion" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2185,33 +2194,23 @@ msgstr "Tidak dapat menemukan GCLK yang kosong" msgid "Unable to init parser" msgstr "Tidak dapat memulai parser" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "Tidak dapat membaca data palet warna" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Tidak dapat menulis ke nvm." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -2974,7 +2973,7 @@ msgstr "" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "heap kosong" @@ -3926,10 +3925,6 @@ msgstr "" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "antrian meluap (overflow)" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4220,7 +4215,8 @@ msgstr "" msgid "unexpected keyword argument" msgstr "argumen keyword tidak diharapkan" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "keyword argumen '%q' tidak diharapkan" @@ -4377,10 +4373,6 @@ msgstr "jumlah nilai yang salah untuk dibongkar" msgid "wrong output type" msgstr "tipe output salah" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "xTaskCreate gagal" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "zi harus ndarray" @@ -4393,6 +4385,15 @@ msgstr "zi harus berjenis float" msgid "zi must be of shape (n_section, 2)" msgstr "Zi harus berbentuk (n_section, 2)" +#~ msgid "ADC2 is being used by WiFi" +#~ msgstr "ADC2 sedang digunakan oleh WiFi" + +#~ msgid "xTaskCreate failed" +#~ msgstr "xTaskCreate gagal" + +#~ msgid "queue overflow" +#~ msgstr "antrian meluap (overflow)" + #~ msgid "Buffer is too small" #~ msgstr "Buffer terlalu kecil" diff --git a/locale/circuitpython.pot b/locale/circuitpython.pot index b61c7b0f4c..a523baebba 100644 --- a/locale/circuitpython.pot +++ b/locale/circuitpython.pot @@ -447,10 +447,6 @@ msgstr "" msgid "A hardware interrupt channel is already in use" msgstr "" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -462,9 +458,14 @@ msgstr "" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "" @@ -1228,6 +1229,7 @@ msgid "Invalid %q" msgstr "" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1382,6 +1384,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "" +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "" @@ -2131,6 +2137,10 @@ msgstr "" msgid "UUID value is not str, int or byte buffer" msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2142,11 +2152,6 @@ msgstr "" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2165,33 +2170,23 @@ msgstr "" msgid "Unable to init parser" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -4193,7 +4188,8 @@ msgstr "" msgid "unexpected keyword argument" msgstr "" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "" @@ -4350,10 +4346,6 @@ msgstr "" msgid "wrong output type" msgstr "" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "" diff --git a/locale/cs.po b/locale/cs.po index 0c22cfffbe..5f4c7f1df1 100644 --- a/locale/cs.po +++ b/locale/cs.po @@ -93,13 +93,17 @@ msgid "" msgstr "%d adresní pin, %d rgb pin a %d dlaždice indikuje výšku %d, ne %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -447,10 +451,6 @@ msgstr "pow() nepodporuje 3 argumenty" msgid "A hardware interrupt channel is already in use" msgstr "Kanál hardwarového přerušení je již používán" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "WiFi používá ADC2" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -462,9 +462,14 @@ msgstr "Adresa musí být %d bajtů dlouhá" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "Všechny CAN periferie jsou používány" @@ -1234,6 +1239,7 @@ msgid "Invalid %q" msgstr "" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1388,6 +1394,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "Musí být podtřída %q." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Musí poskytnout pin MISO nebo MOSI" @@ -2140,6 +2150,10 @@ msgstr "" msgid "UUID value is not str, int or byte buffer" msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2151,11 +2165,6 @@ msgstr "" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2174,33 +2183,23 @@ msgstr "" msgid "Unable to init parser" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -2961,7 +2960,7 @@ msgstr "" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "" @@ -3912,10 +3911,6 @@ msgstr "" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4206,7 +4201,8 @@ msgstr "" msgid "unexpected keyword argument" msgstr "" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "" @@ -4363,10 +4359,6 @@ msgstr "" msgid "wrong output type" msgstr "" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "" @@ -4379,6 +4371,9 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "ADC2 is being used by WiFi" +#~ msgstr "WiFi používá ADC2" + #~ msgid "'coroutine' object is not an iterator" #~ msgstr "Objekt 'coroutine' není iterátor" diff --git a/locale/de_DE.po b/locale/de_DE.po index 26ab1022ce..aa17cf6313 100644 --- a/locale/de_DE.po +++ b/locale/de_DE.po @@ -98,13 +98,17 @@ msgstr "" "nicht %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -454,10 +458,6 @@ msgstr "3-arg pow() wird nicht unterstützt" msgid "A hardware interrupt channel is already in use" msgstr "Ein Hardware Interrupt Kanal wird schon benutzt" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 wird vom WiFi benutzt" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -469,9 +469,14 @@ msgstr "Die Adresse muss %d Bytes lang sein" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "Adressbereich nicht erlaubt" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "Alle CAN-Schnittstellen sind in Benutzung" @@ -1255,6 +1260,7 @@ msgid "Invalid %q" msgstr "Ungültiger %q" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1410,6 +1416,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "Muss eine %q Unterklasse sein." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Muss MISO- oder MOSI-Pin bereitstellen" @@ -2178,6 +2188,10 @@ msgstr "UUID string ist nicht 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" msgid "UUID value is not str, int or byte buffer" msgstr "Der UUID-Wert ist kein str-, int- oder Byte-Puffer" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2189,11 +2203,6 @@ msgstr "Konnte keine Buffer für Vorzeichenumwandlung allozieren" msgid "Unable to allocate the heap." msgstr "Keine Allokation auf dem Heap möglich." -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "ADC-DMA-Controller konnte nicht konfiguriert werden, Fehlercode: %d" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "Lock kann nicht erzeugt werden" @@ -2212,33 +2221,23 @@ msgstr "Konnte keinen freien GCLK finden" msgid "Unable to init parser" msgstr "Parser konnte nicht gestartet werden" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "ADC-DMA-Controller konnte nicht initialisiert werden, Fehlercode: %d" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "Konnte Farbpalettendaten nicht lesen" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "ADC-DMA-Controller konnte nicht gestartet werden, Fehlercode: %d" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "mDNS-Abfrage kann nicht gestartet werden" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "An die Adresse kann nicht geschrieben werden." - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Schreiben in nvm nicht möglich." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "Schreiben in sleep_memory nicht möglich." @@ -3025,7 +3024,7 @@ msgstr "leer" msgid "empty file" msgstr "Leere Datei" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "leerer heap" @@ -3992,10 +3991,6 @@ msgstr "pow() mit 3 Argumenten erfordert ganze Zahlen" msgid "pull masks conflict with direction masks" msgstr "Pull-Masken kollidieren mit Richtungsmasken" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "Warteschlangenüberlauf" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "unformatierte F-Strings werden nicht unterstützt" @@ -4288,7 +4283,8 @@ msgstr "" msgid "unexpected keyword argument" msgstr "unerwartetes Schlüsselwort-Argument" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "unerwartetes Schlüsselwort-Argument '%q'" @@ -4445,10 +4441,6 @@ msgstr "falsche Anzahl zu entpackender Werte" msgid "wrong output type" msgstr "Falscher Ausgabetyp" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "xTaskCreate fehlgeschlagen" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "zi muss ein ndarray sein" @@ -4461,6 +4453,31 @@ msgstr "zi muss eine Gleitkommazahl sein" msgid "zi must be of shape (n_section, 2)" msgstr "zi muss die Form (n_section, 2) haben" +#~ msgid "ADC2 is being used by WiFi" +#~ msgstr "ADC2 wird vom WiFi benutzt" + +#, c-format +#~ msgid "Unable to configure ADC DMA controller, ErrorCode:%d" +#~ msgstr "ADC-DMA-Controller konnte nicht konfiguriert werden, Fehlercode: %d" + +#, c-format +#~ msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" +#~ msgstr "" +#~ "ADC-DMA-Controller konnte nicht initialisiert werden, Fehlercode: %d" + +#, c-format +#~ msgid "Unable to start ADC DMA controller, ErrorCode:%d" +#~ msgstr "ADC-DMA-Controller konnte nicht gestartet werden, Fehlercode: %d" + +#~ msgid "xTaskCreate failed" +#~ msgstr "xTaskCreate fehlgeschlagen" + +#~ msgid "Unable to write to address." +#~ msgstr "An die Adresse kann nicht geschrieben werden." + +#~ msgid "queue overflow" +#~ msgstr "Warteschlangenüberlauf" + #~ msgid "Stopping AP is not supported." #~ msgstr "Das Stoppen des AP wird nicht unterstützt." diff --git a/locale/el.po b/locale/el.po index 657ab83f20..086718f45b 100644 --- a/locale/el.po +++ b/locale/el.po @@ -101,13 +101,17 @@ msgstr "" "%d pin διεύθυνσης, %d rgb ping και %d πλακίδια αναδεικνύουν ύψος %d, όχι %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -455,10 +459,6 @@ msgstr "pow() με 3 παραμέτρους δεν υποστηρίζεται" msgid "A hardware interrupt channel is already in use" msgstr "Ένα κανάλι interrupt υλικού είναι ήδη σε χρήση" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "Το ADC2 χρησιμοποιείται απο το WIFI" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -470,9 +470,14 @@ msgstr "Η διεύθυνση πρέπει να είναι %d bytes μεγάλη #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "Όλα τα περιφεριακά CAN είναι σε χρήση" @@ -1248,6 +1253,7 @@ msgid "Invalid %q" msgstr "" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1402,6 +1408,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "" +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "" @@ -2153,6 +2163,10 @@ msgstr "" msgid "UUID value is not str, int or byte buffer" msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2164,11 +2178,6 @@ msgstr "" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2187,33 +2196,23 @@ msgstr "" msgid "Unable to init parser" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -2974,7 +2973,7 @@ msgstr "" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "" @@ -3925,10 +3924,6 @@ msgstr "" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4219,7 +4214,8 @@ msgstr "" msgid "unexpected keyword argument" msgstr "" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "" @@ -4376,10 +4372,6 @@ msgstr "" msgid "wrong output type" msgstr "" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "" @@ -4392,6 +4384,9 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "ADC2 is being used by WiFi" +#~ msgstr "Το ADC2 χρησιμοποιείται απο το WIFI" + #~ msgid "" #~ "\n" #~ "Please file an issue with your program at https://github.com/adafruit/" diff --git a/locale/en_GB.po b/locale/en_GB.po index 73b5028849..8c8ad14d5a 100644 --- a/locale/en_GB.po +++ b/locale/en_GB.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"PO-Revision-Date: 2023-08-14 01:48+0000\n" +"PO-Revision-Date: 2023-09-10 08:50+0000\n" "Last-Translator: Andi Chandler \n" "Language-Team: none\n" "Language: en_GB\n" @@ -15,7 +15,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 5.0-dev\n" +"X-Generator: Weblate 5.0.1-dev\n" #: main.c msgid "" @@ -39,6 +39,9 @@ msgid "" "Please file an issue with your program at github.com/adafruit/circuitpython/" "issues." msgstr "" +"\n" +"Please file an issue with your program at github.com/adafruit/circuitpython/" +"issues." #: supervisor/shared/safe_mode.c msgid "" @@ -99,13 +102,17 @@ msgstr "" "%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -429,7 +436,7 @@ msgstr "'yield' outside function" #: py/compile.c msgid "* arg after **" -msgstr "" +msgstr "* arg after **" #: py/compile.c msgid "*x must be assignment target" @@ -453,13 +460,9 @@ msgstr "3-arg pow() not supported" msgid "A hardware interrupt channel is already in use" msgstr "A hardware interrupt channel is already in use" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 is being used by WiFi" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" -msgstr "" +msgstr "AP could not be started" #: shared-bindings/_bleio/Address.c shared-bindings/ipaddress/IPv4Address.c #, c-format @@ -468,9 +471,14 @@ msgstr "Address must be %d bytes long" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "Address range not allowed" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "Address range wraps around" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "All CAN peripherals are in use" @@ -699,7 +707,7 @@ msgstr "Buffer too short by %d bytes" #: shared-bindings/framebufferio/FramebufferDisplay.c #: shared-bindings/struct/__init__.c shared-module/struct/__init__.c msgid "Buffer too small" -msgstr "" +msgstr "Buffer too small" #: ports/espressif/common-hal/imagecapture/ParallelImageCapture.c msgid "Buffers must be same size" @@ -1123,7 +1131,7 @@ msgstr "Half duplex SPI is not implemented" #: supervisor/shared/safe_mode.c msgid "Hard fault: memory access or instruction error." -msgstr "" +msgstr "Hard fault: memory access or instruction error." #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c @@ -1240,6 +1248,7 @@ msgid "Invalid %q" msgstr "Invalid %q" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1394,6 +1403,10 @@ msgstr "Missing jmp_pin. %q[%u] jumps on pin" msgid "Must be a %q subclass." msgstr "Must be a %q subclass." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "Must provide 5/6/5 RGB pins" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Must provide MISO or MOSI pin" @@ -1782,7 +1795,7 @@ msgstr "Polygon needs at least 3 points" #: supervisor/shared/safe_mode.c msgid "Power dipped. Make sure you are providing enough power." -msgstr "" +msgstr "Power dipped. Make sure you are providing enough power." #: shared-bindings/_bleio/Adapter.c msgid "Prefix buffer must be on the heap" @@ -2153,6 +2166,10 @@ msgstr "UUID string not 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" msgid "UUID value is not str, int or byte buffer" msgstr "UUID value is not str, int or byte buffer" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "Unable to access unaligned IO register" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2164,11 +2181,6 @@ msgstr "Unable to allocate buffers for signed conversion" msgid "Unable to allocate the heap." msgstr "Unable to allocate the heap." -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "Unable to configure ADC DMA controller, ErrorCode:%d" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "Unable to create lock" @@ -2187,33 +2199,23 @@ msgstr "Unable to find free GCLK" msgid "Unable to init parser" msgstr "Unable to init parser" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "Unable to initialise ADC DMA controller, ErrorCode:%d" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "Unable to read colour palette data" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "Unable to start ADC DMA controller, ErrorCode:%d" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "Unable to start mDNS query" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "Unable to write to address." - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Unable to write to nvm." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "Unable to write to read-only memory" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "Unable to write to sleep_memory." @@ -2399,7 +2401,7 @@ msgstr "You pressed button A at start up." #: ports/espressif/boards/m5stack_m5paper/mpconfigboard.h msgid "You pressed button DOWN at start up." -msgstr "" +msgstr "You pressed button DOWN at start up." #: supervisor/shared/safe_mode.c msgid "You pressed the BOOT button at start up" @@ -2524,7 +2526,7 @@ msgstr "array/bytes required on right side" #: py/asmxtensa.c msgid "asm overflow" -msgstr "" +msgstr "asm overflow" #: extmod/ulab/code/numpy/numerical.c msgid "attempt to get (arg)min/(arg)max of empty sequence" @@ -2616,7 +2618,7 @@ msgstr "Buffer too small for requested bytes" #: py/emitbc.c msgid "bytecode overflow" -msgstr "" +msgstr "bytecode overflow" #: py/objarray.c msgid "bytes length not a multiple of item size" @@ -2675,7 +2677,7 @@ msgstr "can't convert %s to complex" #: py/obj.c #, c-format msgid "can't convert %s to float" -msgstr "" +msgstr "can't convert %s to float" #: py/objstr.c msgid "can't convert '%q' object to %q implicitly" @@ -2691,7 +2693,7 @@ msgstr "can't convert to complex" #: py/obj.c msgid "can't convert to float" -msgstr "" +msgstr "can't convert to float" #: py/runtime.c msgid "can't convert to int" @@ -2775,7 +2777,7 @@ msgstr "" #: extmod/moduasyncio.c msgid "can't wait" -msgstr "" +msgstr "can't wait" #: extmod/ulab/code/ndarray.c msgid "cannot assign new shape" @@ -2984,7 +2986,7 @@ msgstr "empty" msgid "empty file" msgstr "empty file" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "empty heap" @@ -3213,11 +3215,11 @@ msgstr "import * not at module level" #: py/persistentcode.c msgid "incompatible .mpy arch" -msgstr "" +msgstr "incompatible .mpy arch" #: py/persistentcode.c msgid "incompatible .mpy file" -msgstr "" +msgstr "incompatible .mpy file" #: py/objstr.c msgid "incomplete format" @@ -3681,7 +3683,7 @@ msgstr "not a 128-bit UUID" #: py/parse.c msgid "not a constant" -msgstr "" +msgstr "not a constant" #: py/objstr.c msgid "not all arguments converted during string formatting" @@ -3919,11 +3921,11 @@ msgstr "port must be >= 0" #: py/compile.c msgid "positional arg after **" -msgstr "" +msgstr "positional arg after **" #: py/compile.c msgid "positional arg after keyword arg" -msgstr "" +msgstr "positional arg after keyword arg" #: py/objint_mpz.c msgid "pow() 3rd argument cannot be 0" @@ -3937,10 +3939,6 @@ msgstr "pow() with 3 arguments requires integers" msgid "pull masks conflict with direction masks" msgstr "pull masks conflict with direction masks" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "queue overflow" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "raw f-strings are not supported" @@ -4154,7 +4152,7 @@ msgstr "tobytes can be invoked for dense arrays only" #: py/compile.c msgid "too many args" -msgstr "" +msgstr "too many args" #: extmod/ulab/code/ndarray.c extmod/ulab/code/numpy/create.c msgid "too many dimensions" @@ -4231,7 +4229,8 @@ msgstr "unexpected indent" msgid "unexpected keyword argument" msgstr "unexpected keyword argument" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "unexpected keyword argument '%q'" @@ -4388,10 +4387,6 @@ msgstr "wrong number of values to unpack" msgid "wrong output type" msgstr "wrong output type" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "xTaskCreate failed" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "zi must be an ndarray" @@ -4404,6 +4399,30 @@ msgstr "zi must be of float type" msgid "zi must be of shape (n_section, 2)" msgstr "zi must be of shape (n_section, 2)" +#~ msgid "ADC2 is being used by WiFi" +#~ msgstr "ADC2 is being used by WiFi" + +#, c-format +#~ msgid "Unable to configure ADC DMA controller, ErrorCode:%d" +#~ msgstr "Unable to configure ADC DMA controller, ErrorCode:%d" + +#, c-format +#~ msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" +#~ msgstr "Unable to initialise ADC DMA controller, ErrorCode:%d" + +#, c-format +#~ msgid "Unable to start ADC DMA controller, ErrorCode:%d" +#~ msgstr "Unable to start ADC DMA controller, ErrorCode:%d" + +#~ msgid "xTaskCreate failed" +#~ msgstr "xTaskCreate failed" + +#~ msgid "Unable to write to address." +#~ msgstr "Unable to write to address." + +#~ msgid "queue overflow" +#~ msgstr "queue overflow" + #~ msgid "Stopping AP is not supported." #~ msgstr "Stopping AP is not supported." diff --git a/locale/es.po b/locale/es.po index 8066a3bba5..c1b8b53df1 100644 --- a/locale/es.po +++ b/locale/es.po @@ -104,13 +104,17 @@ msgstr "" "no de %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -458,10 +462,6 @@ msgstr "pow() con 3 argumentos no soportado" msgid "A hardware interrupt channel is already in use" msgstr "Un canal de interrupción por hardware ya está en uso" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 está siendo usado por WiFi" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -473,9 +473,14 @@ msgstr "La dirección debe tener %d bytes de longitud" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "Rango de dirección no permitido" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "Todos los periféricos CAN están en uso" @@ -1267,6 +1272,7 @@ msgid "Invalid %q" msgstr "%q inválido" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1421,6 +1427,10 @@ msgstr "Falta jmp_pin. %q[%u] salta en pin" msgid "Must be a %q subclass." msgstr "Debe de ser una subclase de %q." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Debe proporcionar un pin MISO o MOSI" @@ -2192,6 +2202,10 @@ msgstr "UUID string no es 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" msgid "UUID value is not str, int or byte buffer" msgstr "UUID valor no es un str, int o byte buffer" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2203,11 +2217,6 @@ msgstr "No se pudieron asignar buffers para la conversión con signo" msgid "Unable to allocate the heap." msgstr "Imposible de asignar el heap." -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "Imposible de configurar el controlador ADC DMA , código de error:%d" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "No se puede crear bloqueo" @@ -2226,34 +2235,23 @@ msgstr "No se pudo encontrar un GCLK libre" msgid "Unable to init parser" msgstr "Incapaz de inicializar el parser" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" -"No es posible de inicializar el controlador ADC DMA, código de error:%d" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "No se pudo leer los datos de la paleta de colores" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "Imposible de iniciar el controlador ADC DMA, código de error:%d" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "Imposible de incializar una consulta mDNS" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "Imposible de escribir en esa dirección." - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Imposible escribir en nvm." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "Imposible de escribir en sleep_memory." @@ -3031,7 +3029,7 @@ msgstr "vacío" msgid "empty file" msgstr "archivo vacio" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "heap vacío" @@ -3989,10 +3987,6 @@ msgstr "pow() con 3 argumentos requiere enteros" msgid "pull masks conflict with direction masks" msgstr "máscara de pull en conflicto con máscara de dirección" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "desbordamiento de cola(queue)" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "raw f-strings no esta soportadas" @@ -4284,7 +4278,8 @@ msgstr "sangría inesperada" msgid "unexpected keyword argument" msgstr "argumento por palabra clave inesperado" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "argumento por palabra clave inesperado '%q'" @@ -4441,10 +4436,6 @@ msgstr "numero erroneo de valores a descomprimir" msgid "wrong output type" msgstr "tipo de salida incorrecta" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "fallo en xTaskCreate" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "zi debe ser un ndarray" @@ -4457,6 +4448,31 @@ 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 "ADC2 is being used by WiFi" +#~ msgstr "ADC2 está siendo usado por WiFi" + +#, c-format +#~ msgid "Unable to configure ADC DMA controller, ErrorCode:%d" +#~ msgstr "Imposible de configurar el controlador ADC DMA , código de error:%d" + +#, c-format +#~ msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" +#~ msgstr "" +#~ "No es posible de inicializar el controlador ADC DMA, código de error:%d" + +#, c-format +#~ msgid "Unable to start ADC DMA controller, ErrorCode:%d" +#~ msgstr "Imposible de iniciar el controlador ADC DMA, código de error:%d" + +#~ msgid "xTaskCreate failed" +#~ msgstr "fallo en xTaskCreate" + +#~ msgid "Unable to write to address." +#~ msgstr "Imposible de escribir en esa dirección." + +#~ msgid "queue overflow" +#~ msgstr "desbordamiento de cola(queue)" + #~ msgid "Stopping AP is not supported." #~ msgstr "Parar el AP no esta soportado." diff --git a/locale/fil.po b/locale/fil.po index 226de0e449..7fcc48e35c 100644 --- a/locale/fil.po +++ b/locale/fil.po @@ -90,13 +90,17 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -445,10 +449,6 @@ msgstr "3-arg pow() hindi suportado" msgid "A hardware interrupt channel is already in use" msgstr "Isang channel ng hardware interrupt ay ginagamit na" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -460,9 +460,14 @@ msgstr "ang palette ay dapat 32 bytes ang haba" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "" @@ -1234,6 +1239,7 @@ msgid "Invalid %q" msgstr "" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1388,6 +1394,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "" +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "" @@ -2141,6 +2151,10 @@ msgstr "" msgid "UUID value is not str, int or byte buffer" msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2152,11 +2166,6 @@ msgstr "Hindi ma-allocate ang buffers para sa naka-sign na conversion" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2175,33 +2184,23 @@ msgstr "Hindi mahanap ang libreng GCLK" msgid "Unable to init parser" msgstr "Hindi ma-init ang parser" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Hindi ma i-sulat sa NVM." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -2975,7 +2974,7 @@ msgstr "walang laman" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "walang laman ang heap" @@ -3933,10 +3932,6 @@ msgstr "pow() na may 3 argumento kailangan ng integers" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "puno na ang pila (overflow)" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4227,7 +4222,8 @@ msgstr "hindi inaasahang indent" msgid "unexpected keyword argument" msgstr "hindi inaasahang argumento ng keyword" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "hindi inaasahang argumento ng keyword na '%q'" @@ -4384,10 +4380,6 @@ msgstr "maling number ng value na i-unpack" msgid "wrong output type" msgstr "" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "" @@ -4400,6 +4392,9 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "queue overflow" +#~ msgstr "puno na ang pila (overflow)" + #~ msgid "pixel_shader must be displayio.Palette or displayio.ColorConverter" #~ msgstr "pixel_shader ay dapat displayio.Palette o displayio.ColorConverter" diff --git a/locale/fr.po b/locale/fr.po index 55e1cad427..b8b53001cf 100644 --- a/locale/fr.po +++ b/locale/fr.po @@ -101,13 +101,17 @@ msgstr "" "%d, et non %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -457,10 +461,6 @@ msgstr "pow() non supporté avec 3 paramètres" msgid "A hardware interrupt channel is already in use" msgstr "Un canal d'interruptions matériel est déjà utilisé" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 est utilisé pars le Wifi" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -472,9 +472,14 @@ msgstr "L'adresse doit être longue de %d octets" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "Plage d'adresses non autorisée" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "Tous les périphériques CAN sont utilisés" @@ -1272,6 +1277,7 @@ msgid "Invalid %q" msgstr "%q invalide" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1427,6 +1433,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "Doit être une sous-classe de %q." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Doit fournir une broche MISO ou MOSI" @@ -2199,6 +2209,10 @@ msgstr "" "La valeur de l'UUID n'est pas une chaîne de caractères, un chiffre entier ou " "un tampon d'octets" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2210,11 +2224,6 @@ msgstr "Impossible d'allouer des tampons pour une conversion signée" msgid "Unable to allocate the heap." msgstr "Impossible d'allouer le tas." -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "Impossible de créer un verrou ('lock')" @@ -2233,33 +2242,23 @@ msgstr "Impossible de trouver un GCLK libre" msgid "Unable to init parser" msgstr "Impossible d'initialiser le parser" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "Impossible de lire les données de la palette de couleurs" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "Impossible de lancer la requête mDNS" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "L'écriture a échoué." - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Écriture impossible vers nvm." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "Écriture impossible vers sleep_memory." @@ -3045,7 +3044,7 @@ msgstr "vide" msgid "empty file" msgstr "fichier vide" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "tas vide" @@ -4009,10 +4008,6 @@ msgstr "pow() avec 3 arguments nécessite des entiers" msgid "pull masks conflict with direction masks" msgstr "masque pull est en conflit avec les masques de direction" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "dépassement de file" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "les f-strings bruts ne sont pas supportées" @@ -4304,7 +4299,8 @@ msgstr "indentation inattendue" msgid "unexpected keyword argument" msgstr "paramètre nommé inattendu" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "paramètre nommé '%q' inattendu" @@ -4461,10 +4457,6 @@ msgstr "mauvais nombre de valeurs à dégrouper" msgid "wrong output type" msgstr "type de sortie incorrect" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "Échec de xTaskCreate" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "zi doit être un ndarray" @@ -4477,6 +4469,18 @@ 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 "ADC2 is being used by WiFi" +#~ msgstr "ADC2 est utilisé pars le Wifi" + +#~ msgid "xTaskCreate failed" +#~ msgstr "Échec de xTaskCreate" + +#~ msgid "Unable to write to address." +#~ msgstr "L'écriture a échoué." + +#~ msgid "queue overflow" +#~ msgstr "dépassement de file" + #~ msgid "Stopping AP is not supported." #~ msgstr "Stopper n'est pas supporté." diff --git a/locale/hi.po b/locale/hi.po index 8b6daab54f..3a08024011 100644 --- a/locale/hi.po +++ b/locale/hi.po @@ -89,13 +89,17 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -443,10 +447,6 @@ msgstr "" msgid "A hardware interrupt channel is already in use" msgstr "" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -458,9 +458,14 @@ msgstr "" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "" @@ -1224,6 +1229,7 @@ msgid "Invalid %q" msgstr "" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1378,6 +1384,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "" +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "" @@ -2127,6 +2137,10 @@ msgstr "" msgid "UUID value is not str, int or byte buffer" msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2138,11 +2152,6 @@ msgstr "" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2161,33 +2170,23 @@ msgstr "" msgid "Unable to init parser" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -2948,7 +2947,7 @@ msgstr "" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "" @@ -3899,10 +3898,6 @@ msgstr "" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4193,7 +4188,8 @@ msgstr "" msgid "unexpected keyword argument" msgstr "" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "" @@ -4350,10 +4346,6 @@ msgstr "" msgid "wrong output type" msgstr "" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "" diff --git a/locale/it_IT.po b/locale/it_IT.po index e0f719cb5a..e8fb475d1a 100644 --- a/locale/it_IT.po +++ b/locale/it_IT.po @@ -93,13 +93,17 @@ msgstr "" "%d pin indirizzo, %d pin rgb e %d tessere indicano l'altezza di %d, non %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -448,10 +452,6 @@ msgstr "pow() con tre argmomenti non supportata" msgid "A hardware interrupt channel is already in use" msgstr "Un canale di interruzione hardware è già in uso" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 sta usando il WiFi" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -463,9 +463,14 @@ msgstr "L'indirizzo deve essere lungo %d byte" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "Tutte le periferiche CAN sono in uso" @@ -1236,6 +1241,7 @@ msgid "Invalid %q" msgstr "" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1391,6 +1397,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "" +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "" @@ -2148,6 +2158,10 @@ msgstr "" msgid "UUID value is not str, int or byte buffer" msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2159,11 +2173,6 @@ msgstr "Ipossibilitato ad allocare buffer per la conversione con segno" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2182,33 +2191,23 @@ msgstr "Impossibile trovare un GCLK libero" msgid "Unable to init parser" msgstr "Inizilizzazione del parser non possibile" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Imposibile scrivere su nvm." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -2980,7 +2979,7 @@ msgstr "vuoto" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "heap vuoto" @@ -3943,10 +3942,6 @@ msgstr "pow() con 3 argomenti richiede interi" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "overflow della coda" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4237,7 +4232,8 @@ msgstr "indentazione inaspettata" msgid "unexpected keyword argument" msgstr "argomento nominato inaspettato" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "argomento nominato '%q' inaspettato" @@ -4394,10 +4390,6 @@ msgstr "numero di valori da scompattare non corretto" msgid "wrong output type" msgstr "" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "" @@ -4410,6 +4402,12 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "ADC2 is being used by WiFi" +#~ msgstr "ADC2 sta usando il WiFi" + +#~ msgid "queue overflow" +#~ msgstr "overflow della coda" + #~ msgid "'coroutine' object is not an iterator" #~ msgstr "L'oggetto 'coroutine' non è un iteratore" diff --git a/locale/ja.po b/locale/ja.po index 90608bca7e..01a9ed389d 100644 --- a/locale/ja.po +++ b/locale/ja.po @@ -95,13 +95,17 @@ msgid "" msgstr "%dアドレスピン、%dRGBピン、%dタイルは%dの高さを指示する。%dではない。" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -450,10 +454,6 @@ msgstr "引数3つのpow()は非対応" msgid "A hardware interrupt channel is already in use" msgstr "ハードウェア割り込みチャネルは使用中" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -465,9 +465,14 @@ msgstr "アドレスは、%dバイト長でなければなりません" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "全てのCAN周辺機器が使用中" @@ -1235,6 +1240,7 @@ msgid "Invalid %q" msgstr "不正な %q" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1389,6 +1395,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "%q のサブクラスでなければなりません" +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "MISOピンまたはMOSIピンが必要" @@ -2142,6 +2152,10 @@ msgstr "" msgid "UUID value is not str, int or byte buffer" msgstr "UUIDの値がstr, int, bufferのいずれでもありません" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2153,11 +2167,6 @@ msgstr "" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2176,33 +2185,23 @@ msgstr "" msgid "Unable to init parser" msgstr "パーザを初期化できません" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "カラーパレットデータを読み込めません" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "nvmに書き込みできません" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -2967,7 +2966,7 @@ msgstr "" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "" @@ -3919,10 +3918,6 @@ msgstr "pow()の第3引数には整数が必要" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "キューがオーバーフローしました" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4213,7 +4208,8 @@ msgstr "" msgid "unexpected keyword argument" msgstr "" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "キーワード引数'%q'は使えません" @@ -4370,10 +4366,6 @@ msgstr "アンパックする値の個数が不正です" msgid "wrong output type" msgstr "" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "ziはndarrayでなければなりません" @@ -4386,6 +4378,9 @@ msgstr "ziはfloat値でなければなりません" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "queue overflow" +#~ msgstr "キューがオーバーフローしました" + #~ msgid "'coroutine' object is not an iterator" #~ msgstr "'coroutine' オブジェクトはイテレータではありません" diff --git a/locale/ko.po b/locale/ko.po index 0f1329a029..a07596e9df 100644 --- a/locale/ko.po +++ b/locale/ko.po @@ -90,13 +90,17 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -444,10 +448,6 @@ msgstr "" msgid "A hardware interrupt channel is already in use" msgstr "" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -459,9 +459,14 @@ msgstr "" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "" @@ -1227,6 +1232,7 @@ msgid "Invalid %q" msgstr "" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1381,6 +1387,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "" +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "" @@ -2131,6 +2141,10 @@ msgid "UUID value is not str, int or byte buffer" msgstr "" "UUID값이 문자열(str), 정수(int) 또는 바이트버퍼가(byte buffer) 아닙니다" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2142,11 +2156,6 @@ msgstr "" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2165,33 +2174,23 @@ msgstr "" msgid "Unable to init parser" msgstr "파서를 초기화(init) 할 수 없습니다" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -2952,7 +2951,7 @@ msgstr "" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "" @@ -3903,10 +3902,6 @@ msgstr "" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4197,7 +4192,8 @@ msgstr "" msgid "unexpected keyword argument" msgstr "" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "" @@ -4354,10 +4350,6 @@ msgstr "" msgid "wrong output type" msgstr "" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "" diff --git a/locale/nl.po b/locale/nl.po index 424b229068..7372014908 100644 --- a/locale/nl.po +++ b/locale/nl.po @@ -89,13 +89,17 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -443,10 +447,6 @@ msgstr "3-arg pow() niet ondersteund" msgid "A hardware interrupt channel is already in use" msgstr "Een hardware interrupt kanaal is al in gebruik" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 wordt gebruikt door WiFi" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -458,9 +458,14 @@ msgstr "Adres moet %d bytes lang zijn" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "Alle CAN-peripherals zijn in gebruik" @@ -1230,6 +1235,7 @@ msgid "Invalid %q" msgstr "Ongeldige %q" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1384,6 +1390,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "%q moet een subklasse zijn." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "MISO of MOSI moeten worden gegeven" @@ -2146,6 +2156,10 @@ msgstr "UUID string is niet 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" msgid "UUID value is not str, int or byte buffer" msgstr "UUID waarde is geen str, int, of byte buffer" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2157,11 +2171,6 @@ msgstr "Niet in staat buffers voor gesigneerde conversie te alloceren" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "Kan vergrendeling niet maken" @@ -2180,33 +2189,23 @@ msgstr "Niet in staat een vrije GCLK te vinden" msgid "Unable to init parser" msgstr "Niet in staat om de parser te initialiseren" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "Niet in staat kleurenpalet data te lezen" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Niet in staat om naar nvm te schrijven." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "Kan niet naar sleep_memory schrijven." @@ -2976,7 +2975,7 @@ msgstr "leeg" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "lege heap" @@ -3931,10 +3930,6 @@ msgstr "pow() met 3 argumenten vereist integers" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "wachtrij overloop" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4225,7 +4220,8 @@ msgstr "onverwachte inspringing" msgid "unexpected keyword argument" msgstr "onverwacht trefwoordargument" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "onverwacht trefwoordargument '%q'" @@ -4382,10 +4378,6 @@ msgstr "verkeerd aantal waarden om uit te pakken" msgid "wrong output type" msgstr "onjuist uitvoer type" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "zi moet een ndarray zijn" @@ -4398,6 +4390,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 "ADC2 is being used by WiFi" +#~ msgstr "ADC2 wordt gebruikt door WiFi" + +#~ msgid "queue overflow" +#~ msgstr "wachtrij overloop" + #~ msgid "'coroutine' object is not an iterator" #~ msgstr "'coroutine' object is geen iterator" diff --git a/locale/pl.po b/locale/pl.po index 80067e391b..d1879d98b7 100644 --- a/locale/pl.po +++ b/locale/pl.po @@ -91,13 +91,17 @@ msgid "" msgstr "" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -445,10 +449,6 @@ msgstr "3-argumentowy pow() jest niewspierany" msgid "A hardware interrupt channel is already in use" msgstr "Kanał przerwań sprzętowych w użyciu" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 jest używany przez WiFi" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -460,9 +460,14 @@ msgstr "Adres musi mieć %d bajtów" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "" @@ -1230,6 +1235,7 @@ msgid "Invalid %q" msgstr "Nieprawidłowe %q" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1384,6 +1390,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "" +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Należy podać pin MISO lub MOSI" @@ -2133,6 +2143,10 @@ msgstr "UUID inny, niż `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" msgid "UUID value is not str, int or byte buffer" msgstr "UUID nie jest typu str, int lub bytes" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2144,11 +2158,6 @@ msgstr "Nie udała się alokacja buforów do konwersji ze znakiem" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2167,33 +2176,23 @@ msgstr "Brak wolnego GCLK" msgid "Unable to init parser" msgstr "Błąd ustawienia parsera" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "Nie można odczytać danych palety" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Błąd zapisu do NVM." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -2955,7 +2954,7 @@ msgstr "puste" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "pusta sterta" @@ -3906,10 +3905,6 @@ msgstr "trzyargumentowe pow() wymaga liczb całkowitych" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "przepełnienie kolejki" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4200,7 +4195,8 @@ msgstr "złe wcięcie" msgid "unexpected keyword argument" msgstr "zły argument nazwany" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "zły argument nazwany '%q'" @@ -4357,10 +4353,6 @@ msgstr "zła liczba wartości do rozpakowania" msgid "wrong output type" msgstr "nieprawidłowy typ wyjścia" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "" @@ -4373,6 +4365,12 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "ADC2 is being used by WiFi" +#~ msgstr "ADC2 jest używany przez WiFi" + +#~ msgid "queue overflow" +#~ msgstr "przepełnienie kolejki" + #~ msgid "Buffer is too small" #~ msgstr "Bufor jest za mały" diff --git a/locale/pt_BR.po b/locale/pt_BR.po index 18dfbc65ce..bb2cbfe806 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: 2023-08-29 18:34+0000\n" +"PO-Revision-Date: 2023-09-10 08:50+0000\n" "Last-Translator: Wellington Terumi Uemura \n" "Language-Team: \n" "Language: pt_BR\n" @@ -102,13 +102,17 @@ msgstr "" "não %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -460,10 +464,6 @@ msgstr "3-arg pow() não compatível" msgid "A hardware interrupt channel is already in use" msgstr "Um canal de interrupção de hardware já está em uso" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "O ADC2 está sendo usado pelo WiFi" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "Não foi possível iniciar o AP" @@ -475,9 +475,14 @@ msgstr "O endereço deve ter %d bytes de comprimento" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "Intervalo de endereços não permitido" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "O intervalo de endereços envolve" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "Todos os periféricos CAN estão em uso" @@ -1264,6 +1269,7 @@ msgid "Invalid %q" msgstr "%q Inválido" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1418,6 +1424,10 @@ msgstr "Falta jmp_pin. %q[%u] jumper no pino" msgid "Must be a %q subclass." msgstr "Deve ser uma subclasse %q." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "É preciso fornecer os pinos RGB 5/6/5" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Deve informar os pinos MISO ou MOSI" @@ -2193,6 +2203,10 @@ msgstr "A cadeia de caracteres UUID não 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" msgid "UUID value is not str, int or byte buffer" msgstr "O valor UUID não é um buffer str, int ou byte" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "Não foi possível acessar o registro IO não solicitado" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2204,11 +2218,6 @@ msgstr "Não é possível alocar buffers para conversão assinada" msgid "Unable to allocate the heap." msgstr "Não é possível alocar a área de alocação dinâmica de variáveis." -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "Não foi possível configurar o controlador ADC DMA, ErrorCode:%d" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "Não é possível criar um lock" @@ -2227,33 +2236,23 @@ msgstr "Não é possível encontrar GCLK livre" msgid "Unable to init parser" msgstr "Não foi possível iniciar o analisador" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "Não foi possível inicializar o controlador ADC DMA, ErrorCode:%d" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "Não foi possível ler os dados da paleta de cores" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "Não foi possível iniciar o controlador ADC DMA, ErrorCode:%d" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "Não é possível iniciar a consulta mDNS" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "Não é possível gravar no endereço." - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Não é possível gravar no nvm." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "Não foi possível escrever na memória de somente leitura" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "Não foi possível escrever no sleep_memory." @@ -3034,7 +3033,7 @@ msgstr "vazio" msgid "empty file" msgstr "arquivo vazio" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "a área de alocação dinâmica de variáveis (heap) está vazia" @@ -3998,10 +3997,6 @@ msgstr "o pow() com 3 argumentos requer números inteiros" msgid "pull masks conflict with direction masks" msgstr "puxe as máscaras em conflito com as máscaras de direção" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "estouro de fila" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "os f-strings brutos não são suportados" @@ -4292,7 +4287,8 @@ msgstr "recuo inesperado" msgid "unexpected keyword argument" msgstr "argumento inesperado da palavra-chave" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "argumento inesperado da palavra-chave '%q'" @@ -4449,10 +4445,6 @@ msgstr "quantidade incorreta dos valores para descompressão" msgid "wrong output type" msgstr "tipo da saída incorreta" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "o xTaskCreate falhou" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "zi deve ser um ndarray" @@ -4465,6 +4457,30 @@ 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 "ADC2 is being used by WiFi" +#~ msgstr "O ADC2 está sendo usado pelo WiFi" + +#, c-format +#~ msgid "Unable to configure ADC DMA controller, ErrorCode:%d" +#~ msgstr "Não foi possível configurar o controlador ADC DMA, ErrorCode:%d" + +#, c-format +#~ msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" +#~ msgstr "Não foi possível inicializar o controlador ADC DMA, ErrorCode:%d" + +#, c-format +#~ msgid "Unable to start ADC DMA controller, ErrorCode:%d" +#~ msgstr "Não foi possível iniciar o controlador ADC DMA, ErrorCode:%d" + +#~ msgid "xTaskCreate failed" +#~ msgstr "o xTaskCreate falhou" + +#~ msgid "Unable to write to address." +#~ msgstr "Não é possível gravar no endereço." + +#~ msgid "queue overflow" +#~ msgstr "estouro de fila" + #~ msgid "Stopping AP is not supported." #~ msgstr "Não há suporte para a interrupção do AP." diff --git a/locale/ru.po b/locale/ru.po index 1ae155ffdf..8c5846b8ae 100644 --- a/locale/ru.po +++ b/locale/ru.po @@ -7,16 +7,16 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"PO-Revision-Date: 2023-05-21 00:49+0000\n" -"Last-Translator: Scott Shawcroft \n" +"PO-Revision-Date: 2023-09-10 08:50+0000\n" +"Last-Translator: xXx \n" "Language-Team: none\n" "Language: ru\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" -"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" -"X-Generator: Weblate 4.18-dev\n" +"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && " +"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" +"X-Generator: Weblate 5.0.1-dev\n" #: main.c msgid "" @@ -40,18 +40,25 @@ msgid "" "Please file an issue with your program at github.com/adafruit/circuitpython/" "issues." msgstr "" +"\n" +"Пожалуйста подайте вопрос с вашей программой на github.com/adafruit/" +"circuitpython/issues." #: supervisor/shared/safe_mode.c msgid "" "\n" "Press reset to exit safe mode.\n" msgstr "" +"\n" +"Нажмите на сброс чтобы выйти из безопасного режима.\n" #: supervisor/shared/safe_mode.c msgid "" "\n" "You are in safe mode because:\n" msgstr "" +"\n" +"Вы в безопасном режиме потому что:\n" #: py/obj.c msgid " File \"%q\"" @@ -93,16 +100,21 @@ msgstr "" msgid "" "%d address pins, %d rgb pins and %d tiles indicate a height of %d, not %d" msgstr "" -"%d адресных пинов, %d rgb пинов и %d тайлов указывают высоту %d а не %d" +"Адресные контакты %d, контакты rgb %d и плитки %d обозначают высоту %d, а не " +"%d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -113,7 +125,7 @@ msgstr "%q" #: shared-bindings/microcontroller/Pin.c msgid "%q and %q contain duplicate pins" -msgstr "%q и %q содержат пины-дупликаты" +msgstr "%q и %q содержат пины дупликаты" #: ports/atmel-samd/common-hal/audioio/AudioOut.c msgid "%q and %q must be different" @@ -121,7 +133,7 @@ msgstr "%q и %q должны быть разными" #: shared-bindings/microcontroller/Pin.c msgid "%q contains duplicate pins" -msgstr "%q содержит пины-дупликаты" +msgstr "%q содержит пины дупликаты" #: ports/atmel-samd/common-hal/sdioio/SDCard.c msgid "%q failure: %d" @@ -129,7 +141,7 @@ msgstr "%q сбой: %d" #: py/argcheck.c msgid "%q in %q must be of type %q, not %q" -msgstr "" +msgstr "%q в %q должно быть типа %q, а не %q" #: ports/espressif/common-hal/espulp/ULP.c #: ports/mimxrt10xx/common-hal/audiobusio/__init__.c @@ -160,7 +172,7 @@ msgstr "%q является %q" #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "%q is read-only for this board" -msgstr "" +msgstr "%q читается только для этой доски" #: py/argcheck.c shared-bindings/usb_hid/Device.c msgid "%q length must be %d" @@ -192,7 +204,7 @@ msgstr "%q должно быть %d-%d" #: shared-bindings/displayio/Display.c msgid "%q must be 1 when %q is True" -msgstr "%q должно быть 1 когда %q is True" +msgstr "%q должен быть равен 1, если %q имеет значение True" #: py/argcheck.c shared-bindings/gifio/GifWriter.c #: shared-module/gifio/OnDiskGif.c @@ -205,29 +217,29 @@ msgstr "%q должно быть >= %d" #: shared-bindings/analogbufio/BufferedIn.c msgid "%q must be a bytearray or array of type 'H' or 'B'" -msgstr "%q должно быть bytearray или array типа 'H' или 'B'" +msgstr "%q должен быть массивом байтов или массивом типа «H» или «B»" #: shared-bindings/audiocore/RawSample.c msgid "%q must be a bytearray or array of type 'h', 'H', 'b', or 'B'" -msgstr "%q должно быть bytearray или array типа 'h', 'H', 'b', или 'B'" +msgstr "%q должен быть массивом байтов или массивом типа «h», «H», «b» или «B»" #: ports/espressif/common-hal/analogbufio/BufferedIn.c msgid "%q must be array of type 'H'" -msgstr "" +msgstr "%q должен быть массивом типа 'H \"" #: shared-module/synthio/__init__.c msgid "%q must be array of type 'h'" -msgstr "" +msgstr "%q должен быть массивом типа 'h \"" #: ports/raspberrypi/bindings/cyw43/__init__.c py/argcheck.c py/objexcept.c #: shared-bindings/canio/CAN.c shared-bindings/digitalio/Pull.c #: shared-module/synthio/Synthesizer.c msgid "%q must be of type %q or %q, not %q" -msgstr "" +msgstr "%q должно быть типа%q или%q, а не%q" #: py/argcheck.c py/objstrunicode.c shared-module/synthio/__init__.c msgid "%q must be of type %q, not %q" -msgstr "" +msgstr "%q должно быть типа %q, а не %q" #: ports/atmel-samd/common-hal/busio/UART.c msgid "%q must be power of 2" @@ -264,19 +276,19 @@ msgstr "%q=%q" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "%q[%u] shifts in more bits than pin count" -msgstr "" +msgstr "%q [%u] смещается в большем количестве чем количество пинов" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "%q[%u] shifts out more bits than pin count" -msgstr "" +msgstr "%q[%u] смещает больше битов чем количество выводов" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "%q[%u] uses extra pin" -msgstr "" +msgstr "%q[%u] использует дополнительный контакт" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "%q[%u] waits on input outside of count" -msgstr "" +msgstr "%q [%u] ожидает ввода за пределами графа" #: ports/espressif/common-hal/espidf/__init__.c #, c-format @@ -382,51 +394,52 @@ msgstr "'S' и 'O' не являются поддерживаемыми типа #: py/compile.c msgid "'align' requires 1 argument" -msgstr "'align' требует 1 аргумент" +msgstr "«выравнивание» требует 1 аргумента" #: py/compile.c msgid "'await' outside function" -msgstr "'await' вне функции" +msgstr "«ожидание» внешняя функция" #: py/compile.c msgid "'await', 'async for' or 'async with' outside async function" -msgstr "'await', 'async for' или 'async with' вне асинхронной функции" +msgstr "" +"«ожидание», «асинхронность для» или «асинхронность с» вне асинхронной функции" #: py/compile.c msgid "'break' outside loop" -msgstr "'break' вне цикла" +msgstr "«разорвать» внешний цикл" #: py/compile.c msgid "'continue' outside loop" -msgstr "'continue' вне цикла" +msgstr "«продолжить» вне цикла" #: py/compile.c msgid "'data' requires at least 2 arguments" -msgstr "'data' требует как минимум 2 аргумента" +msgstr "«данные» требуют как минимум 2 аргумента" #: py/compile.c msgid "'data' requires integer arguments" -msgstr "'data' требует целочисленные аргументы" +msgstr "«данные» требуют целочисленных аргументов" #: py/compile.c msgid "'label' requires 1 argument" -msgstr "'label' требует 1 аргумент" +msgstr "«метка» требует 1 аргумент" #: py/compile.c msgid "'return' outside function" -msgstr "'return' вне функции" +msgstr "«возврат» внешняя функция" #: py/compile.c msgid "'yield from' inside async function" -msgstr "'yield from' внутри асинхронной функции" +msgstr "«выход из» внутри асинхронной функции" #: py/compile.c msgid "'yield' outside function" -msgstr "'yield' вне функции" +msgstr "внешняя функция \"выход\"" #: py/compile.c msgid "* arg after **" -msgstr "" +msgstr "* аргумент после **" #: py/compile.c msgid "*x must be assignment target" @@ -442,7 +455,7 @@ msgstr "0.0 в комплексную степень" #: py/modbuiltins.c msgid "3-arg pow() not supported" -msgstr "3-аргументный pow() не поддерживается" +msgstr "Pow() с 3 аргументами не поддерживается" #: ports/atmel-samd/common-hal/alarm/pin/PinAlarm.c #: ports/atmel-samd/common-hal/countio/Counter.c @@ -450,13 +463,9 @@ msgstr "3-аргументный pow() не поддерживается" msgid "A hardware interrupt channel is already in use" msgstr "Канал аппаратного прерывания уже используется" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 используется WiFi" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" -msgstr "" +msgstr "AP не может быть запущен" #: shared-bindings/_bleio/Address.c shared-bindings/ipaddress/IPv4Address.c #, c-format @@ -465,9 +474,14 @@ msgstr "Адрес должен быть длиной %d байт" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "Диапазон адресов не разрешен" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "Обертывание диапазона адресов" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "Все периферийные устройства CAN уже используются" @@ -507,7 +521,7 @@ msgstr "Все каналы уже используются" #: ports/raspberrypi/common-hal/usb_host/Port.c msgid "All dma channels in use" -msgstr "" +msgstr "Все используемые каналы dma" #: ports/atmel-samd/common-hal/audioio/AudioOut.c msgid "All event channels in use" @@ -548,7 +562,7 @@ msgstr "Все таймеры уже используются" #: ports/espressif/common-hal/_bleio/Adapter.c #: ports/nrf/common-hal/_bleio/Adapter.c msgid "Already advertising." -msgstr "Уже объявляемся (advertising)." +msgstr "Уже реклама." #: ports/atmel-samd/common-hal/canio/Listener.c msgid "Already have all-matches listener" @@ -569,11 +583,11 @@ msgstr "Поиск сетей wifi уже происходит" #: shared-module/os/getenv.c #, c-format msgid "An error occurred while retrieving '%s':\n" -msgstr "" +msgstr "Произошла ошибка при получении '%s':\n" #: ports/stm/common-hal/audiopwmio/PWMAudioOut.c msgid "Another PWMAudioOut is already active" -msgstr "Другой PWMAudioOut уже активен" +msgstr "Другой аудиовыход PWM уже активен" #: ports/atmel-samd/common-hal/pulseio/PulseOut.c #: ports/cxd56/common-hal/pulseio/PulseOut.c @@ -600,7 +614,7 @@ msgstr "Преобразование звука не реализовано" #: shared-bindings/wifi/Radio.c msgid "AuthMode.OPEN is not used with password" -msgstr "AuthMode.OPEN не используется с паролем" +msgstr "Режим авторизации.OPEN не используется с паролем" #: shared-bindings/wifi/Radio.c supervisor/shared/web_workflow/web_workflow.c msgid "Authentication failure" @@ -620,8 +634,7 @@ msgstr "" #: ports/espressif/common-hal/canio/CAN.c msgid "Baudrate not supported by peripheral" -msgstr "" -"Скорость обмена данными (Baudrate) не поддерживается периферийным устройством" +msgstr "Скорость передачи данных не поддерживается периферийным устройством" #: shared-module/displayio/Display.c #: shared-module/framebufferio/FramebufferDisplay.c @@ -645,15 +658,16 @@ msgstr "Битовая глубина должна быть кратна 8." #: shared-bindings/bitmaptools/__init__.c msgid "Bitmap size and bits per value must match" -msgstr "Размер bitmap и количество бит-на-значение должны совпадать" +msgstr "" +"Размер растрового изображения и число битов на значение должны совпадать" #: supervisor/shared/safe_mode.c msgid "Boot device must be first (interface #0)." -msgstr "" +msgstr "Загрузочное устройство должно быть первым (интерфейс #0)." #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "Both RX and TX required for flow control" -msgstr "Для управления потоком требуется как RX, так и TX" +msgstr "Для управления потоком требуется как RX так и TX" #: ports/atmel-samd/common-hal/rotaryio/IncrementalEncoder.c msgid "Both pins must support hardware interrupts" @@ -675,7 +689,7 @@ msgstr "Элементы буфера должны иметь длину не б #: shared-bindings/framebufferio/FramebufferDisplay.c msgid "Buffer is not a bytearray." -msgstr "Буфер не является байтовым массивом (bytearray)." +msgstr "Буфер не является байтовым массивом." #: ports/stm/common-hal/audiopwmio/PWMAudioOut.c #, c-format @@ -700,7 +714,7 @@ msgstr "Буфер слишком короткий на %d байт" #: shared-bindings/framebufferio/FramebufferDisplay.c #: shared-bindings/struct/__init__.c shared-module/struct/__init__.c msgid "Buffer too small" -msgstr "" +msgstr "Слишком маленький буфер" #: ports/espressif/common-hal/imagecapture/ParallelImageCapture.c msgid "Buffers must be same size" @@ -712,7 +726,7 @@ msgstr "Буферы должны быть одинакового размера #: ports/raspberrypi/common-hal/paralleldisplay/ParallelBus.c #, c-format msgid "Bus pin %d is already in use" -msgstr "Пин шины %d уже используется" +msgstr "Вывод шины %d уже используется" #: shared-bindings/_bleio/UUID.c msgid "Byte buffer must be 16 bytes." @@ -724,7 +738,7 @@ msgstr "Блоки CBC должны быть кратны 16 байтам" #: supervisor/shared/safe_mode.c msgid "CIRCUITPY drive could not be found or created." -msgstr "Не удалось найти или создать диск CIRCUITPY." +msgstr "Диск CIRCUTPY не удалось найти или создать." #: ports/espressif/common-hal/espidf/__init__.c msgid "CRC or checksum was invalid" @@ -732,7 +746,7 @@ msgstr "CRC или контрольная сумма неправильная" #: py/objtype.c msgid "Call super().__init__() before accessing native object." -msgstr "Вызовите super().__init__() перед обращением к родному объекту." +msgstr "Вызовите super().__init__() перед доступом к собственному объекту." #: ports/cxd56/common-hal/camera/Camera.c msgid "Camera init" @@ -740,29 +754,28 @@ msgstr "Иницализация камеры" #: ports/espressif/common-hal/alarm/pin/PinAlarm.c msgid "Can only alarm on RTC IO from deep sleep." -msgstr "Сигнал из глубокого сна может подаваться только на пине RTC IO." +msgstr "Возможен только сигнал тревоги по RTC IO из глубокого сна." #: ports/espressif/common-hal/alarm/pin/PinAlarm.c msgid "Can only alarm on one low pin while others alarm high from deep sleep." msgstr "" -"Сигнал из глубокого сна может подаваться по низкому уровню только на одном " -"пане, пока остальные подают сигнал по высокому уровню." +"Может сигнализировать только по одному низкому контакту в то время как " +"другие сигнализируют о высоком уровне после глубокого сна." #: ports/espressif/common-hal/alarm/pin/PinAlarm.c msgid "Can only alarm on two low pins from deep sleep." msgstr "" -"Сигнал из глубокого сна может подаваться только на двух пинах по низкому " -"уровню." +"Из глубокого сна может сигнализировать только по двум низким контактам." #: ports/espressif/common-hal/_bleio/Characteristic.c #: ports/nrf/common-hal/_bleio/Characteristic.c msgid "Can't set CCCD on local Characteristic" -msgstr "Невозможно установить CCCD на локальную Characteristic" +msgstr "Невозможно установить CCCD для локальной характеристики" #: shared-bindings/storage/__init__.c shared-bindings/usb_cdc/__init__.c #: shared-bindings/usb_hid/__init__.c shared-bindings/usb_midi/__init__.c msgid "Cannot change USB devices now" -msgstr "Сейчас невозможно изменить USB-устройства" +msgstr "Невозможно изменить USB устройство сейчас" #: shared-bindings/_bleio/Adapter.c msgid "Cannot create a new Adapter; use _bleio.adapter;" @@ -779,7 +792,7 @@ msgstr "Невозможно удалить значения" #: ports/nrf/common-hal/digitalio/DigitalInOut.c #: ports/raspberrypi/common-hal/digitalio/DigitalInOut.c msgid "Cannot get pull while in output mode" -msgstr "Невозможно установить подтяжку в режиме output" +msgstr "Невозможно получить pull в режиме вывода" #: ports/nrf/common-hal/microcontroller/Processor.c msgid "Cannot get temperature" @@ -788,13 +801,12 @@ msgstr "Невозможно получить температуру" #: shared-bindings/_bleio/Adapter.c msgid "Cannot have scan responses for extended, connectable advertisements." msgstr "" -"Невозможно иметь ответы сканирования для расширенных, подключаемых " -"объявлений (advertisements)." +"Не может быть ответов на сканирование для расширенных подключаемых рекламных " +"объявлений." #: ports/espressif/common-hal/alarm/pin/PinAlarm.c msgid "Cannot pull on input-only pin." -msgstr "" -"Невозможно установить подтяжку на пине, предназначенном только для ввода." +msgstr "Невозможно вытащить контакт только для ввода." #: shared-bindings/audiobusio/PDMIn.c msgid "Cannot record to a file" @@ -816,7 +828,7 @@ msgstr "Невозможно установить параметры сокет #: shared-bindings/digitalio/DigitalInOut.c msgid "Cannot set value when direction is input." -msgstr "Невозможно установить значение в режиме input." +msgstr "Невозможно установить значение при вводе направления." #: ports/espressif/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c @@ -825,30 +837,28 @@ msgstr "Невозможно указать RTS или CTS в режиме RS485 #: py/objslice.c msgid "Cannot subclass slice" -msgstr "Срез субкласса невозможен" +msgstr "Невозможно создать подкласс среза" #: shared-bindings/pwmio/PWMOut.c msgid "Cannot vary frequency on a timer that is already in use" -msgstr "Невозможно изменить частоту на таймере, который уже используется" +msgstr "Невозможно изменить частоту на таймере который уже используется" #: ports/nrf/common-hal/alarm/pin/PinAlarm.c -#, fuzzy msgid "Cannot wake on pin edge, only level" msgstr "" -"Невозможно проснуться по изменению логического уровня (CHANGE), только по " -"уровню (LEVEL)" +"Невозможно проснуться по изменению логического уровня, только по уровню" #: ports/espressif/common-hal/alarm/pin/PinAlarm.c msgid "Cannot wake on pin edge. Only level." -msgstr "Невозможно проснуться по спаду/росту на пине. Только по уровню." +msgstr "Невозможно проснуться по спаду росту на пине. Только по уровню." #: shared-bindings/_bleio/CharacteristicBuffer.c msgid "CharacteristicBuffer writing not provided" -msgstr "Запись в CharacteristicBuffer не предусмотрена" +msgstr "ХарактеристикаЗапись в буфер не предусмотрена" #: supervisor/shared/safe_mode.c msgid "CircuitPython core code crashed hard. Whoops!\n" -msgstr "Код ядра CircuitPython сильно крашнулся. Упс!\n" +msgstr "Основной код CircuitPython сильно разбился. Упс!\n" #: shared-module/bitbangio/I2C.c msgid "Clock stretch too long" @@ -868,11 +878,11 @@ msgstr "" #: shared-bindings/bitmaptools/__init__.c msgid "Coordinate arrays have different lengths" -msgstr "" +msgstr "Координатные массивы имеют разные длины" #: shared-bindings/bitmaptools/__init__.c msgid "Coordinate arrays types have different sizes" -msgstr "" +msgstr "Типы массивов координат имеют разные размеры" #: ports/espressif/common-hal/neopixel_write/__init__.c msgid "Could not retrieve clock" @@ -884,7 +894,7 @@ msgstr "Не удалось задать адрес" #: shared-bindings/pwmio/PWMOut.c msgid "Could not start PWM" -msgstr "Не удалось запустить ШИМ" +msgstr "Не удалось запустить PWM" #: ports/stm/common-hal/busio/UART.c msgid "Could not start interrupt, RX busy" @@ -896,15 +906,15 @@ msgstr "Не удалось выделить место для декодера" #: ports/stm/common-hal/analogio/AnalogOut.c msgid "DAC Channel Init Error" -msgstr "Ошибка инициализации канала ЦАП" +msgstr "Ошибка инициализации канала DAC" #: ports/stm/common-hal/analogio/AnalogOut.c msgid "DAC Device Init Error" -msgstr "Ошибка инициализации устройства ЦАП" +msgstr "Ошибка инициализации устройства DAC" #: ports/atmel-samd/common-hal/audioio/AudioOut.c msgid "DAC already in use" -msgstr "ЦАП уже используется" +msgstr "DAC уже используется" #: ports/atmel-samd/common-hal/paralleldisplay/ParallelBus.c #: ports/nrf/common-hal/paralleldisplay/ParallelBus.c @@ -933,7 +943,7 @@ msgstr "" #: shared-bindings/audiobusio/PDMIn.c msgid "Destination capacity is smaller than destination_length." -msgstr "Емкость destination меньше, чем destination_length." +msgstr "Емкость места назначения меньше длины места назначения." #: ports/nrf/common-hal/audiobusio/I2SOut.c msgid "Device in use" @@ -942,7 +952,7 @@ msgstr "Устройство используется" #: shared-bindings/displayio/Display.c #: shared-bindings/framebufferio/FramebufferDisplay.c msgid "Display must have a 16 bit colorspace." -msgstr "Дисплей должен иметь 16-битное цветовое пространство." +msgstr "Дисплей должен иметь 16 битное цветовое пространство." #: shared-bindings/displayio/Display.c #: shared-bindings/displayio/EPaperDisplay.c @@ -956,13 +966,12 @@ msgstr "Выполнено" #: shared-bindings/digitalio/DigitalInOut.c msgid "Drive mode not used when direction is input." -msgstr "Drive mode не используется, когда направление является входным." +msgstr "Режим движения не используется при вводе направления." #: py/obj.c -#, fuzzy msgid "During handling of the above exception, another exception occurred:" msgstr "" -"Во время обработки вышеупомянутого исключения произошло другое исключение:" +"При обращении с вышеуказанным исключением произошло еще одно исключение:" #: shared-bindings/aesio/aes.c msgid "ECB only operates on 16 bytes at a time" @@ -982,11 +991,11 @@ msgstr "Канал EXTINT уже используется" #: extmod/modure.c msgid "Error in regex" -msgstr "Ошибка в регулярном выражении(regex)" +msgstr "Ошибка в регулярном выражении" #: supervisor/shared/safe_mode.c msgid "Error in safemode.py." -msgstr "" +msgstr "Ошибка в сейфе. py." #: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "Error: Failure to bind" @@ -994,7 +1003,7 @@ msgstr "Ошибка: Сбой привязки" #: shared-bindings/alarm/__init__.c msgid "Expected a kind of %q" -msgstr "" +msgstr "Ожидаемый вид %q" #: ports/espressif/common-hal/_bleio/Adapter.c #: ports/nrf/common-hal/_bleio/Adapter.c @@ -1003,15 +1012,15 @@ msgstr "Расширенные объявления с ответом скани #: extmod/ulab/code/numpy/fft/fft_tools.c msgid "FFT is defined for ndarrays only" -msgstr "БПФ определено только для ndarrays" +msgstr "FFT определено только для массивов ndarrays" #: extmod/ulab/code/numpy/fft/fft_tools.c msgid "FFT is implemented for linear arrays only" -msgstr "БПФ реализовано только для линейных массивов" +msgstr "FFT реализовано только для линейных массивов" #: ports/espressif/common-hal/ssl/SSLSocket.c msgid "Failed SSL handshake" -msgstr "Не удался SSL handshake" +msgstr "Не удалось установить соединение SSL" #: shared-bindings/ps2io/Ps2.c msgid "Failed sending command." @@ -1045,7 +1054,7 @@ msgstr "Не удалось подключиться: внутренняя ош #: ports/nrf/common-hal/_bleio/Adapter.c msgid "Failed to connect: timeout" -msgstr "Не удалось подключиться: тайм-аут" +msgstr "Не удалось подключиться: таймаут" #: shared-module/audiomp3/MP3Decoder.c msgid "Failed to parse MP3 file" @@ -1075,14 +1084,12 @@ msgid "Filters too complex" msgstr "Фильтры слишком сложные" #: ports/espressif/common-hal/dualbank/__init__.c -#, fuzzy msgid "Firmware is duplicate" -msgstr "Прошивка является дубликатом" +msgstr "Прошивка дублируется" #: ports/espressif/common-hal/dualbank/__init__.c -#, fuzzy msgid "Firmware is invalid" -msgstr "Прошивка является неправильной" +msgstr "Недопустимая прошивка" #: ports/espressif/common-hal/dualbank/__init__.c msgid "Firmware is too big" @@ -1091,12 +1098,14 @@ msgstr "Прошивка слишком большая" #: shared-bindings/bitmaptools/__init__.c msgid "For L8 colorspace, input bitmap must have 8 bits per pixel" msgstr "" -"Для цветового пространства L8 входной bitmap должен иметь 8 бит на пиксель" +"Для цветового пространства L8 входное растровое изображение должно иметь 8 " +"бит на пиксель" #: shared-bindings/bitmaptools/__init__.c msgid "For RGB colorspaces, input bitmap must have 16 bits per pixel" msgstr "" -"Для цветового пространства RGB входной bitmap должен иметь 16 бит на пиксель" +"Для цветовых пространств RGB входное растровое изображение должно иметь 16 " +"бит на пиксель" #: ports/cxd56/common-hal/camera/Camera.c msgid "Format not supported" @@ -1112,8 +1121,8 @@ msgstr "" #: shared-bindings/pwmio/PWMOut.c msgid "Frequency must match existing PWMOut using this timer" msgstr "" -"Частота должна соответствовать существующему PWMOut, использующему этот " -"таймер" +"Частота должна соответствовать существующему выходу PWM с использованием " +"этого таймера" #: shared-bindings/bitbangio/I2C.c shared-bindings/bitbangio/SPI.c #: shared-bindings/busio/I2C.c shared-bindings/busio/SPI.c @@ -1145,7 +1154,7 @@ msgstr "Полудуплексный SPI не реализован" #: supervisor/shared/safe_mode.c msgid "Hard fault: memory access or instruction error." -msgstr "" +msgstr "Жесткая ошибка: доступ к памяти или ошибка инструкции." #: ports/mimxrt10xx/common-hal/busio/SPI.c #: ports/mimxrt10xx/common-hal/busio/UART.c ports/stm/common-hal/busio/I2C.c @@ -1156,12 +1165,14 @@ msgstr "Оборудование используется, попробуйте #: supervisor/shared/safe_mode.c msgid "Heap allocation when VM not running." -msgstr "" +msgstr "Выделение кучи, когда виртуальная машина не запущена." #: supervisor/shared/safe_mode.c msgid "" "Heap was corrupted because the stack was too small. Increase stack size." msgstr "" +"Куча была повреждена, потому что стек был слишком маленьким. Увеличьте " +"размер стека." #: extmod/vfs_posix_file.c py/objstringio.c msgid "I/O operation on closed file" @@ -1191,12 +1202,14 @@ msgstr "Неверный размер программы инициализац #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Initial set pin direction conflicts with initial out pin direction" msgstr "" -"Начальное направление пина set конфликтует с начальным направлением пина out" +"Исходное установленное направление штифта конфликтует с исходным " +"направлением вывода" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Initial set pin state conflicts with initial out pin state" msgstr "" -"Начальное состояние пина set конфликтует с начальным состоянием пина out" +"Исходное установленное состояние контакта конфликтует с исходным состоянием " +"выхода" #: ports/espressif/common-hal/watchdog/WatchDogTimer.c msgid "Initialization failed due to lack of memory" @@ -1205,7 +1218,7 @@ msgstr "Инициализация не удалась из-за нехватк #: shared-bindings/bitops/__init__.c #, c-format msgid "Input buffer length (%d) must be a multiple of the strand count (%d)" -msgstr "Длина входного буфера (%d) должна быть кратна количеству strand (%d)" +msgstr "Длина входного буфера (%d) должна быть кратна количеству цепочек (%d)" #: ports/atmel-samd/common-hal/pulseio/PulseIn.c msgid "Input taking too long" @@ -1246,13 +1259,12 @@ msgid "Internal error #%d" msgstr "Внутренняя ошибка #%d" #: supervisor/shared/safe_mode.c -#, fuzzy msgid "Internal watchdog timer expired." msgstr "Внутренний сторожевой таймер истек." #: supervisor/shared/safe_mode.c msgid "Interrupt error." -msgstr "" +msgstr "Прерванная ошибка." #: ports/mimxrt10xx/common-hal/audiobusio/__init__.c #: ports/mimxrt10xx/common-hal/pwmio/PWMOut.c @@ -1264,6 +1276,7 @@ msgid "Invalid %q" msgstr "Недопустимый %q" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1271,7 +1284,7 @@ msgstr "Недопустимый пин %q" #: ports/stm/common-hal/analogio/AnalogIn.c msgid "Invalid ADC Unit value" -msgstr "Недопустимое значение единицы АЦП" +msgstr "Недопустимое значение единицы ADC" #: ports/espressif/common-hal/_bleio/__init__.c #: ports/nrf/common-hal/_bleio/__init__.c @@ -1284,7 +1297,7 @@ msgstr "Неверный BSSID" #: main.c msgid "Invalid CIRCUITPY_PYSTACK_SIZE\n" -msgstr "" +msgstr "Недопустимый CIRCUITPY_PYSTACK_SIZE\n" #: shared-bindings/wifi/Radio.c msgid "Invalid MAC address" @@ -1310,7 +1323,7 @@ msgstr "Неверный data_pins[%d]" #: shared-module/msgpack/__init__.c msgid "Invalid format" -msgstr "" +msgstr "Недопустимый формат" #: shared-module/audiocore/WaveFile.c msgid "Invalid format chunk size" @@ -1318,11 +1331,11 @@ msgstr "Неверный размер блока формата" #: shared-bindings/wifi/Radio.c msgid "Invalid hex password" -msgstr "" +msgstr "Неверный шестнадцатеричный пароль" #: ports/espressif/common-hal/wifi/Radio.c msgid "Invalid multicast MAC address" -msgstr "Неверный MAC-адрес multicast" +msgstr "Неверный MAC-адрес многоадресной рассылки" #: ports/espressif/common-hal/espidf/__init__.c msgid "Invalid size" @@ -1339,7 +1352,7 @@ msgstr "Неверное состояние" #: shared-module/os/getenv.c msgid "Invalid unicode escape" -msgstr "" +msgstr "Недопустимое экранирование Юникода" #: shared-bindings/aesio/aes.c msgid "Key must be 16, 24, or 32 bytes long" @@ -1351,21 +1364,19 @@ msgstr "Ключ не найден" #: shared-module/is31fl3741/FrameBuffer.c msgid "LED mappings must match display size" -msgstr "" +msgstr "Светодиодные сопоставления должны соответствовать размеру дисплея" #: py/compile.c msgid "LHS of keyword arg must be an id" msgstr "LHS ключевого слова arg должен быть идентификатором(id)" #: shared-module/displayio/Group.c -#, fuzzy msgid "Layer already in a group" msgstr "Слой уже в группе (Group)" #: shared-module/displayio/Group.c -#, fuzzy msgid "Layer must be a Group or TileGrid subclass" -msgstr "Слой должен быть группой (Group) или субклассом TileGrid." +msgstr "Слой должен быть группой (Group) или субклассом TileGrid" #: ports/espressif/common-hal/espidf/__init__.c msgid "MAC address was invalid" @@ -1373,7 +1384,7 @@ msgstr "MAC адрес был недействительным" #: shared-bindings/is31fl3741/IS31FL3741.c msgid "Mapping must be a tuple" -msgstr "" +msgstr "Сопоставление должно быть кортежом" #: shared-bindings/audiobusio/PDMIn.c msgid "Microphone startup delay must be in range 0.0 to 1.0" @@ -1386,40 +1397,44 @@ msgstr "Размер данных различается" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Mismatched swap flag" -msgstr "Несоответствие флага swap" +msgstr "Несоответствующий флаг подкачки" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Missing first_in_pin. %q[%u] reads pin(s)" -msgstr "" +msgstr "Отсутствует first_in_pin. %q[%u] читает выводы" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Missing first_in_pin. %q[%u] shifts in from pin(s)" -msgstr "" +msgstr "Отсутствует first_in_pin. %q[%u] смещается от контакта (контактов)" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Missing first_in_pin. %q[%u] waits based on pin" -msgstr "" +msgstr "Отсутствует first_in_pin. Инструкция %d ожидает на основе пина" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Missing first_out_pin. %q[%u] shifts out to pin(s)" -msgstr "" +msgstr "Отсутствует first_out_pin. %q[%u] переключается на контакты" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Missing first_out_pin. %q[%u] writes pin(s)" -msgstr "" +msgstr "Отсутствует first_out_pin. %q[%u] записывает выводы" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Missing first_set_pin. %q[%u] sets pin(s)" -msgstr "" +msgstr "Отсутствует first_set_pin. %q[%u] устанавливает контакты" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Missing jmp_pin. %q[%u] jumps on pin" -msgstr "" +msgstr "Не хватает jmp_pin.%q [%u] прыгает на пин" #: shared-bindings/busio/UART.c shared-bindings/displayio/Group.c msgid "Must be a %q subclass." msgstr "Должен быть субклассом %q." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "Должен иметь 5/6/5 контактов RGB" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Пин MISO или MOSI должен быть предоставлен" @@ -1431,7 +1446,7 @@ msgstr "Количество используемых rgb-пинов должн #: supervisor/shared/safe_mode.c msgid "NLR jump failed. Likely memory corruption." -msgstr "Не удалось выполнить NLR jump. Вероятно, повреждение памяти." +msgstr "Прыжок NLR не удался. Вероятно повреждение памяти." #: ports/espressif/common-hal/nvm/ByteArray.c msgid "NVS Error" @@ -1439,7 +1454,7 @@ msgstr "Ошибка NVS" #: shared-bindings/socketpool/SocketPool.c msgid "Name or service not known" -msgstr "" +msgstr "Имя или услуга не известны" #: py/qstr.c msgid "Name too long" @@ -1447,11 +1462,13 @@ msgstr "Имя слишком длинное" #: shared-bindings/displayio/TileGrid.c msgid "New bitmap must be same size as old bitmap" -msgstr "Новый bitmap должен быть того же размера что и старый" +msgstr "" +"Новое растровое изображение должно быть того же размера, что и старое " +"растровое изображение" #: ports/espressif/common-hal/_bleio/__init__.c msgid "Nimble out of memory" -msgstr "" +msgstr "Изображение памяти" #: ports/atmel-samd/common-hal/busio/UART.c #: ports/espressif/common-hal/busio/SPI.c @@ -1468,12 +1485,12 @@ msgstr "Нет пина %q" #: ports/espressif/common-hal/_bleio/Characteristic.c #: ports/nrf/common-hal/_bleio/Characteristic.c msgid "No CCCD for this Characteristic" -msgstr "Нет CCCD для этой Characteristic" +msgstr "Для этой характеристики нет CCCD" #: ports/atmel-samd/common-hal/analogio/AnalogOut.c #: ports/stm/common-hal/analogio/AnalogOut.c msgid "No DAC on chip" -msgstr "ЦАП отсутствует на чипе" +msgstr "DAC отсутствует на чипе" #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c @@ -1484,12 +1501,12 @@ msgstr "Канал DMA не найден" #: ports/raspberrypi/common-hal/audiopwmio/PWMAudioOut.c msgid "No DMA pacing timer found" -msgstr "" +msgstr "Таймер стимуляции DMA не найден" #: shared-module/adafruit_bus_device/i2c_device/I2CDevice.c -#, fuzzy, c-format +#, c-format msgid "No I2C device at address: 0x%x" -msgstr "Не найдено устройство I2C по адресу: %x" +msgstr "Нет устройства I2C по адресу: %x" #: supervisor/shared/web_workflow/web_workflow.c msgid "No IP" @@ -1497,7 +1514,7 @@ msgstr "Нет IP" #: ports/atmel-samd/common-hal/frequencyio/FrequencyIn.c msgid "No available clocks" -msgstr "" +msgstr "Нет доступных часов" #: ports/espressif/common-hal/imagecapture/ParallelImageCapture.c msgid "No capture in progress" @@ -1505,7 +1522,7 @@ msgstr "Захват не ведется" #: shared-module/usb/core/Device.c msgid "No configuration set" -msgstr "" +msgstr "Нет конфигураций" #: shared-bindings/_bleio/PacketBuffer.c msgid "No connection: length cannot be determined" @@ -1525,7 +1542,7 @@ msgstr "Отсутствует аппаратный генератор случ #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "No in in program" -msgstr "Нет in в программе" +msgstr "Нет в программе" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "No in or out in program" @@ -1548,8 +1565,7 @@ msgstr "В программе отсутствует вывод" #: 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 "" -"Подтяжка на выводах SDA или SCL не обнаружена; проверь схему подключения" +msgstr "На SDA или SCL не обнаружено подтягивания; проверь свою проводку" #: shared-module/touchio/TouchIn.c msgid "No pulldown on pin; 1Mohm recommended" @@ -1560,7 +1576,6 @@ msgid "No space left on device" msgstr "На устройстве не осталось свободного места" #: py/moduerrno.c -#, fuzzy msgid "No such device" msgstr "Нет такого устройства" @@ -1574,11 +1589,11 @@ msgstr "Нет доступного таймера" #: shared-module/usb/core/Device.c msgid "No usb host port initialized" -msgstr "" +msgstr "Порт USB-хоста не инициализирован" #: ports/nrf/common-hal/_bleio/__init__.c msgid "Nordic system firmware out of memory" -msgstr "" +msgstr "Скандинавская система прошивки из памяти" #: shared-bindings/ipaddress/IPv4Address.c shared-bindings/ipaddress/__init__.c msgid "Not a valid IP string" @@ -1592,7 +1607,6 @@ msgstr "Не подключено" #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audioio/AudioOut.c #: shared-bindings/audiopwmio/PWMAudioOut.c -#, fuzzy msgid "Not playing" msgstr "Не воспроизводится (Not playing)" @@ -1610,16 +1624,15 @@ msgstr "" #: ports/nrf/common-hal/busio/UART.c msgid "Odd parity is not supported" -msgstr "" +msgstr "Нечетная четность не поддерживается" #: supervisor/shared/bluetooth/bluetooth.c msgid "Off" msgstr "Выключено" #: supervisor/shared/bluetooth/bluetooth.c -#, fuzzy msgid "Ok" -msgstr "Ok" +msgstr "Да" #: ports/atmel-samd/common-hal/audiobusio/PDMIn.c #: ports/raspberrypi/common-hal/audiobusio/PDMIn.c @@ -1646,15 +1659,15 @@ msgstr "" #: shared-bindings/_bleio/Adapter.c msgid "Only connectable advertisements can be directed" -msgstr "" +msgstr "Только подключаемые объявления могут быть направлены" #: ports/stm/common-hal/alarm/pin/PinAlarm.c msgid "Only edge detection is available on this hardware" -msgstr "" +msgstr "На этом аппаратном обеспечении доступно только обнаружение края" #: shared-bindings/ipaddress/__init__.c msgid "Only int or string supported for ip" -msgstr "" +msgstr "Для IP поддерживаются только int или строка" #: shared-module/displayio/OnDiskBitmap.c #, c-format @@ -1662,92 +1675,96 @@ msgid "" "Only monochrome, indexed 4bpp or 8bpp, and 16bpp or greater BMPs supported: " "%d bpp given" msgstr "" +"Только монохром, индексированный 4bpp или 8bpp, и 16bpp или больше BMP " +"поддерживаются: %d bpp" #: ports/espressif/common-hal/alarm/touch/TouchAlarm.c msgid "Only one %q can be set in deep sleep." -msgstr "Только один %q может быть погружен в глубокий сон." +msgstr "Только один %q может быть переведен в режим глубокого сна." #: ports/espressif/common-hal/espulp/ULPAlarm.c msgid "Only one %q can be set." -msgstr "" +msgstr "Можно установить только один %q." #: ports/espressif/common-hal/i2ctarget/I2CTarget.c #: ports/raspberrypi/common-hal/i2ctarget/I2CTarget.c msgid "Only one address is allowed" -msgstr "" +msgstr "Разрешен только один адрес" #: ports/atmel-samd/common-hal/alarm/time/TimeAlarm.c #: ports/nrf/common-hal/alarm/time/TimeAlarm.c #: ports/stm/common-hal/alarm/time/TimeAlarm.c msgid "Only one alarm.time alarm can be set" -msgstr "" +msgstr "Можно установить только один будильник" #: ports/espressif/common-hal/alarm/time/TimeAlarm.c #: ports/raspberrypi/common-hal/alarm/time/TimeAlarm.c msgid "Only one alarm.time alarm can be set." -msgstr "" +msgstr "Можно установить только один будильник alarm.time." #: shared-module/displayio/ColorConverter.c msgid "Only one color can be transparent at a time" -msgstr "" +msgstr "Только один цвет может быть прозрачным одновременно" #: py/moduerrno.c msgid "Operation not permitted" -msgstr "" +msgstr "Операция не разрешена" #: ports/espressif/common-hal/espidf/__init__.c msgid "Operation or feature not supported" -msgstr "" +msgstr "Операция или функция, не поддерживаемые" #: ports/espressif/common-hal/espidf/__init__.c msgid "Operation timed out" -msgstr "" +msgstr "Истекло время ожидания операции" #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Out of MDNS service slots" -msgstr "" +msgstr "Отсутствуют сервисные слоты MDNS" #: ports/espressif/common-hal/espidf/__init__.c msgid "Out of memory" -msgstr "" +msgstr "Не хватает памяти" #: ports/espressif/common-hal/socketpool/Socket.c #: ports/raspberrypi/common-hal/socketpool/Socket.c msgid "Out of sockets" -msgstr "" +msgstr "Вне розеток" #: ports/raspberrypi/bindings/rp2pio/StateMachine.c msgid "Out-buffer elements must be <= 4 bytes long" -msgstr "" +msgstr "Элементы вне буфера должны иметь длину <= 4 байта" #: shared-bindings/audiobusio/PDMIn.c msgid "Oversample must be multiple of 8." -msgstr "" +msgstr "Передискретизация должна быть кратна 8." #: shared-bindings/pwmio/PWMOut.c msgid "" "PWM frequency not writable when variable_frequency is False on construction." msgstr "" +"Частота PWM не записывается, если variable_frequency имеет значение False " +"при построении." #: ports/stm/common-hal/pwmio/PWMOut.c msgid "PWM restart" -msgstr "" +msgstr "PWM перезагрузка" #: ports/raspberrypi/common-hal/countio/Counter.c msgid "PWM slice already in use" -msgstr "" +msgstr "PWM уже используется" #: ports/raspberrypi/common-hal/countio/Counter.c msgid "PWM slice channel A already in use" -msgstr "" +msgstr "PWM канал среза A уже используется" #: ports/espressif/common-hal/audiobusio/__init__.c msgid "Peripheral in use" -msgstr "" +msgstr "Периферийные устройства в использовании" #: py/moduerrno.c msgid "Permission denied" -msgstr "" +msgstr "Отказано в разрешении" #: ports/stm/common-hal/alarm/pin/PinAlarm.c msgid "Pin cannot wake from Deep Sleep" @@ -1781,9 +1798,8 @@ msgid "" "bytes. If this cannot be avoided, pass allow_inefficient=True to the " "constructor" msgstr "" -"Pinout использует %d байт на элемент, что потребляет больше, чем идеальные " -"%d байт. Если этого нельзя избежать, передайте allow_inefficient=True в " -"конструктор" +"Распиновка использует %d байт на элемент, что превышает идеальное %d байт. " +"Если этого нельзя избежать, передайте конструктору allow_inefficient=True" #: ports/raspberrypi/common-hal/imagecapture/ParallelImageCapture.c msgid "Pins must be sequential" @@ -1795,27 +1811,28 @@ msgstr "Пины должны быть последовательными выв #: ports/raspberrypi/common-hal/audiopwmio/PWMAudioOut.c msgid "Pins must share PWM slice" -msgstr "Пины должны иметь общий срез ШИМ" +msgstr "Пины должны иметь общий срез PWM" #: shared-module/usb/core/Device.c msgid "Pipe error" -msgstr "" +msgstr "Ошибка трубопровода" #: py/builtinhelp.c msgid "Plus any modules on the filesystem\n" -msgstr "" +msgstr "Плюс любые модули в файловой системе\n" #: shared-module/vectorio/Polygon.c msgid "Polygon needs at least 3 points" -msgstr "" +msgstr "Полигону необходимо как минимум 3 точки" #: supervisor/shared/safe_mode.c msgid "Power dipped. Make sure you are providing enough power." msgstr "" +"Мощность просела. Убедитесь, что вы обеспечиваете достаточную мощность." #: shared-bindings/_bleio/Adapter.c msgid "Prefix buffer must be on the heap" -msgstr "" +msgstr "Буфер префикса должен находиться в куче" #: main.c msgid "Press any key to enter the REPL. Use CTRL-D to reload.\n" @@ -1825,182 +1842,183 @@ msgstr "" #: main.c msgid "Pretending to deep sleep until alarm, CTRL-C or file write.\n" -msgstr "Притворяюсь глубоко спать до сигнала, CTRL-C или запись в файл.\n" +msgstr "" +"Притворяюсь глубоким сном до сигнала тревоги, CTRL-C или записи файла.\n" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Program does IN without loading ISR" -msgstr "" +msgstr "Программа выполняет IN без загрузки ISR" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "Program does OUT without loading OSR" -msgstr "" +msgstr "Программа выполняет ВЫХОД без загрузки OSR" #: ports/raspberrypi/bindings/rp2pio/StateMachine.c msgid "Program size invalid" -msgstr "" +msgstr "Недопустимый размер программы" #: ports/espressif/common-hal/espulp/ULP.c msgid "Program too long" -msgstr "" +msgstr "Слишком длинная программа" #: shared-bindings/digitalio/DigitalInOut.c msgid "Pull not used when direction is output." -msgstr "" +msgstr "Тяга не используется, когда выводится направление." #: ports/atmel-samd/common-hal/watchdog/WatchDogTimer.c #: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "RAISE mode is not implemented" -msgstr "" +msgstr "Режим RAISE не реализован" #: ports/raspberrypi/common-hal/countio/Counter.c msgid "RISE_AND_FALL not available on this chip" -msgstr "" +msgstr "RISE_AND_FALL недоступен на этом чипе" #: ports/stm/common-hal/os/__init__.c msgid "RNG DeInit Error" -msgstr "" +msgstr "Ошибка деинициализации генератора случайных чисел" #: ports/stm/common-hal/os/__init__.c msgid "RNG Init Error" -msgstr "" +msgstr "Ошибка инициализации RNG" #: 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 msgid "RS485" -msgstr "" +msgstr "RS485" #: ports/espressif/common-hal/busio/UART.c #: ports/mimxrt10xx/common-hal/busio/UART.c msgid "RS485 inversion specified when not in RS485 mode" -msgstr "" +msgstr "Инверсия RS485 указана, когда она не находится в режиме RS485" #: shared-bindings/alarm/time/TimeAlarm.c shared-bindings/time/__init__.c msgid "RTC is not supported on this board" -msgstr "" +msgstr "RTC не поддерживается на этой плате" #: ports/stm/common-hal/os/__init__.c msgid "Random number generation error" -msgstr "" +msgstr "Ошибка генерации случайных чисел" #: shared-bindings/_bleio/__init__.c #: shared-bindings/memorymonitor/AllocationSize.c #: shared-bindings/pulseio/PulseIn.c shared-module/bitmaptools/__init__.c #: shared-module/displayio/Bitmap.c msgid "Read-only" -msgstr "" +msgstr "Только для чтения" #: extmod/vfs_fat.c py/moduerrno.c msgid "Read-only filesystem" -msgstr "" +msgstr "Файловая система только для чтения" #: ports/espressif/common-hal/espidf/__init__.c msgid "Received response was invalid" -msgstr "" +msgstr "Полученный ответ недействителен" #: supervisor/shared/bluetooth/bluetooth.c msgid "Reconnecting" -msgstr "" +msgstr "Повторное соединение" #: shared-bindings/displayio/EPaperDisplay.c msgid "Refresh too soon" -msgstr "" +msgstr "Слишком раннее обновление" #: shared-bindings/canio/RemoteTransmissionRequest.c msgid "RemoteTransmissionRequests limited to 8 bytes" -msgstr "" +msgstr "Запросы на удаленную передачу ограничены 8 байтами" #: shared-bindings/aesio/aes.c msgid "Requested AES mode is unsupported" -msgstr "" +msgstr "Запрошенный режим AES не поддерживается" #: ports/espressif/common-hal/espidf/__init__.c msgid "Requested resource not found" -msgstr "" +msgstr "Запрошенный ресурс не найден" #: ports/atmel-samd/common-hal/audioio/AudioOut.c msgid "Right channel unsupported" -msgstr "" +msgstr "Правый канал не поддерживается" #: main.c msgid "Running in safe mode! Not running saved code.\n" -msgstr "" +msgstr "Работает в безопасном режиме! Сохраненный код не выполняется.\n" #: shared-module/sdcardio/SDCard.c msgid "SD card CSD format not supported" -msgstr "" +msgstr "Формат CSD SD-карты не поддерживается" #: ports/cxd56/common-hal/sdioio/SDCard.c msgid "SDCard init" -msgstr "" +msgstr "Инициализация SD-карты" #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO GetCardInfo Error %d" -msgstr "" +msgstr "Ошибка получения информации о карте SDIO %d" #: ports/stm/common-hal/sdioio/SDCard.c #, c-format msgid "SDIO Init Error %d" -msgstr "" +msgstr "Ошибка инициализации SDIO %d" #: ports/espressif/common-hal/busio/SPI.c msgid "SPI configuration failed" -msgstr "" +msgstr "Сбой конфигурации SPI" #: ports/stm/common-hal/busio/SPI.c msgid "SPI init error" -msgstr "" +msgstr "Ошибка инициализации SPI" #: ports/raspberrypi/common-hal/busio/SPI.c msgid "SPI peripheral in use" -msgstr "" +msgstr "Используемое периферийное устройство SPI" #: ports/stm/common-hal/busio/SPI.c msgid "SPI re-init" -msgstr "" +msgstr "Повторная инициализация SPI" #: shared-bindings/is31fl3741/FrameBuffer.c msgid "Scale dimensions must divide by 3" -msgstr "" +msgstr "Размеры шкалы необходимо разделить на 3" #: ports/espressif/common-hal/_bleio/Adapter.c #: ports/nrf/common-hal/_bleio/Adapter.c msgid "Scan already in progress. Stop with stop_scan." -msgstr "" +msgstr "Сканирование уже выполняется. Остановитесь на stop_scan." #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "Serializer in use" -msgstr "" +msgstr "Сериализатор используется" #: shared-bindings/ssl/SSLContext.c msgid "Server side context cannot have hostname" -msgstr "" +msgstr "Контекст на стороне сервера не может иметь имя хоста" #: ports/cxd56/common-hal/camera/Camera.c msgid "Size not supported" -msgstr "" +msgstr "Размер не поддерживается" #: shared-bindings/alarm/SleepMemory.c shared-bindings/memorymap/AddressRange.c #: shared-bindings/nvm/ByteArray.c msgid "Slice and value different lengths." -msgstr "" +msgstr "Нарежьте и оцените разную длину." #: shared-bindings/displayio/Bitmap.c shared-bindings/displayio/Group.c #: shared-bindings/displayio/TileGrid.c #: shared-bindings/memorymonitor/AllocationSize.c #: shared-bindings/pulseio/PulseIn.c msgid "Slices not supported" -msgstr "" +msgstr "Фрагменты не поддерживаются" #: ports/espressif/common-hal/socketpool/SocketPool.c #: ports/raspberrypi/common-hal/socketpool/SocketPool.c msgid "SocketPool can only be used with wifi.radio" -msgstr "" +msgstr "SocketPool можно использовать только с wifi.radio" #: shared-bindings/aesio/aes.c msgid "Source and destination buffers must be the same length" -msgstr "" +msgstr "Исходный и конечный буферы должны иметь одинаковую длину" #: shared-bindings/paralleldisplay/ParallelBus.c msgid "Specify exactly one of data0 or data_pins" @@ -2008,35 +2026,38 @@ msgstr "Укажите точно один из data0 или data_pins" #: extmod/modure.c msgid "Splitting with sub-captures" -msgstr "" +msgstr "Разделение с помощью субзахватов" #: ports/raspberrypi/common-hal/audiopwmio/PWMAudioOut.c msgid "Stereo left must be on PWM channel A" -msgstr "" +msgstr "Стерео слева должно быть на PWM-канале A" #: ports/raspberrypi/common-hal/audiopwmio/PWMAudioOut.c msgid "Stereo right must be on PWM channel B" -msgstr "" +msgstr "Стерео справа должно быть на PWM-канале B" #: shared-bindings/alarm/time/TimeAlarm.c msgid "Supply one of monotonic_time or epoch_time" -msgstr "" +msgstr "Поставьте один из monotonic_time или epoch_time" #: shared-bindings/gnss/GNSS.c msgid "System entry must be gnss.SatelliteSystem" -msgstr "" +msgstr "Системная запись должна быть gnss. Спутниковая система" #: ports/stm/common-hal/microcontroller/Processor.c msgid "Temperature read timed out" -msgstr "" +msgstr "Истекло время ожидания считывания температуры" #: supervisor/shared/safe_mode.c msgid "The `microcontroller` module was used to boot into safe mode." msgstr "" +"Модуль «микроконтроллер» использовался для загрузки в безопасном режиме." #: py/obj.c msgid "The above exception was the direct cause of the following exception:" msgstr "" +"Вышеупомянутое исключение было непосредственной причиной следующего " +"исключения:" #: shared-bindings/rgbmatrix/RGBMatrix.c msgid "The length of rgb_pins must be 6, 12, 18, 24, or 30" @@ -2044,27 +2065,27 @@ msgstr "Длина rgb_pins должна быть 6, 12, 18, 24 или 30" #: shared-module/audiomixer/MixerVoice.c msgid "The sample's bits_per_sample does not match the mixer's" -msgstr "" +msgstr "Bits_per_sample сэмпла не соответствует битам микшера" #: shared-module/audiomixer/MixerVoice.c msgid "The sample's channel count does not match the mixer's" -msgstr "" +msgstr "Количество каналов образца не совпадает с количеством каналов микшера" #: shared-module/audiomixer/MixerVoice.c msgid "The sample's sample rate does not match the mixer's" -msgstr "" +msgstr "Частота дискретизации семпла не соответствует частоте микшера" #: shared-module/audiomixer/MixerVoice.c msgid "The sample's signedness does not match the mixer's" -msgstr "" +msgstr "Подпись семпла не совпадает с подписью микшера" #: supervisor/shared/safe_mode.c msgid "Third-party firmware fatal error." -msgstr "" +msgstr "Неустранимая ошибка прошивки стороннего производителя." #: shared-module/imagecapture/ParallelImageCapture.c msgid "This microcontroller does not support continuous capture." -msgstr "" +msgstr "Этот микроконтроллер не поддерживает непрерывный захват." #: shared-module/paralleldisplay/ParallelBus.c msgid "" @@ -2076,309 +2097,305 @@ msgstr "" #: shared-bindings/displayio/TileGrid.c msgid "Tile height must exactly divide bitmap height" -msgstr "" +msgstr "Высота плитки должна точно делить высоту растрового изображения" #: shared-bindings/displayio/TileGrid.c shared-module/displayio/TileGrid.c msgid "Tile index out of bounds" -msgstr "" +msgstr "Выход индекса плитки за пределы" #: shared-bindings/displayio/TileGrid.c msgid "Tile width must exactly divide bitmap width" -msgstr "" +msgstr "Ширина плитки должна точно делить ширину растрового изображения" #: shared-bindings/alarm/time/TimeAlarm.c msgid "Time is in the past." -msgstr "" +msgstr "Время в прошлом." #: ports/espressif/common-hal/_bleio/Adapter.c #: ports/nrf/common-hal/_bleio/Adapter.c #, c-format msgid "Timeout is too long: Maximum timeout length is %d seconds" -msgstr "" +msgstr "Таймаут слишком длинный: максимальная длина таймаута %d секунд" #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c msgid "Too many channels in sample" -msgstr "" +msgstr "Слишком много каналов в выборке" #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c msgid "Too many channels in sample." -msgstr "" +msgstr "Слишком много каналов в выборке." #: shared-module/displayio/__init__.c msgid "Too many display busses; forgot displayio.release_displays() ?" -msgstr "" +msgstr "Слишком много шин дисплея; забыл displayio.release_displays()?" #: shared-module/displayio/__init__.c msgid "Too many displays" -msgstr "" +msgstr "Слишком много дисплеев" #: ports/espressif/common-hal/_bleio/PacketBuffer.c #: ports/nrf/common-hal/_bleio/PacketBuffer.c msgid "Total data to write is larger than %q" -msgstr "" +msgstr "Общее количество данных для записи превышает %q" #: ports/atmel-samd/common-hal/alarm/touch/TouchAlarm.c #: ports/raspberrypi/common-hal/alarm/touch/TouchAlarm.c #: ports/stm/common-hal/alarm/touch/TouchAlarm.c msgid "Touch alarms not available" -msgstr "" +msgstr "Сенсорные сигналы недоступны" #: py/obj.c msgid "Traceback (most recent call last):\n" -msgstr "" +msgstr "Трассировка (последний вызов):\n" #: shared-bindings/time/__init__.c msgid "Tuple or struct_time argument required" -msgstr "" +msgstr "Требуется кортеж или struct_time аргумент" #: ports/stm/common-hal/busio/UART.c msgid "UART de-init" -msgstr "" +msgstr "Деинициализация UART" #: ports/cxd56/common-hal/busio/UART.c ports/espressif/common-hal/busio/UART.c #: ports/stm/common-hal/busio/UART.c msgid "UART init" -msgstr "" +msgstr "Инициализация UART" #: ports/raspberrypi/common-hal/busio/UART.c msgid "UART peripheral in use" -msgstr "" +msgstr "Используемое периферийное устройство UART" #: ports/stm/common-hal/busio/UART.c msgid "UART re-init" -msgstr "" +msgstr "Повторная инициализация UART" #: ports/stm/common-hal/busio/UART.c msgid "UART write" -msgstr "" +msgstr "Запись UART" #: main.c msgid "UID:" -msgstr "" +msgstr "UID:" #: shared-module/usb_hid/Device.c msgid "USB busy" -msgstr "" +msgstr "USB занят" #: supervisor/shared/safe_mode.c msgid "USB devices need more endpoints than are available." -msgstr "" +msgstr "USB-устройствам требуется больше конечных точек, чем доступно." #: supervisor/shared/safe_mode.c msgid "USB devices specify too many interface names." -msgstr "" +msgstr "USB-устройства указывают слишком много имен интерфейсов." #: shared-module/usb_hid/Device.c msgid "USB error" -msgstr "" +msgstr "Ошибка USB" #: shared-bindings/_bleio/UUID.c msgid "UUID integer value must be 0-0xffff" -msgstr "" +msgstr "Целое значение UUID должно быть равно 0-0xffff" #: shared-bindings/_bleio/UUID.c msgid "UUID string not 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" -msgstr "" +msgstr "UUID строка не 'xxxxxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxxxxxxxxxxx \"" #: shared-bindings/_bleio/UUID.c msgid "UUID value is not str, int or byte buffer" -msgstr "" +msgstr "Значение UUID не является строковым, целым или байтовым буфером" + +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "Невозможно получить доступ к невыровненному регистру ввода-вывода" #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/audiopwmio/PWMAudioOut.c msgid "Unable to allocate buffers for signed conversion" -msgstr "" +msgstr "Не удается выделить буферы для подписанного преобразования" #: supervisor/shared/safe_mode.c msgid "Unable to allocate the heap." -msgstr "" - -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" +msgstr "Невозможно выделить кучу." #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" -msgstr "" +msgstr "Не удается создать блокировку" #: shared-module/displayio/I2CDisplay.c shared-module/is31fl3741/IS31FL3741.c #, c-format msgid "Unable to find I2C Display at %x" -msgstr "" +msgstr "Не удается найти дисплей I2C в %x" #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audiobusio/PDMIn.c msgid "Unable to find free GCLK" -msgstr "" +msgstr "Не удается найти бесплатный GCLK" #: py/parse.c msgid "Unable to init parser" -msgstr "" - -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" +msgstr "Не удается инициировать синтаксический анализатор" #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" -msgstr "" - -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" +msgstr "Не удается прочитать данные цветовой палитры" #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" -msgstr "" - -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" +msgstr "Не удается запустить запрос mDNS" #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." -msgstr "" +msgstr "Невозможно выполнить запись в nvm." + +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "Невозможно записать в постоянную память" #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." -msgstr "" +msgstr "Невозможно записать в Sleep_memory." #: ports/nrf/common-hal/_bleio/UUID.c msgid "Unexpected nrfx uuid type" -msgstr "" +msgstr "Неожиданный тип nrfx uuid" #: ports/espressif/common-hal/ssl/SSLSocket.c #, c-format msgid "Unhandled ESP TLS error %d %d %x %d" -msgstr "" +msgstr "Необработанная ошибка ESP TLS %d %d %x %d" #: ports/espressif/common-hal/_bleio/__init__.c #, c-format msgid "Unknown BLE error at %s:%d: %d" -msgstr "" +msgstr "Неизвестная ошибка BLE в %s:%d: %d" #: ports/espressif/common-hal/_bleio/__init__.c #, c-format msgid "Unknown BLE error: %d" -msgstr "" +msgstr "Неизвестная ошибка BLE: %d" #: ports/raspberrypi/common-hal/wifi/__init__.c #, c-format msgid "Unknown error code %d" -msgstr "" +msgstr "Неизвестный код ошибки %d" #: shared-bindings/wifi/Radio.c #, c-format msgid "Unknown failure %d" -msgstr "" +msgstr "Неизвестный сбой %d" #: ports/nrf/common-hal/_bleio/__init__.c #, c-format msgid "Unknown gatt error: 0x%04x" -msgstr "" +msgstr "Неизвестная ошибка gatt: 0x%04x" #: ports/atmel-samd/common-hal/alarm/pin/PinAlarm.c #: supervisor/shared/safe_mode.c msgid "Unknown reason." -msgstr "" +msgstr "Причина неизвестна." #: ports/nrf/common-hal/_bleio/__init__.c #, c-format msgid "Unknown security error: 0x%04x" -msgstr "" +msgstr "Неизвестная ошибка безопасности: 0x%04x" #: ports/espressif/common-hal/_bleio/__init__.c #, c-format msgid "Unknown system firmware error at %s:%d: %d" -msgstr "" +msgstr "Неизвестная системная ошибка прошивки на %s:%d: %d" #: ports/nrf/common-hal/_bleio/__init__.c #, c-format msgid "Unknown system firmware error: %04x" -msgstr "" +msgstr "Неизвестная системная ошибка прошивки: %04x" #: ports/espressif/common-hal/_bleio/__init__.c #, c-format msgid "Unknown system firmware error: %d" -msgstr "" +msgstr "Неизвестная ошибка прошивки системы: %d" #: shared-bindings/adafruit_pixelbuf/PixelBuf.c #: shared-module/_pixelmap/PixelMap.c #, c-format msgid "Unmatched number of items on RHS (expected %d, got %d)." msgstr "" +"Непревзойденное количество элементов на RHS (ожидалось %d, получено %d)." #: ports/nrf/common-hal/_bleio/__init__.c msgid "" "Unspecified issue. Can be that the pairing prompt on the other device was " "declined or ignored." msgstr "" +"Неуказанная проблема. Возможно, запрос на сопряжение на другом устройстве " +"был отклонен или проигнорирован." #: shared-bindings/bitmaptools/__init__.c msgid "Unsupported colorspace" -msgstr "" +msgstr "Неподдерживаемое цветовое пространство" #: shared-module/displayio/display_core.c msgid "Unsupported display bus type" -msgstr "" +msgstr "Неподдерживаемый тип шины дисплея" #: shared-module/audiocore/WaveFile.c msgid "Unsupported format" -msgstr "" +msgstr "Неподдерживаемый формат" #: shared-bindings/hashlib/__init__.c msgid "Unsupported hash algorithm" -msgstr "" +msgstr "Неподдерживаемый алгоритм хеширования" #: ports/espressif/common-hal/dualbank/__init__.c msgid "Update Failed" -msgstr "" +msgstr "Ошибка обновления" #: ports/espressif/common-hal/_bleio/Characteristic.c #: ports/espressif/common-hal/_bleio/Descriptor.c #: ports/nrf/common-hal/_bleio/Characteristic.c #: ports/nrf/common-hal/_bleio/Descriptor.c msgid "Value length != required fixed length" -msgstr "" +msgstr "Длина значения! = требуемая фиксированная длина" #: ports/espressif/common-hal/_bleio/Characteristic.c #: ports/espressif/common-hal/_bleio/Descriptor.c #: ports/nrf/common-hal/_bleio/Characteristic.c #: ports/nrf/common-hal/_bleio/Descriptor.c msgid "Value length > max_length" -msgstr "" +msgstr "Длина значения > максимальная_длина" #: ports/espressif/common-hal/espidf/__init__.c msgid "Version was invalid" -msgstr "" +msgstr "Версия была недействительной" #: ports/stm/common-hal/microcontroller/Processor.c msgid "Voltage read timed out" -msgstr "" +msgstr "Истекло время ожидания считывания напряжения" #: main.c msgid "WARNING: Your code filename has two extensions\n" -msgstr "" +msgstr "ВНИМАНИЕ: Имя файла кода имеет два расширения\n" #: ports/atmel-samd/common-hal/watchdog/WatchDogTimer.c #: 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 "" +"Сторожевой таймер не может быть деинициализирован, если установлен режим " +"RESET" #: shared-bindings/watchdog/WatchDogTimer.c msgid "WatchDogTimer is not currently running" -msgstr "" +msgstr "Таймер Watch Dog в настоящее время не работает" #: shared-bindings/watchdog/WatchDogTimer.c msgid "WatchDogTimer.mode cannot be changed once set to WatchDogMode.RESET" msgstr "" +"WatchDogTimer.mode не может быть изменен после установки значения " +"WatchDogMode.RESET" #: py/builtinhelp.c #, c-format @@ -2389,551 +2406,568 @@ msgid "" "\n" "To list built-in modules type `help(\"modules\")`.\n" msgstr "" +"Добро пожаловать в Adafruit CircuitPython %s! \n" +"\n" +"Посетите circuitpython.org для получения дополнительной информации. \n" +"\n" +"Чтобы получить список встроенных модулей, введите 'help(\"modules\")'.\n" #: supervisor/shared/web_workflow/web_workflow.c msgid "Wi-Fi: " -msgstr "" +msgstr "Wi-Fi: " #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "Wifi is not enabled" -msgstr "" +msgstr "Wifi не включен" #: main.c msgid "Woken up by alarm.\n" -msgstr "" +msgstr "Проснулся по тревоге.\n" #: ports/espressif/common-hal/_bleio/PacketBuffer.c #: ports/nrf/common-hal/_bleio/PacketBuffer.c msgid "Writes not supported on Characteristic" -msgstr "" +msgstr "Запись не поддерживается в Характеристика" #: ports/atmel-samd/boards/circuitplayground_express/mpconfigboard.h #: ports/atmel-samd/boards/circuitplayground_express_crickit/mpconfigboard.h #: ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.h #: ports/atmel-samd/boards/meowmeow/mpconfigboard.h msgid "You pressed both buttons at start up." -msgstr "" +msgstr "Вы нажали обе кнопки при запуске." #: ports/espressif/boards/m5stack_core_basic/mpconfigboard.h #: ports/espressif/boards/m5stack_core_fire/mpconfigboard.h #: ports/espressif/boards/m5stack_stick_c/mpconfigboard.h #: ports/espressif/boards/m5stack_stick_c_plus/mpconfigboard.h msgid "You pressed button A at start up." -msgstr "" +msgstr "Вы нажали кнопку A при запуске." #: ports/espressif/boards/m5stack_m5paper/mpconfigboard.h msgid "You pressed button DOWN at start up." -msgstr "" +msgstr "Вы нажали кнопку ВНИЗ при запуске." #: supervisor/shared/safe_mode.c msgid "You pressed the BOOT button at start up" -msgstr "" +msgstr "Вы нажали кнопку BOOT при запуске" #: ports/espressif/boards/adafruit_huzzah32_breakout/mpconfigboard.h msgid "You pressed the GPIO0 button at start up." -msgstr "" +msgstr "Вы нажали кнопку GPIO0 при запуске." #: ports/espressif/boards/espressif_esp32_lyrat/mpconfigboard.h msgid "You pressed the Rec button at start up." -msgstr "" +msgstr "Вы нажали кнопку «Запись» при запуске." #: ports/espressif/boards/adafruit_feather_esp32_v2/mpconfigboard.h msgid "You pressed the SW38 button at start up." -msgstr "" +msgstr "Вы нажали кнопку SW38 при запуске." #: ports/espressif/boards/hardkernel_odroid_go/mpconfigboard.h msgid "You pressed the VOLUME button at start up." -msgstr "" +msgstr "Вы нажали кнопку ГРОМКОСТЬ при запуске." #: ports/espressif/boards/m5stack_atom_echo/mpconfigboard.h #: ports/espressif/boards/m5stack_atom_lite/mpconfigboard.h #: ports/espressif/boards/m5stack_atom_matrix/mpconfigboard.h #: ports/espressif/boards/m5stack_atom_u/mpconfigboard.h msgid "You pressed the central button at start up." -msgstr "" +msgstr "Вы нажали центральную кнопку при запуске." #: ports/nrf/boards/aramcon2_badge/mpconfigboard.h msgid "You pressed the left button at start up." -msgstr "" +msgstr "Вы нажали левую кнопку при запуске." #: supervisor/shared/safe_mode.c msgid "You pressed the reset button during boot." -msgstr "" +msgstr "Вы нажали кнопку сброса во время загрузки." #: supervisor/shared/micropython.c msgid "[truncated due to length]" -msgstr "" +msgstr "[отрезается по длине]" #: py/objtype.c msgid "__init__() should return None" -msgstr "" +msgstr "__init__() должен возвращать значение None" #: py/objtype.c msgid "__init__() should return None, not '%q'" -msgstr "" +msgstr "__init__() должен возвращать None, а не '%q'" #: py/objobject.c msgid "__new__ arg must be a user-type" -msgstr "" +msgstr "__new__ arg должен быть пользовательского типа" #: extmod/modubinascii.c extmod/moduhashlib.c py/objarray.c msgid "a bytes-like object is required" -msgstr "" +msgstr "Требуется байтоподобный объект" #: shared-bindings/i2ctarget/I2CTarget.c msgid "addresses is empty" -msgstr "" +msgstr "адреса пусты" #: py/compile.c msgid "annotation must be an identifier" -msgstr "" +msgstr "Аннотация должна быть идентификатором" #: extmod/ulab/code/numpy/create.c msgid "arange: cannot compute length" -msgstr "" +msgstr "arange: не удается вычислить длину" #: py/modbuiltins.c msgid "arg is an empty sequence" -msgstr "" +msgstr "arg - пустая последовательность" #: py/objobject.c msgid "arg must be user-type" -msgstr "" +msgstr "arg должен быть пользовательского типа" #: extmod/ulab/code/numpy/numerical.c msgid "argsort argument must be an ndarray" -msgstr "" +msgstr "аргумент сортировки должен быть аргументом массива ndarray" #: extmod/ulab/code/numpy/numerical.c msgid "argsort is not implemented for flattened arrays" -msgstr "" +msgstr "сортировка arg не реализована для сглаженных массивов" #: py/runtime.c shared-bindings/supervisor/__init__.c msgid "argument has wrong type" -msgstr "" +msgstr "аргумент имеет неправильный тип" #: py/compile.c msgid "argument name reused" -msgstr "" +msgstr "Повторное использование имени аргумента" #: py/argcheck.c shared-bindings/_stage/__init__.c #: shared-bindings/digitalio/DigitalInOut.c msgid "argument num/types mismatch" -msgstr "" +msgstr "Аргумент Несоответствие числа/типов" #: py/runtime.c msgid "argument should be a '%q' not a '%q'" -msgstr "" +msgstr "аргумент должен быть '%q', а не '%q'" #: extmod/ulab/code/numpy/numerical.c extmod/ulab/code/numpy/transform.c msgid "arguments must be ndarrays" -msgstr "" +msgstr "Аргументы должны быть массивами ndarrays" #: extmod/ulab/code/ndarray.c msgid "array and index length must be equal" -msgstr "" +msgstr "Длина массива и индекса должна быть равна" #: extmod/ulab/code/numpy/io/io.c msgid "array has too many dimensions" -msgstr "" +msgstr "Массив имеет слишком много измерений" #: extmod/ulab/code/ndarray.c msgid "array is too big" -msgstr "" +msgstr "массив слишком велик" #: py/objarray.c shared-bindings/alarm/SleepMemory.c #: shared-bindings/memorymap/AddressRange.c shared-bindings/nvm/ByteArray.c msgid "array/bytes required on right side" -msgstr "" +msgstr "массив/байты, необходимые справа" #: py/asmxtensa.c msgid "asm overflow" -msgstr "" +msgstr "Переполнение ASM" #: extmod/ulab/code/numpy/numerical.c msgid "attempt to get (arg)min/(arg)max of empty sequence" msgstr "" +"Попытка получить (аргумент)минимальный/(аргумент)максимальный пустой " +"последовательности" #: extmod/ulab/code/numpy/numerical.c msgid "attempt to get argmin/argmax of an empty sequence" msgstr "" +"Попытка получить аргумент минимальный/аргумент максимальный пустой " +"последовательности" #: py/objstr.c msgid "attributes not supported yet" -msgstr "" +msgstr "Атрибуты пока не поддерживаются" #: extmod/ulab/code/ulab_tools.c msgid "axis is out of bounds" -msgstr "" +msgstr "Ось выходит за пределы" #: extmod/ulab/code/numpy/numerical.c extmod/ulab/code/ulab_tools.c msgid "axis must be None, or an integer" -msgstr "" +msgstr "ось должна быть None или целым числом" #: extmod/ulab/code/numpy/numerical.c msgid "axis too long" -msgstr "" +msgstr "Слишком длинная ось" #: shared-bindings/bitmaptools/__init__.c msgid "background value out of range of target" -msgstr "" +msgstr "Фоновое значение вне диапазона цели" #: py/builtinevex.c msgid "bad compile mode" -msgstr "" +msgstr "Неверный режим компиляции" #: py/objstr.c msgid "bad conversion specifier" -msgstr "" +msgstr "Неверный спецификатор преобразования" #: py/objstr.c msgid "bad format string" -msgstr "" +msgstr "Строка неверного формата" #: py/binary.c py/objarray.c msgid "bad typecode" -msgstr "" +msgstr "Неверный шрифт" #: py/emitnative.c msgid "binary op %q not implemented" -msgstr "" +msgstr "двоичная операция %q не реализована" #: shared-bindings/bitmaptools/__init__.c msgid "bitmap sizes must match" -msgstr "" +msgstr "Размеры растровых изображений должны совпадать" #: extmod/modurandom.c msgid "bits must be 32 or less" -msgstr "" +msgstr "биты должны быть 32 или менее" #: shared-bindings/audiomixer/Mixer.c msgid "bits_per_sample must be 8 or 16" -msgstr "" +msgstr "bits_per_sample должно быть 8 или 16" #: py/emitinlinethumb.c msgid "branch not in range" -msgstr "" +msgstr "Ветвь не в пределах досягаемости" #: extmod/ulab/code/numpy/create.c extmod/ulab/code/utils/utils.c msgid "buffer is smaller than requested size" -msgstr "" +msgstr "Размер буфера меньше запрошенного" #: extmod/ulab/code/numpy/create.c extmod/ulab/code/utils/utils.c msgid "buffer size must be a multiple of element size" -msgstr "" +msgstr "Размер буфера должен быть кратен размеру элемента" #: shared-module/struct/__init__.c msgid "buffer size must match format" -msgstr "" +msgstr "Размер буфера должен соответствовать формату" #: shared-bindings/bitbangio/SPI.c shared-bindings/busio/SPI.c msgid "buffer slices must be of equal length" -msgstr "" +msgstr "Буферные фрагменты должны быть одинаковой длины" #: py/modstruct.c shared-module/struct/__init__.c msgid "buffer too small" -msgstr "" +msgstr "буфер слишком мал" #: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "buffer too small for requested bytes" -msgstr "" +msgstr "Слишком маленький буфер для запрашиваемых байтов" #: py/emitbc.c msgid "bytecode overflow" -msgstr "" +msgstr "Переполнение байт-кода" #: py/objarray.c msgid "bytes length not a multiple of item size" -msgstr "" +msgstr "длина байтов, не кратная размеру элемента" #: py/objstr.c msgid "bytes value out of range" -msgstr "" +msgstr "Значение байтов вне диапазона" #: ports/atmel-samd/bindings/samd/Clock.c msgid "calibration is out of range" -msgstr "" +msgstr "Калибровка выходит за пределы допустимого диапазона" #: ports/atmel-samd/bindings/samd/Clock.c msgid "calibration is read only" -msgstr "" +msgstr "Калибровка доступна только для чтения" #: shared-module/vectorio/Circle.c shared-module/vectorio/Polygon.c #: shared-module/vectorio/Rectangle.c msgid "can only have one parent" -msgstr "" +msgstr "может иметь только одного родителя" #: py/emitinlinethumb.c msgid "can only have up to 4 parameters to Thumb assembly" -msgstr "" +msgstr "может иметь только до 4 параметров для сборки большого пальца" #: py/emitinlinextensa.c msgid "can only have up to 4 parameters to Xtensa assembly" -msgstr "" +msgstr "может иметь только до 4 параметров для сборки Xtensa" #: extmod/ulab/code/ndarray.c msgid "can only specify one unknown dimension" -msgstr "" +msgstr "Можно указать только одно неизвестное измерение" #: py/objtype.c msgid "can't add special method to already-subclassed class" msgstr "" +"Не удается добавить специальный метод к уже имеющемуся подклассу классу" #: py/compile.c msgid "can't assign to expression" -msgstr "" +msgstr "Не удается назначить выражение" #: extmod/moduasyncio.c msgid "can't cancel self" -msgstr "" +msgstr "Не могу отменить себя" #: py/objint.c py/runtime.c shared-module/adafruit_pixelbuf/PixelBuf.c msgid "can't convert %q to %q" -msgstr "" +msgstr "Не удается преобразовать %q в %q" #: py/obj.c #, c-format msgid "can't convert %s to complex" -msgstr "" +msgstr "не может преобразовать %s в сложный" #: py/obj.c #, c-format msgid "can't convert %s to float" -msgstr "" +msgstr "не могу преобразовать %s в число с плавающей запятой" #: py/objstr.c msgid "can't convert '%q' object to %q implicitly" -msgstr "" +msgstr "не может конвертировать «%q» в% q косвенно" #: extmod/ulab/code/numpy/vector.c msgid "can't convert complex to float" -msgstr "" +msgstr "Не может преобразовать сложный в плавающий" #: py/obj.c msgid "can't convert to complex" -msgstr "" +msgstr "не может быть преобразован в сложный" #: py/obj.c msgid "can't convert to float" -msgstr "" +msgstr "Не удается преобразовать в float" #: py/runtime.c msgid "can't convert to int" -msgstr "" +msgstr "Не удается преобразовать в int" #: py/objstr.c msgid "can't convert to str implicitly" -msgstr "" +msgstr "не может превратиться в полосу неявно" #: py/compile.c msgid "can't declare nonlocal in outer code" -msgstr "" +msgstr "не может объявить нелокальный во внешнем коде" #: py/compile.c msgid "can't delete expression" -msgstr "" +msgstr "Не удается удалить выражение" #: py/emitnative.c msgid "can't do binary op between '%q' and '%q'" -msgstr "" +msgstr "Не могу выполнить двоичную операцию между '%q' и '%q'" #: py/objcomplex.c msgid "can't do truncated division of a complex number" -msgstr "" +msgstr "Не могу сделать усеченное деление комплексного числа" #: py/emitnative.c msgid "can't implicitly convert '%q' to 'bool'" -msgstr "" +msgstr "не может неявно преобразовать '%q' в 'bool'" #: py/emitnative.c msgid "can't load from '%q'" -msgstr "" +msgstr "Не удается загрузить из '%q'" #: py/emitnative.c msgid "can't load with '%q' index" -msgstr "" +msgstr "Не удается загрузить с индексом '%q'" #: py/builtinimport.c msgid "can't perform relative import" -msgstr "" +msgstr "Не удается выполнить относительный импорт" #: py/objgenerator.c msgid "can't send non-None value to a just-started generator" msgstr "" +"не может отправить значение, отличное от None, только что запущенному " +"генератору" #: shared-module/sdcardio/SDCard.c msgid "can't set 512 block size" -msgstr "" +msgstr "Не удается установить размер блока 512" #: py/objexcept.c py/objnamedtuple.c msgid "can't set attribute" -msgstr "" +msgstr "Не удается установить атрибут" #: py/runtime.c shared-bindings/supervisor/Runtime.c msgid "can't set attribute '%q'" -msgstr "" +msgstr "Не удается установить атрибут '%q'" #: py/emitnative.c msgid "can't store '%q'" -msgstr "" +msgstr "Не удается сохранить '%q'" #: py/emitnative.c msgid "can't store to '%q'" -msgstr "" +msgstr "невозможно сохранить в «%q»" #: py/emitnative.c msgid "can't store with '%q' index" -msgstr "" +msgstr "не может хранить с индексом%q" #: py/objstr.c msgid "" "can't switch from automatic field numbering to manual field specification" msgstr "" +"Не удается переключиться с автоматической нумерации полей на ручную " +"спецификацию полей" #: py/objstr.c msgid "" "can't switch from manual field specification to automatic field numbering" -msgstr "" +msgstr "не может переключаться с ручного поля на автоматическую нумерацию поля" #: extmod/moduasyncio.c msgid "can't wait" -msgstr "" +msgstr "не может ждать" #: extmod/ulab/code/ndarray.c msgid "cannot assign new shape" -msgstr "" +msgstr "Не удается назначить новую фигуру" #: extmod/ulab/code/ndarray_operators.c msgid "cannot cast output with casting rule" -msgstr "" +msgstr "Не удается привести выходные данные с помощью правила приведения" #: extmod/ulab/code/ndarray.c msgid "cannot convert complex to dtype" -msgstr "" +msgstr "не может превратить комплекс в dtype" #: extmod/ulab/code/ndarray.c msgid "cannot convert complex type" -msgstr "" +msgstr "Не удается преобразовать сложный тип" #: py/objtype.c msgid "cannot create '%q' instances" -msgstr "" +msgstr "Не удается создать экземпляры '%q'" #: py/objtype.c msgid "cannot create instance" -msgstr "" +msgstr "Не удается создать экземпляр" #: extmod/ulab/code/ndarray.c msgid "cannot delete array elements" -msgstr "" +msgstr "Не удается удалить элементы массива" #: py/runtime.c msgid "cannot import name %q" -msgstr "" +msgstr "Не удается импортировать имя %Q" #: extmod/ulab/code/ndarray.c msgid "cannot reshape array" -msgstr "" +msgstr "Не удается изменить форму массива" #: extmod/moductypes.c msgid "cannot unambiguously get sizeof scalar" -msgstr "" +msgstr "не может однозначно получить размер скаляра" #: py/emitnative.c msgid "casting" -msgstr "" +msgstr "кастинг" #: ports/stm/common-hal/pwmio/PWMOut.c msgid "channel re-init" -msgstr "" +msgstr "Реинициализация канала" #: shared-bindings/_stage/Text.c msgid "chars buffer too small" -msgstr "" +msgstr "Слишком маленький буфер символов" #: py/modbuiltins.c msgid "chr() arg not in range(0x110000)" -msgstr "" +msgstr "chr() аргумент вне диапазона (0x110000)" #: py/modbuiltins.c msgid "chr() arg not in range(256)" -msgstr "" +msgstr "chr() аргумент вне диапазона (256)" #: shared-bindings/bitmaptools/__init__.c msgid "clip point must be (x,y) tuple" -msgstr "" +msgstr "Точка клипа должна быть кортежом (x,y)" #: shared-bindings/msgpack/ExtType.c msgid "code outside range 0~127" -msgstr "" +msgstr "код вне диапазона 0~127" #: shared-bindings/displayio/Palette.c msgid "color buffer must be 3 bytes (RGB) or 4 bytes (RGB + pad byte)" msgstr "" +"Цветовой буфер должен иметь размер 3 байта (RGB) или 4 байта (RGB + байт " +"заполнения)" #: shared-bindings/displayio/Palette.c msgid "color buffer must be a buffer, tuple, list, or int" -msgstr "" +msgstr "Цветовой буфер должен быть буфером, кортежом, списком или целым числом" #: shared-bindings/displayio/Palette.c msgid "color buffer must be a bytearray or array of type 'b' or 'B'" msgstr "" +"цветовой буфер должен быть байтом массива или массивом типа \"b\" или \"B\"" #: shared-bindings/displayio/Palette.c msgid "color must be between 0x000000 and 0xffffff" -msgstr "" +msgstr "Цвет должен быть от 0x000000 до 0xffffff" #: py/emitnative.c msgid "comparison of int and uint" -msgstr "" +msgstr "сравнение int и uint" #: py/objfloat.c py/parsenum.c msgid "complex values not supported" -msgstr "" +msgstr "Комплексные значения не поддерживаются" #: extmod/moduzlib.c msgid "compression header" -msgstr "" +msgstr "Заголовок сжатия" #: py/emitnative.c msgid "conversion to object" -msgstr "" +msgstr "Преобразование в объект" #: extmod/ulab/code/numpy/filter.c msgid "convolve arguments must be linear arrays" -msgstr "" +msgstr "Аргументы свертки должны быть линейными массивами" #: extmod/ulab/code/numpy/filter.c msgid "convolve arguments must be ndarrays" -msgstr "" +msgstr "переплетение аргументов должно быть массивами ndarrays" #: extmod/ulab/code/numpy/filter.c msgid "convolve arguments must not be empty" -msgstr "" +msgstr "аргументы свертки не должны быть пустыми" #: extmod/ulab/code/numpy/io/io.c msgid "corrupted file" -msgstr "" +msgstr "Поврежденный файл" #: extmod/ulab/code/numpy/poly.c msgid "could not invert Vandermonde matrix" -msgstr "" +msgstr "не удалось инвертировать матрицу Вандермонда" #: shared-module/sdcardio/SDCard.c msgid "couldn't determine SD card version" -msgstr "" +msgstr "Не удалось определить версию SD карты" #: extmod/ulab/code/numpy/numerical.c msgid "cross is defined for 1D arrays of length 3" -msgstr "" +msgstr "крест определяется для 1D массивов длины 3" #: extmod/ulab/code/scipy/optimize/optimize.c msgid "data must be iterable" -msgstr "" +msgstr "Данные должны быть итерируемыми" #: extmod/ulab/code/scipy/optimize/optimize.c msgid "data must be of equal length" -msgstr "" +msgstr "Данные должны быть одинаковой длины" #: ports/atmel-samd/common-hal/imagecapture/ParallelImageCapture.c #, c-format @@ -2942,986 +2976,999 @@ msgstr "data-пин #%d уже используется" #: extmod/ulab/code/ndarray.c msgid "data type not understood" -msgstr "" +msgstr "Тип данных не понят" #: py/parsenum.c msgid "decimal numbers not supported" -msgstr "" +msgstr "Десятичные числа не поддерживаются" #: py/compile.c msgid "default 'except' must be last" -msgstr "" +msgstr "по умолчанию \"за исключением\" должно быть последним" #: shared-bindings/msgpack/__init__.c msgid "default is not a function" -msgstr "" +msgstr "По умолчанию не является функцией" #: shared-bindings/audiobusio/PDMIn.c msgid "" "destination buffer must be a bytearray or array of type 'B' for bit_depth = 8" msgstr "" +"буфер назначения должен быть байтоммассива или массивом типа \"B\" для " +"бит_глубины = 8" #: shared-bindings/audiobusio/PDMIn.c msgid "destination buffer must be an array of type 'H' for bit_depth = 16" msgstr "" +"буфер назначения должен быть массивом типа «H» для битовой_глубины = 16" #: py/objdict.c msgid "dict update sequence has wrong length" -msgstr "" +msgstr "последовательность обновления дикта имеет неправильную длину" #: extmod/ulab/code/numpy/numerical.c msgid "diff argument must be an ndarray" -msgstr "" +msgstr "аргумент DIFF должен быть массивом ndarray" #: extmod/ulab/code/numpy/numerical.c msgid "differentiation order out of range" -msgstr "" +msgstr "Порядок дифференциации вне диапазона" #: extmod/ulab/code/numpy/transform.c msgid "dimensions do not match" -msgstr "" +msgstr "Размеры не совпадают" #: py/emitnative.c msgid "div/mod not implemented for uint" -msgstr "" +msgstr "div/mod не реализован для uint" #: extmod/ulab/code/numpy/create.c msgid "divide by zero" -msgstr "" +msgstr "Делим на ноль" #: py/runtime.c msgid "division by zero" -msgstr "" +msgstr "Деление на ноль" #: extmod/ulab/code/numpy/vector.c msgid "dtype must be float, or complex" -msgstr "" +msgstr "Тип d должен быть плавающим или сложным" #: py/objdeque.c msgid "empty" -msgstr "" +msgstr "пусто" #: extmod/ulab/code/numpy/io/io.c msgid "empty file" -msgstr "" +msgstr "пустой файл" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" -msgstr "" +msgstr "пустая куча" #: py/objstr.c msgid "empty separator" -msgstr "" +msgstr "пустой сепаратор" #: shared-bindings/random/__init__.c msgid "empty sequence" -msgstr "" +msgstr "пустая последовательность" #: py/objstr.c msgid "end of format while looking for conversion specifier" -msgstr "" +msgstr "конец формата при поиске спецификатора преобразования" #: shared-bindings/alarm/time/TimeAlarm.c msgid "epoch_time not supported on this board" -msgstr "" +msgstr "epoch_time не поддерживается на этой плате" #: ports/nrf/common-hal/busio/UART.c #, c-format msgid "error = 0x%08lX" -msgstr "" +msgstr "ошибка = 0x%08lX" #: ports/espressif/common-hal/espcamera/Camera.c msgid "" "espcamera.Camera requires reserved PSRAM to be configured. See the " "documentation for instructions." msgstr "" +"espcamera.Для настройки камеры требуется зарезервированная PSRAM. Инструкции " +"см. в документации." #: py/runtime.c msgid "exceptions must derive from BaseException" -msgstr "" +msgstr "исключения должны быть производными от базового исключения" #: py/objstr.c msgid "expected ':' after format specifier" -msgstr "" +msgstr "Ожидаемый ':' после спецификатора формата" #: py/obj.c msgid "expected tuple/list" -msgstr "" +msgstr "Ожидаемый кортеж/список" #: py/modthread.c msgid "expecting a dict for keyword args" -msgstr "" +msgstr "ожидание определения аргументов ключевых слов" #: py/compile.c msgid "expecting an assembler instruction" -msgstr "" +msgstr "Ожидание инструкции ассемблера" #: py/compile.c msgid "expecting just a value for set" -msgstr "" +msgstr "ожидание только значения для набора" #: py/compile.c msgid "expecting key:value for dict" -msgstr "" +msgstr "ожидание ключа: значение для дикта" #: shared-bindings/msgpack/__init__.c msgid "ext_hook is not a function" -msgstr "" +msgstr "ext_hook не является функцией" #: py/argcheck.c msgid "extra keyword arguments given" -msgstr "" +msgstr "Приведены дополнительные аргументы ключевых слов" #: py/argcheck.c msgid "extra positional arguments given" -msgstr "" +msgstr "Приведены дополнительные позиционные аргументы" #: shared-bindings/audiocore/WaveFile.c shared-bindings/audiomp3/MP3Decoder.c #: shared-bindings/displayio/OnDiskBitmap.c shared-bindings/gifio/OnDiskGif.c #: shared-bindings/synthio/__init__.c shared-module/gifio/GifWriter.c msgid "file must be a file opened in byte mode" -msgstr "" +msgstr "Файл должен быть файлом, открытым в байтовом режиме" #: shared-bindings/traceback/__init__.c msgid "file write is not available" -msgstr "" +msgstr "Запись файлов недоступна" #: shared-bindings/storage/__init__.c msgid "filesystem must provide mount method" -msgstr "" +msgstr "Файловая система должна предусматривать метод монтирования" #: extmod/ulab/code/numpy/vector.c msgid "first argument must be a callable" -msgstr "" +msgstr "Первый аргумент должен быть вызываемым" #: extmod/ulab/code/scipy/optimize/optimize.c msgid "first argument must be a function" -msgstr "" +msgstr "первый аргумент должен быть функцией" #: extmod/ulab/code/numpy/create.c msgid "first argument must be a tuple of ndarrays" -msgstr "" +msgstr "Первый аргумент должен быть кортежом массива ndarrays" #: extmod/ulab/code/numpy/transform.c extmod/ulab/code/numpy/vector.c msgid "first argument must be an ndarray" -msgstr "" +msgstr "Первым аргументом должен быть массивом ndarray" #: py/objtype.c msgid "first argument to super() must be type" -msgstr "" +msgstr "первый аргумент супер() должен быть типом" #: extmod/ulab/code/scipy/linalg/linalg.c msgid "first two arguments must be ndarrays" -msgstr "" +msgstr "Первые два аргумента должны быть массивами ndarrays" #: extmod/ulab/code/ndarray.c msgid "flattening order must be either 'C', or 'F'" -msgstr "" +msgstr "порядок сглаживания должен быть либо 'C', либо 'F'" #: extmod/ulab/code/numpy/numerical.c msgid "flip argument must be an ndarray" -msgstr "" +msgstr "Флип -аргумент должен быть массивом ndarray" #: py/objint.c msgid "float too big" -msgstr "" +msgstr "Поплавок слишком большой" #: py/nativeglue.c msgid "float unsupported" -msgstr "" +msgstr "Плавающий без поддержки" #: shared-bindings/_stage/Text.c msgid "font must be 2048 bytes long" -msgstr "" +msgstr "Длина шрифта должна составлять 2048 байт" #: py/objstr.c msgid "format requires a dict" -msgstr "" +msgstr "Формат требует диктата" #: py/objdeque.c msgid "full" -msgstr "" +msgstr "полный" #: py/argcheck.c msgid "function doesn't take keyword arguments" -msgstr "" +msgstr "функция не принимает аргументы ключевых слов" #: py/argcheck.c #, c-format msgid "function expected at most %d arguments, got %d" -msgstr "" +msgstr "функция, ожидаемая в большинстве %d аргументов, получила %d" #: py/bc.c py/objnamedtuple.c msgid "function got multiple values for argument '%q'" -msgstr "" +msgstr "функция имеет несколько значений для аргументации%q \"" #: extmod/ulab/code/scipy/optimize/optimize.c msgid "function has the same sign at the ends of interval" -msgstr "" +msgstr "функция имеет один и тот же знак в конце интервала" #: extmod/ulab/code/ndarray.c msgid "function is defined for ndarrays only" -msgstr "" +msgstr "Функция определяется только для массивов ndarrays" #: extmod/ulab/code/numpy/carray/carray.c msgid "function is implemented for ndarrays only" -msgstr "" +msgstr "Функция реализована только для массивов ndarrays" #: py/argcheck.c #, c-format msgid "function missing %d required positional arguments" -msgstr "" +msgstr "Функция отсутствует %d обязательные позиционные аргументы" #: py/bc.c msgid "function missing keyword-only argument" -msgstr "" +msgstr "функция отсутствует аргумент только по ключевому слову" #: py/bc.c msgid "function missing required keyword argument '%q'" -msgstr "" +msgstr "В функции отсутствует обязательный аргумент ключевого слова '%q'" #: py/bc.c #, c-format msgid "function missing required positional argument #%d" -msgstr "" +msgstr "В функции отсутствует обязательный позиционный аргумент #%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 "" +msgstr "функция принимает %d позиционные аргументы, но %d были заданы" #: shared-bindings/time/__init__.c msgid "function takes exactly 9 arguments" -msgstr "" +msgstr "функция принимает ровно 9 аргументов" #: py/objgenerator.c msgid "generator already executing" -msgstr "" +msgstr "генератор уже работает" #: py/objgenerator.c msgid "generator ignored GeneratorExit" -msgstr "" +msgstr "генератор проигнорировал Выход" #: py/objgenerator.c py/runtime.c msgid "generator raised StopIteration" -msgstr "" +msgstr "генератор поднят Остановить итерацию" #: shared-bindings/_stage/Layer.c msgid "graphic must be 2048 bytes long" -msgstr "" +msgstr "Длина рисунка должна составлять 2048 байт" #: extmod/moduhashlib.c msgid "hash is final" -msgstr "" +msgstr "хэш является окончательным" #: extmod/moduheapq.c msgid "heap must be a list" -msgstr "" +msgstr "куча должна быть списком" #: py/compile.c msgid "identifier redefined as global" -msgstr "" +msgstr "идентификатор переопределен как глобальный" #: py/compile.c msgid "identifier redefined as nonlocal" -msgstr "" +msgstr "идентификатор переопределен как нелокальный" #: py/compile.c msgid "import * not at module level" -msgstr "" +msgstr "Импорт * не на уровне модуля" #: py/persistentcode.c msgid "incompatible .mpy arch" -msgstr "" +msgstr "несовместимые .mpy арка" #: py/persistentcode.c msgid "incompatible .mpy file" -msgstr "" +msgstr "несовместимый файл .mpy" #: py/objstr.c msgid "incomplete format" -msgstr "" +msgstr "Неполный формат" #: py/objstr.c msgid "incomplete format key" -msgstr "" +msgstr "Неполный ключ форматирования" #: extmod/modubinascii.c msgid "incorrect padding" -msgstr "" +msgstr "Неправильная набивка" #: extmod/ulab/code/ndarray.c extmod/ulab/code/numpy/transform.c msgid "index is out of bounds" -msgstr "" +msgstr "индекс выходит из границ" #: shared-bindings/_pixelmap/PixelMap.c msgid "index must be tuple or int" -msgstr "" +msgstr "Индекс должен быть кортежом или целым кортежом" #: extmod/ulab/code/numpy/numerical.c extmod/ulab/code/ulab_tools.c #: ports/espressif/common-hal/pulseio/PulseIn.c #: shared-bindings/bitmaptools/__init__.c msgid "index out of range" -msgstr "" +msgstr "индекс вне диапазона" #: py/obj.c msgid "indices must be integers" -msgstr "" +msgstr "индексы должны быть целыми числами" #: extmod/ulab/code/ndarray.c msgid "indices must be integers, slices, or Boolean lists" -msgstr "" +msgstr "индексы должны быть целыми числами, срезами или логическими списками" #: ports/espressif/common-hal/busio/I2C.c msgid "init I2C" -msgstr "" +msgstr "инициализация I2C" #: extmod/ulab/code/scipy/optimize/optimize.c msgid "initial values must be iterable" -msgstr "" +msgstr "Начальные значения должны быть итерируемыми" #: shared-bindings/_bleio/Characteristic.c shared-bindings/_bleio/Descriptor.c msgid "initial_value length is wrong" -msgstr "" +msgstr "длина первоначального_значения ошибочна" #: py/compile.c msgid "inline assembler must be a function" -msgstr "" +msgstr "Встроенный ассемблер должен быть функцией" #: extmod/ulab/code/numpy/vector.c msgid "input and output dimensions differ" -msgstr "" +msgstr "Входные и выходные размеры различаются" #: extmod/ulab/code/numpy/vector.c msgid "input and output shapes differ" -msgstr "" +msgstr "Входные и выходные формы различаются" #: extmod/ulab/code/numpy/create.c msgid "input argument must be an integer, a tuple, or a list" -msgstr "" +msgstr "Входной аргумент должен быть целым числом, кортежом или списком" #: extmod/ulab/code/numpy/fft/fft_tools.c msgid "input array length must be power of 2" -msgstr "" +msgstr "Длина входного массива должна быть равна степени 2" #: extmod/ulab/code/numpy/create.c msgid "input arrays are not compatible" -msgstr "" +msgstr "Входные массивы несовместимы" #: extmod/ulab/code/numpy/poly.c msgid "input data must be an iterable" -msgstr "" +msgstr "Входные данные должны быть итерируемыми" #: extmod/ulab/code/numpy/vector.c msgid "input dtype must be float or complex" -msgstr "" +msgstr "Входной тип dtype должен быть плавающим или сложным" #: extmod/ulab/code/numpy/poly.c msgid "input is not iterable" -msgstr "" +msgstr "Ввод не является итерируемым" #: extmod/ulab/code/numpy/linalg/linalg.c msgid "input matrix is asymmetric" -msgstr "" +msgstr "Входная матрица асимметрична" #: extmod/ulab/code/numpy/linalg/linalg.c #: extmod/ulab/code/scipy/linalg/linalg.c msgid "input matrix is singular" -msgstr "" +msgstr "Входная матрица является сингулярной" #: extmod/ulab/code/numpy/create.c msgid "input must be 1- or 2-d" -msgstr "" +msgstr "Вход должен быть 1- или 2-D" #: extmod/ulab/code/numpy/carray/carray.c msgid "input must be a 1D ndarray" -msgstr "" +msgstr "Ввод должен быть 1D массивом ndarray" #: extmod/ulab/code/scipy/linalg/linalg.c extmod/ulab/code/user/user.c msgid "input must be a dense ndarray" -msgstr "" +msgstr "Ввод должен быть плотным массивом ndarray" #: extmod/ulab/code/user/user.c msgid "input must be an ndarray" -msgstr "" +msgstr "Ввод должен быть массивом ndarray" #: extmod/ulab/code/numpy/carray/carray.c msgid "input must be an ndarray, or a scalar" -msgstr "" +msgstr "Ввод должен быть массивом ndarray или скаляр" #: extmod/ulab/code/scipy/signal/signal.c msgid "input must be one-dimensional" -msgstr "" +msgstr "Входные данные должны быть одномерными" #: extmod/ulab/code/ulab_tools.c msgid "input must be square matrix" -msgstr "" +msgstr "Входные данные должны быть квадратной матрицей" #: extmod/ulab/code/numpy/numerical.c msgid "input must be tuple, list, range, or ndarray" -msgstr "" +msgstr "Ввод должен быть кортеж, список, диапазон или массивом ndarray" #: extmod/ulab/code/numpy/poly.c msgid "input vectors must be of equal length" -msgstr "" +msgstr "Входные векторы должны быть одинаковой длины" #: extmod/ulab/code/numpy/approx.c msgid "interp is defined for 1D iterables of equal length" -msgstr "" +msgstr "interp определен для 1D-итераций одинаковой длины" #: shared-bindings/_bleio/Adapter.c #, c-format msgid "interval must be in range %s-%s" -msgstr "" +msgstr "Интервал должен находиться в диапазоне %s-%s" #: py/compile.c msgid "invalid architecture" -msgstr "" +msgstr "Недопустимая архитектура" #: shared-bindings/bitmaptools/__init__.c #, c-format msgid "invalid bits_per_pixel %d, must be, 1, 2, 4, 8, 16, 24, or 32" -msgstr "" +msgstr "неверный бит_на_пиксель %d, должно быть 1, 2, 4, 8, 16, 24 или 32" #: ports/raspberrypi/common-hal/ssl/SSLSocket.c msgid "invalid cert" -msgstr "" +msgstr "Неверный сертификат" #: shared-bindings/bitmaptools/__init__.c #, c-format msgid "invalid element size %d for bits_per_pixel %d\n" -msgstr "" +msgstr "недопустимый размер элемента %d для битов на_пиксель %d\n" #: shared-bindings/bitmaptools/__init__.c #, c-format msgid "invalid element_size %d, must be, 1, 2, or 4" -msgstr "" +msgstr "аннулированный элемент_размер %d, должен быть, 1, 2 или 4" #: shared-bindings/traceback/__init__.c msgid "invalid exception" -msgstr "" +msgstr "Недопустимое исключение" #: py/objstr.c msgid "invalid format specifier" -msgstr "" +msgstr "Недопустимый спецификатор формата" #: shared-bindings/wifi/Radio.c msgid "invalid hostname" -msgstr "" +msgstr "Недопустимое имя хоста" #: ports/raspberrypi/common-hal/ssl/SSLSocket.c msgid "invalid key" -msgstr "" +msgstr "Неверный ключ" #: py/compile.c msgid "invalid micropython decorator" -msgstr "" +msgstr "неверный декоратор микропитона" #: ports/espressif/common-hal/espcamera/Camera.c msgid "invalid setting" -msgstr "" +msgstr "Недопустимый параметр" #: shared-bindings/random/__init__.c msgid "invalid step" -msgstr "" +msgstr "недействительный шаг" #: py/compile.c py/parse.c msgid "invalid syntax" -msgstr "" +msgstr "недействительный синтаксис" #: py/parsenum.c msgid "invalid syntax for integer" -msgstr "" +msgstr "недействительный синтаксис для целых чисел" #: py/parsenum.c #, c-format msgid "invalid syntax for integer with base %d" -msgstr "" +msgstr "недействительный синтаксис для целых чисел с основанием %d" #: py/parsenum.c msgid "invalid syntax for number" -msgstr "" +msgstr "недействительный синтаксис для номера" #: py/objtype.c msgid "issubclass() arg 1 must be a class" -msgstr "" +msgstr "issubclass() arg 1 должен быть классом" #: py/objtype.c msgid "issubclass() arg 2 must be a class or a tuple of classes" -msgstr "" +msgstr "issubclass() arg 2 должен быть классом или кортежом классов" #: extmod/ulab/code/numpy/linalg/linalg.c msgid "iterations did not converge" -msgstr "" +msgstr "итерации не сходятся" #: py/objstr.c msgid "join expects a list of str/bytes objects consistent with self object" msgstr "" +"присоединяйтесь к ожидающему список стр/байт объектов, совместимых с " +"самообъектом" #: py/argcheck.c msgid "keyword argument(s) not yet implemented - use normal args instead" msgstr "" +"Аргументы ключевого слова еще не реализованы - вместо этого используйте " +"обычные аргументы" #: py/emitinlinethumb.c py/emitinlinextensa.c msgid "label '%q' not defined" -msgstr "" +msgstr "Метка '%q' не определена" #: py/compile.c msgid "label redefined" -msgstr "" +msgstr "Метка переопределена" #: py/stream.c msgid "length argument not allowed for this type" -msgstr "" +msgstr "аргумент длины не допускается для этого типа" #: shared-bindings/audiomixer/MixerVoice.c msgid "level must be between 0 and 1" -msgstr "" +msgstr "уровень должен быть между 0 и 1" #: py/objarray.c msgid "lhs and rhs should be compatible" -msgstr "" +msgstr "lhs и rhs должны быть совместимыми" #: py/emitnative.c msgid "local '%q' has type '%q' but source is '%q'" -msgstr "" +msgstr "Локальный '%q' имеет тип '%q', но источник '%q'" #: py/emitnative.c msgid "local '%q' used before type known" -msgstr "" +msgstr "местный '%q' используется перед типом" #: py/vm.c msgid "local variable referenced before assignment" -msgstr "" +msgstr "локальная переменная, на которую ссылается перед присвоением" #: ports/espressif/common-hal/canio/CAN.c msgid "loopback + silent mode not supported by peripheral" msgstr "" +"Замыкание на себя + бесшумный режим, не поддерживаемый периферийными " +"устройствами" #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "mDNS already initialized" -msgstr "" +msgstr "mDNS уже инициализирован" #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "mDNS only works with built-in WiFi" -msgstr "" +msgstr "mDNS работает только со встроенным WiFi" #: py/parse.c msgid "malformed f-string" -msgstr "" +msgstr "Неправильно сформированная F-строка" #: shared-bindings/_stage/Layer.c msgid "map buffer too small" -msgstr "" +msgstr "Слишком маленький буфер карты" #: py/modmath.c shared-bindings/math/__init__.c msgid "math domain error" -msgstr "" +msgstr "Ошибка математической области" #: extmod/ulab/code/numpy/linalg/linalg.c msgid "matrix is not positive definite" -msgstr "" +msgstr "матрица не является положительно определенной" #: ports/espressif/common-hal/_bleio/Descriptor.c #: ports/nrf/common-hal/_bleio/Characteristic.c #: ports/nrf/common-hal/_bleio/Descriptor.c #, c-format msgid "max_length must be 0-%d when fixed_length is %s" -msgstr "" +msgstr "максимальная_длина должна быть 0-%d когда фиксированная длина %s" #: extmod/ulab/code/ndarray.c msgid "maximum number of dimensions is " -msgstr "" +msgstr "Максимальное количество измерений составляет " #: py/runtime.c msgid "maximum recursion depth exceeded" -msgstr "" +msgstr "Превышена максимальная глубина рекурсии" #: extmod/ulab/code/scipy/optimize/optimize.c msgid "maxiter must be > 0" -msgstr "" +msgstr "maxiter должен быть > 0" #: extmod/ulab/code/scipy/optimize/optimize.c msgid "maxiter should be > 0" -msgstr "" +msgstr "макситер должен быть > 0" #: extmod/ulab/code/numpy/numerical.c msgid "median argument must be an ndarray" -msgstr "" +msgstr "Средний аргумент должен быть массивом ndarray" #: py/runtime.c #, c-format msgid "memory allocation failed, allocating %u bytes" -msgstr "" +msgstr "Сбой выделения памяти, выделение %u байт" #: py/runtime.c msgid "memory allocation failed, heap is locked" -msgstr "" +msgstr "Не удалось выделить память, куча заблокирована" #: py/objarray.c msgid "memoryview: length is not a multiple of itemsize" -msgstr "" +msgstr "вид памяти: длина не является множеством элементов" #: extmod/ulab/code/numpy/linalg/linalg.c msgid "mode must be complete, or reduced" -msgstr "" +msgstr "Режим должен быть завершенным или уменьшенным" #: py/builtinimport.c msgid "module not found" -msgstr "" +msgstr "модуль не найден" #: ports/espressif/common-hal/wifi/Monitor.c msgid "monitor init failed" -msgstr "" +msgstr "Сбой инициализации монитора" #: extmod/ulab/code/numpy/poly.c msgid "more degrees of freedom than data points" -msgstr "" +msgstr "Больше степеней свободы чем точек данных" #: py/compile.c msgid "multiple *x in assignment" -msgstr "" +msgstr "Несколько *x в назначении" #: py/objtype.c msgid "multiple bases have instance lay-out conflict" -msgstr "" +msgstr "Несколько баз имеют конфликт расположения экземпляров" #: py/objtype.c msgid "multiple inheritance not supported" -msgstr "" +msgstr "Множественное наследование не поддерживается" #: py/emitnative.c msgid "must raise an object" -msgstr "" +msgstr "должен поднять объект" #: py/modbuiltins.c msgid "must use keyword argument for key function" -msgstr "" +msgstr "Необходимо использовать аргумент ключевого слова для ключевой функции" #: py/runtime.c msgid "name '%q' is not defined" -msgstr "" +msgstr "Имя '%q' не определено" #: py/runtime.c msgid "name not defined" -msgstr "" +msgstr "Имя не определено" #: py/asmthumb.c msgid "native method too big" -msgstr "" +msgstr "родной метод слишком большой" #: py/emitnative.c msgid "native yield" -msgstr "" +msgstr "родной урожай" #: extmod/ulab/code/ndarray.c msgid "ndarray length overflows" -msgstr "" +msgstr "Переполнение длины массива ndarray" #: py/runtime.c #, c-format msgid "need more than %d values to unpack" -msgstr "" +msgstr "Для распаковки требуется более значений %d" #: py/modmath.c msgid "negative factorial" -msgstr "" +msgstr "отрицательный факториал" #: py/objint_longlong.c py/objint_mpz.c py/runtime.c msgid "negative power with no float support" -msgstr "" +msgstr "Отрицательная мощность без поплавковой опоры" #: py/objint_mpz.c py/runtime.c msgid "negative shift count" -msgstr "" +msgstr "Количество отрицательных сдвигов" #: shared-bindings/_pixelmap/PixelMap.c msgid "nested index must be int" -msgstr "" +msgstr "вложенный индекс должен быть int" #: shared-module/sdcardio/SDCard.c msgid "no SD card" -msgstr "" +msgstr "нет SD карты" #: py/vm.c msgid "no active exception to reraise" -msgstr "" +msgstr "Нет активного исключения для повторного создания" #: py/compile.c msgid "no binding for nonlocal found" -msgstr "" +msgstr "Привязка для нелокальных не найдена" #: shared-module/msgpack/__init__.c msgid "no default packer" -msgstr "" +msgstr "Нет упаковщика по умолчанию" #: extmod/modurandom.c msgid "no default seed" -msgstr "" +msgstr "Нет начального числа по умолчанию" #: py/builtinimport.c msgid "no module named '%q'" -msgstr "" +msgstr "Нет модуля с именем '%Q'" #: shared-module/sdcardio/SDCard.c msgid "no response from SD card" -msgstr "" +msgstr "нет ответа с SD карты" #: ports/espressif/common-hal/espcamera/Camera.c py/objobject.c py/runtime.c msgid "no such attribute" -msgstr "" +msgstr "нет такого атрибута" #: ports/espressif/common-hal/_bleio/Connection.c #: ports/nrf/common-hal/_bleio/Connection.c msgid "non-UUID found in service_uuids_whitelist" -msgstr "" +msgstr "не-UUID найден в сервисе_uuids_белый список" #: py/compile.c msgid "non-default argument follows default argument" msgstr "" +"Аргумент отличный от аргумента по умолчанию следует за аргументом по " +"умолчанию" #: extmod/modubinascii.c msgid "non-hex digit found" -msgstr "" +msgstr "Ненайдена шестнадцатеричная цифра" #: ports/nrf/common-hal/_bleio/Adapter.c msgid "non-zero timeout must be > 0.01" -msgstr "" +msgstr "Ненулевое время ожидания должно быть > 0,01" #: shared-bindings/_bleio/Adapter.c msgid "non-zero timeout must be >= interval" -msgstr "" +msgstr "Ненулевое время ожидания должно быть >= интервал" #: shared-bindings/_bleio/UUID.c msgid "not a 128-bit UUID" -msgstr "" +msgstr "не 128-битный UUID" #: py/parse.c msgid "not a constant" -msgstr "" +msgstr "не константа" #: py/objstr.c msgid "not all arguments converted during string formatting" -msgstr "" +msgstr "Не все аргументы преобразуются при форматировании строки" #: py/objstr.c msgid "not enough arguments for format string" -msgstr "" +msgstr "Недостаточно аргументов для строки форматирования" #: extmod/ulab/code/numpy/carray/carray_tools.c msgid "not implemented for complex dtype" -msgstr "" +msgstr "не реализовано для сложного типа d" #: extmod/ulab/code/numpy/bitwise.c msgid "not supported for input types" -msgstr "" +msgstr "Не поддерживается для типов ввода" #: extmod/ulab/code/numpy/create.c msgid "number of points must be at least 2" -msgstr "" +msgstr "Количество баллов должно быть не менее 2" #: py/builtinhelp.c msgid "object " -msgstr "" +msgstr "объект " #: py/obj.c #, c-format msgid "object '%s' isn't a tuple or list" -msgstr "" +msgstr "Объект \"%s\" не является кортежом или списком" #: py/obj.c msgid "object doesn't support item assignment" -msgstr "" +msgstr "Объект не поддерживает назначение элементов" #: py/obj.c msgid "object doesn't support item deletion" -msgstr "" +msgstr "Объект не поддерживает удаление элементов" #: py/obj.c msgid "object has no len" -msgstr "" +msgstr "Объект не имеет объектива" #: py/obj.c msgid "object isn't subscriptable" -msgstr "" +msgstr "Объект не имеет индекса" #: py/runtime.c msgid "object not an iterator" -msgstr "" +msgstr "объект не итератор" #: py/objtype.c py/runtime.c msgid "object not callable" -msgstr "" +msgstr "Объект не вызывается" #: py/sequence.c shared-bindings/displayio/Group.c msgid "object not in sequence" -msgstr "" +msgstr "объект не в последовательности" #: py/runtime.c msgid "object not iterable" -msgstr "" +msgstr "Объект не итерируемый" #: py/obj.c #, c-format msgid "object of type '%s' has no len()" -msgstr "" +msgstr "объект типа «%s» не имеет len()" #: py/obj.c msgid "object with buffer protocol required" -msgstr "" +msgstr "Объект с обязательным буферным протоколом" #: extmod/modubinascii.c msgid "odd-length string" -msgstr "" +msgstr "Строка нечетной длины" #: supervisor/shared/web_workflow/web_workflow.c msgid "off" -msgstr "" +msgstr "выключить" #: extmod/ulab/code/utils/utils.c msgid "offset is too large" -msgstr "" +msgstr "Смещение слишком большое" #: shared-bindings/dualbank/__init__.c msgid "offset must be >= 0" -msgstr "" +msgstr "Смещение должно быть >= 0" #: extmod/ulab/code/numpy/create.c msgid "offset must be non-negative and no greater than buffer length" -msgstr "" +msgstr "Смещение должно быть неотрицательным и не превышать длину буфера" #: py/objstr.c py/objstrunicode.c msgid "offset out of bounds" -msgstr "" +msgstr "Смещение за пределы" #: ports/nrf/common-hal/audiobusio/PDMIn.c #: ports/stm/common-hal/audiobusio/PDMIn.c msgid "only bit_depth=16 is supported" -msgstr "" +msgstr "поддерживается только бит_глубина=16" #: ports/stm/common-hal/audiobusio/PDMIn.c msgid "only mono is supported" -msgstr "" +msgstr "Поддерживается только моно" #: extmod/ulab/code/numpy/create.c msgid "only ndarrays can be concatenated" -msgstr "" +msgstr "только массивы ndarrays могут быть объединены" #: ports/stm/common-hal/audiobusio/PDMIn.c msgid "only oversample=64 is supported" -msgstr "" +msgstr "поддерживается только выборка = 64" #: ports/nrf/common-hal/audiobusio/PDMIn.c #: ports/stm/common-hal/audiobusio/PDMIn.c msgid "only sample_rate=16000 is supported" -msgstr "" +msgstr "только образец_рейт=16000 поддерживается" #: py/objarray.c py/objstr.c py/objstrunicode.c py/objtuple.c #: shared-bindings/alarm/SleepMemory.c shared-bindings/memorymap/AddressRange.c #: shared-bindings/nvm/ByteArray.c msgid "only slices with step=1 (aka None) are supported" -msgstr "" +msgstr "поддерживаются только срезы с шагом = 1 (так как нет)" #: py/vm.c msgid "opcode" -msgstr "" +msgstr "код операции" #: extmod/ulab/code/ndarray.c extmod/ulab/code/numpy/bitwise.c #: extmod/ulab/code/numpy/compare.c extmod/ulab/code/numpy/vector.c msgid "operands could not be broadcast together" -msgstr "" +msgstr "Операнды не могут транслироваться вместе" #: extmod/ulab/code/numpy/linalg/linalg.c msgid "operation is defined for 2D arrays only" -msgstr "" +msgstr "операция определена только для 2D-массивов" #: extmod/ulab/code/numpy/linalg/linalg.c msgid "operation is defined for ndarrays only" -msgstr "" +msgstr "операция определена только для массивов ndarrays" #: extmod/ulab/code/ndarray.c msgid "operation is implemented for 1D Boolean arrays only" -msgstr "" +msgstr "операция реализована только для 1D логических массивов" #: extmod/ulab/code/numpy/numerical.c msgid "operation is not implemented on ndarrays" -msgstr "" +msgstr "операция не реализована на массивах ndarrays" #: extmod/ulab/code/ndarray.c msgid "operation is not supported for given type" -msgstr "" +msgstr "Операция не поддерживается для данного типа" #: py/modbuiltins.c msgid "ord expects a character" -msgstr "" +msgstr "Орд ожидает персонажа" #: py/modbuiltins.c #, c-format msgid "ord() expected a character, but string of length %d found" -msgstr "" +msgstr "ord() ожидал символ, но строка длины %d найдена" #: extmod/ulab/code/utils/utils.c msgid "out array is too small" -msgstr "" +msgstr "Наш массив слишком мал" #: extmod/ulab/code/numpy/vector.c msgid "out keyword is not supported for complex dtype" -msgstr "" +msgstr "Ключевое слово out не поддерживается для сложного типа d" #: extmod/ulab/code/numpy/vector.c msgid "out keyword is not supported for function" -msgstr "" +msgstr "ключевое слово не поддерживается для функции" #: extmod/ulab/code/utils/utils.c msgid "out must be a float dense array" -msgstr "" +msgstr "Out должен быть плотным массивом с плавающей запятой" #: extmod/ulab/code/numpy/vector.c msgid "out must be an ndarray" -msgstr "" +msgstr "out должен быть массивом ndarray" #: extmod/ulab/code/numpy/vector.c msgid "out must be of float dtype" -msgstr "" +msgstr "Выход должен быть поплавкового типа" #: shared-bindings/bitmaptools/__init__.c msgid "out of range of target" -msgstr "" +msgstr "вне досягаемости цели" #: py/objint_mpz.c msgid "overflow converting long int to machine word" -msgstr "" +msgstr "переполнение преобразование длинного целого в машинное слово" #: py/modstruct.c #, c-format msgid "pack expected %d items for packing (got %d)" -msgstr "" +msgstr "Упаковка ожидаемых %d товаров для упаковки (получил %d)" #: shared-bindings/_stage/Layer.c shared-bindings/_stage/Text.c msgid "palette must be 32 bytes long" -msgstr "" +msgstr "Длина палитры должна составлять 32 байта" #: py/emitinlinextensa.c msgid "parameters must be registers in sequence a2 to a5" -msgstr "" +msgstr "Параметры должны быть регистрами в последовательности от a2 до a5" #: py/emitinlinethumb.c msgid "parameters must be registers in sequence r0 to r3" -msgstr "" +msgstr "Параметры должны быть регистрами в последовательности от r0 до r3" #: shared-bindings/bitmaptools/__init__.c msgid "pixel coordinates out of bounds" -msgstr "" +msgstr "пиксельные координаты за пределами границ" #: extmod/vfs_posix_file.c msgid "poll on file not available on win32" -msgstr "" +msgstr "Опрос в файле недоступен в Win32" #: ports/espressif/common-hal/pulseio/PulseIn.c msgid "pop from an empty PulseIn" -msgstr "" +msgstr "вытолкнуть из пустого импульсного входа" #: ports/atmel-samd/common-hal/pulseio/PulseIn.c #: ports/cxd56/common-hal/pulseio/PulseIn.c @@ -3930,64 +3977,60 @@ msgstr "" #: ports/stm/common-hal/pulseio/PulseIn.c py/objdict.c py/objlist.c py/objset.c #: shared-bindings/ps2io/Ps2.c msgid "pop from empty %q" -msgstr "" +msgstr "Всплывающее окно из пустого %q" #: shared-bindings/socketpool/Socket.c shared-bindings/ssl/SSLSocket.c msgid "port must be >= 0" -msgstr "" +msgstr "порт должен быть >= 0" #: py/compile.c msgid "positional arg after **" -msgstr "" +msgstr "позиционный аргумент после **" #: py/compile.c msgid "positional arg after keyword arg" -msgstr "" +msgstr "позиционный аргумент после ключевого слова аргумента" #: py/objint_mpz.c msgid "pow() 3rd argument cannot be 0" -msgstr "" +msgstr "3-й аргумент pow() не может быть равен 0" #: py/objint_mpz.c msgid "pow() with 3 arguments requires integers" -msgstr "" +msgstr "pow() с 3 аргументами требует целых чисел" #: ports/raspberrypi/common-hal/rp2pio/StateMachine.c msgid "pull masks conflict with direction masks" -msgstr "" - -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "" +msgstr "Маски вытягивания конфликтуют с масками направления" #: py/parse.c msgid "raw f-strings are not supported" -msgstr "" +msgstr "Необработанные F-строки не поддерживаются" #: extmod/ulab/code/numpy/fft/fft_tools.c msgid "real and imaginary parts must be of equal length" -msgstr "" +msgstr "реальные и воображаемые части должны быть одинаковой длины" #: py/builtinimport.c msgid "relative import" -msgstr "" +msgstr "Относительный импорт" #: py/obj.c #, c-format msgid "requested length %d but object has length %d" -msgstr "" +msgstr "запрашиваемая длина %d, но объект имеет длину %d" #: extmod/ulab/code/ndarray_operators.c msgid "results cannot be cast to specified type" -msgstr "" +msgstr "Результаты не могут быть приведены к указанному типу" #: py/compile.c msgid "return annotation must be an identifier" -msgstr "" +msgstr "Возвращаемая аннотация должна быть идентификатором" #: py/emitnative.c msgid "return expected '%q' but got '%q'" -msgstr "" +msgstr "Возврат ожидался '%q', но получил '%q'" #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format @@ -3997,148 +4040,148 @@ msgstr "rgb_pins[%d] дублирует другое назначение пин #: shared-bindings/rgbmatrix/RGBMatrix.c #, c-format msgid "rgb_pins[%d] is not on the same port as clock" -msgstr "rgb_pins[%d] не находится на том же порту, что и clock" +msgstr "rgb_pins[%d] не находится на том же порту что и часы" #: extmod/ulab/code/numpy/numerical.c msgid "roll argument must be an ndarray" -msgstr "" +msgstr "аргумент roll должен быть массивом ndarray" #: py/objstr.c msgid "rsplit(None,n)" -msgstr "" +msgstr "rsplit(Нет;n)" #: ports/atmel-samd/common-hal/audiobusio/PDMIn.c #: ports/raspberrypi/common-hal/audiobusio/PDMIn.c msgid "sampling rate out of range" -msgstr "" +msgstr "Частота дискретизации выходит за пределы допустимого диапазона" #: py/modmicropython.c msgid "schedule queue full" -msgstr "" +msgstr "Расписание Очередь заполнена" #: py/builtinimport.c msgid "script compilation not supported" -msgstr "" +msgstr "Компиляция скриптов не поддерживается" #: py/nativeglue.c msgid "set unsupported" -msgstr "" +msgstr "Установить не поддерживается" #: extmod/ulab/code/ndarray.c msgid "shape must be integer or tuple of integers" -msgstr "" +msgstr "фигура должна быть целым числом или кортежом целых чисел" #: shared-module/msgpack/__init__.c msgid "short read" -msgstr "" +msgstr "короткое чтение" #: py/objstr.c msgid "sign not allowed in string format specifier" -msgstr "" +msgstr "Знак не разрешен в спецификаторе строкового формата" #: py/objstr.c msgid "sign not allowed with integer format specifier 'c'" -msgstr "" +msgstr "Знак не разрешен со спецификатором целочисленного формата 'c'" #: extmod/ulab/code/ulab_tools.c msgid "size is defined for ndarrays only" -msgstr "" +msgstr "размер определен только для массива ndarrays" #: shared-bindings/time/__init__.c msgid "sleep length must be non-negative" -msgstr "" +msgstr "Продолжительность сна должна быть неотрицательной" #: extmod/ulab/code/ndarray.c msgid "slice step can't be zero" -msgstr "" +msgstr "Шаг среза не может быть равен нулю" #: py/nativeglue.c msgid "slice unsupported" -msgstr "" +msgstr "Фрагмент не поддерживается" #: py/objint.c py/sequence.c msgid "small int overflow" -msgstr "" +msgstr "Маленькое переполнение int" #: main.c msgid "soft reboot\n" -msgstr "" +msgstr "Мягкая перезагрузка\n" #: extmod/ulab/code/numpy/numerical.c msgid "sort argument must be an ndarray" -msgstr "" +msgstr "аргумент сортировки должен быть массивом ndarray" #: extmod/ulab/code/scipy/signal/signal.c msgid "sos array must be of shape (n_section, 6)" -msgstr "" +msgstr "Массив sos должен иметь форму (n_section, 6)" #: extmod/ulab/code/scipy/signal/signal.c msgid "sos[:, 3] should be all ones" -msgstr "" +msgstr "sos[:, 3] должны быть все единицы" #: extmod/ulab/code/scipy/signal/signal.c msgid "sosfilt requires iterable arguments" -msgstr "" +msgstr "sosфильтр требует повторяющихся аргументов" #: shared-bindings/bitmaptools/__init__.c msgid "source palette too large" -msgstr "" +msgstr "Исходная палитра слишком велика" #: shared-bindings/bitmaptools/__init__.c msgid "source_bitmap must have value_count of 2 or 65536" -msgstr "" +msgstr "source_bitmap должен иметь значение_счет 2 или 65536" #: shared-bindings/bitmaptools/__init__.c msgid "source_bitmap must have value_count of 65536" -msgstr "" +msgstr "source_bitmap должен иметь значение_счет 65536" #: shared-bindings/bitmaptools/__init__.c msgid "source_bitmap must have value_count of 8" -msgstr "" +msgstr "source_bitmap должен иметь значение_счет 8" #: py/objstr.c msgid "start/end indices" -msgstr "" +msgstr "Начальные/конечные индексы" #: shared-bindings/random/__init__.c msgid "stop not reachable from start" -msgstr "" +msgstr "Остановка недоступна с начального запуска" #: py/stream.c shared-bindings/getpass/__init__.c msgid "stream operation not supported" -msgstr "" +msgstr "Потоковая операция не поддерживается" #: py/stream.c msgid "string not supported; use bytes or bytearray" -msgstr "" +msgstr "строка не поддерживается; Использование байтов или массива байтов" #: extmod/moductypes.c msgid "struct: can't index" -msgstr "" +msgstr "структура: невозможно индексировать" #: extmod/moductypes.c msgid "struct: index out of range" -msgstr "" +msgstr "структура: индекс вне диапазона" #: extmod/moductypes.c msgid "struct: no fields" -msgstr "" +msgstr "Структура: Нет полей" #: py/objarray.c py/objstr.c msgid "substring not found" -msgstr "" +msgstr "Подстрока не найдена" #: py/compile.c msgid "super() can't find self" -msgstr "" +msgstr "super() не может найти себя" #: extmod/modujson.c msgid "syntax error in JSON" -msgstr "" +msgstr "синтаксис ошибка в JSON" #: extmod/moductypes.c msgid "syntax error in uctypes descriptor" -msgstr "" +msgstr "Синтаксическая ошибка в дескрипторе UCTYPES" #: ports/atmel-samd/common-hal/watchdog/WatchDogTimer.c #: ports/espressif/common-hal/watchdog/WatchDogTimer.c @@ -4146,274 +4189,273 @@ msgstr "" #: ports/raspberrypi/common-hal/watchdog/WatchDogTimer.c msgid "timeout duration exceeded the maximum supported value" msgstr "" +"Продолжительность таймаута превысила максимальное поддерживаемое значение" #: ports/nrf/common-hal/_bleio/Adapter.c msgid "timeout must be < 655.35 secs" -msgstr "" +msgstr "таймаут должен быть < 655.35 сек" #: shared-module/sdcardio/SDCard.c msgid "timeout waiting for v1 card" -msgstr "" +msgstr "Таймаут в ожидании карты v1" #: shared-module/sdcardio/SDCard.c msgid "timeout waiting for v2 card" -msgstr "" +msgstr "Таймаут ожидания карты v2" #: ports/stm/common-hal/pwmio/PWMOut.c msgid "timer re-init" -msgstr "" +msgstr "Повторное инициализация таймера" #: shared-bindings/time/__init__.c msgid "timestamp out of range for platform time_t" msgstr "" +"Временная метка выходит за пределы допустимого диапазона для платформы time_t" #: extmod/ulab/code/ndarray.c msgid "tobytes can be invoked for dense arrays only" -msgstr "" +msgstr "Тобайты могут быть вызваны только для плотных массивов" #: py/compile.c msgid "too many args" -msgstr "" +msgstr "слишком много аргументов" #: extmod/ulab/code/ndarray.c extmod/ulab/code/numpy/create.c msgid "too many dimensions" -msgstr "" +msgstr "Слишком много измерений" #: extmod/ulab/code/ndarray.c msgid "too many indices" -msgstr "" +msgstr "Слишком много индексов" #: py/asmthumb.c msgid "too many locals for native method" -msgstr "" +msgstr "Слишком много местных жителей для нативного метода" #: py/runtime.c #, c-format msgid "too many values to unpack (expected %d)" -msgstr "" +msgstr "Слишком много значений для распаковки (ожидаемый %d)" #: extmod/ulab/code/numpy/approx.c msgid "trapz is defined for 1D arrays of equal length" -msgstr "" +msgstr "ловушка определена для одномерных 1D массивов одинаковой длины" #: extmod/ulab/code/numpy/approx.c msgid "trapz is defined for 1D iterables" -msgstr "" +msgstr "ловушка определена для одномерных 1D итераций" #: py/obj.c msgid "tuple/list has wrong length" -msgstr "" +msgstr "Кортеж/список имеет неправильную длину" #: ports/espressif/common-hal/canio/CAN.c #, c-format msgid "twai_driver_install returned esp-idf error #%d" -msgstr "" +msgstr "twai_driver_install вернул ошибку esp-idf #%d" #: ports/espressif/common-hal/canio/CAN.c #, c-format msgid "twai_start returned esp-idf error #%d" -msgstr "" +msgstr "twai_start вернул ошибку esp-idf #%d" #: shared-bindings/busio/UART.c shared-bindings/canio/CAN.c msgid "tx and rx cannot both be None" -msgstr "" +msgstr "tx и rx не могут быть одновременно None" #: py/objtype.c msgid "type '%q' is not an acceptable base type" -msgstr "" +msgstr "Тип '%Q' не является допустимым базовым типом" #: py/objtype.c msgid "type is not an acceptable base type" -msgstr "" +msgstr "Тип не является приемлемым базовым типом" #: py/runtime.c msgid "type object '%q' has no attribute '%q'" -msgstr "" +msgstr "тип объекта '%q' не имеет атрибута '%q \"" #: py/objtype.c msgid "type takes 1 or 3 arguments" -msgstr "" +msgstr "тип занимает 1 или 3 аргумента" #: py/objint_longlong.c msgid "ulonglong too large" -msgstr "" +msgstr "голова длинная слишком большая" #: py/emitnative.c msgid "unary op %q not implemented" -msgstr "" +msgstr "унарная операция %q не реализована" #: py/parse.c msgid "unexpected indent" -msgstr "" +msgstr "Неожиданный отступ" #: py/bc.c msgid "unexpected keyword argument" -msgstr "" +msgstr "Неожиданный аргумент ключевого слова" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" -msgstr "" +msgstr "неожиданный аргумент ключевого слова '%q'" #: py/lexer.c msgid "unicode name escapes" -msgstr "" +msgstr "Экранирование имен в Юникоде" #: py/parse.c msgid "unindent doesn't match any outer indent level" -msgstr "" +msgstr "Отступ не совпадает ни с одним уровнем внешнего отступа" #: py/objstr.c #, c-format msgid "unknown conversion specifier %c" -msgstr "" +msgstr "Неизвестный спецификатор преобразования %c" #: py/objstr.c msgid "unknown format code '%c' for object of type '%q'" -msgstr "" +msgstr "Неизвестный код формата '%c' для объекта типа '%q'" #: py/compile.c msgid "unknown type" -msgstr "" +msgstr "Неизвестный тип" #: py/compile.c msgid "unknown type '%q'" -msgstr "" +msgstr "Неизвестный тип '%q'" #: py/objstr.c #, c-format msgid "unmatched '%c' in format" -msgstr "" +msgstr "Несовпадающий '%c' в формате" #: py/objtype.c py/runtime.c msgid "unreadable attribute" -msgstr "" +msgstr "Нечитаемый атрибут" #: shared-bindings/displayio/TileGrid.c shared-bindings/vectorio/VectorShape.c msgid "unsupported %q type" -msgstr "" +msgstr "Неподдерживаемый тип %Q" #: py/emitinlinethumb.c #, c-format msgid "unsupported Thumb instruction '%s' with %d arguments" -msgstr "" +msgstr "неподдерживаемая инструкция Thumb '%s' с аргументами %d" #: py/emitinlinextensa.c #, c-format msgid "unsupported Xtensa instruction '%s' with %d arguments" -msgstr "" +msgstr "неподдерживаемая инструкция Xtensa '%s' с аргументами %d" #: shared-module/gifio/GifWriter.c msgid "unsupported colorspace for GifWriter" -msgstr "" +msgstr "неподдерживаемое цветовое пространство для GifWriter" #: shared-bindings/bitmaptools/__init__.c msgid "unsupported colorspace for dither" -msgstr "" +msgstr "Неподдерживаемое цветовое пространство для дизеринга" #: py/objstr.c #, c-format msgid "unsupported format character '%c' (0x%x) at index %d" -msgstr "" +msgstr "Неподдерживаемый символ формата '%c' (0x%x) при индексе %d" #: py/runtime.c msgid "unsupported type for %q: '%q'" -msgstr "" +msgstr "Неподдерживаемый тип для %q: '%q'" #: py/runtime.c msgid "unsupported type for operator" -msgstr "" +msgstr "Неподдерживаемый тип для оператора" #: py/runtime.c msgid "unsupported types for %q: '%q', '%q'" -msgstr "" +msgstr "Неподдерживаемые типы для %q: '%q', '%q'" #: extmod/ulab/code/numpy/io/io.c msgid "usecols is too high" -msgstr "" +msgstr "Usecols слишком высок" #: extmod/ulab/code/numpy/io/io.c msgid "usecols keyword must be specified" -msgstr "" +msgstr "Ключевое слово usecols должно быть указано" #: py/objint.c #, c-format msgid "value must fit in %d byte(s)" -msgstr "" +msgstr "Значение должно совпадать с байтами %d" #: shared-bindings/bitmaptools/__init__.c msgid "value out of range of target" -msgstr "" +msgstr "Величина выходящая за пределы диапазона цели" #: ports/espressif/common-hal/watchdog/WatchDogTimer.c msgid "watchdog not initialized" -msgstr "" +msgstr "Сторожевой таймер не инициализирован" #: shared-bindings/is31fl3741/FrameBuffer.c msgid "width must be greater than zero" -msgstr "" +msgstr "ширина должна быть больше нуля" #: ports/espressif/common-hal/wifi/Radio.c #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "wifi is not enabled" -msgstr "" +msgstr "Wi-Fi не включен" #: ports/raspberrypi/common-hal/wifi/Monitor.c msgid "wifi.Monitor not available" -msgstr "" +msgstr "Wi-Fi. Монитор недоступен" #: shared-bindings/_bleio/Adapter.c msgid "window must be <= interval" -msgstr "" +msgstr "окно должно быть <= интервал" #: extmod/ulab/code/numpy/numerical.c msgid "wrong axis index" -msgstr "" +msgstr "Неправильный индекс оси" #: extmod/ulab/code/numpy/create.c msgid "wrong axis specified" -msgstr "" +msgstr "Указана неправильная ось" #: extmod/ulab/code/numpy/io/io.c msgid "wrong dtype" -msgstr "" +msgstr "Неправильный тип" #: extmod/ulab/code/numpy/transform.c msgid "wrong index type" -msgstr "" +msgstr "Неправильный тип индекса" #: extmod/ulab/code/numpy/compare.c extmod/ulab/code/numpy/create.c #: extmod/ulab/code/numpy/io/io.c extmod/ulab/code/numpy/transform.c #: extmod/ulab/code/numpy/vector.c msgid "wrong input type" -msgstr "" +msgstr "Неправильный тип ввода" #: extmod/ulab/code/numpy/transform.c msgid "wrong length of condition array" -msgstr "" +msgstr "неправильная длина массива состояния" #: extmod/ulab/code/numpy/transform.c msgid "wrong length of index array" -msgstr "" +msgstr "неправильная длина массива индексов" #: extmod/ulab/code/numpy/create.c py/objarray.c py/objstr.c msgid "wrong number of arguments" -msgstr "" +msgstr "неправильное количество аргументов" #: py/runtime.c msgid "wrong number of values to unpack" -msgstr "" +msgstr "Неправильное количество значений для распаковки" #: extmod/ulab/code/numpy/vector.c msgid "wrong output type" msgstr "неверный тип вывода" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "xTaskCreate провалился" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" -msgstr "zi должен быть bytearray" +msgstr "зи, должно быть, массивом ndarray" #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be of float type" @@ -4423,6 +4465,30 @@ msgstr "zi должно быть типа float" msgid "zi must be of shape (n_section, 2)" msgstr "zi должен иметь форму (n_section, 2)" +#~ msgid "ADC2 is being used by WiFi" +#~ msgstr "ADC2 используется WiFi" + +#, c-format +#~ msgid "Unable to configure ADC DMA controller, ErrorCode:%d" +#~ msgstr "Невозможно настроить контроллер ADC DMA, код ошибки:%d" + +#, c-format +#~ msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" +#~ msgstr "Невозможно инициализировать контроллер ADC DMA, код ошибки:%d" + +#, c-format +#~ msgid "Unable to start ADC DMA controller, ErrorCode:%d" +#~ msgstr "Не удается запустить контроллер ADC DMA, код ошибки:%d" + +#~ msgid "xTaskCreate failed" +#~ msgstr "x Создать задачу не удалось" + +#~ msgid "Unable to write to address." +#~ msgstr "Невозможно написать на адрес." + +#~ msgid "queue overflow" +#~ msgstr "Переполнение очереди" + #~ msgid "'coroutine' object is not an iterator" #~ msgstr "Объект 'coroutine' не является итератором" diff --git a/locale/sv.po b/locale/sv.po index 10ff982bad..11bd679480 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: 2023-08-29 18:34+0000\n" +"PO-Revision-Date: 2023-09-10 08:50+0000\n" "Last-Translator: Jonny Bergdahl \n" "Language-Team: LANGUAGE \n" "Language: sv\n" @@ -101,13 +101,17 @@ msgstr "" "%d adresspinnar, %d rgb-pinnar och %d brickor anger en höjd på %d, inte %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -457,10 +461,6 @@ msgstr "3-arguments pow() stöds inte" msgid "A hardware interrupt channel is already in use" msgstr "En kanal för hårdvaruavbrott används redan" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 används av WiFi" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "Kunde inte starta AP" @@ -472,9 +472,14 @@ msgstr "Adressen måste vara %d byte lång" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "Adressintervallet är inte tillåtet" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "Adressintervall ger överflödesfel" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "All CAN-kringutrustning används" @@ -1249,6 +1254,7 @@ msgid "Invalid %q" msgstr "Ogiltig %q" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1404,6 +1410,10 @@ msgstr "Saknad jmp_pin. %q[%u] hoppar på pin" msgid "Must be a %q subclass." msgstr "Måste vara en %q-subklass." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "Måset ange 5/6/5 RGB-pinnar" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Måste ange MISO- eller MOSI-pinne" @@ -2167,6 +2177,10 @@ msgstr "UUID-sträng inte \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\"" msgid "UUID value is not str, int or byte buffer" msgstr "UUID-värdet är inte str, int eller byte-buffert" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "Kan inte komma åt ojusterat IO-register" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2178,11 +2192,6 @@ msgstr "Det går inte att allokera buffert för signerad konvertering" msgid "Unable to allocate the heap." msgstr "Kan inte allokera heap." -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "Kan inte konfigurera ADC DMA controller, Felkod:%d" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "Kan inte skapa lås" @@ -2201,33 +2210,23 @@ msgstr "Det gick inte att hitta ledig GCLK" msgid "Unable to init parser" msgstr "Kan inte initiera tolken" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "Kan inte inititiera ADC DMA-controller, Felkod:%d" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "Det går inte att läsa färgpalettdata" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "Kan inte starta ADC DMA controller, Felkod:%d" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "Det gick inte att starta mDNS-frågan" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "Det går inte att skriva till adress." - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Det gick inte att skriva till nvm." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "Kan inte skriva till skrivskyddat minne" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "Det gick inte att skriva till sleep_memory." @@ -3001,7 +3000,7 @@ msgstr "tom" msgid "empty file" msgstr "tom fil" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "tom heap" @@ -3957,10 +3956,6 @@ msgstr "pow() med 3 argument kräver heltal" msgid "pull masks conflict with direction masks" msgstr "pull-mask är i konflikt med riktnings-mask" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "köstorlek överskreds" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "råa f-strängar stöds inte" @@ -4251,7 +4246,8 @@ msgstr "oväntat indrag" msgid "unexpected keyword argument" msgstr "oväntat nyckelordsargument" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "oväntat nyckelordsargument '%q'" @@ -4408,10 +4404,6 @@ msgstr "fel antal värden för att packa upp" msgid "wrong output type" msgstr "fel utdatatyp" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "xTaskCreate misslyckades" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "zi måste vara en ndarray" @@ -4424,6 +4416,30 @@ 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 "ADC2 is being used by WiFi" +#~ msgstr "ADC2 används av WiFi" + +#, c-format +#~ msgid "Unable to configure ADC DMA controller, ErrorCode:%d" +#~ msgstr "Kan inte konfigurera ADC DMA controller, Felkod:%d" + +#, c-format +#~ msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" +#~ msgstr "Kan inte inititiera ADC DMA-controller, Felkod:%d" + +#, c-format +#~ msgid "Unable to start ADC DMA controller, ErrorCode:%d" +#~ msgstr "Kan inte starta ADC DMA controller, Felkod:%d" + +#~ msgid "xTaskCreate failed" +#~ msgstr "xTaskCreate misslyckades" + +#~ msgid "Unable to write to address." +#~ msgstr "Det går inte att skriva till adress." + +#~ msgid "queue overflow" +#~ msgstr "köstorlek överskreds" + #~ msgid "Stopping AP is not supported." #~ msgstr "Stoppa AP stöds inte." diff --git a/locale/tr.po b/locale/tr.po index 6f245c9862..069b0bba3e 100644 --- a/locale/tr.po +++ b/locale/tr.po @@ -97,13 +97,17 @@ msgstr "" "gösterir, %d'nin değil" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -452,10 +456,6 @@ msgstr "3-argümanlı pow() desteklenmemektedir" msgid "A hardware interrupt channel is already in use" msgstr "Bir donanım kesme kanalı halihazırda kullanılmaktadır" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2, WiFi tarafından kullanılmaktadır" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "" @@ -467,9 +467,14 @@ msgstr "Adres %d byte uzunluğunda olmalıdır" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "Tüm CAN çevre birimleri kullanımda" @@ -1240,6 +1245,7 @@ msgid "Invalid %q" msgstr "Geçersiz %q" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1395,6 +1401,10 @@ msgstr "" msgid "Must be a %q subclass." msgstr "" +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "" @@ -2147,6 +2157,10 @@ msgstr "" msgid "UUID value is not str, int or byte buffer" msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2158,11 +2172,6 @@ msgstr "" msgid "Unable to allocate the heap." msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "" @@ -2181,33 +2190,23 @@ msgstr "" msgid "Unable to init parser" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "" - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "" @@ -2968,7 +2967,7 @@ msgstr "" msgid "empty file" msgstr "" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "" @@ -3919,10 +3918,6 @@ msgstr "" msgid "pull masks conflict with direction masks" msgstr "" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "" @@ -4213,7 +4208,8 @@ msgstr "" msgid "unexpected keyword argument" msgstr "" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "" @@ -4370,10 +4366,6 @@ msgstr "" msgid "wrong output type" msgstr "" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "" @@ -4386,6 +4378,9 @@ msgstr "" msgid "zi must be of shape (n_section, 2)" msgstr "" +#~ msgid "ADC2 is being used by WiFi" +#~ msgstr "ADC2, WiFi tarafından kullanılmaktadır" + #~ msgid "'coroutine' object is not an iterator" #~ msgstr "'coroutine' nesnesi bir iteratör değildir" diff --git a/locale/zh_Latn_pinyin.po b/locale/zh_Latn_pinyin.po index 245a4cc759..558fa37016 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: 2023-08-29 18:34+0000\n" +"PO-Revision-Date: 2023-09-13 17:49+0000\n" "Last-Translator: hexthat \n" "Language-Team: Chinese Hanyu Pinyin\n" "Language: zh_Latn_pinyin\n" @@ -103,13 +103,17 @@ msgstr "" "bù shì %d" #: ports/atmel-samd/common-hal/alarm/__init__.c +#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/cxd56/common-hal/analogio/AnalogOut.c ports/cxd56/common-hal/rtc/RTC.c +#: ports/espressif/common-hal/audiobusio/I2SOut.c #: ports/espressif/common-hal/rtc/RTC.c #: ports/mimxrt10xx/common-hal/analogio/AnalogOut.c #: ports/mimxrt10xx/common-hal/rtc/RTC.c ports/nrf/common-hal/alarm/__init__.c -#: ports/nrf/common-hal/analogio/AnalogOut.c ports/nrf/common-hal/rtc/RTC.c +#: ports/nrf/common-hal/analogio/AnalogOut.c +#: ports/nrf/common-hal/audiobusio/I2SOut.c ports/nrf/common-hal/rtc/RTC.c #: ports/raspberrypi/common-hal/alarm/__init__.c #: ports/raspberrypi/common-hal/analogio/AnalogOut.c +#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c #: ports/raspberrypi/common-hal/rtc/RTC.c ports/stm/common-hal/alarm/__init__.c #: ports/stm/common-hal/canio/Listener.c ports/stm/common-hal/rtc/RTC.c #: shared-bindings/audiobusio/I2SOut.c shared-bindings/audiobusio/PDMIn.c @@ -458,10 +462,6 @@ msgstr "bù zhī chí 3-arg pow()" msgid "A hardware interrupt channel is already in use" msgstr "Yìngjiàn zhōngduàn tōngdào yǐ zài shǐyòng zhōng" -#: ports/espressif/common-hal/analogio/AnalogIn.c -msgid "ADC2 is being used by WiFi" -msgstr "ADC2 zhèngzài bèi WiFi shǐ yòng" - #: ports/raspberrypi/common-hal/wifi/Radio.c msgid "AP could not be started" msgstr "wúfǎ qǐdòng AP" @@ -473,9 +473,14 @@ msgstr "dìzhǐ chángdù bìxū shì %d zìjié" #: ports/espressif/common-hal/memorymap/AddressRange.c #: ports/nrf/common-hal/memorymap/AddressRange.c +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c msgid "Address range not allowed" msgstr "bù yǔn xǔ de dì zhǐ fàn wéi" +#: shared-bindings/memorymap/AddressRange.c +msgid "Address range wraps around" +msgstr "dìzhǐ fànwéi huánrào" + #: ports/espressif/common-hal/canio/CAN.c msgid "All CAN peripherals are in use" msgstr "suǒyǒu CAN wàishè dōu zài shǐyòng zhōng" @@ -1255,6 +1260,7 @@ msgid "Invalid %q" msgstr "wú xiào %q" #: ports/atmel-samd/common-hal/microcontroller/Pin.c +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c #: ports/mimxrt10xx/common-hal/microcontroller/Pin.c #: shared-bindings/microcontroller/Pin.c msgid "Invalid %q pin" @@ -1409,6 +1415,10 @@ msgstr "quēshǎo jmp_pin. %q[%u] tiàodào yǐn jiǎoshàng" msgid "Must be a %q subclass." msgstr "Bìxū shì %q zi lèi." +#: ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c +msgid "Must provide 5/6/5 RGB pins" +msgstr "bìxū tígòng 5/6/5RGB yǐnjiǎo" + #: ports/mimxrt10xx/common-hal/busio/SPI.c shared-bindings/busio/SPI.c msgid "Must provide MISO or MOSI pin" msgstr "Bìxū tígōng MISO huò MOSI yǐn jiǎo" @@ -2170,6 +2180,10 @@ msgstr "UUID Zìfú chuàn bùshì 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" msgid "UUID value is not str, int or byte buffer" msgstr "UUID zhí bùshì str,int huò zì jié huǎnchōng qū" +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to access unaligned IO register" +msgstr "wúfǎ fǎngwèn wèi duìqí de IO jìcúnqì" + #: ports/atmel-samd/common-hal/audiobusio/I2SOut.c #: ports/atmel-samd/common-hal/audioio/AudioOut.c #: ports/raspberrypi/common-hal/audiobusio/I2SOut.c @@ -2181,11 +2195,6 @@ msgstr "Wúfǎ fēnpèi huǎnchōng qū yòng yú qiānmíng zhuǎnhuàn" msgid "Unable to allocate the heap." msgstr "wú fǎ fēn pèi duī." -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to configure ADC DMA controller, ErrorCode:%d" -msgstr "wú fǎ pèi zhì ADC DMA kòng zhì qì, cuò wù dài mǎ:%d" - #: ports/espressif/common-hal/busio/I2C.c msgid "Unable to create lock" msgstr "Wúfǎ chuàngjiàn suǒ" @@ -2204,33 +2213,23 @@ msgstr "Wúfǎ zhǎodào miǎnfèi de GCLK" msgid "Unable to init parser" msgstr "Wúfǎ chūshǐhuà jiěxī qì" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" -msgstr "wú fǎ chū shǐ huà ADC DMA kòng zhì qì, cuò wù dài mǎ:%d" - #: shared-module/displayio/OnDiskBitmap.c msgid "Unable to read color palette data" msgstr "Wúfǎ dúqǔ tiáosèbǎn shùjù" -#: ports/espressif/common-hal/analogbufio/BufferedIn.c -#, c-format -msgid "Unable to start ADC DMA controller, ErrorCode:%d" -msgstr "wú fǎ qǐ dòng ADC DMA kòng zhì qì, cuò wù dài mǎ:%d" - #: ports/espressif/common-hal/mdns/Server.c #: ports/raspberrypi/common-hal/mdns/Server.c msgid "Unable to start mDNS query" msgstr "wú fǎ qǐ dòng mDNS chá xún" -#: shared-bindings/memorymap/AddressRange.c -msgid "Unable to write to address." -msgstr "Wú fǎ xiě rù dì zhǐ." - #: shared-bindings/nvm/ByteArray.c msgid "Unable to write to nvm." msgstr "Wúfǎ xiě rù nvm." +#: ports/raspberrypi/common-hal/memorymap/AddressRange.c +msgid "Unable to write to read-only memory" +msgstr "wúfǎ xiěrù zhǐdú nèicún" + #: shared-bindings/alarm/SleepMemory.c msgid "Unable to write to sleep_memory." msgstr "wú fǎ xiě rù sleep_memory." @@ -3005,7 +3004,7 @@ msgstr "kòngxián" msgid "empty file" msgstr "kōng de wénjiàn" -#: extmod/moduasyncio.c extmod/moduheapq.c extmod/modutimeq.c +#: extmod/moduasyncio.c extmod/moduheapq.c msgid "empty heap" msgstr "kōng yīn yīnxiào" @@ -3959,10 +3958,6 @@ msgstr "pow() yǒu 3 cānshù xūyào zhěngshù" msgid "pull masks conflict with direction masks" msgstr "lā kǒu zhào yǔ fāng xiàng miàn mó chōng tū" -#: extmod/modutimeq.c -msgid "queue overflow" -msgstr "duìliè yìchū" - #: py/parse.c msgid "raw f-strings are not supported" msgstr "bù zhī chí yuán shǐ f-strings" @@ -4256,7 +4251,8 @@ msgstr "wèi yùliào de suō jìn" msgid "unexpected keyword argument" msgstr "yìwài de guānjiàn cí cānshù" -#: py/bc.c py/objnamedtuple.c shared-bindings/traceback/__init__.c +#: py/argcheck.c py/bc.c py/objnamedtuple.c +#: shared-bindings/traceback/__init__.c msgid "unexpected keyword argument '%q'" msgstr "yìwài de guānjiàn cí cānshù '%q'" @@ -4413,10 +4409,6 @@ msgstr "wúfǎ jiě bāo de zhí shù" msgid "wrong output type" msgstr "cuòwù de shūchū lèixíng" -#: ports/espressif/common-hal/audiobusio/__init__.c -msgid "xTaskCreate failed" -msgstr "xTaskCreate shī bài" - #: extmod/ulab/code/scipy/signal/signal.c msgid "zi must be an ndarray" msgstr "zi bìxū shì ndarray" @@ -4429,6 +4421,30 @@ 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 "ADC2 is being used by WiFi" +#~ msgstr "ADC2 zhèngzài bèi WiFi shǐ yòng" + +#, c-format +#~ msgid "Unable to configure ADC DMA controller, ErrorCode:%d" +#~ msgstr "wú fǎ pèi zhì ADC DMA kòng zhì qì, cuò wù dài mǎ:%d" + +#, c-format +#~ msgid "Unable to initialize ADC DMA controller, ErrorCode:%d" +#~ msgstr "wú fǎ chū shǐ huà ADC DMA kòng zhì qì, cuò wù dài mǎ:%d" + +#, c-format +#~ msgid "Unable to start ADC DMA controller, ErrorCode:%d" +#~ msgstr "wú fǎ qǐ dòng ADC DMA kòng zhì qì, cuò wù dài mǎ:%d" + +#~ msgid "xTaskCreate failed" +#~ msgstr "xTaskCreate shī bài" + +#~ msgid "Unable to write to address." +#~ msgstr "Wú fǎ xiě rù dì zhǐ." + +#~ msgid "queue overflow" +#~ msgstr "duìliè yìchū" + #~ msgid "Stopping AP is not supported." #~ msgstr "bù zhī chí tíng zhǐ AP." diff --git a/main.c b/main.c index c37c17dab2..dff92da757 100644 --- a/main.c +++ b/main.c @@ -1042,6 +1042,10 @@ int __attribute__((used)) main(void) { set_safe_mode(SAFE_MODE_NO_CIRCUITPY); } + // We maybe can't initialize the heap until here, because on espressif port we need to be able to check for reserved psram in settings.toml + // (but it's OK if this is a no-op due to the heap being initialized in port_init()) + set_safe_mode(port_heap_init(get_safe_mode())); + #if CIRCUITPY_ALARM // Record which alarm woke us up, if any. // common_hal_alarm_record_wake_alarm() should return a static, non-heap object @@ -1171,6 +1175,13 @@ void gc_collect(void) { MP_WEAK void port_gc_collect() { } +// A port may initialize the heap in port_init but if it cannot (for instance +// in espressif it must be done after CIRCUITPY is mounted) then it must provde +// an implementation of this function. +MP_WEAK safe_mode_t port_heap_init(safe_mode_t safe_mode_in) { + return safe_mode_in; +} + void NORETURN nlr_jump_fail(void *val) { reset_into_safe_mode(SAFE_MODE_NLR_JUMP_FAIL); while (true) { @@ -1179,7 +1190,9 @@ void NORETURN nlr_jump_fail(void *val) { #ifndef NDEBUG static void NORETURN __fatal_error(const char *msg) { + #if CIRCUITPY_DEBUG == 0 reset_into_safe_mode(SAFE_MODE_HARD_FAULT); + #endif while (true) { } } diff --git a/ports/espressif/CMakeLists.txt b/ports/espressif/CMakeLists.txt index ce2935a502..995f8eb76a 100644 --- a/ports/espressif/CMakeLists.txt +++ b/ports/espressif/CMakeLists.txt @@ -1,19 +1,12 @@ # The following five lines of boilerplate have to be in your project's # CMakeLists in this exact order for cmake to work correctly -cmake_minimum_required(VERSION 3.13) +cmake_minimum_required(VERSION 3.16) set(ENV{IDF_PATH} ${CMAKE_SOURCE_DIR}/esp-idf) -# The component list here determines what options we get in menuconfig and what the ninja file -# can build. -set(COMPONENTS esptool_py soc driver log main esp-tls mbedtls mdns esp_event esp_adc_cal esp_netif esp_wifi lwip ulp wpa_supplicant freertos bt usb) - -if("${CIRCUITPY_ESPCAMERA}") -message("Including esp32-camera") -set(EXTRA_COMPONENT_DIRS "esp32-camera") -list(APPEND COMPONENTS "esp32-camera") -message("COMPONENTS = ${COMPONENTS}") -endif() +# The component list here determines what options we get in menuconfig and what the ninja file can build. +set(COMPONENTS bt driver esp-tls esp_adc_cal esp_event esp_netif esp_psram esp_wifi esptool_py freertos log lwip main mbedtls mdns soc ulp usb wpa_supplicant esp-camera esp_lcd) +set(EXTRA_COMPONENT_DIRS "esp-protocols/components/mdns" "esp-camera") include($ENV{IDF_PATH}/tools/cmake/project.cmake) project(circuitpython) diff --git a/ports/espressif/Makefile b/ports/espressif/Makefile index 320fda78fc..0622e67447 100644 --- a/ports/espressif/Makefile +++ b/ports/espressif/Makefile @@ -27,11 +27,23 @@ include ../../py/circuitpy_mkenv.mk ifeq ($(IDF_TARGET),esp32c3) IDF_TARGET_ARCH = riscv CROSS_COMPILE = riscv32-esp-elf- +else ifeq ($(IDF_TARGET),esp32c6) +IDF_TARGET_ARCH = riscv +CROSS_COMPILE = riscv32-esp-elf- +else ifeq ($(IDF_TARGET),esp32h2) +IDF_TARGET_ARCH = riscv +CROSS_COMPILE = riscv32-esp-elf- else IDF_TARGET_ARCH = xtensa CROSS_COMPILE = xtensa-$(IDF_TARGET)-elf- endif +ifeq ($(IDF_TARGET),esp32s3) +BT_IDF_TARGET = esp32c3 +else +BT_IDF_TARGET = $(IDF_TARGET) +endif + ####################################### # CFLAGS ####################################### @@ -51,39 +63,56 @@ INC += \ -isystem esp-idf \ -isystem esp-idf/components/app_update/include \ -isystem esp-idf/components/bootloader_support/include \ - -isystem esp-idf/components/bt/include/$(IDF_TARGET)/include \ + -isystem esp-idf/components/bootloader_support/bootloader_flash/include \ + -isystem esp-idf/components/bt/include/$(BT_IDF_TARGET)/include \ -isystem esp-idf/components/bt/host/nimble/esp-hci/include \ -isystem esp-idf/components/bt/host/nimble/nimble/nimble/controller/include \ -isystem esp-idf/components/bt/host/nimble/nimble/nimble/host/include \ -isystem esp-idf/components/bt/host/nimble/nimble/nimble/host/services/gap/include \ -isystem esp-idf/components/bt/host/nimble/nimble/nimble/include \ -isystem esp-idf/components/bt/host/nimble/nimble/nimble/host/util/include \ + -isystem esp-idf/components/bt/host/nimble/nimble/nimble/transport/include \ -isystem esp-idf/components/bt/host/nimble/nimble/porting/nimble/include \ -isystem esp-idf/components/bt/host/nimble/nimble/porting/npl/freertos/include \ -isystem esp-idf/components/bt/host/nimble/port/include \ -isystem esp-idf/components/driver/include \ + -isystem esp-idf/components/driver/deprecated \ + -isystem esp-idf/components/driver/dac/include \ + -isystem esp-idf/components/driver/gpio/include \ + -isystem esp-idf/components/driver/i2c/include \ + -isystem esp-idf/components/driver/i2s/include \ -isystem esp-idf/components/driver/$(IDF_TARGET)/include \ + -isystem esp-idf/components/driver/ledc/include \ + -isystem esp-idf/components/driver/spi/include \ + -isystem esp-idf/components/driver/temperature_sensor/include \ + -isystem esp-idf/components/driver/touch_sensor/include \ + -isystem esp-idf/components/driver/touch_sensor/$(IDF_TARGET)/include \ + -isystem esp-idf/components/driver/twai/include \ -isystem esp-idf/components/efuse/include \ -isystem esp-idf/components/efuse/$(IDF_TARGET)/include \ -isystem esp-idf/components/$(IDF_TARGET)/include \ - -isystem esp-idf/components/esp_adc_cal/include \ + -isystem esp-idf/components/esp_adc/include \ + -isystem esp-idf/components/esp_adc/$(IDF_TARGET)/include \ + -isystem esp-idf/components/esp_app_format/include \ -isystem esp-idf/components/esp_common/include \ -isystem esp-idf/components/esp_event/include \ -isystem esp-idf/components/esp_hw_support/include \ -isystem esp-idf/components/esp_hw_support/include/soc \ - -isystem esp-idf/components/esp_ipc/include \ -isystem esp-idf/components/esp_netif/include \ + -isystem esp-idf/components/esp_partition/include \ -isystem esp-idf/components/esp_pm/include \ + -isystem esp-idf/components/esp_psram/include \ -isystem esp-idf/components/esp_ringbuf/include \ -isystem esp-idf/components/esp_rom/include \ -isystem esp-idf/components/esp_system/include \ -isystem esp-idf/components/esp_timer/include \ -isystem esp-idf/components/esp_wifi/include \ - -isystem esp-idf/components/freertos/include \ - -isystem esp-idf/components/freertos/include/freertos \ - -isystem esp-idf/components/freertos/include/esp_additions \ - -isystem esp-idf/components/freertos/include/esp_additions/freertos \ - -isystem esp-idf/components/freertos/port/$(IDF_TARGET_ARCH)/include \ + -isystem esp-idf/components/freertos/esp_additions/include \ + -isystem esp-idf/components/freertos/esp_additions/include/freertos \ + -isystem esp-idf/components/freertos/esp_additions/arch/$(IDF_TARGET_ARCH)/include \ + -isystem esp-idf/components/freertos/FreeRTOS-Kernel/include \ + -isystem esp-idf/components/freertos/FreeRTOS-Kernel/include/freertos \ + -isystem esp-idf/components/freertos/FreeRTOS-Kernel/portable/$(IDF_TARGET_ARCH)/include \ -isystem esp-idf/components/hal/include \ -isystem esp-idf/components/hal/$(IDF_TARGET)/include \ -isystem esp-idf/components/hal/platform_port/include \ @@ -91,7 +120,9 @@ INC += \ -isystem esp-idf/components/log/include \ -isystem esp-idf/components/lwip/include \ -isystem esp-idf/components/lwip/lwip/src/include \ - -isystem esp-idf/components/lwip/port/esp32/include \ + -isystem esp-idf/components/lwip/port/include \ + -isystem esp-idf/components/lwip/port/esp32xx/include \ + -isystem esp-idf/components/lwip/port/freertos/include \ -isystem esp-idf/components/mbedtls/esp_crt_bundle/include \ -isystem esp-idf/components/mbedtls/mbedtls/include \ -isystem esp-idf/components/mbedtls/port/include \ @@ -100,13 +131,13 @@ INC += \ -isystem esp-idf/components/soc/include \ -isystem esp-idf/components/soc/$(IDF_TARGET)/include \ -isystem esp-idf/components/spi_flash/include \ + -isystem esp-idf/components/ulp/ulp_fsm/include \ + -isystem esp-idf/components/ulp/ulp_riscv/include \ + -isystem esp-idf/components/ulp/ulp_common/include \ + -isystem esp-idf/components/ulp/ulp_common/include/$(IDF_TARGET) \ -isystem esp-idf/components/$(IDF_TARGET_ARCH)/include \ - -isystem esp-idf/components/$(IDF_TARGET_ARCH)/$(IDF_TARGET)/include - -# See https://github.com/espressif/esp-idf/issues/6906 -ifeq ($(IDF_TARGET),esp32c3) -CFLAGS += -include "esp32c3_fix.h" -endif + -isystem esp-idf/components/$(IDF_TARGET_ARCH)/$(IDF_TARGET)/include \ + -isystem esp-protocols/components/mdns/include CFLAGS += \ -DHAVE_CONFIG_H \ @@ -131,7 +162,7 @@ ifeq ($(DEBUG), 1) # You may want to enable these flags to make setting breakpoints easier. # CFLAGS += -fno-inline -fno-ipa-sra else - CFLAGS += -DNDEBUG -ggdb3 + CFLAGS += -DNDEBUG # RISC-V is larger than xtensa # Use -Os for RISC-V when it overflows ifeq ($(IDF_TARGET_ARCH),riscv) @@ -146,10 +177,16 @@ CFLAGS += $(OPTIMIZATION_FLAGS) CFLAGS += $(INC) -Werror -Wall -std=gnu11 -Wl,--gc-sections $(BASE_CFLAGS) $(C_DEFS) $(CFLAGS_MOD) $(COPT) -Werror=missing-prototypes +# Most current ESPs have nano versions of newlib in ROM so we use them. +ifneq ($(IDF_TARGET),esp32c6) + CFLAGS += --specs=nano.specs + LDFLAGS += -T$(IDF_TARGET).rom.newlib-nano.ld +endif + ifeq ($(IDF_TARGET_ARCH),xtensa) CFLAGS += -mlongcalls else ifeq ($(IDF_TARGET_ARCH),riscv) -CFLAGS += -march=rv32imc +CFLAGS += -march=rv32imac_zicsr_zifencei endif LDFLAGS = $(CFLAGS) -Wl,-nostdlib -Wl,-Map=$@.map -Wl,-cref -Wl,--undefined=uxTopUsedPriority @@ -164,7 +201,6 @@ LDFLAGS += \ -T$(IDF_TARGET).rom.ld \ -T$(IDF_TARGET).rom.api.ld \ -T$(IDF_TARGET).rom.libgcc.ld \ - -T$(IDF_TARGET).rom.newlib-nano.ld \ -Wl,-Bstatic \ -Wl,--no-warn-mismatch \ -Wl,--build-id=none \ @@ -180,6 +216,20 @@ LDFLAGS += \ -Tesp32c3.rom.newlib.ld \ -Tesp32c3.rom.version.ld \ -Tesp32c3.rom.eco3.ld +else ifeq ($(IDF_TARGET),esp32c6) +LDFLAGS += \ + -Tesp32c6.rom.phy.ld \ + -Tesp32c6.rom.pp.ld \ + -Tesp32c6.rom.net80211.ld \ + -Tesp32c6.rom.newlib.ld \ + -Tesp32c6.rom.coexist.ld \ + -Tesp32c6.rom.heap.ld \ + -Tesp32c6.rom.wdt.ld +else ifeq ($(IDF_TARGET),esp32h2) +LDFLAGS += \ + -Tesp32h2.rom.heap.ld \ + -Tesp32h2.rom.newlib.ld \ + -Tesp32h2.rom.wdt.ld else ifeq ($(IDF_TARGET),esp32s2) LDFLAGS += \ -T$(IDF_TARGET).rom.newlib-data.ld \ @@ -194,7 +244,7 @@ endif LIBS := -lgcc -lc -lstdc++ # Use toolchain libm if we're not using our own. -ifndef INTERNAL_LIBM +ifneq ($(INTERNAL_LIBM),1) LIBS += -lm endif @@ -232,22 +282,19 @@ SRC_C += \ peripherals/timer.c \ peripherals/$(IDF_TARGET)/pins.c -ifneq ($(IDF_TARGET),esp32c3) -SRC_C += \ - peripherals/pcnt.c \ - peripherals/touch.c -ifeq ($(IDF_TARGET),esp32s2) -SRC_C += \ - i2s_lcd_esp32s2_driver.c -endif +SRC_C += $(wildcard common-hal/espidf/*.c) + +ifneq ($(CIRCUITPY_ESP_USB_SERIAL_JTAG),0) +SRC_C += supervisor/usb_serial_jtag.c endif -ifeq ($(IDF_TARGET),esp32c3) -SRC_C += \ - supervisor/usb_serial_jtag.c +ifneq ($(CIRCUITPY_COUNTIO),0) +SRC_C += peripherals/pcnt.c endif -$(BUILD)/i2s_lcd_esp32s2_driver.o: CFLAGS += -Wno-sign-compare +ifneq ($(CIRCUITPY_TOUCHIO_USE_NATIVE),0) +SRC_C += peripherals/touch.c +endif ifneq ($(CIRCUITPY_USB),0) SRC_C += lib/tinyusb/src/portable/espressif/esp32sx/dcd_esp32sx.c @@ -257,13 +304,18 @@ ifneq ($(CIRCUITPY_BLEIO),0) SRC_C += common-hal/_bleio/ble_events.c endif +ifneq ($(CIRCUITPY_DOTCLOCKFRAMEBUFFER),0) +CFLAGS += -isystem esp-idf/components/esp_lcd/include +CFLAGS += -isystem esp-idf/components/esp_lcd/interface +endif + ifneq ($(CIRCUITPY_ESPCAMERA),0) SRC_CAMERA := \ $(wildcard common-hal/espcamera/*.c) \ $(wildcard bindings/espcamera/*.c) SRC_C += $(SRC_CAMERA) -CFLAGS += -isystem esp32-camera/driver/include -CFLAGS += -isystem esp32-camera/conversions/include +CFLAGS += -isystem esp-camera/driver/include +CFLAGS += -isystem esp-camera/conversions/include endif ifneq ($(CIRCUITPY_ESPIDF),0) @@ -285,8 +337,6 @@ SRC_ULP := \ $(wildcard common-hal/espulp/*.c) \ $(wildcard bindings/espulp/*.c) SRC_C += $(SRC_ULP) -CFLAGS += -isystem esp-idf/components/ulp/include -CFLAGS += -isystem esp-idf/components/ulp/ulp_riscv/include endif SRC_COMMON_HAL_EXPANDED = \ @@ -329,16 +379,26 @@ $(BUILD)/esp-idf: TARGET_SDKCONFIG = esp-idf-config/sdkconfig-$(IDF_TARGET).defaults + ifeq ($(CIRCUITPY_ESP_FLASH_SIZE), 2MB) - FLASH_SDKCONFIG ?= esp-idf-config/sdkconfig-$(CIRCUITPY_ESP_FLASH_SIZE)-no-ota-no-uf2.defaults + FLASH_SIZE_SDKCONFIG ?= esp-idf-config/sdkconfig-flash-$(CIRCUITPY_ESP_FLASH_SIZE)-no-ota-no-uf2.defaults else UF2_BOOTLOADER ?= $(CIRCUITPY_USB) ifeq ($(UF2_BOOTLOADER), 1) - FLASH_SDKCONFIG ?= esp-idf-config/sdkconfig-$(CIRCUITPY_ESP_FLASH_SIZE).defaults + FLASH_SIZE_SDKCONFIG ?= esp-idf-config/sdkconfig-flash-$(CIRCUITPY_ESP_FLASH_SIZE).defaults else - FLASH_SDKCONFIG ?= esp-idf-config/sdkconfig-$(CIRCUITPY_ESP_FLASH_SIZE)-no-uf2.defaults + FLASH_SIZE_SDKCONFIG ?= esp-idf-config/sdkconfig-flash-$(CIRCUITPY_ESP_FLASH_SIZE)-no-uf2.defaults endif endif +FLASH_MODE_SDKCONFIG ?= esp-idf-config/sdkconfig-flash-$(CIRCUITPY_ESP_FLASH_MODE).defaults +FLASH_SPEED_SDKCONFIG ?= esp-idf-config/sdkconfig-flash-$(CIRCUITPY_ESP_FLASH_FREQ).defaults + +ifneq ($(CIRCUITPY_ESP_PSRAM_SIZE), 0) + PSRAM_SDKCONFIG = esp-idf-config/sdkconfig-psram.defaults + PSRAM_SIZE_SDKCONFIG = esp-idf-config/sdkconfig-psram-$(CIRCUITPY_ESP_PSRAM_SIZE).defaults + PSRAM_MODE_SDKCONFIG = esp-idf-config/sdkconfig-psram-$(CIRCUITPY_ESP_PSRAM_MODE).defaults + PSRAM_SPEED_SDKCONFIG = esp-idf-config/sdkconfig-psram-$(CIRCUITPY_ESP_PSRAM_FREQ).defaults +endif ifeq ($(DEBUG), 1) DEBUG_SDKCONFIG = esp-idf-config/sdkconfig-debug.defaults @@ -346,7 +406,7 @@ else DEBUG_SDKCONFIG = esp-idf-config/sdkconfig-opt.defaults endif -SDKCONFIGS := esp-idf-config/sdkconfig.defaults;$(DEBUG_SDKCONFIG);$(FLASH_SDKCONFIG);$(TARGET_SDKCONFIG);boards/$(BOARD)/sdkconfig +SDKCONFIGS := esp-idf-config/sdkconfig.defaults;$(DEBUG_SDKCONFIG);$(FLASH_SIZE_SDKCONFIG);$(FLASH_MODE_SDKCONFIG);$(FLASH_SPEED_SDKCONFIG);$(PSRAM_SDKCONFIG);$(PSRAM_SIZE_SDKCONFIG);$(PSRAM_MODE_SDKCONFIG);$(PSRAM_SPEED_SDKCONFIG);$(TARGET_SDKCONFIG);boards/$(BOARD)/sdkconfig ifneq ($(CIRCUITPY_BLEIO),0) SDKCONFIGS := esp-idf-config/sdkconfig-ble.defaults;$(SDKCONFIGS) endif @@ -354,8 +414,8 @@ endif .PHONY: do-sdkconfig do-sdkconfig: $(BUILD)/esp-idf/config/sdkconfig.h QSTR_GLOBAL_REQUIREMENTS += $(BUILD)/esp-idf/config/sdkconfig.h -$(BUILD)/esp-idf/config/sdkconfig.h: boards/$(BOARD)/sdkconfig CMakeLists.txt | $(BUILD)/esp-idf - IDF_PATH=$(IDF_PATH) cmake -S . -B $(BUILD)/esp-idf -DSDKCONFIG=$(BUILD)/esp-idf/sdkconfig -DSDKCONFIG_DEFAULTS="$(SDKCONFIGS)" -DCMAKE_TOOLCHAIN_FILE=$(IDF_PATH)/tools/cmake/toolchain-$(IDF_TARGET).cmake -DIDF_TARGET=$(IDF_TARGET) -GNinja -DCIRCUITPY_ESPCAMERA=$(CIRCUITPY_ESPCAMERA) +$(BUILD)/esp-idf/config/sdkconfig.h: boards/$(BOARD)/sdkconfig boards/$(BOARD)/mpconfigboard.mk CMakeLists.txt | $(BUILD)/esp-idf + IDF_PATH=$(IDF_PATH) cmake -S . -B $(BUILD)/esp-idf -DSDKCONFIG=$(BUILD)/esp-idf/sdkconfig -DSDKCONFIG_DEFAULTS="$(SDKCONFIGS)" -DCMAKE_TOOLCHAIN_FILE=$(IDF_PATH)/tools/cmake/toolchain-$(IDF_TARGET).cmake -DIDF_TARGET=$(IDF_TARGET) -GNinja # build a lib # Adding -d explain -j 1 -v to the ninja line will output debug info @@ -374,25 +434,60 @@ $(BUILD)/esp-idf/partition_table/partition-table.bin: $(BUILD)/esp-idf/config/sd # run menuconfig and then remove standard settings menuconfig: $(BUILD)/esp-idf/config $(BUILD)/esp-idf/config/sdkconfig.h $(Q)ninja -C $(BUILD)/esp-idf menuconfig - # Newer versions of the idf will have save-defconfig that will only include non-default values. - # We should use that when available. For now, we sort out everything. python tools/update_sdkconfig.py --board=$(BOARD) --debug=$(DEBUG) -BINARY_WIFI_BLOBS = libcoexist.a libcore.a libespnow.a libmesh.a libnet80211.a libpp.a libsmartconfig.a libwapi.a -BINARY_BLOBS = esp-idf/components/esp_phy/lib/$(IDF_TARGET)/libphy.a $(addprefix esp-idf/components/esp_wifi/lib/$(IDF_TARGET)/, $(BINARY_WIFI_BLOBS)) +update-all-sdkconfigs: $(BUILD)/esp-idf/config/sdkconfig.h + python tools/update_sdkconfig.py --update_all --board=$(BOARD) --debug=$(DEBUG) + +update-board-sdkconfig: $(BUILD)/esp-idf/config/sdkconfig.h + python tools/update_sdkconfig.py --board=$(BOARD) --debug=$(DEBUG) + +BINARY_WIFI_BLOBS = libcore.a libespnow.a libmesh.a libnet80211.a libpp.a libsmartconfig.a libwapi.a +BINARY_BLOBS = esp-idf/components/esp_phy/lib/$(IDF_TARGET)/libphy.a +ifneq ($(CIRCUITPY_WIFI),0) + BINARY_BLOBS += esp-idf/components/esp_coex/lib/$(IDF_TARGET)/libcoexist.a $(addprefix esp-idf/components/esp_wifi/lib/$(IDF_TARGET)/, $(BINARY_WIFI_BLOBS)) +endif ifeq ($(IDF_TARGET),esp32) BINARY_BLOBS += esp-idf/components/esp_phy/lib/$(IDF_TARGET)/librtc.a endif -ESP_IDF_COMPONENTS_LINK = $(IDF_TARGET_ARCH) app_update bootloader_support driver efuse esp_adc_cal esp_common esp_event esp_hw_support esp_ipc esp_netif esp_pm esp_phy esp_ringbuf esp_rom esp_system esp_timer esp-tls esp_wifi freertos hal heap log lwip mbedtls mdns newlib nvs_flash pthread soc spi_flash vfs wpa_supplicant +ESP_IDF_COMPONENTS_LINK = $(IDF_TARGET_ARCH) app_update bootloader_support driver efuse esp_adc esp_app_format esp_common esp_event esp_hw_support esp_mm esp_partition esp_phy esp_pm esp_ringbuf esp_rom esp_system esp_timer freertos hal heap log newlib nvs_flash pthread soc spi_flash vfs +ifneq ($(CIRCUITPY_WIFI),0) + ESP_IDF_COMPONENTS_LINK += esp_coex esp_netif esp-tls esp_wifi lwip mbedtls mdns wpa_supplicant +endif ifneq ($(CIRCUITPY_BLEIO),0) + BLE_IMPL_esp32 := esp32 + BLE_IMPL_esp32s3 := esp32c3 + BLE_IMPL_esp32c2 := libble + BLE_IMPL_esp32c3 := esp32c3 + BLE_IMPL_esp32c6 := libble + BLE_IMPL_esp32h2 := libble + BLE_IMPL = $(BLE_IMPL_$(IDF_TARGET)) + ESP_IDF_COMPONENTS_LINK += bt + ifeq ($(BLE_IMPL),esp32) + BINARY_BLOBS += esp-idf/components/bt/controller/lib_esp32/$(IDF_TARGET)/libbtdm_app.a + endif + + ifeq ($(BLE_IMPL),esp32c3) BINARY_BLOBS += esp-idf/components/esp_phy/lib/$(IDF_TARGET)/libbtbb.a \ - esp-idf/components/bt/controller/lib_esp32c3_family/$(IDF_TARGET)/libbtdm_app.a + esp-idf/components/bt/controller/lib_esp32c3_family/$(IDF_TARGET)/libbtdm_app.a + endif + + ifeq ($(BLE_IMPL),libble) + BINARY_BLOBS += esp-idf/components/esp_phy/lib/$(IDF_TARGET)/libbtbb.a \ + esp-idf/components/bt/controller/lib_$(IDF_TARGET)/$(IDF_TARGET)-bt-lib/libble_app.a + endif endif ifneq ($(CIRCUITPY_ESPULP),0) ESP_IDF_COMPONENTS_LINK += ulp endif +ifneq ($(CIRCUITPY_ESP_PSRAM_SIZE),0) + ESP_IDF_COMPONENTS_LINK += esp_psram +endif +ifneq ($(CIRCUITPY_DOTCLOCKFRAMEBUFFER),0) + ESP_IDF_COMPONENTS_LINK += esp_lcd +endif ESP_IDF_COMPONENTS_EXPANDED = $(foreach component, $(ESP_IDF_COMPONENTS_LINK), $(BUILD)/esp-idf/esp-idf/$(component)/lib$(component).a) @@ -405,16 +500,21 @@ ESP_IDF_COMPONENTS_EXPANDED += esp-idf/components/xtensa/$(IDF_TARGET)/libxt_hal endif ifneq ($(CIRCUITPY_ESPCAMERA),0) -ESP_IDF_COMPONENTS_EXPANDED += $(BUILD)/esp-idf/esp-idf/esp32-camera/libesp32-camera.a +ESP_IDF_COMPONENTS_EXPANDED += $(BUILD)/esp-idf/esp-idf/esp-camera/libesp-camera.a #$(error $(ESP_IDF_COMPONENTS_EXPANDED)) endif ifneq ($(VALID_BOARD),) +# From esp-idf/components/bootloader/Kconfig.projbuild # BOOTLOADER_OFFSET is determined by chip type, based on the ROM bootloader, and is not changeable. ifeq ($(IDF_TARGET),esp32) BOOTLOADER_OFFSET = 0x1000 +else ifeq ($(IDF_TARGET),esp32h2) +BOOTLOADER_OFFSET = 0x0 else ifeq ($(IDF_TARGET),esp32c3) BOOTLOADER_OFFSET = 0x0 +else ifeq ($(IDF_TARGET),esp32c6) +BOOTLOADER_OFFSET = 0x0 else ifeq ($(IDF_TARGET),esp32s3) BOOTLOADER_OFFSET = 0x0 else ifeq ($(IDF_TARGET),esp32s2) @@ -432,9 +532,26 @@ IDF_CMAKE_TARGETS = \ PARTITION_TABLE_OFFSET = 0x8000 FIRMWARE_OFFSET = 0x10000 -ESP_AUTOGEN_LD = $(BUILD)/esp-idf/esp-idf/$(IDF_TARGET)/$(IDF_TARGET)_out.ld $(BUILD)/esp-idf/esp-idf/$(IDF_TARGET)/ld/$(IDF_TARGET).project.ld +# Map the flash's run mode to flashing mode (only dual is supported by the early bootloaders). +# https://github.com/espressif/esp-idf/blob/82cceabc6e6a0a2d8c40e2249bc59917cc5e577a/components/esptool_py/Kconfig.projbuild#L74-L87 +ifeq ($(CIRCUITPY_ESP_FLASH_MODE),dout) + ESPTOOLPY_FLASHMODE = "dout" +endif +ifeq ($(CIRCUITPY_ESP_FLASH_MODE),opi) + ESPTOOLPY_FLASHMODE = "dout" +endif +# Most modes can flash with dio +ESPTOOLPY_FLASHMODE ?= "dio" -FLASH_FLAGS = --flash_mode $(CIRCUITPY_ESP_FLASH_MODE) --flash_freq $(CIRCUITPY_ESP_FLASH_FREQ) --flash_size $(CIRCUITPY_ESP_FLASH_SIZE) +# Cap the flash speed to 80m. +# https://github.com/espressif/esp-idf/blob/82cceabc6e6a0a2d8c40e2249bc59917cc5e577a/components/esptool_py/Kconfig.projbuild#L74-L87 +ifeq ($(CIRCUITPY_ESP_FLASH_FREQ),120m) + ESPTOOLPY_FLASHFREQ = "80m" +else + ESPTOOLPY_FLASHFREQ = $(CIRCUITPY_ESP_FLASH_FREQ) +endif + +FLASH_FLAGS = --flash_mode $(ESPTOOLPY_FLASHMODE) --flash_freq $(ESPTOOLPY_FLASHFREQ) --flash_size $(CIRCUITPY_ESP_FLASH_SIZE) ESPTOOL_FLAGS ?= --before=default_reset --after=no_reset --baud 921600 @@ -452,7 +569,7 @@ esp-idf-stamp: $(BUILD)/esp-idf/config/sdkconfig.h $(BUILD)/firmware.elf: $(OBJ) | esp-idf-stamp $(IDF_CMAKE_TARGETS) $(STEPECHO) "LINK $@" - $(Q)$(CC) -o $@ $(LDFLAGS) $^ -Wl,--start-group $(ESP_IDF_COMPONENTS_EXPANDED) $(BINARY_BLOBS) $(MBEDTLS_COMPONENTS_LINK_EXPANDED) $(BUILD)/esp-idf/esp-idf/newlib/libnewlib.a -Wl,--end-group -u newlib_include_pthread_impl -u ld_include_highint_hdl -Wl,--start-group $(LIBS) -Wl,--end-group $(BUILD)/esp-idf/esp-idf/pthread/libpthread.a -u __cxx_fatal_exception + $(Q)$(CC) -o $@ $(LDFLAGS) $^ -Wl,--start-group $(ESP_IDF_COMPONENTS_EXPANDED) $(BINARY_BLOBS) $(MBEDTLS_COMPONENTS_LINK_EXPANDED) $(LIBS) -Wl,--end-group -u newlib_include_pthread_impl -u ld_include_highint_hdl -u __cxx_fatal_exception $(BUILD)/circuitpython-firmware.bin: $(BUILD)/firmware.elf | tools/build_memory_info.py $(STEPECHO) "Create $@" diff --git a/ports/espressif/README.rst b/ports/espressif/README.rst index 49f372359b..b8b0a097aa 100644 --- a/ports/espressif/README.rst +++ b/ports/espressif/README.rst @@ -9,7 +9,7 @@ Support Status: .. csv-table:: :header: SoC, Status - ESP, "beta" + ESP32, "beta" ESP32-C3, "beta" ESP32-S2, "stable" ESP32-S3, "beta" diff --git a/ports/espressif/bindings/espidf/__init__.h b/ports/espressif/bindings/espidf/__init__.h index e091a5c477..5ace1b3ada 100644 --- a/ports/espressif/bindings/espidf/__init__.h +++ b/ports/espressif/bindings/espidf/__init__.h @@ -31,6 +31,8 @@ #include "py/mpconfig.h" #include "py/obj.h" +#include "common-hal/espidf/__init__.h" + extern const mp_obj_type_t mp_type_espidf_IDFError; extern const mp_obj_type_t mp_type_espidf_MemoryError; diff --git a/ports/espressif/bindings/espnow/Peer.c b/ports/espressif/bindings/espnow/Peer.c index 4cceec1498..6515cb4eeb 100644 --- a/ports/espressif/bindings/espnow/Peer.c +++ b/ports/espressif/bindings/espnow/Peer.c @@ -79,11 +79,13 @@ STATIC mp_obj_t espnow_peer_make_new(const mp_obj_type_t *type, size_t n_args, s self->peer_info.ifidx = (wifi_interface_t)mp_arg_validate_int_range(args[ARG_interface].u_int, 0, 1, MP_QSTR_interface); self->peer_info.encrypt = args[ARG_encrypted].u_bool; + self->lmk_set = false; const mp_obj_t lmk = args[ARG_lmk].u_obj; if (lmk != mp_const_none) { + self->lmk_set = true; memcpy(self->peer_info.lmk, common_hal_espnow_get_bytes_len(lmk, ESP_NOW_KEY_LEN), ESP_NOW_KEY_LEN); - } else if (self->peer_info.encrypt && !self->peer_info.lmk) { + } else if (self->peer_info.encrypt) { mp_raise_ValueError_varg(translate("%q is %q"), MP_QSTR_lmk, MP_QSTR_None); } @@ -196,7 +198,7 @@ STATIC mp_obj_t espnow_peer_set_encrypted(const mp_obj_t self_in, const mp_obj_t self->peer_info.encrypt = mp_obj_is_true(value); - if (!self->peer_info.lmk) { + if (!self->lmk_set) { mp_raise_ValueError_varg(translate("%q is %q"), MP_QSTR_lmk, MP_QSTR_None); } diff --git a/ports/espressif/bindings/espnow/Peer.h b/ports/espressif/bindings/espnow/Peer.h index e4cb828472..23a691b3bc 100644 --- a/ports/espressif/bindings/espnow/Peer.h +++ b/ports/espressif/bindings/espnow/Peer.h @@ -32,6 +32,7 @@ typedef struct { mp_obj_base_t base; esp_now_peer_info_t peer_info; + bool lmk_set; } espnow_peer_obj_t; -const mp_obj_type_t espnow_peer_type; +extern const mp_obj_type_t espnow_peer_type; diff --git a/ports/espressif/boards/01space_lcd042_esp32c3/mpconfigboard.h b/ports/espressif/boards/01space_lcd042_esp32c3/mpconfigboard.h index cae80fa78c..7ff1fb17ca 100644 --- a/ports/espressif/boards/01space_lcd042_esp32c3/mpconfigboard.h +++ b/ports/espressif/boards/01space_lcd042_esp32c3/mpconfigboard.h @@ -36,5 +36,3 @@ // For entering safe mode #define CIRCUITPY_BOOT_BUTTON (&pin_GPIO9) - -#define CIRCUITPY_ESP_USB_SERIAL_JTAG (1) diff --git a/ports/espressif/boards/01space_lcd042_esp32c3/mpconfigboard.mk b/ports/espressif/boards/01space_lcd042_esp32c3/mpconfigboard.mk index e4467a3bbf..5f37ab5fac 100644 --- a/ports/espressif/boards/01space_lcd042_esp32c3/mpconfigboard.mk +++ b/ports/espressif/boards/01space_lcd042_esp32c3/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 1 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/01space_lcd042_esp32c3/sdkconfig b/ports/espressif/boards/01space_lcd042_esp32c3/sdkconfig index 24f7d625ea..3a08db70d5 100644 --- a/ports/espressif/boards/01space_lcd042_esp32c3/sdkconfig +++ b/ports/espressif/boards/01space_lcd042_esp32c3/sdkconfig @@ -1,6 +1,15 @@ -# chip is ESP32-C3 FH4 +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="01Space-LCD042-ESP32C3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_esp32s3_camera/board.c b/ports/espressif/boards/adafruit_esp32s3_camera/board.c index 65042bcea5..83396b81a2 100644 --- a/ports/espressif/boards/adafruit_esp32s3_camera/board.c +++ b/ports/espressif/boards/adafruit_esp32s3_camera/board.c @@ -87,7 +87,7 @@ static void io_expander_backlight_init(void) { i2c_master_write_byte(cmd, AW9523_REG_SOFTRESET, true); i2c_master_write_byte(cmd, 0, true); i2c_master_stop(cmd); - i2c_master_cmd_begin(i2c_num, cmd, 1000 / portTICK_RATE_MS); + i2c_master_cmd_begin(i2c_num, cmd, 1000 / portTICK_PERIOD_MS); i2c_cmd_link_delete(cmd); cmd = i2c_cmd_link_create(); @@ -97,7 +97,7 @@ static void io_expander_backlight_init(void) { i2c_master_write_byte(cmd, AW9523_DEFAULT_CONFIG >> 8, true); i2c_master_write_byte(cmd, AW9523_DEFAULT_CONFIG & 0xff, true); i2c_master_stop(cmd); - i2c_master_cmd_begin(i2c_num, cmd, 1000 / portTICK_RATE_MS); + i2c_master_cmd_begin(i2c_num, cmd, 1000 / portTICK_PERIOD_MS); i2c_cmd_link_delete(cmd); cmd = i2c_cmd_link_create(); @@ -107,7 +107,7 @@ static void io_expander_backlight_init(void) { i2c_master_write_byte(cmd, AW9523_DEFAULT_OUTPUT >> 8, true); i2c_master_write_byte(cmd, AW9523_DEFAULT_OUTPUT & 0xff, true); i2c_master_stop(cmd); - i2c_master_cmd_begin(i2c_num, cmd, 1000 / portTICK_RATE_MS); + i2c_master_cmd_begin(i2c_num, cmd, 1000 / portTICK_PERIOD_MS); i2c_cmd_link_delete(cmd); i2c_driver_delete(i2c_num); diff --git a/ports/espressif/boards/adafruit_esp32s3_camera/mpconfigboard.mk b/ports/espressif/boards/adafruit_esp32s3_camera/mpconfigboard.mk index 6b94c979dc..9ead7e4f21 100644 --- a/ports/espressif/boards/adafruit_esp32s3_camera/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_esp32s3_camera/mpconfigboard.mk @@ -5,9 +5,13 @@ USB_MANUFACTURER = "Adafruit" IDF_TARGET = esp32s3 -CIRCUITPY_ESP_FLASH_MODE = dio -CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB +CIRCUITPY_ESP_FLASH_MODE = dio +CIRCUITPY_ESP_FLASH_FREQ = 80m + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m FLASH_SDKCONFIG = esp-idf-config/sdkconfig-4MB-1ota.defaults CIRCUITPY_AUDIOBUSIO = 0 @@ -19,3 +23,5 @@ CIRCUITPY_ONEWIREIO = 0 CIRCUITPY_PARALLELDISPLAY = 0 CIRCUITPY_RGBMATRIX = 0 CIRCUITPY_ROTARYIO = 0 + +OPTIMIZATION_FLAGS = -Os diff --git a/ports/espressif/boards/adafruit_esp32s3_camera/sdkconfig b/ports/espressif/boards/adafruit_esp32s3_camera/sdkconfig index cf6a6def7c..1bddb7a89f 100644 --- a/ports/espressif/boards/adafruit_esp32s3_camera/sdkconfig +++ b/ports/espressif/boards/adafruit_esp32s3_camera/sdkconfig @@ -1,62 +1,22 @@ +# +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y - -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 - -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP -# CONFIG_OV7670_SUPPORT is not set -# CONFIG_NT99141_SUPPORT is not set -CONFIG_OV3360_SUPPORT=n -# CONFIG_OV2640_SUPPORT is not set -CONFIG_OV5640_SUPPORT=y -# CONFIG_GC2145_SUPPORT is not set -# CONFIG_GC032A_SUPPORT is not set -# CONFIG_GC0308_SUPPORT is not set -# CONFIG_BF3005_SUPPORT is not set -# CONFIG_BF20A6_SUPPORT is not set -# CONFIG_SC101IOT_SUPPORT is not set -# CONFIG_SC030IOT_SUPPORT is not set +# +# Camera configuration +# +# CONFIG_OV7725_SUPPORT is not set +# CONFIG_OV3660_SUPPORT is not set +# end of Camera configuration + # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_feather_esp32_v2/board.c b/ports/espressif/boards/adafruit_feather_esp32_v2/board.c index 78341beb3b..02c3cb2ff4 100644 --- a/ports/espressif/boards/adafruit_feather_esp32_v2/board.c +++ b/ports/espressif/boards/adafruit_feather_esp32_v2/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/adafruit_feather_esp32_v2/mpconfigboard.mk b/ports/espressif/boards/adafruit_feather_esp32_v2/mpconfigboard.mk index 38d689d08a..73b5b00959 100644 --- a/ports/espressif/boards/adafruit_feather_esp32_v2/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_feather_esp32_v2/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 8MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/adafruit_feather_esp32_v2/sdkconfig b/ports/espressif/boards/adafruit_feather_esp32_v2/sdkconfig index c09d8c409a..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_feather_esp32_v2/sdkconfig +++ b/ports/espressif/boards/adafruit_feather_esp32_v2/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32_SPIRAM_SUPPORT=y -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -CONFIG_SPIRAM_SPEED_40M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_IGNORE_NOTFOUND=y -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# CONFIG_SPIRAM_ALLOW_NOINIT_SEG_EXTERNAL_MEMORY is not set -CONFIG_SPIRAM_CACHE_WORKAROUND=y - -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### # CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=8 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=7 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings diff --git a/ports/espressif/boards/adafruit_feather_esp32s2/board.c b/ports/espressif/boards/adafruit_feather_esp32s2/board.c index f701d18442..4d64c316e1 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s2/board.c +++ b/ports/espressif/boards/adafruit_feather_esp32s2/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/adafruit_feather_esp32s2/mpconfigboard.mk b/ports/espressif/boards/adafruit_feather_esp32s2/mpconfigboard.mk index 3ba91e62fd..a5ee61ed55 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s2/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_feather_esp32s2/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/adafruit_feather_esp32s2/sdkconfig b/ports/espressif/boards/adafruit_feather_esp32s2/sdkconfig index 37fd534249..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s2/sdkconfig +++ b/ports/espressif/boards/adafruit_feather_esp32s2/sdkconfig @@ -1,47 +0,0 @@ -# -# Component config -# -# -# ESP32S2-specific -# -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# 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_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# end of SPI RAM config - -# end of ESP32S2-specific - -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP - -# end of Component config diff --git a/ports/espressif/boards/adafruit_feather_esp32s2_reverse_tft/mpconfigboard.mk b/ports/espressif/boards/adafruit_feather_esp32s2_reverse_tft/mpconfigboard.mk index 920b748e3d..be2d2fb4e8 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s2_reverse_tft/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_feather_esp32s2_reverse_tft/mpconfigboard.mk @@ -9,3 +9,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/adafruit_feather_esp32s2_reverse_tft/sdkconfig b/ports/espressif/boards/adafruit_feather_esp32s2_reverse_tft/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s2_reverse_tft/sdkconfig +++ b/ports/espressif/boards/adafruit_feather_esp32s2_reverse_tft/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/adafruit_feather_esp32s2_tft/mpconfigboard.mk b/ports/espressif/boards/adafruit_feather_esp32s2_tft/mpconfigboard.mk index 4b559ff1ee..1a4d00e34b 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s2_tft/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_feather_esp32s2_tft/mpconfigboard.mk @@ -9,3 +9,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/adafruit_feather_esp32s2_tft/sdkconfig b/ports/espressif/boards/adafruit_feather_esp32s2_tft/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s2_tft/sdkconfig +++ b/ports/espressif/boards/adafruit_feather_esp32s2_tft/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/board.c b/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/board.c index 983d62a911..ba228d7b12 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/board.c +++ b/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/mpconfigboard.mk b/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/mpconfigboard.mk index 6d78999532..e45e4bc707 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/mpconfigboard.mk @@ -5,8 +5,13 @@ USB_MANUFACTURER = "Adafruit" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 4MB +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m + +OPTIMIZATION_FLAGS = -Os CIRCUITPY_ESPCAMERA = 0 diff --git a/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/sdkconfig b/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/sdkconfig index 9a05ab0205..f5ef797681 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/sdkconfig +++ b/ports/espressif/boards/adafruit_feather_esp32s3_4mbflash_2mbpsram/sdkconfig @@ -1,43 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -45,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_feather_esp32s3_nopsram/board.c b/ports/espressif/boards/adafruit_feather_esp32s3_nopsram/board.c index 983d62a911..ba228d7b12 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s3_nopsram/board.c +++ b/ports/espressif/boards/adafruit_feather_esp32s3_nopsram/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/adafruit_feather_esp32s3_nopsram/sdkconfig b/ports/espressif/boards/adafruit_feather_esp32s3_nopsram/sdkconfig index 9d924272ec..f5ef797681 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s3_nopsram/sdkconfig +++ b/ports/espressif/boards/adafruit_feather_esp32s3_nopsram/sdkconfig @@ -1,7 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=n - +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_feather_esp32s3_reverse_tft/mpconfigboard.mk b/ports/espressif/boards/adafruit_feather_esp32s3_reverse_tft/mpconfigboard.mk index d027443f56..56dd344dbf 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s3_reverse_tft/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_feather_esp32s3_reverse_tft/mpconfigboard.mk @@ -7,7 +7,13 @@ USB_MANUFACTURER = "Adafruit" IDF_TARGET = esp32s3 CIRCUITPY_ESP_FLASH_MODE = dio -CIRCUITPY_ESP_FLASH_FREQ = 40m +CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m + CIRCUITPY_ESPCAMERA = 0 + +OPTIMIZATION_FLAGS = -Os diff --git a/ports/espressif/boards/adafruit_feather_esp32s3_reverse_tft/sdkconfig b/ports/espressif/boards/adafruit_feather_esp32s3_reverse_tft/sdkconfig index 9a05ab0205..f5ef797681 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s3_reverse_tft/sdkconfig +++ b/ports/espressif/boards/adafruit_feather_esp32s3_reverse_tft/sdkconfig @@ -1,43 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -45,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_feather_esp32s3_tft/mpconfigboard.mk b/ports/espressif/boards/adafruit_feather_esp32s3_tft/mpconfigboard.mk index d801afd493..a94670910b 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s3_tft/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_feather_esp32s3_tft/mpconfigboard.mk @@ -7,7 +7,12 @@ USB_MANUFACTURER = "Adafruit" IDF_TARGET = esp32s3 CIRCUITPY_ESP_FLASH_MODE = dio -CIRCUITPY_ESP_FLASH_FREQ = 40m +CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB +OPTIMIZATION_FLAGS = -Os CIRCUITPY_ESPCAMERA = 0 + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/adafruit_feather_esp32s3_tft/sdkconfig b/ports/espressif/boards/adafruit_feather_esp32s3_tft/sdkconfig index 9a05ab0205..f5ef797681 100644 --- a/ports/espressif/boards/adafruit_feather_esp32s3_tft/sdkconfig +++ b/ports/espressif/boards/adafruit_feather_esp32s3_tft/sdkconfig @@ -1,43 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -45,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_feather_huzzah32/sdkconfig b/ports/espressif/boards/adafruit_feather_huzzah32/sdkconfig index 6c0168c829..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_feather_huzzah32/sdkconfig +++ b/ports/espressif/boards/adafruit_feather_huzzah32/sdkconfig @@ -1,20 +0,0 @@ -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y -CONFIG_ESP32_SPIRAM_SUPPORT=n - -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings diff --git a/ports/espressif/boards/adafruit_funhouse/board.c b/ports/espressif/boards/adafruit_funhouse/board.c index b1a01b2dcb..daa4aa474e 100644 --- a/ports/espressif/boards/adafruit_funhouse/board.c +++ b/ports/espressif/boards/adafruit_funhouse/board.c @@ -50,12 +50,6 @@ uint8_t display_init_sequence[] = { }; void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO37); - common_hal_never_reset_pin(&pin_GPIO38); - #endif /* DEBUG */ - displayio_fourwire_obj_t *bus = &allocate_display_bus()->fourwire_bus; busio_spi_obj_t *spi = &bus->inline_bus; common_hal_busio_spi_construct(spi, &pin_GPIO36, &pin_GPIO35, NULL, false); diff --git a/ports/espressif/boards/adafruit_funhouse/mpconfigboard.mk b/ports/espressif/boards/adafruit_funhouse/mpconfigboard.mk index 7d5c91f154..ce85924ef7 100644 --- a/ports/espressif/boards/adafruit_funhouse/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_funhouse/mpconfigboard.mk @@ -12,8 +12,8 @@ CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESPCAMERA = 0 # Include these Python libraries in firmware. -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_PortalBase -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_FakeRequests -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_Requests FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel -FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_Display_Text + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/adafruit_funhouse/pins.c b/ports/espressif/boards/adafruit_funhouse/pins.c index 17c2ac4256..c94aeebf20 100644 --- a/ports/espressif/boards/adafruit_funhouse/pins.c +++ b/ports/espressif/boards/adafruit_funhouse/pins.c @@ -44,8 +44,8 @@ STATIC const mp_rom_map_elem_t board_module_globals_table[] = { { MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_GPIO33) }, { MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_GPIO34) }, - { MP_OBJ_NEW_QSTR(MP_QSTR_DEBUG_TX), MP_ROM_PTR(&pin_GPIO37) }, - { MP_OBJ_NEW_QSTR(MP_QSTR_DEBUG_RX), MP_ROM_PTR(&pin_GPIO38) }, + { MP_OBJ_NEW_QSTR(MP_QSTR_DEBUG_TX), MP_ROM_PTR(&pin_GPIO43) }, + { MP_OBJ_NEW_QSTR(MP_QSTR_DEBUG_RX), MP_ROM_PTR(&pin_GPIO44) }, { MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&board_i2c_obj) }, { MP_ROM_QSTR(MP_QSTR_STEMMA_I2C), MP_ROM_PTR(&board_i2c_obj) }, diff --git a/ports/espressif/boards/adafruit_funhouse/sdkconfig b/ports/espressif/boards/adafruit_funhouse/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_funhouse/sdkconfig +++ b/ports/espressif/boards/adafruit_funhouse/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/adafruit_huzzah32_breakout/sdkconfig b/ports/espressif/boards/adafruit_huzzah32_breakout/sdkconfig index 6c0168c829..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_huzzah32_breakout/sdkconfig +++ b/ports/espressif/boards/adafruit_huzzah32_breakout/sdkconfig @@ -1,20 +0,0 @@ -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y -CONFIG_ESP32_SPIRAM_SUPPORT=n - -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings diff --git a/ports/espressif/boards/adafruit_magtag_2.9_grayscale/board.c b/ports/espressif/boards/adafruit_magtag_2.9_grayscale/board.c index da070688ed..bd5ad77c93 100644 --- a/ports/espressif/boards/adafruit_magtag_2.9_grayscale/board.c +++ b/ports/espressif/boards/adafruit_magtag_2.9_grayscale/board.c @@ -114,12 +114,6 @@ const uint8_t refresh_sequence[] = { }; void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ - displayio_fourwire_obj_t *bus = &allocate_display_bus()->fourwire_bus; busio_spi_obj_t *spi = &bus->inline_bus; common_hal_busio_spi_construct(spi, &pin_GPIO36, &pin_GPIO35, NULL, false); diff --git a/ports/espressif/boards/adafruit_magtag_2.9_grayscale/mpconfigboard.mk b/ports/espressif/boards/adafruit_magtag_2.9_grayscale/mpconfigboard.mk index d941039078..de31f60d76 100644 --- a/ports/espressif/boards/adafruit_magtag_2.9_grayscale/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_magtag_2.9_grayscale/mpconfigboard.mk @@ -18,3 +18,7 @@ FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_Requests FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_Display_Text FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_LIS3DH + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/adafruit_magtag_2.9_grayscale/sdkconfig b/ports/espressif/boards/adafruit_magtag_2.9_grayscale/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_magtag_2.9_grayscale/sdkconfig +++ b/ports/espressif/boards/adafruit_magtag_2.9_grayscale/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/adafruit_matrixportal_s3/board.c b/ports/espressif/boards/adafruit_matrixportal_s3/board.c index a023845eb0..a5067b98fd 100644 --- a/ports/espressif/boards/adafruit_matrixportal_s3/board.c +++ b/ports/espressif/boards/adafruit_matrixportal_s3/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/adafruit_matrixportal_s3/mpconfigboard.mk b/ports/espressif/boards/adafruit_matrixportal_s3/mpconfigboard.mk index 865fc06d96..3488f22d61 100644 --- a/ports/espressif/boards/adafruit_matrixportal_s3/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_matrixportal_s3/mpconfigboard.mk @@ -6,7 +6,11 @@ USB_MANUFACTURER = "Adafruit" IDF_TARGET = esp32s3 CIRCUITPY_ESP_FLASH_MODE = dio -CIRCUITPY_ESP_FLASH_FREQ = 40m +CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m + CIRCUITPY_ESP32_CAMERA = 0 diff --git a/ports/espressif/boards/adafruit_matrixportal_s3/sdkconfig b/ports/espressif/boards/adafruit_matrixportal_s3/sdkconfig index 2b65102e5a..db95a623aa 100644 --- a/ports/espressif/boards/adafruit_matrixportal_s3/sdkconfig +++ b/ports/espressif/boards/adafruit_matrixportal_s3/sdkconfig @@ -1,39 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # # -# ESP32S3-Specific +# LWIP # -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - CONFIG_LWIP_LOCAL_HOSTNAME="matrixportal-s3" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_metro_esp32s2/mpconfigboard.mk b/ports/espressif/boards/adafruit_metro_esp32s2/mpconfigboard.mk index 8f139315c8..1bf5fd818b 100644 --- a/ports/espressif/boards/adafruit_metro_esp32s2/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_metro_esp32s2/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Adafruit" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/adafruit_metro_esp32s2/sdkconfig b/ports/espressif/boards/adafruit_metro_esp32s2/sdkconfig index 9ad9e6c3bb..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_metro_esp32s2/sdkconfig +++ b/ports/espressif/boards/adafruit_metro_esp32s2/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="Metro-ESP32S2" -# end of LWIP diff --git a/ports/espressif/boards/adafruit_metro_esp32s3/mpconfigboard.mk b/ports/espressif/boards/adafruit_metro_esp32s3/mpconfigboard.mk index 039c689eaf..2fd5a40f25 100644 --- a/ports/espressif/boards/adafruit_metro_esp32s3/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_metro_esp32s3/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Adafruit" IDF_TARGET = esp32s3 -CIRCUITPY_ESP_FLASH_MODE = dio -CIRCUITPY_ESP_FLASH_FREQ = 40m +CIRCUITPY_ESP_FLASH_MODE = qio +CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m +CIRCUITPY_ESP_PSRAM_SIZE = 8MB diff --git a/ports/espressif/boards/adafruit_metro_esp32s3/sdkconfig b/ports/espressif/boards/adafruit_metro_esp32s3/sdkconfig index 2d72ed5391..4b1cfa3641 100644 --- a/ports/espressif/boards/adafruit_metro_esp32s3/sdkconfig +++ b/ports/espressif/boards/adafruit_metro_esp32s3/sdkconfig @@ -1,46 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_MODE_QUAD is not set -CONFIG_SPIRAM_MODE_OCT=y -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="Metro-ESP32S3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_qtpy_esp32_pico/board.c b/ports/espressif/boards/adafruit_qtpy_esp32_pico/board.c index b714fd41f0..0e4504e8b8 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32_pico/board.c +++ b/ports/espressif/boards/adafruit_qtpy_esp32_pico/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/adafruit_qtpy_esp32_pico/mpconfigboard.mk b/ports/espressif/boards/adafruit_qtpy_esp32_pico/mpconfigboard.mk index de41053146..b4b40c58c4 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32_pico/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_qtpy_esp32_pico/mpconfigboard.mk @@ -3,6 +3,10 @@ CIRCUITPY_CREATION_ID = 0x00320003 IDF_TARGET = esp32 -CIRCUITPY_ESP_FLASH_MODE = dio -CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 8MB +CIRCUITPY_ESP_FLASH_MODE = qio +CIRCUITPY_ESP_FLASH_FREQ = 80m + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/adafruit_qtpy_esp32_pico/sdkconfig b/ports/espressif/boards/adafruit_qtpy_esp32_pico/sdkconfig index bec9e436b7..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32_pico/sdkconfig +++ b/ports/espressif/boards/adafruit_qtpy_esp32_pico/sdkconfig @@ -1,45 +0,0 @@ -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -CONFIG_SPIRAM_SPEED_40M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_IGNORE_NOTFOUND=y -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# CONFIG_SPIRAM_ALLOW_NOINIT_SEG_EXTERNAL_MEMORY is not set -CONFIG_SPIRAM_CACHE_WORKAROUND=y - -# -# SPI RAM config -# -CONFIG_ESP32_SPIRAM_SUPPORT=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set - -### # Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### # CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=32 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=7 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings diff --git a/ports/espressif/boards/adafruit_qtpy_esp32c3/mpconfigboard.h b/ports/espressif/boards/adafruit_qtpy_esp32c3/mpconfigboard.h index 32b0940881..9a9ccd8124 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32c3/mpconfigboard.h +++ b/ports/espressif/boards/adafruit_qtpy_esp32c3/mpconfigboard.h @@ -43,5 +43,3 @@ // For entering safe mode #define CIRCUITPY_BOOT_BUTTON (&pin_GPIO9) - -#define CIRCUITPY_ESP_USB_SERIAL_JTAG (1) diff --git a/ports/espressif/boards/adafruit_qtpy_esp32c3/mpconfigboard.mk b/ports/espressif/boards/adafruit_qtpy_esp32c3/mpconfigboard.mk index e2ce1e438d..df1a53faba 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32c3/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_qtpy_esp32c3/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 1 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/adafruit_qtpy_esp32c3/sdkconfig b/ports/espressif/boards/adafruit_qtpy_esp32c3/sdkconfig index b47420753c..aa82df2b81 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32c3/sdkconfig +++ b/ports/espressif/boards/adafruit_qtpy_esp32c3/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="Adafruit-QTPy-ESP32C3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_qtpy_esp32s2/mpconfigboard.mk b/ports/espressif/boards/adafruit_qtpy_esp32s2/mpconfigboard.mk index f1bd7652fe..1460667b9e 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32s2/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_qtpy_esp32s2/mpconfigboard.mk @@ -9,3 +9,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/adafruit_qtpy_esp32s2/sdkconfig b/ports/espressif/boards/adafruit_qtpy_esp32s2/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32s2/sdkconfig +++ b/ports/espressif/boards/adafruit_qtpy_esp32s2/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/board.c b/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/board.c index 3b1f5efd87..164430c88c 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/board.c +++ b/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/mpconfigboard.mk b/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/mpconfigboard.mk index 50b1394a25..60ed676f44 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/mpconfigboard.mk +++ b/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/mpconfigboard.mk @@ -10,4 +10,8 @@ CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m + CIRCUITPY_ESPCAMERA = 0 diff --git a/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/sdkconfig b/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/sdkconfig index 9a05ab0205..f5ef797681 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/sdkconfig +++ b/ports/espressif/boards/adafruit_qtpy_esp32s3_4mbflash_2mbpsram/sdkconfig @@ -1,43 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -45,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_qtpy_esp32s3_nopsram/board.c b/ports/espressif/boards/adafruit_qtpy_esp32s3_nopsram/board.c index 3b1f5efd87..164430c88c 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32s3_nopsram/board.c +++ b/ports/espressif/boards/adafruit_qtpy_esp32s3_nopsram/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/adafruit_qtpy_esp32s3_nopsram/sdkconfig b/ports/espressif/boards/adafruit_qtpy_esp32s3_nopsram/sdkconfig index 9d924272ec..f5ef797681 100644 --- a/ports/espressif/boards/adafruit_qtpy_esp32s3_nopsram/sdkconfig +++ b/ports/espressif/boards/adafruit_qtpy_esp32s3_nopsram/sdkconfig @@ -1,7 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=n - +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/adafruit_qualia_s3_rgb666/board.c b/ports/espressif/boards/adafruit_qualia_s3_rgb666/board.c new file mode 100644 index 0000000000..0639737c35 --- /dev/null +++ b/ports/espressif/boards/adafruit_qualia_s3_rgb666/board.c @@ -0,0 +1,34 @@ +/* + * 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) { +} + +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/adafruit_qualia_s3_rgb666/mpconfigboard.h b/ports/espressif/boards/adafruit_qualia_s3_rgb666/mpconfigboard.h new file mode 100644 index 0000000000..04527bb0a1 --- /dev/null +++ b/ports/espressif/boards/adafruit_qualia_s3_rgb666/mpconfigboard.h @@ -0,0 +1,40 @@ +/* + * 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 "Adafruit-Qualia-S3-RGB666" +#define MICROPY_HW_MCU_NAME "ESP32S3" + +#define DEFAULT_I2C_BUS_SDA (&pin_GPIO8) +#define DEFAULT_I2C_BUS_SCL (&pin_GPIO18) + +#define MICROPY_HW_NEOPIXEL (&pin_GPIO4) // also DBLTAP + +#define DOUBLE_TAP_PIN (&pin_GPIO4) // also NEOPIXEL + +// a 1024x768 16BPP framebuffer + some breathing room +#define DEFAULT_RESERVED_PSRAM (1024 * 1024 * 2) diff --git a/ports/espressif/boards/adafruit_qualia_s3_rgb666/mpconfigboard.mk b/ports/espressif/boards/adafruit_qualia_s3_rgb666/mpconfigboard.mk new file mode 100644 index 0000000000..7659cd160a --- /dev/null +++ b/ports/espressif/boards/adafruit_qualia_s3_rgb666/mpconfigboard.mk @@ -0,0 +1,16 @@ +USB_VID = 0x239A +USB_PID = 0x8148 +USB_PRODUCT = "Qualia-S3-RGB666" +USB_MANUFACTURER = "Adafruit" + +IDF_TARGET = esp32s3 + +CIRCUITPY_ESP_FLASH_SIZE = 16MB +CIRCUITPY_ESP_FLASH_MODE = qio +CIRCUITPY_ESP_FLASH_FREQ = 80m + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 120m + +CIRCUITPY_DOTCLOCKFRAMEBUFFER = 1 diff --git a/ports/espressif/boards/adafruit_qualia_s3_rgb666/pins.c b/ports/espressif/boards/adafruit_qualia_s3_rgb666/pins.c new file mode 100644 index 0000000000..a8920961e0 --- /dev/null +++ b/ports/espressif/boards/adafruit_qualia_s3_rgb666/pins.c @@ -0,0 +1,100 @@ +#include "py/objtuple.h" +#include "shared-bindings/board/__init__.h" + +#define MP_DEFINE_BYTES_OBJ(obj_name, bin) mp_obj_str_t obj_name = {{&mp_type_bytes}, 0, sizeof(bin) - 1, (const byte *)bin} + +static const char i2c_bus_init_sequence[] = { + 2, 3, 0x78, // set GPIO direction + 2, 2, 0, // disable all output inversion + 0, // trailing NUL for python bytes() representation +}; +STATIC MP_DEFINE_BYTES_OBJ(i2c_init_byte_obj, i2c_bus_init_sequence); + +STATIC const mp_rom_map_elem_t tft_io_expander_table[] = { + { MP_ROM_QSTR(MP_QSTR_i2c_address), MP_ROM_INT(0x3f)}, + { MP_ROM_QSTR(MP_QSTR_gpio_address), MP_ROM_INT(1)}, + { MP_ROM_QSTR(MP_QSTR_gpio_data_len), MP_ROM_INT(1)}, + { MP_ROM_QSTR(MP_QSTR_gpio_data), MP_ROM_INT(0xFD)}, + { MP_ROM_QSTR(MP_QSTR_cs_bit), MP_ROM_INT(1)}, + { MP_ROM_QSTR(MP_QSTR_mosi_bit), MP_ROM_INT(7)}, + { MP_ROM_QSTR(MP_QSTR_clk_bit), MP_ROM_INT(0)}, + { MP_ROM_QSTR(MP_QSTR_reset_bit), MP_ROM_INT(2)}, + { MP_ROM_QSTR(MP_QSTR_i2c_init_sequence), &i2c_init_byte_obj}, +}; +MP_DEFINE_CONST_DICT(tft_io_expander_dict, tft_io_expander_table); + +STATIC const mp_rom_obj_tuple_t tft_r_pins = { + {&mp_type_tuple}, + 5, + { + MP_ROM_PTR(&pin_GPIO11), + MP_ROM_PTR(&pin_GPIO10), + MP_ROM_PTR(&pin_GPIO9), + MP_ROM_PTR(&pin_GPIO46), + MP_ROM_PTR(&pin_GPIO3), + } +}; + +STATIC const mp_rom_obj_tuple_t tft_g_pins = { + {&mp_type_tuple}, + 6, + { + MP_ROM_PTR(&pin_GPIO48), + MP_ROM_PTR(&pin_GPIO47), + MP_ROM_PTR(&pin_GPIO21), + MP_ROM_PTR(&pin_GPIO14), + MP_ROM_PTR(&pin_GPIO13), + MP_ROM_PTR(&pin_GPIO12), + } +}; + +STATIC const mp_rom_obj_tuple_t tft_b_pins = { + {&mp_type_tuple}, + 5, + { + MP_ROM_PTR(&pin_GPIO40), + MP_ROM_PTR(&pin_GPIO39), + MP_ROM_PTR(&pin_GPIO38), + MP_ROM_PTR(&pin_GPIO0), + MP_ROM_PTR(&pin_GPIO45), + } +}; + +STATIC const mp_rom_map_elem_t tft_table[] = { + { MP_ROM_QSTR(MP_QSTR_de), MP_ROM_PTR(&pin_GPIO2) }, + { MP_ROM_QSTR(MP_QSTR_vsync), MP_ROM_PTR(&pin_GPIO42) }, + { MP_ROM_QSTR(MP_QSTR_hsync), MP_ROM_PTR(&pin_GPIO41) }, + { MP_ROM_QSTR(MP_QSTR_dclk), MP_ROM_PTR(&pin_GPIO1) }, + { MP_ROM_QSTR(MP_QSTR_red), MP_ROM_PTR(&tft_r_pins) }, + { MP_ROM_QSTR(MP_QSTR_green), MP_ROM_PTR(&tft_g_pins) }, + { MP_ROM_QSTR(MP_QSTR_blue), MP_ROM_PTR(&tft_b_pins) }, +}; +MP_DEFINE_CONST_DICT(tft_dict, tft_table); + +STATIC const mp_rom_map_elem_t board_module_globals_table[] = { + CIRCUITPYTHON_BOARD_DICT_STANDARD_ITEMS + + { MP_ROM_QSTR(MP_QSTR_TFT_PINS), MP_ROM_PTR(&tft_dict) }, + { MP_ROM_QSTR(MP_QSTR_TFT_IO_EXPANDER), MP_ROM_PTR(&tft_io_expander_dict) }, + { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(MICROPY_HW_NEOPIXEL) }, + + { 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_SDA), MP_ROM_PTR(DEFAULT_I2C_BUS_SDA) }, + { MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(DEFAULT_I2C_BUS_SCL) }, + + // I/O expander pin numbers + { MP_ROM_QSTR(MP_QSTR_TFT_SCK), MP_ROM_INT(0) }, + { MP_ROM_QSTR(MP_QSTR_TFT_CS), MP_ROM_INT(1) }, + { MP_ROM_QSTR(MP_QSTR_TFT_RESET), MP_ROM_INT(2) }, + { MP_ROM_QSTR(MP_QSTR_TP_IRQ), MP_ROM_INT(3) }, + { MP_ROM_QSTR(MP_QSTR_BACKLIGHT), MP_ROM_INT(4) }, + { MP_ROM_QSTR(MP_QSTR_BTN_UP), MP_ROM_INT(5) }, + { MP_ROM_QSTR(MP_QSTR_BTN_DN), MP_ROM_INT(6) }, + { MP_ROM_QSTR(MP_QSTR_TFT_MOSI), MP_ROM_INT(7) }, + + { MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&board_i2c_obj) }, + { MP_ROM_QSTR(MP_QSTR_STEMMA_I2C), MP_ROM_PTR(&board_i2c_obj) }, +}; +MP_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table); diff --git a/ports/espressif/boards/adafruit_qualia_s3_rgb666/sdkconfig b/ports/espressif/boards/adafruit_qualia_s3_rgb666/sdkconfig new file mode 100644 index 0000000000..8e26f268e7 --- /dev/null +++ b/ports/espressif/boards/adafruit_qualia_s3_rgb666/sdkconfig @@ -0,0 +1,15 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# LWIP +# +CONFIG_LWIP_LOCAL_HOSTNAME="qualia" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/ai_thinker_esp32-c3s-2m/board.c b/ports/espressif/boards/ai_thinker_esp32-c3s-2m/board.c index 2e09e7d9a4..9e9b34a237 100644 --- a/ports/espressif/boards/ai_thinker_esp32-c3s-2m/board.c +++ b/ports/espressif/boards/ai_thinker_esp32-c3s-2m/board.c @@ -28,16 +28,10 @@ #include "shared-bindings/microcontroller/Pin.h" #include "supervisor/board.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "soc/usb_serial_jtag_struct.h" void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO20); - common_hal_never_reset_pin(&pin_GPIO21); - #endif - // This board has LEDs connected to the USB pins USB_SERIAL_JTAG.conf0.usb_pad_enable = 0; USB_SERIAL_JTAG.conf0.dp_pullup = 0; diff --git a/ports/espressif/boards/ai_thinker_esp32-c3s-2m/mpconfigboard.mk b/ports/espressif/boards/ai_thinker_esp32-c3s-2m/mpconfigboard.mk index 054810a088..fec39d79f3 100644 --- a/ports/espressif/boards/ai_thinker_esp32-c3s-2m/mpconfigboard.mk +++ b/ports/espressif/boards/ai_thinker_esp32-c3s-2m/mpconfigboard.mk @@ -8,3 +8,7 @@ CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 2MB CIRCUITPY_DUALBANK = 0 + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 0 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/ai_thinker_esp32-c3s-2m/sdkconfig b/ports/espressif/boards/ai_thinker_esp32-c3s-2m/sdkconfig index 60d8719596..411bc17724 100644 --- a/ports/espressif/boards/ai_thinker_esp32-c3s-2m/sdkconfig +++ b/ports/espressif/boards/ai_thinker_esp32-c3s-2m/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="AIThinker-ESP32C3S-2M" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/ai_thinker_esp32-c3s/board.c b/ports/espressif/boards/ai_thinker_esp32-c3s/board.c index 2e09e7d9a4..9e9b34a237 100644 --- a/ports/espressif/boards/ai_thinker_esp32-c3s/board.c +++ b/ports/espressif/boards/ai_thinker_esp32-c3s/board.c @@ -28,16 +28,10 @@ #include "shared-bindings/microcontroller/Pin.h" #include "supervisor/board.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "soc/usb_serial_jtag_struct.h" void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO20); - common_hal_never_reset_pin(&pin_GPIO21); - #endif - // This board has LEDs connected to the USB pins USB_SERIAL_JTAG.conf0.usb_pad_enable = 0; USB_SERIAL_JTAG.conf0.dp_pullup = 0; diff --git a/ports/espressif/boards/ai_thinker_esp32-c3s/mpconfigboard.mk b/ports/espressif/boards/ai_thinker_esp32-c3s/mpconfigboard.mk index 3597166303..8bc9948aee 100644 --- a/ports/espressif/boards/ai_thinker_esp32-c3s/mpconfigboard.mk +++ b/ports/espressif/boards/ai_thinker_esp32-c3s/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 0 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/ai_thinker_esp32-c3s/sdkconfig b/ports/espressif/boards/ai_thinker_esp32-c3s/sdkconfig index 88467d9c9e..435604eb4b 100644 --- a/ports/espressif/boards/ai_thinker_esp32-c3s/sdkconfig +++ b/ports/espressif/boards/ai_thinker_esp32-c3s/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="AIThinker-ESP32C3S" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/board.c b/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/board.c +++ b/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/mpconfigboard.mk b/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/mpconfigboard.mk index 4ec2175eca..fdb03078d4 100644 --- a/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/mpconfigboard.mk +++ b/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Ai-Thinker" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/sdkconfig b/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/sdkconfig index 49ee336ed4..e69de29bb2 100644 --- a/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/sdkconfig +++ b/ports/espressif/boards/ai_thinker_esp_12k_nodemcu/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/arduino_nano_esp32s3/board.c b/ports/espressif/boards/arduino_nano_esp32s3/board.c index 8952a19c5d..58432f9811 100644 --- a/ports/espressif/boards/arduino_nano_esp32s3/board.c +++ b/ports/espressif/boards/arduino_nano_esp32s3/board.c @@ -27,15 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} +#include "components/driver/gpio/include/driver/gpio.h" bool espressif_board_reset_pin_number(gpio_num_t pin_number) { if (pin_number == 13) { diff --git a/ports/espressif/boards/arduino_nano_esp32s3/mpconfigboard.mk b/ports/espressif/boards/arduino_nano_esp32s3/mpconfigboard.mk index c9af3af25e..c342e5e2cb 100644 --- a/ports/espressif/boards/arduino_nano_esp32s3/mpconfigboard.mk +++ b/ports/espressif/boards/arduino_nano_esp32s3/mpconfigboard.mk @@ -6,9 +6,17 @@ USB_MANUFACTURER = "Arduino" IDF_TARGET = esp32s3 +# This has a u-blox® NORA-W106-10B module. + +# This flash lives outside the module. CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 8MB +CIRCUITPY_ESP_FLASH_SIZE = 16MB + +# This PSRAM is in the module. +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m INTERNAL_FLASH_FILESYSTEM = 0 QSPI_FLASH_FILESYSTEM = 1 diff --git a/ports/espressif/boards/arduino_nano_esp32s3/sdkconfig b/ports/espressif/boards/arduino_nano_esp32s3/sdkconfig index 2acf08a4a7..f5ef797681 100644 --- a/ports/espressif/boards/arduino_nano_esp32s3/sdkconfig +++ b/ports/espressif/boards/arduino_nano_esp32s3/sdkconfig @@ -1,43 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y - -# -# SPI RAM config -# -# CONFIG_SPIRAM_MODE_QUAD is not set -CONFIG_SPIRAM_MODE_OCT=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/board.c b/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/board.c index 8952a19c5d..58432f9811 100644 --- a/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/board.c +++ b/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/board.c @@ -27,15 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} +#include "components/driver/gpio/include/driver/gpio.h" bool espressif_board_reset_pin_number(gpio_num_t pin_number) { if (pin_number == 13) { diff --git a/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/mpconfigboard.mk b/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/mpconfigboard.mk index 925c4ab6e2..70b2abfede 100644 --- a/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/mpconfigboard.mk +++ b/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/mpconfigboard.mk @@ -6,9 +6,17 @@ USB_MANUFACTURER = "Arduino" IDF_TARGET = esp32s3 +# This has a u-blox® NORA-W106-10B module. + +# This flash lives outside the module. CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 8MB +CIRCUITPY_ESP_FLASH_SIZE = 16MB + +# This PSRAM is in the module. +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m INTERNAL_FLASH_FILESYSTEM = 0 QSPI_FLASH_FILESYSTEM = 1 diff --git a/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/sdkconfig b/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/sdkconfig index 26a26b5fe8..b2e5c546b8 100644 --- a/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/sdkconfig +++ b/ports/espressif/boards/arduino_nano_esp32s3_inverted_statusled/sdkconfig @@ -1,43 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y - -# -# SPI RAM config -# -# CONFIG_SPIRAM_MODE_QUAD is not set -CONFIG_SPIRAM_MODE_OCT=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="nano-esp32" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/artisense_rd00/board.c b/ports/espressif/boards/artisense_rd00/board.c index fb3f6befc9..a23fe0765b 100644 --- a/ports/espressif/boards/artisense_rd00/board.c +++ b/ports/espressif/boards/artisense_rd00/board.c @@ -29,12 +29,6 @@ #include "shared-bindings/microcontroller/Pin.h" void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ - // Crystal common_hal_never_reset_pin(&pin_GPIO15); common_hal_never_reset_pin(&pin_GPIO16); diff --git a/ports/espressif/boards/artisense_rd00/mpconfigboard.mk b/ports/espressif/boards/artisense_rd00/mpconfigboard.mk index 1011143972..307169412f 100644 --- a/ports/espressif/boards/artisense_rd00/mpconfigboard.mk +++ b/ports/espressif/boards/artisense_rd00/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/artisense_rd00/sdkconfig b/ports/espressif/boards/artisense_rd00/sdkconfig index cd57f0d118..36749a928b 100644 --- a/ports/espressif/boards/artisense_rd00/sdkconfig +++ b/ports/espressif/boards/artisense_rd00/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="RD00-ESP32S2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/atmegazero_esp32s2/board.c b/ports/espressif/boards/atmegazero_esp32s2/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/atmegazero_esp32s2/board.c +++ b/ports/espressif/boards/atmegazero_esp32s2/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/atmegazero_esp32s2/mpconfigboard.mk b/ports/espressif/boards/atmegazero_esp32s2/mpconfigboard.mk index 53593be38b..aea0315c7a 100644 --- a/ports/espressif/boards/atmegazero_esp32s2/mpconfigboard.mk +++ b/ports/espressif/boards/atmegazero_esp32s2/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/atmegazero_esp32s2/sdkconfig b/ports/espressif/boards/atmegazero_esp32s2/sdkconfig index b528b9f343..0748a66c5c 100644 --- a/ports/espressif/boards/atmegazero_esp32s2/sdkconfig +++ b/ports/espressif/boards/atmegazero_esp32s2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="ATMegaZero-Esp32s2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/beetle-esp32-c3/mpconfigboard.h b/ports/espressif/boards/beetle-esp32-c3/mpconfigboard.h index 2cdf48fad3..7b93665cee 100644 --- a/ports/espressif/boards/beetle-esp32-c3/mpconfigboard.h +++ b/ports/espressif/boards/beetle-esp32-c3/mpconfigboard.h @@ -40,5 +40,3 @@ #define CIRCUITPY_BOARD_UART (1) #define CIRCUITPY_BOARD_UART_PIN {{.tx = &pin_GPIO21, .rx = &pin_GPIO20}} - -#define CIRCUITPY_ESP_USB_SERIAL_JTAG (1) diff --git a/ports/espressif/boards/beetle-esp32-c3/mpconfigboard.mk b/ports/espressif/boards/beetle-esp32-c3/mpconfigboard.mk index b3fc9f5252..034d94bb5f 100644 --- a/ports/espressif/boards/beetle-esp32-c3/mpconfigboard.mk +++ b/ports/espressif/boards/beetle-esp32-c3/mpconfigboard.mk @@ -7,3 +7,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE=qio CIRCUITPY_ESP_FLASH_FREQ=80m CIRCUITPY_ESP_FLASH_SIZE=4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 1 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/beetle-esp32-c3/sdkconfig b/ports/espressif/boards/beetle-esp32-c3/sdkconfig index 69da6d30fd..2b4299082a 100644 --- a/ports/espressif/boards/beetle-esp32-c3/sdkconfig +++ b/ports/espressif/boards/beetle-esp32-c3/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="beetle-esp32-c3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/bpi_bit_s2/board.c b/ports/espressif/boards/bpi_bit_s2/board.c index 22cdb31898..164430c88c 100644 --- a/ports/espressif/boards/bpi_bit_s2/board.c +++ b/ports/espressif/boards/bpi_bit_s2/board.c @@ -25,14 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/bpi_bit_s2/mpconfigboard.mk b/ports/espressif/boards/bpi_bit_s2/mpconfigboard.mk index 2c793ba5fb..ca2d074434 100644 --- a/ports/espressif/boards/bpi_bit_s2/mpconfigboard.mk +++ b/ports/espressif/boards/bpi_bit_s2/mpconfigboard.mk @@ -11,3 +11,7 @@ CIRCUITPY_ESP_FLASH_SIZE=4MB # Include these Python libraries in firmware. FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/bpi_bit_s2/sdkconfig b/ports/espressif/boards/bpi_bit_s2/sdkconfig index 91758051d3..c9b6f75868 100644 --- a/ports/espressif/boards/bpi_bit_s2/sdkconfig +++ b/ports/espressif/boards/bpi_bit_s2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM Clock and CS IO for ESP32S3 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="BPI-BIT-S2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/bpi_leaf_s3/board.c b/ports/espressif/boards/bpi_leaf_s3/board.c index 3b1f5efd87..164430c88c 100644 --- a/ports/espressif/boards/bpi_leaf_s3/board.c +++ b/ports/espressif/boards/bpi_leaf_s3/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/bpi_leaf_s3/mpconfigboard.h b/ports/espressif/boards/bpi_leaf_s3/mpconfigboard.h index fd6aae04ea..4deba7de0c 100644 --- a/ports/espressif/boards/bpi_leaf_s3/mpconfigboard.h +++ b/ports/espressif/boards/bpi_leaf_s3/mpconfigboard.h @@ -40,3 +40,5 @@ #define DEFAULT_UART_BUS_RX (&pin_GPIO44) #define DEFAULT_UART_BUS_TX (&pin_GPIO43) + +#define DOUBLE_TAP_PIN (&pin_GPIO34) diff --git a/ports/espressif/boards/bpi_leaf_s3/mpconfigboard.mk b/ports/espressif/boards/bpi_leaf_s3/mpconfigboard.mk index e2cd188059..705577187e 100644 --- a/ports/espressif/boards/bpi_leaf_s3/mpconfigboard.mk +++ b/ports/espressif/boards/bpi_leaf_s3/mpconfigboard.mk @@ -5,9 +5,13 @@ USB_MANUFACTURER = "BananaPi" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE=8MB CIRCUITPY_ESP_FLASH_MODE=dio CIRCUITPY_ESP_FLASH_FREQ=80m -CIRCUITPY_ESP_FLASH_SIZE=8MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m # Include these Python libraries in firmware. FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/espressif/boards/bpi_leaf_s3/sdkconfig b/ports/espressif/boards/bpi_leaf_s3/sdkconfig index e9c767ea85..6b3f2584c7 100644 --- a/ports/espressif/boards/bpi_leaf_s3/sdkconfig +++ b/ports/espressif/boards/bpi_leaf_s3/sdkconfig @@ -1,43 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -45,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="BPI-Leaf-S3" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/bpi_picow_s3/board.c b/ports/espressif/boards/bpi_picow_s3/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/bpi_picow_s3/board.c +++ b/ports/espressif/boards/bpi_picow_s3/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/bpi_picow_s3/mpconfigboard.mk b/ports/espressif/boards/bpi_picow_s3/mpconfigboard.mk index 6d77a94b08..02969c05c2 100644 --- a/ports/espressif/boards/bpi_picow_s3/mpconfigboard.mk +++ b/ports/espressif/boards/bpi_picow_s3/mpconfigboard.mk @@ -12,9 +12,13 @@ LONGINT_IMPL = MPZ # so increase it to 32. CFLAGS += -DCFG_TUD_TASK_QUEUE_SZ=32 +CIRCUITPY_ESP_FLASH_SIZE = 8MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 8MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m # Include these Python libraries in firmware. FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/espressif/boards/bpi_picow_s3/sdkconfig b/ports/espressif/boards/bpi_picow_s3/sdkconfig index 04ab118924..914b077264 100644 --- a/ports/espressif/boards/bpi_picow_s3/sdkconfig +++ b/ports/espressif/boards/bpi_picow_s3/sdkconfig @@ -1,43 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -45,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="BPI-PicoW-S3" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/brainboardz_neuron/board.c b/ports/espressif/boards/brainboardz_neuron/board.c index 3b1f5efd87..164430c88c 100755 --- a/ports/espressif/boards/brainboardz_neuron/board.c +++ b/ports/espressif/boards/brainboardz_neuron/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/brainboardz_neuron/mpconfigboard.mk b/ports/espressif/boards/brainboardz_neuron/mpconfigboard.mk index 1083b18264..c7ee91cb3e 100755 --- a/ports/espressif/boards/brainboardz_neuron/mpconfigboard.mk +++ b/ports/espressif/boards/brainboardz_neuron/mpconfigboard.mk @@ -6,6 +6,10 @@ USB_MANUFACTURER = "BrainBoardz" IDF_TARGET = esp32s3 -CIRCUITPY_ESP_FLASH_MODE=dio -CIRCUITPY_ESP_FLASH_FREQ=80m -CIRCUITPY_ESP_FLASH_SIZE=8MB +CIRCUITPY_ESP_FLASH_SIZE = 8MB +CIRCUITPY_ESP_FLASH_MODE = dio +CIRCUITPY_ESP_FLASH_FREQ = 80m + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/brainboardz_neuron/sdkconfig b/ports/espressif/boards/brainboardz_neuron/sdkconfig index 39bd2cdb4e..e553af1776 100755 --- a/ports/espressif/boards/brainboardz_neuron/sdkconfig +++ b/ports/espressif/boards/brainboardz_neuron/sdkconfig @@ -1,34 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_MODE_QUAD is not set -CONFIG_SPIRAM_MODE_OCT=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM Clock and CS IO for ESP32S3 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="BrainBoardzNeuron" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/crcibernetica-ideaboard/sdkconfig b/ports/espressif/boards/crcibernetica-ideaboard/sdkconfig index 6c0168c829..e69de29bb2 100644 --- a/ports/espressif/boards/crcibernetica-ideaboard/sdkconfig +++ b/ports/espressif/boards/crcibernetica-ideaboard/sdkconfig @@ -1,20 +0,0 @@ -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y -CONFIG_ESP32_SPIRAM_SUPPORT=n - -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings diff --git a/ports/espressif/boards/crumpspace_crumps2/board.c b/ports/espressif/boards/crumpspace_crumps2/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/crumpspace_crumps2/board.c +++ b/ports/espressif/boards/crumpspace_crumps2/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/crumpspace_crumps2/mpconfigboard.mk b/ports/espressif/boards/crumpspace_crumps2/mpconfigboard.mk index aca5950f9d..a57c81fdf2 100644 --- a/ports/espressif/boards/crumpspace_crumps2/mpconfigboard.mk +++ b/ports/espressif/boards/crumpspace_crumps2/mpconfigboard.mk @@ -13,3 +13,7 @@ CIRCUITPY_BITBANG_APA102 = 1 # Include these Python libraries in firmware. # FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_DotStar + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/crumpspace_crumps2/sdkconfig b/ports/espressif/boards/crumpspace_crumps2/sdkconfig index 94158d85c5..e1f568a2d8 100644 --- a/ports/espressif/boards/crumpspace_crumps2/sdkconfig +++ b/ports/espressif/boards/crumpspace_crumps2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="CrumpS2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/cytron_maker_feather_aiot_s3/board.c b/ports/espressif/boards/cytron_maker_feather_aiot_s3/board.c index 1f9ef3c4e7..8f1a584194 100644 --- a/ports/espressif/boards/cytron_maker_feather_aiot_s3/board.c +++ b/ports/espressif/boards/cytron_maker_feather_aiot_s3/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/cytron_maker_feather_aiot_s3/mpconfigboard.mk b/ports/espressif/boards/cytron_maker_feather_aiot_s3/mpconfigboard.mk index 53e9750463..98ed6a50fc 100644 --- a/ports/espressif/boards/cytron_maker_feather_aiot_s3/mpconfigboard.mk +++ b/ports/espressif/boards/cytron_maker_feather_aiot_s3/mpconfigboard.mk @@ -5,9 +5,13 @@ USB_MANUFACTURER = "Cytron" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 8MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 8MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m # Include these Python libraries in firmware. FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/espressif/boards/cytron_maker_feather_aiot_s3/sdkconfig b/ports/espressif/boards/cytron_maker_feather_aiot_s3/sdkconfig index f508f4a67c..f5ef797681 100644 --- a/ports/espressif/boards/cytron_maker_feather_aiot_s3/sdkconfig +++ b/ports/espressif/boards/cytron_maker_feather_aiot_s3/sdkconfig @@ -1,34 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_MODE_QUAD is not set -CONFIG_SPIRAM_MODE_OCT=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM Clock and CS IO for ESP32S3 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/deneyap_kart/board.c b/ports/espressif/boards/deneyap_kart/board.c index 8c0c8b8b0b..12d8928cd5 100644 --- a/ports/espressif/boards/deneyap_kart/board.c +++ b/ports/espressif/boards/deneyap_kart/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/deneyap_kart/mpconfigboard.mk b/ports/espressif/boards/deneyap_kart/mpconfigboard.mk index ea8c9a8522..c0667ee4fe 100644 --- a/ports/espressif/boards/deneyap_kart/mpconfigboard.mk +++ b/ports/espressif/boards/deneyap_kart/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/deneyap_kart/sdkconfig b/ports/espressif/boards/deneyap_kart/sdkconfig index 7ec0461dcf..e69de29bb2 100644 --- a/ports/espressif/boards/deneyap_kart/sdkconfig +++ b/ports/espressif/boards/deneyap_kart/sdkconfig @@ -1,19 +0,0 @@ -CONFIG_ESP32_SPIRAM_SUPPORT=y -# -# SPI RAM config -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=8388608 -CONFIG_SPIRAM_SPEED_80M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_IGNORE_NOTFOUND=y -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# CONFIG_SPIRAM_ALLOW_NOINIT_SEG_EXTERNAL_MEMORY is not set -CONFIG_SPIRAM_CACHE_WORKAROUND=y diff --git a/ports/espressif/boards/deneyap_kart_1a/board.c b/ports/espressif/boards/deneyap_kart_1a/board.c index 8c0c8b8b0b..12d8928cd5 100644 --- a/ports/espressif/boards/deneyap_kart_1a/board.c +++ b/ports/espressif/boards/deneyap_kart_1a/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/deneyap_kart_1a/mpconfigboard.mk b/ports/espressif/boards/deneyap_kart_1a/mpconfigboard.mk index 976083217e..423ee1e3e5 100644 --- a/ports/espressif/boards/deneyap_kart_1a/mpconfigboard.mk +++ b/ports/espressif/boards/deneyap_kart_1a/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/deneyap_kart_1a/sdkconfig b/ports/espressif/boards/deneyap_kart_1a/sdkconfig index 7ec0461dcf..e69de29bb2 100644 --- a/ports/espressif/boards/deneyap_kart_1a/sdkconfig +++ b/ports/espressif/boards/deneyap_kart_1a/sdkconfig @@ -1,19 +0,0 @@ -CONFIG_ESP32_SPIRAM_SUPPORT=y -# -# SPI RAM config -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=8388608 -CONFIG_SPIRAM_SPEED_80M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_IGNORE_NOTFOUND=y -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# CONFIG_SPIRAM_ALLOW_NOINIT_SEG_EXTERNAL_MEMORY is not set -CONFIG_SPIRAM_CACHE_WORKAROUND=y diff --git a/ports/espressif/boards/deneyap_kart_1a_v2/mpconfigboard.mk b/ports/espressif/boards/deneyap_kart_1a_v2/mpconfigboard.mk index 5fa5d4822f..fb36bbf0db 100644 --- a/ports/espressif/boards/deneyap_kart_1a_v2/mpconfigboard.mk +++ b/ports/espressif/boards/deneyap_kart_1a_v2/mpconfigboard.mk @@ -9,4 +9,11 @@ IDF_TARGET = esp32s3 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m + CIRCUITPY_ESPCAMERA = 0 + +OPTIMIZATION_FLAGS = -Os diff --git a/ports/espressif/boards/deneyap_kart_1a_v2/sdkconfig b/ports/espressif/boards/deneyap_kart_1a_v2/sdkconfig index 2cdb172e06..2d5e06f985 100644 --- a/ports/espressif/boards/deneyap_kart_1a_v2/sdkconfig +++ b/ports/espressif/boards/deneyap_kart_1a_v2/sdkconfig @@ -1,43 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_MODE_QUAD is not set -CONFIG_SPIRAM_MODE_OCT=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -45,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="DeneyapKart1A_v2" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/deneyap_kart_g/mpconfigboard.h b/ports/espressif/boards/deneyap_kart_g/mpconfigboard.h index ce2969bbda..d882e10861 100644 --- a/ports/espressif/boards/deneyap_kart_g/mpconfigboard.h +++ b/ports/espressif/boards/deneyap_kart_g/mpconfigboard.h @@ -40,5 +40,3 @@ // For entering safe mode #define CIRCUITPY_BOOT_BUTTON (&pin_GPIO9) - -#define CIRCUITPY_ESP_USB_SERIAL_JTAG (1) diff --git a/ports/espressif/boards/deneyap_kart_g/mpconfigboard.mk b/ports/espressif/boards/deneyap_kart_g/mpconfigboard.mk index a470d7a088..98e4e4c9a5 100644 --- a/ports/espressif/boards/deneyap_kart_g/mpconfigboard.mk +++ b/ports/espressif/boards/deneyap_kart_g/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 1 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/deneyap_kart_g/sdkconfig b/ports/espressif/boards/deneyap_kart_g/sdkconfig index a988de5fea..f239c31405 100644 --- a/ports/espressif/boards/deneyap_kart_g/sdkconfig +++ b/ports/espressif/boards/deneyap_kart_g/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="DeneyapKartG" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/deneyap_mini/sdkconfig b/ports/espressif/boards/deneyap_mini/sdkconfig index 7dfaf3052c..3bcde1ab9e 100644 --- a/ports/espressif/boards/deneyap_mini/sdkconfig +++ b/ports/espressif/boards/deneyap_mini/sdkconfig @@ -1,4 +1,15 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="DeneyapMini" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/deneyap_mini_v2/mpconfigboard.mk b/ports/espressif/boards/deneyap_mini_v2/mpconfigboard.mk index fa9c6b40ea..08d5f8a7dd 100644 --- a/ports/espressif/boards/deneyap_mini_v2/mpconfigboard.mk +++ b/ports/espressif/boards/deneyap_mini_v2/mpconfigboard.mk @@ -6,6 +6,10 @@ USB_MANUFACTURER = "Turkish Technology Team Foundation" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/deneyap_mini_v2/sdkconfig b/ports/espressif/boards/deneyap_mini_v2/sdkconfig index 613b744ef2..be30fb4463 100644 --- a/ports/espressif/boards/deneyap_mini_v2/sdkconfig +++ b/ports/espressif/boards/deneyap_mini_v2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="DeneyapMini_v2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/doit_esp32_devkit_v1/sdkconfig b/ports/espressif/boards/doit_esp32_devkit_v1/sdkconfig index 6c0168c829..e69de29bb2 100644 --- a/ports/espressif/boards/doit_esp32_devkit_v1/sdkconfig +++ b/ports/espressif/boards/doit_esp32_devkit_v1/sdkconfig @@ -1,20 +0,0 @@ -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y -CONFIG_ESP32_SPIRAM_SUPPORT=n - -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings diff --git a/ports/espressif/boards/electroniccats_bastwifi/board.c b/ports/espressif/boards/electroniccats_bastwifi/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/electroniccats_bastwifi/board.c +++ b/ports/espressif/boards/electroniccats_bastwifi/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/electroniccats_bastwifi/sdkconfig b/ports/espressif/boards/electroniccats_bastwifi/sdkconfig index 5b9c86dcc3..e69de29bb2 100644 --- a/ports/espressif/boards/electroniccats_bastwifi/sdkconfig +++ b/ports/espressif/boards/electroniccats_bastwifi/sdkconfig @@ -1,6 +0,0 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/es3ink/mpconfigboard.mk b/ports/espressif/boards/es3ink/mpconfigboard.mk index bd55e68379..bb102bf202 100644 --- a/ports/espressif/boards/es3ink/mpconfigboard.mk +++ b/ports/espressif/boards/es3ink/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s3 CIRCUITPY_ESP_FLASH_MODE=dio CIRCUITPY_ESP_FLASH_FREQ=80m CIRCUITPY_ESP_FLASH_SIZE=16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/es3ink/sdkconfig b/ports/espressif/boards/es3ink/sdkconfig index 89d29d8ea9..b023c59d03 100644 --- a/ports/espressif/boards/es3ink/sdkconfig +++ b/ports/espressif/boards/es3ink/sdkconfig @@ -1,16 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y - -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -CONFIG_SPIRAM_MODE_OCT=y -CONFIG_SPIRAM_SPEED_80M=y - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 - -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_USE_MEMMAP=y -CONFIG_SPIRAM_MEMTEST=y - +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# LWIP +# CONFIG_LWIP_LOCAL_HOSTNAME="es3ink" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32_eye/board.c b/ports/espressif/boards/espressif_esp32_eye/board.c index 1c09fb1316..b37123db04 100644 --- a/ports/espressif/boards/espressif_esp32_eye/board.c +++ b/ports/espressif/boards/espressif_esp32_eye/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/espressif_esp32_eye/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32_eye/mpconfigboard.mk index e29ca687c6..65198b8936 100644 --- a/ports/espressif/boards/espressif_esp32_eye/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32_eye/mpconfigboard.mk @@ -3,6 +3,10 @@ CIRCUITPY_CREATION_ID = 0x00320001 IDF_TARGET = esp32 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/espressif_esp32_eye/sdkconfig b/ports/espressif/boards/espressif_esp32_eye/sdkconfig index 26db1e8087..dc4ef1fc52 100644 --- a/ports/espressif/boards/espressif_esp32_eye/sdkconfig +++ b/ports/espressif/boards/espressif_esp32_eye/sdkconfig @@ -1,71 +1,24 @@ -# Automatically generated file. DO NOT EDIT. -# Espressif IoT Development Framework (ESP-IDF) Project Configuration +# +# Espressif IoT Development Framework Configuration # # # Component config # -# -# ESP32-specific -# -CONFIG_ESP32_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=-1 -CONFIG_SPIRAM_SPEED_40M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_IGNORE_NOTFOUND=y -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# CONFIG_SPIRAM_ALLOW_NOINIT_SEG_EXTERNAL_MEMORY is not set -CONFIG_SPIRAM_CACHE_WORKAROUND=y -# CONFIG_SPIRAM_BANKSWITCH_ENABLE is not set -# end of SPI RAM config - -# end of ESP32-specific - -# -# NVS -# -# CONFIG_NVS_ASSERT_ERROR_CHECK is not set -# end of NVS - # # Camera configuration # CONFIG_OV7670_SUPPORT=y -CONFIG_OV7725_SUPPORT=y CONFIG_NT99141_SUPPORT=y CONFIG_OV2640_SUPPORT=y -CONFIG_OV3660_SUPPORT=y -CONFIG_OV5640_SUPPORT=y CONFIG_GC2145_SUPPORT=y CONFIG_GC032A_SUPPORT=y CONFIG_GC0308_SUPPORT=y CONFIG_BF3005_SUPPORT=y CONFIG_BF20A6_SUPPORT=y -# CONFIG_SC101IOT_SUPPORT is not set CONFIG_SC030IOT_SUPPORT=y -# CONFIG_SCCB_HARDWARE_I2C_PORT0 is not set -CONFIG_SCCB_HARDWARE_I2C_PORT1=y -CONFIG_SCCB_CLK_FREQ=100000 -# CONFIG_GC_SENSOR_WINDOWING_MODE is not set CONFIG_GC_SENSOR_SUBSAMPLE_MODE=y -CONFIG_CAMERA_CORE0=y -# CONFIG_CAMERA_CORE1 is not set -# CONFIG_CAMERA_NO_AFFINITY is not set -CONFIG_CAMERA_DMA_BUFFER_SIZE_MAX=32768 # end of Camera configuration # end of Component config -# -CONFIG_ESP_CONSOLE_UART_TX_GPIO=1 -CONFIG_ESP_CONSOLE_UART_RX_GPIO=3 + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32_lyrat/board.c b/ports/espressif/boards/espressif_esp32_lyrat/board.c index 8c0c8b8b0b..12d8928cd5 100644 --- a/ports/espressif/boards/espressif_esp32_lyrat/board.c +++ b/ports/espressif/boards/espressif_esp32_lyrat/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/espressif_esp32_lyrat/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32_lyrat/mpconfigboard.mk index e9fcd24e61..57f3f8da81 100644 --- a/ports/espressif/boards/espressif_esp32_lyrat/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32_lyrat/mpconfigboard.mk @@ -3,8 +3,12 @@ CIRCUITPY_CREATION_ID = 0x0032A000 IDF_TARGET = esp32 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 4MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m CIRCUITPY_ESPCAMERA = 0 diff --git a/ports/espressif/boards/espressif_esp32_lyrat/sdkconfig b/ports/espressif/boards/espressif_esp32_lyrat/sdkconfig index 4b2981ba62..e69de29bb2 100644 --- a/ports/espressif/boards/espressif_esp32_lyrat/sdkconfig +++ b/ports/espressif/boards/espressif_esp32_lyrat/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32_SPIRAM_SUPPORT=y -# SPI RAM config -# -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=4194304 -CONFIG_SPIRAM_SPEED_40M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_IGNORE_NOTFOUND=y -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# CONFIG_SPIRAM_ALLOW_NOINIT_SEG_EXTERNAL_MEMORY is not set -CONFIG_SPIRAM_CACHE_WORKAROUND=y - -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### # CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=8 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=7 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings diff --git a/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/board.c b/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/board.c index b155ed7a7b..f749ee60d2 100644 --- a/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/board.c +++ b/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/board.c @@ -24,15 +24,6 @@ * THE SOFTWARE. */ -#include "shared-bindings/microcontroller/Pin.h" #include "supervisor/board.h" -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO20); - common_hal_never_reset_pin(&pin_GPIO21); - #endif -} - // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/mpconfigboard.mk index cd517e75b4..c3e0b6001d 100644 --- a/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/mpconfigboard.mk @@ -3,6 +3,10 @@ CIRCUITPY_CREATION_ID = 0x00C30001 IDF_TARGET = esp32c3 -CIRCUITPY_ESP_FLASH_MODE = dio +CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 0 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/sdkconfig b/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/sdkconfig index 0e24f8dc77..c4def86e69 100644 --- a/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/sdkconfig +++ b/ports/espressif/boards/espressif_esp32c3_devkitm_1_n4/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="ESP32-C3-DevKitM-1" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/board.c b/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/board.c new file mode 100644 index 0000000000..164430c88c --- /dev/null +++ b/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/board.c @@ -0,0 +1,29 @@ +/* + * 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" + +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/mpconfigboard.h b/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/mpconfigboard.h new file mode 100644 index 0000000000..68fa84c75c --- /dev/null +++ b/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/mpconfigboard.h @@ -0,0 +1,35 @@ +/* + * 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 "ESP32-C6-DevKitC-1-N8" +#define MICROPY_HW_MCU_NAME "ESP32C6" + +#define MICROPY_HW_NEOPIXEL (&pin_GPIO8) + +#define DEFAULT_UART_BUS_RX (&pin_GPIO17) +#define DEFAULT_UART_BUS_TX (&pin_GPIO16) diff --git a/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/mpconfigboard.mk new file mode 100644 index 0000000000..e15d2bf41e --- /dev/null +++ b/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/mpconfigboard.mk @@ -0,0 +1,8 @@ +CIRCUITPY_CREATOR_ID = 0x000C303A +CIRCUITPY_CREATION_ID = 0x00C60002 + +IDF_TARGET = esp32c6 + +CIRCUITPY_ESP_FLASH_MODE = qio +CIRCUITPY_ESP_FLASH_FREQ = 80m +CIRCUITPY_ESP_FLASH_SIZE = 8MB diff --git a/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/pins.c b/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/pins.c new file mode 100644 index 0000000000..441bf33909 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/pins.c @@ -0,0 +1,36 @@ +#include "shared-bindings/board/__init__.h" + +STATIC const mp_rom_map_elem_t board_module_globals_table[] = { + CIRCUITPYTHON_BOARD_DICT_STANDARD_ITEMS + + { 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_IO9), MP_ROM_PTR(&pin_GPIO9) }, + { MP_ROM_QSTR(MP_QSTR_IO10), MP_ROM_PTR(&pin_GPIO10) }, + { 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_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_IO22), MP_ROM_PTR(&pin_GPIO22) }, + { MP_ROM_QSTR(MP_QSTR_IO23), MP_ROM_PTR(&pin_GPIO23) }, + { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_GPIO8) }, + + { MP_ROM_QSTR(MP_QSTR_TX), MP_ROM_PTR(&pin_GPIO16) }, + { MP_ROM_QSTR(MP_QSTR_RX), MP_ROM_PTR(&pin_GPIO17) }, + + { MP_ROM_QSTR(MP_QSTR_UART), MP_ROM_PTR(&board_uart_obj) }, +}; +MP_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table); diff --git a/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/sdkconfig b/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/sdkconfig new file mode 100644 index 0000000000..54a5473075 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32c6_devkitc_1_n8/sdkconfig @@ -0,0 +1,15 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# LWIP +# +CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32c6" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/board.c b/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/board.c new file mode 100644 index 0000000000..f749ee60d2 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/board.c @@ -0,0 +1,29 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2021 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 "supervisor/board.h" + +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/esp32c3_fix.h b/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/mpconfigboard.h similarity index 77% rename from ports/espressif/esp32c3_fix.h rename to ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/mpconfigboard.h index cbd36ef2fb..dd6b260e51 100644 --- a/ports/espressif/esp32c3_fix.h +++ b/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/mpconfigboard.h @@ -24,19 +24,14 @@ * THE SOFTWARE. */ -// See https://github.com/espressif/esp-idf/issues/6906 +// Board setup +#define MICROPY_HW_BOARD_NAME "ESP32-C6-DevKitM-1" +#define MICROPY_HW_MCU_NAME "ESP32-C6N4" -#ifndef MICROPY_INCLUDED_ESPRESSIF_ESP32C3_FIX_H -#define MICROPY_INCLUDED_ESPRESSIF_ESP32C3_FIX_H +// Status LED +#define MICROPY_HW_NEOPIXEL (&pin_GPIO8) +#define MICROPY_HW_NEOPIXEL_COUNT (1) -#ifdef __riscv - -#undef __INT32_TYPE__ -#define __INT32_TYPE__ int - -#undef __UINT32_TYPE__ -#define __UINT32_TYPE__ unsigned int - -#endif // __riscv - -#endif // MICROPY_INCLUDED_ESPRESSIF_ESP32C3_FIX_H +// Default bus pins +#define DEFAULT_UART_BUS_RX (&pin_GPIO16) +#define DEFAULT_UART_BUS_TX (&pin_GPIO17) diff --git a/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/mpconfigboard.mk new file mode 100644 index 0000000000..3588556427 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/mpconfigboard.mk @@ -0,0 +1,10 @@ +CIRCUITPY_CREATOR_ID = 0x000C303A +CIRCUITPY_CREATION_ID = 0x00C60001 + +IDF_TARGET = esp32c6 + +CIRCUITPY_ESP_FLASH_MODE = qio +CIRCUITPY_ESP_FLASH_FREQ = 80m +CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/pins.c b/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/pins.c new file mode 100644 index 0000000000..243b6040d0 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/pins.c @@ -0,0 +1,61 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2021 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/board/__init__.h" + +STATIC const mp_rom_map_elem_t board_module_globals_table[] = { + CIRCUITPYTHON_BOARD_DICT_STANDARD_ITEMS + + { 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_IO9), MP_ROM_PTR(&pin_GPIO9) }, + { MP_ROM_QSTR(MP_QSTR_IO10), MP_ROM_PTR(&pin_GPIO10) }, + { 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_RX), MP_ROM_PTR(&pin_GPIO20) }, + { MP_ROM_QSTR(MP_QSTR_TX), MP_ROM_PTR(&pin_GPIO21) }, + + { MP_ROM_QSTR(MP_QSTR_MTMS), MP_ROM_PTR(&pin_GPIO4) }, + { MP_ROM_QSTR(MP_QSTR_MTDI), MP_ROM_PTR(&pin_GPIO5) }, + { MP_ROM_QSTR(MP_QSTR_MTCK), MP_ROM_PTR(&pin_GPIO6) }, + { MP_ROM_QSTR(MP_QSTR_MTDO), MP_ROM_PTR(&pin_GPIO7) }, + + { MP_ROM_QSTR(MP_QSTR_BUTTON), MP_ROM_PTR(&pin_GPIO9) }, + { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_GPIO8) }, + + { MP_ROM_QSTR(MP_QSTR_UART), MP_ROM_PTR(&board_uart_obj) }, +}; +MP_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table); diff --git a/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/sdkconfig b/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/sdkconfig new file mode 100644 index 0000000000..30a4bea2cc --- /dev/null +++ b/ports/espressif/boards/espressif_esp32c6_devkitm_1_n4/sdkconfig @@ -0,0 +1,15 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# LWIP +# +CONFIG_LWIP_LOCAL_HOSTNAME="ESP32-C6-DevKitM-1" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/board.c b/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/board.c new file mode 100644 index 0000000000..f749ee60d2 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/board.c @@ -0,0 +1,29 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2021 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 "supervisor/board.h" + +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/mpconfigboard.h b/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/mpconfigboard.h new file mode 100644 index 0000000000..1536f4296d --- /dev/null +++ b/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/mpconfigboard.h @@ -0,0 +1,37 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2021 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. + */ + +// Board setup +#define MICROPY_HW_BOARD_NAME "ESP32-H2-DevKitM-1" +#define MICROPY_HW_MCU_NAME "ESP32-H2N4" + +// Status LED +#define MICROPY_HW_NEOPIXEL (&pin_GPIO8) +#define MICROPY_HW_NEOPIXEL_COUNT (1) + +// Default bus pins +#define DEFAULT_UART_BUS_RX (&pin_GPIO23) +#define DEFAULT_UART_BUS_TX (&pin_GPIO24) diff --git a/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/mpconfigboard.mk new file mode 100644 index 0000000000..82eb611bdf --- /dev/null +++ b/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/mpconfigboard.mk @@ -0,0 +1,8 @@ +CIRCUITPY_CREATOR_ID = 0x000C303A +CIRCUITPY_CREATION_ID = 0x01420001 + +IDF_TARGET = esp32h2 + +CIRCUITPY_ESP_FLASH_MODE = qio +CIRCUITPY_ESP_FLASH_FREQ = 48m +CIRCUITPY_ESP_FLASH_SIZE = 4MB diff --git a/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/pins.c b/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/pins.c new file mode 100644 index 0000000000..466962a34f --- /dev/null +++ b/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/pins.c @@ -0,0 +1,62 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2021 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/board/__init__.h" + +STATIC const mp_rom_map_elem_t board_module_globals_table[] = { + CIRCUITPYTHON_BOARD_DICT_STANDARD_ITEMS + + { 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_IO8), MP_ROM_PTR(&pin_GPIO8) }, + { MP_ROM_QSTR(MP_QSTR_IO9), MP_ROM_PTR(&pin_GPIO9) }, + { MP_ROM_QSTR(MP_QSTR_IO10), MP_ROM_PTR(&pin_GPIO10) }, + { 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_IO22), MP_ROM_PTR(&pin_GPIO22) }, + + { MP_ROM_QSTR(MP_QSTR_RX), MP_ROM_PTR(&pin_GPIO23) }, + { MP_ROM_QSTR(MP_QSTR_TX), MP_ROM_PTR(&pin_GPIO24) }, + + { MP_ROM_QSTR(MP_QSTR_IO25), MP_ROM_PTR(&pin_GPIO25) }, + + { MP_ROM_QSTR(MP_QSTR_MTMS), MP_ROM_PTR(&pin_GPIO2) }, + { MP_ROM_QSTR(MP_QSTR_MTDO), MP_ROM_PTR(&pin_GPIO3) }, + { MP_ROM_QSTR(MP_QSTR_MTCK), MP_ROM_PTR(&pin_GPIO4) }, + { MP_ROM_QSTR(MP_QSTR_MTDI), MP_ROM_PTR(&pin_GPIO5) }, + + { MP_ROM_QSTR(MP_QSTR_BUTTON), MP_ROM_PTR(&pin_GPIO9) }, + { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_GPIO8) }, + + { MP_ROM_QSTR(MP_QSTR_UART), MP_ROM_PTR(&board_uart_obj) }, +}; +MP_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table); diff --git a/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/sdkconfig b/ports/espressif/boards/espressif_esp32h2_devkitm_1_n4/sdkconfig new file mode 100644 index 0000000000..e69de29bb2 diff --git a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4/board.c b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4/board.c +++ b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4/sdkconfig b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4/sdkconfig index 1aad0eadd1..57f0da698a 100644 --- a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/board.c b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/board.c +++ b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/mpconfigboard.mk index aef3ce0dc7..51abedf36a 100644 --- a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Espressif" IDF_TARGET = esp32s2 -CIRCUITPY_ESP_FLASH_MODE = dio -CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB +CIRCUITPY_ESP_FLASH_MODE = qio +CIRCUITPY_ESP_FLASH_FREQ = 80m + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/sdkconfig b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/sdkconfig index 926a7813ba..57f0da698a 100644 --- a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n4r2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM Clock and CS IO for ESP32S3 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/board.c b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/board.c +++ b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/mpconfigboard.mk index 883df304f4..d274e3e6dd 100644 --- a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE=dio CIRCUITPY_ESP_FLASH_FREQ=40m CIRCUITPY_ESP_FLASH_SIZE=8MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/sdkconfig b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/sdkconfig index 926a7813ba..57f0da698a 100644 --- a/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s2_devkitc_1_n8r2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM Clock and CS IO for ESP32S3 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_box/board.c b/ports/espressif/boards/espressif_esp32s3_box/board.c index a91a924d04..4a2ce0efed 100644 --- a/ports/espressif/boards/espressif_esp32s3_box/board.c +++ b/ports/espressif/boards/espressif_esp32s3_box/board.c @@ -88,12 +88,6 @@ void board_init(void) { true, // backlight_on_high false, // SH1107_addressing 50000); // backlight pwm frequency - - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif } // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s3_box/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32s3_box/mpconfigboard.mk index 5a2a4794bd..5f357ec503 100644 --- a/ports/espressif/boards/espressif_esp32s3_box/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32s3_box/mpconfigboard.mk @@ -5,8 +5,12 @@ USB_MANUFACTURER = "Espressif" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m CIRCUITPY_ESPCAMERA = 0 diff --git a/ports/espressif/boards/espressif_esp32s3_box/sdkconfig b/ports/espressif/boards/espressif_esp32s3_box/sdkconfig index 6884299abe..f5ef797681 100644 --- a/ports/espressif/boards/espressif_esp32s3_box/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s3_box/sdkconfig @@ -1,14 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_MODE_OCT=y -CONFIG_SPIRAM_SPEED_80M=y -CONFIG_SPIRAM_TYPE_AUTO=y - -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_USE_MEMMAP=y - +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_box_lite/board.c b/ports/espressif/boards/espressif_esp32s3_box_lite/board.c index ddfab49797..1917e6df4c 100644 --- a/ports/espressif/boards/espressif_esp32s3_box_lite/board.c +++ b/ports/espressif/boards/espressif_esp32s3_box_lite/board.c @@ -89,12 +89,6 @@ void board_init(void) { false, // backlight_on_high false, // SH1107_addressing 50000); // backlight pwm frequency - - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif } // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s3_box_lite/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32s3_box_lite/mpconfigboard.mk index a4bd29fa52..af4d8840a0 100644 --- a/ports/espressif/boards/espressif_esp32s3_box_lite/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32s3_box_lite/mpconfigboard.mk @@ -5,8 +5,12 @@ USB_MANUFACTURER = "Espressif" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m CIRCUITPY_ESPCAMERA = 0 diff --git a/ports/espressif/boards/espressif_esp32s3_box_lite/sdkconfig b/ports/espressif/boards/espressif_esp32s3_box_lite/sdkconfig index 6884299abe..f5ef797681 100644 --- a/ports/espressif/boards/espressif_esp32s3_box_lite/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s3_box_lite/sdkconfig @@ -1,14 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_MODE_OCT=y -CONFIG_SPIRAM_SPEED_80M=y -CONFIG_SPIRAM_TYPE_AUTO=y - -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_USE_MEMMAP=y - +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/board.c b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/board.c index ff9418ec86..164430c88c 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/board.c +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/board.c @@ -25,24 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} - -bool board_requests_safe_mode(void) { - return false; -} - -void reset_board(void) { - -} - -void board_deinit(void) { -} +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/mpconfigboard.mk index 78423955bb..223c3af6bf 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Espressif" IDF_TARGET = esp32s3 -CIRCUITPY_ESP_FLASH_MODE=dout -CIRCUITPY_ESP_FLASH_FREQ=80m -CIRCUITPY_ESP_FLASH_SIZE=32MB +CIRCUITPY_ESP_FLASH_SIZE = 32MB +CIRCUITPY_ESP_FLASH_MODE = opi +CIRCUITPY_ESP_FLASH_FREQ = 80m + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/sdkconfig b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/sdkconfig index f915462e11..f5ef797681 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n32r8/sdkconfig @@ -1,77 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_MODE_QUAD is not set -CONFIG_SPIRAM_MODE_OCT=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM Clock and CS IO for ESP32S3 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y - -# -# Serial flasher config -# -CONFIG_ESPTOOLPY_BAUD_OTHER_VAL=115200 -# CONFIG_ESPTOOLPY_NO_STUB is not set -CONFIG_ESPTOOLPY_OCT_FLASH=y -CONFIG_ESPTOOLPY_FLASHMODE_OPI=y -# CONFIG_ESPTOOLPY_FLASH_SAMPLE_MODE_STR is not set -CONFIG_ESPTOOLPY_FLASH_SAMPLE_MODE_DTR=y -CONFIG_ESPTOOLPY_FLASHMODE="dout" -CONFIG_ESPTOOLPY_FLASHFREQ_80M=y -# CONFIG_ESPTOOLPY_FLASHFREQ_40M is not set -# CONFIG_ESPTOOLPY_FLASHFREQ_20M is not set -CONFIG_ESPTOOLPY_FLASHFREQ="80m" -# CONFIG_ESPTOOLPY_FLASHSIZE_1MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_2MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_4MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_8MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_16MB is not set -CONFIG_ESPTOOLPY_FLASHSIZE_32MB=y -# CONFIG_ESPTOOLPY_FLASHSIZE_64MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_128MB is not set -CONFIG_ESPTOOLPY_FLASHSIZE="32MB" -CONFIG_ESPTOOLPY_FLASHSIZE_DETECT=y -CONFIG_ESPTOOLPY_BEFORE_RESET=y -# CONFIG_ESPTOOLPY_BEFORE_NORESET is not set -CONFIG_ESPTOOLPY_BEFORE="default_reset" -CONFIG_ESPTOOLPY_AFTER_RESET=y -# CONFIG_ESPTOOLPY_AFTER_NORESET is not set -CONFIG_ESPTOOLPY_AFTER="hard_reset" -# CONFIG_ESPTOOLPY_MONITOR_BAUD_CONSOLE is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_9600B is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_57600B is not set -CONFIG_ESPTOOLPY_MONITOR_BAUD_115200B=y -# CONFIG_ESPTOOLPY_MONITOR_BAUD_230400B is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_921600B is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_2MB is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_OTHER is not set -CONFIG_ESPTOOLPY_MONITOR_BAUD_OTHER_VAL=115200 -CONFIG_ESPTOOLPY_MONITOR_BAUD=115200 -# end of Serial flasher config - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8/board.c b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8/board.c index 3b1f5efd87..164430c88c 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8/board.c +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8/sdkconfig b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8/sdkconfig index a0a61d8392..f5ef797681 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8/sdkconfig @@ -1,6 +1,15 @@ -# CONFIG_ESP32S3_SPIRAM_SUPPORT is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/board.c b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/board.c index 3b1f5efd87..164430c88c 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/board.c +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/mpconfigboard.mk index 7d5afe9a9f..bcc614c500 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Espressif" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 8MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 8MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/sdkconfig b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/sdkconfig index 3e366f0172..f5ef797681 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r2/sdkconfig @@ -1,43 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -45,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/board.c b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/board.c index 3b1f5efd87..164430c88c 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/board.c +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/mpconfigboard.mk index 95fa2d0324..b71b354839 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Espressif" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 8MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 8MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/sdkconfig b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/sdkconfig index f508f4a67c..f5ef797681 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8/sdkconfig @@ -1,34 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_MODE_QUAD is not set -CONFIG_SPIRAM_MODE_OCT=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM Clock and CS IO for ESP32S3 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/board.c b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/board.c new file mode 100644 index 0000000000..3b1f5efd87 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/board.c @@ -0,0 +1,39 @@ +/* + * 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) { + // Debug UART + #ifdef DEBUG + common_hal_never_reset_pin(&pin_GPIO43); + common_hal_never_reset_pin(&pin_GPIO44); + #endif +} + +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/mpconfigboard.h b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/mpconfigboard.h new file mode 100644 index 0000000000..e39cbaad98 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/mpconfigboard.h @@ -0,0 +1,42 @@ +/* + * 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 "ESP32-S3-DevKitC-1-N8R8-with-HACKTABLET" +#define MICROPY_HW_MCU_NAME "ESP32S3" + +#define MICROPY_HW_NEOPIXEL (&pin_GPIO48) + +#define DEFAULT_UART_BUS_RX (&pin_GPIO44) +#define DEFAULT_UART_BUS_TX (&pin_GPIO43) + +// UART pins attached to the USB-serial converter chip +#define CIRCUITPY_CONSOLE_UART_TX (&pin_GPIO43) +#define CIRCUITPY_CONSOLE_UART_RX (&pin_GPIO44) + +// a 800x480 16BPP framebuffer + some breathing room +#define DEFAULT_RESERVED_PSRAM (800 * 800 * 2) diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/mpconfigboard.mk new file mode 100644 index 0000000000..99daa4ab98 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/mpconfigboard.mk @@ -0,0 +1,16 @@ +USB_VID = 0x303A +USB_PID = 0x7003 +USB_PRODUCT = "ESP32-S3-DevKitC-1-N8R8" +USB_MANUFACTURER = "Espressif" + +IDF_TARGET = esp32s3 + +CIRCUITPY_ESP_FLASH_MODE = dio +CIRCUITPY_ESP_FLASH_FREQ = 80m +CIRCUITPY_ESP_FLASH_SIZE = 8MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m + +CIRCUITPY_DOTCLOCKFRAMEBUFFER = 1 diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/pins.c b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/pins.c new file mode 100644 index 0000000000..8f792769e5 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/pins.c @@ -0,0 +1,122 @@ +#include "py/objtuple.h" +#include "shared-bindings/board/__init__.h" + +STATIC const mp_rom_obj_tuple_t tft_r_pins = { + {&mp_type_tuple}, + 5, + { + MP_ROM_PTR(&pin_GPIO14), + MP_ROM_PTR(&pin_GPIO15), + MP_ROM_PTR(&pin_GPIO16), + MP_ROM_PTR(&pin_GPIO17), + MP_ROM_PTR(&pin_GPIO18), + } +}; + +STATIC const mp_rom_obj_tuple_t tft_g_pins = { + {&mp_type_tuple}, + 6, + { + MP_ROM_PTR(&pin_GPIO8), + MP_ROM_PTR(&pin_GPIO9), + MP_ROM_PTR(&pin_GPIO10), + MP_ROM_PTR(&pin_GPIO11), + MP_ROM_PTR(&pin_GPIO12), + MP_ROM_PTR(&pin_GPIO13), + } +}; + +STATIC const mp_rom_obj_tuple_t tft_b_pins = { + {&mp_type_tuple}, + 5, + { + MP_ROM_PTR(&pin_GPIO3), + MP_ROM_PTR(&pin_GPIO4), + MP_ROM_PTR(&pin_GPIO5), + MP_ROM_PTR(&pin_GPIO6), + MP_ROM_PTR(&pin_GPIO7), + } +}; + +STATIC const mp_rom_map_elem_t tft_table[] = { + { MP_ROM_QSTR(MP_QSTR_de), MP_ROM_PTR(&pin_GPIO45) }, + { MP_ROM_QSTR(MP_QSTR_vsync), MP_ROM_PTR(&pin_GPIO48) }, + { MP_ROM_QSTR(MP_QSTR_hsync), MP_ROM_PTR(&pin_GPIO47) }, + { MP_ROM_QSTR(MP_QSTR_dclk), MP_ROM_PTR(&pin_GPIO21) }, + { MP_ROM_QSTR(MP_QSTR_red), MP_ROM_PTR(&tft_r_pins) }, + { MP_ROM_QSTR(MP_QSTR_green), MP_ROM_PTR(&tft_g_pins) }, + { MP_ROM_QSTR(MP_QSTR_blue), MP_ROM_PTR(&tft_b_pins) }, +}; +MP_DEFINE_CONST_DICT(tft_dict, tft_table); + +STATIC const mp_rom_map_elem_t timings800_table[] = { + { MP_ROM_QSTR(MP_QSTR_frequency), MP_ROM_INT(6500000) }, // nominal 16MHz, but display is unstable/tears at that frequency + { MP_ROM_QSTR(MP_QSTR_width), MP_ROM_INT(800) }, + { MP_ROM_QSTR(MP_QSTR_height), MP_ROM_INT(480) }, + { MP_ROM_QSTR(MP_QSTR_hsync_pulse_width), MP_ROM_INT(30) }, + { MP_ROM_QSTR(MP_QSTR_hsync_front_porch), MP_ROM_INT(210) }, + { MP_ROM_QSTR(MP_QSTR_hsync_back_porch), MP_ROM_INT(16) }, + { MP_ROM_QSTR(MP_QSTR_hsync_idle_low), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_vsync_pulse_width), MP_ROM_INT(13) }, + { MP_ROM_QSTR(MP_QSTR_vsync_front_porch), MP_ROM_INT(22) }, + { MP_ROM_QSTR(MP_QSTR_vsync_back_porch), MP_ROM_INT(10) }, + { MP_ROM_QSTR(MP_QSTR_vsync_idle_low), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_de_idle_high), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_pclk_active_high), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_pclk_idle_high), MP_ROM_FALSE }, +}; +MP_DEFINE_CONST_DICT(timings800_dict, timings800_table); + + +STATIC const mp_rom_map_elem_t board_module_globals_table[] = { + CIRCUITPYTHON_BOARD_DICT_STANDARD_ITEMS + + { MP_ROM_QSTR(MP_QSTR_TFT), MP_ROM_PTR(&tft_dict) }, + { MP_ROM_QSTR(MP_QSTR_TIMINGS800), MP_ROM_PTR(&timings800_dict) }, + { MP_ROM_QSTR(MP_QSTR_BACKLIGHT), MP_ROM_PTR(&pin_GPIO39) }, + + { 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_TFTB1), MP_ROM_PTR(&pin_GPIO3) }, + { MP_ROM_QSTR(MP_QSTR_TFTB2), MP_ROM_PTR(&pin_GPIO4) }, + { MP_ROM_QSTR(MP_QSTR_TFTB3), MP_ROM_PTR(&pin_GPIO5) }, + { MP_ROM_QSTR(MP_QSTR_TFTB4), MP_ROM_PTR(&pin_GPIO6) }, + { MP_ROM_QSTR(MP_QSTR_TFTB5), MP_ROM_PTR(&pin_GPIO7) }, + { MP_ROM_QSTR(MP_QSTR_TFTG1), MP_ROM_PTR(&pin_GPIO8) }, + { MP_ROM_QSTR(MP_QSTR_TFTG2), MP_ROM_PTR(&pin_GPIO9) }, + { MP_ROM_QSTR(MP_QSTR_TFTG3), MP_ROM_PTR(&pin_GPIO10) }, + { MP_ROM_QSTR(MP_QSTR_TFTG4), MP_ROM_PTR(&pin_GPIO11) }, + { MP_ROM_QSTR(MP_QSTR_TFTG5), MP_ROM_PTR(&pin_GPIO12) }, + { MP_ROM_QSTR(MP_QSTR_TFTG6), MP_ROM_PTR(&pin_GPIO13) }, + { MP_ROM_QSTR(MP_QSTR_TFTR1), MP_ROM_PTR(&pin_GPIO14) }, + { MP_ROM_QSTR(MP_QSTR_TFTR2), MP_ROM_PTR(&pin_GPIO15) }, + { MP_ROM_QSTR(MP_QSTR_TFTR3), MP_ROM_PTR(&pin_GPIO16) }, + { MP_ROM_QSTR(MP_QSTR_TFTR4), MP_ROM_PTR(&pin_GPIO17) }, + { MP_ROM_QSTR(MP_QSTR_TFTR5), 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_dclk), MP_ROM_PTR(&pin_GPIO21) }, + { MP_ROM_QSTR(MP_QSTR_IO35), MP_ROM_PTR(&pin_GPIO35) }, + { MP_ROM_QSTR(MP_QSTR_IO36), MP_ROM_PTR(&pin_GPIO36) }, + { MP_ROM_QSTR(MP_QSTR_IO37), MP_ROM_PTR(&pin_GPIO37) }, + { MP_ROM_QSTR(MP_QSTR_IO38), MP_ROM_PTR(&pin_GPIO38) }, + { 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_IO43), MP_ROM_PTR(&pin_GPIO43) }, + { MP_ROM_QSTR(MP_QSTR_IO44), MP_ROM_PTR(&pin_GPIO44) }, + { MP_ROM_QSTR(MP_QSTR_de), MP_ROM_PTR(&pin_GPIO45) }, + { MP_ROM_QSTR(MP_QSTR_IO46), MP_ROM_PTR(&pin_GPIO46) }, + { MP_ROM_QSTR(MP_QSTR_hsync), MP_ROM_PTR(&pin_GPIO47) }, + { MP_ROM_QSTR(MP_QSTR_vsync), MP_ROM_PTR(&pin_GPIO48) }, + { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_GPIO48) }, + + { 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_UART), MP_ROM_PTR(&board_uart_obj) }, +}; +MP_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table); diff --git a/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/sdkconfig b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/sdkconfig new file mode 100644 index 0000000000..0452053c1e --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_devkitc_1_n8r8_hacktablet/sdkconfig @@ -0,0 +1,28 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# ESP System Settings +# +CONFIG_ESP_CONSOLE_UART_CUSTOM=y +# CONFIG_ESP_CONSOLE_NONE is not set +CONFIG_ESP_CONSOLE_UART=y +CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y +CONFIG_ESP_CONSOLE_UART_NUM=0 +CONFIG_ESP_CONSOLE_UART_TX_GPIO=43 +CONFIG_ESP_CONSOLE_UART_RX_GPIO=44 +CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 +# end of ESP System Settings + +# +# LWIP +# +CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3-hacktablet" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_devkitm_1_n8/board.c b/ports/espressif/boards/espressif_esp32s3_devkitm_1_n8/board.c index 3b1f5efd87..164430c88c 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitm_1_n8/board.c +++ b/ports/espressif/boards/espressif_esp32s3_devkitm_1_n8/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s3_devkitm_1_n8/sdkconfig b/ports/espressif/boards/espressif_esp32s3_devkitm_1_n8/sdkconfig index a0a61d8392..f5ef797681 100644 --- a/ports/espressif/boards/espressif_esp32s3_devkitm_1_n8/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s3_devkitm_1_n8/sdkconfig @@ -1,6 +1,15 @@ -# CONFIG_ESP32S3_SPIRAM_SUPPORT is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_eye/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32s3_eye/mpconfigboard.mk index 4711f28aaf..0619284e83 100644 --- a/ports/espressif/boards/espressif_esp32s3_eye/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_esp32s3_eye/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Espressif" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 8MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 8MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/espressif_esp32s3_eye/sdkconfig b/ports/espressif/boards/espressif_esp32s3_eye/sdkconfig index 1a24832767..71778c5e6e 100644 --- a/ports/espressif/boards/espressif_esp32s3_eye/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s3_eye/sdkconfig @@ -1,34 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_MODE_QUAD is not set -CONFIG_SPIRAM_MODE_OCT=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM Clock and CS IO for ESP32S3 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3-eye" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_lcd_ev/board.c b/ports/espressif/boards/espressif_esp32s3_lcd_ev/board.c new file mode 100644 index 0000000000..726012d1f7 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_lcd_ev/board.c @@ -0,0 +1,159 @@ +/* + * 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/board/__init__.h" +#include "shared-bindings/busio/I2C.h" +#include "shared-bindings/dotclockframebuffer/DotClockFramebuffer.h" +#include "shared-bindings/dotclockframebuffer/__init__.h" +#include "shared-bindings/framebufferio/FramebufferDisplay.h" +#include "shared-bindings/microcontroller/Pin.h" +#include "shared-module/displayio/__init__.h" +#include "boards/espressif_esp32s3_lcd_ev/board.h" + +#define MP_DEFINE_BYTES_OBJ(obj_name, bin) mp_obj_str_t obj_name = {{&mp_type_bytes}, 0, sizeof(bin) - 1, (const byte *)bin} + +static const uint8_t display_init_sequence[] = { + 0xf0, 5, 0x55, 0xaa, 0x52, 0x08, 0x00, + 0xf6, 2, 0x5a, 0x87, + 0xc1, 1, 0x3f, + 0xc2, 1, 0x0e, + 0xc6, 1, 0xf8, + 0xc9, 1, 0x10, + 0xcd, 1, 0x25, + 0xf8, 1, 0x8a, + 0xac, 1, 0x45, + 0xa0, 1, 0xdd, + 0xa7, 1, 0x47, + 0xfa, 4, 0x00, 0x00, 0x00, 0x04, + 0x86, 4, 0x99, 0xa3, 0xa3, 0x51, + 0xa3, 1, 0xee, + 0xfd, 3, 0x3c, 0x3c, 0x00, + 0x71, 1, 0x48, + 0x72, 1, 0x48, + 0x73, 2, 0x00, 0x44, + 0x97, 1, 0xee, + 0x83, 1, 0x93, + 0x9a, 1, 0x72, + 0x9b, 1, 0x5a, + 0x82, 2, 0x2c, 0x2c, + 0xb1, 1, 0x10, + 0x6d, 32, 0x00, 0x1f, 0x19, 0x1a, 0x10, 0x0e, 0x0c, 0x0a, 0x02, 0x07, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x08, 0x01, 0x09, 0x0b, 0x0d, 0x0f, 0x1a, 0x19, 0x1f, 0x00, + 0x64, 16, 0x38, 0x05, 0x01, 0xdb, 0x03, 0x03, 0x38, 0x04, 0x01, 0xdc, 0x03, 0x03, 0x7a, 0x7a, 0x7a, 0x7a, + 0x65, 16, 0x38, 0x03, 0x01, 0xdd, 0x03, 0x03, 0x38, 0x02, 0x01, 0xde, 0x03, 0x03, 0x7a, 0x7a, 0x7a, 0x7a, + 0x66, 16, 0x38, 0x01, 0x01, 0xdf, 0x03, 0x03, 0x38, 0x00, 0x01, 0xe0, 0x03, 0x03, 0x7a, 0x7a, 0x7a, 0x7a, + 0x67, 16, 0x30, 0x01, 0x01, 0xe1, 0x03, 0x03, 0x30, 0x02, 0x01, 0xe2, 0x03, 0x03, 0x7a, 0x7a, 0x7a, 0x7a, + 0x68, 13, 0x00, 0x08, 0x15, 0x08, 0x15, 0x7a, 0x7a, 0x08, 0x15, 0x08, 0x15, 0x7a, 0x7a, + 0x60, 8, 0x38, 0x08, 0x7a, 0x7a, 0x38, 0x09, 0x7a, 0x7a, + 0x63, 8, 0x31, 0xe4, 0x7a, 0x7a, 0x31, 0xe5, 0x7a, 0x7a, + 0x69, 7, 0x04, 0x22, 0x14, 0x22, 0x14, 0x22, 0x08, + 0x6b, 1, 0x07, + 0x7a, 2, 0x08, 0x13, + 0x7b, 2, 0x08, 0x13, + 0xd1, 52, 0x00, 0x00, 0x00, 0x04, 0x00, 0x12, 0x00, 0x18, 0x00, 0x21, 0x00, 0x2a, 0x00, 0x35, 0x00, 0x47, 0x00, 0x56, 0x00, 0x90, 0x00, 0xe5, 0x01, 0x68, 0x01, 0xd5, 0x01, 0xd7, 0x02, 0x36, 0x02, 0xa6, 0x02, 0xee, 0x03, 0x48, 0x03, 0xa0, 0x03, 0xba, 0x03, 0xc5, 0x03, 0xd0, 0x03, 0xe0, 0x03, 0xea, 0x03, 0xfa, 0x03, 0xff, + 0xd2, 52, 0x00, 0x00, 0x00, 0x04, 0x00, 0x12, 0x00, 0x18, 0x00, 0x21, 0x00, 0x2a, 0x00, 0x35, 0x00, 0x47, 0x00, 0x56, 0x00, 0x90, 0x00, 0xe5, 0x01, 0x68, 0x01, 0xd5, 0x01, 0xd7, 0x02, 0x36, 0x02, 0xa6, 0x02, 0xee, 0x03, 0x48, 0x03, 0xa0, 0x03, 0xba, 0x03, 0xc5, 0x03, 0xd0, 0x03, 0xe0, 0x03, 0xea, 0x03, 0xfa, 0x03, 0xff, + 0xd3, 52, 0x00, 0x00, 0x00, 0x04, 0x00, 0x12, 0x00, 0x18, 0x00, 0x21, 0x00, 0x2a, 0x00, 0x35, 0x00, 0x47, 0x00, 0x56, 0x00, 0x90, 0x00, 0xe5, 0x01, 0x68, 0x01, 0xd5, 0x01, 0xd7, 0x02, 0x36, 0x02, 0xa6, 0x02, 0xee, 0x03, 0x48, 0x03, 0xa0, 0x03, 0xba, 0x03, 0xc5, 0x03, 0xd0, 0x03, 0xe0, 0x03, 0xea, 0x03, 0xfa, 0x03, 0xff, + 0xd4, 52, 0x00, 0x00, 0x00, 0x04, 0x00, 0x12, 0x00, 0x18, 0x00, 0x21, 0x00, 0x2a, 0x00, 0x35, 0x00, 0x47, 0x00, 0x56, 0x00, 0x90, 0x00, 0xe5, 0x01, 0x68, 0x01, 0xd5, 0x01, 0xd7, 0x02, 0x36, 0x02, 0xa6, 0x02, 0xee, 0x03, 0x48, 0x03, 0xa0, 0x03, 0xba, 0x03, 0xc5, 0x03, 0xd0, 0x03, 0xe0, 0x03, 0xea, 0x03, 0xfa, 0x03, 0xff, + 0xd5, 52, 0x00, 0x00, 0x00, 0x04, 0x00, 0x12, 0x00, 0x18, 0x00, 0x21, 0x00, 0x2a, 0x00, 0x35, 0x00, 0x47, 0x00, 0x56, 0x00, 0x90, 0x00, 0xe5, 0x01, 0x68, 0x01, 0xd5, 0x01, 0xd7, 0x02, 0x36, 0x02, 0xa6, 0x02, 0xee, 0x03, 0x48, 0x03, 0xa0, 0x03, 0xba, 0x03, 0xc5, 0x03, 0xd0, 0x03, 0xe0, 0x03, 0xea, 0x03, 0xfa, 0x03, 0xff, + 0xd6, 52, 0x00, 0x00, 0x00, 0x04, 0x00, 0x12, 0x00, 0x18, 0x00, 0x21, 0x00, 0x2a, 0x00, 0x35, 0x00, 0x47, 0x00, 0x56, 0x00, 0x90, 0x00, 0xe5, 0x01, 0x68, 0x01, 0xd5, 0x01, 0xd7, 0x02, 0x36, 0x02, 0xa6, 0x02, 0xee, 0x03, 0x48, 0x03, 0xa0, 0x03, 0xba, 0x03, 0xc5, 0x03, 0xd0, 0x03, 0xe0, 0x03, 0xea, 0x03, 0xfa, 0x03, 0xff, + 0x3a, 1, 0x66, + 0x3a, 1, 0x66, + 0x11, 0x80, 120, + 0x29, 0x0, + 0, // trailing NUL for Python bytes() representation +}; +MP_DEFINE_BYTES_OBJ(display_init_byte_obj, display_init_sequence); + +static const char i2c_bus_init_sequence[] = { + 2, 3, 0xf1, // set GPIO direction + 2, 2, 0, // disable all output inversion + 0, // trailing NUL for Python bytes() representation +}; +MP_DEFINE_BYTES_OBJ(i2c_init_byte_obj, i2c_bus_init_sequence); + +static const mcu_pin_obj_t *red_pins[] = { + &pin_GPIO1, &pin_GPIO2, &pin_GPIO42, &pin_GPIO41, &pin_GPIO40 +}; +static const mcu_pin_obj_t *green_pins[] = { + &pin_GPIO21, &pin_GPIO47, &pin_GPIO48, &pin_GPIO45, &pin_GPIO38, &pin_GPIO39 +}; +static const mcu_pin_obj_t *blue_pins[] = { + &pin_GPIO10, &pin_GPIO11, &pin_GPIO12, &pin_GPIO13, &pin_GPIO14 +}; +void board_init(void) { + dotclockframebuffer_framebuffer_obj_t *framebuffer = &allocate_display_bus_or_raise()->dotclock; + framebuffer->base.type = &dotclockframebuffer_framebuffer_type; + + common_hal_dotclockframebuffer_framebuffer_construct( + framebuffer, + /* de */ &pin_GPIO17, + /* vsync */ &pin_GPIO3, + /* hsync */ &pin_GPIO46, + /* dclk */ &pin_GPIO9, + /* data */ red_pins, MP_ARRAY_SIZE(red_pins), green_pins, MP_ARRAY_SIZE(green_pins), blue_pins, MP_ARRAY_SIZE(blue_pins), + /* frequency */ 12000000, + /* width x height */ 480, 480, + /* horizontal: pulse, back & front porch, idle */ 13, 20, 40, false, + /* vertical: pulse, back & front porch, idle */ 15, 20, 40, false, + /* de_idle_high */ false, + /* pclk_active_high */ true, + /* pclk_idle_high */ false, + /* overscan_left */ 0 + ); + + framebufferio_framebufferdisplay_obj_t *disp = &allocate_display_or_raise()->framebuffer_display; + disp->base.type = &framebufferio_framebufferdisplay_type; + common_hal_framebufferio_framebufferdisplay_construct( + disp, + framebuffer, + 0, + true + ); + + busio_i2c_obj_t i2c; + i2c.base.type = &busio_i2c_type; + common_hal_busio_i2c_construct(&i2c, DEFAULT_I2C_BUS_SCL, DEFAULT_I2C_BUS_SDA, 400000, 255); + const int i2c_device_address = 32; + + dotclockframebuffer_ioexpander_spi_bus spibus = { + .bus = &i2c, + .i2c_device_address = i2c_device_address, + .i2c_write_size = 2, + .addr_reg_shadow = { .u32 = 1 }, // GPIO data at register 1 + .cs_mask = 0x100 << 1, // data payload is at byte 2 + .mosi_mask = 0x100 << 3, + .clk_mask = 0x100 << 2, + }; + + static const mp_buffer_info_t bufinfo_display_init = { (void *)display_init_sequence, sizeof(display_init_sequence) - 1 }; + static const mp_buffer_info_t bufinfo_i2c_bus_init = { (void *)i2c_bus_init_sequence, sizeof(i2c_bus_init_sequence) - 1 }; + dotclockframebuffer_ioexpander_send_init_sequence(&spibus, &bufinfo_i2c_bus_init, &bufinfo_display_init); + + common_hal_busio_i2c_deinit(&i2c); +} + +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_esp32s3_lcd_ev/board.h b/ports/espressif/boards/espressif_esp32s3_lcd_ev/board.h new file mode 100644 index 0000000000..e8f5286542 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_lcd_ev/board.h @@ -0,0 +1,31 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2023 Jeff Epler 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. + */ + +#pragma once + +#include "py/objstr.h" + +extern mp_obj_str_t display_init_byte_obj, i2c_init_byte_obj; diff --git a/ports/espressif/boards/espressif_esp32s3_lcd_ev/mpconfigboard.h b/ports/espressif/boards/espressif_esp32s3_lcd_ev/mpconfigboard.h new file mode 100644 index 0000000000..98b0e04122 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_lcd_ev/mpconfigboard.h @@ -0,0 +1,42 @@ +/* + * 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 "Espressif-ESP32-S3-LCD-EV-Board" +#define MICROPY_HW_MCU_NAME "ESP32S3" + +#define MICROPY_HW_NEOPIXEL (&pin_GPIO4) + +#define DEFAULT_I2C_BUS_SDA (&pin_GPIO8) +#define DEFAULT_I2C_BUS_SCL (&pin_GPIO18) + +// UART pins attached to the USB-serial converter chip +#define CIRCUITPY_CONSOLE_UART_TX (&pin_GPIO43) +#define CIRCUITPY_CONSOLE_UART_RX (&pin_GPIO44) + +// a 1024x768 16BPP framebuffer + some breathing room +#define DEFAULT_RESERVED_PSRAM (1024 * 1024 * 2) diff --git a/ports/espressif/boards/espressif_esp32s3_lcd_ev/mpconfigboard.mk b/ports/espressif/boards/espressif_esp32s3_lcd_ev/mpconfigboard.mk new file mode 100644 index 0000000000..183103f17e --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_lcd_ev/mpconfigboard.mk @@ -0,0 +1,17 @@ +USB_VID = 0x239A +USB_PID = 0x814C +USB_PRODUCT = "ESP32-S3-EV-LCD-Board" +USB_MANUFACTURER = "Espressif" + +IDF_TARGET = esp32s3 + +CIRCUITPY_ESP_FLASH_MODE = dio +CIRCUITPY_ESP_FLASH_FREQ = 80m +CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 120m + +CIRCUITPY_DOTCLOCKFRAMEBUFFER = 1 +UF2_BOOTLOADER = 0 diff --git a/ports/espressif/boards/espressif_esp32s3_lcd_ev/pins.c b/ports/espressif/boards/espressif_esp32s3_lcd_ev/pins.c new file mode 100644 index 0000000000..da25b509a9 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_lcd_ev/pins.c @@ -0,0 +1,110 @@ +#include "py/objtuple.h" +#include "boards/espressif_esp32s3_lcd_ev/board.h" +#include "shared-bindings/board/__init__.h" +#include "shared-module/displayio/__init__.h" + +STATIC const mp_rom_map_elem_t tft_io_expander_table[] = { + { MP_ROM_QSTR(MP_QSTR_i2c_address), MP_ROM_INT(0x20)}, + { MP_ROM_QSTR(MP_QSTR_gpio_address), MP_ROM_INT(1)}, + { MP_ROM_QSTR(MP_QSTR_gpio_data_len), MP_ROM_INT(1)}, + { MP_ROM_QSTR(MP_QSTR_gpio_data), MP_ROM_INT(0xF1)}, + { MP_ROM_QSTR(MP_QSTR_cs_bit), MP_ROM_INT(1)}, + { MP_ROM_QSTR(MP_QSTR_mosi_bit), MP_ROM_INT(3)}, + { MP_ROM_QSTR(MP_QSTR_clk_bit), MP_ROM_INT(2)}, + { MP_ROM_QSTR(MP_QSTR_i2c_init_sequence), &i2c_init_byte_obj}, +}; +MP_DEFINE_CONST_DICT(tft_io_expander_dict, tft_io_expander_table); + +STATIC const mp_rom_obj_tuple_t tft_r_pins = { + {&mp_type_tuple}, + 5, + { + MP_ROM_PTR(&pin_GPIO1), + MP_ROM_PTR(&pin_GPIO2), + MP_ROM_PTR(&pin_GPIO42), + MP_ROM_PTR(&pin_GPIO41), + MP_ROM_PTR(&pin_GPIO40), + } +}; + +STATIC const mp_rom_obj_tuple_t tft_g_pins = { + {&mp_type_tuple}, + 6, + { + MP_ROM_PTR(&pin_GPIO21), + MP_ROM_PTR(&pin_GPIO47), + MP_ROM_PTR(&pin_GPIO48), + MP_ROM_PTR(&pin_GPIO45), + MP_ROM_PTR(&pin_GPIO38), + MP_ROM_PTR(&pin_GPIO39), + } +}; + +STATIC const mp_rom_obj_tuple_t tft_b_pins = { + {&mp_type_tuple}, + 5, + { + MP_ROM_PTR(&pin_GPIO10), + MP_ROM_PTR(&pin_GPIO11), + MP_ROM_PTR(&pin_GPIO12), + MP_ROM_PTR(&pin_GPIO13), + MP_ROM_PTR(&pin_GPIO14), + } +}; + +STATIC const mp_rom_map_elem_t tft_pins_table[] = { + { MP_ROM_QSTR(MP_QSTR_de), MP_ROM_PTR(&pin_GPIO17) }, + { MP_ROM_QSTR(MP_QSTR_vsync), MP_ROM_PTR(&pin_GPIO3) }, + { MP_ROM_QSTR(MP_QSTR_hsync), MP_ROM_PTR(&pin_GPIO46) }, + { MP_ROM_QSTR(MP_QSTR_dclk), MP_ROM_PTR(&pin_GPIO9) }, + { MP_ROM_QSTR(MP_QSTR_red), MP_ROM_PTR(&tft_r_pins) }, + { MP_ROM_QSTR(MP_QSTR_green), MP_ROM_PTR(&tft_g_pins) }, + { MP_ROM_QSTR(MP_QSTR_blue), MP_ROM_PTR(&tft_b_pins) }, +}; +MP_DEFINE_CONST_DICT(tft_pins_dict, tft_pins_table); + +STATIC const mp_rom_map_elem_t tft_timings_table[] = { + { MP_ROM_QSTR(MP_QSTR_frequency), MP_ROM_INT(6500000) }, // nominal 16MHz, but display is unstable/tears at that frequency + { MP_ROM_QSTR(MP_QSTR_width), MP_ROM_INT(480) }, + { MP_ROM_QSTR(MP_QSTR_height), MP_ROM_INT(480) }, + { MP_ROM_QSTR(MP_QSTR_hsync_pulse_width), MP_ROM_INT(13) }, + { MP_ROM_QSTR(MP_QSTR_hsync_front_porch), MP_ROM_INT(20) }, + { MP_ROM_QSTR(MP_QSTR_hsync_back_porch), MP_ROM_INT(40) }, + { MP_ROM_QSTR(MP_QSTR_hsync_idle_low), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_vsync_pulse_width), MP_ROM_INT(15) }, + { MP_ROM_QSTR(MP_QSTR_vsync_front_porch), MP_ROM_INT(20) }, + { MP_ROM_QSTR(MP_QSTR_vsync_back_porch), MP_ROM_INT(40) }, + { MP_ROM_QSTR(MP_QSTR_vsync_idle_low), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_de_idle_high), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_pclk_active_high), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_pclk_idle_high), MP_ROM_FALSE }, +}; +MP_DEFINE_CONST_DICT(tft_timings_dict, tft_timings_table); + +STATIC const mp_rom_map_elem_t board_module_globals_table[] = { + CIRCUITPYTHON_BOARD_DICT_STANDARD_ITEMS + + { MP_ROM_QSTR(MP_QSTR_TFT_PINS), MP_ROM_PTR(&tft_pins_dict) }, + { MP_ROM_QSTR(MP_QSTR_TFT_TIMINGS), MP_ROM_PTR(&tft_timings_dict) }, + { MP_ROM_QSTR(MP_QSTR_TFT_IO_EXPANDER), MP_ROM_PTR(&tft_io_expander_dict) }, + { MP_ROM_QSTR(MP_QSTR_TFT_INIT_SEQUENCE), &display_init_byte_obj}, + + { MP_ROM_QSTR(MP_QSTR_I2S_SCK), MP_ROM_PTR(&pin_GPIO16) }, + { MP_ROM_QSTR(MP_QSTR_I2S_MCLK), MP_ROM_PTR(&pin_GPIO5) }, + { MP_ROM_QSTR(MP_QSTR_I2S_WS), MP_ROM_PTR(&pin_GPIO7) }, + { MP_ROM_QSTR(MP_QSTR_I2S_SDO), MP_ROM_PTR(&pin_GPIO6) }, + + { 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_SCL), MP_ROM_PTR(DEFAULT_I2C_BUS_SCL) }, + { MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(DEFAULT_I2C_BUS_SDA) }, + + { MP_ROM_QSTR(MP_QSTR_DISPLAY), MP_ROM_PTR(&displays[0].display) }, + + // boot mode button can be used in SW as well + { MP_ROM_QSTR(MP_QSTR_BUTTON), MP_ROM_PTR(&pin_GPIO0) }, + + { MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&board_i2c_obj) }, +}; +MP_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table); diff --git a/ports/espressif/boards/espressif_esp32s3_lcd_ev/sdkconfig b/ports/espressif/boards/espressif_esp32s3_lcd_ev/sdkconfig new file mode 100644 index 0000000000..ec582be223 --- /dev/null +++ b/ports/espressif/boards/espressif_esp32s3_lcd_ev/sdkconfig @@ -0,0 +1,28 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# ESP System Settings +# +CONFIG_ESP_CONSOLE_UART_CUSTOM=y +# CONFIG_ESP_CONSOLE_NONE is not set +CONFIG_ESP_CONSOLE_UART=y +CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y +CONFIG_ESP_CONSOLE_UART_NUM=0 +CONFIG_ESP_CONSOLE_UART_TX_GPIO=43 +CONFIG_ESP_CONSOLE_UART_RX_GPIO=44 +CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 +# end of ESP System Settings + +# +# LWIP +# +CONFIG_LWIP_LOCAL_HOSTNAME="circuitpy" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_esp32s3_usb_otg_n8/board.c b/ports/espressif/boards/espressif_esp32s3_usb_otg_n8/board.c index afbb5ae8fb..197dea0a49 100644 --- a/ports/espressif/boards/espressif_esp32s3_usb_otg_n8/board.c +++ b/ports/espressif/boards/espressif_esp32s3_usb_otg_n8/board.c @@ -116,10 +116,6 @@ void board_init(void) { true, // backlight_on_high false, // SH1107_addressing 50000); // backlight pwm frequency - - #if CIRCUITPY_DEBUG - common_hal_never_reset_pin(DEFAULT_UART_BUS_TX); - #endif } bool espressif_board_reset_pin_number(gpio_num_t pin_number) { diff --git a/ports/espressif/boards/espressif_esp32s3_usb_otg_n8/sdkconfig b/ports/espressif/boards/espressif_esp32s3_usb_otg_n8/sdkconfig index a0a61d8392..f5ef797681 100644 --- a/ports/espressif/boards/espressif_esp32s3_usb_otg_n8/sdkconfig +++ b/ports/espressif/boards/espressif_esp32s3_usb_otg_n8/sdkconfig @@ -1,6 +1,15 @@ -# CONFIG_ESP32S3_SPIRAM_SUPPORT is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/espressif_hmi_devkit_1/mpconfigboard.mk b/ports/espressif/boards/espressif_hmi_devkit_1/mpconfigboard.mk index 60ff9fd5a1..7203fe0db2 100644 --- a/ports/espressif/boards/espressif_hmi_devkit_1/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_hmi_devkit_1/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/espressif_hmi_devkit_1/sdkconfig b/ports/espressif/boards/espressif_hmi_devkit_1/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/espressif_hmi_devkit_1/sdkconfig +++ b/ports/espressif/boards/espressif_hmi_devkit_1/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/espressif_kaluga_1.3/board.c b/ports/espressif/boards/espressif_kaluga_1.3/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/espressif_kaluga_1.3/board.c +++ b/ports/espressif/boards/espressif_kaluga_1.3/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_kaluga_1.3/mpconfigboard.mk b/ports/espressif/boards/espressif_kaluga_1.3/mpconfigboard.mk index 23578067ac..c442581bdd 100644 --- a/ports/espressif/boards/espressif_kaluga_1.3/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_kaluga_1.3/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/espressif_kaluga_1.3/sdkconfig b/ports/espressif/boards/espressif_kaluga_1.3/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/espressif_kaluga_1.3/sdkconfig +++ b/ports/espressif/boards/espressif_kaluga_1.3/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/espressif_kaluga_1/board.c b/ports/espressif/boards/espressif_kaluga_1/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/espressif_kaluga_1/board.c +++ b/ports/espressif/boards/espressif_kaluga_1/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_kaluga_1/mpconfigboard.mk b/ports/espressif/boards/espressif_kaluga_1/mpconfigboard.mk index 23578067ac..c442581bdd 100644 --- a/ports/espressif/boards/espressif_kaluga_1/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_kaluga_1/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/espressif_kaluga_1/sdkconfig b/ports/espressif/boards/espressif_kaluga_1/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/espressif_kaluga_1/sdkconfig +++ b/ports/espressif/boards/espressif_kaluga_1/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/espressif_saola_1_wroom/board.c b/ports/espressif/boards/espressif_saola_1_wroom/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/espressif_saola_1_wroom/board.c +++ b/ports/espressif/boards/espressif_saola_1_wroom/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_saola_1_wroom/sdkconfig b/ports/espressif/boards/espressif_saola_1_wroom/sdkconfig index 5b9c86dcc3..e69de29bb2 100644 --- a/ports/espressif/boards/espressif_saola_1_wroom/sdkconfig +++ b/ports/espressif/boards/espressif_saola_1_wroom/sdkconfig @@ -1,6 +0,0 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/espressif_saola_1_wrover/board.c b/ports/espressif/boards/espressif_saola_1_wrover/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/espressif_saola_1_wrover/board.c +++ b/ports/espressif/boards/espressif_saola_1_wrover/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/espressif_saola_1_wrover/mpconfigboard.mk b/ports/espressif/boards/espressif_saola_1_wrover/mpconfigboard.mk index 5156a5b6ce..b1614e6582 100644 --- a/ports/espressif/boards/espressif_saola_1_wrover/mpconfigboard.mk +++ b/ports/espressif/boards/espressif_saola_1_wrover/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/espressif_saola_1_wrover/sdkconfig b/ports/espressif/boards/espressif_saola_1_wrover/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/espressif_saola_1_wrover/sdkconfig +++ b/ports/espressif/boards/espressif_saola_1_wrover/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/franzininho_wifi_wroom/board.c b/ports/espressif/boards/franzininho_wifi_wroom/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/franzininho_wifi_wroom/board.c +++ b/ports/espressif/boards/franzininho_wifi_wroom/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/franzininho_wifi_wroom/sdkconfig b/ports/espressif/boards/franzininho_wifi_wroom/sdkconfig index 5b9c86dcc3..e69de29bb2 100644 --- a/ports/espressif/boards/franzininho_wifi_wroom/sdkconfig +++ b/ports/espressif/boards/franzininho_wifi_wroom/sdkconfig @@ -1,6 +0,0 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/franzininho_wifi_wrover/board.c b/ports/espressif/boards/franzininho_wifi_wrover/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/franzininho_wifi_wrover/board.c +++ b/ports/espressif/boards/franzininho_wifi_wrover/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/franzininho_wifi_wrover/mpconfigboard.mk b/ports/espressif/boards/franzininho_wifi_wrover/mpconfigboard.mk index 2a09bc99eb..a14512cb74 100644 --- a/ports/espressif/boards/franzininho_wifi_wrover/mpconfigboard.mk +++ b/ports/espressif/boards/franzininho_wifi_wrover/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/franzininho_wifi_wrover/sdkconfig b/ports/espressif/boards/franzininho_wifi_wrover/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/franzininho_wifi_wrover/sdkconfig +++ b/ports/espressif/boards/franzininho_wifi_wrover/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/gravitech_cucumber_m/board.c b/ports/espressif/boards/gravitech_cucumber_m/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/gravitech_cucumber_m/board.c +++ b/ports/espressif/boards/gravitech_cucumber_m/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/gravitech_cucumber_m/sdkconfig b/ports/espressif/boards/gravitech_cucumber_m/sdkconfig index 7b07033d7b..ec6db5c72e 100644 --- a/ports/espressif/boards/gravitech_cucumber_m/sdkconfig +++ b/ports/espressif/boards/gravitech_cucumber_m/sdkconfig @@ -1,6 +1,15 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="cucumber_m" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/gravitech_cucumber_ms/board.c b/ports/espressif/boards/gravitech_cucumber_ms/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/gravitech_cucumber_ms/board.c +++ b/ports/espressif/boards/gravitech_cucumber_ms/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/gravitech_cucumber_ms/sdkconfig b/ports/espressif/boards/gravitech_cucumber_ms/sdkconfig index b31dd447e1..f3cc39cc67 100644 --- a/ports/espressif/boards/gravitech_cucumber_ms/sdkconfig +++ b/ports/espressif/boards/gravitech_cucumber_ms/sdkconfig @@ -1,6 +1,15 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="cucumber_ms" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/gravitech_cucumber_r/board.c b/ports/espressif/boards/gravitech_cucumber_r/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/gravitech_cucumber_r/board.c +++ b/ports/espressif/boards/gravitech_cucumber_r/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/gravitech_cucumber_r/mpconfigboard.mk b/ports/espressif/boards/gravitech_cucumber_r/mpconfigboard.mk index d3e40f2df6..88729e7a44 100644 --- a/ports/espressif/boards/gravitech_cucumber_r/mpconfigboard.mk +++ b/ports/espressif/boards/gravitech_cucumber_r/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/gravitech_cucumber_r/sdkconfig b/ports/espressif/boards/gravitech_cucumber_r/sdkconfig index fe0857c4fb..e817a86205 100644 --- a/ports/espressif/boards/gravitech_cucumber_r/sdkconfig +++ b/ports/espressif/boards/gravitech_cucumber_r/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="cucumber_r" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/gravitech_cucumber_rs/board.c b/ports/espressif/boards/gravitech_cucumber_rs/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/gravitech_cucumber_rs/board.c +++ b/ports/espressif/boards/gravitech_cucumber_rs/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/gravitech_cucumber_rs/mpconfigboard.mk b/ports/espressif/boards/gravitech_cucumber_rs/mpconfigboard.mk index e0b3f35d44..9ef503886d 100644 --- a/ports/espressif/boards/gravitech_cucumber_rs/mpconfigboard.mk +++ b/ports/espressif/boards/gravitech_cucumber_rs/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/gravitech_cucumber_rs/sdkconfig b/ports/espressif/boards/gravitech_cucumber_rs/sdkconfig index 23b3eea78d..873eb7207a 100644 --- a/ports/espressif/boards/gravitech_cucumber_rs/sdkconfig +++ b/ports/espressif/boards/gravitech_cucumber_rs/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="cucumber_rs" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/hardkernel_odroid_go/mpconfigboard.mk b/ports/espressif/boards/hardkernel_odroid_go/mpconfigboard.mk index ead48189fa..83fc7650fd 100644 --- a/ports/espressif/boards/hardkernel_odroid_go/mpconfigboard.mk +++ b/ports/espressif/boards/hardkernel_odroid_go/mpconfigboard.mk @@ -3,6 +3,10 @@ CIRCUITPY_CREATION_ID = 0x00320060 IDF_TARGET = esp32 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 4MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/hardkernel_odroid_go/sdkconfig b/ports/espressif/boards/hardkernel_odroid_go/sdkconfig index f4fea0c732..e69de29bb2 100644 --- a/ports/espressif/boards/hardkernel_odroid_go/sdkconfig +++ b/ports/espressif/boards/hardkernel_odroid_go/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32_SPIRAM_SUPPORT=y -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM32=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=4194304 -CONFIG_SPIRAM_SPEED_40M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_IGNORE_NOTFOUND=y -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# CONFIG_SPIRAM_ALLOW_NOINIT_SEG_EXTERNAL_MEMORY is not set -CONFIG_SPIRAM_CACHE_WORKAROUND=y - -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### # CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### nCONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=12 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=15 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings diff --git a/ports/espressif/boards/hexky_s2/mpconfigboard.mk b/ports/espressif/boards/hexky_s2/mpconfigboard.mk index 043dec5824..fa7ae64a24 100644 --- a/ports/espressif/boards/hexky_s2/mpconfigboard.mk +++ b/ports/espressif/boards/hexky_s2/mpconfigboard.mk @@ -11,3 +11,7 @@ CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/hexky_s2/sdkconfig b/ports/espressif/boards/hexky_s2/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/hexky_s2/sdkconfig +++ b/ports/espressif/boards/hexky_s2/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/hiibot_iots2/board.c b/ports/espressif/boards/hiibot_iots2/board.c index 87ee7d0b14..8524c80202 100644 --- a/ports/espressif/boards/hiibot_iots2/board.c +++ b/ports/espressif/boards/hiibot_iots2/board.c @@ -126,25 +126,6 @@ static void display_init(void) { } 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 - - // SPI Flash and RAM - common_hal_never_reset_pin(&pin_GPIO26); - common_hal_never_reset_pin(&pin_GPIO27); - common_hal_never_reset_pin(&pin_GPIO28); - common_hal_never_reset_pin(&pin_GPIO29); - common_hal_never_reset_pin(&pin_GPIO30); - common_hal_never_reset_pin(&pin_GPIO31); - common_hal_never_reset_pin(&pin_GPIO32); - // Display display_init(); } diff --git a/ports/espressif/boards/hiibot_iots2/mpconfigboard.mk b/ports/espressif/boards/hiibot_iots2/mpconfigboard.mk index a60d894665..84a49c256f 100644 --- a/ports/espressif/boards/hiibot_iots2/mpconfigboard.mk +++ b/ports/espressif/boards/hiibot_iots2/mpconfigboard.mk @@ -9,3 +9,7 @@ CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 8MB #CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/hiibot_iots2/sdkconfig b/ports/espressif/boards/hiibot_iots2/sdkconfig index 5ef7020a72..b2b83eb6e6 100644 --- a/ports/espressif/boards/hiibot_iots2/sdkconfig +++ b/ports/espressif/boards/hiibot_iots2/sdkconfig @@ -1,40 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y - # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32=y -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# CONFIG_SPIRAM_SIZE=2097152 - # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# end of SPI RAM config - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="HiiBot_IoTs2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lilygo_tembed_esp32s3/board.c b/ports/espressif/boards/lilygo_tembed_esp32s3/board.c index 03a86a48d4..ee48d50288 100644 --- a/ports/espressif/boards/lilygo_tembed_esp32s3/board.c +++ b/ports/espressif/boards/lilygo_tembed_esp32s3/board.c @@ -88,12 +88,6 @@ void board_init(void) { true, // backlight_on_high false, // SH1107_addressing 50000); // backlight pwm frequency - - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif } // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/lilygo_tembed_esp32s3/mpconfigboard.mk b/ports/espressif/boards/lilygo_tembed_esp32s3/mpconfigboard.mk index 2b8f67b560..bb7847cf27 100644 --- a/ports/espressif/boards/lilygo_tembed_esp32s3/mpconfigboard.mk +++ b/ports/espressif/boards/lilygo_tembed_esp32s3/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "LILYGO" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/lilygo_tembed_esp32s3/sdkconfig b/ports/espressif/boards/lilygo_tembed_esp32s3/sdkconfig index f508f4a67c..f5ef797681 100644 --- a/ports/espressif/boards/lilygo_tembed_esp32s3/sdkconfig +++ b/ports/espressif/boards/lilygo_tembed_esp32s3/sdkconfig @@ -1,34 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_MODE_QUAD is not set -CONFIG_SPIRAM_MODE_OCT=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM Clock and CS IO for ESP32S3 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lilygo_ttgo_t-01c3/board.c b/ports/espressif/boards/lilygo_ttgo_t-01c3/board.c index 67b05e5cd2..e8fec80c7c 100644 --- a/ports/espressif/boards/lilygo_ttgo_t-01c3/board.c +++ b/ports/espressif/boards/lilygo_ttgo_t-01c3/board.c @@ -1,14 +1,3 @@ -#include "shared-bindings/microcontroller/Pin.h" #include "supervisor/board.h" -#include "components/driver/include/driver/gpio.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO20); - common_hal_never_reset_pin(&pin_GPIO21); - #endif -} - // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/lilygo_ttgo_t-01c3/mpconfigboard.mk b/ports/espressif/boards/lilygo_ttgo_t-01c3/mpconfigboard.mk index 2ca19f332c..de5601680c 100644 --- a/ports/espressif/boards/lilygo_ttgo_t-01c3/mpconfigboard.mk +++ b/ports/espressif/boards/lilygo_ttgo_t-01c3/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 0 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/lilygo_ttgo_t-01c3/sdkconfig b/ports/espressif/boards/lilygo_ttgo_t-01c3/sdkconfig index 9d906d3c3b..54105bd51b 100644 --- a/ports/espressif/boards/lilygo_ttgo_t-01c3/sdkconfig +++ b/ports/espressif/boards/lilygo_ttgo_t-01c3/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="LILYGO TTGO T-01C3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lilygo_ttgo_t-oi-plus/board.c b/ports/espressif/boards/lilygo_ttgo_t-oi-plus/board.c index 7bcdcdba25..164430c88c 100644 --- a/ports/espressif/boards/lilygo_ttgo_t-oi-plus/board.c +++ b/ports/espressif/boards/lilygo_ttgo_t-oi-plus/board.c @@ -24,17 +24,6 @@ * THE SOFTWARE. */ -#include "shared-bindings/microcontroller/Pin.h" #include "supervisor/board.h" -#include "components/driver/include/driver/gpio.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO20); - common_hal_never_reset_pin(&pin_GPIO21); - #endif -} - // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/lilygo_ttgo_t-oi-plus/mpconfigboard.mk b/ports/espressif/boards/lilygo_ttgo_t-oi-plus/mpconfigboard.mk index 7a80145217..ede6428e8b 100644 --- a/ports/espressif/boards/lilygo_ttgo_t-oi-plus/mpconfigboard.mk +++ b/ports/espressif/boards/lilygo_ttgo_t-oi-plus/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 0 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/lilygo_ttgo_t-oi-plus/sdkconfig b/ports/espressif/boards/lilygo_ttgo_t-oi-plus/sdkconfig index 7c85db8776..fc0f5c6edd 100644 --- a/ports/espressif/boards/lilygo_ttgo_t-oi-plus/sdkconfig +++ b/ports/espressif/boards/lilygo_ttgo_t-oi-plus/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="LILYGO TTGO T-OI PLUS" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lilygo_ttgo_t8_esp32_s2_wroom/board.c b/ports/espressif/boards/lilygo_ttgo_t8_esp32_s2_wroom/board.c index 6597b51c5f..76973aee30 100644 --- a/ports/espressif/boards/lilygo_ttgo_t8_esp32_s2_wroom/board.c +++ b/ports/espressif/boards/lilygo_ttgo_t8_esp32_s2_wroom/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/lilygo_ttgo_t8_esp32_s2_wroom/sdkconfig b/ports/espressif/boards/lilygo_ttgo_t8_esp32_s2_wroom/sdkconfig index 5b9c86dcc3..e69de29bb2 100644 --- a/ports/espressif/boards/lilygo_ttgo_t8_esp32_s2_wroom/sdkconfig +++ b/ports/espressif/boards/lilygo_ttgo_t8_esp32_s2_wroom/sdkconfig @@ -1,6 +0,0 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/lilygo_ttgo_t8_s2/board.c b/ports/espressif/boards/lilygo_ttgo_t8_s2/board.c index 6597b51c5f..76973aee30 100644 --- a/ports/espressif/boards/lilygo_ttgo_t8_s2/board.c +++ b/ports/espressif/boards/lilygo_ttgo_t8_s2/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/lilygo_ttgo_t8_s2/mpconfigboard.mk b/ports/espressif/boards/lilygo_ttgo_t8_s2/mpconfigboard.mk index e7d70c671a..2af499b5c6 100644 --- a/ports/espressif/boards/lilygo_ttgo_t8_s2/mpconfigboard.mk +++ b/ports/espressif/boards/lilygo_ttgo_t8_s2/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "LILYGO" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/lilygo_ttgo_t8_s2/sdkconfig b/ports/espressif/boards/lilygo_ttgo_t8_s2/sdkconfig index 8c401a6ff3..23f6593f1b 100644 --- a/ports/espressif/boards/lilygo_ttgo_t8_s2/sdkconfig +++ b/ports/espressif/boards/lilygo_ttgo_t8_s2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="TTGO-T8-ESP32-S2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/board.c b/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/board.c index 7ba109dfce..f6ac6ede2d 100644 --- a/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/board.c +++ b/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/board.c @@ -126,12 +126,6 @@ static void display_init(void) { } void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ - // Display display_init(); } diff --git a/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.mk b/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.mk index 865dbe2661..052c1e5417 100644 --- a/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.mk +++ b/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "LILYGO" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/sdkconfig b/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/sdkconfig index 8c401a6ff3..23f6593f1b 100644 --- a/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/sdkconfig +++ b/ports/espressif/boards/lilygo_ttgo_t8_s2_st7789/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="TTGO-T8-ESP32-S2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lilygo_ttgo_tdisplay_esp32_16m/sdkconfig b/ports/espressif/boards/lilygo_ttgo_tdisplay_esp32_16m/sdkconfig index 55052e98ca..61beea449b 100644 --- a/ports/espressif/boards/lilygo_ttgo_tdisplay_esp32_16m/sdkconfig +++ b/ports/espressif/boards/lilygo_ttgo_tdisplay_esp32_16m/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="TTGO-TDISPLAY" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lilygo_twatch_2020_v3/mpconfigboard.mk b/ports/espressif/boards/lilygo_twatch_2020_v3/mpconfigboard.mk index 9d6c8dc25b..f881eddc13 100644 --- a/ports/espressif/boards/lilygo_twatch_2020_v3/mpconfigboard.mk +++ b/ports/espressif/boards/lilygo_twatch_2020_v3/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/lilygo_twatch_2020_v3/sdkconfig b/ports/espressif/boards/lilygo_twatch_2020_v3/sdkconfig index 89647ab5a1..d1e302072a 100644 --- a/ports/espressif/boards/lilygo_twatch_2020_v3/sdkconfig +++ b/ports/espressif/boards/lilygo_twatch_2020_v3/sdkconfig @@ -1,31 +1,22 @@ -# SPI RAM config # -CONFIG_ESP32_SPIRAM_SUPPORT=y -CONFIG_SPIRAM_MODE_OCT=y -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -CONFIG_SPIRAM_SPEED_80M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND=y -CONFIG_SPIRAM_USE_MEMMAP=y -CONFIG_SPIRAM_MEMTEST=y -CONFIG_SPIRAM_CACHE_WORKAROUND=y - -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # ESP System Settings # -CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -# CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set CONFIG_ESP_CONSOLE_UART_CUSTOM=y # CONFIG_ESP_CONSOLE_NONE is not set CONFIG_ESP_CONSOLE_UART=y CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -# CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set CONFIG_ESP_CONSOLE_UART_NUM=0 CONFIG_ESP_CONSOLE_UART_TX_GPIO=1 CONFIG_ESP_CONSOLE_UART_RX_GPIO=3 CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -# CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set # end of ESP System Settings + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lolin_c3_mini/mpconfigboard.h b/ports/espressif/boards/lolin_c3_mini/mpconfigboard.h index 2a90d91845..315384627b 100644 --- a/ports/espressif/boards/lolin_c3_mini/mpconfigboard.h +++ b/ports/espressif/boards/lolin_c3_mini/mpconfigboard.h @@ -44,5 +44,3 @@ #define CIRCUITPY_BOARD_UART (1) #define CIRCUITPY_BOARD_UART_PIN {{.tx = &pin_GPIO21, .rx = &pin_GPIO20}} - -#define CIRCUITPY_ESP_USB_SERIAL_JTAG (1) diff --git a/ports/espressif/boards/lolin_c3_mini/mpconfigboard.mk b/ports/espressif/boards/lolin_c3_mini/mpconfigboard.mk index d1cd0129fd..b6dea28098 100644 --- a/ports/espressif/boards/lolin_c3_mini/mpconfigboard.mk +++ b/ports/espressif/boards/lolin_c3_mini/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE=qio CIRCUITPY_ESP_FLASH_FREQ=80m CIRCUITPY_ESP_FLASH_SIZE=4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 1 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/lolin_c3_mini/sdkconfig b/ports/espressif/boards/lolin_c3_mini/sdkconfig index 833f8368fa..932a4a2cbd 100644 --- a/ports/espressif/boards/lolin_c3_mini/sdkconfig +++ b/ports/espressif/boards/lolin_c3_mini/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="lolin-c3-mini" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lolin_c3_pico/mpconfigboard.h b/ports/espressif/boards/lolin_c3_pico/mpconfigboard.h index 3e68e6adf9..ce0643e787 100644 --- a/ports/espressif/boards/lolin_c3_pico/mpconfigboard.h +++ b/ports/espressif/boards/lolin_c3_pico/mpconfigboard.h @@ -44,5 +44,3 @@ #define CIRCUITPY_BOARD_UART (1) #define CIRCUITPY_BOARD_UART_PIN {{.tx = &pin_GPIO21, .rx = &pin_GPIO20}} - -#define CIRCUITPY_ESP_USB_SERIAL_JTAG (1) diff --git a/ports/espressif/boards/lolin_c3_pico/mpconfigboard.mk b/ports/espressif/boards/lolin_c3_pico/mpconfigboard.mk index a202fd8ad3..56c03ddf68 100644 --- a/ports/espressif/boards/lolin_c3_pico/mpconfigboard.mk +++ b/ports/espressif/boards/lolin_c3_pico/mpconfigboard.mk @@ -7,5 +7,9 @@ CIRCUITPY_ESP_FLASH_MODE=qio CIRCUITPY_ESP_FLASH_FREQ=80m CIRCUITPY_ESP_FLASH_SIZE=4MB +CIRCUITPY_ESP_USB_SERIAL_JTAG = 1 + +CIRCUITPY_BLEIO = 0 + # Include these Python libraries in firmware. FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/espressif/boards/lolin_c3_pico/sdkconfig b/ports/espressif/boards/lolin_c3_pico/sdkconfig index b801dac1e2..00134fd0f2 100644 --- a/ports/espressif/boards/lolin_c3_pico/sdkconfig +++ b/ports/espressif/boards/lolin_c3_pico/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="lolin-c3-pico" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lolin_s2_mini/board.c b/ports/espressif/boards/lolin_s2_mini/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/lolin_s2_mini/board.c +++ b/ports/espressif/boards/lolin_s2_mini/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/lolin_s2_mini/mpconfigboard.mk b/ports/espressif/boards/lolin_s2_mini/mpconfigboard.mk index 24f88d9abf..a1b5333cf0 100644 --- a/ports/espressif/boards/lolin_s2_mini/mpconfigboard.mk +++ b/ports/espressif/boards/lolin_s2_mini/mpconfigboard.mk @@ -5,10 +5,13 @@ USB_MANUFACTURER = "Lolin" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 4MB +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m # Include these Python libraries in firmware. FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/espressif/boards/lolin_s2_mini/sdkconfig b/ports/espressif/boards/lolin_s2_mini/sdkconfig index deb0dadcb9..ac239ca333 100644 --- a/ports/espressif/boards/lolin_s2_mini/sdkconfig +++ b/ports/espressif/boards/lolin_s2_mini/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="LS2Mini" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lolin_s2_pico/board.c b/ports/espressif/boards/lolin_s2_pico/board.c index 2f987799ad..dfac8d0f57 100644 --- a/ports/espressif/boards/lolin_s2_pico/board.c +++ b/ports/espressif/boards/lolin_s2_pico/board.c @@ -97,11 +97,6 @@ static void display_init(void) { void board_init(void) { // init display display_init(); - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ } // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/lolin_s2_pico/mpconfigboard.mk b/ports/espressif/boards/lolin_s2_pico/mpconfigboard.mk index bf946a483f..830c39e691 100644 --- a/ports/espressif/boards/lolin_s2_pico/mpconfigboard.mk +++ b/ports/espressif/boards/lolin_s2_pico/mpconfigboard.mk @@ -5,10 +5,13 @@ USB_MANUFACTURER = "Lolin" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 4MB +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m # Include these Python libraries in firmware. FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/espressif/boards/lolin_s2_pico/sdkconfig b/ports/espressif/boards/lolin_s2_pico/sdkconfig index 5ce352a98d..c2238c6814 100644 --- a/ports/espressif/boards/lolin_s2_pico/sdkconfig +++ b/ports/espressif/boards/lolin_s2_pico/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="Lolin-S2Pico" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lolin_s3/mpconfigboard.mk b/ports/espressif/boards/lolin_s3/mpconfigboard.mk index 56b42a419c..fce42cef8d 100644 --- a/ports/espressif/boards/lolin_s3/mpconfigboard.mk +++ b/ports/espressif/boards/lolin_s3/mpconfigboard.mk @@ -5,8 +5,13 @@ USB_MANUFACTURER = "WEMOS" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 16MB +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m + +OPTIMIZATION_FLAGS = -Os CIRCUITPY_ESPCAMERA = 0 diff --git a/ports/espressif/boards/lolin_s3/sdkconfig b/ports/espressif/boards/lolin_s3/sdkconfig index 23d005edd9..b90e3fa57e 100644 --- a/ports/espressif/boards/lolin_s3/sdkconfig +++ b/ports/espressif/boards/lolin_s3/sdkconfig @@ -1,44 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=8388608 -# -# PSRAM Clock and CS IO for ESP32S3 -# -# CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -CONFIG_SPIRAM_MODE_OCT=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -46,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="LOLIN-S3" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/lolin_s3_mini/board.c b/ports/espressif/boards/lolin_s3_mini/board.c index 9731a30366..00ae21ace8 100644 --- a/ports/espressif/boards/lolin_s3_mini/board.c +++ b/ports/espressif/boards/lolin_s3_mini/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/lolin_s3_mini/mpconfigboard.mk b/ports/espressif/boards/lolin_s3_mini/mpconfigboard.mk index 2a02d7f231..2bd303adb3 100644 --- a/ports/espressif/boards/lolin_s3_mini/mpconfigboard.mk +++ b/ports/espressif/boards/lolin_s3_mini/mpconfigboard.mk @@ -9,7 +9,11 @@ CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB -# OPTIMIZATION_FLAGS = -Os +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m + +OPTIMIZATION_FLAGS = -Os CIRCUITPY_ESPCAMERA = 0 # Include these Python libraries in firmware. diff --git a/ports/espressif/boards/lolin_s3_mini/sdkconfig b/ports/espressif/boards/lolin_s3_mini/sdkconfig index c9fa5f3e51..36be9c760e 100644 --- a/ports/espressif/boards/lolin_s3_mini/sdkconfig +++ b/ports/espressif/boards/lolin_s3_mini/sdkconfig @@ -1,44 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -# CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -# CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_MODE_OCT=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -46,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="LOLIN-S3-MINI" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/luatos_core_esp32c3/mpconfigboard.h b/ports/espressif/boards/luatos_core_esp32c3/mpconfigboard.h index 23bb5ee9b2..6d33513e3c 100644 --- a/ports/espressif/boards/luatos_core_esp32c3/mpconfigboard.h +++ b/ports/espressif/boards/luatos_core_esp32c3/mpconfigboard.h @@ -34,5 +34,3 @@ #define CIRCUITPY_BOARD_UART (1) #define CIRCUITPY_BOARD_UART_PIN {{.tx = &pin_GPIO21, .rx = &pin_GPIO20}} - -#define CIRCUITPY_ESP_USB_SERIAL_JTAG (1) diff --git a/ports/espressif/boards/luatos_core_esp32c3/mpconfigboard.mk b/ports/espressif/boards/luatos_core_esp32c3/mpconfigboard.mk index e0df58f756..dfd8ff63de 100644 --- a/ports/espressif/boards/luatos_core_esp32c3/mpconfigboard.mk +++ b/ports/espressif/boards/luatos_core_esp32c3/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE=dio CIRCUITPY_ESP_FLASH_FREQ=80m CIRCUITPY_ESP_FLASH_SIZE=4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 1 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/luatos_core_esp32c3/sdkconfig b/ports/espressif/boards/luatos_core_esp32c3/sdkconfig index ccc70917b5..7d94db0b5b 100644 --- a/ports/espressif/boards/luatos_core_esp32c3/sdkconfig +++ b/ports/espressif/boards/luatos_core_esp32c3/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="luatos-core-esp32c3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/luatos_core_esp32c3_ch343/mpconfigboard.mk b/ports/espressif/boards/luatos_core_esp32c3_ch343/mpconfigboard.mk index 6a19c783f1..8a425a75cb 100644 --- a/ports/espressif/boards/luatos_core_esp32c3_ch343/mpconfigboard.mk +++ b/ports/espressif/boards/luatos_core_esp32c3_ch343/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE=dio CIRCUITPY_ESP_FLASH_FREQ=80m CIRCUITPY_ESP_FLASH_SIZE=4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 0 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/luatos_core_esp32c3_ch343/sdkconfig b/ports/espressif/boards/luatos_core_esp32c3_ch343/sdkconfig index ccc70917b5..7d94db0b5b 100644 --- a/ports/espressif/boards/luatos_core_esp32c3_ch343/sdkconfig +++ b/ports/espressif/boards/luatos_core_esp32c3_ch343/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="luatos-core-esp32c3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_atom_echo/sdkconfig b/ports/espressif/boards/m5stack_atom_echo/sdkconfig index 3879222bab..861e4ebad3 100644 --- a/ports/espressif/boards/m5stack_atom_echo/sdkconfig +++ b/ports/espressif/boards/m5stack_atom_echo/sdkconfig @@ -1,26 +1,15 @@ -CONFIG_ESP32_SPIRAM_SUPPORT=n - -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="M5StaskAtomEcho" # end of LWIP -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_atom_lite/sdkconfig b/ports/espressif/boards/m5stack_atom_lite/sdkconfig index 8a9fb07019..eaaf716a15 100644 --- a/ports/espressif/boards/m5stack_atom_lite/sdkconfig +++ b/ports/espressif/boards/m5stack_atom_lite/sdkconfig @@ -1,27 +1,15 @@ -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y -CONFIG_ESP32_SPIRAM_SUPPORT=n - -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="M5StaskAtomLite" # end of LWIP -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_atom_matrix/sdkconfig b/ports/espressif/boards/m5stack_atom_matrix/sdkconfig index 474a760b56..730f17de0e 100644 --- a/ports/espressif/boards/m5stack_atom_matrix/sdkconfig +++ b/ports/espressif/boards/m5stack_atom_matrix/sdkconfig @@ -1,26 +1,15 @@ -CONFIG_ESP32_SPIRAM_SUPPORT=n - -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="M5StaskAtomMatrix" # end of LWIP -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_atom_u/sdkconfig b/ports/espressif/boards/m5stack_atom_u/sdkconfig index 90c99459a8..06d0f01693 100644 --- a/ports/espressif/boards/m5stack_atom_u/sdkconfig +++ b/ports/espressif/boards/m5stack_atom_u/sdkconfig @@ -1,26 +1,15 @@ -CONFIG_ESP32_SPIRAM_SUPPORT=n - -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="M5StaskAtomU" # end of LWIP -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_atoms3_lite/sdkconfig b/ports/espressif/boards/m5stack_atoms3_lite/sdkconfig index 9d924272ec..f5ef797681 100644 --- a/ports/espressif/boards/m5stack_atoms3_lite/sdkconfig +++ b/ports/espressif/boards/m5stack_atoms3_lite/sdkconfig @@ -1,7 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=n - +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_atoms3u/board.c b/ports/espressif/boards/m5stack_atoms3u/board.c new file mode 100644 index 0000000000..164430c88c --- /dev/null +++ b/ports/espressif/boards/m5stack_atoms3u/board.c @@ -0,0 +1,29 @@ +/* + * 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" + +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/m5stack_atoms3u/mpconfigboard.h b/ports/espressif/boards/m5stack_atoms3u/mpconfigboard.h new file mode 100644 index 0000000000..1c3376cee4 --- /dev/null +++ b/ports/espressif/boards/m5stack_atoms3u/mpconfigboard.h @@ -0,0 +1,35 @@ +/* + * 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 "M5Stack AtomS3U" +#define MICROPY_HW_MCU_NAME "ESP32S3" + +#define MICROPY_HW_NEOPIXEL (&pin_GPIO35) + +#define CIRCUITPY_BOARD_I2C (1) +#define CIRCUITPY_BOARD_I2C_PIN {{.scl = &pin_GPIO1, .sda = &pin_GPIO2}} diff --git a/ports/espressif/boards/m5stack_atoms3u/mpconfigboard.mk b/ports/espressif/boards/m5stack_atoms3u/mpconfigboard.mk new file mode 100644 index 0000000000..dc65fefc4b --- /dev/null +++ b/ports/espressif/boards/m5stack_atoms3u/mpconfigboard.mk @@ -0,0 +1,11 @@ +USB_VID = 0x303A +USB_PID = 0x8187 +USB_PRODUCT = "M5Stack AtomS3U" +USB_MANUFACTURER = "M5Stack" + +IDF_TARGET = esp32s3 + +CIRCUITPY_ESP_FLASH_MODE = qio +CIRCUITPY_ESP_FLASH_FREQ = 80m +CIRCUITPY_ESP_FLASH_SIZE = 8MB +CIRCUITPY_ESPCAMERA = 0 diff --git a/ports/espressif/boards/m5stack_atoms3u/pins.c b/ports/espressif/boards/m5stack_atoms3u/pins.c new file mode 100644 index 0000000000..716efa593b --- /dev/null +++ b/ports/espressif/boards/m5stack_atoms3u/pins.c @@ -0,0 +1,38 @@ +#include "shared-bindings/board/__init__.h" + +STATIC const mp_rom_map_elem_t board_module_globals_table[] = { + CIRCUITPYTHON_BOARD_DICT_STANDARD_ITEMS + + { MP_ROM_QSTR(MP_QSTR_PORTA_SCL), MP_ROM_PTR(&pin_GPIO1) }, + { MP_ROM_QSTR(MP_QSTR_A1), MP_ROM_PTR(&pin_GPIO1) }, + { MP_ROM_QSTR(MP_QSTR_D1), MP_ROM_PTR(&pin_GPIO1) }, + + { MP_ROM_QSTR(MP_QSTR_PORTA_SCL), MP_ROM_PTR(&pin_GPIO2) }, + { MP_ROM_QSTR(MP_QSTR_A2), MP_ROM_PTR(&pin_GPIO2) }, + { MP_ROM_QSTR(MP_QSTR_D2), MP_ROM_PTR(&pin_GPIO2) }, + + { MP_ROM_QSTR(MP_QSTR_A14), MP_ROM_PTR(&pin_GPIO14) }, + { MP_ROM_QSTR(MP_QSTR_D14), MP_ROM_PTR(&pin_GPIO14) }, + + { MP_ROM_QSTR(MP_QSTR_A17), MP_ROM_PTR(&pin_GPIO17) }, + { MP_ROM_QSTR(MP_QSTR_D17), MP_ROM_PTR(&pin_GPIO17) }, + + { MP_ROM_QSTR(MP_QSTR_D40), MP_ROM_PTR(&pin_GPIO40) }, + + { MP_ROM_QSTR(MP_QSTR_D42), MP_ROM_PTR(&pin_GPIO42) }, + + + { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_GPIO35) }, + + { MP_ROM_QSTR(MP_QSTR_BTN), MP_ROM_PTR(&pin_GPIO41) }, + + { MP_ROM_QSTR(MP_QSTR_IR_LED), MP_ROM_PTR(&pin_GPIO12) }, + + { MP_ROM_QSTR(MP_QSTR_PDM_MIC_CLK), MP_ROM_PTR(&pin_GPIO38) }, + + { MP_ROM_QSTR(MP_QSTR_PDM_MIC_DATA), MP_ROM_PTR(&pin_GPIO39) }, + + { MP_ROM_QSTR(MP_QSTR_PORTA_I2C), MP_ROM_PTR(&board_i2c_obj) }, +}; + +MP_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table); diff --git a/ports/espressif/boards/m5stack_atoms3u/sdkconfig b/ports/espressif/boards/m5stack_atoms3u/sdkconfig new file mode 100644 index 0000000000..f5ef797681 --- /dev/null +++ b/ports/espressif/boards/m5stack_atoms3u/sdkconfig @@ -0,0 +1,15 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# LWIP +# +CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_core2/board.c b/ports/espressif/boards/m5stack_core2/board.c index e64ac35a7d..29011638b2 100644 --- a/ports/espressif/boards/m5stack_core2/board.c +++ b/ports/espressif/boards/m5stack_core2/board.c @@ -34,7 +34,7 @@ #include "shared-bindings/board/__init__.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/m5stack_core2/mpconfigboard.mk b/ports/espressif/boards/m5stack_core2/mpconfigboard.mk index 74ed5bcb83..c8954579ee 100644 --- a/ports/espressif/boards/m5stack_core2/mpconfigboard.mk +++ b/ports/espressif/boards/m5stack_core2/mpconfigboard.mk @@ -7,6 +7,10 @@ CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 16MB +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m + M5STACK_CORE2_5V_OUTPUT_ENABLE_DEFAULT = 1 CFLAGS += -DM5STACK_CORE2_5V_OUTPUT_ENABLE_DEFAULT=$(M5STACK_CORE2_5V_OUTPUT_ENABLE_DEFAULT) diff --git a/ports/espressif/boards/m5stack_core2/sdkconfig b/ports/espressif/boards/m5stack_core2/sdkconfig index 47a0a18a5e..c8ac5f43ac 100644 --- a/ports/espressif/boards/m5stack_core2/sdkconfig +++ b/ports/espressif/boards/m5stack_core2/sdkconfig @@ -1,6 +1,30 @@ -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y -CONFIG_ESP32_SPIRAM_SUPPORT=y +# +# Espressif IoT Development Framework Configuration +# +# +# Security features +# +CONFIG_SECURE_BOOT_V2_RSA_SUPPORTED=y +CONFIG_SECURE_BOOT_V2_PREFERRED=y +# end of Security features + +# +# Component config +# +# +# Hardware Settings +# +# +# Chip revision +# +# CONFIG_ESP32_REV_MIN_0 is not set CONFIG_ESP32_REV_MIN_3=y +CONFIG_ESP32_REV_MIN=3 +CONFIG_ESP32_REV_MIN_FULL=300 +CONFIG_ESP_REV_MIN_FULL=300 +# end of Chip revision + +# end of Hardware Settings # # LWIP @@ -8,27 +32,6 @@ CONFIG_ESP32_REV_MIN_3=y CONFIG_LWIP_LOCAL_HOSTNAME="M5StaskCore2" # end of LWIP -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config +# end of Component config -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_core_basic/sdkconfig b/ports/espressif/boards/m5stack_core_basic/sdkconfig index a4cedd8e81..5b7ecf8709 100644 --- a/ports/espressif/boards/m5stack_core_basic/sdkconfig +++ b/ports/espressif/boards/m5stack_core_basic/sdkconfig @@ -1,28 +1,37 @@ -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y -CONFIG_ESP32_SPIRAM_SUPPORT=n -CONFIG_ESP32_REV_MIN_3=y +# +# Espressif IoT Development Framework Configuration +# +# +# Security features +# +CONFIG_SECURE_BOOT_V2_RSA_SUPPORTED=y +CONFIG_SECURE_BOOT_V2_PREFERRED=y +# end of Security features + +# +# Component config +# +# +# Hardware Settings +# +# +# Chip revision +# +# CONFIG_ESP32_REV_MIN_0 is not set +CONFIG_ESP32_REV_MIN_3=y +CONFIG_ESP32_REV_MIN=3 +CONFIG_ESP32_REV_MIN_FULL=300 +CONFIG_ESP_REV_MIN_FULL=300 +# end of Chip revision + +# end of Hardware Settings -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="M5StaskCoreBasic" # end of LWIP -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_core_fire/mpconfigboard.mk b/ports/espressif/boards/m5stack_core_fire/mpconfigboard.mk index 82e462012c..591c596bbc 100644 --- a/ports/espressif/boards/m5stack_core_fire/mpconfigboard.mk +++ b/ports/espressif/boards/m5stack_core_fire/mpconfigboard.mk @@ -3,7 +3,12 @@ CIRCUITPY_CREATION_ID = 0x00320001 IDF_TARGET = esp32 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m + CIRCUITPY_ESPCAMERA = 0 diff --git a/ports/espressif/boards/m5stack_core_fire/sdkconfig b/ports/espressif/boards/m5stack_core_fire/sdkconfig index d77fe64525..0e7b970938 100644 --- a/ports/espressif/boards/m5stack_core_fire/sdkconfig +++ b/ports/espressif/boards/m5stack_core_fire/sdkconfig @@ -1,58 +1,37 @@ -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y -CONFIG_ESP32_SPIRAM_SUPPORT=y +# +# Espressif IoT Development Framework Configuration +# +# +# Security features +# +CONFIG_SECURE_BOOT_V2_RSA_SUPPORTED=y +CONFIG_SECURE_BOOT_V2_PREFERRED=y +# end of Security features + +# +# Component config +# +# +# Hardware Settings +# +# +# Chip revision +# +# CONFIG_ESP32_REV_MIN_0 is not set CONFIG_ESP32_REV_MIN_3=y +CONFIG_ESP32_REV_MIN=3 +CONFIG_ESP32_REV_MIN_FULL=300 +CONFIG_ESP_REV_MIN_FULL=300 +# end of Chip revision -# -# SPI RAM config -# -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -#CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config +# end of Hardware Settings -# -# PSRAM clock and cs IO for ESP32 -# -CONFIG_D0WD_PSRAM_CLK_IO=17 -CONFIG_D0WD_PSRAM_CS_IO=16 -# end of PSRAM clock and cs IO for ESP32 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="M5StaskCoreFire" # end of LWIP -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_m5paper/mpconfigboard.mk b/ports/espressif/boards/m5stack_m5paper/mpconfigboard.mk index d3e2bb2aac..bacf270a66 100644 --- a/ports/espressif/boards/m5stack_m5paper/mpconfigboard.mk +++ b/ports/espressif/boards/m5stack_m5paper/mpconfigboard.mk @@ -6,4 +6,9 @@ IDF_TARGET = esp32 CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m + CIRCUITPY_ESPCAMERA = 0 diff --git a/ports/espressif/boards/m5stack_m5paper/sdkconfig b/ports/espressif/boards/m5stack_m5paper/sdkconfig index afbee57d19..fbf94f2749 100644 --- a/ports/espressif/boards/m5stack_m5paper/sdkconfig +++ b/ports/espressif/boards/m5stack_m5paper/sdkconfig @@ -1,58 +1,37 @@ -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y -CONFIG_ESP32_SPIRAM_SUPPORT=y +# +# Espressif IoT Development Framework Configuration +# +# +# Security features +# +CONFIG_SECURE_BOOT_V2_RSA_SUPPORTED=y +CONFIG_SECURE_BOOT_V2_PREFERRED=y +# end of Security features + +# +# Component config +# +# +# Hardware Settings +# +# +# Chip revision +# +# CONFIG_ESP32_REV_MIN_0 is not set CONFIG_ESP32_REV_MIN_3=y +CONFIG_ESP32_REV_MIN=3 +CONFIG_ESP32_REV_MIN_FULL=300 +CONFIG_ESP_REV_MIN_FULL=300 +# end of Chip revision -# -# SPI RAM config -# -CONFIG_SPIRAM_TYPE_AUTO=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -#CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config +# end of Hardware Settings -# -# PSRAM clock and cs IO for ESP32 -# -CONFIG_D0WD_PSRAM_CLK_IO=17 -CONFIG_D0WD_PSRAM_CS_IO=16 -# end of PSRAM clock and cs IO for ESP32 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="M5Paper" # end of LWIP -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_stamp_c3/mpconfigboard.h b/ports/espressif/boards/m5stack_stamp_c3/mpconfigboard.h index 3e8be96d7d..90174f60ff 100644 --- a/ports/espressif/boards/m5stack_stamp_c3/mpconfigboard.h +++ b/ports/espressif/boards/m5stack_stamp_c3/mpconfigboard.h @@ -35,8 +35,6 @@ #define CIRCUITPY_BOARD_UART (1) #define CIRCUITPY_BOARD_UART_PIN {{.tx = &pin_GPIO21, .rx = &pin_GPIO20}} -// #define CIRCUITPY_ESP_USB_SERIAL_JTAG (1) - // Serial over UART #define CIRCUITPY_CONSOLE_UART_RX (&pin_GPIO20) #define CIRCUITPY_CONSOLE_UART_TX (&pin_GPIO21) diff --git a/ports/espressif/boards/m5stack_stamp_c3/mpconfigboard.mk b/ports/espressif/boards/m5stack_stamp_c3/mpconfigboard.mk index 25a6f87428..e360567a0a 100644 --- a/ports/espressif/boards/m5stack_stamp_c3/mpconfigboard.mk +++ b/ports/espressif/boards/m5stack_stamp_c3/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE=qio CIRCUITPY_ESP_FLASH_FREQ=80m CIRCUITPY_ESP_FLASH_SIZE=4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 0 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/m5stack_stamp_c3/sdkconfig b/ports/espressif/boards/m5stack_stamp_c3/sdkconfig index 34260aa7f2..87330ec13b 100644 --- a/ports/espressif/boards/m5stack_stamp_c3/sdkconfig +++ b/ports/espressif/boards/m5stack_stamp_c3/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="m5stack-stamp-c3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_stick_c/board.c b/ports/espressif/boards/m5stack_stick_c/board.c index 779125a017..7f9b5a54f4 100644 --- a/ports/espressif/boards/m5stack_stick_c/board.c +++ b/ports/espressif/boards/m5stack_stick_c/board.c @@ -33,7 +33,7 @@ #include "shared-module/displayio/mipi_constants.h" #include "shared-bindings/board/__init__.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/m5stack_stick_c/sdkconfig b/ports/espressif/boards/m5stack_stick_c/sdkconfig index 7ec6f90c15..2e72fdb216 100644 --- a/ports/espressif/boards/m5stack_stick_c/sdkconfig +++ b/ports/espressif/boards/m5stack_stick_c/sdkconfig @@ -1,26 +1,15 @@ -CONFIG_ESP32_SPIRAM_SUPPORT=n - -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="M5StaskStickC" # end of LWIP -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_stick_c_plus/board.c b/ports/espressif/boards/m5stack_stick_c_plus/board.c index ea43209c24..5901f8cea8 100644 --- a/ports/espressif/boards/m5stack_stick_c_plus/board.c +++ b/ports/espressif/boards/m5stack_stick_c_plus/board.c @@ -33,7 +33,7 @@ #include "shared-module/displayio/mipi_constants.h" #include "shared-bindings/board/__init__.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/m5stack_stick_c_plus/sdkconfig b/ports/espressif/boards/m5stack_stick_c_plus/sdkconfig index a37e88cedf..54f50db25c 100644 --- a/ports/espressif/boards/m5stack_stick_c_plus/sdkconfig +++ b/ports/espressif/boards/m5stack_stick_c_plus/sdkconfig @@ -1,26 +1,15 @@ -CONFIG_ESP32_SPIRAM_SUPPORT=n - -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="M5StaskStickCPlus" # end of LWIP -# Uncomment (remove ###) to send ESP_LOG output to TX/RX pins -### # -### # ESP System Settings -### # -### CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -### # CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -### CONFIG_ESP_CONSOLE_UART_CUSTOM=y -### CONFIG_ESP_CONSOLE_NONE is not set -### CONFIG_ESP_CONSOLE_UART=y -### CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y -### # CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_1 is not set -### CONFIG_ESP_CONSOLE_UART_NUM=0 -### CONFIG_ESP_CONSOLE_UART_TX_GPIO=17 -### CONFIG_ESP_CONSOLE_UART_RX_GPIO=16 -### CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -### # CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -### # end of ESP System Settings +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/m5stack_timer_camera_x/board.c b/ports/espressif/boards/m5stack_timer_camera_x/board.c index 65b857c3ae..162ad40a80 100755 --- a/ports/espressif/boards/m5stack_timer_camera_x/board.c +++ b/ports/espressif/boards/m5stack_timer_camera_x/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/m5stack_timer_camera_x/mpconfigboard.mk b/ports/espressif/boards/m5stack_timer_camera_x/mpconfigboard.mk index 6339db806b..e17f5061d9 100644 --- a/ports/espressif/boards/m5stack_timer_camera_x/mpconfigboard.mk +++ b/ports/espressif/boards/m5stack_timer_camera_x/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32 CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/m5stack_timer_camera_x/sdkconfig b/ports/espressif/boards/m5stack_timer_camera_x/sdkconfig index 06cce7a595..a600e00b31 100644 --- a/ports/espressif/boards/m5stack_timer_camera_x/sdkconfig +++ b/ports/espressif/boards/m5stack_timer_camera_x/sdkconfig @@ -1,27 +1,37 @@ -# ESP32-D0WDQ6-V3 (revision 3) -CONFIG_ESP32_SPIRAM_SUPPORT=y -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y +# +# Espressif IoT Development Framework Configuration +# +# +# Security features +# +CONFIG_SECURE_BOOT_V2_RSA_SUPPORTED=y +CONFIG_SECURE_BOOT_V2_PREFERRED=y +# end of Security features + +# +# Component config +# +# +# Hardware Settings +# +# +# Chip revision +# +# CONFIG_ESP32_REV_MIN_0 is not set CONFIG_ESP32_REV_MIN_3=y +CONFIG_ESP32_REV_MIN=3 +CONFIG_ESP32_REV_MIN_FULL=300 +CONFIG_ESP_REV_MIN_FULL=300 +# end of Chip revision -# PSRAM -CONFIG_D0WD_PSRAM_CLK_IO=17 -CONFIG_D0WD_PSRAM_CS_IO=16 +# end of Hardware Settings -CONFIG_SPIRAM_MODE_OCT=y -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -CONFIG_SPIRAM_SPEED_80M=y - -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_USE_MEMMAP=y -CONFIG_SPIRAM_MEMTEST=y - -# Hostname +# +# LWIP +# CONFIG_LWIP_LOCAL_HOSTNAME="M5StackTimerX" +# end of LWIP -# Camera -CONFIG_OV3660_SUPPORT=y -CONFIG_GC_SENSOR_SUBSAMPLE_MODE=y -CONFIG_CAMERA_CORE0=y -CONFIG_CAMERA_DMA_BUFFER_SIZE_MAX=32768 +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/maker_badge/board.c b/ports/espressif/boards/maker_badge/board.c index 19dba31c57..45a7be2380 100644 --- a/ports/espressif/boards/maker_badge/board.c +++ b/ports/espressif/boards/maker_badge/board.c @@ -37,16 +37,6 @@ #define DELAY 0x80 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) { diff --git a/ports/espressif/boards/maker_badge/sdkconfig b/ports/espressif/boards/maker_badge/sdkconfig index 68689ed79e..d62227df74 100644 --- a/ports/espressif/boards/maker_badge/sdkconfig +++ b/ports/espressif/boards/maker_badge/sdkconfig @@ -1,6 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=n - +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="Maker_badge" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/makerfabs_tft7/board.c b/ports/espressif/boards/makerfabs_tft7/board.c new file mode 100644 index 0000000000..0639737c35 --- /dev/null +++ b/ports/espressif/boards/makerfabs_tft7/board.c @@ -0,0 +1,34 @@ +/* + * 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) { +} + +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/makerfabs_tft7/mpconfigboard.h b/ports/espressif/boards/makerfabs_tft7/mpconfigboard.h new file mode 100644 index 0000000000..6dc58e9ef3 --- /dev/null +++ b/ports/espressif/boards/makerfabs_tft7/mpconfigboard.h @@ -0,0 +1,44 @@ +/* + * 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 "MakerFabs-ESP32-S3-Parallel-TFT-With-Touch-7inch" +#define MICROPY_HW_MCU_NAME "ESP32S3" + +#define DEFAULT_I2C_BUS_SDA (&pin_GPIO17) +#define DEFAULT_I2C_BUS_SCL (&pin_GPIO18) + +#define DEFAULT_SPI_BUS_MOSI (&pin_GPIO11) +#define DEFAULT_SPI_BUS_SCK (&pin_GPIO12) +#define DEFAULT_SPI_BUS_MISO (&pin_GPIO13) + +// UART pins attached to the USB-serial converter chip +#define CIRCUITPY_CONSOLE_UART_TX (&pin_GPIO43) +#define CIRCUITPY_CONSOLE_UART_RX (&pin_GPIO44) + +// a 1024x768 16BPP framebuffer + some breathing room +#define DEFAULT_RESERVED_PSRAM (1024 * 1024 * 2) diff --git a/ports/espressif/boards/makerfabs_tft7/mpconfigboard.mk b/ports/espressif/boards/makerfabs_tft7/mpconfigboard.mk new file mode 100644 index 0000000000..dbe7940c7e --- /dev/null +++ b/ports/espressif/boards/makerfabs_tft7/mpconfigboard.mk @@ -0,0 +1,16 @@ +USB_VID = 0x239A +USB_PID = 0x814A +USB_PRODUCT = "MakerFabs-ESP32-S3-Parallel-TFT-With-Touch-7inch" +USB_MANUFACTURER = "MakerFabs" + +IDF_TARGET = esp32s3 + +CIRCUITPY_ESP_FLASH_MODE = dio +CIRCUITPY_ESP_FLASH_FREQ = 80m +CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m + +CIRCUITPY_DOTCLOCKFRAMEBUFFER = 1 diff --git a/ports/espressif/boards/makerfabs_tft7/pins.c b/ports/espressif/boards/makerfabs_tft7/pins.c new file mode 100644 index 0000000000..88738d3c99 --- /dev/null +++ b/ports/espressif/boards/makerfabs_tft7/pins.c @@ -0,0 +1,100 @@ +#include "py/objtuple.h" +#include "shared-bindings/board/__init__.h" + +STATIC const mp_rom_obj_tuple_t tft_r_pins = { + {&mp_type_tuple}, + 5, + { + MP_ROM_PTR(&pin_GPIO14), + MP_ROM_PTR(&pin_GPIO21), + MP_ROM_PTR(&pin_GPIO47), + MP_ROM_PTR(&pin_GPIO48), + MP_ROM_PTR(&pin_GPIO45), + } +}; + +STATIC const mp_rom_obj_tuple_t tft_g_pins = { + {&mp_type_tuple}, + 6, + { + MP_ROM_PTR(&pin_GPIO4), + MP_ROM_PTR(&pin_GPIO16), + MP_ROM_PTR(&pin_GPIO15), + MP_ROM_PTR(&pin_GPIO7), + MP_ROM_PTR(&pin_GPIO6), + MP_ROM_PTR(&pin_GPIO5), + } +}; + +STATIC const mp_rom_obj_tuple_t tft_b_pins = { + {&mp_type_tuple}, + 5, + { + MP_ROM_PTR(&pin_GPIO1), + MP_ROM_PTR(&pin_GPIO9), + MP_ROM_PTR(&pin_GPIO46), + MP_ROM_PTR(&pin_GPIO3), + MP_ROM_PTR(&pin_GPIO8), + } +}; + +STATIC const mp_rom_map_elem_t tft_pins_table[] = { + { MP_ROM_QSTR(MP_QSTR_de), MP_ROM_PTR(&pin_GPIO40) }, + { MP_ROM_QSTR(MP_QSTR_vsync), MP_ROM_PTR(&pin_GPIO41) }, + { MP_ROM_QSTR(MP_QSTR_hsync), MP_ROM_PTR(&pin_GPIO39) }, + { MP_ROM_QSTR(MP_QSTR_dclk), MP_ROM_PTR(&pin_GPIO42) }, + { MP_ROM_QSTR(MP_QSTR_red), MP_ROM_PTR(&tft_r_pins) }, + { MP_ROM_QSTR(MP_QSTR_green), MP_ROM_PTR(&tft_g_pins) }, + { MP_ROM_QSTR(MP_QSTR_blue), MP_ROM_PTR(&tft_b_pins) }, +}; +MP_DEFINE_CONST_DICT(tft_pins_dict, tft_pins_table); + +STATIC const mp_rom_map_elem_t timings800_table[] = { + { MP_ROM_QSTR(MP_QSTR_frequency), MP_ROM_INT(6500000) }, // nominal 16MHz, but display is unstable/tears at that frequency + { MP_ROM_QSTR(MP_QSTR_width), MP_ROM_INT(800) }, + { MP_ROM_QSTR(MP_QSTR_height), MP_ROM_INT(480) }, + { MP_ROM_QSTR(MP_QSTR_hsync_pulse_width), MP_ROM_INT(30) }, + { MP_ROM_QSTR(MP_QSTR_hsync_front_porch), MP_ROM_INT(210) }, + { MP_ROM_QSTR(MP_QSTR_hsync_back_porch), MP_ROM_INT(16) }, + { MP_ROM_QSTR(MP_QSTR_hsync_idle_low), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_vsync_pulse_width), MP_ROM_INT(13) }, + { MP_ROM_QSTR(MP_QSTR_vsync_front_porch), MP_ROM_INT(22) }, + { MP_ROM_QSTR(MP_QSTR_vsync_back_porch), MP_ROM_INT(10) }, + { MP_ROM_QSTR(MP_QSTR_vsync_idle_low), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_de_idle_high), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_pclk_active_high), MP_ROM_FALSE }, + { MP_ROM_QSTR(MP_QSTR_pclk_idle_high), MP_ROM_FALSE }, +}; +MP_DEFINE_CONST_DICT(timings800_dict, timings800_table); + +STATIC const mp_rom_map_elem_t board_module_globals_table[] = { + CIRCUITPYTHON_BOARD_DICT_STANDARD_ITEMS + + { MP_ROM_QSTR(MP_QSTR_TFT_PINS), MP_ROM_PTR(&tft_pins_dict) }, + { MP_ROM_QSTR(MP_QSTR_TFT_TIMINGS_800x480), MP_ROM_PTR(&timings800_dict) }, + { MP_ROM_QSTR(MP_QSTR_BACKLIGHT), MP_ROM_PTR(&pin_GPIO10) }, + + { MP_ROM_QSTR(MP_QSTR_I2S_SCK), MP_ROM_PTR(&pin_GPIO20) }, + { MP_ROM_QSTR(MP_QSTR_I2S_WS), MP_ROM_PTR(&pin_GPIO2) }, + { MP_ROM_QSTR(MP_QSTR_I2S_SDO), MP_ROM_PTR(&pin_GPIO19) }, + + { 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_SCL), MP_ROM_PTR(&pin_GPIO18) }, + { MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_GPIO17) }, + + { MP_ROM_QSTR(MP_QSTR_MOSI), MP_ROM_PTR(&pin_GPIO11) }, + { MP_ROM_QSTR(MP_QSTR_MISO), MP_ROM_PTR(&pin_GPIO13) }, + { MP_ROM_QSTR(MP_QSTR_SCK), MP_ROM_PTR(&pin_GPIO12) }, + + // boot mode button can be used in SW as well + { MP_ROM_QSTR(MP_QSTR_BUTTON), MP_ROM_PTR(&pin_GPIO1) }, + + // IO10 <> SD_CS is cut at factory (non-placed resistor position R34) and pulled up. + // Permanent SDIO 1-bit mode? + + { 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_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table); diff --git a/ports/espressif/boards/makerfabs_tft7/sdkconfig b/ports/espressif/boards/makerfabs_tft7/sdkconfig new file mode 100644 index 0000000000..e05ead7960 --- /dev/null +++ b/ports/espressif/boards/makerfabs_tft7/sdkconfig @@ -0,0 +1,28 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# ESP System Settings +# +CONFIG_ESP_CONSOLE_UART_CUSTOM=y +# CONFIG_ESP_CONSOLE_NONE is not set +CONFIG_ESP_CONSOLE_UART=y +CONFIG_ESP_CONSOLE_UART_CUSTOM_NUM_0=y +CONFIG_ESP_CONSOLE_UART_NUM=0 +CONFIG_ESP_CONSOLE_UART_TX_GPIO=43 +CONFIG_ESP_CONSOLE_UART_RX_GPIO=44 +CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 +# end of ESP System Settings + +# +# LWIP +# +CONFIG_LWIP_LOCAL_HOSTNAME="matouch-tft" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/microdev_micro_c3/board.c b/ports/espressif/boards/microdev_micro_c3/board.c index b155ed7a7b..f749ee60d2 100644 --- a/ports/espressif/boards/microdev_micro_c3/board.c +++ b/ports/espressif/boards/microdev_micro_c3/board.c @@ -24,15 +24,6 @@ * THE SOFTWARE. */ -#include "shared-bindings/microcontroller/Pin.h" #include "supervisor/board.h" -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO20); - common_hal_never_reset_pin(&pin_GPIO21); - #endif -} - // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/microdev_micro_c3/mpconfigboard.h b/ports/espressif/boards/microdev_micro_c3/mpconfigboard.h index 2153513306..0ed8ea8925 100644 --- a/ports/espressif/boards/microdev_micro_c3/mpconfigboard.h +++ b/ports/espressif/boards/microdev_micro_c3/mpconfigboard.h @@ -45,8 +45,5 @@ #define DEFAULT_UART_BUS_RX (&pin_GPIO20) #define DEFAULT_UART_BUS_TX (&pin_GPIO21) -// For REPL over built-in USB Serial -#define CIRCUITPY_ESP_USB_SERIAL_JTAG (1) - // For entering safe mode #define CIRCUITPY_BOOT_BUTTON (&pin_GPIO9) diff --git a/ports/espressif/boards/microdev_micro_c3/mpconfigboard.mk b/ports/espressif/boards/microdev_micro_c3/mpconfigboard.mk index 94c64a8273..dd3e159386 100644 --- a/ports/espressif/boards/microdev_micro_c3/mpconfigboard.mk +++ b/ports/espressif/boards/microdev_micro_c3/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 1 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/microdev_micro_c3/sdkconfig b/ports/espressif/boards/microdev_micro_c3/sdkconfig index f6f038a77c..9b13279bd3 100644 --- a/ports/espressif/boards/microdev_micro_c3/sdkconfig +++ b/ports/espressif/boards/microdev_micro_c3/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="MicroDev-microC3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/microdev_micro_s2/board.c b/ports/espressif/boards/microdev_micro_s2/board.c index 65bb19aced..f749ee60d2 100644 --- a/ports/espressif/boards/microdev_micro_s2/board.c +++ b/ports/espressif/boards/microdev_micro_s2/board.c @@ -25,17 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -#include "components/driver/include/driver/gpio.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/microdev_micro_s2/mpconfigboard.mk b/ports/espressif/boards/microdev_micro_s2/mpconfigboard.mk index e5a7f05462..c090c69aac 100644 --- a/ports/espressif/boards/microdev_micro_s2/mpconfigboard.mk +++ b/ports/espressif/boards/microdev_micro_s2/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "MicroDev" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/microdev_micro_s2/sdkconfig b/ports/espressif/boards/microdev_micro_s2/sdkconfig index 4b617fee71..f6158eac3e 100644 --- a/ports/espressif/boards/microdev_micro_s2/sdkconfig +++ b/ports/espressif/boards/microdev_micro_s2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="MicroDev-microS2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/mixgo_ce_serial/board.c b/ports/espressif/boards/mixgo_ce_serial/board.c index fc592ce4c4..ffc208e46e 100644 --- a/ports/espressif/boards/mixgo_ce_serial/board.c +++ b/ports/espressif/boards/mixgo_ce_serial/board.c @@ -34,12 +34,6 @@ #include "supervisor/filesystem.h" void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ - mp_import_stat_t stat_b = mp_import_stat("boot.py"); if (stat_b != MP_IMPORT_STAT_FILE) { FATFS *fatfs = filesystem_circuitpy(); diff --git a/ports/espressif/boards/mixgo_ce_serial/sdkconfig b/ports/espressif/boards/mixgo_ce_serial/sdkconfig index 5b9c86dcc3..e69de29bb2 100644 --- a/ports/espressif/boards/mixgo_ce_serial/sdkconfig +++ b/ports/espressif/boards/mixgo_ce_serial/sdkconfig @@ -1,6 +0,0 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/mixgo_ce_udisk/board.c b/ports/espressif/boards/mixgo_ce_udisk/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/mixgo_ce_udisk/board.c +++ b/ports/espressif/boards/mixgo_ce_udisk/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/mixgo_ce_udisk/sdkconfig b/ports/espressif/boards/mixgo_ce_udisk/sdkconfig index 5b9c86dcc3..e69de29bb2 100644 --- a/ports/espressif/boards/mixgo_ce_udisk/sdkconfig +++ b/ports/espressif/boards/mixgo_ce_udisk/sdkconfig @@ -1,6 +0,0 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/morpheans_morphesp-240/board.c b/ports/espressif/boards/morpheans_morphesp-240/board.c index 9491902161..b4c0db304a 100644 --- a/ports/espressif/boards/morpheans_morphesp-240/board.c +++ b/ports/espressif/boards/morpheans_morphesp-240/board.c @@ -139,12 +139,6 @@ uint8_t display_init_sequence[] = { void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO6); - common_hal_never_reset_pin(&pin_GPIO7); - #endif /* DEBUG */ - // Display displayio_fourwire_obj_t *bus = &allocate_display_bus()->fourwire_bus; diff --git a/ports/espressif/boards/morpheans_morphesp-240/sdkconfig b/ports/espressif/boards/morpheans_morphesp-240/sdkconfig index 6de15d1556..b0a838eacc 100644 --- a/ports/espressif/boards/morpheans_morphesp-240/sdkconfig +++ b/ports/espressif/boards/morpheans_morphesp-240/sdkconfig @@ -1,6 +1,15 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="MORPHESP-240" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/muselab_nanoesp32_s2_wroom/board.c b/ports/espressif/boards/muselab_nanoesp32_s2_wroom/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/muselab_nanoesp32_s2_wroom/board.c +++ b/ports/espressif/boards/muselab_nanoesp32_s2_wroom/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/muselab_nanoesp32_s2_wroom/sdkconfig b/ports/espressif/boards/muselab_nanoesp32_s2_wroom/sdkconfig index 5b9c86dcc3..e69de29bb2 100644 --- a/ports/espressif/boards/muselab_nanoesp32_s2_wroom/sdkconfig +++ b/ports/espressif/boards/muselab_nanoesp32_s2_wroom/sdkconfig @@ -1,6 +0,0 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/muselab_nanoesp32_s2_wrover/board.c b/ports/espressif/boards/muselab_nanoesp32_s2_wrover/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/muselab_nanoesp32_s2_wrover/board.c +++ b/ports/espressif/boards/muselab_nanoesp32_s2_wrover/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/muselab_nanoesp32_s2_wrover/mpconfigboard.mk b/ports/espressif/boards/muselab_nanoesp32_s2_wrover/mpconfigboard.mk index f008241e19..1707d32706 100644 --- a/ports/espressif/boards/muselab_nanoesp32_s2_wrover/mpconfigboard.mk +++ b/ports/espressif/boards/muselab_nanoesp32_s2_wrover/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Muselab" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/muselab_nanoesp32_s2_wrover/sdkconfig b/ports/espressif/boards/muselab_nanoesp32_s2_wrover/sdkconfig index 9b513fcf5a..e69de29bb2 100644 --- a/ports/espressif/boards/muselab_nanoesp32_s2_wrover/sdkconfig +++ b/ports/espressif/boards/muselab_nanoesp32_s2_wrover/sdkconfig @@ -1,27 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y - -# -# SPI RAM config -# -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -# -# 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_SPEED_40M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_USE_MEMMAP=y -CONFIG_SPIRAM_MEMTEST=y - -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/odt_pixelwing_esp32_s2/mpconfigboard.mk b/ports/espressif/boards/odt_pixelwing_esp32_s2/mpconfigboard.mk index 44546fc09f..f0a39b8a20 100644 --- a/ports/espressif/boards/odt_pixelwing_esp32_s2/mpconfigboard.mk +++ b/ports/espressif/boards/odt_pixelwing_esp32_s2/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Oak Dev Tech" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/odt_pixelwing_esp32_s2/sdkconfig b/ports/espressif/boards/odt_pixelwing_esp32_s2/sdkconfig index 17c1995cd3..3017a9532f 100644 --- a/ports/espressif/boards/odt_pixelwing_esp32_s2/sdkconfig +++ b/ports/espressif/boards/odt_pixelwing_esp32_s2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="PixelWing-ESP32S2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/seeed_xiao_esp32c3/board.c b/ports/espressif/boards/seeed_xiao_esp32c3/board.c index 7bcdcdba25..164430c88c 100644 --- a/ports/espressif/boards/seeed_xiao_esp32c3/board.c +++ b/ports/espressif/boards/seeed_xiao_esp32c3/board.c @@ -24,17 +24,6 @@ * THE SOFTWARE. */ -#include "shared-bindings/microcontroller/Pin.h" #include "supervisor/board.h" -#include "components/driver/include/driver/gpio.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO20); - common_hal_never_reset_pin(&pin_GPIO21); - #endif -} - // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/seeed_xiao_esp32c3/mpconfigboard.h b/ports/espressif/boards/seeed_xiao_esp32c3/mpconfigboard.h index 638be9d197..26fa6b7f83 100644 --- a/ports/espressif/boards/seeed_xiao_esp32c3/mpconfigboard.h +++ b/ports/espressif/boards/seeed_xiao_esp32c3/mpconfigboard.h @@ -10,5 +10,3 @@ #define DEFAULT_UART_BUS_RX (&pin_GPIO20) #define DEFAULT_UART_BUS_TX (&pin_GPIO21) - -#define CIRCUITPY_ESP_USB_SERIAL_JTAG (1) diff --git a/ports/espressif/boards/seeed_xiao_esp32c3/mpconfigboard.mk b/ports/espressif/boards/seeed_xiao_esp32c3/mpconfigboard.mk index d7325cf44e..3e2c97dab9 100644 --- a/ports/espressif/boards/seeed_xiao_esp32c3/mpconfigboard.mk +++ b/ports/espressif/boards/seeed_xiao_esp32c3/mpconfigboard.mk @@ -6,3 +6,7 @@ IDF_TARGET = esp32c3 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_USB_SERIAL_JTAG = 1 + +CIRCUITPY_BLEIO = 0 diff --git a/ports/espressif/boards/seeed_xiao_esp32c3/sdkconfig b/ports/espressif/boards/seeed_xiao_esp32c3/sdkconfig index b2c9bc0fe6..a593f1d173 100644 --- a/ports/espressif/boards/seeed_xiao_esp32c3/sdkconfig +++ b/ports/espressif/boards/seeed_xiao_esp32c3/sdkconfig @@ -1,5 +1,15 @@ # +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="seeed-xiao-esp32c3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/smartbeedesigns_bee_data_logger/board.c b/ports/espressif/boards/smartbeedesigns_bee_data_logger/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/smartbeedesigns_bee_data_logger/board.c +++ b/ports/espressif/boards/smartbeedesigns_bee_data_logger/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/smartbeedesigns_bee_data_logger/sdkconfig b/ports/espressif/boards/smartbeedesigns_bee_data_logger/sdkconfig index 4008263f8d..deb1b88d7c 100644 --- a/ports/espressif/boards/smartbeedesigns_bee_data_logger/sdkconfig +++ b/ports/espressif/boards/smartbeedesigns_bee_data_logger/sdkconfig @@ -1,6 +1,15 @@ -# CONFIG_ESP32S3_SPIRAM_SUPPORT is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="smartbeedesigns_bee_data_logger" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/smartbeedesigns_bee_motion_s3/board.c b/ports/espressif/boards/smartbeedesigns_bee_motion_s3/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/smartbeedesigns_bee_motion_s3/board.c +++ b/ports/espressif/boards/smartbeedesigns_bee_motion_s3/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/smartbeedesigns_bee_motion_s3/sdkconfig b/ports/espressif/boards/smartbeedesigns_bee_motion_s3/sdkconfig index 84cf45aa83..fe95b60d4c 100644 --- a/ports/espressif/boards/smartbeedesigns_bee_motion_s3/sdkconfig +++ b/ports/espressif/boards/smartbeedesigns_bee_motion_s3/sdkconfig @@ -1,6 +1,15 @@ -# CONFIG_ESP32S3_SPIRAM_SUPPORT is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="smartbeedesigns_bee_motion_s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/smartbeedesigns_bee_s3/board.c b/ports/espressif/boards/smartbeedesigns_bee_s3/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/smartbeedesigns_bee_s3/board.c +++ b/ports/espressif/boards/smartbeedesigns_bee_s3/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/smartbeedesigns_bee_s3/sdkconfig b/ports/espressif/boards/smartbeedesigns_bee_s3/sdkconfig index b7bb11fdd5..2c7a057567 100644 --- a/ports/espressif/boards/smartbeedesigns_bee_s3/sdkconfig +++ b/ports/espressif/boards/smartbeedesigns_bee_s3/sdkconfig @@ -1,6 +1,15 @@ -# CONFIG_ESP32S3_SPIRAM_SUPPORT is not set +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="smartbeedesigns_bee_s3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/targett_module_clip_wroom/board.c b/ports/espressif/boards/targett_module_clip_wroom/board.c index ce5a770920..3168e9a0aa 100644 --- a/ports/espressif/boards/targett_module_clip_wroom/board.c +++ b/ports/espressif/boards/targett_module_clip_wroom/board.c @@ -29,12 +29,6 @@ #include "shared-bindings/microcontroller/Pin.h" void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ - // Crystal common_hal_never_reset_pin(&pin_GPIO15); common_hal_never_reset_pin(&pin_GPIO16); diff --git a/ports/espressif/boards/targett_module_clip_wroom/mpconfigboard.mk b/ports/espressif/boards/targett_module_clip_wroom/mpconfigboard.mk index e13c654aa6..2422ee60ef 100644 --- a/ports/espressif/boards/targett_module_clip_wroom/mpconfigboard.mk +++ b/ports/espressif/boards/targett_module_clip_wroom/mpconfigboard.mk @@ -8,4 +8,5 @@ IDF_TARGET = esp32s2 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m CIRCUITPY_ESP_FLASH_SIZE = 4MB + CIRCUITPY_ESPCAMERA = 0 diff --git a/ports/espressif/boards/targett_module_clip_wroom/sdkconfig b/ports/espressif/boards/targett_module_clip_wroom/sdkconfig index 5b9c86dcc3..e69de29bb2 100644 --- a/ports/espressif/boards/targett_module_clip_wroom/sdkconfig +++ b/ports/espressif/boards/targett_module_clip_wroom/sdkconfig @@ -1,6 +0,0 @@ -# CONFIG_ESP32S2_SPIRAM_SUPPORT is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/targett_module_clip_wrover/board.c b/ports/espressif/boards/targett_module_clip_wrover/board.c index ce5a770920..3168e9a0aa 100644 --- a/ports/espressif/boards/targett_module_clip_wrover/board.c +++ b/ports/espressif/boards/targett_module_clip_wrover/board.c @@ -29,12 +29,6 @@ #include "shared-bindings/microcontroller/Pin.h" void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ - // Crystal common_hal_never_reset_pin(&pin_GPIO15); common_hal_never_reset_pin(&pin_GPIO16); diff --git a/ports/espressif/boards/targett_module_clip_wrover/mpconfigboard.mk b/ports/espressif/boards/targett_module_clip_wrover/mpconfigboard.mk index 6ef620ac50..a2e862fa02 100644 --- a/ports/espressif/boards/targett_module_clip_wrover/mpconfigboard.mk +++ b/ports/espressif/boards/targett_module_clip_wrover/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Targett" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m diff --git a/ports/espressif/boards/targett_module_clip_wrover/sdkconfig b/ports/espressif/boards/targett_module_clip_wrover/sdkconfig index f19afafa3d..e69de29bb2 100644 --- a/ports/espressif/boards/targett_module_clip_wrover/sdkconfig +++ b/ports/espressif/boards/targett_module_clip_wrover/sdkconfig @@ -1,37 +0,0 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -# -# PSRAM clock and cs IO for ESP32S2 -# -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# -# LWIP -# -CONFIG_LWIP_LOCAL_HOSTNAME="espressif" -# end of LWIP diff --git a/ports/espressif/boards/unexpectedmaker_feathers2/board.c b/ports/espressif/boards/unexpectedmaker_feathers2/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers2/board.c +++ b/ports/espressif/boards/unexpectedmaker_feathers2/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/unexpectedmaker_feathers2/mpconfigboard.mk b/ports/espressif/boards/unexpectedmaker_feathers2/mpconfigboard.mk index 1d48ea1076..fda8f7bb22 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers2/mpconfigboard.mk +++ b/ports/espressif/boards/unexpectedmaker_feathers2/mpconfigboard.mk @@ -5,9 +5,13 @@ USB_MANUFACTURER = "UnexpectedMaker" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m CIRCUITPY_BITBANG_APA102 = 1 diff --git a/ports/espressif/boards/unexpectedmaker_feathers2/sdkconfig b/ports/espressif/boards/unexpectedmaker_feathers2/sdkconfig index 8d785a6004..a1e5e03b76 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers2/sdkconfig +++ b/ports/espressif/boards/unexpectedmaker_feathers2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="UMFeatherS2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/unexpectedmaker_feathers2_neo/board.c b/ports/espressif/boards/unexpectedmaker_feathers2_neo/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers2_neo/board.c +++ b/ports/espressif/boards/unexpectedmaker_feathers2_neo/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/unexpectedmaker_feathers2_neo/mpconfigboard.mk b/ports/espressif/boards/unexpectedmaker_feathers2_neo/mpconfigboard.mk index 2b78e51635..4f3ea4afac 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers2_neo/mpconfigboard.mk +++ b/ports/espressif/boards/unexpectedmaker_feathers2_neo/mpconfigboard.mk @@ -5,9 +5,13 @@ USB_MANUFACTURER = "UnexpectedMaker" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m CIRCUITPY_BITBANG_NEOPIXEL = 1 diff --git a/ports/espressif/boards/unexpectedmaker_feathers2_neo/sdkconfig b/ports/espressif/boards/unexpectedmaker_feathers2_neo/sdkconfig index 4a5990b91d..cc781c9a3d 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers2_neo/sdkconfig +++ b/ports/espressif/boards/unexpectedmaker_feathers2_neo/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="UMFeatherS2Neo" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/board.c b/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/board.c +++ b/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/mpconfigboard.mk b/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/mpconfigboard.mk index 1d48ea1076..fda8f7bb22 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/mpconfigboard.mk +++ b/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/mpconfigboard.mk @@ -5,9 +5,13 @@ USB_MANUFACTURER = "UnexpectedMaker" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 40m -CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m CIRCUITPY_BITBANG_APA102 = 1 diff --git a/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/sdkconfig b/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/sdkconfig index 8d785a6004..a1e5e03b76 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/sdkconfig +++ b/ports/espressif/boards/unexpectedmaker_feathers2_prerelease/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="UMFeatherS2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/unexpectedmaker_feathers3/board.c b/ports/espressif/boards/unexpectedmaker_feathers3/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers3/board.c +++ b/ports/espressif/boards/unexpectedmaker_feathers3/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/unexpectedmaker_feathers3/mpconfigboard.mk b/ports/espressif/boards/unexpectedmaker_feathers3/mpconfigboard.mk index 666185b6fd..887ca5a122 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers3/mpconfigboard.mk +++ b/ports/espressif/boards/unexpectedmaker_feathers3/mpconfigboard.mk @@ -5,9 +5,13 @@ USB_MANUFACTURER = "UnexpectedMaker" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m #CIRCUITPY_BITBANG_NEOPIXEL = 1 diff --git a/ports/espressif/boards/unexpectedmaker_feathers3/sdkconfig b/ports/espressif/boards/unexpectedmaker_feathers3/sdkconfig index ec989c08fc..3ccd3175c6 100644 --- a/ports/espressif/boards/unexpectedmaker_feathers3/sdkconfig +++ b/ports/espressif/boards/unexpectedmaker_feathers3/sdkconfig @@ -1,39 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y - # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 - # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -# CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# end of SPI RAM config - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="UMFeatherS3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/unexpectedmaker_nanos3/board.c b/ports/espressif/boards/unexpectedmaker_nanos3/board.c index 8fd94f6c8b..164430c88c 100644 --- a/ports/espressif/boards/unexpectedmaker_nanos3/board.c +++ b/ports/espressif/boards/unexpectedmaker_nanos3/board.c @@ -25,13 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/unexpectedmaker_nanos3/mpconfigboard.mk b/ports/espressif/boards/unexpectedmaker_nanos3/mpconfigboard.mk index c61654bfc3..9fd196d4bf 100644 --- a/ports/espressif/boards/unexpectedmaker_nanos3/mpconfigboard.mk +++ b/ports/espressif/boards/unexpectedmaker_nanos3/mpconfigboard.mk @@ -9,6 +9,10 @@ CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m + # CIRCUITPY_BITBANG_NEOPIXEL = 1 # Include these Python libraries in firmware. diff --git a/ports/espressif/boards/unexpectedmaker_nanos3/sdkconfig b/ports/espressif/boards/unexpectedmaker_nanos3/sdkconfig index c1dee83717..815f002d38 100644 --- a/ports/espressif/boards/unexpectedmaker_nanos3/sdkconfig +++ b/ports/espressif/boards/unexpectedmaker_nanos3/sdkconfig @@ -1,39 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y - # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 - # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -# CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# end of SPI RAM config - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="UMNanoS3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/unexpectedmaker_pros3/board.c b/ports/espressif/boards/unexpectedmaker_pros3/board.c index 8fd94f6c8b..164430c88c 100644 --- a/ports/espressif/boards/unexpectedmaker_pros3/board.c +++ b/ports/espressif/boards/unexpectedmaker_pros3/board.c @@ -25,13 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} +// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/unexpectedmaker_pros3/mpconfigboard.mk b/ports/espressif/boards/unexpectedmaker_pros3/mpconfigboard.mk index bf6e7a5105..be2a711c6c 100644 --- a/ports/espressif/boards/unexpectedmaker_pros3/mpconfigboard.mk +++ b/ports/espressif/boards/unexpectedmaker_pros3/mpconfigboard.mk @@ -5,9 +5,13 @@ USB_MANUFACTURER = "UnexpectedMaker" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 16MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m # CIRCUITPY_BITBANG_NEOPIXEL = 1 diff --git a/ports/espressif/boards/unexpectedmaker_pros3/sdkconfig b/ports/espressif/boards/unexpectedmaker_pros3/sdkconfig index eeb103fb7d..21b91a2199 100644 --- a/ports/espressif/boards/unexpectedmaker_pros3/sdkconfig +++ b/ports/espressif/boards/unexpectedmaker_pros3/sdkconfig @@ -1,39 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y - # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 - # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -# CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# end of SPI RAM config - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="UMProS3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/unexpectedmaker_tinypico/board.c b/ports/espressif/boards/unexpectedmaker_tinypico/board.c index e59af9528d..530c27f776 100644 --- a/ports/espressif/boards/unexpectedmaker_tinypico/board.c +++ b/ports/espressif/boards/unexpectedmaker_tinypico/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/unexpectedmaker_tinypico/mpconfigboard.mk b/ports/espressif/boards/unexpectedmaker_tinypico/mpconfigboard.mk index e26981465b..d600ce4d30 100644 --- a/ports/espressif/boards/unexpectedmaker_tinypico/mpconfigboard.mk +++ b/ports/espressif/boards/unexpectedmaker_tinypico/mpconfigboard.mk @@ -3,6 +3,10 @@ CIRCUITPY_CREATION_ID = 0x00000001 IDF_TARGET = esp32 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/unexpectedmaker_tinypico/sdkconfig b/ports/espressif/boards/unexpectedmaker_tinypico/sdkconfig index 2d4d0d4ecc..e69de29bb2 100644 --- a/ports/espressif/boards/unexpectedmaker_tinypico/sdkconfig +++ b/ports/espressif/boards/unexpectedmaker_tinypico/sdkconfig @@ -1,20 +0,0 @@ -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -# CONFIG_SPIRAM_SIZE is not set -CONFIG_ESP32_SPIRAM_SUPPORT=y -CONFIG_SPIRAM_SPEED_80M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_IGNORE_NOTFOUND=y -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# CONFIG_SPIRAM_ALLOW_NOINIT_SEG_EXTERNAL_MEMORY is not set -CONFIG_SPIRAM_CACHE_WORKAROUND=y diff --git a/ports/espressif/boards/unexpectedmaker_tinypico_nano/board.c b/ports/espressif/boards/unexpectedmaker_tinypico_nano/board.c index d66ab9e5f1..551058611e 100644 --- a/ports/espressif/boards/unexpectedmaker_tinypico_nano/board.c +++ b/ports/espressif/boards/unexpectedmaker_tinypico_nano/board.c @@ -27,7 +27,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" #include "shared-bindings/microcontroller/Pin.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" #include "common-hal/microcontroller/Pin.h" diff --git a/ports/espressif/boards/unexpectedmaker_tinypico_nano/mpconfigboard.mk b/ports/espressif/boards/unexpectedmaker_tinypico_nano/mpconfigboard.mk index f3d9ea4c92..5f83793213 100644 --- a/ports/espressif/boards/unexpectedmaker_tinypico_nano/mpconfigboard.mk +++ b/ports/espressif/boards/unexpectedmaker_tinypico_nano/mpconfigboard.mk @@ -3,6 +3,10 @@ CIRCUITPY_CREATION_ID = 0x00000002 IDF_TARGET = esp32 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/unexpectedmaker_tinypico_nano/sdkconfig b/ports/espressif/boards/unexpectedmaker_tinypico_nano/sdkconfig index 2d4d0d4ecc..e69de29bb2 100644 --- a/ports/espressif/boards/unexpectedmaker_tinypico_nano/sdkconfig +++ b/ports/espressif/boards/unexpectedmaker_tinypico_nano/sdkconfig @@ -1,20 +0,0 @@ -# -# SPI RAM config -# -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -# CONFIG_SPIRAM_SIZE is not set -CONFIG_ESP32_SPIRAM_SUPPORT=y -CONFIG_SPIRAM_SPEED_80M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_IGNORE_NOTFOUND=y -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# CONFIG_SPIRAM_ALLOW_NOINIT_SEG_EXTERNAL_MEMORY is not set -CONFIG_SPIRAM_CACHE_WORKAROUND=y diff --git a/ports/espressif/boards/unexpectedmaker_tinys2/board.c b/ports/espressif/boards/unexpectedmaker_tinys2/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/unexpectedmaker_tinys2/board.c +++ b/ports/espressif/boards/unexpectedmaker_tinys2/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/unexpectedmaker_tinys2/mpconfigboard.mk b/ports/espressif/boards/unexpectedmaker_tinys2/mpconfigboard.mk index 39a9c38b36..6b61ef12b7 100644 --- a/ports/espressif/boards/unexpectedmaker_tinys2/mpconfigboard.mk +++ b/ports/espressif/boards/unexpectedmaker_tinys2/mpconfigboard.mk @@ -5,9 +5,13 @@ USB_MANUFACTURER = "UnexpectedMaker" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 40m CIRCUITPY_BITBANG_NEOPIXEL = 1 diff --git a/ports/espressif/boards/unexpectedmaker_tinys2/sdkconfig b/ports/espressif/boards/unexpectedmaker_tinys2/sdkconfig index 8539cb7519..647e33d8f5 100644 --- a/ports/espressif/boards/unexpectedmaker_tinys2/sdkconfig +++ b/ports/espressif/boards/unexpectedmaker_tinys2/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_80M is not set -CONFIG_SPIRAM_SPEED_40M=y -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="UMTinyS2" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/unexpectedmaker_tinys3/board.c b/ports/espressif/boards/unexpectedmaker_tinys3/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/unexpectedmaker_tinys3/board.c +++ b/ports/espressif/boards/unexpectedmaker_tinys3/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/unexpectedmaker_tinys3/mpconfigboard.mk b/ports/espressif/boards/unexpectedmaker_tinys3/mpconfigboard.mk index 716a45b5ca..bf3521ed53 100644 --- a/ports/espressif/boards/unexpectedmaker_tinys3/mpconfigboard.mk +++ b/ports/espressif/boards/unexpectedmaker_tinys3/mpconfigboard.mk @@ -5,9 +5,13 @@ USB_MANUFACTURER = "UnexpectedMaker" IDF_TARGET = esp32s3 +CIRCUITPY_ESP_FLASH_SIZE = 8MB CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 8MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m # CIRCUITPY_BITBANG_NEOPIXEL = 1 diff --git a/ports/espressif/boards/unexpectedmaker_tinys3/sdkconfig b/ports/espressif/boards/unexpectedmaker_tinys3/sdkconfig index 0ac438450d..d08f76926e 100644 --- a/ports/espressif/boards/unexpectedmaker_tinys3/sdkconfig +++ b/ports/espressif/boards/unexpectedmaker_tinys3/sdkconfig @@ -1,41 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y - # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_MODE_OCT is not set -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 - # -# PSRAM clock and cs IO for ESP32S3 +# Component config # -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -# CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set -# end of SPI RAM config - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="UMTinyS3" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/board.c b/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/board.c index 2898f675c8..c49e1b8d45 100644 --- a/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/board.c +++ b/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/board.c @@ -126,12 +126,6 @@ static void display_init(void) { void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ - // Display display_init(); } diff --git a/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/mpconfigboard.mk b/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/mpconfigboard.mk index e65760ec68..64987d2c13 100644 --- a/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/mpconfigboard.mk +++ b/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/mpconfigboard.mk @@ -6,6 +6,10 @@ USB_MANUFACTURER = "Waveshare Electronics" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE=4MB CIRCUITPY_ESP_FLASH_MODE=dio CIRCUITPY_ESP_FLASH_FREQ=80m -CIRCUITPY_ESP_FLASH_SIZE=4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/sdkconfig b/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/sdkconfig index 836fd46764..7c86f9f8e3 100644 --- a/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/sdkconfig +++ b/ports/espressif/boards/waveshare_esp32_s2_pico_lcd/sdkconfig @@ -1,37 +1,15 @@ -CONFIG_ESP32S2_SPIRAM_SUPPORT=y # -# SPI RAM config +# Espressif IoT Development Framework Configuration # -# CONFIG_SPIRAM_TYPE_AUTO is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -# end of SPI RAM config - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 # -# PSRAM clock and cs IO for ESP32S2 +# Component config # -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM clock and cs IO for ESP32S2 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -# CONFIG_SPIRAM_SPEED_26M is not set -# CONFIG_SPIRAM_SPEED_20M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY is not set # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="waveshare" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/waveshare_esp32_s3_pico/board.c b/ports/espressif/boards/waveshare_esp32_s3_pico/board.c index 5031686be4..164430c88c 100644 --- a/ports/espressif/boards/waveshare_esp32_s3_pico/board.c +++ b/ports/espressif/boards/waveshare_esp32_s3_pico/board.c @@ -25,16 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} - // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/waveshare_esp32_s3_pico/mpconfigboard.h b/ports/espressif/boards/waveshare_esp32_s3_pico/mpconfigboard.h index dfec09b8aa..4a12ffacf4 100644 --- a/ports/espressif/boards/waveshare_esp32_s3_pico/mpconfigboard.h +++ b/ports/espressif/boards/waveshare_esp32_s3_pico/mpconfigboard.h @@ -31,7 +31,8 @@ #define MICROPY_HW_NEOPIXEL (&pin_GPIO21) -#define CIRCUITPY_BOOT_BUTTON (&pin_GPIO0) - #define DEFAULT_UART_BUS_RX (&pin_GPIO12) #define DEFAULT_UART_BUS_TX (&pin_GPIO11) + +#define DEFAULT_I2C_BUS_SCL (&pin_GPIO18) +#define DEFAULT_I2C_BUS_SDA (&pin_GPIO17) diff --git a/ports/espressif/boards/waveshare_esp32_s3_pico/mpconfigboard.mk b/ports/espressif/boards/waveshare_esp32_s3_pico/mpconfigboard.mk index 116a998b74..76b6eb2206 100644 --- a/ports/espressif/boards/waveshare_esp32_s3_pico/mpconfigboard.mk +++ b/ports/espressif/boards/waveshare_esp32_s3_pico/mpconfigboard.mk @@ -8,3 +8,7 @@ IDF_TARGET = esp32s3 CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 16MB + +CIRCUITPY_ESP_PSRAM_SIZE = 2MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 80m diff --git a/ports/espressif/boards/waveshare_esp32_s3_pico/pins.c b/ports/espressif/boards/waveshare_esp32_s3_pico/pins.c index 884f4cf9e5..fd74d517ea 100644 --- a/ports/espressif/boards/waveshare_esp32_s3_pico/pins.c +++ b/ports/espressif/boards/waveshare_esp32_s3_pico/pins.c @@ -34,18 +34,15 @@ STATIC const mp_rom_map_elem_t board_module_globals_table[] = { { 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_NEOPIXEL), MP_ROM_PTR(&pin_GPIO21) }, { MP_ROM_QSTR(MP_QSTR_TX), MP_ROM_PTR(&pin_GPIO11) }, { MP_ROM_QSTR(MP_QSTR_RX), MP_ROM_PTR(&pin_GPIO12) }, + { MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_GPIO18) }, + { MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_GPIO17) }, + + { MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&board_i2c_obj) }, { MP_ROM_QSTR(MP_QSTR_UART), MP_ROM_PTR(&board_uart_obj) }, - - - - - }; MP_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table); diff --git a/ports/espressif/boards/waveshare_esp32_s3_pico/sdkconfig b/ports/espressif/boards/waveshare_esp32_s3_pico/sdkconfig index 3e366f0172..f5ef797681 100644 --- a/ports/espressif/boards/waveshare_esp32_s3_pico/sdkconfig +++ b/ports/espressif/boards/waveshare_esp32_s3_pico/sdkconfig @@ -1,43 +1,9 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_SPIRAM_SUPPORT=y -# -# SPI RAM config -# -CONFIG_SPIRAM_MODE_QUAD=y -# CONFIG_SPIRAM_MODE_OCT is not set -# CONFIG_SPIRAM_TYPE_AUTO is not set -CONFIG_SPIRAM_TYPE_ESPPSRAM16=y -# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set -# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set -CONFIG_SPIRAM_SIZE=2097152 -# -# PSRAM Clock and CS IO for ESP32S3 -# -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -# end of PSRAM Clock and CS IO for ESP32S3 - -# CONFIG_SPIRAM_FETCH_INSTRUCTIONS is not set -# CONFIG_SPIRAM_RODATA is not set -# CONFIG_SPIRAM_SPEED_120M is not set -CONFIG_SPIRAM_SPEED_80M=y -# CONFIG_SPIRAM_SPEED_40M is not set -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -# CONFIG_SPIRAM_IGNORE_NOTFOUND is not set -CONFIG_SPIRAM_USE_MEMMAP=y -# CONFIG_SPIRAM_USE_CAPS_ALLOC is not set -# CONFIG_SPIRAM_USE_MALLOC is not set -CONFIG_SPIRAM_MEMTEST=y -# end of SPI RAM config - -# end of ESP32S3-Specific - # # LWIP # @@ -45,3 +11,5 @@ CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" # end of LWIP # end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/waveshare_esp32s2_pico/board.c b/ports/espressif/boards/waveshare_esp32s2_pico/board.c index b3c8cb4191..164430c88c 100644 --- a/ports/espressif/boards/waveshare_esp32s2_pico/board.c +++ b/ports/espressif/boards/waveshare_esp32s2_pico/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif /* DEBUG */ -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/waveshare_esp32s2_pico/mpconfigboard.mk b/ports/espressif/boards/waveshare_esp32s2_pico/mpconfigboard.mk index 2db911fb26..e845f33327 100644 --- a/ports/espressif/boards/waveshare_esp32s2_pico/mpconfigboard.mk +++ b/ports/espressif/boards/waveshare_esp32s2_pico/mpconfigboard.mk @@ -5,6 +5,10 @@ USB_MANUFACTURER = "Waveshare Electronics" IDF_TARGET = esp32s2 +CIRCUITPY_ESP_FLASH_SIZE = 4MB CIRCUITPY_ESP_FLASH_MODE = qio CIRCUITPY_ESP_FLASH_FREQ = 80m -CIRCUITPY_ESP_FLASH_SIZE = 4MB + +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = qio +CIRCUITPY_ESP_PSRAM_FREQ = 120m diff --git a/ports/espressif/boards/waveshare_esp32s2_pico/sdkconfig b/ports/espressif/boards/waveshare_esp32s2_pico/sdkconfig index c81fbb4837..7c86f9f8e3 100644 --- a/ports/espressif/boards/waveshare_esp32s2_pico/sdkconfig +++ b/ports/espressif/boards/waveshare_esp32s2_pico/sdkconfig @@ -1,20 +1,15 @@ # -# SPI RAM config +# Espressif IoT Development Framework Configuration +# +# +# Component config # -CONFIG_ESP32S2_SPIRAM_SUPPORT=y -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_MODE_QUAD=y -CONFIG_SPIRAM_SIZE=8388608 -CONFIG_SPIRAM_SPEED_120M=y -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_USE_MEMMAP=y -CONFIG_SPIRAM_MEMTEST=y - # # LWIP # CONFIG_LWIP_LOCAL_HOSTNAME="waveshare" # end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/yd_esp32_s3_n16r8/board.c b/ports/espressif/boards/yd_esp32_s3_n16r8/board.c index e218345f59..70ff11b067 100644 --- a/ports/espressif/boards/yd_esp32_s3_n16r8/board.c +++ b/ports/espressif/boards/yd_esp32_s3_n16r8/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/yd_esp32_s3_n16r8/mpconfigboard.mk b/ports/espressif/boards/yd_esp32_s3_n16r8/mpconfigboard.mk index 2120ba97cb..be875cd895 100644 --- a/ports/espressif/boards/yd_esp32_s3_n16r8/mpconfigboard.mk +++ b/ports/espressif/boards/yd_esp32_s3_n16r8/mpconfigboard.mk @@ -9,5 +9,9 @@ CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 16MB +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m + # Include these Python libraries in firmware. FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/espressif/boards/yd_esp32_s3_n16r8/sdkconfig b/ports/espressif/boards/yd_esp32_s3_n16r8/sdkconfig index 5aff7f49b1..f5ef797681 100644 --- a/ports/espressif/boards/yd_esp32_s3_n16r8/sdkconfig +++ b/ports/espressif/boards/yd_esp32_s3_n16r8/sdkconfig @@ -1,16 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y - -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -CONFIG_SPIRAM_MODE_OCT=y -CONFIG_SPIRAM_SPEED_80M=y - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 - -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_USE_MEMMAP=y -CONFIG_SPIRAM_MEMTEST=y - +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# LWIP +# CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/boards/yd_esp32_s3_n8r8/board.c b/ports/espressif/boards/yd_esp32_s3_n8r8/board.c index e218345f59..70ff11b067 100644 --- a/ports/espressif/boards/yd_esp32_s3_n8r8/board.c +++ b/ports/espressif/boards/yd_esp32_s3_n8r8/board.c @@ -25,15 +25,5 @@ */ #include "supervisor/board.h" -#include "mpconfigboard.h" -#include "shared-bindings/microcontroller/Pin.h" - -void board_init(void) { - // Debug UART - #ifdef DEBUG - common_hal_never_reset_pin(&pin_GPIO43); - common_hal_never_reset_pin(&pin_GPIO44); - #endif -} // Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here. diff --git a/ports/espressif/boards/yd_esp32_s3_n8r8/mpconfigboard.mk b/ports/espressif/boards/yd_esp32_s3_n8r8/mpconfigboard.mk index 766e71dc2d..6ff5cada7c 100644 --- a/ports/espressif/boards/yd_esp32_s3_n8r8/mpconfigboard.mk +++ b/ports/espressif/boards/yd_esp32_s3_n8r8/mpconfigboard.mk @@ -9,5 +9,9 @@ CIRCUITPY_ESP_FLASH_MODE = dio CIRCUITPY_ESP_FLASH_FREQ = 80m CIRCUITPY_ESP_FLASH_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_SIZE = 8MB +CIRCUITPY_ESP_PSRAM_MODE = opi +CIRCUITPY_ESP_PSRAM_FREQ = 80m + # Include these Python libraries in firmware. FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/espressif/boards/yd_esp32_s3_n8r8/sdkconfig b/ports/espressif/boards/yd_esp32_s3_n8r8/sdkconfig index 5aff7f49b1..f5ef797681 100644 --- a/ports/espressif/boards/yd_esp32_s3_n8r8/sdkconfig +++ b/ports/espressif/boards/yd_esp32_s3_n8r8/sdkconfig @@ -1,16 +1,15 @@ -CONFIG_ESP32S3_SPIRAM_SUPPORT=y - -CONFIG_SPIRAM_TYPE_ESPPSRAM64=y -CONFIG_SPIRAM_SIZE=8388608 -CONFIG_SPIRAM_MODE_OCT=y -CONFIG_SPIRAM_SPEED_80M=y - -CONFIG_DEFAULT_PSRAM_CLK_IO=30 -CONFIG_DEFAULT_PSRAM_CS_IO=26 - -CONFIG_SPIRAM=y -CONFIG_SPIRAM_BOOT_INIT=y -CONFIG_SPIRAM_USE_MEMMAP=y -CONFIG_SPIRAM_MEMTEST=y - +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# LWIP +# CONFIG_LWIP_LOCAL_HOSTNAME="espressif-esp32s3" +# end of LWIP + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/common-hal/_bleio/Adapter.c b/ports/espressif/common-hal/_bleio/Adapter.c index 24452993cb..b03bf7c439 100644 --- a/ports/espressif/common-hal/_bleio/Adapter.c +++ b/ports/espressif/common-hal/_bleio/Adapter.c @@ -95,7 +95,6 @@ void common_hal_bleio_adapter_set_enabled(bleio_adapter_obj_t *self, bool enable } if (enabled) { - esp_nimble_hci_and_controller_init(); nimble_port_init(); // ble_hs_cfg.reset_cb = blecent_on_reset; ble_hs_cfg.sync_cb = _on_sync; diff --git a/ports/espressif/common-hal/alarm/SleepMemory.h b/ports/espressif/common-hal/alarm/SleepMemory.h index 626f748a67..68e9a7d1a6 100644 --- a/ports/espressif/common-hal/alarm/SleepMemory.h +++ b/ports/espressif/common-hal/alarm/SleepMemory.h @@ -41,7 +41,11 @@ // is set. Any memory not allocated by us can be used by the ESP-IDF for heap or other purposes. // Use half of RTC_SLOW_MEM or RTC_FAST_MEM. -#define SLEEP_MEMORY_LENGTH (4096) +#ifdef CONFIG_IDF_TARGET_ESP32 +#define SLEEP_MEMORY_LENGTH (3 * 1024) +#else +#define SLEEP_MEMORY_LENGTH (4 * 1024) +#endif typedef struct { mp_obj_base_t base; diff --git a/ports/espressif/common-hal/alarm/__init__.c b/ports/espressif/common-hal/alarm/__init__.c index 6fa205d01f..6590bcc8e4 100644 --- a/ports/espressif/common-hal/alarm/__init__.c +++ b/ports/espressif/common-hal/alarm/__init__.c @@ -51,8 +51,8 @@ #include "esp_sleep.h" #include "soc/rtc_cntl_reg.h" -#include "components/driver/include/driver/gpio.h" -#include "components/driver/include/driver/uart.h" +#include "components/driver/gpio/include/driver/gpio.h" +#include "components/driver/uart/include/driver/uart.h" // Singleton instance of SleepMemory. const alarm_sleep_memory_obj_t alarm_sleep_memory_obj = { @@ -213,6 +213,8 @@ void NORETURN common_hal_alarm_enter_deep_sleep(void) { // The ESP-IDF caches the deep sleep settings and applies them before sleep. // We don't need to worry about resetting them in the interim. esp_deep_sleep_start(); + + reset_into_safe_mode(SAFE_MODE_HARD_FAULT); } void common_hal_alarm_gc_collect(void) { diff --git a/ports/espressif/common-hal/alarm/pin/PinAlarm.c b/ports/espressif/common-hal/alarm/pin/PinAlarm.c index 6db184a4dd..7d35b66d0c 100644 --- a/ports/espressif/common-hal/alarm/pin/PinAlarm.c +++ b/ports/espressif/common-hal/alarm/pin/PinAlarm.c @@ -36,8 +36,8 @@ #include "hal/gpio_ll.h" #include "esp_debug_helpers.h" -#include "components/driver/include/driver/rtc_io.h" -#include "components/freertos/include/freertos/FreeRTOS.h" +#include "driver/rtc_io.h" +#include "freertos/FreeRTOS.h" void common_hal_alarm_pin_pinalarm_construct(alarm_pin_pinalarm_obj_t *self, const mcu_pin_obj_t *pin, bool value, bool edge, bool pull) { if (edge) { diff --git a/ports/espressif/common-hal/analogbufio/BufferedIn.c b/ports/espressif/common-hal/analogbufio/BufferedIn.c index 9dd66bc9da..47942c7c33 100644 --- a/ports/espressif/common-hal/analogbufio/BufferedIn.c +++ b/ports/espressif/common-hal/analogbufio/BufferedIn.c @@ -28,6 +28,7 @@ */ #include +#include "bindings/espidf/__init__.h" #include "common-hal/analogbufio/BufferedIn.h" #include "shared-bindings/analogbufio/BufferedIn.h" #include "shared-bindings/microcontroller/Pin.h" @@ -39,7 +40,6 @@ #include "freertos/FreeRTOS.h" #include "freertos/task.h" #include "freertos/semphr.h" -#include "driver/adc.h" // #define DEBUG_ANALOGBUFIO @@ -56,12 +56,14 @@ #elif defined(CONFIG_IDF_TARGET_ESP32S2) #define ADC_RESULT_BYTE 2 #define ADC_CONV_LIMIT_EN 0 -#elif defined(CONFIG_IDF_TARGET_ESP32C3) || defined(CONFIG_IDF_TARGET_ESP32H2) +#elif defined(CONFIG_IDF_TARGET_ESP32C3) || defined(CONFIG_IDF_TARGET_ESP32C6) || defined(CONFIG_IDF_TARGET_ESP32H2) #define ADC_RESULT_BYTE 4 #define ADC_CONV_LIMIT_EN 0 #elif defined(CONFIG_IDF_TARGET_ESP32S3) #define ADC_RESULT_BYTE 4 #define ADC_CONV_LIMIT_EN 0 +#else +#error No known CONFIG_IDF_TARGET_xxx found #endif static void start_dma(analogbufio_bufferedin_obj_t *self, adc_digi_convert_mode_t *convert_mode, adc_digi_output_format_t *output_format); @@ -70,35 +72,10 @@ static void stop_dma(analogbufio_bufferedin_obj_t *self); void common_hal_analogbufio_bufferedin_construct(analogbufio_bufferedin_obj_t *self, const mcu_pin_obj_t *pin, uint32_t sample_rate) { self->pin = pin; self->sample_rate = sample_rate; -} - -static void start_dma(analogbufio_bufferedin_obj_t *self, adc_digi_convert_mode_t *convert_mode, adc_digi_output_format_t *output_format) { - uint16_t adc1_chan_mask = 0; - uint16_t adc2_chan_mask = 0; - - const mcu_pin_obj_t *pin = self->pin; - uint32_t sample_rate = self->sample_rate; - - *output_format = ADC_DIGI_OUTPUT_FORMAT_TYPE1; - if (pin->adc_index == ADC_UNIT_1) { - *convert_mode = ADC_CONV_SINGLE_UNIT_1; - } else { - *convert_mode = ADC_CONV_SINGLE_UNIT_2; - } - if (pin->adc_index == NO_ADC || pin->adc_channel == NO_ADC_CHANNEL) { raise_ValueError_invalid_pin(); } - /* - * Chip version Conversion Mode Output Format Type - * ESP32 1 TYPE1 - * ESP32S2 1,2,BOTH,ALTER TYPE1, TYPE2 - * ESP32C3 ALTER TYPE2 - * ESP32S3 1,2,BOTH,ALTER TYPE2 - * ESP32H3 1,2,BOTH,ALTER TYPE2 - */ - #if defined(CONFIG_IDF_TARGET_ESP32) if (pin->adc_index != ADC_UNIT_1) { /* @@ -110,6 +87,36 @@ static void start_dma(analogbufio_bufferedin_obj_t *self, adc_digi_convert_mode_ } #endif + // C3 and S3 have errata related to ADC2 and continuous mode. + #if (defined(CONFIG_IDF_TARGET_ESP32C3) || defined(CONFIG_IDF_TARGET_ESP32S3)) && !defined(CONFIG_ADC_CONTINUOUS_FORCE_USE_ADC2_ON_C3_S3) + if (pin->adc_index != ADC_UNIT_1) { + raise_ValueError_invalid_pin(); + } + #endif + + common_hal_mcu_pin_claim(pin); +} + +static void start_dma(analogbufio_bufferedin_obj_t *self, adc_digi_convert_mode_t *convert_mode, adc_digi_output_format_t *output_format) { + const mcu_pin_obj_t *pin = self->pin; + uint32_t sample_rate = self->sample_rate; + + *output_format = ADC_DIGI_OUTPUT_FORMAT_TYPE1; + if (pin->adc_index == ADC_UNIT_1) { + *convert_mode = ADC_CONV_SINGLE_UNIT_1; + } else { + *convert_mode = ADC_CONV_SINGLE_UNIT_2; + } + + /* + * Chip version Conversion Mode Output Format Type + * ESP32 1 TYPE1 + * ESP32S2 1,2,BOTH,ALTER TYPE1, TYPE2 + * ESP32C3 ALTER TYPE2 + * ESP32S3 1,2,BOTH,ALTER TYPE2 + * ESP32H3 1,2,BOTH,ALTER TYPE2 + */ + #if defined(CONFIG_IDF_TARGET_ESP32C3) /* ESP32C3 only supports alter mode */ *convert_mode = ADC_CONV_ALTER_UNIT; @@ -119,34 +126,21 @@ static void start_dma(analogbufio_bufferedin_obj_t *self, adc_digi_convert_mode_ *output_format = ADC_DIGI_OUTPUT_FORMAT_TYPE2; #endif - common_hal_mcu_pin_claim(pin); - - if (pin->adc_index == ADC_UNIT_1) { - adc1_chan_mask = 1 << pin->adc_channel; - } else { - adc2_chan_mask = 1 << pin->adc_channel; - } - - adc_digi_init_config_t adc_dma_config = { + adc_continuous_handle_cfg_t adc_dma_config = { .max_store_buf_size = DMA_BUFFER_SIZE, - .conv_num_each_intr = NUM_SAMPLES_PER_INTERRUPT, - .adc1_chan_mask = adc1_chan_mask, - .adc2_chan_mask = adc2_chan_mask, + .conv_frame_size = NUM_SAMPLES_PER_INTERRUPT * SOC_ADC_DIGI_DATA_BYTES_PER_CONV }; #if defined(DEBUG_ANALOGBUFIO) mp_printf(&mp_plat_print, "pin:%d, ADC channel:%d, ADC index:%d, adc1_chan_mask:0x%x, adc2_chan_mask:0x%x\n", pin->number, pin->adc_channel, pin->adc_index, adc1_chan_mask, adc2_chan_mask); #endif // DEBUG_ANALOGBUFIO - esp_err_t err = adc_digi_initialize(&adc_dma_config); + esp_err_t err = adc_continuous_new_handle(&adc_dma_config, &self->handle); if (ESP_OK != err) { stop_dma(self); - common_hal_analogbufio_bufferedin_deinit(self); - mp_raise_ValueError_varg(translate("Unable to initialize ADC DMA controller, ErrorCode:%d"), err); + CHECK_ESP_RESULT(err); } - adc_digi_configuration_t dig_cfg = { - .conv_limit_en = ADC_CONV_LIMIT_EN, - .conv_limit_num = 250, + adc_continuous_config_t dig_cfg = { .pattern_num = NUM_ADC_CHANNELS, .sample_freq_hz = sample_rate, .conv_mode = *convert_mode, @@ -172,25 +166,28 @@ static void start_dma(analogbufio_bufferedin_obj_t *self, adc_digi_convert_mode_ mp_printf(&mp_plat_print, "adc_pattern[0].channel:%d, adc_pattern[0].unit:%d, adc_pattern[0].atten:%d\n", adc_pattern[0].channel, adc_pattern[0].unit, adc_pattern[0].atten); #endif // DEBUG_ANALOGBUFIO - err = adc_digi_controller_configure(&dig_cfg); + err = adc_continuous_config(self->handle, &dig_cfg); if (ESP_OK != err) { stop_dma(self); - common_hal_analogbufio_bufferedin_deinit(self); - mp_raise_ValueError_varg(translate("Unable to configure ADC DMA controller, ErrorCode:%d"), err); + CHECK_ESP_RESULT(err); } - err = adc_digi_start(); + err = adc_continuous_start(self->handle); if (ESP_OK != err) { stop_dma(self); - common_hal_analogbufio_bufferedin_deinit(self); - mp_raise_ValueError_varg(translate("Unable to start ADC DMA controller, ErrorCode:%d"), err); + CHECK_ESP_RESULT(err); } + self->started = true; } static void stop_dma(analogbufio_bufferedin_obj_t *self) { - adc_digi_stop(); - adc_digi_deinitialize(); - // Release ADC Pin - reset_pin_number(self->pin->number); + if (self->started) { + adc_continuous_stop(self->handle); + self->started = false; + } + if (self->handle != NULL) { + adc_continuous_deinit(self->handle); + self->handle = NULL; + } } bool common_hal_analogbufio_bufferedin_deinited(analogbufio_bufferedin_obj_t *self) { @@ -201,11 +198,18 @@ void common_hal_analogbufio_bufferedin_deinit(analogbufio_bufferedin_obj_t *self if (common_hal_analogbufio_bufferedin_deinited(self)) { return; } + // Release ADC Pin + reset_pin_number(self->pin->number); self->pin = NULL; } static bool check_valid_data(const adc_digi_output_data_t *data, const mcu_pin_obj_t *pin, adc_digi_convert_mode_t convert_mode, adc_digi_output_format_t output_format) { - unsigned int unit = data->type2.unit; + unsigned int unit; + #if SOC_ADC_PERIPH_NUM == 1 + unit = 0; + #else + unit = data->type2.unit; + #endif if (output_format == ADC_DIGI_OUTPUT_FORMAT_TYPE2) { if (data->type2.channel >= SOC_ADC_CHANNEL_NUM(unit)) { return false; @@ -235,7 +239,7 @@ static bool check_valid_data(const adc_digi_output_data_t *data, const mcu_pin_o } uint32_t common_hal_analogbufio_bufferedin_readinto(analogbufio_bufferedin_obj_t *self, uint8_t *buffer, uint32_t len, uint8_t bytes_per_sample) { - uint8_t result[NUM_SAMPLES_PER_INTERRUPT] __attribute__ ((aligned(4))) = {0}; + uint8_t result[NUM_SAMPLES_PER_INTERRUPT * SOC_ADC_DIGI_DATA_BYTES_PER_CONV] __attribute__ ((aligned(4))) = {0}; uint32_t captured_samples = 0; uint32_t captured_bytes = 0; esp_err_t ret; @@ -256,7 +260,7 @@ uint32_t common_hal_analogbufio_bufferedin_readinto(analogbufio_bufferedin_obj_t while (captured_bytes < len) { ret_num = 0; - ret = adc_digi_read_bytes(result, NUM_SAMPLES_PER_INTERRUPT, &ret_num, ADC_READ_TIMEOUT_MS); + ret = adc_continuous_read(self->handle, result, NUM_SAMPLES_PER_INTERRUPT * SOC_ADC_DIGI_DATA_BYTES_PER_CONV, &ret_num, ADC_READ_TIMEOUT_MS); if (ret == ESP_OK) { for (uint32_t i = 0; i < ret_num; i += ADC_RESULT_BYTE) { diff --git a/ports/espressif/common-hal/analogbufio/BufferedIn.h b/ports/espressif/common-hal/analogbufio/BufferedIn.h index 909455ca06..8e0695c57d 100644 --- a/ports/espressif/common-hal/analogbufio/BufferedIn.h +++ b/ports/espressif/common-hal/analogbufio/BufferedIn.h @@ -32,11 +32,15 @@ #include "common-hal/microcontroller/Pin.h" #include "py/obj.h" +#include "components/esp_adc/include/esp_adc/adc_continuous.h" + // This is the analogbufio object typedef struct { mp_obj_base_t base; const mcu_pin_obj_t *pin; uint32_t sample_rate; + adc_continuous_handle_t handle; + bool started; } analogbufio_bufferedin_obj_t; #endif // MICROPY_INCLUDED_ESP32_COMMON_HAL_ANALOGBUFIO_BUFFEREDIN_H diff --git a/ports/espressif/common-hal/analogio/AnalogIn.c b/ports/espressif/common-hal/analogio/AnalogIn.c index fb2e098cb4..ea322690f7 100644 --- a/ports/espressif/common-hal/analogio/AnalogIn.c +++ b/ports/espressif/common-hal/analogio/AnalogIn.c @@ -25,13 +25,18 @@ */ #include "common-hal/analogio/AnalogIn.h" + +#include "bindings/espidf/__init__.h" #include "shared-bindings/analogio/AnalogIn.h" #include "py/mperrno.h" #include "py/runtime.h" #include "supervisor/shared/translate/translate.h" -#include "components/driver/include/driver/adc_common.h" -#include "components/esp_adc_cal/include/esp_adc_cal.h" +#include "adc_cali_schemes.h" +#include "esp_adc/adc_oneshot.h" +#include "esp_adc/adc_cali.h" +#include "driver/gpio.h" +#include "hal/adc_types.h" #include "shared-bindings/microcontroller/Pin.h" @@ -41,20 +46,24 @@ #define NO_OF_SAMPLES 2 #define ATTENUATION ADC_ATTEN_DB_11 #if defined(CONFIG_IDF_TARGET_ESP32) -#define DATA_WIDTH ADC_WIDTH_BIT_12 +#define DATA_WIDTH ADC_BITWIDTH_12 #elif defined(CONFIG_IDF_TARGET_ESP32C3) -#define DATA_WIDTH ADC_WIDTH_BIT_12 +#define DATA_WIDTH ADC_BITWIDTH_12 +#elif defined(CONFIG_IDF_TARGET_ESP32C6) +#define DATA_WIDTH ADC_BITWIDTH_12 #elif defined(CONFIG_IDF_TARGET_ESP32S2) -#define DATA_WIDTH ADC_WIDTH_BIT_13 +#define DATA_WIDTH ADC_BITWIDTH_13 #elif defined(CONFIG_IDF_TARGET_ESP32S3) -#define DATA_WIDTH ADC_WIDTH_BIT_12 +#define DATA_WIDTH ADC_BITWIDTH_12 +#elif defined(CONFIG_IDF_TARGET_ESP32H2) +#define DATA_WIDTH ADC_BITWIDTH_12 #else #error No known CONFIG_IDF_TARGET_xxx found #endif void common_hal_analogio_analogin_construct(analogio_analogin_obj_t *self, const mcu_pin_obj_t *pin) { - if (pin->adc_index == 0 || pin->adc_channel == ADC_CHANNEL_MAX) { + if (pin->adc_index == 0 || pin->adc_channel == NO_ADC_CHANNEL) { raise_ValueError_invalid_pin(); } common_hal_mcu_pin_claim(pin); @@ -78,38 +87,86 @@ void common_hal_analogio_analogin_deinit(analogio_analogin_obj_t *self) { } uint16_t common_hal_analogio_analogin_get_value(analogio_analogin_obj_t *self) { - if (self->pin->adc_index == ADC_UNIT_1) { - adc1_config_width(DATA_WIDTH); - adc1_config_channel_atten((adc1_channel_t)self->pin->adc_channel, ATTENUATION); - } else if (self->pin->adc_index == ADC_UNIT_2) { - adc2_config_channel_atten((adc2_channel_t)self->pin->adc_channel, ATTENUATION); - } else { - raise_ValueError_invalid_pin(); + adc_oneshot_unit_handle_t adc_handle; + adc_oneshot_unit_init_cfg_t adc_config = { + .unit_id = self->pin->adc_index, + .ulp_mode = ADC_ULP_MODE_DISABLE + }; + cp_check_esp_error(adc_oneshot_new_unit(&adc_config, &adc_handle)); + + adc_oneshot_chan_cfg_t channel_config = { + .atten = ATTENUATION, + .bitwidth = DATA_WIDTH + }; + adc_channel_t channel = (adc_channel_t)self->pin->adc_channel; + adc_oneshot_config_channel(adc_handle, channel, &channel_config); + + adc_cali_scheme_ver_t supported_schemes; + adc_cali_check_scheme(&supported_schemes); + adc_cali_scheme_ver_t calibration_scheme = 0; + adc_cali_handle_t calibration; + + #if defined(ADC_CALI_SCHEME_CURVE_FITTING_SUPPORTED) && ADC_CALI_SCHEME_CURVE_FITTING_SUPPORTED + adc_cali_curve_fitting_config_t config = { + .unit_id = self->pin->adc_index, + .chan = channel, + .atten = ATTENUATION, + .bitwidth = DATA_WIDTH + }; + if (adc_cali_create_scheme_curve_fitting(&config, &calibration) == ESP_OK) { + calibration_scheme = ADC_CALI_SCHEME_VER_CURVE_FITTING; } - - // Automatically select calibration process depending on status of efuse - esp_adc_cal_characteristics_t adc_chars; - memset(&adc_chars, 0, sizeof(adc_chars)); - esp_adc_cal_characterize(self->pin->adc_index, ATTENUATION, DATA_WIDTH, DEFAULT_VREF, &adc_chars); - - uint32_t adc_reading = 0; - // Multisampling - for (int i = 0; i < NO_OF_SAMPLES; i++) { - if (self->pin->adc_index == ADC_UNIT_1) { - adc_reading += adc1_get_raw((adc1_channel_t)self->pin->adc_channel); - } else { - int raw; - esp_err_t r = adc2_get_raw((adc2_channel_t)self->pin->adc_channel, DATA_WIDTH, &raw); - if (r != ESP_OK) { - mp_raise_ValueError(translate("ADC2 is being used by WiFi")); - } - adc_reading += raw; + #endif + #if defined(ADC_CALI_SCHEME_LINE_FITTING_SUPPORTED) && ADC_CALI_SCHEME_LINE_FITTING_SUPPORTED + if (calibration_scheme == 0) { + adc_cali_line_fitting_config_t config = { + .unit_id = self->pin->adc_index, + .atten = ATTENUATION, + .bitwidth = DATA_WIDTH, + #ifdef CONFIG_IDF_TARGET_ESP32 + .default_vref = DEFAULT_VREF, + #endif + }; + if (adc_cali_create_scheme_line_fitting(&config, &calibration) == ESP_OK) { + calibration_scheme = ADC_CALI_SCHEME_VER_LINE_FITTING; } } - adc_reading /= NO_OF_SAMPLES; + #endif + + uint32_t adc_reading = 0; + size_t sample_count = 0; + // Multisampling + esp_err_t ret = ESP_OK; + for (int i = 0; i < NO_OF_SAMPLES; i++) { + int raw; + ret = adc_oneshot_read(adc_handle, channel, &raw); + if (ret != ESP_OK) { + continue; + } + adc_reading += raw; + sample_count += 1; + } + if (sample_count == 0) { + raise_esp_error(ret); + } + adc_reading /= sample_count; // This corrects non-linear regions of the ADC range with a LUT, so it's a better reading than raw - uint32_t voltage = esp_adc_cal_raw_to_voltage(adc_reading, &adc_chars); + int voltage; + adc_cali_raw_to_voltage(calibration, adc_reading, &voltage); + + + #if defined(ADC_CALI_SCHEME_CURVE_FITTING_SUPPORTED) && ADC_CALI_SCHEME_CURVE_FITTING_SUPPORTED + if (calibration_scheme == ADC_CALI_SCHEME_VER_CURVE_FITTING) { + adc_cali_delete_scheme_curve_fitting(calibration); + } + #endif + #if defined(ADC_CALI_SCHEME_LINE_FITTING_SUPPORTED) && ADC_CALI_SCHEME_LINE_FITTING_SUPPORTED + if (calibration_scheme == ADC_CALI_SCHEME_VER_LINE_FITTING) { + adc_cali_delete_scheme_line_fitting(calibration); + } + #endif + adc_oneshot_del_unit(adc_handle); return voltage * ((1 << 16) - 1) / 3300; } diff --git a/ports/espressif/common-hal/analogio/AnalogOut.c b/ports/espressif/common-hal/analogio/AnalogOut.c index 1a1e74391b..b2bf7294f1 100644 --- a/ports/espressif/common-hal/analogio/AnalogOut.c +++ b/ports/espressif/common-hal/analogio/AnalogOut.c @@ -35,63 +35,71 @@ #include "shared-bindings/microcontroller/Pin.h" #include "supervisor/shared/translate/translate.h" -#if defined(CONFIG_IDF_TARGET_ESP32) || defined(CONFIG_IDF_TARGET_ESP32S2) -#include "components/driver/include/driver/dac_common.h" -#define HAS_DAC 1 +#ifdef SOC_DAC_SUPPORTED +#include "driver/dac_oneshot.h" + #if defined(CONFIG_IDF_TARGET_ESP32) -#define pin_CHANNEL_1 pin_GPIO25 -#define pin_CHANNEL_2 pin_GPIO26 +#define pin_CHANNEL_0 pin_GPIO25 +#define pin_CHANNEL_1 pin_GPIO26 #elif defined(CONFIG_IDF_TARGET_ESP32S2) -#define pin_CHANNEL_1 pin_GPIO17 -#define pin_CHANNEL_2 pin_GPIO18 +#define pin_CHANNEL_0 pin_GPIO17 +#define pin_CHANNEL_1 pin_GPIO18 #endif -#else -#define HAS_DAC 0 +static dac_oneshot_handle_t _active_handles[SOC_DAC_CHAN_NUM]; #endif + void common_hal_analogio_analogout_construct(analogio_analogout_obj_t *self, const mcu_pin_obj_t *pin) { - #if HAS_DAC - if (pin == &pin_CHANNEL_1) { - self->channel = DAC_CHANNEL_1; - } else if (pin == &pin_CHANNEL_2) { - self->channel = DAC_CHANNEL_2; + #ifdef SOC_DAC_SUPPORTED + if (pin == &pin_CHANNEL_0) { + self->channel = DAC_CHAN_0; + } else if (pin == &pin_CHANNEL_1) { + self->channel = DAC_CHAN_1; } else { raise_ValueError_invalid_pin(); } - dac_output_enable(self->channel); + dac_oneshot_config_t config = { + .chan_id = self->channel + }; + dac_oneshot_new_channel(&config, &self->handle); + _active_handles[self->channel] = self->handle; #else mp_raise_NotImplementedError(NULL); #endif } bool common_hal_analogio_analogout_deinited(analogio_analogout_obj_t *self) { - #if HAS_DAC - return self->channel == DAC_CHANNEL_MAX; + #ifdef SOC_DAC_SUPPORTED + return self->handle == NULL; #else return false; #endif } void common_hal_analogio_analogout_deinit(analogio_analogout_obj_t *self) { - #if HAS_DAC - dac_output_disable(self->channel); - self->channel = DAC_CHANNEL_MAX; + #ifdef SOC_DAC_SUPPORTED + dac_oneshot_del_channel(self->handle); + self->handle = NULL; + _active_handles[self->channel] = NULL; #endif } void common_hal_analogio_analogout_set_value(analogio_analogout_obj_t *self, uint16_t value) { - #if HAS_DAC + #ifdef SOC_DAC_SUPPORTED uint8_t dac_value = (value * 255) / 65535; - dac_output_enable(self->channel); - dac_output_voltage(self->channel, dac_value); + dac_oneshot_output_voltage(self->handle, dac_value); #endif } void analogout_reset(void) { - #if HAS_DAC - dac_output_disable(DAC_CHANNEL_1); - dac_output_disable(DAC_CHANNEL_2); + #ifdef SOC_DAC_SUPPORTED + for (uint8_t c = 0; c < SOC_DAC_CHAN_NUM; c++) { + if (_active_handles[c] != NULL) { + dac_oneshot_del_channel(_active_handles[c]); + } + _active_handles[c] = NULL; + } #endif } diff --git a/ports/espressif/common-hal/analogio/AnalogOut.h b/ports/espressif/common-hal/analogio/AnalogOut.h index 085c4e6783..26cdd08675 100644 --- a/ports/espressif/common-hal/analogio/AnalogOut.h +++ b/ports/espressif/common-hal/analogio/AnalogOut.h @@ -30,12 +30,17 @@ #include "common-hal/microcontroller/Pin.h" +#ifdef SOC_DAC_SUPPORTED +#include "esp-idf/components/driver/dac/include/driver/dac_oneshot.h" +#endif #include "py/obj.h" typedef struct { mp_obj_base_t base; - const mcu_pin_obj_t *pin; + #ifdef SOC_DAC_SUPPORTED + dac_oneshot_handle_t handle; uint8_t channel; + #endif } analogio_analogout_obj_t; void analogout_reset(void); diff --git a/ports/espressif/common-hal/audiobusio/I2SOut.c b/ports/espressif/common-hal/audiobusio/I2SOut.c index 8b03a534a4..33e5dd6ac0 100644 --- a/ports/espressif/common-hal/audiobusio/I2SOut.c +++ b/ports/espressif/common-hal/audiobusio/I2SOut.c @@ -44,7 +44,7 @@ #include "shared-bindings/microcontroller/Pin.h" #include "supervisor/shared/translate/translate.h" -#include "driver/i2s.h" +#include "driver/i2s_std.h" // Caller validates that pins are free. void common_hal_audiobusio_i2sout_construct(audiobusio_i2sout_obj_t *self, @@ -53,15 +53,20 @@ void common_hal_audiobusio_i2sout_construct(audiobusio_i2sout_obj_t *self, if (main_clock != NULL) { mp_raise_NotImplementedError_varg(translate("%q"), MP_QSTR_main_clock); } - port_i2s_allocate_init(&self->peripheral, left_justified); + port_i2s_allocate_init(&self->i2s, left_justified); - i2s_pin_config_t i2s_pin_config = { - .bck_io_num = bit_clock->number, - .ws_io_num = word_select->number, - .data_out_num = data->number, - .data_in_num = I2S_PIN_NO_CHANGE, + i2s_std_config_t i2s_config = { + .clk_cfg = I2S_STD_CLK_DEFAULT_CONFIG(48000), + .slot_cfg = I2S_STD_MSB_SLOT_DEFAULT_CONFIG(I2S_DATA_BIT_WIDTH_16BIT, I2S_SLOT_MODE_STEREO), + .gpio_cfg = { + .mclk = I2S_GPIO_UNUSED, + .bclk = bit_clock->number, + .ws = word_select->number, + .dout = data->number, + .din = I2S_GPIO_UNUSED, + } }; - CHECK_ESP_RESULT(i2s_set_pin(self->peripheral.instance, &i2s_pin_config)); + CHECK_ESP_RESULT(i2s_channel_init_std_mode(self->i2s.handle, &i2s_config)); self->bit_clock = bit_clock; self->word_select = word_select; self->data = data; @@ -71,7 +76,7 @@ void common_hal_audiobusio_i2sout_construct(audiobusio_i2sout_obj_t *self, } bool common_hal_audiobusio_i2sout_deinited(audiobusio_i2sout_obj_t *self) { - return self->peripheral.instance == -1; + return self->data == NULL; } void common_hal_audiobusio_i2sout_deinit(audiobusio_i2sout_obj_t *self) { @@ -79,6 +84,10 @@ void common_hal_audiobusio_i2sout_deinit(audiobusio_i2sout_obj_t *self) { return; } + common_hal_audiobusio_i2sout_stop(self); + + port_i2s_deinit(&self->i2s); + if (self->bit_clock) { reset_pin_number(self->bit_clock->number); } @@ -94,10 +103,6 @@ void common_hal_audiobusio_i2sout_deinit(audiobusio_i2sout_obj_t *self) { } self->data = NULL; - if (self->peripheral.instance >= 0) { - port_i2s_reset_instance(self->peripheral.instance); - } - self->peripheral.instance = -1; } void common_hal_audiobusio_i2sout_play(audiobusio_i2sout_obj_t *self, @@ -105,27 +110,27 @@ void common_hal_audiobusio_i2sout_play(audiobusio_i2sout_obj_t *self, if (common_hal_audiobusio_i2sout_get_playing(self)) { common_hal_audiobusio_i2sout_stop(self); } - port_i2s_play(&self->peripheral, sample, loop); + port_i2s_play(&self->i2s, sample, loop); } void common_hal_audiobusio_i2sout_pause(audiobusio_i2sout_obj_t *self) { - port_i2s_pause(&self->peripheral); + port_i2s_pause(&self->i2s); } void common_hal_audiobusio_i2sout_resume(audiobusio_i2sout_obj_t *self) { - port_i2s_resume(&self->peripheral); + port_i2s_resume(&self->i2s); } bool common_hal_audiobusio_i2sout_get_paused(audiobusio_i2sout_obj_t *self) { - return port_i2s_paused(&self->peripheral); + return port_i2s_paused(&self->i2s); } void common_hal_audiobusio_i2sout_stop(audiobusio_i2sout_obj_t *self) { - port_i2s_stop(&self->peripheral); + port_i2s_stop(&self->i2s); } bool common_hal_audiobusio_i2sout_get_playing(audiobusio_i2sout_obj_t *self) { - return port_i2s_playing(&self->peripheral); + return port_i2s_playing(&self->i2s); } #endif // CIRCUITPY_AUDIOBUSIO_I2SOUT diff --git a/ports/espressif/common-hal/audiobusio/I2SOut.h b/ports/espressif/common-hal/audiobusio/I2SOut.h index 891e9af674..48ab26a42e 100644 --- a/ports/espressif/common-hal/audiobusio/I2SOut.h +++ b/ports/espressif/common-hal/audiobusio/I2SOut.h @@ -36,7 +36,7 @@ typedef struct { mp_obj_base_t base; - i2s_t peripheral; + i2s_t i2s; const mcu_pin_obj_t *bit_clock; const mcu_pin_obj_t *word_select; const mcu_pin_obj_t *data; diff --git a/ports/espressif/common-hal/audiobusio/__init__.c b/ports/espressif/common-hal/audiobusio/__init__.c index e58aeefe88..d05e40c772 100644 --- a/ports/espressif/common-hal/audiobusio/__init__.c +++ b/ports/espressif/common-hal/audiobusio/__init__.c @@ -35,70 +35,26 @@ #include "shared-module/audiocore/__init__.h" -#define I2S_QUEUE_SIZE (3) - -static i2s_t *i2s_instance[I2S_NUM_MAX]; -static QueueHandle_t i2s_queues[I2S_NUM_MAX]; -static TaskHandle_t i2s_tasks[I2S_NUM_MAX]; - -void port_i2s_allocate_i2s0(void) { - if (!i2s_instance[0]) { - i2s_instance[0] = (void *)~(intptr_t)0; - return; - } - - mp_raise_RuntimeError(translate("Peripheral in use")); -} - -static int8_t port_i2s_allocate(void) { - #if defined(I2S_NUM_1) - if (!i2s_instance[1]) { - return 1; - } - #endif - if (!i2s_instance[0]) { - return 0; - } - - mp_raise_RuntimeError(translate("Peripheral in use")); -} - -void port_i2s_reset_instance(int i) { - assert(i >= 0 && i < I2S_NUM_MAX); - if (i2s_tasks[i]) { - vTaskDelete(i2s_tasks[i]); - } - i2s_tasks[i] = NULL; - - (void)i2s_driver_uninstall(i); - i2s_instance[i] = NULL; -} - -void i2s_reset(void) { - for (int i = 0; i < I2S_NUM_MAX; i++) { - port_i2s_reset_instance(i); - } -} - -#define I2S_WRITE_DELAY pdMS_TO_TICKS(1) +#define CIRCUITPY_BUFFER_COUNT 3 +#define CIRCUITPY_BUFFER_SIZE 1023 +#define CIRCUITPY_OUTPUT_SLOTS 2 static void i2s_fill_buffer(i2s_t *self) { - if (self->instance < 0 || self->instance >= I2S_NUM_MAX) { + if (self->next_buffer_size == 0) { + // Error, no new buffer queued. return; } -#define STACK_BUFFER_SIZE (4096) - int16_t signed_samples[STACK_BUFFER_SIZE / sizeof(int16_t)]; - + int16_t *output_buffer = (int16_t *)self->next_buffer; + size_t output_buffer_size = self->next_buffer_size; + const size_t bytes_per_output_frame = 4; + size_t bytes_per_input_frame = self->channel_count * self->bytes_per_sample; if (!self->playing || self->paused || !self->sample || self->stopping) { - memset(signed_samples, 0, sizeof(signed_samples)); - - size_t bytes_written = 0; - do { - CHECK_ESP_RESULT(i2s_write(self->instance, signed_samples, sizeof(signed_samples), &bytes_written, I2S_WRITE_DELAY)); - } while (bytes_written != 0); + memset(output_buffer, 0, self->next_buffer_size); + self->next_buffer = NULL; + self->next_buffer_size = 0; return; } - while (!self->stopping) { + while (!self->stopping && output_buffer_size > 0) { if (self->sample_data == self->sample_end) { uint32_t sample_buffer_length; audioio_get_buffer_result_t get_buffer_result = @@ -118,51 +74,45 @@ static void i2s_fill_buffer(i2s_t *self) { break; } } - size_t bytes_written = 0; - size_t bytecount = self->sample_end - self->sample_data; + size_t sample_bytecount = self->sample_end - self->sample_data; + // The framecount is the minimum of space left in the output buffer or left in the incoming sample. + size_t framecount = MIN(output_buffer_size / bytes_per_output_frame, sample_bytecount / bytes_per_input_frame); if (self->samples_signed && self->channel_count == 2) { if (self->bytes_per_sample == 2) { - CHECK_ESP_RESULT(i2s_write(self->instance, self->sample_data, bytecount, &bytes_written, I2S_WRITE_DELAY)); + memcpy(output_buffer, self->sample_data, framecount * bytes_per_output_frame); } else { - CHECK_ESP_RESULT(i2s_write_expand(self->instance, self->sample_data, bytecount, 8, 16, &bytes_written, I2S_WRITE_DELAY)); + audiosample_convert_s8s_s16s(output_buffer, ((int8_t *)self->sample_data), framecount); } } else { - const size_t bytes_per_output_frame = 4; - size_t bytes_per_input_frame = self->channel_count * self->bytes_per_sample; - size_t framecount = MIN(STACK_BUFFER_SIZE / bytes_per_output_frame, bytecount / bytes_per_input_frame); if (self->samples_signed) { assert(self->channel_count == 1); if (self->bytes_per_sample == 1) { - audiosample_convert_s8m_s16s(signed_samples, (int8_t *)(void *)self->sample_data, framecount); + audiosample_convert_s8m_s16s(output_buffer, (int8_t *)(void *)self->sample_data, framecount); } else { - audiosample_convert_s16m_s16s(signed_samples, (int16_t *)(void *)self->sample_data, framecount); + audiosample_convert_s16m_s16s(output_buffer, (int16_t *)(void *)self->sample_data, framecount); } } else { if (self->channel_count == 1) { if (self->bytes_per_sample == 1) { - audiosample_convert_u8m_s16s(signed_samples, (uint8_t *)(void *)self->sample_data, framecount); + audiosample_convert_u8m_s16s(output_buffer, (uint8_t *)(void *)self->sample_data, framecount); } else { - audiosample_convert_u16m_s16s(signed_samples, (uint16_t *)(void *)self->sample_data, framecount); + audiosample_convert_u16m_s16s(output_buffer, (uint16_t *)(void *)self->sample_data, framecount); } } else { if (self->bytes_per_sample == 1) { - audiosample_convert_u8s_s16s(signed_samples, (uint8_t *)(void *)self->sample_data, framecount); + audiosample_convert_u8s_s16s(output_buffer, (uint8_t *)(void *)self->sample_data, framecount); } else { - audiosample_convert_u16s_s16s(signed_samples, (uint16_t *)(void *)self->sample_data, framecount); + audiosample_convert_u16s_s16s(output_buffer, (uint16_t *)(void *)self->sample_data, framecount); } } } - size_t expanded_bytes_written = 0; - CHECK_ESP_RESULT(i2s_write(self->instance, signed_samples, bytes_per_output_frame * framecount, &expanded_bytes_written, I2S_WRITE_DELAY)); - assert(expanded_bytes_written % 4 == 0); - bytes_written = expanded_bytes_written / bytes_per_output_frame * bytes_per_input_frame; - } - self->sample_data += bytes_written; - // We have filled the DMA buffer - if (!bytes_written) { - break; } + self->sample_data += framecount * bytes_per_input_frame; + output_buffer += framecount * CIRCUITPY_OUTPUT_SLOTS; + output_buffer_size -= framecount * bytes_per_output_frame; } + self->next_buffer = NULL; + self->next_buffer_size = 0; } static void i2s_callback_fun(void *self_in) { @@ -170,39 +120,41 @@ static void i2s_callback_fun(void *self_in) { i2s_fill_buffer(self); } -static void i2s_event_task(void *self_in) { +static bool i2s_event_interrupt(i2s_chan_handle_t handle, i2s_event_data_t *event, void *self_in) { i2s_t *self = self_in; - while (true) { - i2s_event_type_t event; - BaseType_t result = xQueueReceive(i2s_queues[self->instance], &event, portMAX_DELAY); - if (result && event == I2S_EVENT_TX_DONE) { - background_callback_add(&self->callback, i2s_callback_fun, self_in); - } - } + self->underrun = self->underrun || self->next_buffer != NULL; + self->next_buffer = *(int16_t **)event->data; + self->next_buffer_size = event->size; + background_callback_add(&self->callback, i2s_callback_fun, self_in); + return false; } void port_i2s_allocate_init(i2s_t *self, bool left_justified) { - self->instance = port_i2s_allocate(); - - i2s_config_t i2s_config = { - .mode = I2S_MODE_MASTER | I2S_MODE_TX, - .sample_rate = 44100, - .bits_per_sample = 16, - .channel_format = I2S_CHANNEL_FMT_RIGHT_LEFT, - .communication_format = left_justified ? I2S_COMM_FORMAT_STAND_I2S : I2S_COMM_FORMAT_STAND_I2S, - .dma_buf_count = 3, - .dma_buf_len = 1024, // in _frames_, so 1024 is 4096 bytes per dma buf - .use_apll = false, + i2s_chan_config_t chan_config = { + .id = I2S_NUM_AUTO, + .role = I2S_ROLE_MASTER, + .dma_desc_num = CIRCUITPY_BUFFER_COUNT, + .dma_frame_num = CIRCUITPY_BUFFER_SIZE, // in _frames_, so 1023 is 4092 bytes per dma buf which is the maximum }; - CHECK_ESP_RESULT(i2s_driver_install(self->instance, &i2s_config, I2S_QUEUE_SIZE, &i2s_queues[self->instance])); - - if (!xTaskCreate(i2s_event_task, "I2S_task", 3 * configMINIMAL_STACK_SIZE, self, CONFIG_PTHREAD_TASK_PRIO_DEFAULT, &i2s_tasks[self->instance])) { - mp_raise_OSError_msg(translate("xTaskCreate failed")); + esp_err_t err = i2s_new_channel(&chan_config, &self->handle, NULL); + if (err == ESP_ERR_NOT_FOUND) { + mp_raise_RuntimeError(translate("Peripheral in use")); } - i2s_instance[self->instance] = self; + i2s_event_callbacks_t callbacks = { + .on_recv = NULL, + .on_recv_q_ovf = NULL, + .on_sent = i2s_event_interrupt, + .on_send_q_ovf = NULL, + }; + i2s_channel_register_event_callback(self->handle, &callbacks, self); } +void port_i2s_deinit(i2s_t *self) { + port_i2s_stop(self); + i2s_del_channel(self->handle); + self->handle = NULL; +} void port_i2s_play(i2s_t *self, mp_obj_t sample, bool loop) { self->sample = sample; @@ -216,9 +168,6 @@ void port_i2s_play(i2s_t *self, mp_obj_t sample, bool loop) { audiosample_get_buffer_structure(sample, false, &single_buffer, &samples_signed, &max_buffer_length, &spacing); self->samples_signed = samples_signed; - self->playing = true; - self->paused = false; - self->stopping = false; self->sample_data = self->sample_end = NULL; // We always output stereo so output twice as many bits. // uint16_t bits_per_sample_output = bits_per_sample * 2; @@ -226,12 +175,32 @@ void port_i2s_play(i2s_t *self, mp_obj_t sample, bool loop) { audiosample_reset_buffer(self->sample, false, 0); uint32_t sample_rate = audiosample_sample_rate(sample); - if (sample_rate != self->i2s_config.sample_rate) { - CHECK_ESP_RESULT(i2s_set_sample_rates(self->instance, audiosample_sample_rate(sample))); - self->i2s_config.sample_rate = sample_rate; + i2s_std_clk_config_t clk_config = I2S_STD_CLK_DEFAULT_CONFIG(sample_rate); + CHECK_ESP_RESULT(i2s_channel_reconfig_std_clock(self->handle, &clk_config)); + + // preload the data + self->playing = true; + self->paused = false; + self->stopping = false; + // This will be slow but we can't rewind the underlying sample. So, we will + // preload one frame at a time and drop the last sample that can't fit. + // We cap ourselves at the max DMA set to prevent a sample drop if starting + // fresh. + uint32_t starting_frame; + size_t bytes_loaded = 4; + size_t preloaded = 0; + while (bytes_loaded > 0 && preloaded < CIRCUITPY_BUFFER_SIZE * CIRCUITPY_BUFFER_COUNT) { + self->next_buffer = &starting_frame; + self->next_buffer_size = sizeof(starting_frame); + i2s_fill_buffer(self); + i2s_channel_preload_data(self->handle, &starting_frame, sizeof(uint32_t), &bytes_loaded); + preloaded += 1; } - background_callback_add(&self->callback, i2s_callback_fun, self); + // enable the channel + i2s_channel_enable(self->handle); + + // The IDF will call us back when there is a free DMA buffer. } bool port_i2s_playing(i2s_t *self) { @@ -243,8 +212,8 @@ bool port_i2s_paused(i2s_t *self) { } void port_i2s_stop(i2s_t *self) { + port_i2s_pause(self); self->sample = NULL; - self->paused = false; self->playing = false; self->stopping = false; } @@ -252,13 +221,13 @@ void port_i2s_stop(i2s_t *self) { void port_i2s_pause(i2s_t *self) { if (!self->paused) { self->paused = true; - CHECK_ESP_RESULT(i2s_stop(self->instance)); + CHECK_ESP_RESULT(i2s_channel_disable(self->handle)); } } void port_i2s_resume(i2s_t *self) { if (self->paused) { self->paused = false; - CHECK_ESP_RESULT(i2s_start(self->instance)); + CHECK_ESP_RESULT(i2s_channel_enable(self->handle)); } } diff --git a/ports/espressif/common-hal/audiobusio/__init__.h b/ports/espressif/common-hal/audiobusio/__init__.h index 00dc99d30a..a2e397828a 100644 --- a/ports/espressif/common-hal/audiobusio/__init__.h +++ b/ports/espressif/common-hal/audiobusio/__init__.h @@ -30,7 +30,7 @@ #include "supervisor/background_callback.h" -#include "driver/i2s.h" +#include "driver/i2s_std.h" typedef struct { mp_obj_t *sample; @@ -42,23 +42,22 @@ typedef struct { bool samples_signed; int8_t bytes_per_sample; int8_t channel_count; - int8_t instance; uint16_t buffer_length; uint8_t *sample_data, *sample_end; - i2s_config_t i2s_config; + void *next_buffer; + size_t next_buffer_size; + i2s_chan_handle_t handle; background_callback_t callback; + bool underrun; } i2s_t; void port_i2s_allocate_init(i2s_t *self, bool left_justified); -void port_i2s_reset_instance(int i); -void i2s_reset(void); +void port_i2s_deinit(i2s_t *self); + void port_i2s_play(i2s_t *self, mp_obj_t sample, bool loop); void port_i2s_stop(i2s_t *self); bool port_i2s_playing(i2s_t *self); bool port_i2s_paused(i2s_t *self); void port_i2s_pause(i2s_t *self); void port_i2s_resume(i2s_t *self); - -// some uses (imagecapture) can only operate on i2s0 and need their own init code -void port_i2s_allocate_i2s0(void); diff --git a/ports/espressif/common-hal/busio/I2C.c b/ports/espressif/common-hal/busio/I2C.c index 92bd4fb157..ea752c986d 100644 --- a/ports/espressif/common-hal/busio/I2C.c +++ b/ports/espressif/common-hal/busio/I2C.c @@ -28,7 +28,7 @@ #include "py/mperrno.h" #include "py/runtime.h" -#include "components/driver/include/driver/i2c.h" +#include "components/driver/i2c/include/driver/i2c.h" #include "shared-bindings/microcontroller/__init__.h" #include "shared-bindings/microcontroller/Pin.h" @@ -82,6 +82,7 @@ void common_hal_busio_i2c_construct(busio_i2c_obj_t *self, self->sda_pin = sda; self->scl_pin = scl; self->i2c_num = peripherals_i2c_get_free_num(); + self->has_lock = 0; if (self->i2c_num == I2C_NUM_MAX) { mp_raise_ValueError(translate("All I2C peripherals are in use")); diff --git a/ports/espressif/common-hal/busio/SPI.c b/ports/espressif/common-hal/busio/SPI.c index 0b6b395c51..96a2226553 100644 --- a/ports/espressif/common-hal/busio/SPI.c +++ b/ports/espressif/common-hal/busio/SPI.c @@ -30,7 +30,7 @@ #include "shared-bindings/busio/SPI.h" #include "shared-bindings/microcontroller/Pin.h" -#include "driver/spi_common_internal.h" +#include "esp_private/spi_common_internal.h" #define SPI_MAX_DMA_BITS (SPI_MAX_DMA_LEN * 8) #define MAX_SPI_TRANSACTIONS 10 diff --git a/ports/espressif/common-hal/busio/UART.c b/ports/espressif/common-hal/busio/UART.c index 37e0092726..e96861191f 100644 --- a/ports/espressif/common-hal/busio/UART.c +++ b/ports/espressif/common-hal/busio/UART.c @@ -28,7 +28,7 @@ #include "shared-bindings/microcontroller/Pin.h" #include "shared-bindings/busio/UART.h" -#include "components/driver/include/driver/uart.h" +#include "components/driver/uart/include/driver/uart.h" #include "mpconfigport.h" #include "shared/readline/readline.h" @@ -175,7 +175,7 @@ void common_hal_busio_uart_construct(busio_uart_obj_t *self, xTaskCreatePinnedToCore( uart_event_task, "uart_event_task", - configMINIMAL_STACK_SIZE, + configMINIMAL_STACK_SIZE + 512, self, CONFIG_PTHREAD_TASK_PRIO_DEFAULT, &self->event_task, @@ -230,7 +230,7 @@ void common_hal_busio_uart_construct(busio_uart_obj_t *self, uart_config.stop_bits = UART_STOP_BITS_2; } // uart_set_stop_bits(self->uart_num, stop_bits); - uart_config.source_clk = UART_SCLK_APB; // guessing here... + uart_config.source_clk = UART_SCLK_DEFAULT; // config all in one? if (uart_param_config(self->uart_num, &uart_config) != ESP_OK) { diff --git a/ports/espressif/common-hal/canio/Listener.c b/ports/espressif/common-hal/canio/Listener.c index 66ce096970..a6c0dbf90c 100644 --- a/ports/espressif/common-hal/canio/Listener.c +++ b/ports/espressif/common-hal/canio/Listener.c @@ -39,40 +39,30 @@ #include "hal/twai_ll.h" +// There is no logic that dictates TWAI vs TWAI0 +#if defined(CONFIG_IDF_TARGET_ESP32H2) || defined(CONFIG_IDF_TARGET_ESP32C6) +#define TWAI TWAI0 +#endif + // IDE = "extended ID" flag of packet header. We always add this bit to the // mask because a match is always for just one kind of address length #define FILTER16_IDE (1 << 3) #define FILTER32_IDE (1 << 2) -// Work around a problem reported at -// https://github.com/espressif/esp-idf/issues/6020 where -// twai_ll_set_acc_filter does not work under -Os optimization -__attribute__((optimize("O0"))) -__attribute__((noinline)) -static void canio_set_acc_filter(twai_dev_t *hw, uint32_t code, uint32_t mask, bool single_filter) { - uint32_t code_swapped = __builtin_bswap32(code); - uint32_t mask_swapped = __builtin_bswap32(mask); - for (int i = 0; i < 4; i++) { - hw->acceptance_filter.acr[i].val = ((code_swapped >> (i * 8)) & 0xFF); - hw->acceptance_filter.amr[i].val = ((mask_swapped >> (i * 8)) & 0xFF); - } - hw->mode_reg.afm = single_filter; -} - STATIC void install_standard_filter(canio_listener_obj_t *self, canio_match_obj_t *match) { - canio_set_acc_filter(&TWAI, match->id << 21, ~(match->mask << 21), true); + twai_ll_set_acc_filter(&TWAI, match->id << 21, ~(match->mask << 21), true); self->extended = false; self->standard = true; } STATIC void install_extended_filter(canio_listener_obj_t *self, canio_match_obj_t *match) { - canio_set_acc_filter(&TWAI, match->id << 3, ~(match->mask << 3), true); + twai_ll_set_acc_filter(&TWAI, match->id << 3, ~(match->mask << 3), true); self->extended = true; self->standard = false; } STATIC void install_all_match_filter(canio_listener_obj_t *self) { - canio_set_acc_filter(&TWAI, 0u, ~0u, true); + twai_ll_set_acc_filter(&TWAI, 0u, ~0u, true); self->extended = true; self->standard = true; } diff --git a/ports/espressif/common-hal/countio/Counter.c b/ports/espressif/common-hal/countio/Counter.c index cc4c067266..1cf6d8e707 100644 --- a/ports/espressif/common-hal/countio/Counter.c +++ b/ports/espressif/common-hal/countio/Counter.c @@ -31,6 +31,8 @@ #include "py/runtime.h" #include "supervisor/shared/translate/translate.h" +#include "driver/gpio.h" + void common_hal_countio_counter_construct(countio_counter_obj_t *self, const mcu_pin_obj_t *pin, countio_edge_t edge, digitalio_pull_t pull) { claim_pin(pin); diff --git a/ports/espressif/common-hal/digitalio/DigitalInOut.c b/ports/espressif/common-hal/digitalio/DigitalInOut.c index 61671dadb9..4b6c966da3 100644 --- a/ports/espressif/common-hal/digitalio/DigitalInOut.c +++ b/ports/espressif/common-hal/digitalio/DigitalInOut.c @@ -28,7 +28,7 @@ #include "py/runtime.h" #include "supervisor/shared/translate/translate.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" diff --git a/ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c b/ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c new file mode 100644 index 0000000000..ade19da396 --- /dev/null +++ b/ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.c @@ -0,0 +1,231 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2023 Jeff Epler 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 + +#include "esp_intr_alloc.h" +#include "esp_lcd_panel_interface.h" +#include "esp_lcd_panel_rgb.h" +#include "esp_pm.h" +#include "esp_private/gdma.h" +#include "hal/dma_types.h" +#include "hal/lcd_hal.h" +#include "hal/lcd_ll.h" +#include "soc/lcd_periph.h" + +#include "esp_log.h" +#define TAG "LCD" + +#include "components/esp_rom/include/esp_rom_sys.h" + +#include "bindings/espidf/__init__.h" +#include "py/objarray.h" +#include "shared-bindings/dotclockframebuffer/DotClockFramebuffer.h" +#include "common-hal/dotclockframebuffer/DotClockFramebuffer.h" +#include "common-hal/espidf/__init__.h" +#include "shared-bindings/microcontroller/Pin.h" +#include "py/runtime.h" +#include "components/driver/gpio/include/driver/gpio.h" +#include "components/esp_rom/include/esp_rom_gpio.h" +#include "components/hal/esp32s3/include/hal/lcd_ll.h" +#include "components/hal/include/hal/gpio_hal.h" +#include "components/soc/esp32s3/include/soc/lcd_cam_struct.h" +#include "esp_heap_caps.h" + +// should be from rom/cache.h but it wasn't working +int Cache_WriteBack_Addr(uint32_t addr, uint32_t size); + +#define LCD_RGB_ISR_IRAM_SAFE (1) +#define LCD_RGB_INTR_ALLOC_FLAGS (ESP_INTR_FLAG_IRAM | ESP_INTR_FLAG_INTRDISABLED) + +#define common_hal_mcu_pin_number_maybe(x) ((x) ? common_hal_mcu_pin_number((x)) : -1) + +static void claim_and_record(const mcu_pin_obj_t *pin, uint64_t *used_pins_mask) { + if (pin) { + int number = common_hal_mcu_pin_number(pin); + *used_pins_mask |= (UINT64_C(1) << number); + claim_pin_number(number); + never_reset_pin_number(number); + } +} + +static int valid_pin(const mcu_pin_obj_t *pin, qstr name) { + int result = common_hal_mcu_pin_number(pin); + if (result == NO_PIN) { + mp_raise_ValueError_varg(translate("Invalid %q pin"), name); + } + return result; +} + +void common_hal_dotclockframebuffer_framebuffer_construct(dotclockframebuffer_framebuffer_obj_t *self, + const mcu_pin_obj_t *de, + const mcu_pin_obj_t *vsync, + const mcu_pin_obj_t *hsync, + const mcu_pin_obj_t *dclk, + const mcu_pin_obj_t **red, uint8_t num_red, + const mcu_pin_obj_t **green, uint8_t num_green, + const mcu_pin_obj_t **blue, uint8_t num_blue, + int frequency, int width, int height, + int hsync_pulse_width, int hsync_back_porch, int hsync_front_porch, bool hsync_idle_low, + int vsync_pulse_width, int vsync_back_porch, int vsync_front_porch, bool vsync_idle_low, + bool de_idle_high, bool pclk_active_high, bool pclk_idle_high, int overscan_left) { + + if (num_red != 5 || num_green != 6 || num_blue != 5) { + mp_raise_ValueError(translate("Must provide 5/6/5 RGB pins")); + } + + claim_and_record(de, &self->used_pins_mask); + claim_and_record(vsync, &self->used_pins_mask); + claim_and_record(hsync, &self->used_pins_mask); + claim_and_record(dclk, &self->used_pins_mask); + + for (size_t i = 0; i < num_red; i++) { + claim_and_record(red[i], &self->used_pins_mask); + } + for (size_t i = 0; i < num_green; i++) { + claim_and_record(green[i], &self->used_pins_mask); + } + for (size_t i = 0; i < num_blue; i++) { + claim_and_record(blue[i], &self->used_pins_mask); + } + + esp_lcd_rgb_panel_config_t *cfg = &self->panel_config; + cfg->timings.pclk_hz = frequency; + cfg->timings.h_res = width + overscan_left; + cfg->timings.v_res = height; + cfg->timings.hsync_pulse_width = hsync_pulse_width; + cfg->timings.hsync_back_porch = hsync_back_porch; + cfg->timings.hsync_front_porch = hsync_front_porch; + cfg->timings.vsync_pulse_width = vsync_pulse_width; + cfg->timings.vsync_back_porch = vsync_back_porch; + cfg->timings.vsync_front_porch = vsync_front_porch; + cfg->timings.flags.hsync_idle_low = hsync_idle_low; + cfg->timings.flags.vsync_idle_low = hsync_idle_low; + cfg->timings.flags.de_idle_high = de_idle_high; + cfg->timings.flags.pclk_active_neg = !pclk_active_high; + cfg->timings.flags.pclk_idle_high = pclk_idle_high; + + cfg->data_width = 16; + cfg->sram_trans_align = 8; + cfg->psram_trans_align = 64; + cfg->hsync_gpio_num = valid_pin(hsync, MP_QSTR_hsync); + cfg->vsync_gpio_num = valid_pin(vsync, MP_QSTR_vsync); + cfg->de_gpio_num = valid_pin(de, MP_QSTR_de); + cfg->pclk_gpio_num = valid_pin(dclk, MP_QSTR_dclk); + cfg->clk_src = LCD_CLK_SRC_DEFAULT; + + cfg->data_gpio_nums[0] = valid_pin(blue[0], MP_QSTR_blue); + cfg->data_gpio_nums[1] = valid_pin(blue[1], MP_QSTR_blue); + cfg->data_gpio_nums[2] = valid_pin(blue[2], MP_QSTR_blue); + cfg->data_gpio_nums[3] = valid_pin(blue[3], MP_QSTR_blue); + cfg->data_gpio_nums[4] = valid_pin(blue[4], MP_QSTR_blue); + + cfg->data_gpio_nums[5] = valid_pin(green[0], MP_QSTR_green); + cfg->data_gpio_nums[6] = valid_pin(green[1], MP_QSTR_green); + cfg->data_gpio_nums[7] = valid_pin(green[2], MP_QSTR_green); + cfg->data_gpio_nums[8] = valid_pin(green[3], MP_QSTR_green); + cfg->data_gpio_nums[9] = valid_pin(green[4], MP_QSTR_green); + cfg->data_gpio_nums[10] = valid_pin(green[5], MP_QSTR_green); + + cfg->data_gpio_nums[11] = valid_pin(red[0], MP_QSTR_red); + cfg->data_gpio_nums[12] = valid_pin(red[1], MP_QSTR_red); + cfg->data_gpio_nums[13] = valid_pin(red[2], MP_QSTR_red); + cfg->data_gpio_nums[14] = valid_pin(red[3], MP_QSTR_red); + cfg->data_gpio_nums[15] = valid_pin(red[4], MP_QSTR_red); + + cfg->disp_gpio_num = GPIO_NUM_NC; + + cfg->flags.disp_active_low = 0; + cfg->flags.refresh_on_demand = 0; + cfg->flags.fb_in_psram = 1; // allocate frame buffer in PSRAM + + esp_err_t ret = esp_lcd_new_rgb_panel(&self->panel_config, &self->panel_handle); + cp_check_esp_error(ret); + cp_check_esp_error(esp_lcd_panel_reset(self->panel_handle)); + cp_check_esp_error(esp_lcd_panel_init(self->panel_handle)); + + uint16_t color = 0; + cp_check_esp_error(self->panel_handle->draw_bitmap(self->panel_handle, 0, 0, 1, 1, &color)); + + void *fb; + cp_check_esp_error(esp_lcd_rgb_panel_get_frame_buffer(self->panel_handle, 1, &fb)); + + self->frequency = frequency; + self->row_stride = 2 * (width + overscan_left); + self->first_pixel_offset = 2 * overscan_left; + self->refresh_rate = frequency / (width + hsync_front_porch + hsync_back_porch) / (height + vsync_front_porch + vsync_back_porch); + self->bufinfo.buf = (uint8_t *)fb; + self->bufinfo.len = 2 * (cfg->timings.h_res * cfg->timings.v_res); + self->bufinfo.typecode = 'H' | MP_OBJ_ARRAY_TYPECODE_FLAG_RW; + +// LCD_CAM.lcd_ctrl2.lcd_vsync_idle_pol = _vsync_polarity; +// LCD_CAM.lcd_ctrl2.lcd_hsync_idle_pol = _hsync_polarity; + +} + + +void common_hal_dotclockframebuffer_framebuffer_deinit(dotclockframebuffer_framebuffer_obj_t *self) { + if (common_hal_dotclockframebuffer_framebuffer_deinitialized(self)) { + return; + } + + reset_pin_mask(self->used_pins_mask); + self->used_pins_mask = 0; + esp_lcd_panel_del(self->panel_handle); +} + +bool common_hal_dotclockframebuffer_framebuffer_deinitialized(dotclockframebuffer_framebuffer_obj_t *self) { + return self->used_pins_mask == 0; +} + + +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_width(dotclockframebuffer_framebuffer_obj_t *self) { + return self->panel_config.timings.h_res - self->first_pixel_offset / 2; +} + +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_height(dotclockframebuffer_framebuffer_obj_t *self) { + return self->panel_config.timings.v_res; +} + +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_frequency(dotclockframebuffer_framebuffer_obj_t *self) { + return self->frequency; +} + +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_row_stride(dotclockframebuffer_framebuffer_obj_t *self) { + return self->row_stride; +} + +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_first_pixel_offset(dotclockframebuffer_framebuffer_obj_t *self) { + return self->first_pixel_offset; +} + +void common_hal_dotclockframebuffer_framebuffer_refresh(dotclockframebuffer_framebuffer_obj_t *self) { + Cache_WriteBack_Addr((uint32_t)(self->bufinfo.buf), self->bufinfo.len); +} + +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_refresh_rate(dotclockframebuffer_framebuffer_obj_t *self) { + return self->refresh_rate; +} diff --git a/ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.h b/ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.h new file mode 100644 index 0000000000..1432b7009b --- /dev/null +++ b/ports/espressif/common-hal/dotclockframebuffer/DotClockFramebuffer.h @@ -0,0 +1,47 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2023 Jeff Epler 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. + */ + +#pragma once + +#include "py/obj.h" + +#include "esp_lcd_panel_io.h" +#include "esp_lcd_panel_rgb.h" +#include "esp_lcd_panel_vendor.h" +#include "esp_lcd_panel_ops.h" +#include "esp_lcd_panel_interface.h" + +typedef struct dotclockframebuffer_framebuffer_obj { + mp_obj_base_t base; + mp_buffer_info_t bufinfo; + mp_int_t row_stride; + uint32_t frequency, refresh_rate; + uint32_t first_pixel_offset; + uint64_t used_pins_mask; + volatile int32_t frame_count; + esp_lcd_rgb_panel_config_t panel_config; + esp_lcd_panel_handle_t panel_handle; +} dotclockframebuffer_framebuffer_obj_t; diff --git a/ports/espressif/common-hal/dotclockframebuffer/__init__.c b/ports/espressif/common-hal/dotclockframebuffer/__init__.c new file mode 100644 index 0000000000..e69de29bb2 diff --git a/ports/espressif/common-hal/dotclockframebuffer/__init__.h b/ports/espressif/common-hal/dotclockframebuffer/__init__.h new file mode 100644 index 0000000000..e69de29bb2 diff --git a/ports/espressif/common-hal/dualbank/__init__.c b/ports/espressif/common-hal/dualbank/__init__.c index 9e3fb38627..b3151f268d 100644 --- a/ports/espressif/common-hal/dualbank/__init__.c +++ b/ports/espressif/common-hal/dualbank/__init__.c @@ -31,6 +31,7 @@ #include "esp_log.h" #include "esp_ota_ops.h" +#include "esp_app_format.h" static const esp_partition_t *update_partition = NULL; static esp_ota_handle_t update_handle = 0; @@ -59,10 +60,10 @@ void common_hal_dualbank_flash(const void *buf, const size_t len, const size_t o update_partition = esp_ota_get_next_update_partition(NULL); assert(update_partition != NULL); - ESP_LOGI(TAG, "Running partition type %d subtype %d (offset 0x%08x)", + ESP_LOGI(TAG, "Running partition type %d subtype %d (offset 0x%08lu)", running->type, running->subtype, running->address); - ESP_LOGI(TAG, "Writing partition type %d subtype %d (offset 0x%08x)\n", + ESP_LOGI(TAG, "Writing partition type %d subtype %d (offset 0x%08lu)\n", update_partition->type, update_partition->subtype, update_partition->address); } diff --git a/ports/espressif/common-hal/espcamera/Camera.c b/ports/espressif/common-hal/espcamera/Camera.c index 574b4e846b..cdf7ab63c8 100644 --- a/ports/espressif/common-hal/espcamera/Camera.c +++ b/ports/espressif/common-hal/espcamera/Camera.c @@ -35,7 +35,7 @@ #include "shared-bindings/util.h" #include "common-hal/microcontroller/Pin.h" -#include "esp32-camera/driver/private_include/cam_hal.h" +#include "esp-camera/driver/private_include/cam_hal.h" #if !CONFIG_SPIRAM #error espcamera only works on boards configured with spiram, disable it in mpconfigboard.mk @@ -161,6 +161,10 @@ extern void common_hal_espcamera_camera_deinit(espcamera_camera_obj_t *self) { esp_camera_deinit(); + reset_pin_number(self->camera_config.pin_pclk); + reset_pin_number(self->camera_config.pin_vsync); + reset_pin_number(self->camera_config.pin_href); + self->camera_config.xclk_freq_hz = 0; } diff --git a/ports/espressif/common-hal/espidf/__init__.c b/ports/espressif/common-hal/espidf/__init__.c index 379d7c5ab4..e5f866b906 100644 --- a/ports/espressif/common-hal/espidf/__init__.c +++ b/ports/espressif/common-hal/espidf/__init__.c @@ -35,7 +35,7 @@ #define TAG "espidf" #ifdef CONFIG_SPIRAM -#include "esp32/spiram.h" +#include "esp_psram.h" #include "esp_heap_caps.h" #include "esp_heap_caps_init.h" #include "soc/soc.h" @@ -44,14 +44,13 @@ #else #define esp_himem_reserved_area_size() (0) #endif -bool ok_to_reserve_psram = true; size_t reserved_psram = DEFAULT_RESERVED_PSRAM; #endif static size_t psram_size_usable(void) { #ifdef CONFIG_SPIRAM /* PSRAM chip may be larger than the size we can map into address space */ - size_t s = MIN(esp_spiram_get_size(), SOC_EXTRAM_DATA_SIZE); + size_t s = MIN(esp_psram_get_size(), SOC_EXTRAM_DATA_SIZE); return s - esp_himem_reserved_area_size(); #else return 0; @@ -60,10 +59,7 @@ static size_t psram_size_usable(void) { bool common_hal_espidf_set_reserved_psram(size_t amount) { #ifdef CONFIG_SPIRAM - if (!esp_spiram_is_initialized()) { - return false; - } - if (!ok_to_reserve_psram) { + if (!esp_psram_is_initialized()) { return false; } if (amount > psram_size_usable()) { @@ -79,7 +75,7 @@ bool common_hal_espidf_set_reserved_psram(size_t amount) { supervisor_allocation *psram_for_idf; void common_hal_espidf_reserve_psram(void) { - #ifdef CONFIG_SPIRAM + #ifdef CONFIG_SPIRAM_USE_MEMMAP if (!psram_for_idf) { ESP_LOGI(TAG, "Reserving %d bytes of psram", reserved_psram); if (reserved_psram == 0) { @@ -112,20 +108,14 @@ size_t common_hal_espidf_get_total_psram(void) { intptr_t common_hal_espidf_get_psram_start(void) { #ifdef CONFIG_SPIRAM - if (esp_spiram_is_initialized()) { - #ifdef CONFIG_IDF_TARGET_ESP32 - return SOC_EXTRAM_DATA_LOW; - #else - return SOC_EXTRAM_DATA_HIGH - psram_size_usable(); - #endif - } + return (intptr_t)esp_psram_get_address(); #endif return 0; } intptr_t common_hal_espidf_get_psram_end(void) { #ifdef CONFIG_SPIRAM - if (esp_spiram_is_initialized()) { + if (esp_psram_is_initialized()) { return common_hal_espidf_get_psram_start() + psram_size_usable(); } #endif @@ -198,4 +188,11 @@ void raise_esp_error(esp_err_t err) { mp_raise_msg_varg(exception_type, translate("%s error 0x%x"), group, err); } +void cp_check_esp_error(esp_err_t err) { + if (err == ESP_OK) { + return; + } + raise_esp_error(err); +} + MP_REGISTER_MODULE(MP_QSTR_espidf, espidf_module); diff --git a/ports/espressif/common-hal/espidf/__init__.h b/ports/espressif/common-hal/espidf/__init__.h index 0d168b105c..337ad7ef99 100644 --- a/ports/espressif/common-hal/espidf/__init__.h +++ b/ports/espressif/common-hal/espidf/__init__.h @@ -26,4 +26,4 @@ #pragma once -#include "bindings/espidf/__init__.h" +void cp_check_esp_error(esp_err_t err); diff --git a/ports/espressif/common-hal/espnow/ESPNow.c b/ports/espressif/common-hal/espnow/ESPNow.c index ff07497a30..814499b1c0 100644 --- a/ports/espressif/common-hal/espnow/ESPNow.c +++ b/ports/espressif/common-hal/espnow/ESPNow.c @@ -88,7 +88,7 @@ static void send_cb(const uint8_t *mac, esp_now_send_status_t status) { // Callback triggered when an ESP-NOW packet is received. // Write the peer MAC address and the message into the recv_buffer as an ESPNow packet. // If the buffer is full, drop the message and increment the dropped count. -static void recv_cb(const uint8_t *mac, const uint8_t *msg, int msg_len) { +static void recv_cb(const esp_now_recv_info_t *esp_now_info, const uint8_t *msg, int msg_len) { espnow_obj_t *self = MP_STATE_PORT(espnow_singleton); ringbuf_t *buf = self->recv_buffer; @@ -117,7 +117,7 @@ static void recv_cb(const uint8_t *mac, const uint8_t *msg, int msg_len) { header.time_ms = mp_hal_ticks_ms(); ringbuf_put_n(buf, (uint8_t *)&header, sizeof(header)); - ringbuf_put_n(buf, mac, ESP_NOW_ETH_ALEN); + ringbuf_put_n(buf, esp_now_info->src_addr, ESP_NOW_ETH_ALEN); ringbuf_put_n(buf, msg, msg_len); self->read_success++; diff --git a/ports/espressif/common-hal/espulp/ULP.c b/ports/espressif/common-hal/espulp/ULP.c index 3350f6d45c..d8bb0be597 100644 --- a/ports/espressif/common-hal/espulp/ULP.c +++ b/ports/espressif/common-hal/espulp/ULP.c @@ -28,7 +28,6 @@ #include "bindings/espulp/ULP.h" #include "py/runtime.h" - #include "shared-bindings/microcontroller/Pin.h" #if defined(CONFIG_IDF_TARGET_ESP32) @@ -36,11 +35,11 @@ #define ULP_COPROC_RESERVE_MEM (CONFIG_ESP32_ULP_COPROC_RESERVE_MEM) #elif defined(CONFIG_IDF_TARGET_ESP32S2) #include "esp32s2/ulp.h" -#include "esp32s2/ulp_riscv.h" +#include "ulp_riscv.h" #define ULP_COPROC_RESERVE_MEM (CONFIG_ESP32S2_ULP_COPROC_RESERVE_MEM) #elif defined(CONFIG_IDF_TARGET_ESP32S3) #include "esp32s3/ulp.h" -#include "esp32s3/ulp_riscv.h" +#include "ulp_riscv.h" #define ULP_COPROC_RESERVE_MEM (CONFIG_ESP32S3_ULP_COPROC_RESERVE_MEM) #endif @@ -56,7 +55,7 @@ void espulp_reset(void) { } void common_hal_espulp_ulp_run(espulp_ulp_obj_t *self, uint32_t *program, size_t length, uint32_t pin_mask) { - if (length > ULP_COPROC_RESERVE_MEM) { + if (length > CONFIG_ULP_COPROC_RESERVE_MEM) { mp_raise_ValueError(translate("Program too long")); } @@ -91,16 +90,18 @@ void common_hal_espulp_ulp_run(espulp_ulp_obj_t *self, uint32_t *program, size_t ulp_set_wakeup_period(0, 20000); switch (self->arch) { + #ifdef CONFIG_ULP_COPROC_TYPE_FSM case FSM: ulp_load_binary(0, (const uint8_t *)program, length); ulp_run(0); break; + #endif + #ifdef CONFIG_ULP_COPROC_TYPE_RISCV case RISCV: - #ifndef CONFIG_IDF_TARGET_ESP32 ulp_riscv_load_binary((const uint8_t *)program, length); ulp_riscv_run(); break; - #endif + #endif default: mp_raise_NotImplementedError(NULL); break; @@ -108,22 +109,23 @@ void common_hal_espulp_ulp_run(espulp_ulp_obj_t *self, uint32_t *program, size_t } void common_hal_espulp_ulp_halt(espulp_ulp_obj_t *self) { - #ifdef CONFIG_IDF_TARGET_ESP32 - mp_raise_NotImplementedError(NULL); - #else - // To-do idf v5.0: use following functions - // ulp_riscv_timer_stop(); - // ulp_riscv_halt(); - - // stop the ulp timer so that it doesn't restart the cpu - CLEAR_PERI_REG_MASK(RTC_CNTL_ULP_CP_TIMER_REG, RTC_CNTL_ULP_CP_SLP_TIMER_EN); - - // suspends the ulp operation - SET_PERI_REG_MASK(RTC_CNTL_COCPU_CTRL_REG, RTC_CNTL_COCPU_DONE); - - // resets the processor - SET_PERI_REG_MASK(RTC_CNTL_COCPU_CTRL_REG, RTC_CNTL_COCPU_SHUT_RESET_EN); - #endif + switch (self->arch) { + /* + #ifdef CONFIG_ULP_COPROC_TYPE_FSM + case FSM: + break; + #endif + */ + #ifdef CONFIG_ULP_COPROC_TYPE_RISCV + case RISCV: + ulp_riscv_timer_stop(); + ulp_riscv_halt(); + break; + #endif + default: + mp_raise_NotImplementedError(NULL); + break; + } // Release pins we were using. for (uint8_t i = 0; i < 32; i++) { @@ -141,11 +143,19 @@ void common_hal_espulp_ulp_construct(espulp_ulp_obj_t *self, espulp_architecture mp_raise_ValueError_varg(translate("%q in use"), MP_QSTR_ULP); } - #ifdef CONFIG_IDF_TARGET_ESP32 - if (self->arch == RISCV) { - mp_raise_NotImplementedError(NULL); + switch (arch) { + #ifdef CONFIG_ULP_COPROC_TYPE_FSM + case FSM: + break; + #endif + #ifdef CONFIG_ULP_COPROC_TYPE_RISCV + case RISCV: + break; + #endif + default: + mp_raise_NotImplementedError(NULL); + break; } - #endif self->arch = arch; self->inited = true; diff --git a/ports/espressif/common-hal/espulp/ULPAlarm.c b/ports/espressif/common-hal/espulp/ULPAlarm.c index 3717d2ab71..798d86ce29 100644 --- a/ports/espressif/common-hal/espulp/ULPAlarm.c +++ b/ports/espressif/common-hal/espulp/ULPAlarm.c @@ -29,7 +29,7 @@ #include "common-hal/alarm/__init__.h" #include "supervisor/port.h" -#include "driver/rtc_cntl.h" +#include "esp_private/rtc_ctrl.h" #include "soc/rtc_cntl_reg.h" #include "esp_sleep.h" @@ -81,20 +81,22 @@ void espulp_ulpalarm_set_alarm(const bool deep_sleep, const size_t n_alarms, con // enable ulp interrupt switch (alarm->ulp->arch) { + #ifdef CONFIG_ULP_COPROC_TYPE_FSM case FSM: #ifdef CONFIG_IDF_TARGET_ESP32 - rtc_isr_register(&ulp_interrupt, NULL, RTC_CNTL_ULP_CP_INT_RAW); + rtc_isr_register(&ulp_interrupt, NULL, RTC_CNTL_ULP_CP_INT_RAW, 0); #else - rtc_isr_register(&ulp_interrupt, NULL, RTC_CNTL_ULP_CP_INT_ST); + rtc_isr_register(&ulp_interrupt, NULL, RTC_CNTL_ULP_CP_INT_ST, 0); #endif REG_SET_BIT(RTC_CNTL_INT_ENA_REG, RTC_CNTL_ULP_CP_INT_ENA); break; + #endif + #ifdef CONFIG_ULP_COPROC_TYPE_RISCV case RISCV: - #ifndef CONFIG_IDF_TARGET_ESP32 - rtc_isr_register(&ulp_interrupt, NULL, RTC_CNTL_COCPU_INT_ST); + rtc_isr_register(&ulp_interrupt, NULL, RTC_CNTL_COCPU_INT_ST, 0); REG_SET_BIT(RTC_CNTL_INT_ENA_REG, RTC_CNTL_COCPU_INT_ENA); break; - #endif + #endif default: mp_raise_NotImplementedError(NULL); break; @@ -110,14 +112,18 @@ void espulp_ulpalarm_prepare_for_deep_sleep(void) { // disable ulp interrupt rtc_isr_deregister(&ulp_interrupt, NULL); + #ifdef CONFIG_ULP_COPROC_TYPE_FSM REG_CLR_BIT(RTC_CNTL_INT_ENA_REG, RTC_CNTL_ULP_CP_INT_ENA); - #ifndef CONFIG_IDF_TARGET_ESP32 + #endif + #ifdef CONFIG_ULP_COPROC_TYPE_RISCV REG_CLR_BIT(RTC_CNTL_INT_ENA_REG, RTC_CNTL_COCPU_INT_ENA); #endif // enable ulp wakeup esp_sleep_enable_ulp_wakeup(); + #if defined(SOC_PM_SUPPORT_RTC_SLOW_MEM_PD) && SOC_PM_SUPPORT_RTC_SLOW_MEM_PD esp_sleep_pd_config(ESP_PD_DOMAIN_RTC_SLOW_MEM, ESP_PD_OPTION_ON); + #endif } bool espulp_ulpalarm_woke_this_cycle(void) { diff --git a/ports/espressif/common-hal/frequencyio/FrequencyIn.c b/ports/espressif/common-hal/frequencyio/FrequencyIn.c index d35614ea19..92e76f1207 100644 --- a/ports/espressif/common-hal/frequencyio/FrequencyIn.c +++ b/ports/espressif/common-hal/frequencyio/FrequencyIn.c @@ -28,6 +28,10 @@ #include "py/runtime.h" +#include "driver/gpio.h" +#include "driver/timer.h" +#include "soc/timer_group_struct.h" + static void IRAM_ATTR pcnt_overflow_handler(void *self_in) { frequencyio_frequencyin_obj_t *self = self_in; // reset counter @@ -56,28 +60,20 @@ static void IRAM_ATTR timer_interrupt_handler(void *self_in) { // reset interrupt timg_dev_t *device = self->timer.group ? &(TIMERG1) : &(TIMERG0); - #if defined(CONFIG_IDF_TARGET_ESP32) - if (self->timer.idx) { - device->int_clr_timers.t1 = 1; - } else { - device->int_clr_timers.t0 = 1; - } - #else + #if SOC_TIMER_GROUP_TIMERS_PER_GROUP > 1 if (self->timer.idx) { device->int_clr_timers.t1_int_clr = 1; } else { - device->int_clr_timers.t0_int_clr = 1; - } + #endif + device->int_clr_timers.t0_int_clr = 1; + #if SOC_TIMER_GROUP_TIMERS_PER_GROUP > 1 +} #endif - #if defined(CONFIG_IDF_TARGET_ESP32) - device->hw_timer[self->timer.idx].config.alarm_en = 1; - #elif defined(CONFIG_IDF_TARGET_ESP32S2) || defined(CONFIG_IDF_TARGET_ESP32C2) - device->hw_timer[self->timer.idx].config.tx_alarm_en = 1; - #elif defined(CONFIG_IDF_TARGET_ESP32S3) + #if defined(CONFIG_IDF_TARGET_ESP32S3) device->hw_timer[self->timer.idx].config.tn_alarm_en = 1; #else - #error No known CONFIG_IDF_TARGET_xxx found + device->hw_timer[self->timer.idx].config.tx_alarm_en = 1; #endif } diff --git a/ports/espressif/common-hal/hashlib/Hash.c b/ports/espressif/common-hal/hashlib/Hash.c index 8090128acb..5aed82817a 100644 --- a/ports/espressif/common-hal/hashlib/Hash.c +++ b/ports/espressif/common-hal/hashlib/Hash.c @@ -30,7 +30,7 @@ void common_hal_hashlib_hash_update(hashlib_hash_obj_t *self, const uint8_t *data, size_t datalen) { if (self->hash_type == MBEDTLS_SSL_HASH_SHA1) { - mbedtls_sha1_update_ret(&self->sha1, data, datalen); + mbedtls_sha1_update(&self->sha1, data, datalen); return; } } @@ -44,7 +44,7 @@ void common_hal_hashlib_hash_digest(hashlib_hash_obj_t *self, uint8_t *data, siz // the digest a second time. mbedtls_sha1_context copy; mbedtls_sha1_clone(©, &self->sha1); - mbedtls_sha1_finish_ret(&self->sha1, data); + mbedtls_sha1_finish(&self->sha1, data); mbedtls_sha1_clone(&self->sha1, ©); } } diff --git a/ports/espressif/common-hal/hashlib/__init__.c b/ports/espressif/common-hal/hashlib/__init__.c index 1e6b2a4802..7dd147be5f 100644 --- a/ports/espressif/common-hal/hashlib/__init__.c +++ b/ports/espressif/common-hal/hashlib/__init__.c @@ -33,7 +33,7 @@ bool common_hal_hashlib_new(hashlib_hash_obj_t *self, const char *algorithm) { if (strcmp(algorithm, "sha1") == 0) { self->hash_type = MBEDTLS_SSL_HASH_SHA1; mbedtls_sha1_init(&self->sha1); - mbedtls_sha1_starts_ret(&self->sha1); + mbedtls_sha1_starts(&self->sha1); return true; } return false; diff --git a/ports/espressif/common-hal/mdns/RemoteService.h b/ports/espressif/common-hal/mdns/RemoteService.h index ca59f5ece6..b577938024 100644 --- a/ports/espressif/common-hal/mdns/RemoteService.h +++ b/ports/espressif/common-hal/mdns/RemoteService.h @@ -26,7 +26,7 @@ #pragma once -#include "components/mdns/include/mdns.h" +#include "mdns.h" typedef struct { mp_obj_base_t base; diff --git a/ports/espressif/common-hal/mdns/Server.c b/ports/espressif/common-hal/mdns/Server.c index 9205f76087..0246a39587 100644 --- a/ports/espressif/common-hal/mdns/Server.c +++ b/ports/espressif/common-hal/mdns/Server.c @@ -31,7 +31,7 @@ #include "shared-bindings/mdns/RemoteService.h" #include "shared-bindings/wifi/__init__.h" -#include "components/mdns/include/mdns.h" +#include "mdns.h" // Track whether the underlying IDF mdns has been started so that we only // create a single inited MDNS object to CircuitPython. (After deinit, another @@ -125,22 +125,13 @@ size_t mdns_server_find(mdns_server_obj_t *self, const char *service_type, const if (search == NULL) { return 0; } + uint8_t num_results; mdns_result_t *results; - while (!mdns_query_async_get_results(search, 1, &results)) { + while (!mdns_query_async_get_results(search, 1, &results, &num_results)) { RUN_BACKGROUND_TASKS; } mdns_query_async_delete(search); - // Count how many results we got. - // TODO: Remove this loop when moving off 4.4. Newer APIs will give us num_results - // back directly. mdns_result_t *next = results; - uint8_t num_results = 0; - while (next != NULL) { - num_results++; - next = next->next; - } - - next = results; // Don't error if we're out of memory. Instead, truncate the tuple. uint8_t added = 0; while (next != NULL && added < out_len) { @@ -166,27 +157,19 @@ mp_obj_t common_hal_mdns_server_find(mdns_server_obj_t *self, const char *servic if (search == NULL) { mp_raise_RuntimeError(translate("Unable to start mDNS query")); } + uint8_t num_results; mdns_result_t *results; - while (!mdns_query_async_get_results(search, 1, &results)) { + while (!mdns_query_async_get_results(search, 1, &results, &num_results)) { RUN_BACKGROUND_TASKS; } mdns_query_async_delete(search); - // Count how many results we got. - // TODO: Remove this loop when moving off 4.4. Newer APIs will give us num_results - // back directly. - mdns_result_t *next = results; - uint8_t num_results = 0; - while (next != NULL) { - num_results++; - next = next->next; - } mp_obj_tuple_t *tuple = MP_OBJ_TO_PTR(mp_obj_new_tuple(num_results, NULL)); // The empty tuple object is shared and stored in flash so return early if // we got it. Without this we'll crash when trying to set len below. if (num_results == 0) { return MP_OBJ_FROM_PTR(tuple); } - next = results; + mdns_result_t *next = results; // Don't error if we're out of memory. Instead, truncate the tuple. uint8_t added = 0; while (next != NULL) { diff --git a/ports/espressif/common-hal/memorymap/AddressRange.c b/ports/espressif/common-hal/memorymap/AddressRange.c index ed46c159bb..9e87e5384b 100644 --- a/ports/espressif/common-hal/memorymap/AddressRange.c +++ b/ports/espressif/common-hal/memorymap/AddressRange.c @@ -29,7 +29,6 @@ #include "shared-bindings/memorymap/AddressRange.h" #include "py/runtime.h" - #include "soc/soc.h" size_t allow_ranges[][2] = { @@ -39,7 +38,6 @@ size_t allow_ranges[][2] = { {SOC_RTC_DRAM_LOW, SOC_RTC_DRAM_HIGH}, // RTC peripheral registers {0x60008000, 0x60009000} - }; void common_hal_memorymap_addressrange_construct(memorymap_addressrange_obj_t *self, uint8_t *start_address, size_t length) { @@ -66,7 +64,7 @@ size_t common_hal_memorymap_addressrange_get_length(const memorymap_addressrange return self->len; } -bool common_hal_memorymap_addressrange_set_bytes(const memorymap_addressrange_obj_t *self, +void common_hal_memorymap_addressrange_set_bytes(const memorymap_addressrange_obj_t *self, size_t start_index, uint8_t *values, size_t len) { uint8_t *address = self->start_address + start_index; #pragma GCC diagnostic push @@ -83,8 +81,6 @@ bool common_hal_memorymap_addressrange_set_bytes(const memorymap_addressrange_ob memcpy(address, values, len); } #pragma GCC diagnostic pop - - return true; } void common_hal_memorymap_addressrange_get_bytes(const memorymap_addressrange_obj_t *self, diff --git a/ports/espressif/common-hal/microcontroller/Pin.c b/ports/espressif/common-hal/microcontroller/Pin.c index 4e1efa868f..5c2724e103 100644 --- a/ports/espressif/common-hal/microcontroller/Pin.c +++ b/ports/espressif/common-hal/microcontroller/Pin.c @@ -30,7 +30,7 @@ #include "py/mphal.h" -#include "components/driver/include/driver/gpio.h" +#include "components/driver/gpio/include/driver/gpio.h" #include "components/hal/include/hal/gpio_hal.h" STATIC uint64_t _never_reset_pin_mask; @@ -38,6 +38,66 @@ STATIC uint64_t _skip_reset_once_pin_mask; STATIC uint64_t _preserved_pin_mask; STATIC uint64_t _in_use_pin_mask; +#define GPIO_SEL_0 (BIT(0)) /*!< Pin 0 selected */ +#define GPIO_SEL_1 (BIT(1)) /*!< Pin 1 selected */ +#define GPIO_SEL_2 (BIT(2)) /*!< Pin 2 selected */ +#define GPIO_SEL_3 (BIT(3)) /*!< Pin 3 selected */ +#define GPIO_SEL_4 (BIT(4)) /*!< Pin 4 selected */ +#define GPIO_SEL_5 (BIT(5)) /*!< Pin 5 selected */ +#define GPIO_SEL_6 (BIT(6)) /*!< Pin 6 selected */ +#define GPIO_SEL_7 (BIT(7)) /*!< Pin 7 selected */ +#define GPIO_SEL_8 (BIT(8)) /*!< Pin 8 selected */ +#define GPIO_SEL_9 (BIT(9)) /*!< Pin 9 selected */ +#define GPIO_SEL_10 (BIT(10)) /*!< Pin 10 selected */ +#define GPIO_SEL_11 (BIT(11)) /*!< Pin 11 selected */ +#define GPIO_SEL_12 (BIT(12)) /*!< Pin 12 selected */ +#define GPIO_SEL_13 (BIT(13)) /*!< Pin 13 selected */ +#define GPIO_SEL_14 (BIT(14)) /*!< Pin 14 selected */ +#define GPIO_SEL_15 (BIT(15)) /*!< Pin 15 selected */ +#define GPIO_SEL_16 (BIT(16)) /*!< Pin 16 selected */ +#define GPIO_SEL_17 (BIT(17)) /*!< Pin 17 selected */ +#define GPIO_SEL_18 (BIT(18)) /*!< Pin 18 selected */ +#define GPIO_SEL_19 (BIT(19)) /*!< Pin 19 selected */ +#define GPIO_SEL_20 (BIT(20)) /*!< Pin 20 selected */ +#if SOC_GPIO_PIN_COUNT > 21 +#define GPIO_SEL_21 (BIT(21)) /*!< Pin 21 selected */ +#endif +#if SOC_GPIO_PIN_COUNT > 22 +#define GPIO_SEL_22 (BIT(22)) /*!< Pin 22 selected */ +#define GPIO_SEL_23 (BIT(23)) /*!< Pin 23 selected */ +#define GPIO_SEL_24 (BIT(24)) /*!< Pin 24 selected */ +#define GPIO_SEL_25 (BIT(25)) /*!< Pin 25 selected */ +#define GPIO_SEL_26 (BIT(26)) /*!< Pin 26 selected */ +#define GPIO_SEL_27 (BIT(27)) /*!< Pin 27 selected */ +#endif +#if SOC_GPIO_PIN_COUNT > 28 +#define GPIO_SEL_28 (BIT(28)) /*!< Pin 28 selected */ +#define GPIO_SEL_29 (BIT(29)) /*!< Pin 29 selected */ +#define GPIO_SEL_30 (BIT(30)) /*!< Pin 30 selected */ +#define GPIO_SEL_31 (BIT(31)) /*!< Pin 31 selected */ +#define GPIO_SEL_32 ((uint64_t)PIN_BIT(32)) /*!< Pin 32 selected */ +#define GPIO_SEL_33 ((uint64_t)PIN_BIT(33)) /*!< Pin 33 selected */ +#define GPIO_SEL_34 ((uint64_t)PIN_BIT(34)) /*!< Pin 34 selected */ +#define GPIO_SEL_35 ((uint64_t)PIN_BIT(35)) /*!< Pin 35 selected */ +#define GPIO_SEL_36 ((uint64_t)PIN_BIT(36)) /*!< Pin 36 selected */ +#define GPIO_SEL_37 ((uint64_t)PIN_BIT(37)) /*!< Pin 37 selected */ +#define GPIO_SEL_38 ((uint64_t)PIN_BIT(38)) /*!< Pin 38 selected */ +#define GPIO_SEL_39 ((uint64_t)PIN_BIT(39)) /*!< Pin 39 selected */ +#endif +#if SOC_GPIO_PIN_COUNT > 40 +#define GPIO_SEL_40 ((uint64_t)PIN_BIT(40)) /*!< Pin 40 selected */ +#define GPIO_SEL_41 ((uint64_t)PIN_BIT(41)) /*!< Pin 41 selected */ +#define GPIO_SEL_42 ((uint64_t)PIN_BIT(42)) /*!< Pin 42 selected */ +#define GPIO_SEL_43 ((uint64_t)PIN_BIT(43)) /*!< Pin 43 selected */ +#define GPIO_SEL_44 ((uint64_t)PIN_BIT(44)) /*!< Pin 44 selected */ +#define GPIO_SEL_45 ((uint64_t)PIN_BIT(45)) /*!< Pin 45 selected */ +#define GPIO_SEL_46 ((uint64_t)PIN_BIT(46)) /*!< Pin 46 selected */ +#endif +#if SOC_GPIO_PIN_COUNT > 47 +#define GPIO_SEL_47 ((uint64_t)PIN_BIT(47)) /*!< Pin 47 selected */ +#define GPIO_SEL_48 ((uint64_t)PIN_BIT(48)) /*!< Pin 48 selected */ +#endif + // Bit mask of all pins that should never EVER be reset. // Typically these are SPI flash and PSRAM control pins, and communication pins. // "Reset forbidden" is stronger than "never reset" below, which may only be temporary. @@ -70,6 +130,51 @@ static const uint64_t pin_mask_reset_forbidden = #endif #endif // ESP32C3 + #if defined(CONFIG_IDF_TARGET_ESP32C6) + // Never ever reset pins used to communicate with SPI flash. + GPIO_SEL_24 | // SPICS0 + GPIO_SEL_25 | // SPIQ + GPIO_SEL_26 | // SPIWP + GPIO_SEL_28 | // SPIHD + GPIO_SEL_29 | // SPICLK + GPIO_SEL_30 | // SPID + #if CIRCUITPY_ESP_USB_SERIAL_JTAG + // Never ever reset serial/JTAG communication pins. + GPIO_SEL_12 | // USB D- + GPIO_SEL_13 | // USB D+ + #endif + #if defined(CONFIG_ESP_CONSOLE_UART_DEFAULT) && CONFIG_ESP_CONSOLE_UART_DEFAULT && CONFIG_ESP_CONSOLE_UART_NUM == 0 + // Never reset debug UART/console pins. + GPIO_SEL_16 | + GPIO_SEL_17 | + #endif + #endif // ESP32C6 + + #if defined(CONFIG_IDF_TARGET_ESP32H2) + // Never ever reset pins used to communicate with the in-package SPI flash. + GPIO_SEL_15 | + GPIO_SEL_16 | + GPIO_SEL_17 | + GPIO_SEL_18 | + GPIO_SEL_19 | + GPIO_SEL_20 | + GPIO_SEL_21 | + // It isn't clear what these are used for but they aren't broken out for + // user use. + GPIO_SEL_6 | + GPIO_SEL_7 | + #if CIRCUITPY_ESP_USB_SERIAL_JTAG + // Never ever reset serial/JTAG communication pins. + GPIO_SEL_26 | // USB D- + GPIO_SEL_27 | // USB D+ + #endif + #if defined(CONFIG_ESP_CONSOLE_UART_DEFAULT) && CONFIG_ESP_CONSOLE_UART_DEFAULT && CONFIG_ESP_CONSOLE_UART_NUM == 0 + // Never reset debug UART/console pins. + GPIO_SEL_23 | + GPIO_SEL_24 | + #endif + #endif // ESP32C6 + #if defined(CONFIG_IDF_TARGET_ESP32S2) || defined(CONFIG_IDF_TARGET_ESP32S3) // Never ever reset pins used to communicate with SPI flash and PSRAM. GPIO_SEL_19 | // USB D- @@ -98,6 +203,11 @@ static const uint64_t pin_mask_reset_forbidden = GPIO_SEL_19 | // USB D- GPIO_SEL_20 | // USB D+ #endif + #if defined(CONFIG_ESP_CONSOLE_UART_DEFAULT) && CONFIG_ESP_CONSOLE_UART_DEFAULT && CONFIG_ESP_CONSOLE_UART_NUM == 0 + // Don't reset/use the IDF UART console. + GPIO_SEL_43 | // UART TX + GPIO_SEL_44 | // UART RX + #endif #endif // ESP32S2, ESP32S3 0; // Terminate last "|". @@ -193,10 +303,12 @@ void preserve_pin_number(gpio_num_t pin_number) { _preserved_pin_mask |= PIN_BIT(pin_number); } if (_preserved_pin_mask) { + #if defined(SOC_GPIO_SUPPORT_HOLD_SINGLE_IO_IN_DSLP) && !SOC_GPIO_SUPPORT_HOLD_SINGLE_IO_IN_DSLP // Allow pin holds to work during deep sleep. This increases power consumption noticeably // during deep sleep, so enable holds only if we actually are holding some pins. // 270uA or so extra current is consumed even with no pins held. gpio_deep_sleep_hold_en(); + #endif } } @@ -218,6 +330,14 @@ void reset_pin_number(gpio_num_t pin_number) { _reset_pin(pin_number); } +void reset_pin_mask(uint64_t mask) { + for (int i = 0; i < 64; i++, mask >>= 1) { + if (mask & 1) { + reset_pin_number(i); + } + } +} + void common_hal_mcu_pin_reset_number(uint8_t i) { reset_pin_number((gpio_num_t)i); } @@ -232,7 +352,9 @@ void common_hal_reset_pin(const mcu_pin_obj_t *pin) { void reset_all_pins(void) { // Undo deep sleep holds in case we woke up from deep sleep. // We still need to unhold individual pins, which is done by _reset_pin. + #if defined(SOC_GPIO_SUPPORT_HOLD_SINGLE_IO_IN_DSLP) && !SOC_GPIO_SUPPORT_HOLD_SINGLE_IO_IN_DSLP gpio_deep_sleep_hold_dis(); + #endif for (uint8_t i = 0; i < GPIO_PIN_COUNT; i++) { uint32_t iomux_address = GPIO_PIN_MUX_REG[i]; @@ -244,7 +366,7 @@ void reset_all_pins(void) { } _reset_pin(i); } - _in_use_pin_mask = _never_reset_pin_mask; + _in_use_pin_mask = _never_reset_pin_mask | pin_mask_reset_forbidden; // Don't continue to skip resetting these pins. _skip_reset_once_pin_mask = 0; } diff --git a/ports/espressif/common-hal/microcontroller/Pin.h b/ports/espressif/common-hal/microcontroller/Pin.h index 05c8fe880d..8551a29a95 100644 --- a/ports/espressif/common-hal/microcontroller/Pin.h +++ b/ports/espressif/common-hal/microcontroller/Pin.h @@ -41,6 +41,8 @@ extern void reset_all_pins(void); // reset_pin_number takes the pin number instead of the pointer so that objects don't // need to store a full pointer. extern void reset_pin_number(gpio_num_t pin_number); +// reset all pins in `bitmask` +extern void reset_pin_mask(uint64_t bitmask); extern void skip_reset_once_pin_number(gpio_num_t pin_number); extern void claim_pin(const mcu_pin_obj_t *pin); extern void claim_pin_number(gpio_num_t pin_number); diff --git a/ports/espressif/common-hal/microcontroller/Processor.c b/ports/espressif/common-hal/microcontroller/Processor.c index 5b7463c9ff..4248a972f4 100644 --- a/ports/espressif/common-hal/microcontroller/Processor.c +++ b/ports/espressif/common-hal/microcontroller/Processor.c @@ -41,21 +41,23 @@ #include "soc/efuse_reg.h" #if !defined(CONFIG_IDF_TARGET_ESP32) -#include "driver/temp_sensor.h" +#include "driver/temperature_sensor.h" #endif float common_hal_mcu_processor_get_temperature(void) { - float tsens_out; + float tsens_value; #if defined(CONFIG_IDF_TARGET_ESP32) return NAN; #else - temp_sensor_config_t temp_sensor = TSENS_CONFIG_DEFAULT(); // DEFAULT: range:-10℃ ~ 80℃, error < 1℃. - temp_sensor_set_config(temp_sensor); - temp_sensor_start(); - temp_sensor_read_celsius(&tsens_out); - temp_sensor_stop(); + temperature_sensor_handle_t temp_sensor = NULL; + temperature_sensor_config_t temp_sensor_config = TEMPERATURE_SENSOR_CONFIG_DEFAULT(-10, 80); // DEFAULT: range:-10℃ ~ 80℃, error < 1℃. + temperature_sensor_install(&temp_sensor_config, &temp_sensor); + temperature_sensor_enable(temp_sensor); + temperature_sensor_get_celsius(temp_sensor, &tsens_value); + temperature_sensor_disable(temp_sensor); + temperature_sensor_uninstall(temp_sensor); #endif - return tsens_out; + return tsens_value; } float common_hal_mcu_processor_get_voltage(void) { @@ -63,17 +65,7 @@ float common_hal_mcu_processor_get_voltage(void) { } uint32_t common_hal_mcu_processor_get_frequency(void) { - #if defined(CONFIG_IDF_TARGET_ESP32) - return CONFIG_ESP32_DEFAULT_CPU_FREQ_MHZ * 1000000; - #elif defined(CONFIG_IDF_TARGET_ESP32C3) - return CONFIG_ESP32C3_DEFAULT_CPU_FREQ_MHZ * 1000000; - #elif defined(CONFIG_IDF_TARGET_ESP32S2) - return CONFIG_ESP32S2_DEFAULT_CPU_FREQ_MHZ * 1000000; - #elif defined(CONFIG_IDF_TARGET_ESP32S3) - return CONFIG_ESP32S3_DEFAULT_CPU_FREQ_MHZ * 1000000; - #else - #error No known CONFIG_IDF_TARGET_xxx found - #endif + return CONFIG_ESP_DEFAULT_CPU_FREQ_MHZ * 1000000; } STATIC uint8_t swap_nibbles(uint8_t v) { @@ -88,6 +80,8 @@ void common_hal_mcu_processor_get_uid(uint8_t raw_id[]) { #if defined(CONFIG_IDF_TARGET_ESP32) uint32_t mac_address_part = REG_READ(EFUSE_BLK0_RDATA1_REG); + #elif defined(CONFIG_IDF_TARGET_ESP32H2) + uint32_t mac_address_part = REG_READ(EFUSE_RD_MAC_SYS_0_REG); #else uint32_t mac_address_part = REG_READ(EFUSE_RD_MAC_SPI_SYS_0_REG); #endif @@ -103,6 +97,8 @@ void common_hal_mcu_processor_get_uid(uint8_t raw_id[]) { // and 16 in the high order word #if defined(CONFIG_IDF_TARGET_ESP32) mac_address_part = REG_READ(EFUSE_BLK0_RDATA2_REG); + #elif defined(CONFIG_IDF_TARGET_ESP32H2) + mac_address_part = REG_READ(EFUSE_RD_MAC_SYS_1_REG); #else mac_address_part = REG_READ(EFUSE_RD_MAC_SPI_SYS_1_REG); #endif diff --git a/ports/espressif/common-hal/microcontroller/__init__.c b/ports/espressif/common-hal/microcontroller/__init__.c index 7ec9b215f1..470bebae58 100644 --- a/ports/espressif/common-hal/microcontroller/__init__.c +++ b/ports/espressif/common-hal/microcontroller/__init__.c @@ -42,21 +42,30 @@ #include "freertos/FreeRTOS.h" -#include "soc/rtc_cntl_reg.h" #include "esp_private/system_internal.h" #if defined(CONFIG_IDF_TARGET_ESP32) +#include "soc/rtc_cntl_reg.h" #include "esp32/rom/rtc.h" #elif defined(CONFIG_IDF_TARGET_ESP32C3) +#include "soc/rtc_cntl_reg.h" #include "esp32c3/rom/rtc.h" +#elif defined(CONFIG_IDF_TARGET_ESP32C6) +#include "soc/lp_aon_reg.h" +#include "esp32c6/rom/rtc.h" #elif defined(CONFIG_IDF_TARGET_ESP32S2) +#include "soc/rtc_cntl_reg.h" #include "esp32s2/rom/rtc.h" #include "esp32s2/rom/usb/usb_persist.h" #include "esp32s2/rom/usb/chip_usb_dw_wrapper.h" #elif defined(CONFIG_IDF_TARGET_ESP32S3) +#include "soc/rtc_cntl_reg.h" #include "esp32s3/rom/rtc.h" #include "esp32s3/rom/usb/usb_persist.h" #include "esp32s3/rom/usb/chip_usb_dw_wrapper.h" +#elif defined(CONFIG_IDF_TARGET_ESP32H2) +#include "soc/lp_aon_reg.h" +#include "esp32h2/rom/rtc.h" #else #error No known CONFIG_IDF_TARGET_xxx found #endif @@ -101,10 +110,18 @@ void common_hal_mcu_on_next_reset(mcu_runmode_t runmode) { #if defined(CONFIG_IDF_TARGET_ESP32S2) || defined(CONFIG_IDF_TARGET_ESP32S3) REG_WRITE(RTC_RESET_CAUSE_REG, 0); // reset uf2 #endif + #ifdef SOC_LP_AON_SUPPORTED + REG_WRITE(LP_AON_STORE0_REG, 0); // reset safe mode + #else REG_WRITE(RTC_CNTL_STORE0_REG, 0); // reset safe mode + #endif #if !defined(CONFIG_IDF_TARGET_ESP32) + #ifdef SOC_LP_AON_SUPPORTED + REG_WRITE(LP_AON_SYS_CFG_REG, 0); // reset bootloader + #else REG_WRITE(RTC_CNTL_OPTION1_REG, 0); // reset bootloader #endif + #endif break; case RUNMODE_SAFE_MODE: // enter safe mode on next boot @@ -118,8 +135,12 @@ void common_hal_mcu_on_next_reset(mcu_runmode_t runmode) { #if defined(CONFIG_IDF_TARGET_ESP32S2) || defined(CONFIG_IDF_TARGET_ESP32S3) chip_usb_set_persist_flags(USBDC_BOOT_DFU); #endif + #ifdef SOC_LP_AON_SUPPORTED + REG_WRITE(LP_AON_SYS_CFG_REG, LP_AON_FORCE_DOWNLOAD_BOOT); + #else REG_WRITE(RTC_CNTL_OPTION1_REG, RTC_CNTL_FORCE_DOWNLOAD_BOOT); #endif + #endif break; default: break; diff --git a/ports/espressif/common-hal/neopixel_write/__init__.c b/ports/espressif/common-hal/neopixel_write/__init__.c index 148b47aeb0..6d91cc7766 100644 --- a/ports/espressif/common-hal/neopixel_write/__init__.c +++ b/ports/espressif/common-hal/neopixel_write/__init__.c @@ -44,7 +44,6 @@ #include "py/runtime.h" #include "shared-bindings/neopixel_write/__init__.h" #include "supervisor/port.h" -#include "components/driver/include/driver/rmt.h" #include "peripherals/rmt.h" // Use closer to WS2812-style timings instead of WS2812B, to accommodate more varieties. diff --git a/ports/espressif/common-hal/os/__init__.c b/ports/espressif/common-hal/os/__init__.c index 1dcd3e46e0..bc18c838ae 100644 --- a/ports/espressif/common-hal/os/__init__.c +++ b/ports/espressif/common-hal/os/__init__.c @@ -33,6 +33,7 @@ #include "shared-bindings/os/__init__.h" #include "esp_system.h" +#include "esp_random.h" STATIC const qstr os_uname_info_fields[] = { MP_QSTR_sysname, MP_QSTR_nodename, @@ -60,7 +61,7 @@ mp_obj_t common_hal_os_uname(void) { return (mp_obj_t)&os_uname_info_obj; } -bool common_hal_os_urandom(uint8_t *buffer, uint32_t length) { +bool common_hal_os_urandom(uint8_t *buffer, mp_uint_t length) { uint32_t i = 0; while (i < length) { uint32_t new_random = esp_random(); diff --git a/ports/espressif/common-hal/paralleldisplay/ParallelBus.c b/ports/espressif/common-hal/paralleldisplay/ParallelBus.c index c9ba3edd06..49008948b7 100644 --- a/ports/espressif/common-hal/paralleldisplay/ParallelBus.c +++ b/ports/espressif/common-hal/paralleldisplay/ParallelBus.c @@ -36,8 +36,8 @@ #include "common-hal/microcontroller/Pin.h" #include "py/runtime.h" -#include "i2s_lcd_driver.h" #include "driver/gpio.h" + /* * Current pin limitations for ESP32-S2 ParallelBus: * - data0 pin must be byte aligned @@ -166,11 +166,12 @@ bool common_hal_paralleldisplay_parallelbus_bus_free(mp_obj_t obj) { bool common_hal_paralleldisplay_parallelbus_begin_transaction(mp_obj_t obj) { paralleldisplay_parallelbus_obj_t *self = MP_OBJ_TO_PTR(obj); - bool r = i2s_lcd_acquire_nonblocking(self->handle, 1); - if (r) { + bool lock_acquired = false; + i2s_lcd_acquire_nonblocking(self->handle, 1, &lock_acquired); + if (lock_acquired) { gpio_set_level(self->config.pin_num_cs, false); } - return r; + return lock_acquired; } void common_hal_paralleldisplay_parallelbus_send(mp_obj_t obj, display_byte_type_t byte_type, diff --git a/ports/espressif/common-hal/pulseio/PulseIn.h b/ports/espressif/common-hal/pulseio/PulseIn.h index 55714b04b2..92db65f772 100644 --- a/ports/espressif/common-hal/pulseio/PulseIn.h +++ b/ports/espressif/common-hal/pulseio/PulseIn.h @@ -30,7 +30,6 @@ #include "common-hal/microcontroller/Pin.h" #include "py/obj.h" -#include "components/driver/include/driver/rmt.h" #include "peripherals/rmt.h" typedef struct { diff --git a/ports/espressif/common-hal/pulseio/PulseOut.h b/ports/espressif/common-hal/pulseio/PulseOut.h index 359280a86f..66b01df318 100644 --- a/ports/espressif/common-hal/pulseio/PulseOut.h +++ b/ports/espressif/common-hal/pulseio/PulseOut.h @@ -28,7 +28,6 @@ #define MICROPY_INCLUDED_ESPRESSIF_COMMON_HAL_PULSEIO_PULSEOUT_H #include "common-hal/microcontroller/Pin.h" -#include "components/driver/include/driver/rmt.h" #include "peripherals/rmt.h" #include "py/obj.h" diff --git a/ports/espressif/common-hal/pwmio/PWMOut.c b/ports/espressif/common-hal/pwmio/PWMOut.c index 519885a032..225560b34a 100644 --- a/ports/espressif/common-hal/pwmio/PWMOut.c +++ b/ports/espressif/common-hal/pwmio/PWMOut.c @@ -28,7 +28,8 @@ #include "common-hal/pwmio/PWMOut.h" #include "shared-bindings/pwmio/PWMOut.h" #include "py/runtime.h" -#include "components/driver/include/driver/ledc.h" +#include "driver/ledc.h" +#include "soc/soc.h" #define INDEX_EMPTY 0xFF @@ -40,7 +41,7 @@ STATIC bool never_reset_chan[LEDC_CHANNEL_MAX]; STATIC uint32_t calculate_duty_cycle(uint32_t frequency) { uint32_t duty_bits = 0; - uint32_t interval = LEDC_APB_CLK_HZ / frequency; + uint32_t interval = APB_CLK_FREQ / frequency; for (size_t i = 0; i < 32; i++) { if (!(interval >> i)) { duty_bits = i - 1; diff --git a/ports/espressif/common-hal/pwmio/PWMOut.h b/ports/espressif/common-hal/pwmio/PWMOut.h index cde579ce89..a7711ebf07 100644 --- a/ports/espressif/common-hal/pwmio/PWMOut.h +++ b/ports/espressif/common-hal/pwmio/PWMOut.h @@ -28,7 +28,7 @@ #define MICROPY_INCLUDED_ESPRESSIF_COMMON_HAL_PWMIO_PWMOUT_H #include "common-hal/microcontroller/Pin.h" -#include "components/driver/include/driver/ledc.h" +#include "components/driver/ledc/include/driver/ledc.h" typedef struct { mp_obj_base_t base; diff --git a/ports/espressif/common-hal/socketpool/Socket.c b/ports/espressif/common-hal/socketpool/Socket.c index 9d3c22aca8..f063873df9 100644 --- a/ports/espressif/common-hal/socketpool/Socket.c +++ b/ports/espressif/common-hal/socketpool/Socket.c @@ -402,7 +402,7 @@ void common_hal_socketpool_socket_connect(socketpool_socket_obj_t *self, #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); + lwip_freeaddrinfo(result_i); dest_addr.sin_family = AF_INET; dest_addr.sin_port = htons(port); @@ -582,7 +582,7 @@ mp_uint_t common_hal_socketpool_socket_sendto(socketpool_socket_obj_t *self, #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); + lwip_freeaddrinfo(result_i); dest_addr.sin_family = AF_INET; dest_addr.sin_port = htons(port); diff --git a/ports/espressif/common-hal/socketpool/Socket.h b/ports/espressif/common-hal/socketpool/Socket.h index dfd1cbfc11..4c86c9b379 100644 --- a/ports/espressif/common-hal/socketpool/Socket.h +++ b/ports/espressif/common-hal/socketpool/Socket.h @@ -32,6 +32,7 @@ #include "common-hal/ssl/SSLContext.h" #include "components/esp-tls/esp_tls.h" +#include "components/lwip/lwip/src/include/lwip/sockets.h" typedef struct ssl_sslsocket_obj ssl_sslsocket_obj_t; diff --git a/ports/espressif/common-hal/socketpool/SocketPool.c b/ports/espressif/common-hal/socketpool/SocketPool.c index 780e90c42c..9137ac3c8f 100644 --- a/ports/espressif/common-hal/socketpool/SocketPool.c +++ b/ports/espressif/common-hal/socketpool/SocketPool.c @@ -60,7 +60,7 @@ mp_obj_t common_hal_socketpool_socketpool_gethostbyname(socketpool_socketpool_ob .ai_socktype = SOCK_STREAM, }; struct addrinfo *res; - int err = getaddrinfo(host, NULL, &hints, &res); + int err = lwip_getaddrinfo(host, NULL, &hints, &res); if (err != 0 || res == NULL) { return mp_const_none; } @@ -72,7 +72,7 @@ mp_obj_t common_hal_socketpool_socketpool_gethostbyname(socketpool_socketpool_ob char ip_str[IP4ADDR_STRLEN_MAX]; inet_ntoa_r(*addr, ip_str, IP4ADDR_STRLEN_MAX); mp_obj_t ip_obj = mp_obj_new_str(ip_str, strlen(ip_str)); - freeaddrinfo(res); + lwip_freeaddrinfo(res); return ip_obj; } diff --git a/ports/espressif/common-hal/ssl/SSLContext.c b/ports/espressif/common-hal/ssl/SSLContext.c index 1923a9c2a9..c583cecaa7 100644 --- a/ports/espressif/common-hal/ssl/SSLContext.c +++ b/ports/espressif/common-hal/ssl/SSLContext.c @@ -32,6 +32,7 @@ #include "components/mbedtls/esp_crt_bundle/include/esp_crt_bundle.h" #include "py/runtime.h" +#include "lwip/sockets.h" void common_hal_ssl_sslcontext_construct(ssl_sslcontext_obj_t *self) { diff --git a/ports/espressif/common-hal/ssl/SSLSocket.c b/ports/espressif/common-hal/ssl/SSLSocket.c index 2446ce3005..b94924000b 100644 --- a/ports/espressif/common-hal/ssl/SSLSocket.c +++ b/ports/espressif/common-hal/ssl/SSLSocket.c @@ -33,7 +33,9 @@ #include "shared/runtime/interrupt_char.h" #include "py/mperrno.h" #include "py/runtime.h" +#include "supervisor/port.h" #include "supervisor/shared/tick.h" +#include "lwip/sockets.h" ssl_sslsocket_obj_t *common_hal_ssl_sslsocket_accept(ssl_sslsocket_obj_t *self, uint8_t *ip, uint32_t *port) { @@ -55,12 +57,16 @@ void common_hal_ssl_sslsocket_close(ssl_sslsocket_obj_t *self) { void common_hal_ssl_sslsocket_connect(ssl_sslsocket_obj_t *self, const char *host, size_t hostlen, uint32_t port) { + // Yield briefly so that the IDF can clean up memory before we need more. + port_yield(); int result = esp_tls_conn_new_sync(host, hostlen, port, &self->ssl_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); + esp_tls_error_handle_t tls_error_handle; + esp_tls_get_error_handle(self->tls, &tls_error_handle); + esp_err_t err = esp_tls_get_and_clear_last_error(tls_error_handle, &esp_tls_code, &flags); if (err == ESP_ERR_MBEDTLS_SSL_SETUP_FAILED) { mp_raise_espidf_MemoryError(); @@ -154,7 +160,9 @@ mp_uint_t common_hal_ssl_sslsocket_send(ssl_sslsocket_obj_t *self, const uint8_t 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); + esp_tls_error_handle_t tls_error_handle; + esp_tls_get_error_handle(self->tls, &tls_error_handle); + esp_err_t err = esp_tls_get_and_clear_last_error(tls_error_handle, &esp_tls_code, &flags); if (err == ESP_ERR_MBEDTLS_SSL_SETUP_FAILED) { mp_raise_espidf_MemoryError(); diff --git a/ports/espressif/common-hal/watchdog/WatchDogTimer.c b/ports/espressif/common-hal/watchdog/WatchDogTimer.c index 159c99458f..78c04ba533 100644 --- a/ports/espressif/common-hal/watchdog/WatchDogTimer.c +++ b/ports/espressif/common-hal/watchdog/WatchDogTimer.c @@ -62,7 +62,12 @@ void watchdog_reset(void) { static void wdt_config(watchdog_watchdogtimer_obj_t *self) { // enable panic hanler in WATCHDOGMODE_RESET mode // initialize Task Watchdog Timer (TWDT) - if (esp_task_wdt_init((uint32_t)self->timeout, (self->mode == WATCHDOGMODE_RESET)) != ESP_OK) { + esp_task_wdt_config_t twdt_config = { + .timeout_ms = (uint32_t)self->timeout, + .idle_core_mask = (1 << portNUM_PROCESSORS) - 1, // Bitmask of all cores + .trigger_panic = (self->mode == WATCHDOGMODE_RESET), + }; + if (esp_task_wdt_init(&twdt_config) != ESP_OK) { mp_raise_RuntimeError(translate("Initialization failed due to lack of memory")); } esp_task_wdt_add(NULL); diff --git a/ports/espressif/common-hal/wifi/Radio.c b/ports/espressif/common-hal/wifi/Radio.c index e6385ee1e5..b96c76adff 100644 --- a/ports/espressif/common-hal/wifi/Radio.c +++ b/ports/espressif/common-hal/wifi/Radio.c @@ -44,7 +44,7 @@ #include "components/lwip/include/apps/ping/ping_sock.h" #if CIRCUITPY_MDNS -#include "components/mdns/include/mdns.h" +#include "mdns.h" #endif #define MAC_ADDRESS_LENGTH 6 diff --git a/ports/espressif/common-hal/wifi/Radio.h b/ports/espressif/common-hal/wifi/Radio.h index 3c0828bf0b..ddab4b2a5b 100644 --- a/ports/espressif/common-hal/wifi/Radio.h +++ b/ports/espressif/common-hal/wifi/Radio.h @@ -34,6 +34,8 @@ #include "shared-bindings/wifi/ScannedNetworks.h" #include "shared-bindings/wifi/Network.h" +#include "esp_netif_types.h" + // Event bits for the Radio event group. #define WIFI_SCAN_DONE_BIT BIT0 #define WIFI_CONNECTED_BIT BIT1 diff --git a/ports/espressif/common-hal/wifi/__init__.c b/ports/espressif/common-hal/wifi/__init__.c index cfcfaf024b..970eb8eb04 100644 --- a/ports/espressif/common-hal/wifi/__init__.c +++ b/ports/espressif/common-hal/wifi/__init__.c @@ -32,6 +32,7 @@ #include "shared-bindings/wifi/Monitor.h" #include "shared-bindings/wifi/Radio.h" +#include "py/gc.h" #include "py/mpstate.h" #include "py/runtime.h" @@ -121,7 +122,7 @@ static void event_handler(void *arg, esp_event_base_t event_base, // Cases to handle later. // case WIFI_EVENT_STA_AUTHMODE_CHANGE: default: { - ESP_LOGW(TAG, "event %d 0x%02x", event_id, event_id); + ESP_LOGW(TAG, "event %ld 0x%02ld", event_id, event_id); break; } } @@ -162,8 +163,8 @@ void common_hal_wifi_init(bool user_initiated) { if (!wifi_ever_inited) { ESP_ERROR_CHECK(esp_netif_init()); ESP_ERROR_CHECK(esp_event_loop_create_default()); + wifi_ever_inited = true; } - wifi_ever_inited = true; self->netif = esp_netif_create_default_wifi_sta(); self->ap_netif = esp_netif_create_default_wifi_ap(); @@ -189,7 +190,8 @@ void common_hal_wifi_init(bool user_initiated) { &self->handler_instance_got_ip)); wifi_init_config_t config = WIFI_INIT_CONFIG_DEFAULT(); - #ifdef CONFIG_IDF_TARGET_ESP32 + #ifdef CONFIG_ESP32_WIFI_NVS_ENABLED + // Generally we don't use this because we store ssid and passwords ourselves in the filesystem. esp_err_t err = nvs_flash_init(); if (err == ESP_ERR_NVS_NO_FREE_PAGES || err == ESP_ERR_NVS_NEW_VERSION_FOUND) { // NVS partition was truncated and needs to be erased @@ -201,9 +203,16 @@ void common_hal_wifi_init(bool user_initiated) { #endif esp_err_t result = esp_wifi_init(&config); if (result == ESP_ERR_NO_MEM) { - mp_raise_msg(&mp_type_MemoryError, translate("Failed to allocate Wifi memory")); + if (gc_alloc_possible()) { + mp_raise_msg(&mp_type_MemoryError, translate("Failed to allocate Wifi memory")); + } + ESP_LOGE(TAG, "Failed to allocate Wifi memory"); } else if (result != ESP_OK) { - raise_esp_error(result); + if (gc_alloc_possible()) { + raise_esp_error(result); + } + ESP_LOGE(TAG, "WiFi error code: %x", result); + return; } // set station mode to avoid the default SoftAP common_hal_wifi_radio_start_station(self); diff --git a/ports/espressif/esp-camera b/ports/espressif/esp-camera new file mode 160000 index 0000000000..8f3f2cc8cf --- /dev/null +++ b/ports/espressif/esp-camera @@ -0,0 +1 @@ +Subproject commit 8f3f2cc8cfb2e4371870b0c5a974d40468114a9e diff --git a/ports/espressif/esp-idf b/ports/espressif/esp-idf index 630c2724fc..fb07ab7f00 160000 --- a/ports/espressif/esp-idf +++ b/ports/espressif/esp-idf @@ -1 +1 @@ -Subproject commit 630c2724fc8c69eeaaa1bb025de52b99c5cb11aa +Subproject commit fb07ab7f0007549d38081cfc6d83348780526a28 diff --git a/ports/espressif/esp-idf-config/sdkconfig-ble.defaults b/ports/espressif/esp-idf-config/sdkconfig-ble.defaults index 8180786fbf..c260c38016 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-ble.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-ble.defaults @@ -1,164 +1,37 @@ # +# Espressif IoT Development Framework Configuration +# +# # Component config # # # Bluetooth # CONFIG_BT_ENABLED=y -# -# Bluetooth controller -# -CONFIG_BT_CTRL_MODE_EFF=1 -CONFIG_BT_CTRL_BLE_MAX_ACT=10 -CONFIG_BT_CTRL_BLE_MAX_ACT_EFF=10 -CONFIG_BT_CTRL_BLE_STATIC_ACL_TX_BUF_NB=0 -CONFIG_BT_CTRL_PINNED_TO_CORE=0 -CONFIG_BT_CTRL_HCI_MODE_VHCI=y -# CONFIG_BT_CTRL_HCI_MODE_UART_H4 is not set -CONFIG_BT_CTRL_HCI_TL=1 -CONFIG_BT_CTRL_ADV_DUP_FILT_MAX=30 -# CONFIG_BT_CTRL_HW_CCA is not set -CONFIG_BT_CTRL_HW_CCA_VAL=20 -CONFIG_BT_CTRL_HW_CCA_EFF=0 -CONFIG_BT_CTRL_CE_LENGTH_TYPE_ORIG=y -# CONFIG_BT_CTRL_CE_LENGTH_TYPE_CE is not set -# CONFIG_BT_CTRL_CE_LENGTH_TYPE_SD is not set -CONFIG_BT_CTRL_CE_LENGTH_TYPE_EFF=0 -CONFIG_BT_CTRL_TX_ANTENNA_INDEX_0=y -# CONFIG_BT_CTRL_TX_ANTENNA_INDEX_1 is not set -CONFIG_BT_CTRL_TX_ANTENNA_INDEX_EFF=0 -CONFIG_BT_CTRL_RX_ANTENNA_INDEX_0=y -# CONFIG_BT_CTRL_RX_ANTENNA_INDEX_1 is not set -CONFIG_BT_CTRL_RX_ANTENNA_INDEX_EFF=0 -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_N27 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_N24 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_N21 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_N18 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_N15 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_N12 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_N9 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_N6 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_N3 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_N0 is not set -CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_P3=y -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_P6 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_P9 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_P12 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_P15 is not set -# CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_P18 is not set -CONFIG_BT_CTRL_DFT_TX_POWER_LEVEL_EFF=10 -CONFIG_BT_CTRL_BLE_ADV_REPORT_FLOW_CTRL_SUPP=y -CONFIG_BT_CTRL_BLE_ADV_REPORT_FLOW_CTRL_NUM=100 -CONFIG_BT_CTRL_BLE_ADV_REPORT_DISCARD_THRSHOLD=20 -# CONFIG_BT_CTRL_BLE_SCAN_DUPL is not set -# CONFIG_BT_CTRL_COEX_PHY_CODED_TX_RX_TLIM_EN is not set -CONFIG_BT_CTRL_COEX_PHY_CODED_TX_RX_TLIM_DIS=y -CONFIG_BT_CTRL_COEX_PHY_CODED_TX_RX_TLIM_EFF=0 -# -# MODEM SLEEP Options -# -# CONFIG_BT_CTRL_MODEM_SLEEP is not set -# end of MODEM SLEEP Options - -CONFIG_BT_CTRL_SLEEP_MODE_EFF=0 -CONFIG_BT_CTRL_SLEEP_CLOCK_EFF=0 -CONFIG_BT_CTRL_HCI_TL_EFF=1 -# CONFIG_BT_CTRL_AGC_RECORRECT_EN is not set -# end of Bluetooth controller - -# CONFIG_BT_BLUEDROID_ENABLED is not set CONFIG_BT_NIMBLE_ENABLED=y -# CONFIG_BT_CONTROLLER_ONLY is not set # # NimBLE Options # -CONFIG_BT_NIMBLE_MEM_ALLOC_MODE_INTERNAL=y -# CONFIG_BT_NIMBLE_MEM_ALLOC_MODE_DEFAULT is not set -# CONFIG_BT_NIMBLE_LOG_LEVEL_NONE is not set -# CONFIG_BT_NIMBLE_LOG_LEVEL_ERROR is not set -# CONFIG_BT_NIMBLE_LOG_LEVEL_WARNING is not set -CONFIG_BT_NIMBLE_LOG_LEVEL_INFO=y -# CONFIG_BT_NIMBLE_LOG_LEVEL_DEBUG is not set -CONFIG_BT_NIMBLE_LOG_LEVEL=1 -CONFIG_BT_NIMBLE_MAX_CONNECTIONS=3 -CONFIG_BT_NIMBLE_MAX_BONDS=3 -CONFIG_BT_NIMBLE_MAX_CCCDS=8 -CONFIG_BT_NIMBLE_L2CAP_COC_MAX_NUM=0 -CONFIG_BT_NIMBLE_TASK_STACK_SIZE=4096 -CONFIG_BT_NIMBLE_ROLE_CENTRAL=y -CONFIG_BT_NIMBLE_ROLE_PERIPHERAL=y -CONFIG_BT_NIMBLE_ROLE_BROADCASTER=y -CONFIG_BT_NIMBLE_ROLE_OBSERVER=y +CONFIG_BT_NIMBLE_LOG_LEVEL_NONE=y CONFIG_BT_NIMBLE_NVS_PERSIST=y -CONFIG_BT_NIMBLE_SM_LEGACY=y -CONFIG_BT_NIMBLE_SM_SC=y -# CONFIG_BT_NIMBLE_DEBUG is not set -# CONFIG_BT_NIMBLE_SM_SC_DEBUG_KEYS is not set -CONFIG_BT_NIMBLE_SVC_GAP_DEVICE_NAME="nimble" -CONFIG_BT_NIMBLE_GAP_DEVICE_NAME_MAX_LEN=31 -CONFIG_BT_NIMBLE_ATT_PREFERRED_MTU=256 -CONFIG_BT_NIMBLE_SVC_GAP_APPEARANCE=0 +# +# Memory Settings +# CONFIG_BT_NIMBLE_ACL_BUF_COUNT=20 -CONFIG_BT_NIMBLE_ACL_BUF_SIZE=255 CONFIG_BT_NIMBLE_HCI_EVT_BUF_SIZE=70 -CONFIG_BT_NIMBLE_HCI_EVT_HI_BUF_COUNT=30 -CONFIG_BT_NIMBLE_HCI_EVT_LO_BUF_COUNT=8 -CONFIG_BT_NIMBLE_MSYS1_BLOCK_COUNT=12 -# CONFIG_BT_NIMBLE_HS_FLOW_CTRL is not set -CONFIG_BT_NIMBLE_RPA_TIMEOUT=900 -# CONFIG_BT_NIMBLE_MESH is not set -CONFIG_BT_NIMBLE_CRYPTO_STACK_MBEDTLS=y -CONFIG_BT_NIMBLE_HS_STOP_TIMEOUT_MS=2000 -# CONFIG_BT_NIMBLE_HOST_BASED_PRIVACY is not set -CONFIG_BT_NIMBLE_ENABLE_CONN_REATTEMPT=y -CONFIG_BT_NIMBLE_MAX_CONN_REATTEMPT=3 +# end of Memory Settings + CONFIG_BT_NIMBLE_EXT_ADV=y -CONFIG_BT_NIMBLE_MAX_EXT_ADV_INSTANCES=1 -CONFIG_BT_NIMBLE_MAX_EXT_ADV_DATA_LEN=1650 -CONFIG_BT_NIMBLE_ENABLE_PERIODIC_ADV=y -CONFIG_BT_NIMBLE_MAX_PERIODIC_SYNCS=1 -# CONFIG_BT_NIMBLE_BLUFI_ENABLE is not set -CONFIG_BT_NIMBLE_USE_ESP_TIMER=y # end of NimBLE Options +# +# Controller Options +# +# CONFIG_BT_CTRL_BLE_SCAN_DUPL is not set +# end of Controller Options + # end of Bluetooth # end of Component config -# -# Deprecated options for backward compatibility -# -# CONFIG_BLUEDROID_ENABLED is not set -CONFIG_NIMBLE_ENABLED=y -CONFIG_NIMBLE_MEM_ALLOC_MODE_INTERNAL=y -# CONFIG_NIMBLE_MEM_ALLOC_MODE_DEFAULT is not set -CONFIG_NIMBLE_MAX_CONNECTIONS=3 -CONFIG_NIMBLE_MAX_BONDS=3 -CONFIG_NIMBLE_MAX_CCCDS=8 -CONFIG_NIMBLE_L2CAP_COC_MAX_NUM=0 -CONFIG_NIMBLE_TASK_STACK_SIZE=4096 -CONFIG_NIMBLE_ROLE_CENTRAL=y -CONFIG_NIMBLE_ROLE_PERIPHERAL=y -CONFIG_NIMBLE_ROLE_BROADCASTER=y -CONFIG_NIMBLE_ROLE_OBSERVER=y -CONFIG_NIMBLE_NVS_PERSIST=y -CONFIG_NIMBLE_SM_LEGACY=y -CONFIG_NIMBLE_SM_SC=y -# CONFIG_NIMBLE_DEBUG is not set -# CONFIG_NIMBLE_SM_SC_DEBUG_KEYS is not set -CONFIG_NIMBLE_SVC_GAP_DEVICE_NAME="nimble" -CONFIG_NIMBLE_GAP_DEVICE_NAME_MAX_LEN=31 -CONFIG_NIMBLE_ATT_PREFERRED_MTU=256 -CONFIG_NIMBLE_SVC_GAP_APPEARANCE=0 -CONFIG_NIMBLE_ACL_BUF_COUNT=20 -CONFIG_NIMBLE_ACL_BUF_SIZE=255 -CONFIG_NIMBLE_HCI_EVT_BUF_SIZE=70 -CONFIG_NIMBLE_HCI_EVT_HI_BUF_COUNT=30 -CONFIG_NIMBLE_HCI_EVT_LO_BUF_COUNT=8 -CONFIG_NIMBLE_MSYS1_BLOCK_COUNT=12 -# CONFIG_NIMBLE_HS_FLOW_CTRL is not set -CONFIG_NIMBLE_RPA_TIMEOUT=900 -# CONFIG_NIMBLE_MESH is not set -CONFIG_NIMBLE_CRYPTO_STACK_MBEDTLS=y -CONFIG_SW_COEXIST_ENABLE=y -# end of Deprecated options for backward compatibility +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-debug.defaults b/ports/espressif/esp-idf-config/sdkconfig-debug.defaults index bef5ee5fe8..5976192600 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-debug.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-debug.defaults @@ -1,95 +1,21 @@ # -# Bootloader config +# Espressif IoT Development Framework Configuration # -CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_SIZE=y -# CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_DEBUG is not set -# CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_PERF is not set -# CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_NONE is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_NONE is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_ERROR is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_WARN is not set -CONFIG_BOOTLOADER_LOG_LEVEL_INFO=y -# CONFIG_BOOTLOADER_LOG_LEVEL_DEBUG is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_VERBOSE is not set -# end of Bootloader config - -# CONFIG_COMPILER_OPTIMIZATION_DEFAULT is not set # # Compiler options # CONFIG_COMPILER_OPTIMIZATION_SIZE=y -# CONFIG_COMPILER_OPTIMIZATION_PERF is not set -# CONFIG_COMPILER_OPTIMIZATION_NONE is not set -CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_ENABLE=y -# CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_SILENT is not set -# CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_DISABLE is not set -CONFIG_COMPILER_OPTIMIZATION_ASSERTION_LEVEL=2 -# CONFIG_COMPILER_OPTIMIZATION_CHECKS_SILENT is not set # end of Compiler options -CONFIG_ESP_ERR_TO_NAME_LOOKUP=y +# +# Component config +# # # ESP System Settings # CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -# CONFIG_ESP_SYSTEM_PANIC_PRINT_REBOOT is not set -# CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -# CONFIG_ESP_SYSTEM_PANIC_GDBSTUB is not set # end of ESP System Settings -CONFIG_ESP_CONSOLE_UART_DEFAULT=y -# CONFIG_ESP_CONSOLE_USB_CDC is not set -# CONFIG_ESP_CONSOLE_UART_CUSTOM is not set -# CONFIG_ESP_CONSOLE_NONE is not set -CONFIG_ESP_CONSOLE_UART=y -CONFIG_ESP_CONSOLE_MULTIPLE_UART=y -CONFIG_ESP_CONSOLE_UART_NUM=0 -CONFIG_ESP_CONSOLE_UART_BAUDRATE=115200 -# -# FreeRTOS -# -CONFIG_FREERTOS_ASSERT_ON_UNTESTED_FUNCTION=y -CONFIG_FREERTOS_ASSERT_FAIL_ABORT=y -# CONFIG_FREERTOS_ASSERT_FAIL_PRINT_CONTINUE is not set -# CONFIG_FREERTOS_ASSERT_DISABLE is not set -CONFIG_FREERTOS_TASK_FUNCTION_WRAPPER=y -CONFIG_FREERTOS_DEBUG_OCDAWARE=y -# end of FreeRTOS +# end of Component config -CONFIG_HAL_ASSERTION_EQUALS_SYSTEM=y -# -# Hardware Abstraction Layer (HAL) and Low Level (LL) -# -# CONFIG_HAL_ASSERTION_DISABLE is not set -# CONFIG_HAL_ASSERTION_SILIENT is not set -# CONFIG_HAL_ASSERTION_ENABLE is not set -CONFIG_HAL_DEFAULT_ASSERTION_LEVEL=2 -# end of Hardware Abstraction Layer (HAL) and Low Level (LL) - -# -# Log output -# -# CONFIG_LOG_DEFAULT_LEVEL_NONE is not set -# CONFIG_LOG_DEFAULT_LEVEL_ERROR is not set -# CONFIG_LOG_DEFAULT_LEVEL_WARN is not set -CONFIG_LOG_DEFAULT_LEVEL_INFO=y -# CONFIG_LOG_DEFAULT_LEVEL_DEBUG is not set -# CONFIG_LOG_DEFAULT_LEVEL_VERBOSE is not set -# end of Log output - -CONFIG_LWIP_ESP_LWIP_ASSERT=y -# -# Deprecated options for backward compatibility -# -CONFIG_COMPILER_OPTIMIZATION_LEVEL_DEBUG=y -# CONFIG_COMPILER_OPTIMIZATION_LEVEL_RELEASE is not set -CONFIG_OPTIMIZATION_ASSERTIONS_ENABLED=y -# CONFIG_OPTIMIZATION_ASSERTIONS_SILENT is not set -# CONFIG_OPTIMIZATION_ASSERTIONS_DISABLED is not set -CONFIG_OPTIMIZATION_ASSERTION_LEVEL=2 -CONFIG_CONSOLE_UART_DEFAULT=y -# CONFIG_CONSOLE_UART_CUSTOM is not set -# CONFIG_ESP_CONSOLE_UART_NONE is not set -CONFIG_CONSOLE_UART_NUM=0 -CONFIG_CONSOLE_UART_BAUDRATE=115200 -# end of Deprecated options for backward compatibility +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-esp32.defaults b/ports/espressif/esp-idf-config/sdkconfig-esp32.defaults index b6c5a938b1..de30ada541 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-esp32.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-esp32.defaults @@ -1,1143 +1,78 @@ # -# Espressif IoT Development Framework (ESP-IDF) Project Configuration +# Espressif IoT Development Framework Configuration # -CONFIG_IDF_TARGET_ARCH_XTENSA=y -CONFIG_IDF_TARGET="esp32" -CONFIG_IDF_TARGET_ESP32=y -CONFIG_IDF_FIRMWARE_CHIP_ID=0x0000 - -# -# SDK tool configuration -# -CONFIG_SDK_TOOLPREFIX="xtensa-esp32-elf-" -# CONFIG_SDK_TOOLCHAIN_SUPPORTS_TIME_WIDE_64_BITS is not set -# end of SDK tool configuration - -# -# Build type -# -CONFIG_APP_BUILD_TYPE_APP_2NDBOOT=y -# CONFIG_APP_BUILD_TYPE_ELF_RAM is not set -CONFIG_APP_BUILD_GENERATE_BINARIES=y -CONFIG_APP_BUILD_BOOTLOADER=y -CONFIG_APP_BUILD_USE_FLASH_SECTIONS=y -# end of Build type - -# -# Application manager -# -CONFIG_APP_COMPILE_TIME_DATE=y -# CONFIG_APP_EXCLUDE_PROJECT_VER_VAR is not set -# CONFIG_APP_EXCLUDE_PROJECT_NAME_VAR is not set -# CONFIG_APP_PROJECT_VER_FROM_CONFIG is not set -CONFIG_APP_RETRIEVE_LEN_ELF_SHA=16 -# end of Application manager - -# -# Bootloader config -# -CONFIG_BOOTLOADER_OFFSET_IN_FLASH=0x1000 -CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_SIZE=y -# CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_DEBUG is not set -# CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_PERF is not set -# CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_NONE is not set -CONFIG_BOOTLOADER_LOG_LEVEL_NONE=y -# CONFIG_BOOTLOADER_LOG_LEVEL_ERROR is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_WARN is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_INFO is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_DEBUG is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_VERBOSE is not set -CONFIG_BOOTLOADER_LOG_LEVEL=0 -# CONFIG_BOOTLOADER_VDDSDIO_BOOST_1_8V is not set -CONFIG_BOOTLOADER_VDDSDIO_BOOST_1_9V=y -# CONFIG_BOOTLOADER_FACTORY_RESET is not set -# CONFIG_BOOTLOADER_APP_TEST is not set -CONFIG_BOOTLOADER_WDT_ENABLE=y -# CONFIG_BOOTLOADER_WDT_DISABLE_IN_USER_CODE is not set -CONFIG_BOOTLOADER_WDT_TIME_MS=9000 -# CONFIG_BOOTLOADER_APP_ROLLBACK_ENABLE is not set -# CONFIG_BOOTLOADER_SKIP_VALIDATE_IN_DEEP_SLEEP is not set -# CONFIG_BOOTLOADER_SKIP_VALIDATE_ON_POWER_ON is not set -# CONFIG_BOOTLOADER_SKIP_VALIDATE_ALWAYS is not set -CONFIG_BOOTLOADER_RESERVE_RTC_SIZE=0 -# CONFIG_BOOTLOADER_CUSTOM_RESERVE_RTC is not set -CONFIG_BOOTLOADER_FLASH_XMC_SUPPORT=y -# end of Bootloader config - -# -# Security features -# -# CONFIG_SECURE_SIGNED_APPS_NO_SECURE_BOOT is not set -# CONFIG_SECURE_BOOT is not set -# CONFIG_SECURE_FLASH_ENC_ENABLED is not set -# end of Security features - -# -# Serial flasher config -# -CONFIG_ESPTOOLPY_BAUD_OTHER_VAL=115200 -# CONFIG_ESPTOOLPY_NO_STUB is not set -# CONFIG_ESPTOOLPY_FLASHMODE_QIO is not set -# CONFIG_ESPTOOLPY_FLASHMODE_QOUT is not set -CONFIG_ESPTOOLPY_FLASHMODE_DIO=y -# CONFIG_ESPTOOLPY_FLASHMODE_DOUT is not set -CONFIG_ESPTOOLPY_FLASH_SAMPLE_MODE_STR=y -CONFIG_ESPTOOLPY_FLASHMODE="dio" -# CONFIG_ESPTOOLPY_FLASHFREQ_80M is not set -CONFIG_ESPTOOLPY_FLASHFREQ_40M=y -# CONFIG_ESPTOOLPY_FLASHFREQ_26M is not set -# CONFIG_ESPTOOLPY_FLASHFREQ_20M is not set -CONFIG_ESPTOOLPY_FLASHFREQ="40m" -# CONFIG_ESPTOOLPY_FLASHSIZE_1MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_2MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_4MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_8MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_16MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_32MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_64MB is not set -# CONFIG_ESPTOOLPY_FLASHSIZE_128MB is not set -CONFIG_ESPTOOLPY_FLASHSIZE_DETECT=y -CONFIG_ESPTOOLPY_BEFORE_RESET=y -# CONFIG_ESPTOOLPY_BEFORE_NORESET is not set -CONFIG_ESPTOOLPY_BEFORE="default_reset" -CONFIG_ESPTOOLPY_AFTER_RESET=y -# CONFIG_ESPTOOLPY_AFTER_NORESET is not set -CONFIG_ESPTOOLPY_AFTER="hard_reset" -# CONFIG_ESPTOOLPY_MONITOR_BAUD_CONSOLE is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_9600B is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_57600B is not set -CONFIG_ESPTOOLPY_MONITOR_BAUD_115200B=y -# CONFIG_ESPTOOLPY_MONITOR_BAUD_230400B is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_921600B is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_2MB is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_OTHER is not set -CONFIG_ESPTOOLPY_MONITOR_BAUD_OTHER_VAL=115200 -CONFIG_ESPTOOLPY_MONITOR_BAUD=115200 -# end of Serial flasher config - -# -# Compiler options -# -# CONFIG_COMPILER_OPTIMIZATION_DEFAULT is not set -CONFIG_COMPILER_OPTIMIZATION_SIZE=y -# CONFIG_COMPILER_OPTIMIZATION_PERF is not set -# CONFIG_COMPILER_OPTIMIZATION_NONE is not set -CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_ENABLE=y -# CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_SILENT is not set -# CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_DISABLE is not set -CONFIG_COMPILER_OPTIMIZATION_ASSERTION_LEVEL=2 -# CONFIG_COMPILER_OPTIMIZATION_CHECKS_SILENT is not set -CONFIG_COMPILER_HIDE_PATHS_MACROS=y -# CONFIG_COMPILER_CXX_EXCEPTIONS is not set -# CONFIG_COMPILER_CXX_RTTI is not set -CONFIG_COMPILER_STACK_CHECK_MODE_NONE=y -# CONFIG_COMPILER_STACK_CHECK_MODE_NORM is not set -# CONFIG_COMPILER_STACK_CHECK_MODE_STRONG is not set -# CONFIG_COMPILER_STACK_CHECK_MODE_ALL is not set -# CONFIG_COMPILER_WARN_WRITE_STRINGS is not set -# CONFIG_COMPILER_DISABLE_GCC8_WARNINGS is not set -# CONFIG_COMPILER_DUMP_RTL_FILES is not set -# end of Compiler options - # # Component config # - # -# Application Level Tracing +# Driver Configurations # -# CONFIG_APPTRACE_DEST_JTAG is not set -CONFIG_APPTRACE_DEST_NONE=y -CONFIG_APPTRACE_LOCK_ENABLE=y -# end of Application Level Tracing - # -# Bluetooth +# TWAI Configuration # -# CONFIG_BT_ENABLED is not set -# end of Bluetooth - -# -# Driver configurations -# - -# -# ADC configuration -# -# CONFIG_ADC_FORCE_XPD_FSM is not set -CONFIG_ADC_DISABLE_DAC=y -# end of ADC configuration - -# -# MCPWM configuration -# -# CONFIG_MCPWM_ISR_IN_IRAM is not set -# end of MCPWM configuration - -# -# SPI configuration -# -# CONFIG_SPI_MASTER_IN_IRAM is not set -CONFIG_SPI_MASTER_ISR_IN_IRAM=y -# CONFIG_SPI_SLAVE_IN_IRAM is not set -CONFIG_SPI_SLAVE_ISR_IN_IRAM=y -# end of SPI configuration - -# -# TWAI configuration -# -# CONFIG_TWAI_ISR_IN_IRAM is not set # CONFIG_TWAI_ERRATA_FIX_BUS_OFF_REC is not set # CONFIG_TWAI_ERRATA_FIX_TX_INTR_LOST is not set # CONFIG_TWAI_ERRATA_FIX_RX_FRAME_INVALID is not set # CONFIG_TWAI_ERRATA_FIX_RX_FIFO_CORRUPT is not set -# end of TWAI configuration +# end of TWAI Configuration # -# UART configuration +# PCNT Configuration # -CONFIG_UART_ISR_IN_IRAM=y -# end of UART configuration +CONFIG_PCNT_SUPPRESS_DEPRECATE_WARN=y +# end of PCNT Configuration # -# RTCIO configuration +# RMT Configuration # -# CONFIG_RTCIO_SUPPORT_RTC_GPIO_DESC is not set -# end of RTCIO configuration +CONFIG_RMT_SUPPRESS_DEPRECATE_WARN=y +# end of RMT Configuration + +# end of Driver Configurations # -# GPIO Configuration +# ESP System Settings # -# CONFIG_GPIO_ESP32_SUPPORT_SWITCH_SLP_PULL is not set -# end of GPIO Configuration - -# -# GDMA Configuration -# -# CONFIG_GDMA_CTRL_FUNC_IN_IRAM is not set -# CONFIG_GDMA_ISR_IRAM_SAFE is not set -# end of GDMA Configuration -# end of Driver configurations - -# -# eFuse Bit Manager -# -# CONFIG_EFUSE_CUSTOM_TABLE is not set -# CONFIG_EFUSE_VIRTUAL is not set -# CONFIG_EFUSE_CODE_SCHEME_COMPAT_NONE is not set -CONFIG_EFUSE_CODE_SCHEME_COMPAT_3_4=y -# CONFIG_EFUSE_CODE_SCHEME_COMPAT_REPEAT is not set -CONFIG_EFUSE_MAX_BLK_LEN=192 -# end of eFuse Bit Manager - -# -# ESP-TLS -# -CONFIG_ESP_TLS_USING_MBEDTLS=y -# CONFIG_ESP_TLS_USE_SECURE_ELEMENT is not set -# CONFIG_ESP_TLS_CLIENT_SESSION_TICKETS is not set -CONFIG_ESP_TLS_SERVER=y -# CONFIG_ESP_TLS_SERVER_SESSION_TICKETS is not set -# CONFIG_ESP_TLS_SERVER_MIN_AUTH_MODE_OPTIONAL is not set -# CONFIG_ESP_TLS_PSK_VERIFICATION is not set -# CONFIG_ESP_TLS_INSECURE is not set -# end of ESP-TLS - -# -# ESP32-specific -# -CONFIG_ESP32_ECO3_CACHE_LOCK_FIX=y -CONFIG_ESP32_REV_MIN_0=y -# CONFIG_ESP32_REV_MIN_1 is not set -# CONFIG_ESP32_REV_MIN_2 is not set -# CONFIG_ESP32_REV_MIN_3 is not set -CONFIG_ESP32_REV_MIN=0 -CONFIG_ESP32_DPORT_WORKAROUND=y -# CONFIG_ESP32_DEFAULT_CPU_FREQ_80 is not set -# CONFIG_ESP32_DEFAULT_CPU_FREQ_160 is not set -CONFIG_ESP32_DEFAULT_CPU_FREQ_240=y -CONFIG_ESP32_DEFAULT_CPU_FREQ_MHZ=240 -# CONFIG_ESP32_SPIRAM_SUPPORT is not set - -# -# SPIRAM cache workaround debugging -# -CONFIG_SPIRAM_CACHE_WORKAROUND_STRATEGY_MEMW=y -# CONFIG_SPIRAM_CACHE_WORKAROUND_STRATEGY_DUPLDST is not set -# CONFIG_SPIRAM_CACHE_WORKAROUND_STRATEGY_NOPS is not set -# end of SPIRAM cache workaround debugging - -# -# SPIRAM workaround libraries placement -# -CONFIG_SPIRAM_CACHE_LIBJMP_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBMATH_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBNUMPARSER_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBIO_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBTIME_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBCHAR_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBMEM_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBSTR_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBRAND_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBENV_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBFILE_IN_IRAM=y -CONFIG_SPIRAM_CACHE_LIBMISC_IN_IRAM=y -# end of SPIRAM workaround libraries placement - -CONFIG_SPIRAM_BANKSWITCH_ENABLE=n - -# -# PSRAM clock and cs IO for ESP32-DOWD -# -CONFIG_D0WD_PSRAM_CLK_IO=17 -CONFIG_D0WD_PSRAM_CS_IO=16 -# end of PSRAM clock and cs IO for ESP32-DOWD - -# -# PSRAM clock and cs IO for ESP32-D2WD -# -CONFIG_D2WD_PSRAM_CLK_IO=9 -CONFIG_D2WD_PSRAM_CS_IO=10 -# end of PSRAM clock and cs IO for ESP32-D2WD - -# -# PSRAM clock and cs IO for ESP32-PICO -# -CONFIG_PICO_PSRAM_CS_IO=10 -# end of PSRAM clock and cs IO for ESP32-PICO - -# CONFIG_SPIRAM_CUSTOM_SPIWP_SD3_PIN is not set -CONFIG_SPIRAM_SPIWP_SD3_PIN=7 -# CONFIG_SPIRAM_2T_MODE is not set -# end of SPI RAM config - -# CONFIG_ESP32_TRAX is not set -CONFIG_ESP32_TRACEMEM_RESERVE_DRAM=0x0 -CONFIG_ESP32_ULP_COPROC_ENABLED=y -CONFIG_ESP32_ULP_COPROC_RESERVE_MEM=4080 -CONFIG_ESP32_DEBUG_OCDAWARE=y -CONFIG_ESP32_BROWNOUT_DET=y -CONFIG_ESP32_BROWNOUT_DET_LVL_SEL_0=y -# CONFIG_ESP32_BROWNOUT_DET_LVL_SEL_1 is not set -# CONFIG_ESP32_BROWNOUT_DET_LVL_SEL_2 is not set -# CONFIG_ESP32_BROWNOUT_DET_LVL_SEL_3 is not set -# CONFIG_ESP32_BROWNOUT_DET_LVL_SEL_4 is not set -# CONFIG_ESP32_BROWNOUT_DET_LVL_SEL_5 is not set -# CONFIG_ESP32_BROWNOUT_DET_LVL_SEL_6 is not set -# CONFIG_ESP32_BROWNOUT_DET_LVL_SEL_7 is not set -CONFIG_ESP32_BROWNOUT_DET_LVL=0 -CONFIG_ESP32_TIME_SYSCALL_USE_RTC_FRC1=y -# CONFIG_ESP32_TIME_SYSCALL_USE_RTC is not set -# CONFIG_ESP32_TIME_SYSCALL_USE_FRC1 is not set -# CONFIG_ESP32_TIME_SYSCALL_USE_NONE is not set -CONFIG_ESP32_RTC_CLK_SRC_INT_RC=y -# CONFIG_ESP32_RTC_CLK_SRC_EXT_CRYS is not set -# CONFIG_ESP32_RTC_CLK_SRC_EXT_OSC is not set -# CONFIG_ESP32_RTC_CLK_SRC_INT_8MD256 is not set -CONFIG_ESP32_RTC_CLK_CAL_CYCLES=1024 -CONFIG_ESP32_DEEP_SLEEP_WAKEUP_DELAY=2000 -CONFIG_ESP32_XTAL_FREQ_40=y -# CONFIG_ESP32_XTAL_FREQ_26 is not set -# CONFIG_ESP32_XTAL_FREQ_AUTO is not set -CONFIG_ESP32_XTAL_FREQ=40 -# CONFIG_ESP32_DISABLE_BASIC_ROM_CONSOLE is not set -# CONFIG_ESP32_NO_BLOBS is not set -# CONFIG_ESP32_COMPATIBLE_PRE_V2_1_BOOTLOADERS is not set -# CONFIG_ESP32_COMPATIBLE_PRE_V3_1_BOOTLOADERS is not set -# CONFIG_ESP32_USE_FIXED_STATIC_RAM_SIZE is not set -CONFIG_ESP32_DPORT_DIS_INTERRUPT_LVL=5 -# end of ESP32-specific - -# -# ADC-Calibration -# -CONFIG_ADC_CAL_EFUSE_TP_ENABLE=y -CONFIG_ADC_CAL_EFUSE_VREF_ENABLE=y -CONFIG_ADC_CAL_LUT_ENABLE=y -# end of ADC-Calibration - -# -# Common ESP-related -# -CONFIG_ESP_ERR_TO_NAME_LOOKUP=y -# end of Common ESP-related - -# -# Ethernet -# -# CONFIG_ETH_USE_ESP32_EMAC is not set -# CONFIG_ETH_USE_SPI_ETHERNET is not set -# CONFIG_ETH_USE_OPENETH is not set -# end of Ethernet - -# -# Event Loop Library -# -# CONFIG_ESP_EVENT_LOOP_PROFILING is not set -CONFIG_ESP_EVENT_POST_FROM_ISR=y -CONFIG_ESP_EVENT_POST_FROM_IRAM_ISR=y -# end of Event Loop Library - -# -# GDB Stub -# -# end of GDB Stub - -# -# Hardware Settings -# - -# -# MAC Config -# -CONFIG_ESP_MAC_ADDR_UNIVERSE_WIFI_STA=y -CONFIG_ESP_MAC_ADDR_UNIVERSE_WIFI_AP=y -CONFIG_ESP_MAC_ADDR_UNIVERSE_BT=y -CONFIG_ESP_MAC_ADDR_UNIVERSE_ETH=y -# CONFIG_ESP32_UNIVERSAL_MAC_ADDRESSES_TWO is not set -CONFIG_ESP32_UNIVERSAL_MAC_ADDRESSES_FOUR=y -CONFIG_ESP32_UNIVERSAL_MAC_ADDRESSES=4 -# end of MAC Config - -# -# Sleep Config -# -CONFIG_ESP_SLEEP_RTC_BUS_ISO_WORKAROUND=y -# CONFIG_ESP_SLEEP_GPIO_RESET_WORKAROUND is not set -# CONFIG_ESP_SLEEP_PSRAM_LEAKAGE_WORKAROUND is not set -# CONFIG_ESP_SLEEP_FLASH_LEAKAGE_WORKAROUND is not set -# end of Sleep Config - -# -# RTC Clock Config -# -# end of RTC Clock Config -# end of Hardware Settings +CONFIG_ESP_DEFAULT_CPU_FREQ_MHZ_240=y +# end of ESP System Settings # # IPC (Inter-Processor Call) # CONFIG_ESP_IPC_TASK_STACK_SIZE=1536 -CONFIG_ESP_IPC_USES_CALLERS_PRIORITY=y -CONFIG_ESP_IPC_ISR_ENABLE=y # end of IPC (Inter-Processor Call) -# -# ESP NETIF Adapter -# -CONFIG_ESP_NETIF_IP_LOST_TIMER_INTERVAL=120 -CONFIG_ESP_NETIF_TCPIP_LWIP=y -# CONFIG_ESP_NETIF_LOOPBACK is not set -# CONFIG_ESP_NETIF_TCPIP_ADAPTER_COMPATIBLE_LAYER is not set -# end of ESP NETIF Adapter - -# -# PHY -# -CONFIG_ESP_PHY_CALIBRATION_AND_DATA_STORAGE=y -# CONFIG_ESP_PHY_INIT_DATA_IN_PARTITION is not set -CONFIG_ESP_PHY_MAX_WIFI_TX_POWER=20 -CONFIG_ESP_PHY_MAX_TX_POWER=20 -CONFIG_ESP_PHY_REDUCE_TX_POWER=y -# end of PHY - -# -# Power Management -# -# CONFIG_PM_ENABLE is not set -# end of Power Management - -# -# ESP System Settings -# -CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y -# CONFIG_ESP_SYSTEM_PANIC_PRINT_REBOOT is not set -# CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT is not set -# CONFIG_ESP_SYSTEM_PANIC_GDBSTUB is not set -# CONFIG_ESP_SYSTEM_GDBSTUB_RUNTIME is not set - -# -# Memory protection -# -# end of Memory protection - -CONFIG_ESP_SYSTEM_EVENT_QUEUE_SIZE=32 -CONFIG_ESP_SYSTEM_EVENT_TASK_STACK_SIZE=2304 -CONFIG_ESP_MAIN_TASK_AFFINITY_CPU0=y -# CONFIG_ESP_MAIN_TASK_AFFINITY_CPU1 is not set -# CONFIG_ESP_MAIN_TASK_AFFINITY_NO_AFFINITY is not set -CONFIG_ESP_MAIN_TASK_AFFINITY=0x0 -CONFIG_ESP_MINIMAL_SHARED_STACK_SIZE=2048 -# CONFIG_ESP_CONSOLE_UART_DEFAULT is not set -# CONFIG_ESP_CONSOLE_UART_CUSTOM is not set -CONFIG_ESP_CONSOLE_NONE=y -CONFIG_ESP_CONSOLE_MULTIPLE_UART=y -CONFIG_ESP_CONSOLE_UART_NUM=-1 -CONFIG_ESP_INT_WDT=y -CONFIG_ESP_INT_WDT_TIMEOUT_MS=300 -CONFIG_ESP_INT_WDT_CHECK_CPU1=y -# CONFIG_ESP_TASK_WDT is not set -# CONFIG_ESP_PANIC_HANDLER_IRAM is not set -# CONFIG_ESP_DEBUG_STUBS_ENABLE is not set -# CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_5 is not set -CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_4=y -# end of ESP System Settings - -# -# High resolution timer (esp_timer) -# -# CONFIG_ESP_TIMER_PROFILING is not set -CONFIG_ESP_TIME_FUNCS_USE_RTC_TIMER=y -CONFIG_ESP_TIME_FUNCS_USE_ESP_TIMER=y -CONFIG_ESP_TIMER_TASK_STACK_SIZE=3584 -CONFIG_ESP_TIMER_INTERRUPT_LEVEL=1 -# CONFIG_ESP_TIMER_SUPPORTS_ISR_DISPATCH_METHOD is not set -# CONFIG_ESP_TIMER_IMPL_FRC2 is not set -CONFIG_ESP_TIMER_IMPL_TG0_LAC=y -# end of High resolution timer (esp_timer) - # # Wi-Fi # -CONFIG_ESP32_WIFI_ENABLED=y -CONFIG_ESP32_WIFI_STATIC_RX_BUFFER_NUM=10 -CONFIG_ESP32_WIFI_DYNAMIC_RX_BUFFER_NUM=32 -CONFIG_ESP32_WIFI_STATIC_TX_BUFFER=y -# CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER is not set -CONFIG_ESP32_WIFI_TX_BUFFER_TYPE=0 -CONFIG_ESP32_WIFI_STATIC_TX_BUFFER_NUM=16 -CONFIG_ESP32_WIFI_CACHE_TX_BUFFER_NUM=32 -# CONFIG_ESP32_WIFI_CSI_ENABLED is not set -CONFIG_ESP32_WIFI_AMPDU_TX_ENABLED=y -CONFIG_ESP32_WIFI_TX_BA_WIN=6 -CONFIG_ESP32_WIFI_AMPDU_RX_ENABLED=y -CONFIG_ESP32_WIFI_RX_BA_WIN=6 -# CONFIG_ESP32_WIFI_AMSDU_TX_ENABLED is not set -CONFIG_ESP32_WIFI_NVS_ENABLED=y -CONFIG_ESP32_WIFI_TASK_PINNED_TO_CORE_0=y -# CONFIG_ESP32_WIFI_TASK_PINNED_TO_CORE_1 is not set -CONFIG_ESP32_WIFI_SOFTAP_BEACON_MAX_LEN=752 -CONFIG_ESP32_WIFI_MGMT_SBUF_NUM=32 -CONFIG_ESP32_WIFI_IRAM_OPT=y -CONFIG_ESP32_WIFI_RX_IRAM_OPT=y -CONFIG_ESP32_WIFI_ENABLE_WPA3_SAE=y -# CONFIG_ESP_WIFI_SLP_IRAM_OPT is not set # CONFIG_ESP_WIFI_STA_DISCONNECTED_PM_ENABLE is not set -# CONFIG_ESP_WIFI_GMAC_SUPPORT is not set -CONFIG_ESP_WIFI_SOFTAP_SUPPORT=y # end of Wi-Fi -# -# Core dump -# -# CONFIG_ESP_COREDUMP_ENABLE_TO_FLASH is not set -# CONFIG_ESP_COREDUMP_ENABLE_TO_UART is not set -CONFIG_ESP_COREDUMP_ENABLE_TO_NONE=y -# end of Core dump - -# -# FreeRTOS -# -# CONFIG_FREERTOS_UNICORE is not set -CONFIG_FREERTOS_NO_AFFINITY=0x7FFFFFFF -CONFIG_FREERTOS_TICK_SUPPORT_CORETIMER=y -CONFIG_FREERTOS_CORETIMER_0=y -# CONFIG_FREERTOS_CORETIMER_1 is not set -CONFIG_FREERTOS_SYSTICK_USES_CCOUNT=y -CONFIG_FREERTOS_HZ=100 -CONFIG_FREERTOS_ASSERT_ON_UNTESTED_FUNCTION=y -# CONFIG_FREERTOS_CHECK_STACKOVERFLOW_NONE is not set -# CONFIG_FREERTOS_CHECK_STACKOVERFLOW_PTRVAL is not set -CONFIG_FREERTOS_CHECK_STACKOVERFLOW_CANARY=y -# CONFIG_FREERTOS_WATCHPOINT_END_OF_STACK is not set -CONFIG_FREERTOS_INTERRUPT_BACKTRACE=y -CONFIG_FREERTOS_THREAD_LOCAL_STORAGE_POINTERS=1 -CONFIG_FREERTOS_ASSERT_FAIL_ABORT=y -# CONFIG_FREERTOS_ASSERT_FAIL_PRINT_CONTINUE is not set -# CONFIG_FREERTOS_ASSERT_DISABLE is not set -CONFIG_FREERTOS_IDLE_TASK_STACKSIZE=1536 -CONFIG_FREERTOS_ISR_STACKSIZE=1536 -# CONFIG_FREERTOS_LEGACY_HOOKS is not set -CONFIG_FREERTOS_MAX_TASK_NAME_LEN=16 -CONFIG_FREERTOS_SUPPORT_STATIC_ALLOCATION=y -# CONFIG_FREERTOS_ENABLE_STATIC_TASK_CLEAN_UP is not set -CONFIG_FREERTOS_TIMER_TASK_PRIORITY=1 -CONFIG_FREERTOS_TIMER_TASK_STACK_DEPTH=2048 -CONFIG_FREERTOS_TIMER_QUEUE_LENGTH=10 -CONFIG_FREERTOS_QUEUE_REGISTRY_SIZE=0 -# CONFIG_FREERTOS_USE_TRACE_FACILITY is not set -# CONFIG_FREERTOS_GENERATE_RUN_TIME_STATS is not set -CONFIG_FREERTOS_CHECK_MUTEX_GIVEN_BY_OWNER=y -# CONFIG_FREERTOS_CHECK_PORT_CRITICAL_COMPLIANCE is not set -# CONFIG_FREERTOS_PLACE_FUNCTIONS_INTO_FLASH is not set -CONFIG_FREERTOS_DEBUG_OCDAWARE=y -# CONFIG_FREERTOS_FPU_IN_ISR is not set -CONFIG_FREERTOS_ENABLE_TASK_SNAPSHOT=y -# CONFIG_FREERTOS_PLACE_SNAPSHOT_FUNS_INTO_FLASH is not set -# end of FreeRTOS - -# -# Hardware Abstraction Layer (HAL) and Low Level (LL) -# -CONFIG_HAL_ASSERTION_EQUALS_SYSTEM=y -# CONFIG_HAL_ASSERTION_DISABLE is not set -# CONFIG_HAL_ASSERTION_SILIENT is not set -# CONFIG_HAL_ASSERTION_ENABLE is not set -CONFIG_HAL_DEFAULT_ASSERTION_LEVEL=2 -# end of Hardware Abstraction Layer (HAL) and Low Level (LL) - -# -# Heap memory debugging -# -CONFIG_HEAP_POISONING_DISABLED=y -# CONFIG_HEAP_POISONING_LIGHT is not set -# CONFIG_HEAP_POISONING_COMPREHENSIVE is not set -CONFIG_HEAP_TRACING_OFF=y -# CONFIG_HEAP_TRACING_STANDALONE is not set -# CONFIG_HEAP_TRACING_TOHOST is not set -# CONFIG_HEAP_ABORT_WHEN_ALLOCATION_FAILS is not set -# end of Heap memory debugging - - -# -# LWIP -# -# CONFIG_LWIP_NETIF_API is not set -# CONFIG_LWIP_TCPIP_CORE_LOCKING is not set -CONFIG_LWIP_DNS_SUPPORT_MDNS_QUERIES=y -# CONFIG_LWIP_L2_TO_L3_COPY is not set -# CONFIG_LWIP_IRAM_OPTIMIZATION is not set -CONFIG_LWIP_TIMERS_ONDEMAND=y -CONFIG_LWIP_MAX_SOCKETS=8 -# CONFIG_LWIP_USE_ONLY_LWIP_SELECT is not set -# CONFIG_LWIP_SO_LINGER is not set -CONFIG_LWIP_SO_REUSE=y -CONFIG_LWIP_SO_REUSE_RXTOALL=y -CONFIG_LWIP_SO_RCVBUF=y -# CONFIG_LWIP_NETBUF_RECVINFO is not set -CONFIG_LWIP_IP4_FRAG=y -CONFIG_LWIP_IP6_FRAG=y -# CONFIG_LWIP_IP4_REASSEMBLY is not set -# CONFIG_LWIP_IP6_REASSEMBLY is not set -# CONFIG_LWIP_IP_FORWARD is not set -# CONFIG_LWIP_STATS is not set -# CONFIG_LWIP_ETHARP_TRUST_IP_MAC is not set -CONFIG_LWIP_ESP_GRATUITOUS_ARP=y -CONFIG_LWIP_GARP_TMR_INTERVAL=60 -CONFIG_LWIP_TCPIP_RECVMBOX_SIZE=32 -CONFIG_LWIP_DHCP_DOES_ARP_CHECK=y -# CONFIG_LWIP_DHCP_DISABLE_CLIENT_ID is not set -CONFIG_LWIP_DHCP_DISABLE_VENDOR_CLASS_ID=y -# CONFIG_LWIP_DHCP_RESTORE_LAST_IP is not set -CONFIG_LWIP_DHCP_OPTIONS_LEN=68 - -# -# DHCP server -# -CONFIG_LWIP_DHCPS=y -CONFIG_LWIP_DHCPS_LEASE_UNIT=60 -CONFIG_LWIP_DHCPS_MAX_STATION_NUM=8 -# end of DHCP server - -# CONFIG_LWIP_AUTOIP is not set -CONFIG_LWIP_IPV6=y -# CONFIG_LWIP_IPV6_AUTOCONFIG is not set -CONFIG_LWIP_IPV6_NUM_ADDRESSES=3 -# CONFIG_LWIP_IPV6_FORWARD is not set -# CONFIG_LWIP_NETIF_STATUS_CALLBACK is not set -CONFIG_LWIP_NETIF_LOOPBACK=y -CONFIG_LWIP_LOOPBACK_MAX_PBUFS=8 - -# -# TCP -# -CONFIG_LWIP_MAX_ACTIVE_TCP=4 -CONFIG_LWIP_MAX_LISTENING_TCP=4 -CONFIG_LWIP_TCP_HIGH_SPEED_RETRANSMISSION=y -CONFIG_LWIP_TCP_MAXRTX=12 -CONFIG_LWIP_TCP_SYNMAXRTX=6 -CONFIG_LWIP_TCP_MSS=1440 -CONFIG_LWIP_TCP_TMR_INTERVAL=250 -CONFIG_LWIP_TCP_MSL=60000 -CONFIG_LWIP_TCP_SND_BUF_DEFAULT=2880 -CONFIG_LWIP_TCP_WND_DEFAULT=2880 -CONFIG_LWIP_TCP_RECVMBOX_SIZE=6 -CONFIG_LWIP_TCP_QUEUE_OOSEQ=y -# CONFIG_LWIP_TCP_SACK_OUT is not set -# CONFIG_LWIP_TCP_KEEP_CONNECTION_WHEN_IP_CHANGES is not set -CONFIG_LWIP_TCP_OVERSIZE_MSS=y -# CONFIG_LWIP_TCP_OVERSIZE_QUARTER_MSS is not set -# CONFIG_LWIP_TCP_OVERSIZE_DISABLE is not set -CONFIG_LWIP_TCP_RTO_TIME=3000 -# end of TCP - -# -# UDP -# -CONFIG_LWIP_MAX_UDP_PCBS=16 -CONFIG_LWIP_UDP_RECVMBOX_SIZE=6 -# end of UDP - -# -# Checksums -# -# CONFIG_LWIP_CHECKSUM_CHECK_IP is not set -# CONFIG_LWIP_CHECKSUM_CHECK_UDP is not set -CONFIG_LWIP_CHECKSUM_CHECK_ICMP=y -# end of Checksums - -CONFIG_LWIP_TCPIP_TASK_STACK_SIZE=3072 -CONFIG_LWIP_TCPIP_TASK_AFFINITY_NO_AFFINITY=y -# CONFIG_LWIP_TCPIP_TASK_AFFINITY_CPU0 is not set -# CONFIG_LWIP_TCPIP_TASK_AFFINITY_CPU1 is not set -CONFIG_LWIP_TCPIP_TASK_AFFINITY=0x7FFFFFFF -# CONFIG_LWIP_PPP_SUPPORT is not set -CONFIG_LWIP_IPV6_MEMP_NUM_ND6_QUEUE=3 -CONFIG_LWIP_IPV6_ND6_NUM_NEIGHBORS=5 -# CONFIG_LWIP_SLIP_SUPPORT is not set - -# -# ICMP -# -CONFIG_LWIP_ICMP=y -# CONFIG_LWIP_MULTICAST_PING is not set -# CONFIG_LWIP_BROADCAST_PING is not set -# end of ICMP - -# -# LWIP RAW API -# -CONFIG_LWIP_MAX_RAW_PCBS=16 -# end of LWIP RAW API - -# -# SNTP -# -CONFIG_LWIP_SNTP_MAX_SERVERS=1 -# CONFIG_LWIP_DHCP_GET_NTP_SRV is not set -CONFIG_LWIP_SNTP_UPDATE_DELAY=3600000 -# end of SNTP - -CONFIG_LWIP_ESP_LWIP_ASSERT=y - -# -# Hooks -# -# CONFIG_LWIP_HOOK_TCP_ISN_NONE is not set -CONFIG_LWIP_HOOK_TCP_ISN_DEFAULT=y -# CONFIG_LWIP_HOOK_TCP_ISN_CUSTOM is not set -CONFIG_LWIP_HOOK_IP6_ROUTE_NONE=y -# CONFIG_LWIP_HOOK_IP6_ROUTE_DEFAULT is not set -# CONFIG_LWIP_HOOK_IP6_ROUTE_CUSTOM is not set -CONFIG_LWIP_HOOK_ND6_GET_GW_NONE=y -# CONFIG_LWIP_HOOK_ND6_GET_GW_DEFAULT is not set -# CONFIG_LWIP_HOOK_ND6_GET_GW_CUSTOM is not set -CONFIG_LWIP_HOOK_NETCONN_EXT_RESOLVE_NONE=y -# CONFIG_LWIP_HOOK_NETCONN_EXT_RESOLVE_DEFAULT is not set -# CONFIG_LWIP_HOOK_NETCONN_EXT_RESOLVE_CUSTOM is not set -# end of Hooks - -# CONFIG_LWIP_DEBUG is not set -# end of LWIP - -# -# mbedTLS -# -CONFIG_MBEDTLS_INTERNAL_MEM_ALLOC=y -# CONFIG_MBEDTLS_DEFAULT_MEM_ALLOC is not set -# CONFIG_MBEDTLS_CUSTOM_MEM_ALLOC is not set -CONFIG_MBEDTLS_ASYMMETRIC_CONTENT_LEN=y -CONFIG_MBEDTLS_SSL_IN_CONTENT_LEN=16384 -CONFIG_MBEDTLS_SSL_OUT_CONTENT_LEN=2048 -# CONFIG_MBEDTLS_DEBUG is not set - -# -# mbedTLS v2.28.x related -# -# CONFIG_MBEDTLS_SSL_VARIABLE_BUFFER_LENGTH is not set -CONFIG_MBEDTLS_ECDH_LEGACY_CONTEXT=y -# CONFIG_MBEDTLS_X509_TRUSTED_CERT_CALLBACK is not set -# CONFIG_MBEDTLS_SSL_CONTEXT_SERIALIZATION is not set -CONFIG_MBEDTLS_SSL_KEEP_PEER_CERTIFICATE=y - -# -# DTLS-based configurations -# -# CONFIG_MBEDTLS_SSL_DTLS_CONNECTION_ID is not set -# CONFIG_MBEDTLS_SSL_DTLS_SRTP is not set -# end of DTLS-based configurations -# end of mbedTLS v2.28.x related - -# -# Certificate Bundle -# -CONFIG_MBEDTLS_CERTIFICATE_BUNDLE=y -# CONFIG_MBEDTLS_CERTIFICATE_BUNDLE_DEFAULT_FULL is not set -# CONFIG_MBEDTLS_CERTIFICATE_BUNDLE_DEFAULT_CMN is not set -CONFIG_MBEDTLS_CERTIFICATE_BUNDLE_DEFAULT_NONE=y -CONFIG_MBEDTLS_CUSTOM_CERTIFICATE_BUNDLE=y -CONFIG_MBEDTLS_CUSTOM_CERTIFICATE_BUNDLE_PATH="../../lib/certificates/nina-fw/data/roots.pem" -# end of Certificate Bundle - -CONFIG_MBEDTLS_ECP_RESTARTABLE=y -CONFIG_MBEDTLS_CMAC_C=y -CONFIG_MBEDTLS_HARDWARE_AES=y -CONFIG_MBEDTLS_HARDWARE_MPI=y -CONFIG_MBEDTLS_HARDWARE_SHA=y -CONFIG_MBEDTLS_ROM_MD5=y -# CONFIG_MBEDTLS_ATCA_HW_ECDSA_SIGN is not set -# CONFIG_MBEDTLS_ATCA_HW_ECDSA_VERIFY is not set -CONFIG_MBEDTLS_HAVE_TIME=y -# CONFIG_MBEDTLS_HAVE_TIME_DATE is not set -CONFIG_MBEDTLS_ECDSA_DETERMINISTIC=y -CONFIG_MBEDTLS_SHA512_C=y -CONFIG_MBEDTLS_TLS_SERVER_AND_CLIENT=y -# CONFIG_MBEDTLS_TLS_SERVER_ONLY is not set -# CONFIG_MBEDTLS_TLS_CLIENT_ONLY is not set -# CONFIG_MBEDTLS_TLS_DISABLED is not set -CONFIG_MBEDTLS_TLS_SERVER=y -CONFIG_MBEDTLS_TLS_CLIENT=y -CONFIG_MBEDTLS_TLS_ENABLED=y - -# -# TLS Key Exchange Methods -# -CONFIG_MBEDTLS_PSK_MODES=y -CONFIG_MBEDTLS_KEY_EXCHANGE_PSK=y -CONFIG_MBEDTLS_KEY_EXCHANGE_DHE_PSK=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ECDHE_PSK=y -CONFIG_MBEDTLS_KEY_EXCHANGE_RSA_PSK=y -CONFIG_MBEDTLS_KEY_EXCHANGE_RSA=y -CONFIG_MBEDTLS_KEY_EXCHANGE_DHE_RSA=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ELLIPTIC_CURVE=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ECDHE_RSA=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ECDH_RSA=y -# end of TLS Key Exchange Methods - -CONFIG_MBEDTLS_SSL_RENEGOTIATION=y -# CONFIG_MBEDTLS_SSL_PROTO_SSL3 is not set -# CONFIG_MBEDTLS_SSL_PROTO_TLS1 is not set -# CONFIG_MBEDTLS_SSL_PROTO_TLS1_1 is not set -CONFIG_MBEDTLS_SSL_PROTO_TLS1_2=y -# CONFIG_MBEDTLS_SSL_PROTO_GMTSSL1_1 is not set -CONFIG_MBEDTLS_SSL_PROTO_DTLS=y -CONFIG_MBEDTLS_SSL_ALPN=y -CONFIG_MBEDTLS_CLIENT_SSL_SESSION_TICKETS=y -CONFIG_MBEDTLS_X509_CHECK_KEY_USAGE=y -CONFIG_MBEDTLS_X509_CHECK_EXTENDED_KEY_USAGE=y -CONFIG_MBEDTLS_SERVER_SSL_SESSION_TICKETS=y - -# -# Symmetric Ciphers -# -CONFIG_MBEDTLS_AES_C=y -# CONFIG_MBEDTLS_CAMELLIA_C is not set -# CONFIG_MBEDTLS_DES_C is not set -CONFIG_MBEDTLS_RC4_DISABLED=y -# CONFIG_MBEDTLS_RC4_ENABLED_NO_DEFAULT is not set -# CONFIG_MBEDTLS_RC4_ENABLED is not set -# CONFIG_MBEDTLS_BLOWFISH_C is not set -# CONFIG_MBEDTLS_XTEA_C is not set -CONFIG_MBEDTLS_CCM_C=y -CONFIG_MBEDTLS_GCM_C=y -# CONFIG_MBEDTLS_NIST_KW_C is not set -# end of Symmetric Ciphers - -# CONFIG_MBEDTLS_RIPEMD160_C is not set - -# -# Certificates -# -CONFIG_MBEDTLS_PEM_PARSE_C=y -CONFIG_MBEDTLS_PEM_WRITE_C=y -CONFIG_MBEDTLS_X509_CRL_PARSE_C=y -CONFIG_MBEDTLS_X509_CSR_PARSE_C=y -# end of Certificates - -CONFIG_MBEDTLS_ECP_C=y -CONFIG_MBEDTLS_ECDH_C=y -CONFIG_MBEDTLS_ECDSA_C=y -# CONFIG_MBEDTLS_ECJPAKE_C is not set -CONFIG_MBEDTLS_ECP_DP_SECP192R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP224R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP256R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP384R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP521R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP192K1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP224K1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP256K1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_BP256R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_BP384R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_BP512R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_CURVE25519_ENABLED=y -CONFIG_MBEDTLS_ECP_NIST_OPTIM=y -# CONFIG_MBEDTLS_POLY1305_C is not set -# CONFIG_MBEDTLS_CHACHA20_C is not set -# CONFIG_MBEDTLS_HKDF_C is not set -# CONFIG_MBEDTLS_THREADING_C is not set -# CONFIG_MBEDTLS_LARGE_KEY_SOFTWARE_MPI is not set -# CONFIG_MBEDTLS_SECURITY_RISKS is not set -# end of mbedTLS - -# -# mDNS -# -CONFIG_MDNS_MAX_SERVICES=10 -CONFIG_MDNS_TASK_PRIORITY=1 -CONFIG_MDNS_TASK_STACK_SIZE=4096 -# CONFIG_MDNS_TASK_AFFINITY_NO_AFFINITY is not set -CONFIG_MDNS_TASK_AFFINITY_CPU0=y -# CONFIG_MDNS_TASK_AFFINITY_CPU1 is not set -CONFIG_MDNS_TASK_AFFINITY=0x0 -CONFIG_MDNS_SERVICE_ADD_TIMEOUT_MS=2000 -# CONFIG_MDNS_STRICT_MODE is not set -CONFIG_MDNS_TIMER_PERIOD_MS=100 -# CONFIG_MDNS_NETWORKING_SOCKET is not set -CONFIG_MDNS_MULTIPLE_INSTANCE=y -# end of mDNS - # # Newlib # -CONFIG_NEWLIB_STDOUT_LINE_ENDING_CRLF=y -# CONFIG_NEWLIB_STDOUT_LINE_ENDING_LF is not set -# CONFIG_NEWLIB_STDOUT_LINE_ENDING_CR is not set -# CONFIG_NEWLIB_STDIN_LINE_ENDING_CRLF is not set -# CONFIG_NEWLIB_STDIN_LINE_ENDING_LF is not set -CONFIG_NEWLIB_STDIN_LINE_ENDING_CR=y -# CONFIG_NEWLIB_NANO_FORMAT is not set +CONFIG_NEWLIB_NANO_FORMAT=y # end of Newlib -# -# NVS -# -# end of NVS - -# -# OpenThread -# -# CONFIG_OPENTHREAD_ENABLED is not set -# end of OpenThread - -# -# PThreads -# -CONFIG_PTHREAD_TASK_PRIO_DEFAULT=5 -CONFIG_PTHREAD_TASK_STACK_SIZE_DEFAULT=3072 -CONFIG_PTHREAD_STACK_MIN=768 -CONFIG_PTHREAD_DEFAULT_CORE_NO_AFFINITY=y -# CONFIG_PTHREAD_DEFAULT_CORE_0 is not set -# CONFIG_PTHREAD_DEFAULT_CORE_1 is not set -CONFIG_PTHREAD_TASK_CORE_DEFAULT=-1 -CONFIG_PTHREAD_TASK_NAME_DEFAULT="pthread" -# end of PThreads - # # SPI Flash driver # -# CONFIG_SPI_FLASH_VERIFY_WRITE is not set -# CONFIG_SPI_FLASH_ENABLE_COUNTERS is not set -CONFIG_SPI_FLASH_ROM_DRIVER_PATCH=y -CONFIG_SPI_FLASH_DANGEROUS_WRITE_ABORTS=y -# CONFIG_SPI_FLASH_DANGEROUS_WRITE_FAILS is not set -# CONFIG_SPI_FLASH_DANGEROUS_WRITE_ALLOWED is not set -# CONFIG_SPI_FLASH_USE_LEGACY_IMPL is not set -# CONFIG_SPI_FLASH_SHARE_SPI1_BUS is not set -# CONFIG_SPI_FLASH_BYPASS_BLOCK_ERASE is not set -# CONFIG_SPI_FLASH_YIELD_DURING_ERASE is not set -CONFIG_SPI_FLASH_WRITE_CHUNK_SIZE=4096 -# CONFIG_SPI_FLASH_SIZE_OVERRIDE is not set -# CONFIG_SPI_FLASH_CHECK_ERASE_TIMEOUT_DISABLED is not set -# CONFIG_SPI_FLASH_OVERRIDE_CHIP_DRIVER_LIST is not set - # # Auto-detect flash chips # -CONFIG_SPI_FLASH_SUPPORT_ISSI_CHIP=y -CONFIG_SPI_FLASH_SUPPORT_MXIC_CHIP=y -CONFIG_SPI_FLASH_SUPPORT_GD_CHIP=y -CONFIG_SPI_FLASH_SUPPORT_WINBOND_CHIP=y CONFIG_SPI_FLASH_SUPPORT_BOYA_CHIP=y CONFIG_SPI_FLASH_SUPPORT_TH_CHIP=y # end of Auto-detect flash chips -CONFIG_SPI_FLASH_ENABLE_ENCRYPTED_READ_WRITE=y # end of SPI Flash driver # -# Virtual file system +# Ultra Low Power (ULP) Co-processor # -CONFIG_VFS_SUPPORT_IO=y -CONFIG_VFS_SUPPORT_DIR=y -CONFIG_VFS_SUPPORT_SELECT=y -CONFIG_VFS_SUPPRESS_SELECT_DEBUG_OUTPUT=y -CONFIG_VFS_SUPPORT_TERMIOS=y +CONFIG_ULP_COPROC_ENABLED=y +CONFIG_ULP_COPROC_RESERVE_MEM=4080 +# end of Ultra Low Power (ULP) Co-processor -# -# Host File System I/O (Semihosting) -# -CONFIG_VFS_SEMIHOSTFS_MAX_MOUNT_POINTS=1 -CONFIG_VFS_SEMIHOSTFS_HOST_PATH_MAX_LEN=128 -# end of Host File System I/O (Semihosting) -# end of Virtual file system - -# -# Supplicant -# -CONFIG_WPA_MBEDTLS_CRYPTO=y -# CONFIG_WPA_WAPI_PSK is not set -# CONFIG_WPA_SUITE_B_192 is not set -# CONFIG_WPA_DEBUG_PRINT is not set -# CONFIG_WPA_TESTING_OPTIONS is not set -# CONFIG_WPA_WPS_STRICT is not set -# CONFIG_WPA_11KV_SUPPORT is not set -# CONFIG_WPA_MBO_SUPPORT is not set -# CONFIG_WPA_DPP_SUPPORT is not set -# end of Supplicant # end of Component config -# -# Compatibility options -# -# CONFIG_LEGACY_INCLUDE_COMMON_HEADERS is not set -# end of Compatibility options - -# Deprecated options for backward compatibility -CONFIG_TOOLPREFIX="xtensa-esp32-elf-" -CONFIG_LOG_BOOTLOADER_LEVEL_NONE=y -# CONFIG_LOG_BOOTLOADER_LEVEL_ERROR is not set -# CONFIG_LOG_BOOTLOADER_LEVEL_WARN is not set -# CONFIG_LOG_BOOTLOADER_LEVEL_INFO is not set -# CONFIG_LOG_BOOTLOADER_LEVEL_DEBUG is not set -# CONFIG_LOG_BOOTLOADER_LEVEL_VERBOSE is not set -CONFIG_LOG_BOOTLOADER_LEVEL=0 -# CONFIG_APP_ROLLBACK_ENABLE is not set -# CONFIG_FLASH_ENCRYPTION_ENABLED is not set -# CONFIG_FLASHMODE_QIO is not set -# CONFIG_FLASHMODE_QOUT is not set -CONFIG_FLASHMODE_DIO=y -# CONFIG_FLASHMODE_DOUT is not set -# CONFIG_MONITOR_BAUD_9600B is not set -# CONFIG_MONITOR_BAUD_57600B is not set -CONFIG_MONITOR_BAUD_115200B=y -# CONFIG_MONITOR_BAUD_230400B is not set -# CONFIG_MONITOR_BAUD_921600B is not set -# CONFIG_MONITOR_BAUD_2MB is not set -# CONFIG_MONITOR_BAUD_OTHER is not set -CONFIG_MONITOR_BAUD_OTHER_VAL=115200 -CONFIG_MONITOR_BAUD=115200 -# CONFIG_COMPILER_OPTIMIZATION_LEVEL_DEBUG is not set -CONFIG_COMPILER_OPTIMIZATION_LEVEL_RELEASE=y -CONFIG_OPTIMIZATION_ASSERTIONS_ENABLED=y -# CONFIG_OPTIMIZATION_ASSERTIONS_SILENT is not set -# CONFIG_OPTIMIZATION_ASSERTIONS_DISABLED is not set -CONFIG_OPTIMIZATION_ASSERTION_LEVEL=2 -# CONFIG_CXX_EXCEPTIONS is not set -CONFIG_STACK_CHECK_NONE=y -# CONFIG_STACK_CHECK_NORM is not set -# CONFIG_STACK_CHECK_STRONG is not set -# CONFIG_STACK_CHECK_ALL is not set -# CONFIG_WARN_WRITE_STRINGS is not set -# CONFIG_DISABLE_GCC8_WARNINGS is not set -# CONFIG_ESP32_APPTRACE_DEST_TRAX is not set -CONFIG_ESP32_APPTRACE_DEST_NONE=y -CONFIG_ESP32_APPTRACE_LOCK_ENABLE=y -CONFIG_ADC2_DISABLE_DAC=y -CONFIG_TRACEMEM_RESERVE_DRAM=0x0 -# CONFIG_ULP_COPROC_ENABLED is not set -CONFIG_ULP_COPROC_RESERVE_MEM=0 -CONFIG_BROWNOUT_DET=y -CONFIG_BROWNOUT_DET_LVL_SEL_0=y -# CONFIG_BROWNOUT_DET_LVL_SEL_1 is not set -# CONFIG_BROWNOUT_DET_LVL_SEL_2 is not set -# CONFIG_BROWNOUT_DET_LVL_SEL_3 is not set -# CONFIG_BROWNOUT_DET_LVL_SEL_4 is not set -# CONFIG_BROWNOUT_DET_LVL_SEL_5 is not set -# CONFIG_BROWNOUT_DET_LVL_SEL_6 is not set -# CONFIG_BROWNOUT_DET_LVL_SEL_7 is not set -CONFIG_BROWNOUT_DET_LVL=0 -CONFIG_ESP32_RTC_CLOCK_SOURCE_INTERNAL_RC=y -# CONFIG_ESP32_RTC_CLOCK_SOURCE_EXTERNAL_CRYSTAL is not set -# CONFIG_ESP32_RTC_CLOCK_SOURCE_EXTERNAL_OSC is not set -# CONFIG_ESP32_RTC_CLOCK_SOURCE_INTERNAL_8MD256 is not set -# CONFIG_DISABLE_BASIC_ROM_CONSOLE is not set -# CONFIG_NO_BLOBS is not set -# CONFIG_COMPATIBLE_PRE_V2_1_BOOTLOADERS is not set -# CONFIG_EVENT_LOOP_PROFILING is not set -CONFIG_POST_EVENTS_FROM_ISR=y -CONFIG_POST_EVENTS_FROM_IRAM_ISR=y -# CONFIG_TWO_UNIVERSAL_MAC_ADDRESS is not set -CONFIG_FOUR_UNIVERSAL_MAC_ADDRESS=y -CONFIG_NUMBER_OF_UNIVERSAL_MAC_ADDRESS=4 -# CONFIG_ESP32C3_LIGHTSLEEP_GPIO_RESET_WORKAROUND is not set -CONFIG_IPC_TASK_STACK_SIZE=1536 -CONFIG_ESP32_PHY_CALIBRATION_AND_DATA_STORAGE=y -# CONFIG_ESP32_PHY_INIT_DATA_IN_PARTITION is not set -CONFIG_ESP32_PHY_MAX_WIFI_TX_POWER=20 -CONFIG_ESP32_PHY_MAX_TX_POWER=20 -CONFIG_ESP32_REDUCE_PHY_TX_POWER=y -CONFIG_ESP32S2_PANIC_PRINT_HALT=y -# CONFIG_ESP32S2_PANIC_PRINT_REBOOT is not set -# CONFIG_ESP32S2_PANIC_SILENT_REBOOT is not set -# CONFIG_ESP32S2_PANIC_GDBSTUB is not set -CONFIG_SYSTEM_EVENT_QUEUE_SIZE=32 -CONFIG_SYSTEM_EVENT_TASK_STACK_SIZE=2304 -# CONFIG_CONSOLE_UART_DEFAULT is not set -# CONFIG_CONSOLE_UART_CUSTOM is not set -CONFIG_ESP_CONSOLE_UART_NONE=y -CONFIG_CONSOLE_UART_NUM=-1 -CONFIG_INT_WDT=y -CONFIG_INT_WDT_TIMEOUT_MS=300 -CONFIG_INT_WDT_CHECK_CPU1=y -# CONFIG_TASK_WDT is not set -# CONFIG_ESP32_DEBUG_STUBS_ENABLE is not set -CONFIG_TIMER_TASK_STACK_SIZE=3584 -# CONFIG_ESP32_ENABLE_COREDUMP_TO_FLASH is not set -# CONFIG_ESP32_ENABLE_COREDUMP_TO_UART is not set -CONFIG_ESP32_ENABLE_COREDUMP_TO_NONE=y -# CONFIG_ENABLE_STATIC_TASK_CLEAN_UP_HOOK is not set -CONFIG_TIMER_TASK_PRIORITY=1 -CONFIG_TIMER_TASK_STACK_DEPTH=2048 -CONFIG_TIMER_QUEUE_LENGTH=10 -# CONFIG_L2_TO_L3_COPY is not set -# CONFIG_USE_ONLY_LWIP_SELECT is not set -CONFIG_ESP_GRATUITOUS_ARP=y -CONFIG_GARP_TMR_INTERVAL=60 -CONFIG_TCPIP_RECVMBOX_SIZE=32 -CONFIG_TCP_MAXRTX=12 -CONFIG_TCP_SYNMAXRTX=6 -CONFIG_TCP_MSS=1440 -CONFIG_TCP_MSL=60000 -CONFIG_TCP_SND_BUF_DEFAULT=2880 -CONFIG_TCP_WND_DEFAULT=2880 -CONFIG_TCP_RECVMBOX_SIZE=6 -CONFIG_TCP_QUEUE_OOSEQ=y -# CONFIG_ESP_TCP_KEEP_CONNECTION_WHEN_IP_CHANGES is not set -CONFIG_TCP_OVERSIZE_MSS=y -# CONFIG_TCP_OVERSIZE_QUARTER_MSS is not set -# CONFIG_TCP_OVERSIZE_DISABLE is not set -CONFIG_UDP_RECVMBOX_SIZE=6 -CONFIG_TCPIP_TASK_STACK_SIZE=3072 -CONFIG_TCPIP_TASK_AFFINITY_NO_AFFINITY=y -# CONFIG_TCPIP_TASK_AFFINITY_CPU0 is not set -# CONFIG_TCPIP_TASK_AFFINITY_CPU1 is not set -CONFIG_TCPIP_TASK_AFFINITY=0x7FFFFFFF -# CONFIG_PPP_SUPPORT is not set -CONFIG_ESP32_PTHREAD_TASK_PRIO_DEFAULT=5 -CONFIG_ESP32_PTHREAD_TASK_STACK_SIZE_DEFAULT=3072 -CONFIG_ESP32_PTHREAD_STACK_MIN=768 -CONFIG_ESP32_DEFAULT_PTHREAD_CORE_NO_AFFINITY=y -# CONFIG_ESP32_DEFAULT_PTHREAD_CORE_0 is not set -# CONFIG_ESP32_DEFAULT_PTHREAD_CORE_1 is not set -CONFIG_ESP32_PTHREAD_TASK_CORE_DEFAULT=-1 -CONFIG_ESP32_PTHREAD_TASK_NAME_DEFAULT="pthread" -CONFIG_SPI_FLASH_WRITING_DANGEROUS_REGIONS_ABORTS=y -# CONFIG_SPI_FLASH_WRITING_DANGEROUS_REGIONS_FAILS is not set -# CONFIG_SPI_FLASH_WRITING_DANGEROUS_REGIONS_ALLOWED is not set -CONFIG_SUPPRESS_SELECT_DEBUG_OUTPUT=y -CONFIG_SUPPORT_TERMIOS=y -CONFIG_SEMIHOSTFS_MAX_MOUNT_POINTS=1 -CONFIG_SEMIHOSTFS_HOST_PATH_MAX_LEN=128 -# End of deprecated options +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-esp32c3.defaults b/ports/espressif/esp-idf-config/sdkconfig-esp32c3.defaults index 5fdb766add..76a7924f67 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-esp32c3.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-esp32c3.defaults @@ -1,171 +1,60 @@ -CONFIG_IDF_TARGET_ARCH_RISCV=y -CONFIG_IDF_TARGET="esp32c3" -CONFIG_IDF_TARGET_ESP32C3=y -CONFIG_IDF_FIRMWARE_CHIP_ID=0x0005 # -# SDK tool configuration +# Espressif IoT Development Framework Configuration # -CONFIG_SDK_TOOLPREFIX="riscv32-esp-elf-" -# end of SDK tool configuration - -# -# Bootloader config -# -CONFIG_BOOTLOADER_OFFSET_IN_FLASH=0x0 -# end of Bootloader config - # # Component config # # # Bluetooth # -CONFIG_BT_SOC_SUPPORT_5_0=y +CONFIG_BT_ENABLED=y +CONFIG_BT_NIMBLE_ENABLED=y # # NimBLE Options # -CONFIG_BT_NIMBLE_PINNED_TO_CORE=0 +CONFIG_BT_NIMBLE_LOG_LEVEL_NONE=y +CONFIG_BT_NIMBLE_NVS_PERSIST=y +# +# Memory Settings +# +CONFIG_BT_NIMBLE_TRANSPORT_ACL_FROM_LL_COUNT=20 +CONFIG_BT_NIMBLE_TRANSPORT_EVT_SIZE=70 +# end of Memory Settings + +CONFIG_BT_NIMBLE_EXT_ADV=y # end of NimBLE Options +# +# Controller Options +# +# CONFIG_BT_CTRL_BLE_SCAN_DUPL is not set +# end of Controller Options + # end of Bluetooth # -# ESP32C3-Specific +# Driver Configurations # -# CONFIG_ESP32C3_DEFAULT_CPU_FREQ_80 is not set -CONFIG_ESP32C3_DEFAULT_CPU_FREQ_160=y -CONFIG_ESP32C3_DEFAULT_CPU_FREQ_MHZ=160 -# CONFIG_ESP32C3_REV_MIN_0 is not set -# CONFIG_ESP32C3_REV_MIN_1 is not set -# CONFIG_ESP32C3_REV_MIN_2 is not set -CONFIG_ESP32C3_REV_MIN_3=y -CONFIG_ESP32C3_REV_MIN=3 -CONFIG_ESP32C3_DEBUG_OCDAWARE=y -CONFIG_ESP32C3_BROWNOUT_DET=y -CONFIG_ESP32C3_BROWNOUT_DET_LVL_SEL_7=y -# CONFIG_ESP32C3_BROWNOUT_DET_LVL_SEL_6 is not set -# CONFIG_ESP32C3_BROWNOUT_DET_LVL_SEL_5 is not set -# CONFIG_ESP32C3_BROWNOUT_DET_LVL_SEL_4 is not set -# CONFIG_ESP32C3_BROWNOUT_DET_LVL_SEL_3 is not set -# CONFIG_ESP32C3_BROWNOUT_DET_LVL_SEL_2 is not set -CONFIG_ESP32C3_BROWNOUT_DET_LVL=7 -CONFIG_ESP32C3_TIME_SYSCALL_USE_RTC_SYSTIMER=y -# CONFIG_ESP32C3_TIME_SYSCALL_USE_RTC is not set -# CONFIG_ESP32C3_TIME_SYSCALL_USE_SYSTIMER is not set -# CONFIG_ESP32C3_TIME_SYSCALL_USE_NONE is not set -CONFIG_ESP32C3_RTC_CLK_SRC_INT_RC=y -# CONFIG_ESP32C3_RTC_CLK_SRC_EXT_CRYS is not set -# CONFIG_ESP32C3_RTC_CLK_SRC_EXT_OSC is not set -# CONFIG_ESP32C3_RTC_CLK_SRC_INT_8MD256 is not set -CONFIG_ESP32C3_RTC_CLK_CAL_CYCLES=1024 -# end of ESP32C3-Specific - -# -# Hardware Settings -# -# -# MAC Config -# -# CONFIG_ESP32C3_UNIVERSAL_MAC_ADDRESSES_TWO is not set -CONFIG_ESP32C3_UNIVERSAL_MAC_ADDRESSES_FOUR=y -CONFIG_ESP32C3_UNIVERSAL_MAC_ADDRESSES=4 -# end of MAC Config - -# -# Sleep Config -# -CONFIG_ESP_SLEEP_POWER_DOWN_FLASH=y -CONFIG_ESP_SLEEP_GPIO_RESET_WORKAROUND=y -# end of Sleep Config - -# end of Hardware Settings - -# -# PHY -# -CONFIG_ESP_PHY_ENABLE_USB=y -# end of PHY - -# -# ESP System Settings -# -CONFIG_ESP_SYSTEM_SINGLE_CORE_MODE=y -# -# Memory protection -# -CONFIG_ESP_SYSTEM_MEMPROT_DEPCHECK=y -CONFIG_ESP_SYSTEM_MEMPROT_FEATURE=y -CONFIG_ESP_SYSTEM_MEMPROT_FEATURE_LOCK=y -CONFIG_ESP_SYSTEM_MEMPROT_CPU_PREFETCH_PAD_SIZE=16 -CONFIG_ESP_SYSTEM_MEMPROT_MEM_ALIGN_SIZE=512 -# end of Memory protection - -CONFIG_ESP_MAIN_TASK_AFFINITY_CPU0=y -# CONFIG_ESP_MAIN_TASK_AFFINITY_NO_AFFINITY is not set -CONFIG_ESP_MAIN_TASK_AFFINITY=0x0 - -CONFIG_ESP_CONSOLE_SECONDARY_NONE=y -# CONFIG_ESP_CONSOLE_SECONDARY_USB_SERIAL_JTAG is not set -# end of ESP System Settings +# +# RMT Configuration +# +CONFIG_RMT_SUPPRESS_DEPRECATE_WARN=y +# end of RMT Configuration +# end of Driver Configurations # # Wi-Fi # -CONFIG_ESP32_WIFI_ENABLED=y -CONFIG_ESP32_WIFI_SW_COEXIST_ENABLE=y -CONFIG_ESP32_WIFI_STATIC_RX_BUFFER_NUM=4 -CONFIG_ESP32_WIFI_DYNAMIC_RX_BUFFER_NUM=8 -# CONFIG_ESP32_WIFI_STATIC_TX_BUFFER is not set -CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER=y -CONFIG_ESP32_WIFI_TX_BUFFER_TYPE=1 -CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER_NUM=16 -# CONFIG_ESP32_WIFI_CSI_ENABLED is not set -CONFIG_ESP32_WIFI_AMPDU_TX_ENABLED=y -CONFIG_ESP32_WIFI_TX_BA_WIN=6 -CONFIG_ESP32_WIFI_AMPDU_RX_ENABLED=y -CONFIG_ESP32_WIFI_RX_BA_WIN=6 -# CONFIG_ESP32_WIFI_NVS_ENABLED is not set -CONFIG_ESP32_WIFI_SOFTAP_BEACON_MAX_LEN=752 -CONFIG_ESP32_WIFI_MGMT_SBUF_NUM=32 -CONFIG_ESP32_WIFI_IRAM_OPT=y -CONFIG_ESP32_WIFI_RX_IRAM_OPT=y -# CONFIG_ESP32_WIFI_ENABLE_WPA3_SAE is not set +CONFIG_ESP_WIFI_STATIC_RX_BUFFER_NUM=4 # end of Wi-Fi # -# FreeRTOS +# Newlib # -CONFIG_FREERTOS_UNICORE=y -CONFIG_FREERTOS_OPTIMIZED_SCHEDULER=y -# end of FreeRTOS +CONFIG_NEWLIB_NANO_FORMAT=y +# end of Newlib # end of Component config -# -# Deprecated options for backward compatibility -# -CONFIG_TOOLPREFIX="riscv32-esp-elf-" -# CONFIG_ESP32_APPTRACE_DEST_TRAX is not set -CONFIG_ESP32_APPTRACE_DEST_NONE=y -CONFIG_ESP32_APPTRACE_LOCK_ENABLE=y -CONFIG_NIMBLE_PINNED_TO_CORE=0 -CONFIG_ESP_SYSTEM_PD_FLASH=y -CONFIG_ESP32C3_LIGHTSLEEP_GPIO_RESET_WORKAROUND=y -CONFIG_ESP32_PHY_CALIBRATION_AND_DATA_STORAGE=y -# CONFIG_ESP32_PHY_INIT_DATA_IN_PARTITION is not set -CONFIG_ESP32_PHY_MAX_WIFI_TX_POWER=20 -CONFIG_ESP32_PHY_MAX_TX_POWER=20 -CONFIG_ESP32S2_ALLOW_RTC_FAST_MEM_AS_HEAP=y -CONFIG_ESP32H2_MEMPROT_FEATURE=y -CONFIG_ESP32H2_MEMPROT_FEATURE_LOCK=y -# CONFIG_ESP32_DEBUG_STUBS_ENABLE is not set -# CONFIG_ESP32_ENABLE_COREDUMP_TO_FLASH is not set -# CONFIG_ESP32_ENABLE_COREDUMP_TO_UART is not set -CONFIG_ESP32_ENABLE_COREDUMP_TO_NONE=y -CONFIG_ESP32_PTHREAD_TASK_PRIO_DEFAULT=5 -CONFIG_ESP32_PTHREAD_TASK_STACK_SIZE_DEFAULT=3072 -CONFIG_ESP32_PTHREAD_STACK_MIN=768 -CONFIG_ESP32_PTHREAD_TASK_CORE_DEFAULT=-1 -CONFIG_ESP32_PTHREAD_TASK_NAME_DEFAULT="pthread" -# end of Deprecated options for backward compatibility +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-esp32c6.defaults b/ports/espressif/esp-idf-config/sdkconfig-esp32c6.defaults new file mode 100644 index 0000000000..c1776fc47c --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-esp32c6.defaults @@ -0,0 +1,60 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# Bluetooth +# +CONFIG_BT_ENABLED=y +CONFIG_BT_NIMBLE_ENABLED=y +# +# NimBLE Options +# +CONFIG_BT_NIMBLE_LOG_LEVEL_NONE=y +CONFIG_BT_NIMBLE_NVS_PERSIST=y +# +# Memory Settings +# +CONFIG_BT_NIMBLE_TRANSPORT_ACL_FROM_LL_COUNT=20 +CONFIG_BT_NIMBLE_TRANSPORT_EVT_SIZE=70 +# end of Memory Settings + +CONFIG_BT_NIMBLE_EXT_ADV=y +# end of NimBLE Options + +# end of Bluetooth + +# +# Driver Configurations +# +# +# PCNT Configuration +# +CONFIG_PCNT_SUPPRESS_DEPRECATE_WARN=y +# end of PCNT Configuration + +# +# RMT Configuration +# +CONFIG_RMT_SUPPRESS_DEPRECATE_WARN=y +# end of RMT Configuration + +# end of Driver Configurations + +# +# PHY +# +CONFIG_ESP_PHY_ENABLE_USB=y +# end of PHY + +# +# Wi-Fi +# +CONFIG_ESP_WIFI_STATIC_RX_BUFFER_NUM=4 +# end of Wi-Fi + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-esp32h2.defaults b/ports/espressif/esp-idf-config/sdkconfig-esp32h2.defaults new file mode 100644 index 0000000000..c1776fc47c --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-esp32h2.defaults @@ -0,0 +1,60 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# Bluetooth +# +CONFIG_BT_ENABLED=y +CONFIG_BT_NIMBLE_ENABLED=y +# +# NimBLE Options +# +CONFIG_BT_NIMBLE_LOG_LEVEL_NONE=y +CONFIG_BT_NIMBLE_NVS_PERSIST=y +# +# Memory Settings +# +CONFIG_BT_NIMBLE_TRANSPORT_ACL_FROM_LL_COUNT=20 +CONFIG_BT_NIMBLE_TRANSPORT_EVT_SIZE=70 +# end of Memory Settings + +CONFIG_BT_NIMBLE_EXT_ADV=y +# end of NimBLE Options + +# end of Bluetooth + +# +# Driver Configurations +# +# +# PCNT Configuration +# +CONFIG_PCNT_SUPPRESS_DEPRECATE_WARN=y +# end of PCNT Configuration + +# +# RMT Configuration +# +CONFIG_RMT_SUPPRESS_DEPRECATE_WARN=y +# end of RMT Configuration + +# end of Driver Configurations + +# +# PHY +# +CONFIG_ESP_PHY_ENABLE_USB=y +# end of PHY + +# +# Wi-Fi +# +CONFIG_ESP_WIFI_STATIC_RX_BUFFER_NUM=4 +# end of Wi-Fi + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-esp32s2.defaults b/ports/espressif/esp-idf-config/sdkconfig-esp32s2.defaults index bfd64ef90e..eba36817a8 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-esp32s2.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-esp32s2.defaults @@ -1,167 +1,66 @@ # -# Espressif IoT Development Framework (ESP-IDF) Project Configuration +# Espressif IoT Development Framework Configuration # -CONFIG_IDF_TARGET_ARCH_XTENSA=y -CONFIG_IDF_TARGET="esp32s2" -CONFIG_IDF_TARGET_ESP32S2=y -CONFIG_IDF_FIRMWARE_CHIP_ID=0x0002 -# end of Espressif IoT Development Framework (ESP-IDF) Project Configuration +# +# Component config +# +# +# Driver Configurations +# +# +# PCNT Configuration +# +CONFIG_PCNT_SUPPRESS_DEPRECATE_WARN=y +# end of PCNT Configuration -CONFIG_SDK_TOOLPREFIX="xtensa-esp32s2-elf-" # -# Bootloader config +# RMT Configuration # -CONFIG_BOOTLOADER_OFFSET_IN_FLASH=0x1000 -# end of Bootloader config +CONFIG_RMT_SUPPRESS_DEPRECATE_WARN=y +# end of RMT Configuration -# CONFIG_ESP32S2_DEFAULT_CPU_FREQ_80 is not set -# -# ESP32S2-specific -# -# CONFIG_ESP32S2_DEFAULT_CPU_FREQ_160 is not set -CONFIG_ESP32S2_DEFAULT_CPU_FREQ_240=y -CONFIG_ESP32S2_DEFAULT_CPU_FREQ_MHZ=240 -# end of ESP32S2-specific +# end of Driver Configurations -# CONFIG_ESP32S2_INSTRUCTION_CACHE_8KB is not set +# +# ESP System Settings +# +CONFIG_ESP_DEFAULT_CPU_FREQ_MHZ_240=y # # Cache config # CONFIG_ESP32S2_INSTRUCTION_CACHE_16KB=y -# CONFIG_ESP32S2_INSTRUCTION_CACHE_LINE_16B is not set -CONFIG_ESP32S2_INSTRUCTION_CACHE_LINE_32B=y -# CONFIG_ESP32S2_DATA_CACHE_0KB is not set -# CONFIG_ESP32S2_DATA_CACHE_8KB is not set CONFIG_ESP32S2_DATA_CACHE_16KB=y -# CONFIG_ESP32S2_DATA_CACHE_LINE_16B is not set -CONFIG_ESP32S2_DATA_CACHE_LINE_32B=y -# CONFIG_ESP32S2_INSTRUCTION_CACHE_WRAP is not set -# CONFIG_ESP32S2_DATA_CACHE_WRAP is not set # end of Cache config -# CONFIG_ESP32S2_TRAX is not set -CONFIG_ESP32S2_TRACEMEM_RESERVE_DRAM=0x0 -CONFIG_ESP32S2_ULP_COPROC_ENABLED=y -CONFIG_ESP32S2_ULP_COPROC_RESERVE_MEM=8176 -CONFIG_ESP32S2_ULP_COPROC_RISCV=y -CONFIG_ESP32S2_DEBUG_OCDAWARE=y -# CONFIG_ESP32S2_DEBUG_STUBS_ENABLE is not set -CONFIG_ESP32S2_BROWNOUT_DET=y -CONFIG_ESP32S2_BROWNOUT_DET_LVL_SEL_7=y -# CONFIG_ESP32S2_BROWNOUT_DET_LVL_SEL_6 is not set -# CONFIG_ESP32S2_BROWNOUT_DET_LVL_SEL_5 is not set -# CONFIG_ESP32S2_BROWNOUT_DET_LVL_SEL_4 is not set -# CONFIG_ESP32S2_BROWNOUT_DET_LVL_SEL_3 is not set -# CONFIG_ESP32S2_BROWNOUT_DET_LVL_SEL_2 is not set -# CONFIG_ESP32S2_BROWNOUT_DET_LVL_SEL_1 is not set -CONFIG_ESP32S2_BROWNOUT_DET_LVL=7 -CONFIG_ESP32S2_TIME_SYSCALL_USE_RTC_FRC1=y -# CONFIG_ESP32S2_TIME_SYSCALL_USE_RTC is not set -# CONFIG_ESP32S2_TIME_SYSCALL_USE_FRC1 is not set -# CONFIG_ESP32S2_TIME_SYSCALL_USE_NONE is not set -CONFIG_ESP32S2_RTC_CLK_SRC_INT_RC=y -# CONFIG_ESP32S2_RTC_CLK_SRC_EXT_CRYS is not set -# CONFIG_ESP32S2_RTC_CLK_SRC_EXT_OSC is not set -# CONFIG_ESP32S2_RTC_CLK_SRC_INT_8MD256 is not set -CONFIG_ESP32S2_RTC_CLK_CAL_CYCLES=576 -# CONFIG_ESP32S2_NO_BLOBS is not set -# CONFIG_ESP32S2_KEEP_USB_ALIVE is not set +# +# Memory +# CONFIG_ESP32S2_RTCDATA_IN_FAST_MEM=y -# CONFIG_ESP32S2_USE_FIXED_STATIC_RAM_SIZE is not set -# -# MAC Config -# -# CONFIG_ESP32S2_UNIVERSAL_MAC_ADDRESSES_ONE is not set -CONFIG_ESP32S2_UNIVERSAL_MAC_ADDRESSES_TWO=y -CONFIG_ESP32S2_UNIVERSAL_MAC_ADDRESSES=2 -# end of MAC Config +# end of Memory -CONFIG_ESP_SLEEP_POWER_DOWN_FLASH=y -# -# Sleep Config -# -# CONFIG_ESP_SLEEP_GPIO_RESET_WORKAROUND is not set -# end of Sleep Config +# end of ESP System Settings -# -# PHY -# -# CONFIG_ESP_PHY_ENABLE_USB is not set -# end of PHY - -CONFIG_ESP_SYSTEM_SINGLE_CORE_MODE=y -# -# Memory protection -# -CONFIG_ESP_SYSTEM_MEMPROT_FEATURE=y -CONFIG_ESP_SYSTEM_MEMPROT_FEATURE_LOCK=y -CONFIG_ESP_SYSTEM_MEMPROT_CPU_PREFETCH_PAD_SIZE=16 -CONFIG_ESP_SYSTEM_MEMPROT_MEM_ALIGN_SIZE=4 -# end of Memory protection - -CONFIG_ESP_MAIN_TASK_AFFINITY_CPU0=y -# CONFIG_ESP_MAIN_TASK_AFFINITY_NO_AFFINITY is not set -CONFIG_ESP_MAIN_TASK_AFFINITY=0x0 # # Wi-Fi # -CONFIG_ESP32_WIFI_ENABLED=y -CONFIG_ESP32_WIFI_STATIC_RX_BUFFER_NUM=4 -CONFIG_ESP32_WIFI_DYNAMIC_RX_BUFFER_NUM=8 -# CONFIG_ESP32_WIFI_STATIC_TX_BUFFER is not set -CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER=y -CONFIG_ESP32_WIFI_TX_BUFFER_TYPE=1 -CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER_NUM=16 -CONFIG_ESP32_WIFI_CACHE_TX_BUFFER_NUM=16 -# CONFIG_ESP32_WIFI_CSI_ENABLED is not set -CONFIG_ESP32_WIFI_AMPDU_TX_ENABLED=y -CONFIG_ESP32_WIFI_TX_BA_WIN=6 -CONFIG_ESP32_WIFI_AMPDU_RX_ENABLED=y -CONFIG_ESP32_WIFI_RX_BA_WIN=6 -# CONFIG_ESP32_WIFI_NVS_ENABLED is not set -CONFIG_ESP32_WIFI_SOFTAP_BEACON_MAX_LEN=752 -CONFIG_ESP32_WIFI_MGMT_SBUF_NUM=32 -CONFIG_ESP32_WIFI_IRAM_OPT=y -CONFIG_ESP32_WIFI_RX_IRAM_OPT=y -# CONFIG_ESP32_WIFI_ENABLE_WPA3_SAE is not set -# CONFIG_ESP_WIFI_EXTERNAL_COEXIST_ENABLE is not set +CONFIG_ESP_WIFI_STATIC_RX_BUFFER_NUM=4 +CONFIG_ESP_WIFI_CACHE_TX_BUFFER_NUM=16 +CONFIG_ESP_WIFI_RX_BA_WIN=4 # end of Wi-Fi -CONFIG_FREERTOS_UNICORE=y # -# FreeRTOS +# Newlib # -CONFIG_FREERTOS_TICK_SUPPORT_CORETIMER=y -CONFIG_FREERTOS_CORETIMER_0=y -# CONFIG_FREERTOS_CORETIMER_1 is not set -CONFIG_FREERTOS_SYSTICK_USES_CCOUNT=y -CONFIG_FREERTOS_OPTIMIZED_SCHEDULER=y -# end of FreeRTOS +CONFIG_NEWLIB_NANO_FORMAT=y +# end of Newlib -CONFIG_MBEDTLS_HARDWARE_GCM=y # -# Deprecated options for backward compatibility +# Ultra Low Power (ULP) Co-processor # -CONFIG_TOOLPREFIX="xtensa-esp32s2-elf-" -# CONFIG_ESP32_APPTRACE_DEST_TRAX is not set -CONFIG_ESP32_APPTRACE_DEST_NONE=y -CONFIG_ESP32_APPTRACE_LOCK_ENABLE=y -CONFIG_ESP_SYSTEM_PD_FLASH=y -# CONFIG_ESP32C3_LIGHTSLEEP_GPIO_RESET_WORKAROUND is not set -CONFIG_ESP32_PHY_CALIBRATION_AND_DATA_STORAGE=y -# CONFIG_ESP32_PHY_INIT_DATA_IN_PARTITION is not set -CONFIG_ESP32_PHY_MAX_WIFI_TX_POWER=20 -CONFIG_ESP32_PHY_MAX_TX_POWER=20 -CONFIG_ESP32S2_ALLOW_RTC_FAST_MEM_AS_HEAP=y -CONFIG_ESP32H2_MEMPROT_FEATURE=y -CONFIG_ESP32H2_MEMPROT_FEATURE_LOCK=y -# CONFIG_EXTERNAL_COEX_ENABLE is not set -# CONFIG_ESP32_ENABLE_COREDUMP_TO_FLASH is not set -# CONFIG_ESP32_ENABLE_COREDUMP_TO_UART is not set -CONFIG_ESP32_ENABLE_COREDUMP_TO_NONE=y -CONFIG_ESP32_PTHREAD_TASK_PRIO_DEFAULT=5 -CONFIG_ESP32_PTHREAD_TASK_STACK_SIZE_DEFAULT=3072 -CONFIG_ESP32_PTHREAD_STACK_MIN=768 -CONFIG_ESP32_PTHREAD_TASK_CORE_DEFAULT=-1 -CONFIG_ESP32_PTHREAD_TASK_NAME_DEFAULT="pthread" -# end of Deprecated options for backward compatibility +CONFIG_ULP_COPROC_ENABLED=y +CONFIG_ULP_COPROC_RESERVE_MEM=8176 +# end of Ultra Low Power (ULP) Co-processor + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-esp32s3.defaults b/ports/espressif/esp-idf-config/sdkconfig-esp32s3.defaults index f6fb80c752..59966474a5 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-esp32s3.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-esp32s3.defaults @@ -1,221 +1,106 @@ -CONFIG_IDF_TARGET_ARCH_XTENSA=y -CONFIG_IDF_TARGET="esp32s3" -CONFIG_IDF_TARGET_ESP32S3=y -CONFIG_IDF_FIRMWARE_CHIP_ID=0x0009 # -# SDK tool configuration +# Espressif IoT Development Framework Configuration # -CONFIG_SDK_TOOLPREFIX="xtensa-esp32s3-elf-" -# end of SDK tool configuration - -# -# Bootloader config -# -CONFIG_BOOTLOADER_OFFSET_IN_FLASH=0x0 -# end of Bootloader config - # # Component config # # # Bluetooth # -CONFIG_BT_SOC_SUPPORT_5_0=y +CONFIG_BT_ENABLED=y +CONFIG_BT_NIMBLE_ENABLED=y # # NimBLE Options # -# CONFIG_BT_NIMBLE_PINNED_TO_CORE_0 is not set +CONFIG_BT_NIMBLE_LOG_LEVEL_NONE=y CONFIG_BT_NIMBLE_PINNED_TO_CORE_1=y -CONFIG_BT_NIMBLE_PINNED_TO_CORE=1 +CONFIG_BT_NIMBLE_NVS_PERSIST=y +# +# Memory Settings +# +CONFIG_BT_NIMBLE_TRANSPORT_ACL_FROM_LL_COUNT=20 +CONFIG_BT_NIMBLE_TRANSPORT_EVT_SIZE=70 +# end of Memory Settings + +CONFIG_BT_NIMBLE_EXT_ADV=y +# CONFIG_BT_NIMBLE_ENABLE_PERIODIC_ADV is not set # end of NimBLE Options +# +# Controller Options +# +# CONFIG_BT_CTRL_BLE_SCAN_DUPL is not set +# end of Controller Options + # end of Bluetooth # -# ESP32S3-Specific +# Driver Configurations # -# CONFIG_ESP32S3_DEFAULT_CPU_FREQ_80 is not set -# CONFIG_ESP32S3_DEFAULT_CPU_FREQ_160 is not set -CONFIG_ESP32S3_DEFAULT_CPU_FREQ_240=y -CONFIG_ESP32S3_DEFAULT_CPU_FREQ_MHZ=240 # -# Cache config +# PCNT Configuration # -CONFIG_ESP32S3_INSTRUCTION_CACHE_16KB=y -# CONFIG_ESP32S3_INSTRUCTION_CACHE_32KB is not set -CONFIG_ESP32S3_INSTRUCTION_CACHE_SIZE=0x4000 -# CONFIG_ESP32S3_INSTRUCTION_CACHE_4WAYS is not set -CONFIG_ESP32S3_INSTRUCTION_CACHE_8WAYS=y -CONFIG_ESP32S3_ICACHE_ASSOCIATED_WAYS=8 -# CONFIG_ESP32S3_INSTRUCTION_CACHE_LINE_16B is not set -CONFIG_ESP32S3_INSTRUCTION_CACHE_LINE_32B=y -CONFIG_ESP32S3_INSTRUCTION_CACHE_LINE_SIZE=32 -# CONFIG_ESP32S3_INSTRUCTION_CACHE_WRAP is not set -# CONFIG_ESP32S3_DATA_CACHE_16KB is not set -CONFIG_ESP32S3_DATA_CACHE_32KB=y -# CONFIG_ESP32S3_DATA_CACHE_64KB is not set -CONFIG_ESP32S3_DATA_CACHE_SIZE=0x8000 -# CONFIG_ESP32S3_DATA_CACHE_4WAYS is not set -CONFIG_ESP32S3_DATA_CACHE_8WAYS=y -CONFIG_ESP32S3_DCACHE_ASSOCIATED_WAYS=8 -# CONFIG_ESP32S3_DATA_CACHE_LINE_16B is not set -CONFIG_ESP32S3_DATA_CACHE_LINE_32B=y -# CONFIG_ESP32S3_DATA_CACHE_LINE_64B is not set -CONFIG_ESP32S3_DATA_CACHE_LINE_SIZE=32 -# CONFIG_ESP32S3_DATA_CACHE_WRAP is not set -# end of Cache config - -# CONFIG_ESP32S3_TRAX is not set -CONFIG_ESP32S3_TRACEMEM_RESERVE_DRAM=0x0 -CONFIG_ESP32S3_ULP_COPROC_ENABLED=y -CONFIG_ESP32S3_ULP_COPROC_RESERVE_MEM=8176 -CONFIG_ESP32S3_ULP_COPROC_RISCV=y -CONFIG_ESP32S3_BROWNOUT_DET=y -CONFIG_ESP32S3_BROWNOUT_DET_LVL_SEL_7=y -# CONFIG_ESP32S3_BROWNOUT_DET_LVL_SEL_6 is not set -# CONFIG_ESP32S3_BROWNOUT_DET_LVL_SEL_5 is not set -# CONFIG_ESP32S3_BROWNOUT_DET_LVL_SEL_4 is not set -# CONFIG_ESP32S3_BROWNOUT_DET_LVL_SEL_3 is not set -# CONFIG_ESP32S3_BROWNOUT_DET_LVL_SEL_2 is not set -# CONFIG_ESP32S3_BROWNOUT_DET_LVL_SEL_1 is not set -CONFIG_ESP32S3_BROWNOUT_DET_LVL=7 -CONFIG_ESP32S3_TIME_SYSCALL_USE_RTC_FRC1=y -# CONFIG_ESP32S3_TIME_SYSCALL_USE_RTC is not set -# CONFIG_ESP32S3_TIME_SYSCALL_USE_FRC1 is not set -# CONFIG_ESP32S3_TIME_SYSCALL_USE_NONE is not set -CONFIG_ESP32S3_RTC_CLK_SRC_INT_RC=y -# CONFIG_ESP32S3_RTC_CLK_SRC_EXT_CRYS is not set -# CONFIG_ESP32S3_RTC_CLK_SRC_EXT_OSC is not set -# CONFIG_ESP32S3_RTC_CLK_SRC_INT_8MD256 is not set -CONFIG_ESP32S3_RTC_CLK_CAL_CYCLES=1024 -CONFIG_ESP32S3_DEEP_SLEEP_WAKEUP_DELAY=2000 -CONFIG_ESP32S3_RTCDATA_IN_FAST_MEM=y -# CONFIG_ESP32S3_USE_FIXED_STATIC_RAM_SIZE is not set -# end of ESP32S3-Specific +CONFIG_PCNT_SUPPRESS_DEPRECATE_WARN=y +# end of PCNT Configuration # -# Hardware Settings +# RMT Configuration # -# -# MAC Config -# -# CONFIG_ESP32S3_UNIVERSAL_MAC_ADDRESSES_TWO is not set -CONFIG_ESP32S3_UNIVERSAL_MAC_ADDRESSES_FOUR=y -CONFIG_ESP32S3_UNIVERSAL_MAC_ADDRESSES=4 -# end of MAC Config +CONFIG_RMT_SUPPRESS_DEPRECATE_WARN=y +# end of RMT Configuration + +# end of Driver Configurations # -# Sleep Config +# LCD and Touch Panel # -CONFIG_ESP_SLEEP_GPIO_RESET_WORKAROUND=y -# end of Sleep Config +# +# LCD Peripheral Configuration +# +CONFIG_LCD_RGB_RESTART_IN_VSYNC=y +# end of LCD Peripheral Configuration -# end of Hardware Settings - -# -# PHY -# -CONFIG_ESP_PHY_ENABLE_USB=y -# end of PHY +# end of LCD and Touch Panel # # ESP System Settings # -# CONFIG_ESP_MAIN_TASK_AFFINITY_CPU0 is not set +CONFIG_ESP_DEFAULT_CPU_FREQ_MHZ_240=y +# +# Memory +# +CONFIG_ESP32S3_RTCDATA_IN_FAST_MEM=y +# end of Memory + CONFIG_ESP_MAIN_TASK_AFFINITY_CPU1=y -# CONFIG_ESP_MAIN_TASK_AFFINITY_NO_AFFINITY is not set -CONFIG_ESP_MAIN_TASK_AFFINITY=0x1 # end of ESP System Settings +# +# IPC (Inter-Processor Call) +# +CONFIG_ESP_IPC_TASK_STACK_SIZE=1536 +# end of IPC (Inter-Processor Call) + # # Wi-Fi # -CONFIG_ESP32_WIFI_ENABLED=y -CONFIG_ESP32_WIFI_SW_COEXIST_ENABLE=y -CONFIG_ESP32_WIFI_STATIC_RX_BUFFER_NUM=4 -CONFIG_ESP32_WIFI_DYNAMIC_RX_BUFFER_NUM=8 -# CONFIG_ESP32_WIFI_STATIC_TX_BUFFER is not set -CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER=y -CONFIG_ESP32_WIFI_TX_BUFFER_TYPE=1 -CONFIG_ESP32_WIFI_CACHE_TX_BUFFER_NUM=16 -CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER_NUM=16 -# CONFIG_ESP32_WIFI_CSI_ENABLED is not set -CONFIG_ESP32_WIFI_AMPDU_TX_ENABLED=y -CONFIG_ESP32_WIFI_TX_BA_WIN=6 -CONFIG_ESP32_WIFI_AMPDU_RX_ENABLED=y -CONFIG_ESP32_WIFI_RX_BA_WIN=6 -# CONFIG_ESP32_WIFI_AMSDU_TX_ENABLED is not set -# CONFIG_ESP32_WIFI_NVS_ENABLED is not set -CONFIG_ESP32_WIFI_TASK_PINNED_TO_CORE_0=y -# CONFIG_ESP32_WIFI_TASK_PINNED_TO_CORE_1 is not set -CONFIG_ESP32_WIFI_SOFTAP_BEACON_MAX_LEN=752 -CONFIG_ESP32_WIFI_MGMT_SBUF_NUM=32 -CONFIG_ESP32_WIFI_IRAM_OPT=y -CONFIG_ESP32_WIFI_RX_IRAM_OPT=y -# CONFIG_ESP32_WIFI_ENABLE_WPA3_SAE is not set +CONFIG_ESP_WIFI_STATIC_RX_BUFFER_NUM=4 +CONFIG_ESP_WIFI_CACHE_TX_BUFFER_NUM=16 # end of Wi-Fi # -# FreeRTOS +# Newlib # -# CONFIG_FREERTOS_UNICORE is not set -# end of FreeRTOS +CONFIG_NEWLIB_NANO_FORMAT=y +# end of Newlib + +# +# Ultra Low Power (ULP) Co-processor +# +CONFIG_ULP_COPROC_ENABLED=y +CONFIG_ULP_COPROC_RESERVE_MEM=8176 +# end of Ultra Low Power (ULP) Co-processor # end of Component config -# -# Deprecated options for backward compatibility -# -CONFIG_TOOLPREFIX="xtensa-esp32s3-elf-" -# CONFIG_ESP32_APPTRACE_DEST_TRAX is not set -CONFIG_ESP32_APPTRACE_DEST_NONE=y -CONFIG_ESP32_APPTRACE_LOCK_ENABLE=y -# CONFIG_NIMBLE_PINNED_TO_CORE_0 is not set -CONFIG_NIMBLE_PINNED_TO_CORE_1=y -CONFIG_NIMBLE_PINNED_TO_CORE=1 -CONFIG_ESP32C3_LIGHTSLEEP_GPIO_RESET_WORKAROUND=y -CONFIG_ESP32_PHY_CALIBRATION_AND_DATA_STORAGE=y -# CONFIG_ESP32_PHY_INIT_DATA_IN_PARTITION is not set -CONFIG_ESP32_PHY_MAX_WIFI_TX_POWER=20 -CONFIG_ESP32_PHY_MAX_TX_POWER=20 -CONFIG_ESP32S2_ALLOW_RTC_FAST_MEM_AS_HEAP=y -# CONFIG_ESP32_DEBUG_STUBS_ENABLE is not set -# CONFIG_ESP32_ENABLE_COREDUMP_TO_FLASH is not set -# CONFIG_ESP32_ENABLE_COREDUMP_TO_UART is not set -CONFIG_ESP32_ENABLE_COREDUMP_TO_NONE=y -CONFIG_ESP32_PTHREAD_TASK_PRIO_DEFAULT=5 -CONFIG_ESP32_PTHREAD_TASK_STACK_SIZE_DEFAULT=3072 -CONFIG_ESP32_PTHREAD_STACK_MIN=768 -CONFIG_ESP32_DEFAULT_PTHREAD_CORE_NO_AFFINITY=y -# CONFIG_ESP32_DEFAULT_PTHREAD_CORE_0 is not set -# CONFIG_ESP32_DEFAULT_PTHREAD_CORE_1 is not set -CONFIG_ESP32_PTHREAD_TASK_CORE_DEFAULT=-1 -CONFIG_ESP32_PTHREAD_TASK_NAME_DEFAULT="pthread" -# end of Deprecated options for backward compatibility - -# -# Camera configuration -# -CONFIG_OV7670_SUPPORT=y -# CONFIG_OV7725_SUPPORT is not set -# CONFIG_NT99141_SUPPORT is not set -CONFIG_OV2640_SUPPORT=y -CONFIG_OV3660_SUPPORT=y -CONFIG_OV5640_SUPPORT=y -# CONFIG_GC2145_SUPPORT is not set -# CONFIG_GC032A_SUPPORT is not set -# CONFIG_GC0308_SUPPORT is not set -# CONFIG_BF3005_SUPPORT is not set -# CONFIG_BF20A6_SUPPORT is not set -# CONFIG_SC101IOT_SUPPORT is not set -# CONFIG_SC030IOT_SUPPORT is not set -# CONFIG_SCCB_HARDWARE_I2C_PORT0 is not set -CONFIG_SCCB_HARDWARE_I2C_PORT1=y -CONFIG_SCCB_CLK_FREQ=100000 -CONFIG_CAMERA_CORE0=y -# CONFIG_CAMERA_CORE1 is not set -# CONFIG_CAMERA_NO_AFFINITY is not set -CONFIG_CAMERA_DMA_BUFFER_SIZE_MAX=32768 -# CONFIG_CAMERA_CONVERTER_ENABLED is not set -# end of Camera configuration -# end of Component config +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-16MB-no-uf2.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-16MB-no-uf2.defaults similarity index 100% rename from ports/espressif/esp-idf-config/sdkconfig-16MB-no-uf2.defaults rename to ports/espressif/esp-idf-config/sdkconfig-flash-16MB-no-uf2.defaults diff --git a/ports/espressif/esp-idf-config/sdkconfig-16MB.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-16MB.defaults similarity index 66% rename from ports/espressif/esp-idf-config/sdkconfig-16MB.defaults rename to ports/espressif/esp-idf-config/sdkconfig-flash-16MB.defaults index fac8ba1cad..cc5d54fec4 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-16MB.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-16MB.defaults @@ -1,4 +1,7 @@ # +# Espressif IoT Development Framework Configuration +# +# # Serial flasher config # # CONFIG_ESPTOOLPY_FLASHSIZE_1MB is not set @@ -6,13 +9,17 @@ # CONFIG_ESPTOOLPY_FLASHSIZE_4MB is not set # CONFIG_ESPTOOLPY_FLASHSIZE_8MB is not set CONFIG_ESPTOOLPY_FLASHSIZE_16MB=y +# CONFIG_ESPTOOLPY_FLASHSIZE_32MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_64MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_128MB is not set CONFIG_ESPTOOLPY_FLASHSIZE="16MB" -CONFIG_ESPTOOLPY_FLASHSIZE_DETECT=y # end of Serial flasher config -CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="esp-idf-config/partitions-16MB.csv" # # Partition Table # +CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="esp-idf-config/partitions-16MB.csv" CONFIG_PARTITION_TABLE_FILENAME="esp-idf-config/partitions-16MB.csv" # end of Partition Table + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-2MB-no-ota-no-uf2.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-2MB-no-ota-no-uf2.defaults similarity index 100% rename from ports/espressif/esp-idf-config/sdkconfig-2MB-no-ota-no-uf2.defaults rename to ports/espressif/esp-idf-config/sdkconfig-flash-2MB-no-ota-no-uf2.defaults diff --git a/ports/espressif/esp-idf-config/sdkconfig-32MB.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-32MB.defaults similarity index 100% rename from ports/espressif/esp-idf-config/sdkconfig-32MB.defaults rename to ports/espressif/esp-idf-config/sdkconfig-flash-32MB.defaults diff --git a/ports/espressif/esp-idf-config/sdkconfig-flash-40m.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-40m.defaults new file mode 100644 index 0000000000..235a62a57e --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-40m.defaults @@ -0,0 +1,14 @@ +# CONFIG_ESPTOOLPY_FLASHFREQ_120M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_80M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_64M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_60M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_48M is not set +CONFIG_ESPTOOLPY_FLASHFREQ_40M=y +# CONFIG_ESPTOOLPY_FLASHFREQ_32M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_30M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_26M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_24M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_20M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_16M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_15M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_80M_DEFAULT is not set diff --git a/ports/espressif/esp-idf-config/sdkconfig-flash-48m.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-48m.defaults new file mode 100644 index 0000000000..b710fd2255 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-48m.defaults @@ -0,0 +1,14 @@ +# CONFIG_ESPTOOLPY_FLASHFREQ_120M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_80M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_64M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_60M is not set +CONFIG_ESPTOOLPY_FLASHFREQ_48M=y +# CONFIG_ESPTOOLPY_FLASHFREQ_40M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_32M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_30M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_26M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_24M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_20M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_16M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_15M is not set +CONFIG_ESPTOOLPY_FLASHFREQ_48M_DEFAULT=y diff --git a/ports/espressif/esp-idf-config/sdkconfig-4MB-1ota.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-4MB-1ota.defaults similarity index 100% rename from ports/espressif/esp-idf-config/sdkconfig-4MB-1ota.defaults rename to ports/espressif/esp-idf-config/sdkconfig-flash-4MB-1ota.defaults diff --git a/ports/espressif/esp-idf-config/sdkconfig-4MB-no-uf2.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-4MB-no-uf2.defaults similarity index 66% rename from ports/espressif/esp-idf-config/sdkconfig-4MB-no-uf2.defaults rename to ports/espressif/esp-idf-config/sdkconfig-flash-4MB-no-uf2.defaults index 2325a67296..d24998167e 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-4MB-no-uf2.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-4MB-no-uf2.defaults @@ -1,4 +1,7 @@ # +# Espressif IoT Development Framework Configuration +# +# # Serial flasher config # # CONFIG_ESPTOOLPY_FLASHSIZE_1MB is not set @@ -6,13 +9,17 @@ CONFIG_ESPTOOLPY_FLASHSIZE_4MB=y # CONFIG_ESPTOOLPY_FLASHSIZE_8MB is not set # CONFIG_ESPTOOLPY_FLASHSIZE_16MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_32MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_64MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_128MB is not set CONFIG_ESPTOOLPY_FLASHSIZE="4MB" -CONFIG_ESPTOOLPY_FLASHSIZE_DETECT=y # end of Serial flasher config -CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="esp-idf-config/partitions-4MB-no-uf2.csv" # # Partition Table # +CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="esp-idf-config/partitions-4MB-no-uf2.csv" CONFIG_PARTITION_TABLE_FILENAME="esp-idf-config/partitions-4MB-no-uf2.csv" # end of Partition Table + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-4MB.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-4MB.defaults similarity index 66% rename from ports/espressif/esp-idf-config/sdkconfig-4MB.defaults rename to ports/espressif/esp-idf-config/sdkconfig-flash-4MB.defaults index 69f15ebe7b..811c9ea37d 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-4MB.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-4MB.defaults @@ -1,4 +1,7 @@ # +# Espressif IoT Development Framework Configuration +# +# # Serial flasher config # # CONFIG_ESPTOOLPY_FLASHSIZE_1MB is not set @@ -6,13 +9,17 @@ CONFIG_ESPTOOLPY_FLASHSIZE_4MB=y # CONFIG_ESPTOOLPY_FLASHSIZE_8MB is not set # CONFIG_ESPTOOLPY_FLASHSIZE_16MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_32MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_64MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_128MB is not set CONFIG_ESPTOOLPY_FLASHSIZE="4MB" -CONFIG_ESPTOOLPY_FLASHSIZE_DETECT=y # end of Serial flasher config -CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="esp-idf-config/partitions-4MB.csv" # # Partition Table # +CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="esp-idf-config/partitions-4MB.csv" CONFIG_PARTITION_TABLE_FILENAME="esp-idf-config/partitions-4MB.csv" # end of Partition Table + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-flash-80m.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-80m.defaults new file mode 100644 index 0000000000..2ea4419003 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-80m.defaults @@ -0,0 +1,14 @@ +# CONFIG_ESPTOOLPY_FLASHFREQ_120M is not set +CONFIG_ESPTOOLPY_FLASHFREQ_80M=y +# CONFIG_ESPTOOLPY_FLASHFREQ_64M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_60M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_48M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_40M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_32M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_30M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_26M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_24M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_20M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_16M is not set +# CONFIG_ESPTOOLPY_FLASHFREQ_15M is not set +CONFIG_ESPTOOLPY_FLASHFREQ_80M_DEFAULT=y diff --git a/ports/espressif/esp-idf-config/sdkconfig-8MB-no-uf2.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-8MB-no-uf2.defaults similarity index 66% rename from ports/espressif/esp-idf-config/sdkconfig-8MB-no-uf2.defaults rename to ports/espressif/esp-idf-config/sdkconfig-flash-8MB-no-uf2.defaults index 2a2548ba04..eda2a71c62 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-8MB-no-uf2.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-8MB-no-uf2.defaults @@ -1,4 +1,7 @@ # +# Espressif IoT Development Framework Configuration +# +# # Serial flasher config # # CONFIG_ESPTOOLPY_FLASHSIZE_1MB is not set @@ -6,13 +9,17 @@ # CONFIG_ESPTOOLPY_FLASHSIZE_4MB is not set CONFIG_ESPTOOLPY_FLASHSIZE_8MB=y # CONFIG_ESPTOOLPY_FLASHSIZE_16MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_32MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_64MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_128MB is not set CONFIG_ESPTOOLPY_FLASHSIZE="8MB" -CONFIG_ESPTOOLPY_FLASHSIZE_DETECT=y # end of Serial flasher config -CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="esp-idf-config/partitions-8MB-no-uf2.csv" # # Partition Table # +CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="esp-idf-config/partitions-8MB-no-uf2.csv" CONFIG_PARTITION_TABLE_FILENAME="esp-idf-config/partitions-8MB-no-uf2.csv" # end of Partition Table + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-8MB.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-8MB.defaults similarity index 66% rename from ports/espressif/esp-idf-config/sdkconfig-8MB.defaults rename to ports/espressif/esp-idf-config/sdkconfig-flash-8MB.defaults index 1ecb1b4c16..c64775aa1c 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-8MB.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-8MB.defaults @@ -1,4 +1,7 @@ # +# Espressif IoT Development Framework Configuration +# +# # Serial flasher config # # CONFIG_ESPTOOLPY_FLASHSIZE_1MB is not set @@ -6,8 +9,10 @@ # CONFIG_ESPTOOLPY_FLASHSIZE_4MB is not set CONFIG_ESPTOOLPY_FLASHSIZE_8MB=y # CONFIG_ESPTOOLPY_FLASHSIZE_16MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_32MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_64MB is not set +# CONFIG_ESPTOOLPY_FLASHSIZE_128MB is not set CONFIG_ESPTOOLPY_FLASHSIZE="8MB" -CONFIG_ESPTOOLPY_FLASHSIZE_DETECT=y # end of Serial flasher config # @@ -16,3 +21,5 @@ CONFIG_ESPTOOLPY_FLASHSIZE_DETECT=y CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="esp-idf-config/partitions-8MB.csv" CONFIG_PARTITION_TABLE_FILENAME="esp-idf-config/partitions-8MB.csv" # end of Partition Table + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-flash-dio.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-dio.defaults new file mode 100644 index 0000000000..12ef8ad896 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-dio.defaults @@ -0,0 +1,6 @@ +# CONFIG_ESPTOOLPY_OCT_FLASH is not set +# CONFIG_ESPTOOLPY_FLASHMODE_QIO is not set +# CONFIG_ESPTOOLPY_FLASHMODE_QOUT is not set +CONFIG_ESPTOOLPY_FLASHMODE_DIO=y +# CONFIG_ESPTOOLPY_FLASHMODE_DOUT is not set +# CONFIG_ESPTOOLPY_FLASHMODE_OPI is not set diff --git a/ports/espressif/esp-idf-config/sdkconfig-flash-dout.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-dout.defaults new file mode 100644 index 0000000000..e0f319ce39 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-dout.defaults @@ -0,0 +1,6 @@ +# CONFIG_ESPTOOLPY_OCT_FLASH is not set +# CONFIG_ESPTOOLPY_FLASHMODE_QIO is not set +# CONFIG_ESPTOOLPY_FLASHMODE_QOUT is not set +# CONFIG_ESPTOOLPY_FLASHMODE_DIO is not set +CONFIG_ESPTOOLPY_FLASHMODE_DOUT=y +# CONFIG_ESPTOOLPY_FLASHMODE_OPI is not set diff --git a/ports/espressif/esp-idf-config/sdkconfig-flash-opi.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-opi.defaults new file mode 100644 index 0000000000..90e1291cc8 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-opi.defaults @@ -0,0 +1,6 @@ +CONFIG_ESPTOOLPY_OCT_FLASH=y +# CONFIG_ESPTOOLPY_FLASHMODE_QIO is not set +# CONFIG_ESPTOOLPY_FLASHMODE_QOUT is not set +# CONFIG_ESPTOOLPY_FLASHMODE_DIO is not set +# CONFIG_ESPTOOLPY_FLASHMODE_DOUT is not set +# CONFIG_ESPTOOLPY_FLASHMODE_OPI is not set diff --git a/ports/espressif/esp-idf-config/sdkconfig-flash-qio.defaults b/ports/espressif/esp-idf-config/sdkconfig-flash-qio.defaults new file mode 100644 index 0000000000..647dd84dda --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-flash-qio.defaults @@ -0,0 +1,6 @@ +# CONFIG_ESPTOOLPY_OCT_FLASH is not set +CONFIG_ESPTOOLPY_FLASHMODE_QIO=y +# CONFIG_ESPTOOLPY_FLASHMODE_QOUT is not set +# CONFIG_ESPTOOLPY_FLASHMODE_DIO is not set +# CONFIG_ESPTOOLPY_FLASHMODE_DOUT is not set +# CONFIG_ESPTOOLPY_FLASHMODE_OPI is not set diff --git a/ports/espressif/esp-idf-config/sdkconfig-opt.defaults b/ports/espressif/esp-idf-config/sdkconfig-opt.defaults index 1ccd6478fe..74502488dc 100644 --- a/ports/espressif/esp-idf-config/sdkconfig-opt.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig-opt.defaults @@ -1,41 +1,23 @@ # +# Espressif IoT Development Framework Configuration +# +# # Bootloader config # -CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_SIZE=y -# CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_DEBUG is not set -# CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_PERF is not set -# CONFIG_BOOTLOADER_COMPILER_OPTIMIZATION_NONE is not set CONFIG_BOOTLOADER_LOG_LEVEL_NONE=y -# CONFIG_BOOTLOADER_LOG_LEVEL_ERROR is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_WARN is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_INFO is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_DEBUG is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_VERBOSE is not set # end of Bootloader config # # Compiler options # -# CONFIG_COMPILER_OPTIMIZATION_DEFAULT is not set CONFIG_COMPILER_OPTIMIZATION_SIZE=y -# CONFIG_COMPILER_OPTIMIZATION_PERF is not set -# CONFIG_COMPILER_OPTIMIZATION_NONE is not set -# CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_ENABLE is not set CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_SILENT=y -# CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_DISABLE is not set -CONFIG_COMPILER_OPTIMIZATION_ASSERTION_LEVEL=1 -# CONFIG_COMPILER_OPTIMIZATION_CHECKS_SILENT is not set +CONFIG_COMPILER_OPTIMIZATION_CHECKS_SILENT=y # end of Compiler options # # Component config # -# -# ESP32S3-Specific -# -CONFIG_ESP32S3_DEBUG_OCDAWARE=y -# end of ESP32S3-Specific - # # Common ESP-related # @@ -45,74 +27,17 @@ CONFIG_ESP32S3_DEBUG_OCDAWARE=y # # ESP System Settings # -# CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT is not set -# CONFIG_ESP_SYSTEM_PANIC_PRINT_REBOOT is not set CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT=y -# CONFIG_ESP_SYSTEM_PANIC_GDBSTUB is not set -# CONFIG_ESP_CONSOLE_UART_DEFAULT is not set -# CONFIG_ESP_CONSOLE_USB_CDC is not set -# CONFIG_ESP_CONSOLE_USB_SERIAL_JTAG is not set -# CONFIG_ESP_CONSOLE_UART_CUSTOM is not set CONFIG_ESP_CONSOLE_NONE=y -# CONFIG_ESP_CONSOLE_SECONDARY_NONE is not set -CONFIG_ESP_CONSOLE_SECONDARY_USB_SERIAL_JTAG=y -CONFIG_ESP_CONSOLE_MULTIPLE_UART=y -CONFIG_ESP_CONSOLE_UART_NUM=-1 +CONFIG_ESP_CONSOLE_SECONDARY_NONE=y # end of ESP System Settings -# -# FreeRTOS -# -CONFIG_FREERTOS_ASSERT_ON_UNTESTED_FUNCTION=y -CONFIG_FREERTOS_ASSERT_FAIL_ABORT=y -# CONFIG_FREERTOS_ASSERT_FAIL_PRINT_CONTINUE is not set -# CONFIG_FREERTOS_ASSERT_DISABLE is not set -CONFIG_FREERTOS_DEBUG_OCDAWARE=y -# end of FreeRTOS - -# -# Hardware Abstraction Layer (HAL) and Low Level (LL) -# -CONFIG_HAL_ASSERTION_EQUALS_SYSTEM=y -# CONFIG_HAL_ASSERTION_DISABLE is not set -# CONFIG_HAL_ASSERTION_SILIENT is not set -CONFIG_HAL_DEFAULT_ASSERTION_LEVEL=1 -# end of Hardware Abstraction Layer (HAL) and Low Level (LL) - # # Log output # CONFIG_LOG_DEFAULT_LEVEL_NONE=y -# CONFIG_LOG_DEFAULT_LEVEL_ERROR is not set -# CONFIG_LOG_DEFAULT_LEVEL_WARN is not set -# CONFIG_LOG_DEFAULT_LEVEL_INFO is not set -# CONFIG_LOG_DEFAULT_LEVEL_DEBUG is not set -# CONFIG_LOG_DEFAULT_LEVEL_VERBOSE is not set # end of Log output -# -# LWIP -# -CONFIG_LWIP_ESP_LWIP_ASSERT=y -# end of LWIP - # end of Component config -# -# Deprecated options for backward compatibility -# -# CONFIG_COMPILER_OPTIMIZATION_LEVEL_DEBUG is not set -CONFIG_COMPILER_OPTIMIZATION_LEVEL_RELEASE=y -# CONFIG_OPTIMIZATION_ASSERTIONS_ENABLED is not set -CONFIG_OPTIMIZATION_ASSERTIONS_SILENT=y -# CONFIG_OPTIMIZATION_ASSERTIONS_DISABLED is not set -CONFIG_OPTIMIZATION_ASSERTION_LEVEL=1 -# CONFIG_ESP32S2_PANIC_PRINT_HALT is not set -# CONFIG_ESP32S2_PANIC_PRINT_REBOOT is not set -CONFIG_ESP32S2_PANIC_SILENT_REBOOT=y -# CONFIG_ESP32S2_PANIC_GDBSTUB is not set -# CONFIG_CONSOLE_UART_DEFAULT is not set -# CONFIG_CONSOLE_UART_CUSTOM is not set -CONFIG_ESP_CONSOLE_UART_NONE=y -CONFIG_CONSOLE_UART_NUM=-1 -# end of Deprecated options for backward compatibility +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig-psram-120m.defaults b/ports/espressif/esp-idf-config/sdkconfig-psram-120m.defaults new file mode 100644 index 0000000000..4ff192db3a --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-psram-120m.defaults @@ -0,0 +1,3 @@ +CONFIG_SPIRAM_SPEED_120M=y +# CONFIG_SPIRAM_SPEED_80M is not set +# CONFIG_SPIRAM_SPEED_40M is not set diff --git a/ports/espressif/esp-idf-config/sdkconfig-psram-2MB.defaults b/ports/espressif/esp-idf-config/sdkconfig-psram-2MB.defaults new file mode 100644 index 0000000000..154e9517e5 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-psram-2MB.defaults @@ -0,0 +1,4 @@ +# CONFIG_SPIRAM_TYPE_AUTO is not set +CONFIG_SPIRAM_TYPE_ESPPSRAM16=y +# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set +# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set diff --git a/ports/espressif/esp-idf-config/sdkconfig-psram-40m.defaults b/ports/espressif/esp-idf-config/sdkconfig-psram-40m.defaults new file mode 100644 index 0000000000..5dba8c6d55 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-psram-40m.defaults @@ -0,0 +1,2 @@ +# CONFIG_SPIRAM_SPEED_80M is not set +CONFIG_SPIRAM_SPEED_40M=y diff --git a/ports/espressif/esp-idf-config/sdkconfig-psram-4MB.defaults b/ports/espressif/esp-idf-config/sdkconfig-psram-4MB.defaults new file mode 100644 index 0000000000..86ef9bcf4b --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-psram-4MB.defaults @@ -0,0 +1,4 @@ +# CONFIG_SPIRAM_TYPE_AUTO is not set +# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set +CONFIG_SPIRAM_TYPE_ESPPSRAM32=y +# CONFIG_SPIRAM_TYPE_ESPPSRAM64 is not set diff --git a/ports/espressif/esp-idf-config/sdkconfig-psram-80m.defaults b/ports/espressif/esp-idf-config/sdkconfig-psram-80m.defaults new file mode 100644 index 0000000000..7a2e500409 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-psram-80m.defaults @@ -0,0 +1,3 @@ +# CONFIG_SPIRAM_SPEED_120M is not set +CONFIG_SPIRAM_SPEED_80M=y +# CONFIG_SPIRAM_SPEED_40M is not set diff --git a/ports/espressif/esp-idf-config/sdkconfig-psram-8MB.defaults b/ports/espressif/esp-idf-config/sdkconfig-psram-8MB.defaults new file mode 100644 index 0000000000..b842862762 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-psram-8MB.defaults @@ -0,0 +1,4 @@ +# CONFIG_SPIRAM_TYPE_AUTO is not set +# CONFIG_SPIRAM_TYPE_ESPPSRAM16 is not set +# CONFIG_SPIRAM_TYPE_ESPPSRAM32 is not set +CONFIG_SPIRAM_TYPE_ESPPSRAM64=y diff --git a/ports/espressif/esp-idf-config/sdkconfig-psram-opi.defaults b/ports/espressif/esp-idf-config/sdkconfig-psram-opi.defaults new file mode 100644 index 0000000000..05133e84c4 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-psram-opi.defaults @@ -0,0 +1,2 @@ +# CONFIG_SPIRAM_MODE_QUAD is not set +CONFIG_SPIRAM_MODE_OCT=y diff --git a/ports/espressif/esp-idf-config/sdkconfig-psram-qio.defaults b/ports/espressif/esp-idf-config/sdkconfig-psram-qio.defaults new file mode 100644 index 0000000000..ad262b4918 --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-psram-qio.defaults @@ -0,0 +1,2 @@ +CONFIG_SPIRAM_MODE_QUAD=y +# CONFIG_SPIRAM_MODE_OCT is not set diff --git a/ports/espressif/esp-idf-config/sdkconfig-psram.defaults b/ports/espressif/esp-idf-config/sdkconfig-psram.defaults new file mode 100644 index 0000000000..0ac0e6c7bc --- /dev/null +++ b/ports/espressif/esp-idf-config/sdkconfig-psram.defaults @@ -0,0 +1,27 @@ +# +# Espressif IoT Development Framework Configuration +# +# +# Component config +# +# +# ESP PSRAM +# +CONFIG_SPIRAM=y +# +# SPI RAM config +# +CONFIG_SPIRAM_USE_MEMMAP=y +# end of SPI RAM config + +# end of ESP PSRAM + +# +# Wi-Fi +# +CONFIG_ESP_WIFI_CACHE_TX_BUFFER_NUM=16 +# end of Wi-Fi + +# end of Component config + +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-idf-config/sdkconfig.defaults b/ports/espressif/esp-idf-config/sdkconfig.defaults index b183cd630d..74c9019d99 100644 --- a/ports/espressif/esp-idf-config/sdkconfig.defaults +++ b/ports/espressif/esp-idf-config/sdkconfig.defaults @@ -1,877 +1,130 @@ -CONFIG_IDF_CMAKE=y # -# SDK tool configuration +# Espressif IoT Development Framework Configuration # -# CONFIG_SDK_TOOLCHAIN_SUPPORTS_TIME_WIDE_64_BITS is not set -# end of SDK tool configuration - -# -# Build type -# -CONFIG_APP_BUILD_TYPE_APP_2NDBOOT=y -# CONFIG_APP_BUILD_TYPE_ELF_RAM is not set -CONFIG_APP_BUILD_GENERATE_BINARIES=y -CONFIG_APP_BUILD_BOOTLOADER=y -CONFIG_APP_BUILD_USE_FLASH_SECTIONS=y -# end of Build type - -# -# Application manager -# -CONFIG_APP_COMPILE_TIME_DATE=y -# CONFIG_APP_EXCLUDE_PROJECT_VER_VAR is not set -# CONFIG_APP_EXCLUDE_PROJECT_NAME_VAR is not set -# CONFIG_APP_PROJECT_VER_FROM_CONFIG is not set -CONFIG_APP_RETRIEVE_LEN_ELF_SHA=16 -# end of Application manager - -# -# Bootloader config -# -# CONFIG_BOOTLOADER_LOG_LEVEL_NONE is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_ERROR is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_WARN is not set -CONFIG_BOOTLOADER_LOG_LEVEL_INFO=y -# CONFIG_BOOTLOADER_LOG_LEVEL_DEBUG is not set -# CONFIG_BOOTLOADER_LOG_LEVEL_VERBOSE is not set -CONFIG_BOOTLOADER_LOG_LEVEL=3 -# CONFIG_BOOTLOADER_VDDSDIO_BOOST_1_8V is not set -CONFIG_BOOTLOADER_VDDSDIO_BOOST_1_9V=y -# CONFIG_BOOTLOADER_FACTORY_RESET is not set -# CONFIG_BOOTLOADER_APP_TEST is not set -CONFIG_BOOTLOADER_WDT_ENABLE=y -# CONFIG_BOOTLOADER_WDT_DISABLE_IN_USER_CODE is not set -CONFIG_BOOTLOADER_WDT_TIME_MS=9000 -# CONFIG_BOOTLOADER_APP_ROLLBACK_ENABLE is not set -# CONFIG_BOOTLOADER_SKIP_VALIDATE_IN_DEEP_SLEEP is not set -# CONFIG_BOOTLOADER_SKIP_VALIDATE_ON_POWER_ON is not set -# CONFIG_BOOTLOADER_SKIP_VALIDATE_ALWAYS is not set -CONFIG_BOOTLOADER_RESERVE_RTC_SIZE=0 -# CONFIG_BOOTLOADER_CUSTOM_RESERVE_RTC is not set -CONFIG_BOOTLOADER_FLASH_XMC_SUPPORT=y -# end of Bootloader config - -# -# Security features -# -CONFIG_SECURE_BOOT_SUPPORTS_RSA=y -CONFIG_SECURE_TARGET_HAS_SECURE_ROM_DL_MODE=y -# CONFIG_SECURE_SIGNED_APPS_NO_SECURE_BOOT is not set -# CONFIG_SECURE_BOOT is not set -# CONFIG_SECURE_FLASH_ENC_ENABLED is not set -# end of Security features - -# -# Boot ROM Behavior -# -CONFIG_BOOT_ROM_LOG_ALWAYS_ON=y -# CONFIG_BOOT_ROM_LOG_ALWAYS_OFF is not set -# CONFIG_BOOT_ROM_LOG_ON_GPIO_HIGH is not set -# CONFIG_BOOT_ROM_LOG_ON_GPIO_LOW is not set -# end of Boot ROM Behavior - -# -# Serial flasher config -# -CONFIG_ESPTOOLPY_BAUD_OTHER_VAL=115200 -# CONFIG_ESPTOOLPY_NO_STUB is not set -# CONFIG_ESPTOOLPY_OCT_FLASH is not set -# CONFIG_ESPTOOLPY_FLASHMODE_QIO is not set -# CONFIG_ESPTOOLPY_FLASHMODE_QOUT is not set -CONFIG_ESPTOOLPY_FLASHMODE_DIO=y -# CONFIG_ESPTOOLPY_FLASHMODE_DOUT is not set -CONFIG_ESPTOOLPY_FLASH_SAMPLE_MODE_STR=y -CONFIG_ESPTOOLPY_FLASHMODE="dio" -# CONFIG_ESPTOOLPY_FLASHFREQ_120M is not set -# CONFIG_ESPTOOLPY_FLASHFREQ_80M is not set -CONFIG_ESPTOOLPY_FLASHFREQ_40M=y -# CONFIG_ESPTOOLPY_FLASHFREQ_20M is not set -CONFIG_ESPTOOLPY_FLASHFREQ="40m" -CONFIG_ESPTOOLPY_BEFORE_RESET=y -# CONFIG_ESPTOOLPY_BEFORE_NORESET is not set -CONFIG_ESPTOOLPY_BEFORE="default_reset" -CONFIG_ESPTOOLPY_AFTER_RESET=y -# CONFIG_ESPTOOLPY_AFTER_NORESET is not set -CONFIG_ESPTOOLPY_AFTER="hard_reset" -# CONFIG_ESPTOOLPY_MONITOR_BAUD_CONSOLE is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_9600B is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_57600B is not set -CONFIG_ESPTOOLPY_MONITOR_BAUD_115200B=y -# CONFIG_ESPTOOLPY_MONITOR_BAUD_230400B is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_921600B is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_2MB is not set -# CONFIG_ESPTOOLPY_MONITOR_BAUD_OTHER is not set -CONFIG_ESPTOOLPY_MONITOR_BAUD_OTHER_VAL=115200 -CONFIG_ESPTOOLPY_MONITOR_BAUD=115200 -# end of Serial flasher config - # # Partition Table # -# CONFIG_PARTITION_TABLE_SINGLE_APP is not set -# CONFIG_PARTITION_TABLE_SINGLE_APP_LARGE is not set -# CONFIG_PARTITION_TABLE_TWO_OTA is not set CONFIG_PARTITION_TABLE_CUSTOM=y -CONFIG_PARTITION_TABLE_OFFSET=0x8000 -CONFIG_PARTITION_TABLE_MD5=y # end of Partition Table -# -# Compiler options -# -CONFIG_COMPILER_HIDE_PATHS_MACROS=y -# CONFIG_COMPILER_CXX_EXCEPTIONS is not set -# CONFIG_COMPILER_CXX_RTTI is not set -CONFIG_COMPILER_STACK_CHECK_MODE_NONE=y -# CONFIG_COMPILER_STACK_CHECK_MODE_NORM is not set -# CONFIG_COMPILER_STACK_CHECK_MODE_STRONG is not set -# CONFIG_COMPILER_STACK_CHECK_MODE_ALL is not set -# CONFIG_COMPILER_WARN_WRITE_STRINGS is not set -# CONFIG_COMPILER_DISABLE_GCC8_WARNINGS is not set -# CONFIG_COMPILER_DUMP_RTL_FILES is not set -# end of Compiler options - # # Component config # # -# Application Level Tracing +# Driver Configurations # -# CONFIG_APPTRACE_DEST_JTAG is not set -CONFIG_APPTRACE_DEST_NONE=y -CONFIG_APPTRACE_LOCK_ENABLE=y -# end of Application Level Tracing +# +# GPTimer Configuration +# +CONFIG_GPTIMER_SUPPRESS_DEPRECATE_WARN=y +# end of GPTimer Configuration -# CONFIG_BLE_MESH is not set -# -# Driver configurations -# -# -# ADC configuration -# -# CONFIG_ADC_FORCE_XPD_FSM is not set -CONFIG_ADC_DISABLE_DAC=y -# end of ADC configuration - -# -# MCPWM configuration -# -# CONFIG_MCPWM_ISR_IN_IRAM is not set -# end of MCPWM configuration - -# -# SPI configuration -# -# CONFIG_SPI_MASTER_IN_IRAM is not set -CONFIG_SPI_MASTER_ISR_IN_IRAM=y -# CONFIG_SPI_SLAVE_IN_IRAM is not set -CONFIG_SPI_SLAVE_ISR_IN_IRAM=y -# end of SPI configuration - -# -# TWAI configuration -# -# CONFIG_TWAI_ISR_IN_IRAM is not set -# end of TWAI configuration - -# -# UART configuration -# -# CONFIG_UART_ISR_IN_IRAM is not set -# end of UART configuration - -# -# GDMA Configuration -# -# CONFIG_GDMA_CTRL_FUNC_IN_IRAM is not set -# CONFIG_GDMA_ISR_IRAM_SAFE is not set -# end of GDMA Configuration - -# end of Driver configurations - -# -# eFuse Bit Manager -# -# CONFIG_EFUSE_CUSTOM_TABLE is not set -# CONFIG_EFUSE_VIRTUAL is not set -CONFIG_EFUSE_MAX_BLK_LEN=256 -# end of eFuse Bit Manager - -# -# ESP-TLS -# -CONFIG_ESP_TLS_USING_MBEDTLS=y -CONFIG_ESP_TLS_USE_DS_PERIPHERAL=y -CONFIG_ESP_TLS_SERVER=y -# CONFIG_ESP_TLS_CLIENT_SESSION_TICKETS is not set -# CONFIG_ESP_TLS_SERVER_SESSION_TICKETS is not set -# CONFIG_ESP_TLS_PSK_VERIFICATION is not set -# CONFIG_ESP_TLS_INSECURE is not set -# end of ESP-TLS - -# -# Ethernet -# -# CONFIG_ETH_USE_SPI_ETHERNET is not set -# CONFIG_ETH_USE_OPENETH is not set -# end of Ethernet - -# -# Event Loop Library -# -# CONFIG_ESP_EVENT_LOOP_PROFILING is not set -CONFIG_ESP_EVENT_POST_FROM_ISR=y -CONFIG_ESP_EVENT_POST_FROM_IRAM_ISR=y -# end of Event Loop Library - -# -# Hardware Settings -# -# -# MAC Config -# -CONFIG_ESP_MAC_ADDR_UNIVERSE_WIFI_STA=y -CONFIG_ESP_MAC_ADDR_UNIVERSE_WIFI_AP=y -CONFIG_ESP_MAC_ADDR_UNIVERSE_BT=y -CONFIG_ESP_MAC_ADDR_UNIVERSE_ETH=y -# end of MAC Config - -# -# Sleep Config -# -CONFIG_ESP_SLEEP_RTC_BUS_ISO_WORKAROUND=y -# CONFIG_ESP_SLEEP_PSRAM_LEAKAGE_WORKAROUND is not set -# CONFIG_ESP_SLEEP_FLASH_LEAKAGE_WORKAROUND is not set -# end of Sleep Config - -# -# RTC Clock Config -# -CONFIG_RTC_CLOCK_BBPLL_POWER_ON_WITH_USB=y -# end of RTC Clock Config - -# end of Hardware Settings - -# -# IPC (Inter-Processor Call) -# -CONFIG_ESP_IPC_TASK_STACK_SIZE=1536 -CONFIG_ESP_IPC_USES_CALLERS_PRIORITY=y -CONFIG_ESP_IPC_ISR_ENABLE=y -# end of IPC (Inter-Processor Call) - -# -# ESP NETIF Adapter -# -CONFIG_ESP_NETIF_IP_LOST_TIMER_INTERVAL=120 -CONFIG_ESP_NETIF_TCPIP_LWIP=y -# CONFIG_ESP_NETIF_LOOPBACK is not set -# CONFIG_ESP_NETIF_TCPIP_ADAPTER_COMPATIBLE_LAYER is not set -# end of ESP NETIF Adapter +# end of Driver Configurations # # PHY # -CONFIG_ESP_PHY_CALIBRATION_AND_DATA_STORAGE=y -# CONFIG_ESP_PHY_INIT_DATA_IN_PARTITION is not set -CONFIG_ESP_PHY_MAX_WIFI_TX_POWER=20 -CONFIG_ESP_PHY_MAX_TX_POWER=20 +# CONFIG_ESP_PHY_CALIBRATION_AND_DATA_STORAGE is not set # end of PHY -# -# Power Management -# -# CONFIG_PM_ENABLE is not set -CONFIG_PM_POWER_DOWN_CPU_IN_LIGHT_SLEEP=y -CONFIG_PM_POWER_DOWN_TAGMEM_IN_LIGHT_SLEEP=y -# end of Power Management - # # ESP System Settings # -# CONFIG_ESP_SYSTEM_GDBSTUB_RUNTIME is not set -CONFIG_ESP_SYSTEM_RTC_FAST_MEM_AS_HEAP_DEPCHECK=y -CONFIG_ESP_SYSTEM_ALLOW_RTC_FAST_MEM_AS_HEAP=y -CONFIG_ESP_SYSTEM_EVENT_QUEUE_SIZE=32 -CONFIG_ESP_SYSTEM_EVENT_TASK_STACK_SIZE=2304 CONFIG_ESP_MAIN_TASK_STACK_SIZE=16384 -CONFIG_ESP_MINIMAL_SHARED_STACK_SIZE=2048 -CONFIG_ESP_INT_WDT=y -CONFIG_ESP_INT_WDT_TIMEOUT_MS=300 -CONFIG_ESP_INT_WDT_CHECK_CPU1=y -# CONFIG_ESP_TASK_WDT is not set -# CONFIG_ESP_PANIC_HANDLER_IRAM is not set -# CONFIG_ESP_DEBUG_STUBS_ENABLE is not set -CONFIG_ESP_SYSTEM_CHECK_INT_LEVEL_4=y +# CONFIG_ESP_TASK_WDT_INIT is not set +# CONFIG_ESP_DEBUG_OCDAWARE is not set # end of ESP System Settings -# -# High resolution timer (esp_timer) -# -# CONFIG_ESP_TIMER_PROFILING is not set -CONFIG_ESP_TIME_FUNCS_USE_RTC_TIMER=y -CONFIG_ESP_TIME_FUNCS_USE_ESP_TIMER=y -CONFIG_ESP_TIMER_TASK_STACK_SIZE=3584 -CONFIG_ESP_TIMER_INTERRUPT_LEVEL=1 -# CONFIG_ESP_TIMER_SUPPORTS_ISR_DISPATCH_METHOD is not set -CONFIG_ESP_TIMER_IMPL_SYSTIMER=y -# end of High resolution timer (esp_timer) - # # Wi-Fi # -# CONFIG_ESP_WIFI_SLP_IRAM_OPT is not set -# CONFIG_ESP_WIFI_FTM_ENABLE is not set -# CONFIG_ESP_WIFI_STA_DISCONNECTED_PM_ENABLE is not set -# CONFIG_ESP_WIFI_GCMP_SUPPORT is not set -# CONFIG_ESP_WIFI_GMAC_SUPPORT is not set -CONFIG_ESP_WIFI_SOFTAP_SUPPORT=y +CONFIG_ESP_WIFI_DYNAMIC_RX_BUFFER_NUM=8 +CONFIG_ESP_WIFI_STATIC_TX_BUFFER=y +# CONFIG_ESP_WIFI_NVS_ENABLED is not set # end of Wi-Fi -# -# Core dump -# -# CONFIG_ESP_COREDUMP_ENABLE_TO_FLASH is not set -# CONFIG_ESP_COREDUMP_ENABLE_TO_UART is not set -CONFIG_ESP_COREDUMP_ENABLE_TO_NONE=y -# end of Core dump - -# -# FreeRTOS -# -CONFIG_FREERTOS_NO_AFFINITY=0x7FFFFFFF -CONFIG_FREERTOS_TICK_SUPPORT_SYSTIMER=y -CONFIG_FREERTOS_CORETIMER_SYSTIMER_LVL1=y -# CONFIG_FREERTOS_CORETIMER_SYSTIMER_LVL3 is not set -CONFIG_FREERTOS_SYSTICK_USES_SYSTIMER=y -CONFIG_FREERTOS_HZ=100 -# CONFIG_FREERTOS_CHECK_STACKOVERFLOW_NONE is not set -# CONFIG_FREERTOS_CHECK_STACKOVERFLOW_PTRVAL is not set -CONFIG_FREERTOS_CHECK_STACKOVERFLOW_CANARY=y -# CONFIG_FREERTOS_WATCHPOINT_END_OF_STACK is not set -CONFIG_FREERTOS_INTERRUPT_BACKTRACE=y -CONFIG_FREERTOS_THREAD_LOCAL_STORAGE_POINTERS=1 -CONFIG_FREERTOS_IDLE_TASK_STACKSIZE=1536 -CONFIG_FREERTOS_ISR_STACKSIZE=1536 -# CONFIG_FREERTOS_LEGACY_HOOKS is not set -CONFIG_FREERTOS_MAX_TASK_NAME_LEN=16 -CONFIG_FREERTOS_SUPPORT_STATIC_ALLOCATION=y -# CONFIG_FREERTOS_ENABLE_STATIC_TASK_CLEAN_UP is not set -CONFIG_FREERTOS_TIMER_TASK_PRIORITY=1 -CONFIG_FREERTOS_TIMER_TASK_STACK_DEPTH=2048 -CONFIG_FREERTOS_TIMER_QUEUE_LENGTH=10 -CONFIG_FREERTOS_QUEUE_REGISTRY_SIZE=0 -# CONFIG_FREERTOS_USE_TRACE_FACILITY is not set -# CONFIG_FREERTOS_GENERATE_RUN_TIME_STATS is not set -CONFIG_FREERTOS_CHECK_MUTEX_GIVEN_BY_OWNER=y -# CONFIG_FREERTOS_CHECK_PORT_CRITICAL_COMPLIANCE is not set -# CONFIG_FREERTOS_PLACE_FUNCTIONS_INTO_FLASH is not set -CONFIG_FREERTOS_ENABLE_TASK_SNAPSHOT=y -# CONFIG_FREERTOS_PLACE_SNAPSHOT_FUNS_INTO_FLASH is not set -# end of FreeRTOS - -# -# Heap memory debugging -# -CONFIG_HEAP_POISONING_DISABLED=y -# CONFIG_HEAP_POISONING_LIGHT is not set -# CONFIG_HEAP_POISONING_COMPREHENSIVE is not set -CONFIG_HEAP_TRACING_OFF=y -# CONFIG_HEAP_TRACING_STANDALONE is not set -# CONFIG_HEAP_TRACING_TOHOST is not set -# CONFIG_HEAP_ABORT_WHEN_ALLOCATION_FAILS is not set -# end of Heap memory debugging - -# -# Log output -# -# CONFIG_LOG_DEFAULT_LEVEL_NONE is not set -# CONFIG_LOG_DEFAULT_LEVEL_ERROR is not set -# CONFIG_LOG_DEFAULT_LEVEL_WARN is not set -CONFIG_LOG_DEFAULT_LEVEL_INFO=y -# CONFIG_LOG_DEFAULT_LEVEL_DEBUG is not set -# CONFIG_LOG_DEFAULT_LEVEL_VERBOSE is not set -CONFIG_LOG_DEFAULT_LEVEL=3 -CONFIG_LOG_MAXIMUM_EQUALS_DEFAULT=y -# CONFIG_LOG_MAXIMUM_LEVEL_DEBUG is not set -# CONFIG_LOG_MAXIMUM_LEVEL_VERBOSE is not set -CONFIG_LOG_MAXIMUM_LEVEL=3 -CONFIG_LOG_COLORS=y -CONFIG_LOG_TIMESTAMP_SOURCE_RTOS=y -# CONFIG_LOG_TIMESTAMP_SOURCE_SYSTEM is not set -# end of Log output - # # LWIP # -# CONFIG_LWIP_NETIF_API is not set -# CONFIG_LWIP_TCPIP_CORE_LOCKING is not set -CONFIG_LWIP_DNS_SUPPORT_MDNS_QUERIES=y -# CONFIG_LWIP_L2_TO_L3_COPY is not set -# CONFIG_LWIP_IRAM_OPTIMIZATION is not set -CONFIG_LWIP_TIMERS_ONDEMAND=y CONFIG_LWIP_MAX_SOCKETS=8 -# CONFIG_LWIP_USE_ONLY_LWIP_SELECT is not set -# CONFIG_LWIP_SO_LINGER is not set -CONFIG_LWIP_SO_REUSE=y -CONFIG_LWIP_SO_REUSE_RXTOALL=y CONFIG_LWIP_SO_RCVBUF=y -# CONFIG_LWIP_NETBUF_RECVINFO is not set -CONFIG_LWIP_IP4_FRAG=y -CONFIG_LWIP_IP6_FRAG=y -# CONFIG_LWIP_IP4_REASSEMBLY is not set -# CONFIG_LWIP_IP6_REASSEMBLY is not set -# CONFIG_LWIP_IP_FORWARD is not set -# CONFIG_LWIP_STATS is not set -# CONFIG_LWIP_ETHARP_TRUST_IP_MAC is not set -CONFIG_LWIP_ESP_GRATUITOUS_ARP=y -CONFIG_LWIP_GARP_TMR_INTERVAL=60 -CONFIG_LWIP_TCPIP_RECVMBOX_SIZE=32 -CONFIG_LWIP_DHCP_DOES_ARP_CHECK=y -# CONFIG_LWIP_DHCP_DISABLE_CLIENT_ID is not set -CONFIG_LWIP_DHCP_DISABLE_VENDOR_CLASS_ID=y -# CONFIG_LWIP_DHCP_RESTORE_LAST_IP is not set -CONFIG_LWIP_DHCP_OPTIONS_LEN=68 -# -# DHCP server -# -CONFIG_LWIP_DHCPS=y -CONFIG_LWIP_DHCPS_LEASE_UNIT=60 -CONFIG_LWIP_DHCPS_MAX_STATION_NUM=8 -# end of DHCP server - -# CONFIG_LWIP_AUTOIP is not set -CONFIG_LWIP_IPV6=y -# CONFIG_LWIP_IPV6_AUTOCONFIG is not set -CONFIG_LWIP_IPV6_NUM_ADDRESSES=3 -# CONFIG_LWIP_IPV6_FORWARD is not set -# CONFIG_LWIP_NETIF_STATUS_CALLBACK is not set -CONFIG_LWIP_NETIF_LOOPBACK=y -CONFIG_LWIP_LOOPBACK_MAX_PBUFS=8 # # TCP # CONFIG_LWIP_MAX_ACTIVE_TCP=4 CONFIG_LWIP_MAX_LISTENING_TCP=4 -CONFIG_LWIP_TCP_HIGH_SPEED_RETRANSMISSION=y -CONFIG_LWIP_TCP_MAXRTX=12 CONFIG_LWIP_TCP_SYNMAXRTX=6 -CONFIG_LWIP_TCP_MSS=1440 -CONFIG_LWIP_TCP_TMR_INTERVAL=250 -CONFIG_LWIP_TCP_MSL=60000 CONFIG_LWIP_TCP_SND_BUF_DEFAULT=2880 CONFIG_LWIP_TCP_WND_DEFAULT=2880 -CONFIG_LWIP_TCP_RECVMBOX_SIZE=6 -CONFIG_LWIP_TCP_QUEUE_OOSEQ=y -# CONFIG_LWIP_TCP_SACK_OUT is not set -# CONFIG_LWIP_TCP_KEEP_CONNECTION_WHEN_IP_CHANGES is not set -CONFIG_LWIP_TCP_OVERSIZE_MSS=y -# CONFIG_LWIP_TCP_OVERSIZE_QUARTER_MSS is not set -# CONFIG_LWIP_TCP_OVERSIZE_DISABLE is not set CONFIG_LWIP_TCP_RTO_TIME=3000 # end of TCP -# -# UDP -# -CONFIG_LWIP_MAX_UDP_PCBS=16 -CONFIG_LWIP_UDP_RECVMBOX_SIZE=6 -# end of UDP - -# -# Checksums -# -# CONFIG_LWIP_CHECKSUM_CHECK_IP is not set -# CONFIG_LWIP_CHECKSUM_CHECK_UDP is not set -CONFIG_LWIP_CHECKSUM_CHECK_ICMP=y -# end of Checksums - -CONFIG_LWIP_TCPIP_TASK_STACK_SIZE=3072 -CONFIG_LWIP_TCPIP_TASK_AFFINITY_NO_AFFINITY=y -# CONFIG_LWIP_TCPIP_TASK_AFFINITY_CPU0 is not set -# CONFIG_LWIP_TCPIP_TASK_AFFINITY_CPU1 is not set -CONFIG_LWIP_TCPIP_TASK_AFFINITY=0x7FFFFFFF -# CONFIG_LWIP_PPP_SUPPORT is not set -CONFIG_LWIP_IPV6_MEMP_NUM_ND6_QUEUE=3 -CONFIG_LWIP_IPV6_ND6_NUM_NEIGHBORS=5 -# CONFIG_LWIP_SLIP_SUPPORT is not set -# -# ICMP -# -CONFIG_LWIP_ICMP=y -# CONFIG_LWIP_MULTICAST_PING is not set -# CONFIG_LWIP_BROADCAST_PING is not set -# end of ICMP - -# -# LWIP RAW API -# -CONFIG_LWIP_MAX_RAW_PCBS=16 -# end of LWIP RAW API - -# -# SNTP -# -CONFIG_LWIP_SNTP_MAX_SERVERS=1 -# CONFIG_LWIP_DHCP_GET_NTP_SRV is not set -CONFIG_LWIP_SNTP_UPDATE_DELAY=3600000 -# end of SNTP - -# -# Hooks -# -# CONFIG_LWIP_HOOK_TCP_ISN_NONE is not set -CONFIG_LWIP_HOOK_TCP_ISN_DEFAULT=y -# CONFIG_LWIP_HOOK_TCP_ISN_CUSTOM is not set -CONFIG_LWIP_HOOK_IP6_ROUTE_NONE=y -# CONFIG_LWIP_HOOK_IP6_ROUTE_DEFAULT is not set -# CONFIG_LWIP_HOOK_IP6_ROUTE_CUSTOM is not set -CONFIG_LWIP_HOOK_ND6_GET_GW_NONE=y -# CONFIG_LWIP_HOOK_ND6_GET_GW_DEFAULT is not set -# CONFIG_LWIP_HOOK_ND6_GET_GW_CUSTOM is not set -CONFIG_LWIP_HOOK_NETCONN_EXT_RESOLVE_NONE=y -# CONFIG_LWIP_HOOK_NETCONN_EXT_RESOLVE_DEFAULT is not set -# CONFIG_LWIP_HOOK_NETCONN_EXT_RESOLVE_CUSTOM is not set -# end of Hooks - -# CONFIG_LWIP_DEBUG is not set # end of LWIP # # mbedTLS # -CONFIG_MBEDTLS_INTERNAL_MEM_ALLOC=y -# CONFIG_MBEDTLS_DEFAULT_MEM_ALLOC is not set -# CONFIG_MBEDTLS_CUSTOM_MEM_ALLOC is not set -CONFIG_MBEDTLS_ASYMMETRIC_CONTENT_LEN=y -CONFIG_MBEDTLS_SSL_IN_CONTENT_LEN=16384 CONFIG_MBEDTLS_SSL_OUT_CONTENT_LEN=2048 -# CONFIG_MBEDTLS_DEBUG is not set # -# mbedTLS v2.28.x related +# mbedTLS v3.x related # -# CONFIG_MBEDTLS_SSL_VARIABLE_BUFFER_LENGTH is not set -CONFIG_MBEDTLS_ECDH_LEGACY_CONTEXT=y -# CONFIG_MBEDTLS_X509_TRUSTED_CERT_CALLBACK is not set -# CONFIG_MBEDTLS_SSL_CONTEXT_SERIALIZATION is not set -CONFIG_MBEDTLS_SSL_KEEP_PEER_CERTIFICATE=y -# -# DTLS-based configurations -# -# CONFIG_MBEDTLS_SSL_DTLS_CONNECTION_ID is not set -# CONFIG_MBEDTLS_SSL_DTLS_SRTP is not set -# end of DTLS-based configurations - -# end of mbedTLS v2.28.x related +# CONFIG_MBEDTLS_SSL_KEEP_PEER_CERTIFICATE is not set +# end of mbedTLS v3.x related # # Certificate Bundle # -CONFIG_MBEDTLS_CERTIFICATE_BUNDLE=y -# CONFIG_MBEDTLS_CERTIFICATE_BUNDLE_DEFAULT_FULL is not set -# CONFIG_MBEDTLS_CERTIFICATE_BUNDLE_DEFAULT_CMN is not set CONFIG_MBEDTLS_CERTIFICATE_BUNDLE_DEFAULT_NONE=y CONFIG_MBEDTLS_CUSTOM_CERTIFICATE_BUNDLE=y -CONFIG_MBEDTLS_CUSTOM_CERTIFICATE_BUNDLE_PATH="../../lib/certificates/nina-fw/data/roots.pem" +CONFIG_MBEDTLS_CUSTOM_CERTIFICATE_BUNDLE_PATH="../../lib/certificates/data/roots.pem" # end of Certificate Bundle -CONFIG_MBEDTLS_ECP_RESTARTABLE=y -CONFIG_MBEDTLS_CMAC_C=y -CONFIG_MBEDTLS_HARDWARE_AES=y -CONFIG_MBEDTLS_AES_USE_INTERRUPT=y -CONFIG_MBEDTLS_HARDWARE_MPI=y -CONFIG_MBEDTLS_HARDWARE_SHA=y -CONFIG_MBEDTLS_ROM_MD5=y -# CONFIG_MBEDTLS_ATCA_HW_ECDSA_SIGN is not set -# CONFIG_MBEDTLS_ATCA_HW_ECDSA_VERIFY is not set -CONFIG_MBEDTLS_HAVE_TIME=y -# CONFIG_MBEDTLS_HAVE_TIME_DATE is not set -CONFIG_MBEDTLS_ECDSA_DETERMINISTIC=y -CONFIG_MBEDTLS_SHA512_C=y -CONFIG_MBEDTLS_TLS_SERVER_AND_CLIENT=y -# CONFIG_MBEDTLS_TLS_SERVER_ONLY is not set -# CONFIG_MBEDTLS_TLS_CLIENT_ONLY is not set -# CONFIG_MBEDTLS_TLS_DISABLED is not set -CONFIG_MBEDTLS_TLS_SERVER=y -CONFIG_MBEDTLS_TLS_CLIENT=y -CONFIG_MBEDTLS_TLS_ENABLED=y # # TLS Key Exchange Methods # -CONFIG_MBEDTLS_PSK_MODES=y -CONFIG_MBEDTLS_KEY_EXCHANGE_PSK=y -CONFIG_MBEDTLS_KEY_EXCHANGE_DHE_PSK=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ECDHE_PSK=y -CONFIG_MBEDTLS_KEY_EXCHANGE_RSA_PSK=y -CONFIG_MBEDTLS_KEY_EXCHANGE_RSA=y -CONFIG_MBEDTLS_KEY_EXCHANGE_DHE_RSA=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ELLIPTIC_CURVE=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ECDHE_RSA=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA=y -CONFIG_MBEDTLS_KEY_EXCHANGE_ECDH_RSA=y +# CONFIG_MBEDTLS_KEY_EXCHANGE_RSA is not set # end of TLS Key Exchange Methods -CONFIG_MBEDTLS_SSL_RENEGOTIATION=y -# CONFIG_MBEDTLS_SSL_PROTO_SSL3 is not set -# CONFIG_MBEDTLS_SSL_PROTO_TLS1 is not set -# CONFIG_MBEDTLS_SSL_PROTO_TLS1_1 is not set -CONFIG_MBEDTLS_SSL_PROTO_TLS1_2=y -# CONFIG_MBEDTLS_SSL_PROTO_GMTSSL1_1 is not set CONFIG_MBEDTLS_SSL_PROTO_DTLS=y -CONFIG_MBEDTLS_SSL_ALPN=y -CONFIG_MBEDTLS_CLIENT_SSL_SESSION_TICKETS=y -CONFIG_MBEDTLS_X509_CHECK_KEY_USAGE=y -CONFIG_MBEDTLS_X509_CHECK_EXTENDED_KEY_USAGE=y -CONFIG_MBEDTLS_SERVER_SSL_SESSION_TICKETS=y -# -# Symmetric Ciphers -# -CONFIG_MBEDTLS_AES_C=y -# CONFIG_MBEDTLS_CAMELLIA_C is not set -# CONFIG_MBEDTLS_DES_C is not set -CONFIG_MBEDTLS_RC4_DISABLED=y -# CONFIG_MBEDTLS_RC4_ENABLED_NO_DEFAULT is not set -# CONFIG_MBEDTLS_RC4_ENABLED is not set -# CONFIG_MBEDTLS_BLOWFISH_C is not set -# CONFIG_MBEDTLS_XTEA_C is not set -CONFIG_MBEDTLS_CCM_C=y -CONFIG_MBEDTLS_GCM_C=y -# CONFIG_MBEDTLS_NIST_KW_C is not set -# end of Symmetric Ciphers - -# CONFIG_MBEDTLS_RIPEMD160_C is not set # # Certificates # -CONFIG_MBEDTLS_PEM_PARSE_C=y -CONFIG_MBEDTLS_PEM_WRITE_C=y -CONFIG_MBEDTLS_X509_CRL_PARSE_C=y -CONFIG_MBEDTLS_X509_CSR_PARSE_C=y +# CONFIG_MBEDTLS_PEM_WRITE_C is not set # end of Certificates -CONFIG_MBEDTLS_ECP_C=y -CONFIG_MBEDTLS_ECDH_C=y -CONFIG_MBEDTLS_ECDSA_C=y -# CONFIG_MBEDTLS_ECJPAKE_C is not set -CONFIG_MBEDTLS_ECP_DP_SECP192R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP224R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP256R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP384R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP521R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP192K1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP224K1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_SECP256K1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_BP256R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_BP384R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_BP512R1_ENABLED=y -CONFIG_MBEDTLS_ECP_DP_CURVE25519_ENABLED=y -CONFIG_MBEDTLS_ECP_NIST_OPTIM=y -# CONFIG_MBEDTLS_POLY1305_C is not set -# CONFIG_MBEDTLS_CHACHA20_C is not set -# CONFIG_MBEDTLS_HKDF_C is not set -# CONFIG_MBEDTLS_THREADING_C is not set -# CONFIG_MBEDTLS_LARGE_KEY_SOFTWARE_MPI is not set -# CONFIG_MBEDTLS_SECURITY_RISKS is not set +# CONFIG_MBEDTLS_ECP_DP_SECP192R1_ENABLED is not set +# CONFIG_MBEDTLS_ECP_DP_SECP224R1_ENABLED is not set +# CONFIG_MBEDTLS_ECP_DP_SECP521R1_ENABLED is not set +# CONFIG_MBEDTLS_ECP_DP_SECP192K1_ENABLED is not set +# CONFIG_MBEDTLS_ECP_DP_SECP224K1_ENABLED is not set +# CONFIG_MBEDTLS_ECP_DP_BP256R1_ENABLED is not set +# CONFIG_MBEDTLS_ECP_DP_BP384R1_ENABLED is not set +# CONFIG_MBEDTLS_ECP_DP_BP512R1_ENABLED is not set +# CONFIG_MBEDTLS_ECP_NIST_OPTIM is not set # end of mbedTLS -# -# mDNS -# -CONFIG_MDNS_MAX_SERVICES=10 -CONFIG_MDNS_TASK_PRIORITY=1 -CONFIG_MDNS_TASK_STACK_SIZE=4096 -# CONFIG_MDNS_TASK_AFFINITY_NO_AFFINITY is not set -CONFIG_MDNS_TASK_AFFINITY_CPU0=y -# CONFIG_MDNS_TASK_AFFINITY_CPU1 is not set -CONFIG_MDNS_TASK_AFFINITY=0x0 -CONFIG_MDNS_SERVICE_ADD_TIMEOUT_MS=2000 -# CONFIG_MDNS_STRICT_MODE is not set -CONFIG_MDNS_TIMER_PERIOD_MS=100 -# CONFIG_MDNS_NETWORKING_SOCKET is not set -CONFIG_MDNS_MULTIPLE_INSTANCE=y -# end of mDNS - -# -# Newlib -# -CONFIG_NEWLIB_STDOUT_LINE_ENDING_CRLF=y -# CONFIG_NEWLIB_STDOUT_LINE_ENDING_LF is not set -# CONFIG_NEWLIB_STDOUT_LINE_ENDING_CR is not set -# CONFIG_NEWLIB_STDIN_LINE_ENDING_CRLF is not set -# CONFIG_NEWLIB_STDIN_LINE_ENDING_LF is not set -CONFIG_NEWLIB_STDIN_LINE_ENDING_CR=y -# CONFIG_NEWLIB_NANO_FORMAT is not set -# end of Newlib - -# -# OpenThread -# -# CONFIG_OPENTHREAD_ENABLED is not set -# end of OpenThread - -# -# PThreads -# -CONFIG_PTHREAD_TASK_PRIO_DEFAULT=5 -CONFIG_PTHREAD_TASK_STACK_SIZE_DEFAULT=3072 -CONFIG_PTHREAD_STACK_MIN=768 -CONFIG_PTHREAD_DEFAULT_CORE_NO_AFFINITY=y -# CONFIG_PTHREAD_DEFAULT_CORE_0 is not set -# CONFIG_PTHREAD_DEFAULT_CORE_1 is not set -CONFIG_PTHREAD_TASK_CORE_DEFAULT=-1 -CONFIG_PTHREAD_TASK_NAME_DEFAULT="pthread" -# end of PThreads - # # SPI Flash driver # -# CONFIG_SPI_FLASH_VERIFY_WRITE is not set -# CONFIG_SPI_FLASH_ENABLE_COUNTERS is not set -CONFIG_SPI_FLASH_ROM_DRIVER_PATCH=y -# CONFIG_SPI_FLASH_ROM_IMPL is not set -CONFIG_SPI_FLASH_DANGEROUS_WRITE_ABORTS=y -# CONFIG_SPI_FLASH_DANGEROUS_WRITE_FAILS is not set -# CONFIG_SPI_FLASH_DANGEROUS_WRITE_ALLOWED is not set -# CONFIG_SPI_FLASH_USE_LEGACY_IMPL is not set -# CONFIG_SPI_FLASH_SHARE_SPI1_BUS is not set -# CONFIG_SPI_FLASH_BYPASS_BLOCK_ERASE is not set # CONFIG_SPI_FLASH_YIELD_DURING_ERASE is not set CONFIG_SPI_FLASH_WRITE_CHUNK_SIZE=4096 -# CONFIG_SPI_FLASH_SIZE_OVERRIDE is not set -# CONFIG_SPI_FLASH_CHECK_ERASE_TIMEOUT_DISABLED is not set -# CONFIG_SPI_FLASH_OVERRIDE_CHIP_DRIVER_LIST is not set -# -# Auto-detect flash chips -# -CONFIG_SPI_FLASH_SUPPORT_ISSI_CHIP=y -CONFIG_SPI_FLASH_SUPPORT_MXIC_CHIP=y -CONFIG_SPI_FLASH_SUPPORT_GD_CHIP=y -CONFIG_SPI_FLASH_SUPPORT_WINBOND_CHIP=y -CONFIG_SPI_FLASH_SUPPORT_BOYA_CHIP=y -CONFIG_SPI_FLASH_SUPPORT_TH_CHIP=y -CONFIG_SPI_FLASH_SUPPORT_MXIC_OPI_CHIP=y -# end of Auto-detect flash chips - -CONFIG_SPI_FLASH_ENABLE_ENCRYPTED_READ_WRITE=y # end of SPI Flash driver # -# Virtual file system +# Camera configuration # -CONFIG_VFS_SUPPORT_IO=y -CONFIG_VFS_SUPPORT_DIR=y -CONFIG_VFS_SUPPORT_SELECT=y -CONFIG_VFS_SUPPRESS_SELECT_DEBUG_OUTPUT=y -CONFIG_VFS_SUPPORT_TERMIOS=y -# -# Host File System I/O (Semihosting) -# -CONFIG_VFS_SEMIHOSTFS_MAX_MOUNT_POINTS=1 -CONFIG_VFS_SEMIHOSTFS_HOST_PATH_MAX_LEN=128 -# end of Host File System I/O (Semihosting) - -# end of Virtual file system - -# -# Supplicant -# -CONFIG_WPA_MBEDTLS_CRYPTO=y -# CONFIG_WPA_WAPI_PSK is not set -# CONFIG_WPA_SUITE_B_192 is not set -# CONFIG_WPA_DEBUG_PRINT is not set -# CONFIG_WPA_TESTING_OPTIONS is not set -# CONFIG_WPA_WPS_STRICT is not set -# CONFIG_WPA_11KV_SUPPORT is not set -# end of Supplicant +# CONFIG_OV7670_SUPPORT is not set +# CONFIG_NT99141_SUPPORT is not set +# CONFIG_OV2640_SUPPORT is not set +# CONFIG_GC2145_SUPPORT is not set +# CONFIG_GC032A_SUPPORT is not set +# CONFIG_GC0308_SUPPORT is not set +# CONFIG_BF3005_SUPPORT is not set +# CONFIG_BF20A6_SUPPORT is not set +# CONFIG_SC030IOT_SUPPORT is not set +# end of Camera configuration # end of Component config -# -# Compatibility options -# -# CONFIG_LEGACY_INCLUDE_COMMON_HEADERS is not set -# end of Compatibility options - -# -# Deprecated options for backward compatibility -# -# CONFIG_LOG_BOOTLOADER_LEVEL_NONE is not set -# CONFIG_LOG_BOOTLOADER_LEVEL_ERROR is not set -# CONFIG_LOG_BOOTLOADER_LEVEL_WARN is not set -CONFIG_LOG_BOOTLOADER_LEVEL_INFO=y -# CONFIG_LOG_BOOTLOADER_LEVEL_DEBUG is not set -# CONFIG_LOG_BOOTLOADER_LEVEL_VERBOSE is not set -CONFIG_LOG_BOOTLOADER_LEVEL=3 -# CONFIG_APP_ROLLBACK_ENABLE is not set -# CONFIG_FLASH_ENCRYPTION_ENABLED is not set -CONFIG_FLASHMODE_QIO=y -# CONFIG_FLASHMODE_QOUT is not set -# CONFIG_FLASHMODE_DIO is not set -# CONFIG_FLASHMODE_DOUT is not set -# CONFIG_MONITOR_BAUD_9600B is not set -# CONFIG_MONITOR_BAUD_57600B is not set -CONFIG_MONITOR_BAUD_115200B=y -# CONFIG_MONITOR_BAUD_230400B is not set -# CONFIG_MONITOR_BAUD_921600B is not set -# CONFIG_MONITOR_BAUD_2MB is not set -# CONFIG_MONITOR_BAUD_OTHER is not set -CONFIG_MONITOR_BAUD_OTHER_VAL=115200 -CONFIG_MONITOR_BAUD=115200 -# CONFIG_CXX_EXCEPTIONS is not set -CONFIG_STACK_CHECK_NONE=y -# CONFIG_STACK_CHECK_NORM is not set -# CONFIG_STACK_CHECK_STRONG is not set -# CONFIG_STACK_CHECK_ALL is not set -# CONFIG_WARN_WRITE_STRINGS is not set -# CONFIG_DISABLE_GCC8_WARNINGS is not set -CONFIG_ADC2_DISABLE_DAC=y -# CONFIG_EVENT_LOOP_PROFILING is not set -CONFIG_POST_EVENTS_FROM_ISR=y -CONFIG_POST_EVENTS_FROM_IRAM_ISR=y -CONFIG_IPC_TASK_STACK_SIZE=1536 -CONFIG_ESP_SYSTEM_PM_POWER_DOWN_CPU=y -CONFIG_SYSTEM_EVENT_QUEUE_SIZE=32 -CONFIG_SYSTEM_EVENT_TASK_STACK_SIZE=2304 -CONFIG_MAIN_TASK_STACK_SIZE=8192 -CONFIG_INT_WDT=y -CONFIG_INT_WDT_TIMEOUT_MS=300 -CONFIG_INT_WDT_CHECK_CPU1=y -# CONFIG_TASK_WDT is not set -CONFIG_TIMER_TASK_STACK_SIZE=3584 -# CONFIG_ENABLE_STATIC_TASK_CLEAN_UP_HOOK is not set -CONFIG_TIMER_TASK_PRIORITY=1 -CONFIG_TIMER_TASK_STACK_DEPTH=2048 -CONFIG_TIMER_QUEUE_LENGTH=10 -# CONFIG_L2_TO_L3_COPY is not set -# CONFIG_USE_ONLY_LWIP_SELECT is not set -CONFIG_ESP_GRATUITOUS_ARP=y -CONFIG_GARP_TMR_INTERVAL=60 -CONFIG_TCPIP_RECVMBOX_SIZE=32 -CONFIG_TCP_MAXRTX=12 -CONFIG_TCP_SYNMAXRTX=6 -CONFIG_TCP_MSS=1440 -CONFIG_TCP_MSL=60000 -CONFIG_TCP_SND_BUF_DEFAULT=2880 -CONFIG_TCP_WND_DEFAULT=2880 -CONFIG_TCP_RECVMBOX_SIZE=6 -CONFIG_TCP_QUEUE_OOSEQ=y -# CONFIG_ESP_TCP_KEEP_CONNECTION_WHEN_IP_CHANGES is not set -CONFIG_TCP_OVERSIZE_MSS=y -# CONFIG_TCP_OVERSIZE_QUARTER_MSS is not set -# CONFIG_TCP_OVERSIZE_DISABLE is not set -CONFIG_UDP_RECVMBOX_SIZE=6 -CONFIG_TCPIP_TASK_STACK_SIZE=3072 -CONFIG_TCPIP_TASK_AFFINITY_NO_AFFINITY=y -# CONFIG_TCPIP_TASK_AFFINITY_CPU0 is not set -# CONFIG_TCPIP_TASK_AFFINITY_CPU1 is not set -CONFIG_TCPIP_TASK_AFFINITY=0x7FFFFFFF -# CONFIG_PPP_SUPPORT is not set -CONFIG_SPI_FLASH_WRITING_DANGEROUS_REGIONS_ABORTS=y -# CONFIG_SPI_FLASH_WRITING_DANGEROUS_REGIONS_FAILS is not set -# CONFIG_SPI_FLASH_WRITING_DANGEROUS_REGIONS_ALLOWED is not set -CONFIG_SUPPRESS_SELECT_DEBUG_OUTPUT=y -CONFIG_SUPPORT_TERMIOS=y -CONFIG_SEMIHOSTFS_MAX_MOUNT_POINTS=1 -CONFIG_SEMIHOSTFS_HOST_PATH_MAX_LEN=128 -# end of Deprecated options for backward compatibility +CONFIG_IDF_EXPERIMENTAL_FEATURES=y +# end of Espressif IoT Development Framework Configuration diff --git a/ports/espressif/esp-protocols b/ports/espressif/esp-protocols new file mode 160000 index 0000000000..457f8335bb --- /dev/null +++ b/ports/espressif/esp-protocols @@ -0,0 +1 @@ +Subproject commit 457f8335bb876b8af80a65b096e5381f49f29878 diff --git a/ports/espressif/esp32-camera b/ports/espressif/esp32-camera deleted file mode 160000 index 2758089a06..0000000000 --- a/ports/espressif/esp32-camera +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 2758089a06ccae79d8fcab6c93e2ca3761646f9f diff --git a/ports/espressif/i2s_lcd_driver.h b/ports/espressif/i2s_lcd_driver.h deleted file mode 100644 index 27c4e66b06..0000000000 --- a/ports/espressif/i2s_lcd_driver.h +++ /dev/null @@ -1,135 +0,0 @@ -/* *INDENT-OFF* */ -// Copyright 2015-2016 Espressif Systems (Shanghai) PTE LTD -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at - -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -#ifndef __I2S_LCD_DRIVER_H__ -#define __I2S_LCD_DRIVER_H__ - -#include "driver/i2s.h" - -#ifdef __cplusplus -extern "C" -{ -#endif - -#define LCD_CMD_LEV (0) -#define LCD_DATA_LEV (1) - -typedef void *i2s_lcd_handle_t; /** Handle of i2s lcd driver */ - -/** - * @brief Configuration of i2s lcd mode - * - */ -typedef struct { - int8_t data_width; /*!< Parallel data width, 16bit or 8bit available */ - int8_t pin_data_num[16]; /*!< Parallel data output IO*/ - int8_t pin_num_cs; /*!< CS io num */ - int8_t pin_num_wr; /*!< Write clk io*/ - int8_t pin_num_rs; /*!< RS io num */ - int clk_freq; /*!< I2s clock frequency */ - i2s_port_t i2s_port; /*!< I2S port number */ - bool swap_data; /*!< Swap the 2 bytes of RGB565 color */ - uint32_t buffer_size; /*!< DMA buffer size */ -} i2s_lcd_config_t; - -/** - * @brief Initialize i2s lcd driver. - * - * @param config configuration of i2s - * - * @return A handle to the created i2s lcd driver, or NULL in case of error. - */ -i2s_lcd_handle_t i2s_lcd_driver_init(const i2s_lcd_config_t *config); - -/** - * @brief Deinit i2s lcd driver. - * - * @param handle i2s lcd driver handle to deinitilize - * - * @return - * - ESP_OK on success - * - ESP_ERR_INVALID_ARG handle is invalid - */ -esp_err_t i2s_lcd_driver_deinit(i2s_lcd_handle_t handle); - -/** - * @brief Write a data to LCD - * - * @param handle i2s lcd driver handle - * @param data Data to write - * - * @return - * - ESP_OK on success - * - ESP_ERR_INVALID_ARG handle is invalid - */ -esp_err_t i2s_lcd_write_data(i2s_lcd_handle_t handle, uint16_t data); - -/** - * @brief Write a command to LCD - * - * @param handle Handle of i2s lcd driver - * @param cmd command to write - * - * @return - * - ESP_OK on success - * - ESP_ERR_INVALID_ARG handle is invalid - */ -esp_err_t i2s_lcd_write_cmd(i2s_lcd_handle_t handle, uint16_t cmd); - -/** - * @brief Write block data to LCD - * - * @param handle Handle of i2s lcd driver - * @param data Pointer of data - * @param length length of data - * - * @return - * - ESP_OK on success - * - ESP_ERR_INVALID_ARG handle is invalid - */ -esp_err_t i2s_lcd_write(i2s_lcd_handle_t handle, const uint8_t *data, uint32_t length); - -/** - * @brief acquire a lock - * - * @param handle Handle of i2s lcd driver - * - * @return Always return ESP_OK - */ -esp_err_t i2s_lcd_acquire(i2s_lcd_handle_t handle); - -/** - * @brief acquire a lock, but only wait a certain period of time - * - * @param handle Handle of i2s lcd driver - * - * @return true if the lock was acquired, false otherwise - */ -bool i2s_lcd_acquire_nonblocking(i2s_lcd_handle_t handle, TickType_t ticks_to_wait); - -/** - * @brief release a lock - * - * @param handle Handle of i2s lcd driver - * - * @return Always return ESP_OK - */ -esp_err_t i2s_lcd_release(i2s_lcd_handle_t handle); - - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/ports/espressif/i2s_lcd_esp32s2_driver.c b/ports/espressif/i2s_lcd_esp32s2_driver.c deleted file mode 100644 index 1bf8cd00f3..0000000000 --- a/ports/espressif/i2s_lcd_esp32s2_driver.c +++ /dev/null @@ -1,489 +0,0 @@ -/* *INDENT-OFF* */ -// Copyright 2015-2020 Espressif Systems (Shanghai) PTE LTD -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at - -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#include "sdkconfig.h" -#if CONFIG_IDF_TARGET_ESP32S2 - -#include -#include -#include "freertos/FreeRTOS.h" -#include "freertos/task.h" -#include "freertos/semphr.h" -#include "esp_log.h" -#include "driver/gpio.h" -#include "driver/i2s.h" -#include "esp_heap_caps.h" -#include "esp32s2/rom/lldesc.h" -#include "soc/system_reg.h" -#include "i2s_lcd_driver.h" - - -static const char *TAG = "ESP32S2_I2S_LCD"; - -#define I2S_CHECK(a, str, ret) if (!(a)) { \ - ESP_LOGE(TAG, "%s:%d (%s):%s", __FILE__, __LINE__, __FUNCTION__, str); \ - return ret; \ -} - -#define LCD_CAM_DMA_NODE_BUFFER_MAX_SIZE (4000) // 4-byte aligned -#define LCD_DATA_MAX_WIDTH (24) /*!< Maximum width of LCD data bus */ - -typedef struct { - uint32_t dma_buffer_size; - uint32_t dma_half_buffer_size; - uint32_t dma_node_buffer_size; - uint32_t dma_node_cnt; - uint32_t dma_half_node_cnt; - lldesc_t *dma; - uint8_t *dma_buffer; - QueueHandle_t event_queue; - uint8_t width; - bool swap_data; -} lcd_obj_t; - -typedef struct { - lcd_obj_t lcd; - intr_handle_t lcd_cam_intr_handle; - i2s_dev_t *i2s_dev; -} lcd_cam_obj_t; - -typedef struct { - int rs_io_num; - lcd_cam_obj_t *lcd_cam_obj; - SemaphoreHandle_t mutex; -} i2s_lcd_driver_t; - -static void IRAM_ATTR i2s_isr(void *arg) { - BaseType_t HPTaskAwoken = pdFALSE; - lcd_cam_obj_t *lcd_cam_obj = (lcd_cam_obj_t *)arg; - i2s_dev_t *i2s_dev = lcd_cam_obj->i2s_dev; - - typeof(i2s_dev->int_st) status = i2s_dev->int_st; - i2s_dev->int_clr.val = status.val; - if (status.val == 0) { - return; - } - - if (status.out_eof) { - xQueueSendFromISR(lcd_cam_obj->lcd.event_queue, (void *)&status.val, &HPTaskAwoken); - } - - if (HPTaskAwoken == pdTRUE) { - portYIELD_FROM_ISR(); - } -} - - -static void lcd_dma_set_int(lcd_cam_obj_t *lcd_cam_obj) { - // Generate a data DMA linked list - for (int x = 0; x < lcd_cam_obj->lcd.dma_node_cnt; x++) { - lcd_cam_obj->lcd.dma[x].size = lcd_cam_obj->lcd.dma_node_buffer_size; - lcd_cam_obj->lcd.dma[x].length = lcd_cam_obj->lcd.dma_node_buffer_size; - lcd_cam_obj->lcd.dma[x].buf = (lcd_cam_obj->lcd.dma_buffer + lcd_cam_obj->lcd.dma_node_buffer_size * x); - lcd_cam_obj->lcd.dma[x].eof = !((x + 1) % lcd_cam_obj->lcd.dma_half_node_cnt); - lcd_cam_obj->lcd.dma[x].empty = (uint32_t)&lcd_cam_obj->lcd.dma[(x + 1) % lcd_cam_obj->lcd.dma_node_cnt]; - } - lcd_cam_obj->lcd.dma[lcd_cam_obj->lcd.dma_half_node_cnt - 1].empty = (uint32_t)NULL; - lcd_cam_obj->lcd.dma[lcd_cam_obj->lcd.dma_node_cnt - 1].empty = (uint32_t)NULL; -} - -static void lcd_dma_set_left(lcd_cam_obj_t *lcd_cam_obj, int pos, size_t len) { - int end_pos = 0, size = 0; - // Processing data length is an integer multiple of lcd_cam_obj->lcd.dma_node_buffer_size - if (len % lcd_cam_obj->lcd.dma_node_buffer_size) { - end_pos = (pos % 2) * lcd_cam_obj->lcd.dma_half_node_cnt + len / lcd_cam_obj->lcd.dma_node_buffer_size; - size = len % lcd_cam_obj->lcd.dma_node_buffer_size; - } else { - end_pos = (pos % 2) * lcd_cam_obj->lcd.dma_half_node_cnt + len / lcd_cam_obj->lcd.dma_node_buffer_size - 1; - size = lcd_cam_obj->lcd.dma_node_buffer_size; - } - // Process the tail node to make it a DMA tail - lcd_cam_obj->lcd.dma[end_pos].size = size; - lcd_cam_obj->lcd.dma[end_pos].length = size; - lcd_cam_obj->lcd.dma[end_pos].eof = 1; - lcd_cam_obj->lcd.dma[end_pos].empty = (uint32_t)NULL; -} - -static void lcd_i2s_start(i2s_dev_t *i2s_dev, uint32_t addr, size_t len) { - while (!i2s_dev->state.tx_idle) { - ; - } - i2s_dev->conf.tx_reset = 1; - i2s_dev->conf.tx_reset = 0; - i2s_dev->conf.tx_fifo_reset = 1; - i2s_dev->conf.tx_fifo_reset = 0; - i2s_dev->out_link.addr = addr; - i2s_dev->out_link.start = 1; - ets_delay_us(1); - i2s_dev->conf.tx_start = 1; -} - -static void i2s_write_data(lcd_cam_obj_t *lcd_cam_obj, uint8_t *data, size_t len) { - int event = 0; - int x = 0, y = 0, left = 0, cnt = 0; - if (len <= 0) { - ESP_LOGE(TAG, "wrong len!"); - return; - } - lcd_dma_set_int(lcd_cam_obj); - cnt = len / lcd_cam_obj->lcd.dma_half_buffer_size; - // Start signal - xQueueSend(lcd_cam_obj->lcd.event_queue, &event, 0); - // Process a complete piece of data, ping-pong operation - for (x = 0; x < cnt; x++) { - uint8_t *out = (uint8_t *)lcd_cam_obj->lcd.dma[(x % 2) * lcd_cam_obj->lcd.dma_half_node_cnt].buf; - uint8_t *in = data; - if (lcd_cam_obj->lcd.swap_data) { - for (y = 0; y < lcd_cam_obj->lcd.dma_half_buffer_size; y += 2) { - out[y + 1] = in[y + 0]; - out[y + 0] = in[y + 1]; - } - } else { - memcpy(out, in, lcd_cam_obj->lcd.dma_half_buffer_size); - } - data += lcd_cam_obj->lcd.dma_half_buffer_size; - xQueueReceive(lcd_cam_obj->lcd.event_queue, (void *)&event, portMAX_DELAY); - lcd_i2s_start(lcd_cam_obj->i2s_dev, ((uint32_t)&lcd_cam_obj->lcd.dma[(x % 2) * lcd_cam_obj->lcd.dma_half_node_cnt]) & 0xfffff, lcd_cam_obj->lcd.dma_half_buffer_size); - } - left = len % lcd_cam_obj->lcd.dma_half_buffer_size; - // Process remaining incomplete segment data - if (left) { - uint8_t *out = (uint8_t *)lcd_cam_obj->lcd.dma[(x % 2) * lcd_cam_obj->lcd.dma_half_node_cnt].buf; - uint8_t *in = data; - cnt = left - left % 2; - if (cnt) { - if (lcd_cam_obj->lcd.swap_data) { - for (y = 0; y < cnt; y += 2) { - out[y + 1] = in[y + 0]; - out[y + 0] = in[y + 1]; - } - } else { - memcpy(out, in, cnt); - } - } - - if (left % 2) { - out[cnt] = in[cnt]; - } - lcd_dma_set_left(lcd_cam_obj, x, left); - xQueueReceive(lcd_cam_obj->lcd.event_queue, (void *)&event, portMAX_DELAY); - lcd_i2s_start(lcd_cam_obj->i2s_dev, ((uint32_t)&lcd_cam_obj->lcd.dma[(x % 2) * lcd_cam_obj->lcd.dma_half_node_cnt]) & 0xfffff, left); - } - xQueueReceive(lcd_cam_obj->lcd.event_queue, (void *)&event, portMAX_DELAY); -} - - -static esp_err_t i2s_lcd_reg_config(i2s_dev_t *i2s_dev, uint16_t data_width, uint32_t clk_freq) { - // Configure the clock - i2s_dev->clkm_conf.clkm_div_num = 2; // 160MHz / 2 = 80MHz - i2s_dev->clkm_conf.clkm_div_b = 0; - i2s_dev->clkm_conf.clkm_div_a = 0; - i2s_dev->clkm_conf.clk_sel = 2; // PLL_160M_CLK - i2s_dev->clkm_conf.clk_en = 1; - - i2s_dev->conf.val = 0; - i2s_dev->fifo_conf.val = 0; - i2s_dev->fifo_conf.dscr_en = 1; - - i2s_dev->lc_conf.ahbm_fifo_rst = 1; - i2s_dev->lc_conf.ahbm_fifo_rst = 0; - i2s_dev->lc_conf.ahbm_rst = 1; - i2s_dev->lc_conf.ahbm_rst = 0; - i2s_dev->lc_conf.check_owner = 0; - - i2s_dev->timing.val = 0; - - i2s_dev->int_ena.val = 0; - i2s_dev->int_clr.val = ~0; - - i2s_dev->conf2.lcd_en = 1; - - // Configure sampling rate - // The datasheet states that Fws = Fbck / (W*2), but empirically storing - // 1 in the register gives the highest value of 20MHz, storing 2 gives - // 10MHz, (and storing 0 causes a freeze instead of acting as though 64 was - // specified). - int div_num = (20000000 + clk_freq - 1) / clk_freq; - if (div_num == 0) { - div_num = 1; - } - if (div_num > 63) { - div_num = 63; - } - i2s_dev->sample_rate_conf.tx_bck_div_num = div_num; - i2s_dev->sample_rate_conf.tx_bits_mod = data_width; - // Configuration data format - - i2s_dev->conf.tx_right_first = 1; - i2s_dev->conf.tx_msb_right = 1; - i2s_dev->conf.tx_dma_equal = 1; - - i2s_dev->conf1.tx_pcm_bypass = 1; - i2s_dev->conf1.tx_stop_en = 1; - - i2s_dev->conf2.lcd_en = 1; - - i2s_dev->conf_chan.tx_chan_mod = 1; - - i2s_dev->fifo_conf.tx_fifo_mod_force_en = 1; - i2s_dev->fifo_conf.tx_data_num = 32; - i2s_dev->fifo_conf.tx_fifo_mod = 2; - i2s_dev->fifo_conf.tx_24msb_en = 0; - - i2s_dev->lc_conf.out_rst = 1; - i2s_dev->lc_conf.out_rst = 0; - - i2s_dev->int_ena.out_eof = 1; - - - return ESP_OK; -} - -static esp_err_t lcd_set_pin(const i2s_lcd_config_t *config) { - PIN_FUNC_SELECT(GPIO_PIN_MUX_REG[config->pin_num_wr], PIN_FUNC_GPIO); - gpio_set_direction(config->pin_num_wr, GPIO_MODE_OUTPUT); - gpio_set_pull_mode(config->pin_num_wr, GPIO_FLOATING); - gpio_matrix_out(config->pin_num_wr, I2S0O_WS_OUT_IDX, true, false); - - for (int i = 0; i < config->data_width; i++) { - PIN_FUNC_SELECT(GPIO_PIN_MUX_REG[config->pin_data_num[i]], PIN_FUNC_GPIO); - gpio_set_direction(config->pin_data_num[i], GPIO_MODE_OUTPUT); - gpio_set_pull_mode(config->pin_data_num[i], GPIO_FLOATING); - // High bit aligned, OUT23 is always the highest bit - gpio_matrix_out(config->pin_data_num[i], I2S0O_DATA_OUT0_IDX + (LCD_DATA_MAX_WIDTH - config->data_width) + i, false, false); - } - - return ESP_OK; -} - -static esp_err_t lcd_dma_config(lcd_cam_obj_t *lcd_cam_obj, uint32_t max_dma_buffer_size) { - int cnt = 0; - if (LCD_CAM_DMA_NODE_BUFFER_MAX_SIZE % 2 != 0) { - ESP_LOGE(TAG, "ESP32 only supports 2-byte aligned data length"); - return ESP_FAIL; - } - if (max_dma_buffer_size >= LCD_CAM_DMA_NODE_BUFFER_MAX_SIZE * 2) { - lcd_cam_obj->lcd.dma_node_buffer_size = LCD_CAM_DMA_NODE_BUFFER_MAX_SIZE; - for (cnt = 0; cnt < max_dma_buffer_size - 8; cnt++) { // Find a buffer size that can divide dma_size - if ((max_dma_buffer_size - cnt) % (lcd_cam_obj->lcd.dma_node_buffer_size * 2) == 0) { - break; - } - } - lcd_cam_obj->lcd.dma_buffer_size = max_dma_buffer_size - cnt; - } else { - lcd_cam_obj->lcd.dma_node_buffer_size = max_dma_buffer_size / 2; - lcd_cam_obj->lcd.dma_buffer_size = lcd_cam_obj->lcd.dma_node_buffer_size * 2; - } - - lcd_cam_obj->lcd.dma_half_buffer_size = lcd_cam_obj->lcd.dma_buffer_size / 2; - lcd_cam_obj->lcd.dma_node_cnt = (lcd_cam_obj->lcd.dma_buffer_size) / lcd_cam_obj->lcd.dma_node_buffer_size; // Number of DMA nodes - lcd_cam_obj->lcd.dma_half_node_cnt = lcd_cam_obj->lcd.dma_node_cnt / 2; - - ESP_LOGI(TAG, "lcd_buffer_size: %d, lcd_dma_size: %d, lcd_dma_node_cnt: %d", lcd_cam_obj->lcd.dma_buffer_size, lcd_cam_obj->lcd.dma_node_buffer_size, lcd_cam_obj->lcd.dma_node_cnt); - - lcd_cam_obj->lcd.dma = (lldesc_t *)heap_caps_malloc(lcd_cam_obj->lcd.dma_node_cnt * sizeof(lldesc_t), MALLOC_CAP_DMA | MALLOC_CAP_8BIT); - lcd_cam_obj->lcd.dma_buffer = (uint8_t *)heap_caps_malloc(lcd_cam_obj->lcd.dma_buffer_size * sizeof(uint8_t), MALLOC_CAP_DMA | MALLOC_CAP_8BIT); - return ESP_OK; -} - -static esp_err_t lcd_cam_deinit(i2s_lcd_driver_t *drv) { - if (!drv->lcd_cam_obj) { - return ESP_FAIL; - } - - if (drv->lcd_cam_obj->lcd.event_queue) { - vQueueDelete(drv->lcd_cam_obj->lcd.event_queue); - } - if (drv->lcd_cam_obj->lcd.dma) { - heap_caps_free(drv->lcd_cam_obj->lcd.dma); - } - if (drv->lcd_cam_obj->lcd.dma_buffer) { - heap_caps_free(drv->lcd_cam_obj->lcd.dma_buffer); - } - - if (drv->lcd_cam_obj->lcd_cam_intr_handle) { - esp_intr_free(drv->lcd_cam_obj->lcd_cam_intr_handle); - } - - heap_caps_free(drv->lcd_cam_obj); - drv->lcd_cam_obj = NULL; - return ESP_OK; -} - -static esp_err_t lcd_cam_init(i2s_lcd_driver_t *drv, const i2s_lcd_config_t *config) { - esp_err_t ret = ESP_OK; - - lcd_cam_obj_t *lcd_cam_obj = (lcd_cam_obj_t *)heap_caps_calloc(1, sizeof(lcd_cam_obj_t), MALLOC_CAP_DMA); - if (lcd_cam_obj == NULL) { - ESP_LOGE(TAG, "lcd_cam object malloc error"); - return ESP_ERR_NO_MEM; - } - drv->lcd_cam_obj = lcd_cam_obj; - - if (I2S_NUM_0 == config->i2s_port) { - lcd_cam_obj->i2s_dev = &I2S0; - periph_module_enable(PERIPH_I2S0_MODULE); - } else { - ESP_LOGE(TAG, "Designated I2S peripheral not found"); - } - - ret |= i2s_lcd_reg_config(lcd_cam_obj->i2s_dev, config->data_width, config->clk_freq); - - if (ret != ESP_OK) { - ESP_LOGE(TAG, "lcd_cam config fail!"); - lcd_cam_deinit(drv); - return ESP_FAIL; - } - - ret |= lcd_set_pin(config); - ret |= lcd_dma_config(lcd_cam_obj, config->buffer_size); - - if (ret != ESP_OK) { - ESP_LOGE(TAG, "lcd config fail!"); - lcd_cam_deinit(drv); - return ESP_FAIL; - } - - lcd_cam_obj->lcd.event_queue = xQueueCreate(1, sizeof(int)); - lcd_cam_obj->lcd.width = config->data_width; - lcd_cam_obj->lcd.swap_data = config->swap_data; - - if (lcd_cam_obj->lcd.event_queue == NULL) { - ESP_LOGE(TAG, "lcd config fail!"); - lcd_cam_deinit(drv); - return ESP_FAIL; - } - - ret |= esp_intr_alloc(ETS_I2S0_INTR_SOURCE, ESP_INTR_FLAG_LOWMED | ESP_INTR_FLAG_IRAM, i2s_isr, lcd_cam_obj, &lcd_cam_obj->lcd_cam_intr_handle); - - if (ret != ESP_OK) { - ESP_LOGE(TAG, "lcd_cam intr alloc fail!"); - lcd_cam_deinit(drv); - return ESP_FAIL; - } - - ESP_LOGI(TAG, "lcd init ok"); - - return ESP_OK; -} - - -/**< Public functions */ - -i2s_lcd_handle_t i2s_lcd_driver_init(const i2s_lcd_config_t *config) { - I2S_CHECK(NULL != config, "config pointer invalid", NULL); - I2S_CHECK(GPIO_IS_VALID_GPIO(config->pin_num_wr), "GPIO WR invalid", NULL); - I2S_CHECK(GPIO_IS_VALID_GPIO(config->pin_num_rs), "GPIO RS invalid", NULL); - I2S_CHECK(config->data_width > 0 && config->data_width <= 16, "Bit width out of range", NULL); - I2S_CHECK(0 == (config->data_width % 8), "Bit width must be a multiple of 8", NULL); - uint64_t pin_mask = 0; - for (size_t i = 0; i < config->data_width; i++) { - uint64_t mask = 1ULL << config->pin_data_num[i]; - I2S_CHECK(!(pin_mask & mask), "Data bus GPIO has a duplicate", NULL); - I2S_CHECK(GPIO_IS_VALID_GPIO(config->pin_data_num[i]), "Data bus gpio invalid", NULL); - pin_mask |= mask; - } - - i2s_lcd_driver_t *i2s_lcd_drv = (i2s_lcd_driver_t *)heap_caps_malloc(sizeof(i2s_lcd_driver_t), MALLOC_CAP_INTERNAL | MALLOC_CAP_8BIT); - I2S_CHECK(NULL != i2s_lcd_drv, "Error malloc handle of i2s lcd driver", NULL); - - esp_err_t ret = lcd_cam_init(i2s_lcd_drv, config); - if (ESP_OK != ret) { - ESP_LOGE(TAG, "%s:%d (%s):%s", __FILE__, __LINE__, __FUNCTION__, "i2s lcd driver initialize failed"); - heap_caps_free(i2s_lcd_drv); - return NULL; - } - - i2s_lcd_drv->mutex = xSemaphoreCreateMutex(); - if (i2s_lcd_drv->mutex == NULL) { - ESP_LOGE(TAG, "%s:%d (%s):%s", __FILE__, __LINE__, __FUNCTION__, "lcd create mutex failed"); - lcd_cam_deinit(i2s_lcd_drv); - heap_caps_free(i2s_lcd_drv); - return NULL; - } - - if (config->pin_num_cs >= 0) { - gpio_pad_select_gpio(config->pin_num_cs); - gpio_set_direction(config->pin_num_cs, GPIO_MODE_OUTPUT); - gpio_set_level(config->pin_num_cs, 0); - } - - gpio_pad_select_gpio(config->pin_num_rs); - gpio_set_direction(config->pin_num_rs, GPIO_MODE_OUTPUT); - i2s_lcd_drv->rs_io_num = config->pin_num_rs; - return (i2s_lcd_handle_t)i2s_lcd_drv; -} - -esp_err_t i2s_lcd_driver_deinit(i2s_lcd_handle_t handle) { - i2s_lcd_driver_t *i2s_lcd_drv = (i2s_lcd_driver_t *)handle; - I2S_CHECK(NULL != i2s_lcd_drv, "handle pointer invalid", ESP_ERR_INVALID_ARG); - lcd_cam_deinit(i2s_lcd_drv); - vSemaphoreDelete(i2s_lcd_drv->mutex); - heap_caps_free(handle); - return ESP_OK; -} - -esp_err_t i2s_lcd_write_data(i2s_lcd_handle_t handle, uint16_t data) { - i2s_lcd_driver_t *i2s_lcd_drv = (i2s_lcd_driver_t *)handle; - I2S_CHECK(NULL != i2s_lcd_drv, "handle pointer invalid", ESP_ERR_INVALID_ARG); - i2s_write_data(i2s_lcd_drv->lcd_cam_obj, (uint8_t *)&data, 2); - return ESP_OK; -} - -esp_err_t i2s_lcd_write_cmd(i2s_lcd_handle_t handle, uint16_t cmd) { - i2s_lcd_driver_t *i2s_lcd_drv = (i2s_lcd_driver_t *)handle; - I2S_CHECK(NULL != i2s_lcd_drv, "handle pointer invalid", ESP_ERR_INVALID_ARG); - gpio_set_level(i2s_lcd_drv->rs_io_num, LCD_CMD_LEV); - i2s_write_data(i2s_lcd_drv->lcd_cam_obj, (uint8_t *)&cmd, 2); - gpio_set_level(i2s_lcd_drv->rs_io_num, LCD_DATA_LEV); - return ESP_OK; -} - -esp_err_t i2s_lcd_write(i2s_lcd_handle_t handle, const uint8_t *data, uint32_t length) { - i2s_lcd_driver_t *i2s_lcd_drv = (i2s_lcd_driver_t *)handle; - I2S_CHECK(NULL != i2s_lcd_drv, "handle pointer invalid", ESP_ERR_INVALID_ARG); - i2s_write_data(i2s_lcd_drv->lcd_cam_obj, (uint8_t *)data, length); - - return ESP_OK; -} - -esp_err_t i2s_lcd_acquire(i2s_lcd_handle_t handle) { - i2s_lcd_driver_t *i2s_lcd_drv = (i2s_lcd_driver_t *)handle; - I2S_CHECK(NULL != i2s_lcd_drv, "handle pointer invalid", ESP_ERR_INVALID_ARG); - BaseType_t ret = xSemaphoreTake(i2s_lcd_drv->mutex, portMAX_DELAY); - I2S_CHECK(pdTRUE == ret, "Take semaphore failed", ESP_FAIL); - return ESP_OK; -} - -bool i2s_lcd_acquire_nonblocking(i2s_lcd_handle_t handle, TickType_t ticks_to_wait) { - i2s_lcd_driver_t *i2s_lcd_drv = (i2s_lcd_driver_t *)handle; - return xSemaphoreTake(i2s_lcd_drv->mutex, ticks_to_wait); -} - -esp_err_t i2s_lcd_release(i2s_lcd_handle_t handle) { - i2s_lcd_driver_t *i2s_lcd_drv = (i2s_lcd_driver_t *)handle; - I2S_CHECK(NULL != i2s_lcd_drv, "handle pointer invalid", ESP_ERR_INVALID_ARG); - i2s_dev_t *i2s_dev = &I2S0; -// at this point, the DMA is done but there could still be data in the FIFO. so we need -// to wait for I2S_TX_IDLE so that it's safe e.g., for calling code to deassert CS - while (!i2s_dev->state.tx_idle) { - ; - } - BaseType_t ret = xSemaphoreGive(i2s_lcd_drv->mutex); - I2S_CHECK(pdTRUE == ret, "Give semaphore failed", ESP_FAIL); - return ESP_OK; -} - -#endif // CONFIG_IDF_TARGET_ESP32S2 diff --git a/ports/espressif/mpconfigport.h b/ports/espressif/mpconfigport.h index e4733356bb..bb333ae4ac 100644 --- a/ports/espressif/mpconfigport.h +++ b/ports/espressif/mpconfigport.h @@ -59,12 +59,10 @@ // Nearly all boards have this because it is used to enter the ROM bootloader. #ifndef CIRCUITPY_BOOT_BUTTON - #ifdef CONFIG_IDF_TARGET_ESP32C3 + #if defined(CONFIG_IDF_TARGET_ESP32C3) || defined(CONFIG_IDF_TARGET_ESP32C6) || defined(CONFIG_IDF_TARGET_ESP32H2) #define CIRCUITPY_BOOT_BUTTON (&pin_GPIO9) - #else - #ifndef CONFIG_IDF_TARGET_ESP32 - #define CIRCUITPY_BOOT_BUTTON (&pin_GPIO0) - #endif + #elif !defined(CONFIG_IDF_TARGET_ESP32) + #define CIRCUITPY_BOOT_BUTTON (&pin_GPIO0) #endif #endif @@ -90,12 +88,6 @@ #define CIRCUITPY_I2C_ALLOW_INTERNAL_PULL_UP (0) #endif -// Define to (1) in mpconfigboard.h if the board uses the internal USB to -// Serial/JTAG to connect do USB. -#ifndef CIRCUITPY_ESP_USB_SERIAL_JTAG -#define CIRCUITPY_ESP_USB_SERIAL_JTAG (0) -#endif - #ifndef DEFAULT_RESERVED_PSRAM #define DEFAULT_RESERVED_PSRAM (0) #endif diff --git a/ports/espressif/mpconfigport.mk b/ports/espressif/mpconfigport.mk index 982e3bde36..cc2ddf9f07 100644 --- a/ports/espressif/mpconfigport.mk +++ b/ports/espressif/mpconfigport.mk @@ -2,11 +2,14 @@ INTERNAL_FLASH_FILESYSTEM = 1 # Internal math library is substantially smaller than toolchain one -INTERNAL_LIBM = 1 +INTERNAL_LIBM = 0 # Longints can be implemented as mpz, as longlong, or not LONGINT_IMPL = MPZ +# Default to no-psram +CIRCUITPY_ESP_PSRAM_SIZE ?= 0 + # Enable more features CIRCUITPY_FULL_BUILD ?= 1 @@ -21,6 +24,7 @@ CIRCUITPY_BLEIO ?= 1 CIRCUITPY_BLEIO_HCI = 0 CIRCUITPY_CANIO ?= 1 CIRCUITPY_COUNTIO ?= 1 +CIRCUITPY_DOTCLOCKFRAMEBUFFER_USES_SUPERVISOR_ALLOCATION = 0 CIRCUITPY_DUALBANK ?= 1 CIRCUITPY_ESPCAMERA ?= 1 CIRCUITPY_ESPIDF ?= 1 @@ -32,8 +36,11 @@ CIRCUITPY_I2CTARGET ?= 1 CIRCUITPY_IMAGECAPTURE = 0 CIRCUITPY_MEMORYMAP ?= 1 CIRCUITPY_NVM ?= 1 +# Turn off because it uses the old I2S driver which conflicts with the new ADC driver. +CIRCUITPY_PARALLELDISPLAY ?= 0 CIRCUITPY_PS2IO ?= 1 -CIRCUITPY_RGBMATRIX ?= 1 +# Disabled temporarily +CIRCUITPY_RGBMATRIX ?= 0 CIRCUITPY_ROTARYIO ?= 1 CIRCUITPY_SYNTHIO_MAX_CHANNELS ?= 12 CIRCUITPY_TOUCHIO_USE_NATIVE ?= 1 @@ -43,9 +50,8 @@ CIRCUITPY_WIFI ?= 1 # Conditionally turn off modules/features ifeq ($(IDF_TARGET),esp32) # Modules -CIRCUITPY_BLEIO = 0 -CIRCUITPY_PARALLELDISPLAY = 0 CIRCUITPY_RGBMATRIX = 0 +CIRCUITPY_BLEIO = 0 # Features CIRCUITPY_USB = 0 @@ -64,16 +70,55 @@ CIRCUITPY_TOUCHIO ?= 1 CIRCUITPY_TOUCHIO_USE_NATIVE = 0 # Features CIRCUITPY_USB = 0 +CIRCUITPY_ESP_USB_SERIAL_JTAG ?= 1 + +else ifeq ($(IDF_TARGET),esp32c6) +# Modules +CIRCUITPY_ALARM = 0 +CIRCUITPY_AUDIOBUSIO = 0 +CIRCUITPY_ESPCAMERA = 0 +CIRCUITPY_ESPULP = 0 +CIRCUITPY_MEMORYMAP = 0 +CIRCUITPY_PARALLELDISPLAY = 0 +CIRCUITPY_TOUCHIO ?= 1 +CIRCUITPY_TOUCHIO_USE_NATIVE = 0 +# Features +CIRCUITPY_USB = 0 +CIRCUITPY_ESP_USB_SERIAL_JTAG ?= 1 + +else ifeq ($(IDF_TARGET),esp32h2) +# Modules +CIRCUITPY_ALARM = 0 +# Turn off analogio because calibration is currently supported. +# https://github.com/espressif/esp-idf/issues/11038 +CIRCUITPY_ANALOGIO = 0 +CIRCUITPY_AUDIOBUSIO = 0 +CIRCUITPY_ESPCAMERA = 0 +CIRCUITPY_ESPULP = 0 +CIRCUITPY_MEMORYMAP = 0 +CIRCUITPY_PARALLELDISPLAY = 0 +CIRCUITPY_RGBMATRIX = 0 +CIRCUITPY_TOUCHIO ?= 1 +CIRCUITPY_TOUCHIO_USE_NATIVE = 0 +# Features +CIRCUITPY_USB = 0 +CIRCUITPY_ESP_USB_SERIAL_JTAG ?= 1 +CIRCUITPY_WIFI = 0 else ifeq ($(IDF_TARGET),esp32s2) # Modules CIRCUITPY_BLEIO = 0 CIRCUITPY_RGBMATRIX_USES_SUPERVISOR_ALLOCATION = 0 +CIRCUITPY_ESP_USB_SERIAL_JTAG ?= 0 + else ifeq ($(IDF_TARGET),esp32s3) # Modules CIRCUITPY_PARALLELDISPLAY = 0 CIRCUITPY_RGBMATRIX_USES_SUPERVISOR_ALLOCATION = 0 + +CIRCUITPY_ESP_USB_SERIAL_JTAG ?= 0 + endif # No room for dualbank on boards with 2MB flash diff --git a/ports/espressif/mphalport.c b/ports/espressif/mphalport.c index 76d2c05cc3..0342c56c11 100644 --- a/ports/espressif/mphalport.c +++ b/ports/espressif/mphalport.c @@ -32,10 +32,16 @@ #include "components/esp_rom/include/esp32/rom/ets_sys.h" #elif defined(CONFIG_IDF_TARGET_ESP32C3) #include "components/esp_rom/include/esp32c3/rom/ets_sys.h" +#elif defined(CONFIG_IDF_TARGET_ESP32C6) +#include "components/esp_rom/include/esp32c6/rom/ets_sys.h" +#elif defined(CONFIG_IDF_TARGET_ESP32H2) +#include "components/esp_rom/include/esp32h2/rom/ets_sys.h" #elif defined(CONFIG_IDF_TARGET_ESP32S2) #include "components/esp_rom/include/esp32s2/rom/ets_sys.h" #elif defined(CONFIG_IDF_TARGET_ESP32S3) #include "components/esp_rom/include/esp32s3/rom/ets_sys.h" +#else +#error Unknown CONFIG_IDF_TARGET_xxx #endif void mp_hal_delay_us(mp_uint_t delay) { @@ -43,7 +49,7 @@ void mp_hal_delay_us(mp_uint_t delay) { } // This is provided by the esp-idf/components/xtensa/esp32s2/libhal.a binary blob. -#ifndef CONFIG_IDF_TARGET_ESP32C3 +#ifndef CONFIG_IDF_TARGET_ARCH_RISCV extern void xthal_window_spill(void); #endif @@ -61,7 +67,7 @@ mp_uint_t cpu_get_regs_and_sp(mp_uint_t *regs) { // there is a HAL call to do it. There is a bit of a race condition here // because the register value could change after it's been restored but that // is unlikely to happen with a heap pointer while we do a GC. - #ifndef CONFIG_IDF_TARGET_ESP32C3 + #ifndef CONFIG_IDF_TARGET_ARCH_RISCV xthal_window_spill(); #endif return (mp_uint_t)__builtin_frame_address(0); diff --git a/ports/espressif/peripherals/esp32c6/pins.c b/ports/espressif/peripherals/esp32c6/pins.c new file mode 100644 index 0000000000..51f68777c6 --- /dev/null +++ b/ports/espressif/peripherals/esp32c6/pins.c @@ -0,0 +1,59 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2021 microDev + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#include "peripherals/pins.h" + +const mcu_pin_obj_t pin_GPIO0 = PIN(0, ADC_UNIT_1, ADC_CHANNEL_0, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO1 = PIN(1, ADC_UNIT_1, ADC_CHANNEL_1, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO2 = PIN(2, ADC_UNIT_1, ADC_CHANNEL_2, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO3 = PIN(3, ADC_UNIT_1, ADC_CHANNEL_3, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO4 = PIN(4, ADC_UNIT_1, ADC_CHANNEL_4, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO5 = PIN(5, ADC_UNIT_1, ADC_CHANNEL_5, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO6 = PIN(6, ADC_UNIT_1, ADC_CHANNEL_6, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO7 = PIN(7, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO8 = PIN(8, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO9 = PIN(9, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO10 = PIN(10, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO11 = PIN(11, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO12 = PIN(12, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO13 = PIN(13, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO14 = PIN(14, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO15 = PIN(15, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO16 = PIN(16, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO17 = PIN(17, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO18 = PIN(18, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO19 = PIN(19, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO20 = PIN(20, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO21 = PIN(21, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO22 = PIN(22, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO23 = PIN(23, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO24 = PIN(24, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO25 = PIN(25, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO26 = PIN(26, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO27 = PIN(27, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO28 = PIN(28, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO29 = PIN(29, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO30 = PIN(30, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); diff --git a/ports/espressif/peripherals/esp32c6/pins.h b/ports/espressif/peripherals/esp32c6/pins.h new file mode 100644 index 0000000000..4c2b4390e7 --- /dev/null +++ b/ports/espressif/peripherals/esp32c6/pins.h @@ -0,0 +1,94 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2023 Scott Shawcroft for Adafruit Industries LLC + * + * 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. + */ + +// DO NOT include this file directly. +// Use shared-bindings/microcontroller/Pin.h instead. +// This ensures that all necessary includes are already included. + +#pragma once + +#define GPIO0_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO0; +#define GPIO1_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO1; +#define GPIO2_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO2; +#define GPIO3_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO3; +#define GPIO4_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO4; +#define GPIO5_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO5; +#define GPIO6_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO6; +#define GPIO7_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO7; +#define GPIO8_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO8; +#define GPIO9_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO9; +#define GPIO10_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO10; +#define GPIO11_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO11; +#define GPIO12_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO12; +#define GPIO13_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO13; +#define GPIO14_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO14; +#define GPIO15_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO15; +#define GPIO16_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO16; +#define GPIO17_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO17; +#define GPIO18_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO18; +#define GPIO19_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO19; +#define GPIO20_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO20; +#define GPIO21_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO21; +#define GPIO22_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO22; +#define GPIO23_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO23; +#define GPIO24_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO24; +#define GPIO25_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO25; +#define GPIO26_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO26; +#define GPIO27_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO27; +#define GPIO28_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO28; +#define GPIO29_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO29; +#define GPIO30_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO30; diff --git a/ports/espressif/peripherals/esp32h2/pins.c b/ports/espressif/peripherals/esp32h2/pins.c new file mode 100644 index 0000000000..a085ca09ae --- /dev/null +++ b/ports/espressif/peripherals/esp32h2/pins.c @@ -0,0 +1,47 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2021 microDev + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#include "peripherals/pins.h" + +const mcu_pin_obj_t pin_GPIO0 = PIN(0, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO1 = PIN(1, ADC_UNIT_1, ADC_CHANNEL_0, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO2 = PIN(2, ADC_UNIT_1, ADC_CHANNEL_1, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO3 = PIN(3, ADC_UNIT_1, ADC_CHANNEL_2, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO4 = PIN(4, ADC_UNIT_1, ADC_CHANNEL_3, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO5 = PIN(5, ADC_UNIT_1, ADC_CHANNEL_4, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO8 = PIN(8, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO9 = PIN(9, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO10 = PIN(10, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO11 = PIN(11, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO12 = PIN(12, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO13 = PIN(13, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO14 = PIN(14, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO22 = PIN(22, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO23 = PIN(23, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO24 = PIN(24, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO25 = PIN(25, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO26 = PIN(26, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); +const mcu_pin_obj_t pin_GPIO27 = PIN(27, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); diff --git a/ports/espressif/peripherals/esp32h2/pins.h b/ports/espressif/peripherals/esp32h2/pins.h new file mode 100644 index 0000000000..7d781ff733 --- /dev/null +++ b/ports/espressif/peripherals/esp32h2/pins.h @@ -0,0 +1,70 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2023 Scott Shawcroft for Adafruit Industries LLC + * + * 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. + */ + +// DO NOT include this file directly. +// Use shared-bindings/microcontroller/Pin.h instead. +// This ensures that all necessary includes are already included. + +#pragma once + +#define GPIO0_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO0; +#define GPIO1_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO1; +#define GPIO2_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO2; +#define GPIO3_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO3; +#define GPIO4_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO4; +#define GPIO5_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO5; +#define GPIO8_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO8; +#define GPIO9_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO9; +#define GPIO10_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO10; +#define GPIO11_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO11; +#define GPIO12_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO12; +#define GPIO13_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO13; +#define GPIO14_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO14; +#define GPIO22_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO22; +#define GPIO23_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO23; +#define GPIO24_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO24; +#define GPIO25_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO25; +#define GPIO26_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO26; +#define GPIO27_EXISTS 1 +extern const mcu_pin_obj_t pin_GPIO27; diff --git a/ports/espressif/peripherals/esp32s3/pins.c b/ports/espressif/peripherals/esp32s3/pins.c index 891cc398ae..ef5b2462c6 100644 --- a/ports/espressif/peripherals/esp32s3/pins.c +++ b/ports/espressif/peripherals/esp32s3/pins.c @@ -26,6 +26,8 @@ #include "peripherals/pins.h" +// NOTE: These numbers do NOT always match the package and module pin number. +// These are by solely by GPIO numbers. const mcu_pin_obj_t pin_GPIO0 = PIN(0, NO_ADC, NO_ADC_CHANNEL, NO_TOUCH_CHANNEL); const mcu_pin_obj_t pin_GPIO1 = PIN(1, ADC_UNIT_1, ADC_CHANNEL_0, TOUCH_PAD_NUM1); const mcu_pin_obj_t pin_GPIO2 = PIN(2, ADC_UNIT_1, ADC_CHANNEL_1, TOUCH_PAD_NUM2); diff --git a/ports/espressif/peripherals/i2c.c b/ports/espressif/peripherals/i2c.c index 7a85349f96..d16f165d38 100644 --- a/ports/espressif/peripherals/i2c.c +++ b/ports/espressif/peripherals/i2c.c @@ -35,7 +35,7 @@ typedef enum { static i2c_status_t i2c_status[I2C_NUM_MAX]; void i2c_reset(void) { - for (i2c_port_t num = 0; num < I2C_NUM_MAX; num++) { + for (i2c_port_t num = 0; num < (i2c_port_t)I2C_NUM_MAX; num++) { if (i2c_status[num] == STATUS_IN_USE) { i2c_driver_delete(num); i2c_status[num] = STATUS_FREE; @@ -70,7 +70,7 @@ void peripherals_i2c_deinit(i2c_port_t num) { i2c_port_t peripherals_i2c_get_free_num(void) { i2c_port_t i2c_num = I2C_NUM_MAX; - for (i2c_port_t num = 0; num < I2C_NUM_MAX; num++) { + for (i2c_port_t num = 0; num < (int)I2C_NUM_MAX; num++) { if (i2c_status[num] == STATUS_FREE) { i2c_num = num; break; diff --git a/ports/espressif/peripherals/pins.h b/ports/espressif/peripherals/pins.h index 9edad560c8..5d759c6612 100644 --- a/ports/espressif/peripherals/pins.h +++ b/ports/espressif/peripherals/pins.h @@ -49,12 +49,12 @@ extern const mp_obj_type_t mcu_pin_type; #define NO_PIN (GPIO_NUM_NC) -#define NO_ADC 0 -#define NO_ADC_CHANNEL ADC_CHANNEL_MAX +#define NO_ADC SOC_ADC_PERIPH_NUM +#define NO_ADC_CHANNEL SOC_ADC_MAX_CHANNEL_NUM #define NO_TOUCH_CHANNEL TOUCH_PAD_MAX -// This macro is used to simplify pin definition in boards//pins.c +// This macro is used to simplify pin definition in peripherals//pins.c #define PIN(p_number, p_adc_index, p_adc_channel, p_touch_channel) \ { \ { &mcu_pin_type }, \ @@ -69,6 +69,10 @@ extern const mp_obj_type_t mcu_pin_type; #include "esp32/pins.h" #elif defined(CONFIG_IDF_TARGET_ESP32C3) #include "esp32c3/pins.h" +#elif defined(CONFIG_IDF_TARGET_ESP32C6) +#include "esp32c6/pins.h" +#elif defined(CONFIG_IDF_TARGET_ESP32H2) +#include "esp32h2/pins.h" #elif defined(CONFIG_IDF_TARGET_ESP32S2) #include "esp32s2/pins.h" #elif defined(CONFIG_IDF_TARGET_ESP32S3) diff --git a/ports/espressif/peripherals/rmt.h b/ports/espressif/peripherals/rmt.h index 24a4383789..08a446636e 100644 --- a/ports/espressif/peripherals/rmt.h +++ b/ports/espressif/peripherals/rmt.h @@ -27,9 +27,11 @@ #ifndef MICROPY_INCLUDED_ESPRESSIF_PERIPHERALS_RMT_H #define MICROPY_INCLUDED_ESPRESSIF_PERIPHERALS_RMT_H -#include "py/mphal.h" -#include "components/driver/include/driver/rmt.h" #include + +#include "py/mphal.h" +#include "driver/rmt.h" + #define TRANSMIT_MODE true #define RECEIVE_MODE false diff --git a/ports/espressif/peripherals/timer.h b/ports/espressif/peripherals/timer.h index c968b0f400..82dcc7838a 100644 --- a/ports/espressif/peripherals/timer.h +++ b/ports/espressif/peripherals/timer.h @@ -28,6 +28,7 @@ #define MICROPY_INCLUDED_ESPRESSIF_PERIPHERALS_TIMER_HANDLER_H #include "driver/timer.h" +#include "soc/timer_group_struct.h" typedef struct { timg_dev_t *hw; diff --git a/ports/espressif/supervisor/port.c b/ports/espressif/supervisor/port.c index db4a436b13..8962fb870f 100644 --- a/ports/espressif/supervisor/port.c +++ b/ports/espressif/supervisor/port.c @@ -25,12 +25,15 @@ * THE SOFTWARE. */ +#include #include #include #include "supervisor/board.h" #include "supervisor/port.h" #include "supervisor/filesystem.h" #include "supervisor/shared/reload.h" +#include "supervisor/serial.h" +#include "py/mpprint.h" #include "py/runtime.h" #include "freertos/FreeRTOS.h" @@ -71,10 +74,6 @@ #include "peripherals/touch.h" #endif -#if CIRCUITPY_AUDIOBUSIO -#include "common-hal/audiobusio/__init__.h" -#endif - #if CIRCUITPY_BLEIO #include "shared-bindings/_bleio/__init__.h" #endif @@ -83,21 +82,26 @@ #include "esp_camera.h" #endif -#ifndef CONFIG_IDF_TARGET_ESP32 -#include "soc/cache_memory.h" -#endif - #include "soc/efuse_reg.h" +#if defined(SOC_LP_AON_SUPPORTED) +#include "soc/lp_aon_reg.h" +#define CP_SAVED_WORD_REGISTER LP_AON_STORE0_REG +#else #include "soc/rtc_cntl_reg.h" - -#include "esp_debug_helpers.h" +#define CP_SAVED_WORD_REGISTER RTC_CNTL_STORE0_REG +#endif +#include "soc/spi_pins.h" #include "bootloader_flash_config.h" + +#include "esp_debug_helpers.h" #include "esp_efuse.h" #include "esp_ipc.h" #include "esp_rom_efuse.h" +#include "esp_timer.h" #ifdef CONFIG_IDF_TARGET_ESP32 +#include "hal/efuse_hal.h" #include "esp32/rom/efuse.h" #endif @@ -184,7 +188,7 @@ static void _never_reset_spi_ram_flash(void) { if (pkg_ver == EFUSE_RD_CHIP_VER_PKG_ESP32D2WDQ5) { never_reset_pin_number(D2WD_PSRAM_CLK_IO); never_reset_pin_number(D2WD_PSRAM_CS_IO); - } else if (pkg_ver == EFUSE_RD_CHIP_VER_PKG_ESP32PICOD4 && esp_efuse_get_chip_ver() >= 3) { + } else if (pkg_ver == EFUSE_RD_CHIP_VER_PKG_ESP32PICOD4 && efuse_hal_get_major_chip_version() >= 3) { // This chip is ESP32-PICO-V3 and doesn't have PSRAM. } else if ((pkg_ver == EFUSE_RD_CHIP_VER_PKG_ESP32PICOD2) || (pkg_ver == EFUSE_RD_CHIP_VER_PKG_ESP32PICOD4)) { never_reset_pin_number(PICO_PSRAM_CLK_IO); @@ -243,16 +247,17 @@ safe_mode_t port_init(void) { circuitpython_task = xTaskGetCurrentTaskHandle(); + #if !defined(DEBUG) + #define DEBUG (0) + #endif + // Send the ROM output out of the UART. This includes early logs. - #ifdef DEBUG - ets_install_uart_printf(); + #if DEBUG + esp_rom_install_uart_printf(); #endif heap = NULL; - - #ifndef DEBUG - #define DEBUG (0) - #endif + heap_size = 0; #define pin_GPIOn(n) pin_GPIO##n #define pin_GPIOn_EXPAND(x) pin_GPIOn(x) @@ -281,6 +286,7 @@ safe_mode_t port_init(void) { #endif #if ENABLE_JTAG + ESP_LOGI(TAG, "Marking JTAG pins never_reset"); // JTAG #ifdef CONFIG_IDF_TARGET_ESP32C3 common_hal_never_reset_pin(&pin_GPIO4); @@ -295,33 +301,8 @@ safe_mode_t port_init(void) { #endif #endif - #ifdef CONFIG_SPIRAM - { - intptr_t heap_start = common_hal_espidf_get_psram_start(); - intptr_t heap_end = common_hal_espidf_get_psram_end(); - size_t spiram_size = heap_end - heap_start; - if (spiram_size > 0) { - heap = (uint32_t *)heap_start; - heap_size = (heap_end - heap_start) / sizeof(uint32_t); - } else { - ESP_LOGE(TAG, "CONFIG_SPIRAM enabled but no spiram heap available"); - } - } - #endif - _never_reset_spi_ram_flash(); - if (heap == NULL) { - size_t heap_total = heap_caps_get_total_size(MALLOC_CAP_8BIT); - heap_size = MIN(heap_caps_get_largest_free_block(MALLOC_CAP_8BIT), heap_total / 2); - heap = malloc(heap_size); - heap_size = heap_size / sizeof(uint32_t); - } - if (heap == NULL) { - heap_size = 0; - return SAFE_MODE_NO_HEAP; - } - esp_reset_reason_t reason = esp_reset_reason(); switch (reason) { case ESP_RST_BROWNOUT: @@ -340,6 +321,57 @@ safe_mode_t port_init(void) { return SAFE_MODE_NONE; } +safe_mode_t port_heap_init(safe_mode_t sm) { + mp_int_t reserved = 0; + if (filesystem_present() && common_hal_os_getenv_int("CIRCUITPY_RESERVED_PSRAM", &reserved) == GETENV_OK) { + common_hal_espidf_set_reserved_psram(reserved); + } + + #if defined(CONFIG_SPIRAM_USE_MEMMAP) + { + intptr_t heap_start = common_hal_espidf_get_psram_start(); + intptr_t heap_end = common_hal_espidf_get_psram_end(); + size_t spiram_size = heap_end - heap_start; + if (spiram_size > 0) { + heap = (uint32_t *)heap_start; + heap_size = (heap_end - heap_start) / sizeof(uint32_t); + common_hal_espidf_reserve_psram(); + } else { + ESP_LOGE(TAG, "CONFIG_SPIRAM_USE_MMAP enabled but no spiram heap available"); + } + } + #elif defined(CONFIG_SPIRAM_USE_CAPS_ALLOC) + { + intptr_t psram_start = common_hal_espidf_get_psram_start(); + intptr_t psram_end = common_hal_espidf_get_psram_end(); + size_t psram_amount = psram_end - psram_start; + size_t biggest_block = heap_caps_get_largest_free_block(MALLOC_CAP_SPIRAM); + size_t try_alloc = MIN(biggest_block, psram_amount - common_hal_espidf_get_reserved_psram()); + heap = heap_caps_malloc(try_alloc, MALLOC_CAP_SPIRAM); + + if (heap) { + heap_size = try_alloc; + } else { + ESP_LOGE(TAG, "CONFIG_SPIRAM_USE_CAPS_ALLOC but no spiram heap available"); + } + } + #endif + + if (heap == NULL) { + size_t heap_total = heap_caps_get_total_size(MALLOC_CAP_8BIT); + heap_size = MIN(heap_caps_get_largest_free_block(MALLOC_CAP_8BIT), heap_total / 2); + heap = malloc(heap_size); + heap_size = heap_size / sizeof(uint32_t); + } + if (heap == NULL) { + heap_size = 0; + return SAFE_MODE_NO_HEAP; + } + + return sm; + +} + void reset_port(void) { // TODO deinit for esp32-camera #if CIRCUITPY_ESPCAMERA @@ -352,10 +384,6 @@ void reset_port(void) { analogout_reset(); #endif - #if CIRCUITPY_AUDIOBUSIO - i2s_reset(); - #endif - #if CIRCUITPY_BUSIO i2c_reset(); spi_reset(); @@ -421,7 +449,7 @@ void reset_to_bootloader(void) { } void reset_cpu(void) { - #ifndef CONFIG_IDF_TARGET_ESP32C3 + #ifndef CONFIG_IDF_TARGET_ARCH_RISCV esp_backtrace_print(100); #endif esp_restart(); @@ -461,13 +489,12 @@ bool port_has_fixed_stack(void) { return true; } -// Place the word to save just after our BSS section that gets blanked. void port_set_saved_word(uint32_t value) { - REG_WRITE(RTC_CNTL_STORE0_REG, value); + REG_WRITE(CP_SAVED_WORD_REGISTER, value); } uint32_t port_get_saved_word(void) { - return REG_READ(RTC_CNTL_STORE0_REG); + return REG_READ(CP_SAVED_WORD_REGISTER); } uint64_t port_get_raw_ticks(uint8_t *subticks) { @@ -529,14 +556,20 @@ void port_idle_until_interrupt(void) { void port_post_boot_py(bool heap_valid) { if (!heap_valid && filesystem_present()) { - mp_int_t reserved; - if (common_hal_os_getenv_int("CIRCUITPY_RESERVED_PSRAM", &reserved) == GETENV_OK) { - common_hal_espidf_set_reserved_psram(reserved); - } - common_hal_espidf_reserve_psram(); } } + +#if CIRCUITPY_CONSOLE_UART +static int vprintf_adapter(const char *fmt, va_list ap) { + return mp_vprintf(&mp_plat_print, fmt, ap); +} + +void port_serial_early_init(void) { + esp_log_set_vprintf(vprintf_adapter); +} +#endif + // Wrap main in app_main that the IDF expects. extern void main(void); extern void app_main(void); diff --git a/ports/espressif/supervisor/usb.c b/ports/espressif/supervisor/usb.c index 61e6b5f09d..ad4c950333 100644 --- a/ports/espressif/supervisor/usb.c +++ b/ports/espressif/supervisor/usb.c @@ -35,8 +35,8 @@ #include "hal/usb_hal.h" #include "soc/usb_periph.h" -#include "components/driver/include/driver/gpio.h" -#include "components/driver/include/driver/periph_ctrl.h" +#include "driver/gpio.h" +#include "esp_private/periph_ctrl.h" #ifdef CONFIG_IDF_TARGET_ESP32C3 #include "components/esp_rom/include/esp32c3/rom/gpio.h" diff --git a/ports/espressif/tools/build_memory_info.py b/ports/espressif/tools/build_memory_info.py index bbcd3d2df7..04ed04331a 100644 --- a/ports/espressif/tools/build_memory_info.py +++ b/ports/espressif/tools/build_memory_info.py @@ -38,12 +38,27 @@ internal_memory = { ("Internal SRAM 1", (0x3FC8_0000, 0x4037_8000), 416 * 1024), ("Internal SRAM 2", (0x3FCF_0000,), 64 * 1024), ], + "esp32c2": [ + # Name, Start, Length + ("Internal SRAM 0", (0x4037_C000,), 16 * 1024), + ("Internal SRAM 1", (0x3FCA_0000, 0x4038_0000), 256 * 1024), + ], "esp32c3": [ # Name, Start, Length ("RTC Fast Memory", (0x5000_0000,), 8 * 1024), ("Internal SRAM 0", (0x4037_C000,), 16 * 1024), ("Internal SRAM 1", (0x3FC8_0000, 0x4038_0000), 384 * 1024), ], + "esp32c6": [ + # Name, Start, Length + ("LP SRAM", (0x5000_0000,), 16 * 1024), + ("HP SRAM", (0x4080_0000,), 512 * 1024), + ], + "esp32h2": [ + # Name, Start, Length + ("LP SRAM", (0x5000_0000,), 4 * 1024), + ("HP SRAM", (0x4080_0000,), 320 * 1024), + ], } diff --git a/ports/espressif/tools/update_all_board_sdkconfig.py b/ports/espressif/tools/update_all_board_sdkconfig.py new file mode 100644 index 0000000000..60f7c7e045 --- /dev/null +++ b/ports/espressif/tools/update_all_board_sdkconfig.py @@ -0,0 +1,20 @@ +import pathlib +import sys +import shlex +import subprocess + + +def run(cmd): + proc = subprocess.run(shlex.split(cmd), capture_output=True) + return proc.returncode == 0 + + +failed_count = 0 +for board in sorted(list(pathlib.Path("boards/").glob("*/"))): + board = board.name + print(board) + if not run(f"make BOARD={board} clean update-board-sdkconfig"): + print(" Failed!") + failed_count += 1 + +print(f"{failed_count} boards failed") diff --git a/ports/espressif/tools/update_sdkconfig.py b/ports/espressif/tools/update_sdkconfig.py index 9639e06435..efae6a4dc1 100644 --- a/ports/espressif/tools/update_sdkconfig.py +++ b/ports/espressif/tools/update_sdkconfig.py @@ -4,6 +4,8 @@ import pathlib import click import copy +import kconfiglib +import os OPT_SETTINGS = [ "CONFIG_ESP_ERR_TO_NAME_LOOKUP", @@ -21,17 +23,14 @@ OPT_SETTINGS = [ "CONFIG_OPTIMIZATION_ASSERTION_LEVEL", "CONFIG_OPTIMIZATION_ASSERTIONS_", "CONFIG_HAL_DEFAULT_ASSERTION_LEVEL", + "CONFIG_BOOTLOADER_LOG_LEVEL", + "LOG_DEFAULT_LEVEL", ] TARGET_SETTINGS = [ "CONFIG_IDF_TARGET", "CONFIG_IDF_FIRMWARE_CHIP_ID", "CONFIG_BOOTLOADER_OFFSET_IN_FLASH", - "CONFIG_ESP32_", - "CONFIG_ESP32C3_", - "CONFIG_ESP32S2_", - "CONFIG_ESP32S3_", - "CONFIG_ESP32H2_", "CONFIG_ESP_SLEEP_POWER_DOWN_FLASH", "CONFIG_ESP_SYSTEM_SINGLE_CORE_MODE", "CONFIG_ESP_SYSTEM_MEMPROT_", @@ -54,22 +53,42 @@ TARGET_SETTINGS = [ "CONFIG_NIMBLE_PINNED_TO_CORE", "CONFIG_BT_NIMBLE_PINNED_TO_CORE", "CONFIG_BT_CTRL_PINNED_TO_CORE", + "CONFIG_SPIRAM_SPEED_2", + "CONFIG_SPIRAM_BANKSWITCH_ENABLE", # For ESP32 ] BOARD_SETTINGS = [ - "PSRAM clock and cs IO for ESP32S3", - "CONFIG_SPIRAM", - "CONFIG_DEFAULT_PSRAM_", - "_SPIRAM_SUPPORT", "CONFIG_LWIP_LOCAL_HOSTNAME", ] -FLASH_SETTINGS = [ +FLASH_SIZE_SETTINGS = [ "CONFIG_ESPTOOLPY_FLASHSIZE", "CONFIG_PARTITION_TABLE_CUSTOM_FILENAME", "CONFIG_PARTITION_TABLE_FILENAME", ] +FLASH_MODE_SETTINGS = [ + "CONFIG_ESPTOOLPY_FLASHMODE_", + "CONFIG_ESPTOOLPY_OCT_FLASH", + "CONFIG_ESPTOOLPY_FLASH_SAMBLE_MODE_", +] + +FLASH_FREQ_SETTINGS = [ + "CONFIG_ESPTOOLPY_FLASHFREQ_", +] + +PSRAM_SETTINGS = ["CONFIG_SPIRAM"] + +PSRAM_SIZE_SETTINGS = ["CONFIG_SPIRAM_TYPE_"] + +PSRAM_MODE_SETTINGS = ["CONFIG_SPIRAM_MODE_"] + +PSRAM_FREQ_SETTINGS = ["CONFIG_SPIRAM_SPEED_"] + +# Some settings are target dependent but we want to always include them anyway +# because the files they are in will be used across targets. +ALWAYS_INCLUDE = FLASH_MODE_SETTINGS + FLASH_FREQ_SETTINGS + PSRAM_FREQ_SETTINGS + BLE_SETTINGS = ["CONFIG_BT_", "CONFIG_BLUEDROID_", "CONFIG_NIMBLE_", "CONFIG_SW_COEXIST_ENABLE"] # boards/lilygo_ttgo_t8_s2_st7789/sdkconfig @@ -102,6 +121,33 @@ def add_group(lines, last_group, current_group): return last_group +def sym_default(sym): + # Skip symbols that cannot be changed. Only check + # non-choice symbols, as selects don't affect choice + # symbols. + if not sym.choice and sym.visibility <= kconfiglib.expr_value(sym.rev_dep): + return True + + # Skip symbols whose value matches their default + if sym.str_value == sym._str_default(): + return True + + # Skip symbols that would be selected by default in a + # choice, unless the choice is optional or the symbol type + # isn't bool (it might be possible to set the choice mode + # to n or the symbol to m in those cases). + if ( + sym.choice + and not sym.choice.is_optional + and sym.choice._selection_from_defaults() is sym + and sym.orig_type is kconfiglib.BOOL + and sym.tri_value == 2 + ): + return True + + return False + + @click.command() @click.option("--debug") @click.option("--board") @@ -116,33 +162,106 @@ def update(debug, board, update_all): was likely modified by menuconfig.""" board_make = pathlib.Path(f"boards/{board}/mpconfigboard.mk") + psram_size = "0" + uf2_bootloader = None + ble_enabled = None for line in board_make.read_text().split("\n"): - if line.startswith("IDF_TARGET"): - target = line.split("=")[1].strip() - elif line.startswith("CIRCUITPY_ESP_FLASH_SIZE"): - flash = line.split("=")[1].strip() + if "=" not in line or line.startswith("#"): + continue + key, value = line.split("=", maxsplit=1) + key = key.strip() + value = value.strip() + if key == "IDF_TARGET": + target = value + if uf2_bootloader is None: + uf2_bootloader = target not in ("esp32", "esp32c3", "esp32c6", "esp32h2") + if ble_enabled is None: + ble_enabled = target not in ( + "esp32", + "esp32s2", + ) # ESP32 is disabled by us. S2 doesn't support it. + elif key == "CIRCUITPY_ESP_FLASH_SIZE": + flash_size = value + elif key == "CIRCUITPY_ESP_FLASH_MODE": + flash_mode = value + elif key == "CIRCUITPY_ESP_FLASH_FREQ": + flash_freq = value + elif key == "CIRCUITPY_ESP_PSRAM_SIZE": + psram_size = value + elif key == "CIRCUITPY_ESP_PSRAM_MODE": + psram_mode = value + elif key == "CIRCUITPY_ESP_PSRAM_FREQ": + psram_freq = value + elif key == "UF2_BOOTLOADER": + uf2_bootloader = not (value == "0") + elif key == "CIRCUITPY_BLEIO": + ble_enabled = not (value == "0") + + os.environ["IDF_TARGET"] = target + os.environ[ + "COMPONENT_KCONFIGS_PROJBUILD_SOURCE_FILE" + ] = f"build-{board}/esp-idf/kconfigs_projbuild.in" + os.environ["COMPONENT_KCONFIGS_SOURCE_FILE"] = f"build-{board}/esp-idf/kconfigs.in" + + kconfig_path = pathlib.Path(f"build-{board}/esp-idf/kconfigs.in") + + kconfig_path = pathlib.Path(f"esp-idf/Kconfig") + kconfig = kconfiglib.Kconfig(kconfig_path) input_config = pathlib.Path(f"build-{board}/esp-idf/sdkconfig") + kconfig.load_config(input_config) + + sdkconfigs = [] default_config = pathlib.Path("esp-idf-config/sdkconfig.defaults") + sdkconfigs.append(default_config) if debug: opt_config = pathlib.Path("esp-idf-config/sdkconfig-debug.defaults") else: opt_config = pathlib.Path("esp-idf-config/sdkconfig-opt.defaults") - flash_config = pathlib.Path(f"esp-idf-config/sdkconfig-{flash}.defaults") - target_config = pathlib.Path(f"esp-idf-config/sdkconfig-{target}.defaults") - ble_config = pathlib.Path(f"esp-idf-config/sdkconfig-ble.defaults") - board_config = pathlib.Path(f"boards/{board}/sdkconfig") + sdkconfigs.append(opt_config) + size_options = "" + if flash_size == "2MB": + size_options = "-no-ota-no-uf2" + elif not uf2_bootloader: + # These boards don't have native USB. + size_options = "-no-uf2" + flash_size_config = pathlib.Path( + f"esp-idf-config/sdkconfig-flash-{flash_size}{size_options}.defaults" + ) + flash_mode_config = pathlib.Path(f"esp-idf-config/sdkconfig-flash-{flash_mode}.defaults") + flash_freq_config = pathlib.Path(f"esp-idf-config/sdkconfig-flash-{flash_freq}.defaults") + sdkconfigs.extend((flash_size_config, flash_mode_config, flash_freq_config)) - defaults = default_config.read_text().split("\n") - defaults.extend(opt_config.read_text().split("\n")) - defaults.extend(flash_config.read_text().split("\n")) - defaults.extend(target_config.read_text().split("\n")) - defaults.extend(ble_config.read_text().split("\n")) + if psram_size != "0": + psram_config = pathlib.Path(f"esp-idf-config/sdkconfig-psram.defaults") + psram_size_config = pathlib.Path(f"esp-idf-config/sdkconfig-psram-{psram_size}.defaults") + psram_mode_config = pathlib.Path(f"esp-idf-config/sdkconfig-psram-{psram_mode}.defaults") + psram_freq_config = pathlib.Path(f"esp-idf-config/sdkconfig-psram-{psram_freq}.defaults") + sdkconfigs.extend((psram_config, psram_size_config, psram_mode_config, psram_freq_config)) + target_config = pathlib.Path(f"esp-idf-config/sdkconfig-{target}.defaults") + sdkconfigs.append(target_config) + if ble_enabled: + ble_config = pathlib.Path(f"esp-idf-config/sdkconfig-ble.defaults") + sdkconfigs.append(ble_config) + board_config = pathlib.Path(f"boards/{board}/sdkconfig") + # Don't include the board file in cp defaults. The board may have custom + # overrides. + + cp_kconfig_defaults = kconfiglib.Kconfig(kconfig_path) + for default_file in sdkconfigs: + cp_kconfig_defaults.load_config(default_file, replace=False) board_settings = [] last_board_group = None - flash_settings = [] - last_flash_group = None + flash_size_settings = [] + last_flash_size_group = None + flash_mode_settings = [] + flash_freq_settings = [] + psram_settings = [] + last_psram_group = None + psram_size_settings = [] + psram_mode_settings = [] + psram_freq_settings = [] opt_settings = [] last_opt_group = None target_settings = [] @@ -151,58 +270,231 @@ def update(debug, board, update_all): last_ble_group = None default_settings = [] last_default_group = None + + target_kconfig_snippets = set() + target_symbols = set() + current_group = [] - for line in input_config.read_text().split("\n"): - # Normalize the deprecated section labels. - if line == "# End of deprecated options": - line = "# end of Deprecated options for backward compatibility" - if ( - line.startswith("# ") - and "CONFIG_" not in line - and "DO NOT EDIT" not in line - and "Project Configuration" not in line - and len(line) > 3 - ): - if line.startswith("# end of"): - current_group.pop() + + for sym in kconfig.unique_defined_syms: + sym._visited = False + + # This merges the normal `write_config`, `write_min_config` and CP settings to split into + # different files. + pending_nodes = [kconfig.top_node] + i = 0 + while pending_nodes: + node = pending_nodes.pop() + if node is None: + current_group.pop() + continue + + if node.item is kconfiglib.MENU: + if node.prompt: + print(" " * len(current_group), i, node.prompt[0]) + i += 1 + if node.next: + pending_nodes.append(node.next) + + # if i > 300: + # break + + # We have a configuration item. + item = node.item + if isinstance(item, kconfiglib.Symbol): + if item._visited: + continue + item._visited = True + + config_string = item.config_string.strip() + if not config_string: + cp_sym = cp_kconfig_defaults.syms[item.name] + if cp_sym.str_value == "n": + config_string = f"# CONFIG_{item.name} is not set" + else: + continue + + if node.list: + pending_nodes.append(node.list) + + matches_cp_default = cp_kconfig_defaults.syms[item.name].str_value == item.str_value + matches_esp_default = sym_default(item) + + print_debug = not matches_esp_default or (not update_all and not matches_cp_default) + if print_debug: + print(" " * len(current_group), i, config_string.strip()) + + # Some files are `rsource`d into another kconfig with $IDF_TARGET as + # part of the path. kconfiglib doesn't show this as a reference so + # we have to look ourselves. + target_reference = target in item.name_and_loc + if target_reference: + loc = item.name_and_loc.split("defined at ")[1].split(":")[0].replace(target, "*") + if loc not in target_kconfig_snippets: + differing_keys = set() + shared_keys = {} + first = True + for path in pathlib.Path(".").glob(loc): + kc = kconfiglib.Kconfig(path) + all_file_syms = set() + for sym in kc.unique_defined_syms: + all_file_syms.add(sym) + if sym.name in differing_keys: + continue + if first: + shared_keys[sym.name] = sym.str_value + elif ( + sym.name not in shared_keys + or shared_keys[sym.name] != sym.str_value + ): + differing_keys.add(sym.name) + if sym.name in shared_keys: + del shared_keys[sym.name] + # Any settings missing from a file are *not* shared. + shared_syms = set(shared_keys.keys()) + for missing in shared_syms - all_file_syms: + differing_keys.add(missing) + del shared_keys[missing] + first = False + target_kconfig_snippets.add(loc) + target_symbols = target_symbols.union(differing_keys) + + # kconfig settings can be set by others. item.referenced doesn't + # know this. So we collect all things that reference this using + # rev_dep. + all_references = set(item.referenced) + to_unpack = [item.rev_dep] + while to_unpack: + rdep = to_unpack.pop() + if isinstance(rdep, tuple): + to_unpack.extend(rdep) + elif isinstance(rdep, int): + # skip logic + pass + else: + all_references.add(rdep) + all_references.update(rdep.referenced) + psram_reference = False + for referenced in all_references: + if referenced.name.startswith("IDF_TARGET"): + target_reference = True + if referenced.name in target_symbols: + # Implicit target symbols + target_reference = True + if referenced.name == "SPIRAM": + psram_reference = True + + if (not update_all and not matches_cp_default) or ( + update_all + and matches_group(config_string, BOARD_SETTINGS) + and not matches_esp_default + ): + print(" " * (len(current_group) + 1), "board") + last_board_group = add_group(board_settings, last_board_group, current_group) + board_settings.append(config_string) + elif update_all: + target_setting = target_reference or matches_group(config_string, TARGET_SETTINGS) + if matches_group(config_string, FLASH_SIZE_SETTINGS): + print(" " * (len(current_group) + 1), "flash size") + last_flash_size_group = add_group( + flash_size_settings, last_flash_size_group, current_group + ) + flash_size_settings.append(config_string) + elif matches_group(config_string, FLASH_MODE_SETTINGS): + print(" " * (len(current_group) + 1), "flash mode") + flash_mode_settings.append(config_string) + elif matches_group(config_string, FLASH_FREQ_SETTINGS): + print(" " * (len(current_group) + 1), "flash freq") + flash_freq_settings.append(config_string) + elif matches_group(config_string, PSRAM_SIZE_SETTINGS): + print(" " * (len(current_group) + 1), "psram size") + psram_size_settings.append(config_string) + elif matches_group(config_string, PSRAM_MODE_SETTINGS): + print(" " * (len(current_group) + 1), "psram mode") + psram_mode_settings.append(config_string) + elif ( + matches_group(config_string, PSRAM_FREQ_SETTINGS) + and "26M" not in config_string + and "20M" not in config_string + ): + # The ESP32S2 has two frequencies (20M and 26M) that aren't on the S3 or ESP32. + # So, put those in target settings. + print(" " * (len(current_group) + 1), "psram freq") + psram_freq_settings.append(config_string) + elif matches_esp_default: + if print_debug: + print(" " * (len(current_group) + 1), "default") + # Always document the above settings. Settings below should + # be non-default. + pass + elif matches_group(config_string, PSRAM_SETTINGS) or psram_reference: + print(" " * (len(current_group) + 1), "psram shared") + last_psram_group = add_group(psram_settings, last_psram_group, current_group) + psram_settings.append(config_string) + elif matches_group(config_string, OPT_SETTINGS): + print(" " * (len(current_group) + 1), "opt") + last_opt_group = add_group(opt_settings, last_opt_group, current_group) + opt_settings.append(config_string) + elif target_setting: + print(" " * (len(current_group) + 1), "target") + last_target_group = add_group( + target_settings, last_target_group, current_group + ) + target_settings.append(config_string) + elif matches_group(config_string, BLE_SETTINGS): + print(" " * (len(current_group) + 1), "ble") + last_ble_group = add_group(ble_settings, last_ble_group, current_group) + ble_settings.append(config_string) + else: + print(" " * (len(current_group) + 1), "all") + last_default_group = add_group( + default_settings, last_default_group, current_group + ) + default_settings.append(config_string) + + else: + if item is kconfiglib.COMMENT: + print("comment", repr(item)) + elif item is kconfiglib.MENU: + if node.list: + current_group.append(node.prompt[0]) + pending_nodes.append(None) + pending_nodes.append(node.list) + elif isinstance(item, kconfiglib.Choice): + # Choices are made up of individual symbols that we need to check. + pending_nodes.append(node.list) else: - current_group.append(line[2:]) - elif (not update_all and line not in defaults) or ( - update_all and matches_group(line, BOARD_SETTINGS) - ): - last_board_group = add_group(board_settings, last_board_group, current_group) - board_settings.append(line) - elif update_all: - if matches_group(line, OPT_SETTINGS): - last_opt_group = add_group(opt_settings, last_opt_group, current_group) - opt_settings.append(line) - elif matches_group(line, FLASH_SETTINGS): - last_flash_group = add_group(flash_settings, last_flash_group, current_group) - flash_settings.append(line) - elif matches_group(line, TARGET_SETTINGS): - last_target_group = add_group(target_settings, last_target_group, current_group) - target_settings.append(line) - elif matches_group(line, BLE_SETTINGS): - last_ble_group = add_group(ble_settings, last_ble_group, current_group) - ble_settings.append(line) - elif "CONFIG_" in line: - last_default_group = add_group(default_settings, last_default_group, current_group) - default_settings.append(line) + print("unknown", repr(item)) add_group(board_settings, last_board_group, current_group) add_group(opt_settings, last_opt_group, current_group) - add_group(flash_settings, last_flash_group, current_group) + add_group(flash_size_settings, last_flash_size_group, current_group) + add_group(psram_settings, last_psram_group, current_group) add_group(target_settings, last_target_group, current_group) add_group(ble_settings, last_ble_group, current_group) add_group(default_settings, last_default_group, current_group) board_config.write_text("\n".join(board_settings)) if update_all: - flash_config.write_text("\n".join(flash_settings)) + # Add empty strings to get trailing newlines + flash_mode_settings.append("") + flash_freq_settings.append("") + flash_size_config.write_text("\n".join(flash_size_settings)) + flash_mode_config.write_text("\n".join(flash_mode_settings)) + flash_freq_config.write_text("\n".join(flash_freq_settings)) + if psram_size != "0": + psram_size_settings.append("") + psram_mode_settings.append("") + psram_freq_settings.append("") + psram_config.write_text("\n".join(psram_settings)) + psram_size_config.write_text("\n".join(psram_size_settings)) + psram_mode_config.write_text("\n".join(psram_mode_settings)) + psram_freq_config.write_text("\n".join(psram_freq_settings)) opt_config.write_text("\n".join(opt_settings)) default_config.write_text("\n".join(default_settings)) target_config.write_text("\n".join(target_settings)) - ble_config.write_text("\n".join(ble_settings)) + if ble_settings: + ble_config.write_text("\n".join(ble_settings)) if __name__ == "__main__": diff --git a/ports/nrf/common-hal/busio/UART.c b/ports/nrf/common-hal/busio/UART.c index 5c44ab16d5..5bc0854fe7 100644 --- a/ports/nrf/common-hal/busio/UART.c +++ b/ports/nrf/common-hal/busio/UART.c @@ -260,15 +260,8 @@ bool common_hal_busio_uart_deinited(busio_uart_obj_t *self) { } void common_hal_busio_uart_deinit(busio_uart_obj_t *self) { - volatile uint32_t *power_cycle = (void *)(self->uarte->p_reg) + 0xFFC; if (!common_hal_busio_uart_deinited(self)) { - nrfx_uarte_rx_abort(self->uarte); - nrfx_uarte_tx_abort(self->uarte); nrfx_uarte_uninit(self->uarte); - // power cycle the peripheral as per https://devzone.nordicsemi.com/f/nordic-q-a/26030/how-to-reach-nrf52840-uarte-current-supply-specification/102605#102605 - *power_cycle = 0; - *power_cycle; - *power_cycle = 1; reset_pin_number(self->tx_pin_number); reset_pin_number(self->rx_pin_number); reset_pin_number(self->rts_pin_number); diff --git a/ports/nrf/common-hal/memorymap/AddressRange.c b/ports/nrf/common-hal/memorymap/AddressRange.c index eaef202d0d..b829cbb253 100644 --- a/ports/nrf/common-hal/memorymap/AddressRange.c +++ b/ports/nrf/common-hal/memorymap/AddressRange.c @@ -90,13 +90,13 @@ void common_hal_memorymap_addressrange_construct(memorymap_addressrange_obj_t *s self->len = length; } -uint32_t common_hal_memorymap_addressrange_get_length(const memorymap_addressrange_obj_t *self) { +size_t common_hal_memorymap_addressrange_get_length(const memorymap_addressrange_obj_t *self) { return self->len; } -bool common_hal_memorymap_addressrange_set_bytes(const memorymap_addressrange_obj_t *self, - uint32_t start_index, uint8_t *values, uint32_t len) { +void common_hal_memorymap_addressrange_set_bytes(const memorymap_addressrange_obj_t *self, + size_t start_index, uint8_t *values, size_t len) { uint8_t *address = self->start_address + start_index; #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wcast-align" @@ -112,12 +112,10 @@ bool common_hal_memorymap_addressrange_set_bytes(const memorymap_addressrange_ob memcpy(address, values, len); } #pragma GCC diagnostic pop - - return true; } void common_hal_memorymap_addressrange_get_bytes(const memorymap_addressrange_obj_t *self, - uint32_t start_index, uint32_t len, uint8_t *values) { + size_t start_index, size_t len, uint8_t *values) { uint8_t *address = self->start_address + start_index; #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wcast-align" diff --git a/ports/raspberrypi/Makefile b/ports/raspberrypi/Makefile index 1a9cd35f55..5a021494f6 100644 --- a/ports/raspberrypi/Makefile +++ b/ports/raspberrypi/Makefile @@ -358,7 +358,7 @@ CFLAGS += \ -isystem $(TOP)/lib/mbedtls/include \ -DMBEDTLS_CONFIG_FILE='"mbedtls/mbedtls_config.h"' \ -$(BUILD)/x509_crt_bundle.S: $(TOP)/lib/certificates/nina-fw/data/roots.pem $(TOP)/tools/gen_crt_bundle.py +$(BUILD)/x509_crt_bundle.S: $(TOP)/lib/certificates/data/roots.pem $(TOP)/tools/gen_crt_bundle.py $(Q)$(PYTHON) $(TOP)/tools/gen_crt_bundle.py -i $< -o $@ --asm OBJ_MBEDTLS := $(BUILD)/x509_crt_bundle.o $(patsubst %.c,$(BUILD)/%.o,$(SRC_MBEDTLS))): CFLAGS += -Wno-suggest-attribute=format diff --git a/ports/raspberrypi/common-hal/memorymap/AddressRange.c b/ports/raspberrypi/common-hal/memorymap/AddressRange.c new file mode 100644 index 0000000000..185be10ab4 --- /dev/null +++ b/ports/raspberrypi/common-hal/memorymap/AddressRange.c @@ -0,0 +1,136 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2020 microDev + * Copyright (c) 2023 Bob Abeles + * + * 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 + +#include "shared-bindings/memorymap/AddressRange.h" + +#include "py/runtime.h" + +#include "hardware/regs/addressmap.h" + +// RP2 address map ranges, must be arranged in order by ascending start address +addressmap_rp2_range_t rp2_ranges[] = { + {(uint8_t *)ROM_BASE, 0x00004000, ROM}, // boot ROM + {(uint8_t *)XIP_BASE, 0x00100000, XIP}, // XIP normal cache operation + {(uint8_t *)XIP_NOALLOC_BASE, 0x00100000, XIP}, // XIP check for hit, no update on miss + {(uint8_t *)XIP_NOCACHE_BASE, 0x00100000, XIP}, // XIP don't check for hit, no update on miss + {(uint8_t *)XIP_NOCACHE_NOALLOC_BASE, 0x00100000, XIP}, // XIP bypass cache completely + {(uint8_t *)XIP_CTRL_BASE, 0x00004000, IO}, // XIP control registers + {(uint8_t *)XIP_SRAM_BASE, 0x00004000, SRAM}, // XIP SRAM 16KB XIP cache + {(uint8_t *)XIP_SSI_BASE, 0x00004000, IO}, // XIP SSI registers + {(uint8_t *)SRAM_BASE, 0x00042000, SRAM}, // SRAM 256KB striped plus 16KB contiguous + {(uint8_t *)SRAM0_BASE, 0x00040000, SRAM}, // SRAM0 to SRAM3 256KB non-striped + {(uint8_t *)SYSINFO_BASE, 0x00070000, IO}, // APB peripherals + {(uint8_t *)DMA_BASE, 0x00004000, IO}, // DMA registers + {(uint8_t *)USBCTRL_DPRAM_BASE, 0x00001000, SRAM}, // USB DPSRAM 4KB + {(uint8_t *)USBCTRL_REGS_BASE, 0x00004000, IO}, // USB registers + {(uint8_t *)PIO0_BASE, 0x00004000, IO}, // PIO0 registers + {(uint8_t *)PIO1_BASE, 0x00004000, IO}, // PIO1 registers + {(uint8_t *)SIO_BASE, 0x00001000, IO}, // SIO registers, no aliases + {(uint8_t *)PPB_BASE, 0x00004000, IO} // PPB registers +}; + +void common_hal_memorymap_addressrange_construct(memorymap_addressrange_obj_t *self, + uint8_t *start_address, size_t length) { + for (size_t i = 0; i < MP_ARRAY_SIZE(rp2_ranges); i++) { + if (start_address <= rp2_ranges[i].start_address) { + uint8_t *range_end_address = rp2_ranges[i].start_address + rp2_ranges[i].len - 1; + uint8_t *end_address = start_address + length - 1; + if (start_address > range_end_address || end_address > range_end_address) { + break; + } + self->start_address = start_address; + self->len = length; + self->type = rp2_ranges[i].type; + return; + } + } + + mp_raise_ValueError(translate("Address range not allowed")); +} + +size_t common_hal_memorymap_addressrange_get_length(const memorymap_addressrange_obj_t *self) { + return self->len; +} + +void common_hal_memorymap_addressrange_set_bytes(const memorymap_addressrange_obj_t *self, + size_t start_index, uint8_t *values, size_t len) { + uint8_t *dest_addr = self->start_address + start_index; + switch (self->type) { + case SRAM: + // Writes to SRAM may be arbitrary length and alignment. We use memcpy() which + // may optimize aligned writes depending on CIRCUITPY_FULL_BUILD of the CP build. + memcpy(dest_addr, values, len); + break; + case IO: + if ((size_t)dest_addr & 0x03 || len & 0x03) { + // Unaligned access or unaligned length not supported by RP2 for IO registers + mp_raise_RuntimeError(translate("Unable to access unaligned IO register")); + } else { + // Aligned access and length, use 32-bit writes + uint32_t *dest_addr32 = (uint32_t *)dest_addr; + size_t access_count = len >> 2; + for (size_t i = 0; i < access_count; i++) { + *dest_addr32++ = ((uint32_t *)values)[i]; + } + } + break; + case XIP: + case ROM: + // XIP and ROM are read-only + mp_raise_RuntimeError(translate("Unable to write to read-only memory")); + break; + } +} + +void common_hal_memorymap_addressrange_get_bytes(const memorymap_addressrange_obj_t *self, + size_t start_index, size_t len, uint8_t *values) { + uint8_t *src_addr = self->start_address + start_index; + switch (self->type) { + case SRAM: + case XIP: + case ROM: + // Reads from these sources may be arbitrary length and alignment. We use memcpy() + // which may optimize aligned writes depending on CIRCUITPY_FULL_BUILD of the CP build. + memcpy(values, src_addr, len); + break; + case IO: + if ((size_t)src_addr & 0x03 || len & 0x03) { + // Unaligned access or unaligned length not supported by RP2 for IO registers + mp_raise_RuntimeError(translate("Unable to access unaligned IO register")); + } else { + // Aligned access and length, use 32-bit reads + uint32_t *src_addr32 = (uint32_t *)src_addr; + size_t access_count = len >> 2; + for (size_t i = 0; i < access_count; i++) { + ((uint32_t *)values)[i] = *src_addr32++; + } + } + break; + } +} diff --git a/ports/raspberrypi/common-hal/memorymap/AddressRange.h b/ports/raspberrypi/common-hal/memorymap/AddressRange.h new file mode 100644 index 0000000000..0e929c4305 --- /dev/null +++ b/ports/raspberrypi/common-hal/memorymap/AddressRange.h @@ -0,0 +1,49 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2020 microDev + * Copyright (c) 2023 Bob Abeles + * + * 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_MEMORYMAP_ADDRESSRANGE_H +#define MICROPY_INCLUDED_RASPBERRYPI_COMMON_HAL_MEMORYMAP_ADDRESSRANGE_H + +#include "py/obj.h" + +// depending on the section memory type, different access methods and rules apply +typedef enum { SRAM, ROM, XIP, IO } memorymap_rp2_section_t; + +typedef struct { + mp_obj_base_t base; + uint8_t *start_address; + size_t len; + memorymap_rp2_section_t type; +} memorymap_addressrange_obj_t; + +typedef struct { + uint8_t *start_address; + size_t len; + memorymap_rp2_section_t type; +} addressmap_rp2_range_t; + +#endif // MICROPY_INCLUDED_RASPBERRYPI_COMMON_HAL_MEMORYMAP_ADDRESSRANGE_H diff --git a/ports/raspberrypi/common-hal/memorymap/__init__.c b/ports/raspberrypi/common-hal/memorymap/__init__.c new file mode 100644 index 0000000000..c15b17f451 --- /dev/null +++ b/ports/raspberrypi/common-hal/memorymap/__init__.c @@ -0,0 +1 @@ +// No memorymap module functions. diff --git a/ports/raspberrypi/mpconfigport.mk b/ports/raspberrypi/mpconfigport.mk index fdc2b0922a..d5e7734be1 100644 --- a/ports/raspberrypi/mpconfigport.mk +++ b/ports/raspberrypi/mpconfigport.mk @@ -15,6 +15,7 @@ CIRCUITPY_FULL_BUILD ?= 1 CIRCUITPY_AUDIOMP3 ?= 1 CIRCUITPY_BITOPS ?= 1 CIRCUITPY_IMAGECAPTURE ?= 1 +CIRCUITPY_MEMORYMAP ?= 1 CIRCUITPY_PWMIO ?= 1 CIRCUITPY_RGBMATRIX ?= $(CIRCUITPY_DISPLAYIO) CIRCUITPY_ROTARYIO ?= 1 diff --git a/py/argcheck.c b/py/argcheck.c index c3bde804d4..76c84e83b0 100644 --- a/py/argcheck.c +++ b/py/argcheck.c @@ -133,7 +133,28 @@ void mp_arg_parse_all(size_t n_pos, const mp_obj_t *pos, mp_map_t *kws, size_t n #if MICROPY_ERROR_REPORTING <= MICROPY_ERROR_REPORTING_TERSE mp_arg_error_terse_mismatch(); #else - // TODO better error message + #if CIRCUITPY_FULL_BUILD + mp_map_elem_t *elem = kws->table; + size_t alloc = kws->alloc; + for (size_t i = 0; i < alloc; i++) { + mp_obj_t key = elem[i].key; + if (key == MP_OBJ_NULL) { + continue; + } + bool seen = false; + for (size_t j = n_pos; j < n_allowed; j++) { + if (mp_obj_equal(MP_OBJ_NEW_QSTR(allowed[j].qst), key)) { + seen = true; + break; + } + } + if (!seen) { + mp_raise_msg_varg(&mp_type_TypeError, + MP_ERROR_TEXT("unexpected keyword argument '%q'"), mp_obj_str_get_qstr(key)); + } + } + #endif + // (for the !FULL_BUILD case, and as a fallthrough for the FULL_BUILD case, even though it SHOULD be unreachable in that case) mp_raise_TypeError(MP_ERROR_TEXT("extra keyword arguments given")); #endif } diff --git a/py/circuitpy_defns.mk b/py/circuitpy_defns.mk index 8186d24b2a..c819d46db8 100644 --- a/py/circuitpy_defns.mk +++ b/py/circuitpy_defns.mk @@ -296,6 +296,9 @@ endif ifeq ($(CIRCUITPY_RGBMATRIX),1) SRC_PATTERNS += rgbmatrix/% endif +ifeq ($(CIRCUITPY_DOTCLOCKFRAMEBUFFER),1) +SRC_PATTERNS += dotclockframebuffer/% +endif ifeq ($(CIRCUITPY_RP2PIO),1) SRC_PATTERNS += rp2pio/% endif @@ -435,6 +438,8 @@ SRC_COMMON_HAL_ALL = \ countio/__init__.c \ digitalio/DigitalInOut.c \ digitalio/__init__.c \ + dotclockframebuffer/DotClockFramebuffer.c \ + dotclockframebuffer/__init__.c \ dualbank/__init__.c \ frequencyio/FrequencyIn.c \ frequencyio/__init__.c \ @@ -598,6 +603,7 @@ SRC_SHARED_MODULE_ALL = \ displayio/TileGrid.c \ displayio/area.c \ displayio/__init__.c \ + dotclockframebuffer/__init__.c \ floppyio/__init__.c \ fontio/BuiltinFont.c \ fontio/__init__.c \ diff --git a/py/circuitpy_mpconfig.mk b/py/circuitpy_mpconfig.mk index 5ba3f8640b..e15383cc5f 100644 --- a/py/circuitpy_mpconfig.mk +++ b/py/circuitpy_mpconfig.mk @@ -206,6 +206,11 @@ CIRCUITPY_PARALLELDISPLAY = 0 endif CFLAGS += -DCIRCUITPY_PARALLELDISPLAY=$(CIRCUITPY_PARALLELDISPLAY) +CIRCUITPY_DOTCLOCKFRAMEBUFFER ?= 0 +CFLAGS += -DCIRCUITPY_DOTCLOCKFRAMEBUFFER=$(CIRCUITPY_DOTCLOCKFRAMEBUFFER) +CIRCUITPY_DOTCLOCKFRAMEBUFFER_USES_SUPERVISOR_ALLOCATION ?= 1 +CFLAGS += -DCIRCUITPY_DOTCLOCKFRAMEBUFFER_USES_SUPERVISOR_ALLOCATION=$(CIRCUITPY_DOTCLOCKFRAMEBUFFER_USES_SUPERVISOR_ALLOCATION) + # bitmaptools and framebufferio rely on displayio CIRCUITPY_BITMAPTOOLS ?= $(call enable-if-all,$(CIRCUITPY_FULL_BUILD) $(CIRCUITPY_DISPLAYIO)) CIRCUITPY_FRAMEBUFFERIO ?= $(call enable-if-all,$(CIRCUITPY_FULL_BUILD) $(CIRCUITPY_DISPLAYIO)) @@ -238,6 +243,9 @@ CFLAGS += -DCIRCUITPY_ESPNOW=$(CIRCUITPY_ESPNOW) CIRCUITPY_ESPULP ?= 0 CFLAGS += -DCIRCUITPY_ESPULP=$(CIRCUITPY_ESPULP) +CIRCUITPY_ESP_USB_SERIAL_JTAG ?= 0 +CFLAGS += -DCIRCUITPY_ESP_USB_SERIAL_JTAG=$(CIRCUITPY_ESP_USB_SERIAL_JTAG) + CIRCUITPY_ESPCAMERA ?= 0 CFLAGS += -DCIRCUITPY_ESPCAMERA=$(CIRCUITPY_ESPCAMERA) diff --git a/py/makeqstrdefs.py b/py/makeqstrdefs.py index adf6195389..178149c688 100644 --- a/py/makeqstrdefs.py +++ b/py/makeqstrdefs.py @@ -94,7 +94,10 @@ def preprocess(): def pp(flags): def run(files): - return subprocess.check_output(args.pp + flags + files) + completed = subprocess.run(args.pp + flags + files, stdout=subprocess.PIPE) + if completed.returncode != 0: + raise RuntimeError() + return completed.stdout return run diff --git a/requirements-dev.txt b/requirements-dev.txt index 5efa084652..7d5766ec5a 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -25,7 +25,8 @@ intelhex pyelftools # for mbedtls certificate store -cryptography +# version limit due to espressif +cryptography<36.1,>=2.1.4 # for web workflow minify minify_html diff --git a/shared-bindings/dotclockframebuffer/DotClockFramebuffer.c b/shared-bindings/dotclockframebuffer/DotClockFramebuffer.c new file mode 100644 index 0000000000..6799618efa --- /dev/null +++ b/shared-bindings/dotclockframebuffer/DotClockFramebuffer.c @@ -0,0 +1,395 @@ +/* + * This file is part of the Micro Python project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2023 Jeff Epler 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/dotclockframebuffer/DotClockFramebuffer.h" + +#include "py/binary.h" +#include "py/objarray.h" +#include "py/objproperty.h" +#include "py/runtime.h" +#include "shared-bindings/microcontroller/Pin.h" +#include "shared-bindings/util.h" +#include "shared-module/displayio/__init__.h" +#include "supervisor/shared/translate/translate.h" + +//| class DotClockFramebuffer: +//| """Manage updating a 'dot-clock' framebuffer in the background while Python code runs. +//| It doesn't handle display initialization.""" +//| +//| def __init__( +//| self, +//| *, +//| de: microcontroller.Pin, +//| vsync: microcontroller.Pin, +//| hsync: microcontroller.Pin, +//| dclk: microcontroller.Pin, +//| red: Tuple[microcontroller.Pin], +//| green: Tuple[microcontroller.Pin], +//| blue: Tuple[microcontroller.Pin], +//| frequency: int, +//| width: int, +//| height: int, +//| hsync_pulse_width: int, +//| hsync_back_porch: int, +//| hsync_front_porch: int, +//| hsync_idle_low: bool, +//| vsync_back_porch: int, +//| vsync_front_porch: int, +//| vsync_idle_low: bool, +//| de_idle_high: bool, +//| pclk_active_high: bool, +//| pclk_idle_high: bool, +//| overscan_left: int = 0, +//| ) -> None: +//| """Create a DotClockFramebuffer object associated with the given pins. +//| +//| The pins are then in use by the display until `displayio.release_displays()` +//| is called even after a reload. (It does this so CircuitPython can use the display after your +//| code is done.) So, the first time you initialize a display bus in code.py you should call +//| :py:func:`displayio.release_displays` first, otherwise it will error after the first code.py run. +//| +//| When a board has dedicated dot clock framebuffer pins and/or timings, they are intended to be used in the constructor with ``**`` dictionary unpacking like so: +//| ``DotClockFramebuffer(**board.TFT_PINS, **board.TFT_TIMINGS)`` +//| +//| On Espressif-family microcontrollers, this driver requires that the +//| ``CIRCUITPY_RESERVED_PSRAM`` in ``settings.toml`` be large enough to hold the +//| framebuffer. Generally, boards with built-in displays or display connectors +//| will have a default setting that is large enough for typical use. If the +//| constructor raises a MemoryError or an IDFError, this probably indicates the +//| setting is too small and should be increased. +//| +//| TFT connection parameters: +//| +//| :param microcontroller.Pin de: The "data enable" input to the display +//| :param microcontroller.Pin vsync: The "vertical sync" input to the display +//| :param microcontroller.Pin hsync: The "horizontal sync" input to the display +//| :param microcontroller.Pin dclk: The "data clock" input to the display +//| :param ~tuple red: The red data pins, most significant pin first. +//| :param ~tuple green: The green data pins, most significant pin first. +//| :param ~tuple blue: The blue data pins, most significant pin first. +//| +//| TFT timing parameters: +//| +//| :param int frequency: The requested data clock frequency in Hz. +//| :param int width: The visible width of the display, in pixels +//| :param int height: The visible height of the display, in pixels +//| :param int hsync_pulse_width: Horizontal sync width in pixels +//| :param int hsync_back_porch: Horizontal back porch, number of pixels between hsync and start of line active data +//| :param int hsync_front_porch: Horizontal front porch, number of pixels between the end of active data and the next hsync +//| :param int vsync_back_porch: Vertical back porch, number of lines between vsync and start of frame +//| :param int vsync_front_porch: Vertical front porch, number of lines between the end of frame and the next vsync +//| :param bool hsync_idle_low: True if the hsync signal is low in IDLE state +//| :param bool vsync_idle_low: True if the vsync signal is low in IDLE state +//| :param bool de_idle_high: True if the de signal is high in IDLE state +//| :param bool pclk_active_high: True if the display data is clocked out at the rising edge of dclk +//| :param bool pclk_idle_high: True if the dclk stays at high level in IDLE phase +//| +//| :param int overscan_left: Allocate additional non-visible columns left of the first display column +//| """ +//| #:param int overscan_top: Allocate additional non-visible rows above the first display row +//| #:param int overscan_right: Allocate additional non-visible columns right of the last display column +//| #:param int overscan_bottom: Allocate additional non-visible rows below the last display row +//| ... +STATIC mp_obj_t dotclockframebuffer_framebuffer_make_new(const mp_obj_type_t *type, size_t n_args, size_t n_kw, const mp_obj_t *all_args) { + enum { ARG_de, ARG_vsync, ARG_hsync, ARG_dclk, ARG_red, ARG_green, ARG_blue, + ARG_frequency, ARG_width, ARG_height, + ARG_hsync_pulse_width, ARG_hsync_back_porch, ARG_hsync_front_porch, ARG_hsync_idle_low, + ARG_vsync_pulse_width, ARG_vsync_back_porch, ARG_vsync_front_porch, ARG_vsync_idle_low, + ARG_de_idle_high, ARG_pclk_active_high, ARG_pclk_idle_high, + ARG_overscan_left}; + + static const mp_arg_t allowed_args[] = { + { MP_QSTR_de, MP_ARG_OBJ | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_obj = mp_const_none } }, + { MP_QSTR_vsync, MP_ARG_OBJ | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_obj = mp_const_none } }, + { MP_QSTR_hsync, MP_ARG_OBJ | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_obj = mp_const_none } }, + { MP_QSTR_dclk, MP_ARG_OBJ | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_obj = mp_const_none } }, + { MP_QSTR_red, MP_ARG_OBJ | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_obj = mp_const_none } }, + { MP_QSTR_green, MP_ARG_OBJ | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_obj = mp_const_none } }, + { MP_QSTR_blue, MP_ARG_OBJ | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_obj = mp_const_none } }, + + { MP_QSTR_frequency, MP_ARG_INT | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_int = 0 } }, + { MP_QSTR_width, MP_ARG_INT | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_int = 0 } }, + { MP_QSTR_height, MP_ARG_INT | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_int = 0 } }, + + { MP_QSTR_hsync_pulse_width, MP_ARG_INT | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_int = 0 } }, + { MP_QSTR_hsync_back_porch, MP_ARG_INT | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_int = 0 } }, + { MP_QSTR_hsync_front_porch, MP_ARG_INT | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_int = 0 } }, + { MP_QSTR_hsync_idle_low, MP_ARG_BOOL | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_bool = false } }, + + { MP_QSTR_vsync_pulse_width, MP_ARG_INT | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_int = 0 } }, + { MP_QSTR_vsync_back_porch, MP_ARG_INT | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_int = 0 } }, + { MP_QSTR_vsync_front_porch, MP_ARG_INT | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_int = 0 } }, + { MP_QSTR_vsync_idle_low, MP_ARG_BOOL | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_bool = false } }, + + { MP_QSTR_de_idle_high, MP_ARG_BOOL | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_bool = false } }, + { MP_QSTR_pclk_active_high, MP_ARG_BOOL | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_bool = false } }, + { MP_QSTR_pclk_idle_high, MP_ARG_BOOL | MP_ARG_KW_ONLY | MP_ARG_REQUIRED, {.u_bool = false } }, + + { MP_QSTR_overscan_left, MP_ARG_INT | MP_ARG_KW_ONLY, {.u_int = 0 } }, + }; + + mp_arg_val_t args[MP_ARRAY_SIZE(allowed_args)]; + mp_arg_parse_all_kw_array(n_args, n_kw, all_args, MP_ARRAY_SIZE(allowed_args), allowed_args, args); + + const mcu_pin_obj_t *de = validate_obj_is_free_pin(args[ARG_de].u_obj, MP_QSTR_de); + const mcu_pin_obj_t *vsync = validate_obj_is_free_pin(args[ARG_vsync].u_obj, MP_QSTR_vsync); + const mcu_pin_obj_t *hsync = validate_obj_is_free_pin(args[ARG_hsync].u_obj, MP_QSTR_hsync); + const mcu_pin_obj_t *dclk = validate_obj_is_free_pin(args[ARG_dclk].u_obj, MP_QSTR_dclk); + + uint8_t num_red, num_green, num_blue; + const mcu_pin_obj_t *red_pins[8], *green_pins[8], *blue_pins[8]; + + validate_list_is_free_pins(MP_QSTR_red, red_pins, (mp_int_t)MP_ARRAY_SIZE(red_pins), args[ARG_red].u_obj, &num_red); + validate_list_is_free_pins(MP_QSTR_green, green_pins, (mp_int_t)MP_ARRAY_SIZE(green_pins), args[ARG_green].u_obj, &num_green); + validate_list_is_free_pins(MP_QSTR_blue, blue_pins, (mp_int_t)MP_ARRAY_SIZE(blue_pins), args[ARG_blue].u_obj, &num_blue); + + dotclockframebuffer_framebuffer_obj_t *self = &allocate_display_bus_or_raise()->dotclock; + self->base.type = &dotclockframebuffer_framebuffer_type; + + common_hal_dotclockframebuffer_framebuffer_construct( + self, de, vsync, hsync, dclk, red_pins, num_red, green_pins, num_green, blue_pins, num_blue, + args[ARG_frequency].u_int, args[ARG_width].u_int, args[ARG_height].u_int, + args[ARG_hsync_pulse_width].u_int, args[ARG_hsync_back_porch].u_int, args[ARG_hsync_front_porch].u_int, args[ARG_hsync_idle_low].u_bool, + args[ARG_vsync_pulse_width].u_int, args[ARG_vsync_back_porch].u_int, args[ARG_vsync_front_porch].u_int, args[ARG_vsync_idle_low].u_bool, + args[ARG_de_idle_high].u_bool, + args[ARG_pclk_active_high].u_bool, + args[ARG_pclk_idle_high].u_bool, + args[ARG_overscan_left].u_int + ); + + return self; +} + +static void check_for_deinit(dotclockframebuffer_framebuffer_obj_t *self) { + if (common_hal_dotclockframebuffer_framebuffer_deinitialized(self)) { + raise_deinited_error(); + } +} + +//| def refresh(self) -> None: +//| """Transmits the color data in the buffer to the pixels so that +//| they are shown. +//| +//| If this function is not called, the results are unpredictable; updates may be partially shown. +//| """ +//| ... +STATIC mp_obj_t dotclockframebuffer_framebuffer_refresh(mp_obj_t self_in) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + check_for_deinit(self); + common_hal_dotclockframebuffer_framebuffer_refresh(self); + return mp_const_none; +} +MP_DEFINE_CONST_FUN_OBJ_1(dotclockframebuffer_framebuffer_refresh_obj, dotclockframebuffer_framebuffer_refresh); + + +//| refresh_rate: float +//| """The pixel refresh rate of the display, in Hz""" +STATIC mp_obj_t dotclockframebuffer_framebuffer_get_refresh_rate(mp_obj_t self_in) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + check_for_deinit(self); + return MP_OBJ_NEW_SMALL_INT(common_hal_dotclockframebuffer_framebuffer_get_refresh_rate(self)); +} +MP_DEFINE_CONST_FUN_OBJ_1(dotclockframebuffer_framebuffer_get_refresh_rate_obj, dotclockframebuffer_framebuffer_get_refresh_rate); +MP_PROPERTY_GETTER(dotclockframebuffer_framebuffer_refresh_rate_obj, + (mp_obj_t)&dotclockframebuffer_framebuffer_get_refresh_rate_obj); + +//| frequency: int +//| """The pixel frequency of the display, in Hz""" +STATIC mp_obj_t dotclockframebuffer_framebuffer_get_frequency(mp_obj_t self_in) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + check_for_deinit(self); + return MP_OBJ_NEW_SMALL_INT(common_hal_dotclockframebuffer_framebuffer_get_frequency(self)); +} +MP_DEFINE_CONST_FUN_OBJ_1(dotclockframebuffer_framebuffer_get_frequency_obj, dotclockframebuffer_framebuffer_get_frequency); +MP_PROPERTY_GETTER(dotclockframebuffer_framebuffer_frequency_obj, + (mp_obj_t)&dotclockframebuffer_framebuffer_get_frequency_obj); + +//| width: int +//| """The width of the display, in pixels""" +STATIC mp_obj_t dotclockframebuffer_framebuffer_get_width(mp_obj_t self_in) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + check_for_deinit(self); + return MP_OBJ_NEW_SMALL_INT(common_hal_dotclockframebuffer_framebuffer_get_width(self)); +} +MP_DEFINE_CONST_FUN_OBJ_1(dotclockframebuffer_framebuffer_get_width_obj, dotclockframebuffer_framebuffer_get_width); +MP_PROPERTY_GETTER(dotclockframebuffer_framebuffer_width_obj, + (mp_obj_t)&dotclockframebuffer_framebuffer_get_width_obj); + +//| height: int +//| """The height of the display, in pixels""" +//| +STATIC mp_obj_t dotclockframebuffer_framebuffer_get_height(mp_obj_t self_in) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + check_for_deinit(self); + return MP_OBJ_NEW_SMALL_INT(common_hal_dotclockframebuffer_framebuffer_get_height(self)); +} +MP_DEFINE_CONST_FUN_OBJ_1(dotclockframebuffer_framebuffer_get_height_obj, dotclockframebuffer_framebuffer_get_height); + +MP_PROPERTY_GETTER(dotclockframebuffer_framebuffer_height_obj, + (mp_obj_t)&dotclockframebuffer_framebuffer_get_height_obj); + +//| row_stride: int +//| """The row_stride of the display, in bytes +//| +//| Due to overscan or alignment requirements, the memory address for row N+1 may not be exactly ``2*width`` bytes after the memory address for row N. +//| This property gives the stride in **bytes**. +//| +//| On Espressif this value is **guaranteed** to be a multiple of the 2 (i.e., it is a whole number of pixels)""" +//| +STATIC mp_obj_t dotclockframebuffer_framebuffer_get_row_stride(mp_obj_t self_in) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + check_for_deinit(self); + return MP_OBJ_NEW_SMALL_INT(common_hal_dotclockframebuffer_framebuffer_get_row_stride(self)); +} +MP_DEFINE_CONST_FUN_OBJ_1(dotclockframebuffer_framebuffer_get_row_stride_obj, dotclockframebuffer_framebuffer_get_row_stride); + +MP_PROPERTY_GETTER(dotclockframebuffer_framebuffer_row_stride_obj, + (mp_obj_t)&dotclockframebuffer_framebuffer_get_row_stride_obj); + +//| first_pixel_offset: int +//| """The first_pixel_offset of the display, in bytes +//| +//| Due to overscan or alignment requirements, the memory address for row N+1 may not be exactly ``2*width`` bytes after the memory address for row N. +//| This property gives the stride in **bytes**. +//| +//| On Espressif this value is **guaranteed** to be a multiple of the 2 (i.e., it is a whole number of pixels)""" +//| +STATIC mp_obj_t dotclockframebuffer_framebuffer_get_first_pixel_offset(mp_obj_t self_in) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + check_for_deinit(self); + return MP_OBJ_NEW_SMALL_INT(common_hal_dotclockframebuffer_framebuffer_get_first_pixel_offset(self)); +} +MP_DEFINE_CONST_FUN_OBJ_1(dotclockframebuffer_framebuffer_get_first_pixel_offset_obj, dotclockframebuffer_framebuffer_get_first_pixel_offset); + +MP_PROPERTY_GETTER(dotclockframebuffer_framebuffer_first_pixel_offset_obj, + (mp_obj_t)&dotclockframebuffer_framebuffer_get_first_pixel_offset_obj); + +STATIC mp_int_t dotclockframebuffer_framebuffer_get_buffer(mp_obj_t self_in, mp_buffer_info_t *bufinfo, mp_uint_t flags) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + // a readonly framebuffer would be unusual but not impossible + if ((flags & MP_BUFFER_WRITE) && !(self->bufinfo.typecode & MP_OBJ_ARRAY_TYPECODE_FLAG_RW)) { + return 1; + } + *bufinfo = self->bufinfo; + bufinfo->typecode = 'H'; + return 0; +} + +// These version exists so that the prototype matches the protocol, +// avoiding a type cast that can hide errors +STATIC void dotclockframebuffer_framebuffer_swapbuffers(mp_obj_t self_in, uint8_t *dirty_row_bitmap) { + (void)dirty_row_bitmap; + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + common_hal_dotclockframebuffer_framebuffer_refresh(self); +} + +STATIC void dotclockframebuffer_framebuffer_deinit_proto(mp_obj_t self_in) { + common_hal_dotclockframebuffer_framebuffer_deinit(self_in); +} + +STATIC float dotclockframebuffer_framebuffer_get_brightness_proto(mp_obj_t self_in) { + return 1.0f; +} + +STATIC bool dotclockframebuffer_framebuffer_set_brightness_proto(mp_obj_t self_in, mp_float_t value) { + return false; +} + +STATIC int dotclockframebuffer_framebuffer_get_width_proto(mp_obj_t self_in) { + return common_hal_dotclockframebuffer_framebuffer_get_width(self_in); +} + +STATIC int dotclockframebuffer_framebuffer_get_height_proto(mp_obj_t self_in) { + return common_hal_dotclockframebuffer_framebuffer_get_height(self_in); +} + +STATIC int dotclockframebuffer_framebuffer_get_color_depth_proto(mp_obj_t self_in) { + return 16; +} + +STATIC int dotclockframebuffer_framebuffer_get_bytes_per_cell_proto(mp_obj_t self_in) { + return 1; +} + +STATIC int dotclockframebuffer_framebuffer_get_native_frames_per_second_proto(mp_obj_t self_in) { + return common_hal_dotclockframebuffer_framebuffer_get_refresh_rate(self_in); +} + +STATIC void dotclockframebuffer_framebuffer_get_bufinfo(mp_obj_t self_in, mp_buffer_info_t *bufinfo) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + + *bufinfo = self->bufinfo; +} + +STATIC int dotclockframebuffer_framebuffer_get_row_stride_proto(mp_obj_t self_in) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + return common_hal_dotclockframebuffer_framebuffer_get_row_stride(self); +} + +STATIC int dotclockframebuffer_framebuffer_get_first_pixel_offset_proto(mp_obj_t self_in) { + dotclockframebuffer_framebuffer_obj_t *self = (dotclockframebuffer_framebuffer_obj_t *)self_in; + return common_hal_dotclockframebuffer_framebuffer_get_first_pixel_offset(self); +} + +STATIC const framebuffer_p_t dotclockframebuffer_framebuffer_proto = { + MP_PROTO_IMPLEMENT(MP_QSTR_protocol_framebuffer) + .get_bufinfo = dotclockframebuffer_framebuffer_get_bufinfo, + .set_brightness = dotclockframebuffer_framebuffer_set_brightness_proto, + .get_brightness = dotclockframebuffer_framebuffer_get_brightness_proto, + .get_width = dotclockframebuffer_framebuffer_get_width_proto, + .get_height = dotclockframebuffer_framebuffer_get_height_proto, + .get_color_depth = dotclockframebuffer_framebuffer_get_color_depth_proto, + .get_row_stride = dotclockframebuffer_framebuffer_get_row_stride_proto, + .get_first_pixel_offset = dotclockframebuffer_framebuffer_get_first_pixel_offset_proto, + .get_bytes_per_cell = dotclockframebuffer_framebuffer_get_bytes_per_cell_proto, + .get_native_frames_per_second = dotclockframebuffer_framebuffer_get_native_frames_per_second_proto, + .swapbuffers = dotclockframebuffer_framebuffer_swapbuffers, + .deinit = dotclockframebuffer_framebuffer_deinit_proto, +}; + + +STATIC const mp_rom_map_elem_t dotclockframebuffer_framebuffer_locals_dict_table[] = { + { MP_ROM_QSTR(MP_QSTR_width), MP_ROM_PTR(&dotclockframebuffer_framebuffer_width_obj) }, + { MP_ROM_QSTR(MP_QSTR_height), MP_ROM_PTR(&dotclockframebuffer_framebuffer_height_obj) }, + { MP_ROM_QSTR(MP_QSTR_row_stride), MP_ROM_PTR(&dotclockframebuffer_framebuffer_row_stride_obj) }, + { MP_ROM_QSTR(MP_QSTR_first_pixel_offset), MP_ROM_PTR(&dotclockframebuffer_framebuffer_first_pixel_offset_obj) }, + { MP_ROM_QSTR(MP_QSTR_frequency), MP_ROM_PTR(&dotclockframebuffer_framebuffer_frequency_obj) }, + { MP_ROM_QSTR(MP_QSTR_refresh_rate), MP_ROM_PTR(&dotclockframebuffer_framebuffer_refresh_rate_obj) }, + { MP_ROM_QSTR(MP_QSTR_refresh), MP_ROM_PTR(&dotclockframebuffer_framebuffer_refresh_obj) }, +}; +STATIC MP_DEFINE_CONST_DICT(dotclockframebuffer_framebuffer_locals_dict, dotclockframebuffer_framebuffer_locals_dict_table); + +const mp_obj_type_t dotclockframebuffer_framebuffer_type = { + { &mp_type_type }, + .flags = MP_TYPE_FLAG_EXTENDED, + .name = MP_QSTR_DotClockFramebuffer, + .make_new = dotclockframebuffer_framebuffer_make_new, + .locals_dict = (mp_obj_dict_t *)&dotclockframebuffer_framebuffer_locals_dict, + MP_TYPE_EXTENDED_FIELDS( + .buffer_p = { .get_buffer = dotclockframebuffer_framebuffer_get_buffer, }, + .protocol = &dotclockframebuffer_framebuffer_proto, + ), +}; diff --git a/shared-bindings/dotclockframebuffer/DotClockFramebuffer.h b/shared-bindings/dotclockframebuffer/DotClockFramebuffer.h new file mode 100644 index 0000000000..0f99d2017e --- /dev/null +++ b/shared-bindings/dotclockframebuffer/DotClockFramebuffer.h @@ -0,0 +1,60 @@ +/* + * This file is part of the Micro Python 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. + */ + +#pragma once + +#include "common-hal/microcontroller/Pin.h" +#include "shared-bindings/displayio/__init__.h" +#include "shared-module/displayio/Group.h" + +typedef struct dotclockframebuffer_framebuffer_obj dotclockframebuffer_framebuffer_obj_t; + +extern const mp_obj_type_t dotclockframebuffer_framebuffer_type; + +void common_hal_dotclockframebuffer_framebuffer_construct(dotclockframebuffer_framebuffer_obj_t *self, + const mcu_pin_obj_t *de, + const mcu_pin_obj_t *vsync, + const mcu_pin_obj_t *hsync, + const mcu_pin_obj_t *dclk, + const mcu_pin_obj_t **red, uint8_t num_red, + const mcu_pin_obj_t **green, uint8_t num_green, + const mcu_pin_obj_t **blue, uint8_t num_blue, + int frequency, int width, int height, + int hsync_pulse_width, int hsync_back_porch, int hsync_front_porch, bool hsync_idle_low, + int vsync_pulse_width, int vsync_back_porch, int vsync_front_porch, bool vsync_idle_low, + bool de_idle_high, bool pclk_active_high, bool pclk_idle_high, + int overscan_left); + +void common_hal_dotclockframebuffer_framebuffer_deinit(dotclockframebuffer_framebuffer_obj_t *self); +bool common_hal_dotclockframebuffer_framebuffer_deinitialized(dotclockframebuffer_framebuffer_obj_t *self); + +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_width(dotclockframebuffer_framebuffer_obj_t *self); +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_height(dotclockframebuffer_framebuffer_obj_t *self); +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_frequency(dotclockframebuffer_framebuffer_obj_t *self); +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_refresh_rate(dotclockframebuffer_framebuffer_obj_t *self); +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_row_stride(dotclockframebuffer_framebuffer_obj_t *self); +mp_int_t common_hal_dotclockframebuffer_framebuffer_get_first_pixel_offset(dotclockframebuffer_framebuffer_obj_t *self); +void common_hal_dotclockframebuffer_framebuffer_refresh(dotclockframebuffer_framebuffer_obj_t *self); diff --git a/shared-bindings/dotclockframebuffer/__init__.c b/shared-bindings/dotclockframebuffer/__init__.c new file mode 100644 index 0000000000..30f4022d0f --- /dev/null +++ b/shared-bindings/dotclockframebuffer/__init__.c @@ -0,0 +1,168 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2018 Scott Shawcroft for Adafruit Industries + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#include + +#include "py/enum.h" +#include "py/obj.h" +#include "py/runtime.h" + +#include "shared-bindings/dotclockframebuffer/__init__.h" +#include "shared-bindings/dotclockframebuffer/DotClockFramebuffer.h" + +//| """Native helpers for driving parallel displays""" +//| +//| Length = typing.Literal[1, 2] +//| +//| def ioexpander_send_init_sequence( +//| bus: busio.I2C, +//| init_sequence: ReadableBuffer, +//| *, +//| i2c_init_sequence: ReadableBuffer, +//| i2c_address: int, +//| gpio_address: int, +//| gpio_data_len: Length, +//| gpio_data: int, +//| cs_bit: int, +//| mosi_bit: int, +//| clk_bit: int, +//| reset_bit: Optional[int], +//| ): +//| """Send a displayio-style initialization sequence over an I2C I/O expander +//| +//| This function is highly generic in order to support various I/O expanders. +//| What's assumed is that all the GPIO can be updated by writing to a single I2C register. +//| Normal output polarity is assumed (CS and CLK are active low, data is not inverted). +//| Only 8-bit I2C addresses are supported. +//| 8- and 16-bit I2C addresses and data registers are supported. +//| The Data/Command bit is sent as part of the serial data. +//| +//| Normally this function is used via a convenience library that is specific to the display & I/O expander in use. +//| +//| If the board has an integrated I/O expander, ``**board.TFT_IO_EXPANDER`` expands to the proper arguments starting with ``gpio_address``. +//| Note that this may include the ``i2c_init_sequence`` argument which can change the direction & value of I/O expander pins. +//| If this is undesirable, take a copy of ``TFT_IO_EXPANDER`` and change or remove the ``i2c_init_sequence`` key. +//| +//| If the board has an integrated display that requires an initialization sequence, ``board.TFT_INIT_SEQUENCE`` is the initialization string for the display. +//| +//| :param busio.I2C bus: The I2C bus where the I/O expander resides +//| :param int busio.i2c_address: The I2C bus address of the I/O expander +//| :param ReadableBuffer init_sequence: The initialization sequence to send to the display +//| :param int gpio_address: The address portion of the I2C transaction (1 byte) +//| :param int gpio_data_len: The size of the data portion of the I2C transaction, 1 or 2 bytes +//| :param int gpio_data: The output value for all GPIO bits other than cs, mosi, and clk (needed because GPIO expanders may be unable to read back the current output value) +//| :param int cs_bit: The bit number (from 0 to 7, or from 0 to 15) of the chip select bit in the GPIO register +//| :param int mosi_value: The bit number (from 0 to 7, or from 0 to 15) of the data out bit in the GPIO register +//| :param int clk_value: The bit number (from 0 to 7, or from 0 to 15) of the clock out bit in the GPIO register +//| :param Optional[int] reset_value: The bit number (from 0 to 7, or from 0 to 15) of the display reset bit in the GPIO register +//| :param Optional[ReadableBuffer] i2c_init_sequence: An initialization sequence to send to the I2C expander +//| """ +//| + +STATIC mp_obj_t ioexpander_send_init_sequence(size_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) { + enum { ARG_bus, ARG_init_sequence, ARG_i2c_address, ARG_gpio_address, ARG_gpio_data_len, ARG_gpio_data, ARG_cs_bit, ARG_mosi_bit, ARG_clk_bit, ARG_reset_bit, ARG_i2c_init_sequence, NUM_ARGS }; + + static const mp_arg_t allowed_args[] = { + { MP_QSTR_bus, MP_ARG_REQUIRED | MP_ARG_OBJ }, + { MP_QSTR_init_sequence, MP_ARG_REQUIRED | MP_ARG_OBJ }, + { MP_QSTR_i2c_address, MP_ARG_KW_ONLY | MP_ARG_REQUIRED | MP_ARG_INT }, + { MP_QSTR_gpio_address, MP_ARG_KW_ONLY | MP_ARG_REQUIRED | MP_ARG_INT }, + { MP_QSTR_gpio_data_len, MP_ARG_KW_ONLY | MP_ARG_REQUIRED | MP_ARG_INT }, + { MP_QSTR_gpio_data, MP_ARG_KW_ONLY | MP_ARG_REQUIRED | MP_ARG_INT }, + { MP_QSTR_cs_bit, MP_ARG_KW_ONLY | MP_ARG_REQUIRED | MP_ARG_INT }, + { MP_QSTR_mosi_bit, MP_ARG_KW_ONLY | MP_ARG_REQUIRED | MP_ARG_INT }, + { MP_QSTR_clk_bit, MP_ARG_KW_ONLY | MP_ARG_REQUIRED | MP_ARG_INT }, + { MP_QSTR_reset_bit, MP_ARG_KW_ONLY | MP_ARG_OBJ, { .u_obj = MP_ROM_NONE } }, + { MP_QSTR_i2c_init_sequence, MP_ARG_KW_ONLY | MP_ARG_OBJ, { .u_obj = MP_ROM_NONE } }, + }; + + mp_arg_val_t args[MP_ARRAY_SIZE(allowed_args)]; + MP_STATIC_ASSERT(MP_ARRAY_SIZE(allowed_args) == NUM_ARGS); + mp_arg_parse_all(n_args, pos_args, kw_args, MP_ARRAY_SIZE(allowed_args), allowed_args, args); + + mp_obj_t bus_obj = mp_arg_validate_type(args[ARG_bus].u_obj, &busio_i2c_type, MP_QSTR_bus); + mp_int_t i2c_address = args[ARG_i2c_address].u_int; + mp_int_t gpio_address = args[ARG_gpio_address].u_int; + mp_int_t gpio_data_len = args[ARG_gpio_data_len].u_int; + mp_int_t gpio_data = args[ARG_gpio_data].u_int; + mp_int_t cs_bit = args[ARG_cs_bit].u_int; + mp_int_t mosi_bit = args[ARG_mosi_bit].u_int; + mp_int_t clk_bit = args[ARG_clk_bit].u_int; + + mp_buffer_info_t bufinfo_display_init_sequence; + mp_get_buffer_raise(args[ARG_init_sequence].u_obj, &bufinfo_display_init_sequence, MP_BUFFER_READ); + + mp_arg_validate_int_range(i2c_address, 0, 127, MP_QSTR_i2c_address); + mp_arg_validate_int_range(gpio_data_len, 1, 2, MP_QSTR_gpio_dat_len); + + int max_bit = gpio_data_len * 8 - 1; + mp_arg_validate_int_range(cs_bit, 0, max_bit, MP_QSTR_cs_bit); + mp_arg_validate_int_range(mosi_bit, 0, max_bit, MP_QSTR_mosi_bit); + mp_arg_validate_int_range(clk_bit, 0, max_bit, MP_QSTR_clk_bit); + mp_arg_validate_int_range(gpio_data, 0, (1 << (max_bit * 8)) - 1, MP_QSTR_gpio_data); + mp_int_t reset_mask = 0; + if (args[ARG_reset_bit].u_obj != MP_ROM_NONE) { + mp_int_t reset_bit = mp_arg_validate_int_range(mp_arg_validate_type_int(args[ARG_reset_bit].u_obj, MP_QSTR_reset_bit), 0, max_bit, MP_QSTR_reset_bit); + reset_mask = 0x100 << reset_bit; + } + + mp_buffer_info_t bufinfo_i2c_init_sequence = {}; + if (args[ARG_i2c_init_sequence].u_obj != mp_const_none) { + mp_get_buffer_raise(args[ARG_i2c_init_sequence].u_obj, &bufinfo_i2c_init_sequence, MP_BUFFER_READ); + } + + dotclockframebuffer_ioexpander_spi_bus b = { + .bus = bus_obj, + .i2c_device_address = i2c_address, + .i2c_write_size = 1 + gpio_data_len, + // ASSERT(LITTLE_ENDIAN, "don't have to differentiate 8- vs 16-bits here") + .addr_reg_shadow = { .u32 = gpio_address | (gpio_data << 8) }, + .cs_mask = 0x100 << cs_bit, + .mosi_mask = 0x100 << mosi_bit, + .clk_mask = 0x100 << clk_bit, + .reset_mask = reset_mask, + }; + + dotclockframebuffer_ioexpander_send_init_sequence(&b, &bufinfo_i2c_init_sequence, &bufinfo_display_init_sequence); + return mp_const_none; +} + +STATIC MP_DEFINE_CONST_FUN_OBJ_KW(ioexpander_send_init_sequence_obj, 0, ioexpander_send_init_sequence); + +STATIC const mp_rom_map_elem_t dotclockframebuffer_module_globals_table[] = { + { MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_dotclockframebuffer) }, + { MP_ROM_QSTR(MP_QSTR_DotClockFramebuffer), MP_ROM_PTR(&dotclockframebuffer_framebuffer_type) }, + { MP_ROM_QSTR(MP_QSTR_ioexpander_send_init_sequence), MP_ROM_PTR(&ioexpander_send_init_sequence_obj) }, +}; + +STATIC MP_DEFINE_CONST_DICT(dotclockframebuffer_module_globals, dotclockframebuffer_module_globals_table); + +const mp_obj_module_t dotclockframebuffer_module = { + .base = { &mp_type_module }, + .globals = (mp_obj_dict_t *)&dotclockframebuffer_module_globals, +}; + +MP_REGISTER_MODULE(MP_QSTR_dotclockframebuffer, dotclockframebuffer_module); diff --git a/shared-bindings/dotclockframebuffer/__init__.h b/shared-bindings/dotclockframebuffer/__init__.h new file mode 100644 index 0000000000..864eac3573 --- /dev/null +++ b/shared-bindings/dotclockframebuffer/__init__.h @@ -0,0 +1,57 @@ +/* + * This file is part of the MicroPython project, http://micropython.org/ + * + * The MIT License (MIT) + * + * Copyright (c) 2018 Scott Shawcroft for Adafruit Industries + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#pragma once + +#include "py/obj.h" +#include "shared-bindings/busio/I2C.h" + +typedef union { + struct { + uint8_t addr, data; + } a8d8; + struct { + uint16_t addr, data; // in little endian + } a16d16; + struct { + uint8_t addr; + uint16_t data; // in little endian + } __attribute__((packed)) a8d16; + uint32_t u32; +} dotclockframebuffer_ioexpander_addr_reg_t; + +typedef struct { + busio_i2c_obj_t *bus; + uint8_t i2c_device_address; + uint8_t i2c_write_size; + dotclockframebuffer_ioexpander_addr_reg_t addr_reg_shadow; + uint32_t cs_mask; + uint32_t mosi_mask; + uint32_t clk_mask; + uint32_t reset_mask; +} dotclockframebuffer_ioexpander_spi_bus; + +void dotclockframebuffer_ioexpander_send_init_sequence(dotclockframebuffer_ioexpander_spi_bus *bus, const mp_buffer_info_t *i2c_bus_init, const mp_buffer_info_t *display_init); diff --git a/shared-bindings/memorymap/AddressRange.c b/shared-bindings/memorymap/AddressRange.c index 7fd1062534..4ea7c680f5 100644 --- a/shared-bindings/memorymap/AddressRange.c +++ b/shared-bindings/memorymap/AddressRange.c @@ -47,6 +47,32 @@ //| import memorymap //| rtc_slow_mem = memorymap.AddressRange(start=0x50000000, length=0x2000) //| rtc_slow_mem[0:3] = b"\xcc\x10\x00" +//| +//| Example I/O register usage on RP2040:: +//| +//| import binascii +//| import board +//| import digitalio +//| import memorymap +//| +//| def rp2040_set_pad_drive(p, d): +//| pads_bank0 = memorymap.AddressRange(start=0x4001C000, length=0x4000) +//| pad_ctrl = int.from_bytes(pads_bank0[p*4+4:p*4+8], "little") +//| # Pad control register is updated using an MP-safe atomic XOR +//| pad_ctrl ^= (d << 4) +//| pad_ctrl &= 0x00000030 +//| pads_bank0[p*4+0x3004:p*4+0x3008] = pad_ctrl.to_bytes(4, "little") +//| +//| def rp2040_get_pad_drive(p): +//| pads_bank0 = memorymap.AddressRange(start=0x4001C000, length=0x4000) +//| pad_ctrl = int.from_bytes(pads_bank0[p*4+4:p*4+8], "little") +//| return (pad_ctrl >> 4) & 0x3 +//| +//| # set GPIO16 pad drive strength to 12 mA +//| rp2040_set_pad_drive(16, 3) +//| +//| # print GPIO16 pad drive strength +//| print(rp2040_get_pad_drive(16)) //| """ //| def __init__(self, *, start, length) -> None: @@ -57,17 +83,29 @@ STATIC mp_obj_t memorymap_addressrange_make_new(const mp_obj_type_t *type, size_t n_args, size_t n_kw, const mp_obj_t *all_args) { enum { ARG_start, ARG_length }; static const mp_arg_t allowed_args[] = { - { MP_QSTR_start, MP_ARG_KW_ONLY | MP_ARG_REQUIRED | MP_ARG_INT }, + { MP_QSTR_start, MP_ARG_KW_ONLY | MP_ARG_REQUIRED | MP_ARG_OBJ }, { MP_QSTR_length, MP_ARG_KW_ONLY | MP_ARG_REQUIRED | MP_ARG_INT }, }; mp_arg_val_t args[MP_ARRAY_SIZE(allowed_args)]; mp_arg_parse_all_kw_array(n_args, n_kw, all_args, MP_ARRAY_SIZE(allowed_args), allowed_args, args); - size_t start = - mp_arg_validate_int_min(args[ARG_start].u_int, 0, MP_QSTR_start); + // Argument start is a pointer into the address map, so we validate it here because a + // signed int argument will overflow if it is in the upper half of the map. + size_t start; + if (mp_obj_is_small_int(args[ARG_start].u_obj)) { + start = MP_OBJ_SMALL_INT_VALUE(args[ARG_start].u_obj); + } else if (mp_obj_is_type(args[ARG_start].u_obj, &mp_type_int)) { + start = mp_obj_int_get_uint_checked(args[ARG_start].u_obj); + } else { + mp_obj_t arg = mp_unary_op(MP_UNARY_OP_INT, args[ARG_start].u_obj); + start = mp_obj_int_get_uint_checked(arg); + } size_t length = mp_arg_validate_int_min(args[ARG_length].u_int, 1, MP_QSTR_length); - + // Check for address range wrap here as this can break port-specific code due to size_t overflow. + if (start + length - 1 < start) { + mp_raise_ValueError(translate("Address range wraps around")); + } memorymap_addressrange_obj_t *self = mp_obj_malloc(memorymap_addressrange_obj_t, &memorymap_addressrange_type); @@ -104,7 +142,8 @@ STATIC MP_DEFINE_CONST_DICT(memorymap_addressrange_locals_dict, memorymap_addres //| def __getitem__(self, index: int) -> int: //| """Returns the value(s) at the given index. //| -//| 1, 2, 4 and 8 byte aligned reads will be done in one transaction. +//| 1, 2, 4 and 8 byte aligned reads will be done in one transaction +//| when possible. //| All others may use multiple transactions.""" //| ... //| @overload @@ -113,7 +152,8 @@ STATIC MP_DEFINE_CONST_DICT(memorymap_addressrange_locals_dict, memorymap_addres //| def __setitem__(self, index: int, value: int) -> None: //| """Set the value(s) at the given index. //| -//| 1, 2, 4 and 8 byte aligned writes will be done in one transaction. +//| 1, 2, 4 and 8 byte aligned writes will be done in one transaction +//| when possible. //| All others may use multiple transactions.""" //| ... //| @@ -154,9 +194,7 @@ STATIC mp_obj_t memorymap_addressrange_subscr(mp_obj_t self_in, mp_obj_t index_i mp_raise_NotImplementedError(translate("array/bytes required on right side")); } - if (!common_hal_memorymap_addressrange_set_bytes(self, slice.start, src_items, src_len)) { - mp_raise_RuntimeError(translate("Unable to write to address.")); - } + common_hal_memorymap_addressrange_set_bytes(self, slice.start, src_items, src_len); return mp_const_none; #else return MP_OBJ_NULL; // op not supported @@ -184,9 +222,7 @@ STATIC mp_obj_t memorymap_addressrange_subscr(mp_obj_t self_in, mp_obj_t index_i mp_arg_validate_int_range(byte_value, 0, 255, MP_QSTR_bytes); uint8_t short_value = byte_value; - if (!common_hal_memorymap_addressrange_set_bytes(self, index, &short_value, 1)) { - mp_raise_RuntimeError(translate("Unable to write to address.")); - } + common_hal_memorymap_addressrange_set_bytes(self, index, &short_value, 1); return mp_const_none; } } diff --git a/shared-bindings/memorymap/AddressRange.h b/shared-bindings/memorymap/AddressRange.h index 74a214d949..93c082c8eb 100644 --- a/shared-bindings/memorymap/AddressRange.h +++ b/shared-bindings/memorymap/AddressRange.h @@ -33,14 +33,14 @@ extern const mp_obj_type_t memorymap_addressrange_type; void common_hal_memorymap_addressrange_construct(memorymap_addressrange_obj_t *self, uint8_t *start_address, size_t length); -uint32_t common_hal_memorymap_addressrange_get_length(const memorymap_addressrange_obj_t *self); +size_t common_hal_memorymap_addressrange_get_length(const memorymap_addressrange_obj_t *self); -bool common_hal_memorymap_addressrange_set_bytes(const memorymap_addressrange_obj_t *self, - uint32_t start_index, uint8_t *values, uint32_t len); +void common_hal_memorymap_addressrange_set_bytes(const memorymap_addressrange_obj_t *self, + size_t start_index, uint8_t *values, size_t len); // len and values are intentionally swapped to signify values is an output and // also leverage the compiler to validate uses are expected. void common_hal_memorymap_addressrange_get_bytes(const memorymap_addressrange_obj_t *self, - uint32_t start_index, uint32_t len, uint8_t *values); + size_t start_index, size_t len, uint8_t *values); #endif // MICROPY_INCLUDED_SHARED_BINDINGS_MEMORYMAP_ADDRESSRANGE_H diff --git a/shared-bindings/ssl/SSLContext.c b/shared-bindings/ssl/SSLContext.c index 5fc4238f75..a132476614 100644 --- a/shared-bindings/ssl/SSLContext.c +++ b/shared-bindings/ssl/SSLContext.c @@ -100,7 +100,7 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_KW(ssl_sslcontext_load_cert_chain_obj, 1, ssl_ssl STATIC mp_obj_t ssl_sslcontext_load_verify_locations(size_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) { enum { ARG_cadata }; static const mp_arg_t allowed_args[] = { - { MP_QSTR_cadata, MP_ARG_KW_ONLY | MP_ARG_OBJ, {.u_obj = mp_const_none} }, + { MP_QSTR_cadata, MP_ARG_OBJ, {.u_obj = mp_const_none} }, }; ssl_sslcontext_obj_t *self = MP_OBJ_TO_PTR(pos_args[0]); diff --git a/shared-module/displayio/__init__.c b/shared-module/displayio/__init__.c index f01cca781e..a62b0a8bb5 100644 --- a/shared-module/displayio/__init__.c +++ b/shared-module/displayio/__init__.c @@ -43,6 +43,10 @@ #include "supervisor/spi_flash_api.h" #include "py/mpconfig.h" +#if CIRCUITPY_DOTCLOCKFRAMEBUFFER +#include "shared-bindings/dotclockframebuffer/DotClockFramebuffer.h" +#endif + #if CIRCUITPY_SHARPDISPLAY #include "shared-bindings/sharpdisplay/SharpMemoryFramebuffer.h" #include "shared-module/sharpdisplay/SharpMemoryFramebuffer.h" @@ -133,6 +137,10 @@ void common_hal_displayio_release_displays(void) { common_hal_displayio_fourwire_deinit(&display_buses[i].fourwire_bus); } else if (bus_type == &displayio_i2cdisplay_type) { common_hal_displayio_i2cdisplay_deinit(&display_buses[i].i2cdisplay_bus); + #if CIRCUITPY_DOTCLOCKFRAMEBUFFER + } else if (bus_type == &dotclockframebuffer_framebuffer_type) { + common_hal_dotclockframebuffer_framebuffer_deinit(&display_buses[i].dotclock); + #endif #if CIRCUITPY_PARALLELDISPLAY } else if (bus_type == ¶lleldisplay_parallelbus_type) { common_hal_paralleldisplay_parallelbus_deinit(&display_buses[i].parallel_bus); diff --git a/shared-module/displayio/__init__.h b/shared-module/displayio/__init__.h index 1add0133b6..0695b950ac 100644 --- a/shared-module/displayio/__init__.h +++ b/shared-module/displayio/__init__.h @@ -47,6 +47,9 @@ #if CIRCUITPY_SHARPDISPLAY #include "shared-module/sharpdisplay/SharpMemoryFramebuffer.h" #endif +#if CIRCUITPY_DOTCLOCKFRAMEBUFFER +#include "common-hal/dotclockframebuffer/DotClockFramebuffer.h" +#endif // Port unique frame buffers. #if CIRCUITPY_VIDEOCORE #include "bindings/videocore/Framebuffer.h" @@ -78,6 +81,9 @@ typedef struct { #if CIRCUITPY_PICODVI picodvi_framebuffer_obj_t picodvi; #endif + #if CIRCUITPY_DOTCLOCKFRAMEBUFFER + dotclockframebuffer_framebuffer_obj_t dotclock; + #endif }; } primary_display_bus_t; diff --git a/shared-module/dotclockframebuffer/__init__.c b/shared-module/dotclockframebuffer/__init__.c new file mode 100644 index 0000000000..1fa2426d2d --- /dev/null +++ b/shared-module/dotclockframebuffer/__init__.c @@ -0,0 +1,102 @@ +#include "shared-bindings/dotclockframebuffer/__init__.h" + +#include +#include +#include + +#define DELAY (0x80) + +static void pin_change(dotclockframebuffer_ioexpander_spi_bus *bus, uint32_t set_bits, uint32_t clear_bits) { + uint32_t data = (bus->addr_reg_shadow.u32 & ~clear_bits) | set_bits; + // no way to signal failure to caller! + (void)common_hal_busio_i2c_write(bus->bus, bus->i2c_device_address, (uint8_t *)&data, bus->i2c_write_size); + bus->addr_reg_shadow.u32 = data; +} + +static void ioexpander_bus_send(dotclockframebuffer_ioexpander_spi_bus *bus, + bool is_command, + const uint8_t *data, uint32_t data_length) { + + int dc_mask = is_command ? 0 : 0x100; + for (uint32_t i = 0; i < data_length; i++) { + int bits = data[i] | dc_mask; + + for (uint32_t j = 0; j < 9; j++) { + // CPOL=CPHA=0: output fresh data on falling edge of clk or cs + if (bits & 0x100) { + pin_change(bus, /* set */ bus->mosi_mask, /* clear */ bus->clk_mask | bus->cs_mask); + } else { + pin_change(bus, /* set */ 0, /* clear */ bus->mosi_mask | bus->clk_mask | bus->cs_mask); + } + // Display latches bit on rising edge of CLK + pin_change(bus, /* set */ bus->clk_mask, /* clear */ 0); + + // next bit + bits <<= 1; + } + } +} + +// Send a circuitpython-style display initialization sequence over an i2c-attached bus expander +// This always assumes +// * 9-bit SPI (no DC pin) +// * CPOL=CPHA=0 +// * CS deasserted after each init sequence step, but not otherwise just like +// displayio fourwire bus without data_as_commands +void dotclockframebuffer_ioexpander_send_init_sequence(dotclockframebuffer_ioexpander_spi_bus *bus, const mp_buffer_info_t *i2c_bus_init, const mp_buffer_info_t *display_init) { + while (!common_hal_busio_i2c_try_lock(bus->bus)) { + RUN_BACKGROUND_TASKS; + } + + // send i2c init sequence + { + size_t init_sequence_len = i2c_bus_init->len; + const uint8_t *init_sequence = i2c_bus_init->buf; + + for (size_t i = 0; i < init_sequence_len; /* NO INCREMENT */) { + uint8_t data_size = init_sequence[i]; + const uint8_t *data_ptr = &init_sequence[i + 1]; + (void)common_hal_busio_i2c_write(bus->bus, bus->i2c_device_address, data_ptr, data_size); + i = i + data_size + 1; + } + } + + // ensure deasserted CS and idle CLK (and set other pins according to addr_reg_shadow); enter reset mode if applicable + pin_change(bus, /* set */ bus->cs_mask, /* clear */ bus->clk_mask | bus->reset_mask); + + if (bus->reset_mask) { + mp_hal_delay_ms(10); // reset pulse length + pin_change(bus, /* set */ bus->reset_mask, /* clear */ 0); + mp_hal_delay_ms(100); // display start-up time + } + + size_t init_sequence_len = display_init->len; + const uint8_t *init_sequence = display_init->buf; + + for (size_t i = 0; i < init_sequence_len; /* NO INCREMENT */) { + const uint8_t *cmd = init_sequence + i; + uint8_t data_size = *(cmd + 1); + bool delay = (data_size & DELAY) != 0; + data_size &= ~DELAY; + const uint8_t *data = cmd + 2; + + ioexpander_bus_send(bus, true, cmd, 1); + ioexpander_bus_send(bus, false, data, data_size); + + // idle CLK + pin_change(bus, 0, /* clear */ bus->clk_mask); + // deassert CS + pin_change(bus, /* set */ bus->cs_mask, 0); + + if (delay) { + data_size++; + uint16_t delay_length_ms = *(cmd + 1 + data_size); + if (delay_length_ms == 255) { + delay_length_ms = 500; + } + mp_hal_delay_ms(delay_length_ms); + } + i += 2 + data_size; + } + common_hal_busio_i2c_unlock(bus->bus); +} diff --git a/shared-module/framebufferio/FramebufferDisplay.c b/shared-module/framebufferio/FramebufferDisplay.c index 6db2c3fec1..737cef5ad0 100644 --- a/shared-module/framebufferio/FramebufferDisplay.c +++ b/shared-module/framebufferio/FramebufferDisplay.c @@ -85,7 +85,7 @@ void common_hal_framebufferio_framebufferdisplay_construct(framebufferio_framebu } self->framebuffer_protocol->get_bufinfo(self->framebuffer, &self->bufinfo); - size_t framebuffer_size = self->first_pixel_offset + self->row_stride * self->core.height; + size_t framebuffer_size = self->first_pixel_offset + self->row_stride * (self->core.height - 1) + self->core.width * self->core.colorspace.depth / 8; mp_arg_validate_length_min(self->bufinfo.len, framebuffer_size, MP_QSTR_framebuffer); @@ -252,7 +252,9 @@ STATIC void _refresh_display(framebufferio_framebufferdisplay_obj_t *self) { displayio_display_core_start_refresh(&self->core); const displayio_area_t *current_area = _get_refresh_areas(self); if (current_area) { - uint8_t dirty_row_bitmask[(self->core.height + 7) / 8]; + bool transposed = (self->core.rotation == 90 || self->core.rotation == 270); + int row_count = transposed ? self->core.width : self->core.height; + uint8_t dirty_row_bitmask[(row_count + 7) / 8]; memset(dirty_row_bitmask, 0, sizeof(dirty_row_bitmask)); self->framebuffer_protocol->get_bufinfo(self->framebuffer, &self->bufinfo); while (current_area != NULL) { diff --git a/supervisor/port.h b/supervisor/port.h index 7b48a3f13b..ebfa8473f2 100644 --- a/supervisor/port.h +++ b/supervisor/port.h @@ -43,6 +43,11 @@ extern uint32_t _ebss; safe_mode_t port_init(void); +// If the port does not initialize the heap during port_init(), it must provide +// this function which is called after CIRCUITPY is mounted. +// If not required, a default (weak) implementation that does nothing is used. +safe_mode_t port_heap_init(safe_mode_t); + // Reset the microcontroller completely. void reset_cpu(void) NORETURN; diff --git a/supervisor/shared/translate/compressed_string.h b/supervisor/shared/translate/compressed_string.h index ac7517b9f6..8b0ce3d018 100644 --- a/supervisor/shared/translate/compressed_string.h +++ b/supervisor/shared/translate/compressed_string.h @@ -38,12 +38,18 @@ // 9 in some translations sometime in the future. This length excludes // the trailing NUL, though notably decompress_length includes it. // -// - followed by the huffman encoding of the individual UTF-16 code +// - followed by the huffman encoding of the individual code // points that make up the string. The trailing "\0" is not // represented by a huffman code, but is implied by the length. // (building the huffman encoding on UTF-16 code points gave better // compression than building it on UTF-8 bytes) // +// - If possible, the code points are represented as uint8_t values, with +// 0..127 representing themselves and 160..255 representing another range +// of Unicode, controlled by translation_offset and translation_offstart. +// If this is not possible, uint16_t values are used. At present, no translation +// requires code points not in the BMP, so this is adequate. +// // - code points starting at 128 (word_start) and potentially extending // to 255 (word_end) (but never interfering with the target // language's used code points) stand for dictionary entries in a diff --git a/supervisor/shared/web_workflow/web_workflow.c b/supervisor/shared/web_workflow/web_workflow.c index 04a02b8628..ce94fb4609 100644 --- a/supervisor/shared/web_workflow/web_workflow.c +++ b/supervisor/shared/web_workflow/web_workflow.c @@ -353,8 +353,7 @@ bool supervisor_start_web_workflow(bool reload) { #if CIRCUITPY_MDNS // Try to start MDNS if the user deinited it. if (mdns.base.type != &mdns_server_type || - common_hal_mdns_server_deinited(&mdns) || - reload) { // Always reconstruct on reload, since we don't know if the net changed. + common_hal_mdns_server_deinited(&mdns)) { mdns_server_construct(&mdns, true); mdns.base.type = &mdns_server_type; if (!common_hal_mdns_server_deinited(&mdns)) { diff --git a/tools/ci_check_duplicate_usb_vid_pid.py b/tools/ci_check_duplicate_usb_vid_pid.py index f22225007b..b8170aa9e3 100644 --- a/tools/ci_check_duplicate_usb_vid_pid.py +++ b/tools/ci_check_duplicate_usb_vid_pid.py @@ -55,6 +55,7 @@ DEFAULT_CLUSTERLIST = { "espressif_esp32s3_devkitc_1_n8r2", "espressif_esp32s3_devkitc_1_n8r8", "espressif_esp32s3_devkitc_1_n32r8", + "espressif_esp32s3_devkitc_1_n8r8_hacktablet", ], "0x303A:0x7009": [ "espressif_esp32s2_devkitc_1_n4", @@ -94,7 +95,9 @@ def check_vid_pid(files, clusterlist): if duplicates are found, and lists the duplicates. """ - usb_pattern = re.compile(r"^CIRCUITPY_USB\s*=\s*0$|^IDF_TARGET = (esp32|esp32c3)$", flags=re.M) + usb_pattern = re.compile( + r"^CIRCUITPY_USB\s*=\s*0$|^IDF_TARGET = (esp32|esp32c3|esp32c6|esp32h2)$", flags=re.M + ) usb_ids = defaultdict(set) for board_config in files: @@ -138,7 +141,8 @@ def check_vid_pid(files, clusterlist): f"Duplicate VID/PID usage found!\n{duplicates}\n" f"If you are open source maker, then you can request a PID from http://pid.codes\n" f"For boards without native USB, you can request a Creator ID from https://github.com/creationid/creators/\n" - f"Otherwise, companies should pay the USB-IF for a vendor ID: https://www.usb.org/getting-vendor-id" + f"Otherwise, companies should pay the USB-IF for a vendor ID: https://www.usb.org/getting-vendor-id\n" + f"FAQ: Why does CircuitPython require a unique VID:PID for every board definition? https://learn.adafruit.com/how-to-add-a-new-board-to-circuitpython/frequently-asked-questions#faq-3130480" ) sys.exit(duplicate_message) diff --git a/tools/ci_fetch_deps.py b/tools/ci_fetch_deps.py index caaea8cea8..92b87ba1fa 100644 --- a/tools/ci_fetch_deps.py +++ b/tools/ci_fetch_deps.py @@ -24,7 +24,7 @@ PORT_DEPS = { "cxd56": ["extmod/ulab/", "lib/tinyusb/"], "espressif": [ "extmod/ulab/", - "lib/certificates/nina-fw/", + "lib/certificates/", "lib/protomatter/", "lib/quirc/", "lib/tinyusb/", @@ -37,7 +37,7 @@ PORT_DEPS = { "lib/adafruit_floppy/", "lib/mbedtls/", "lib/mp3/", - "lib/certificates/nina-fw/", + "lib/certificates/", "lib/protomatter/", "lib/quirc/", "lib/tinyusb/",