Skip to content

Born from Python: The Rise of MicroPython in Embedded Systems

Micro Python

Python is no longer confined to laptops, desktop and servers, it can also run on tiny digital IC's like microcontrollers too. In this blog will go through the baby named micropython, born out of CPython (Python).

In this article

MicroPython is a distribution of python3 programming language, streamlined to run on embedded systems and microcontrollers. It is Open Source and released under MIT License.

MicroPython can run with in 256k of code space and 16k of RAM. It is packed with advanced features such as an interactive prompt (REPL), arbitrary precision integers, list comprehension, exception handling, generators, closures and more.

Supported Microcontrollers and Development Boards

MicroPython supports wide range of microcontrollers with a minimum Flash of 256KB and 16KB RAM.

  1. Raspberry Pi Pico boards
    • Raspberry Pi Pico (RP2040)
    • Raspberry Pi Pico W (RP2040)
    • Raspberry Pi Pico 2 (RP2350)
    • Raspberry Pi Pico 2 W (RP2350)
  2. Espressif ESP8266
  3. Espressif ESP32
  4. Nordic Semiconductor
    • nRF51
    • nRF52.
  5. Microchip (Atmel)
    • SAMD21
    • SAMD51
  6. STMicroelectronics
    • STM32 MC (F0, F4, F7, G0, G4, H7, L0, L4, WB)
  7. Microchip PIC 16-bit Microcontrollers
  8. Teensy 4.x

Info

MicroPython is not only limited to microcontrollers, it can also run on emulated targets like QEMU, Zephyr RTOS, webassembly, IBM Power PC.

Difference & Similarities between Python & MicroPython

Both Python & MicroPython are written using C-Programming language.

CPython used to run scripts on different platforms like Linux , Windows , MacOs & Android .

Micropython is optimized to run scripts on microcontrollers like ESP8266, RP2040, STM32 etc..

Features Python MicroPython
Platform Linux , Windows , MacOs & Android Microcontroller
Library Standard + Third-party limited standard libraries + hardware
Performance High, preferred for Micro Processor Optimized for MicroController
Use Cases Server, general-purpose computing, AI, ML Embedded system, IOT, Robotics