micropython v1.29.0
Permanent link:
cppdashboard.dev/r/2026/08/micropython-v1-29-0MicroPython - a lean and efficient Python implementation for microcontrollers and constrained systems
Release notes
Overview
========
This release of MicroPython adds a new "psoc-edge" port for Infineon PSOC Edge microcontrollers. This is a bare-metal port using CMSIS 6 and a set of low-level HAL submodules from Infineon's Modus Toolbox. It uses the standard ARM toolchains and builds with make. It currently supports a UART REPL, a filesystem (using QSPI flash), machine Pin, UART and RTC classes, including IRQs for Pin and UART. There is currently one supported board, the KIT_PSE84_AI.
The previous v1.28.0 release introduced a new `machine.CAN` API with an implementation for the stm32 port. This release implements that API on both the alif and mimxrt ports. Much effort went into making sure these three ports have the same consistent behaviour when using CAN, so that reliable applications can be built upon that API.
Also in this release is a new `machine.mem_backup()` interface which gives consistent access to backup memory on the alif, esp32, mimxrt, nrf, rp2, samd and stm32 ports. Calling this function returns a writable `memoryview` that survives (in most cases) a hard reset. The available regions can be discovered via `machine.mem_backup(-1)`. See the documentation for more details and examples: https://docs.micropython.org/en/latest/library/machine.html .
Configuring a custom build with user C modules is now a lot simpler thanks to the addition of the `c_module()` function to the manifest API. This function lets a manifest file declare which user C modules should be included in the build. They are declared alongside the declaration of frozen modules, making it much easier to configure firmware with extensions. For example, a `manifest.py` file containing:
require("bundle-networking")
freeze("/path/to/custom/modules")
c_module("/path/to/micropython-ulab/code")
will freeze in the networking bundle from micropython-lib, freeze in custom Python code, and include the micropython-ulab C library in the build. This `c_module()` feature is intended to replace the existing `USER_C_MODULES` option (although it currently works together with that option).
Unicode support is improved in this release:
- `bytes.decode()` and three-argument `str()` now support "strict", "ignore" and "replace" for the errors argument;
- when converting between str and bytes, the encoding/decoding mode is now validated and only "utf-8", "utf8" and "ascii" are accepted;
- `str.center()` is fixed so it handles Unicode characters correctly;
- all printable Unicode characters are now printed verbatim (not as an escape sequence).
A USB network (Network Control Model, NCM) driver implementation has been added, providing Ethernet-over-USB backed by the lwIP stack, available to Python through the new `network.USBD_NCM` class. With this enabled, the host computer sees the MicroPython device as a USB Ethernet adapter, and the host is assigned an IP address via DHCP (served by the MicroPython device). Python code on the device can then use all the usual networking facilities to communicate with the host. It's disabled by default, and needs `MICROPY_PY_NETWORK_USBD_NCM` enabled in a custom build.
The parser now recognises const assignments with type hints, for example `_X: int = const(123)`. There is now support for `bytes.find(int)` as well as `int.to_bytes()` with argument `signed=True`. The RISC-V inline assembler adds support for Zcmp opcodes and has improved register allocation. The LoongArch64 architecture is now supported and that is tested as part of CI.
Native .mpy modules built via `mpy_ld.py` now automatically include `memset`, `memmove` and `memcpy` in the linking stage so these no longer need to be manually provided. Native modules can also now be built with Clang.
The mbedTLS component is updated to v3.6.6, and support is added for TLS-PSK (pre-shared key) in the `SSLContext` class. Parsing of PEM certificates is also enabled for all ports using mbedTLS. LittleFS is updated to v2.11.3, TinyUSB to 0… Share this resource