{"id":13398362,"url":"https://github.com/micropython/micropython","last_synced_at":"2025-05-12T16:17:23.861Z","repository":{"id":12665257,"uuid":"15337142","full_name":"micropython/micropython","owner":"micropython","description":"MicroPython - a lean and efficient Python implementation for microcontrollers and constrained systems","archived":false,"fork":false,"pushed_at":"2025-05-02T07:30:11.000Z","size":66385,"stargazers_count":20297,"open_issues_count":1693,"forks_count":8159,"subscribers_count":721,"default_branch":"master","last_synced_at":"2025-05-05T14:13:22.473Z","etag":null,"topics":["embedded","microcontroller","micropython","python"],"latest_commit_sha":null,"homepage":"https://micropython.org","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/micropython.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":"micropython"}},"created_at":"2013-12-20T11:47:07.000Z","updated_at":"2025-05-05T13:32:20.000Z","dependencies_parsed_at":"2023-10-12T09:51:14.931Z","dependency_job_id":"1c3c26e1-fa94-4481-ae07-27da37a6ae2f","html_url":"https://github.com/micropython/micropython","commit_stats":{"total_commits":15744,"total_committers":678,"mean_commits":"23.221238938053098","dds":0.6498348577235773,"last_synced_commit":"51974f20e1ff77110c3caef83719f9411e00c637"},"previous_names":[],"tags_count":67,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/micropython%2Fmicropython","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/micropython%2Fmicropython/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/micropython%2Fmicropython/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/micropython%2Fmicropython/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/micropython","download_url":"https://codeload.github.com/micropython/micropython/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253601000,"owners_count":21934246,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["embedded","microcontroller","micropython","python"],"created_at":"2024-07-30T19:00:23.849Z","updated_at":"2025-05-12T16:17:23.840Z","avatar_url":"https://github.com/micropython.png","language":"C","readme":"[![Unix CI badge](https://github.com/micropython/micropython/actions/workflows/ports_unix.yml/badge.svg)](https://github.com/micropython/micropython/actions?query=branch%3Amaster+event%3Apush) [![STM32 CI badge](https://github.com/micropython/micropython/actions/workflows/ports_stm32.yml/badge.svg)](https://github.com/micropython/micropython/actions?query=branch%3Amaster+event%3Apush) [![Docs CI badge](https://github.com/micropython/micropython/actions/workflows/docs.yml/badge.svg)](https://docs.micropython.org/) [![codecov](https://codecov.io/gh/micropython/micropython/branch/master/graph/badge.svg?token=I92PfD05sD)](https://codecov.io/gh/micropython/micropython)\n\nThe MicroPython project\n=======================\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/micropython/micropython/master/logo/upython-with-micro.jpg\" alt=\"MicroPython Logo\"/\u003e\n\u003c/p\u003e\n\nThis is the MicroPython project, which aims to put an implementation\nof Python 3.x on microcontrollers and small embedded systems.\nYou can find the official website at [micropython.org](http://www.micropython.org).\n\nWARNING: this project is in beta stage and is subject to changes of the\ncode-base, including project-wide name changes and API changes.\n\nMicroPython implements the entire Python 3.4 syntax (including exceptions,\n`with`, `yield from`, etc., and additionally `async`/`await` keywords from\nPython 3.5 and some select features from later versions). The following core\ndatatypes are provided: `str`(including basic Unicode support), `bytes`,\n`bytearray`, `tuple`, `list`, `dict`, `set`, `frozenset`, `array.array`,\n`collections.namedtuple`, classes and instances. Builtin modules include\n`os`, `sys`, `time`, `re`, and `struct`, etc. Some ports have support for\n`_thread` module (multithreading), `socket` and `ssl` for networking, and\n`asyncio`. Note that only a subset of Python 3 functionality is implemented\nfor the data types and modules.\n\nMicroPython can execute scripts in textual source form (.py files) or from\nprecompiled bytecode (.mpy files), in both cases either from an on-device\nfilesystem or \"frozen\" into the MicroPython executable.\n\nMicroPython also provides a set of MicroPython-specific modules to access\nhardware-specific functionality and peripherals such as GPIO, Timers, ADC,\nDAC, PWM, SPI, I2C, CAN, Bluetooth, and USB.\n\nGetting started\n---------------\n\nSee the [online documentation](https://docs.micropython.org/) for the API\nreference and information about using MicroPython and information about how\nit is implemented.\n\nWe use [GitHub Discussions](https://github.com/micropython/micropython/discussions)\nas our forum, and [Discord](https://discord.gg/RB8HZSAExQ) for chat. These\nare great places to ask questions and advice from the community or to discuss your\nMicroPython-based projects.\n\nFor bugs and feature requests, please [raise an issue](https://github.com/micropython/micropython/issues/new/choose)\nand follow the templates there.\n\nFor information about the [MicroPython pyboard](https://store.micropython.org/pyb-features),\nthe officially supported board from the\n[original Kickstarter campaign](https://www.kickstarter.com/projects/214379695/micro-python-python-for-microcontrollers),\nsee the [schematics and pinouts](http://github.com/micropython/pyboard) and\n[documentation](https://docs.micropython.org/en/latest/pyboard/quickref.html).\n\nContributing\n------------\n\nMicroPython is an open-source project and welcomes contributions. To be\nproductive, please be sure to follow the\n[Contributors' Guidelines](https://github.com/micropython/micropython/wiki/ContributorGuidelines)\nand the [Code Conventions](https://github.com/micropython/micropython/blob/master/CODECONVENTIONS.md).\nNote that MicroPython is licenced under the MIT license, and all contributions\nshould follow this license.\n\nAbout this repository\n---------------------\n\nThis repository contains the following components:\n- [py/](py/) -- the core Python implementation, including compiler, runtime, and\n  core library.\n- [mpy-cross/](mpy-cross/) -- the MicroPython cross-compiler which is used to turn scripts\n  into precompiled bytecode.\n- [ports/](ports/) -- platform-specific code for the various ports and architectures that MicroPython runs on.\n- [lib/](lib/) -- submodules for external dependencies.\n- [tests/](tests/) -- test framework and test scripts.\n- [docs/](docs/) -- user documentation in Sphinx reStructuredText format. This is used to generate the [online documentation](http://docs.micropython.org).\n- [extmod/](extmod/) -- additional (non-core) modules implemented in C.\n- [tools/](tools/) -- various tools, including the pyboard.py module.\n- [examples/](examples/) -- a few example Python scripts.\n\n\"make\" is used to build the components, or \"gmake\" on BSD-based systems.\nYou will also need bash, gcc, and Python 3.3+ available as the command `python3`\n(if your system only has Python 2.7 then invoke make with the additional option\n`PYTHON=python2`). Some ports (rp2 and esp32) additionally use CMake.\n\nSupported platforms \u0026 architectures\n-----------------------------------\n\nMicroPython runs on a wide range of microcontrollers, as well as on Unix-like\n(including Linux, BSD, macOS, WSL) and Windows systems.\n\nMicrocontroller targets can be as small as 256kiB flash + 16kiB RAM, although\ndevices with at least 512kiB flash + 128kiB RAM allow a much more\nfull-featured experience.\n\nThe [Unix](ports/unix) and [Windows](ports/windows) ports allow both\ndevelopment and testing of MicroPython itself, as well as providing\nlightweight alternative to CPython on these platforms (in particular on\nembedded Linux systems).\n\nThe [\"minimal\"](ports/minimal) port provides an example of a very basic\nMicroPython port and can be compiled as both a standalone Linux binary as\nwell as for ARM Cortex M4. Start with this if you want to port MicroPython to\nanother microcontroller. Additionally the [\"bare-arm\"](ports/bare-arm) port\nis an example of the absolute minimum configuration, and is used to keep\ntrack of the code size of the core runtime and VM.\n\nIn addition, the following ports are provided in this repository:\n - [cc3200](ports/cc3200) -- Texas Instruments CC3200 (including PyCom WiPy).\n - [esp32](ports/esp32) -- Espressif ESP32 SoC (including ESP32S2, ESP32S3, ESP32C3, ESP32C6).\n - [esp8266](ports/esp8266) -- Espressif ESP8266 SoC.\n - [mimxrt](ports/mimxrt) -- NXP m.iMX RT (including Teensy 4.x).\n - [nrf](ports/nrf) -- Nordic Semiconductor nRF51 and nRF52.\n - [pic16bit](ports/pic16bit) -- Microchip PIC 16-bit.\n - [powerpc](ports/powerpc) -- IBM PowerPC (including Microwatt)\n - [qemu](ports/qemu) -- QEMU-based emulated target (for testing)\n - [renesas-ra](ports/renesas-ra) -- Renesas RA family.\n - [rp2](ports/rp2) -- Raspberry Pi RP2040 (including Pico and Pico W).\n - [samd](ports/samd) -- Microchip (formerly Atmel) SAMD21 and SAMD51.\n - [stm32](ports/stm32) -- STMicroelectronics STM32 family (including F0, F4, F7, G0, G4, H7, L0, L4, WB)\n - [webassembly](ports/webassembly) -- Emscripten port targeting browsers and NodeJS.\n - [zephyr](ports/zephyr) -- Zephyr RTOS.\n\nThe MicroPython cross-compiler, mpy-cross\n-----------------------------------------\n\nMost ports require the [MicroPython cross-compiler](mpy-cross) to be built\nfirst.  This program, called mpy-cross, is used to pre-compile Python scripts\nto .mpy files which can then be included (frozen) into the\nfirmware/executable for a port.  To build mpy-cross use:\n\n    $ cd mpy-cross\n    $ make\n\nExternal dependencies\n---------------------\n\nThe core MicroPython VM and runtime has no external dependencies, but a given\nport might depend on third-party drivers or vendor HALs. This repository\nincludes [several submodules](lib/) linking to these external dependencies.\nBefore compiling a given port, use\n\n    $ cd ports/name\n    $ make submodules\n\nto ensure that all required submodules are initialised.\n","funding_links":["https://github.com/sponsors/micropython"],"categories":["C","Virtual Machines","Lightweight implementations","Implementations","资源列表","Python Hacks","高性能","Libraries","Containers \u0026 Language Extentions \u0026 Linting","实现","Python Implementations","Resources","Python","python","硬件_其他","排序","虚拟机","Robotics","Implementations [🔝](#readme)","十三、嵌入式语言与工具","Language","Awesome Python","programming framework"],"sub_categories":["高性能","Languages \u0026 Runtimes","For Python","Utilities","Other dialects and variants","网络服务_其他","虚拟机","Drone Frames","编程语言","Android Things","Implementations","vm"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmicropython%2Fmicropython","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmicropython%2Fmicropython","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmicropython%2Fmicropython/lists"}