Skip to main content

micropython mpy-cross distribution

Project description

mpy-cross is the micropython cross compiler utility, used to pre-compile python files into bytecode suitable for running on your target.

This project compiles mpy-cross for windows, linux and macos and distributes them in python wheels for easy installation on development pc’s.

Version

The release version of this package directly corresponds to the micropython release it’s built against.

If a wrapper update is needed for a particular release version, it will be updloaded with a .postN version

Weekly releases build against master should be available at: https://gitlab.com/alelec/mpy_cross/pipelines These will have version numbers that reflect the previous release and the current git hash built against.

Usage

mpy-cross can be run in three different ways

  • From python command line

    python -m mpy_cross <args>
    python -m mpy_cross --version
  • From python code

    import mpy_cross
    
    mpy_cross.run(*args, **kwargs)
    
    import subprocess
    proc = mpy_cross.run('--version', stdout=subprocess.PIPE)

where *args are arguments passed to mpy-cross, **kwargs are arguments to pass to subprocess.Popen() internally

  • Standalone

    # Print out path to actual mpy-cross exe
    python -c "import mpy_cross; print(mpy_cross.mpy_cross)"
    > /home/andrew/.local/share/virtualenvs/mpy_cross-gSGkki0d/lib/python3.5/site-packages/mpy_cross/mpy-cross
    /home/corona/.local/share/virtualenvs/mpy_cross-gSGkki0d/lib/python3.5/site-packages/mpy_cross/mpy-cross --version

mpy-cross options

usage: mpy-cross [<opts>] [-X <implopt>] <input filename>
Options:
--version : show version information
-o : output file for compiled bytecode (defaults to input with .mpy extension)
-s : source filename to embed in the compiled bytecode (defaults to input file)
-v : verbose (trace various operations); can be multiple
-O[N] : apply bytecode optimizations of level N

Target specific options:
-msmall-int-bits=number : set the maximum bits used to encode a small-int
-mno-unicode : don't support unicode in compiled strings
-mcache-lookup-bc : cache map lookups in the bytecode
-march=<arch> : set architecture for native emitter; x86, x64, armv6, armv7m, armv7em, armv7emsp, armv7emdp, xtensa, xtensawin

Implementation specific options:
  emit={bytecode,native,viper} -- set the default code emitter
  heapsize=<n> -- set the heap size for the GC (default 2097152)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

mpy_cross-1.17-py2.py3-none-win_amd64.whl (159.3 kB view details)

Uploaded Python 2Python 3Windows x86-64

mpy_cross-1.17-py2.py3-none-win32.whl (149.1 kB view details)

Uploaded Python 2Python 3Windows x86

mpy_cross-1.17-py2.py3-none-manylinux2014_armv7l.whl (111.3 kB view details)

Uploaded Python 2Python 3

mpy_cross-1.17-py2.py3-none-manylinux2014_aarch64.whl (143.8 kB view details)

Uploaded Python 2Python 3

mpy_cross-1.17-py2.py3-none-manylinux1_x86_64.whl (120.9 kB view details)

Uploaded Python 2Python 3

mpy_cross-1.17-py2.py3-none-manylinux1_i686.whl (121.1 kB view details)

Uploaded Python 2Python 3

mpy_cross-1.17-py2.py3-none-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (153.8 kB view details)

Uploaded Python 2Python 3macOS 10.10+ Intel (x86-64, i386)macOS 10.10+ x86-64macOS 10.6+ Intel (x86-64, i386)macOS 10.9+ Intel (x86-64, i386)macOS 10.9+ x86-64

File details

Details for the file mpy_cross-1.17-py2.py3-none-win_amd64.whl.

File metadata

  • Download URL: mpy_cross-1.17-py2.py3-none-win_amd64.whl
  • Upload date:
  • Size: 159.3 kB
  • Tags: Python 2, Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.1

File hashes

Hashes for mpy_cross-1.17-py2.py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 ebf6aa1ed16062064cfc72e939ba95bd51502ba1bdbdcb737d294746dc0be568
MD5 892dfa6f5a84c7ff3f21019b3624d960
BLAKE2b-256 4261b44c6e3802eb6898c836790cd69a1eb7f1a1d834b69d60dbdf4d5e5d23fd

See more details on using hashes here.

File details

Details for the file mpy_cross-1.17-py2.py3-none-win32.whl.

File metadata

  • Download URL: mpy_cross-1.17-py2.py3-none-win32.whl
  • Upload date:
  • Size: 149.1 kB
  • Tags: Python 2, Python 3, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.1

File hashes

Hashes for mpy_cross-1.17-py2.py3-none-win32.whl
Algorithm Hash digest
SHA256 71832c58ab3ec2dd0d14af4f103975f3af7c04884aa8b93b668e648621f57d40
MD5 47a61b2895057dae9b1eb42c37c5d792
BLAKE2b-256 979e802888e00bde99608bf5f78d2f11c7c5c419d7370e70c30df2a1e7656aaa

See more details on using hashes here.

File details

Details for the file mpy_cross-1.17-py2.py3-none-manylinux2014_armv7l.whl.

File metadata

  • Download URL: mpy_cross-1.17-py2.py3-none-manylinux2014_armv7l.whl
  • Upload date:
  • Size: 111.3 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.7

File hashes

Hashes for mpy_cross-1.17-py2.py3-none-manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 0dccb75293b6e7fd95b6b14580252e0fef7d40edeba89f7bf38824e127b98ce8
MD5 85b7374b03491cb55ac4948216e271ee
BLAKE2b-256 08c0056ca43a1279bfaec3139d4e777e47bc288bf5e59ff72265c09e4f308f6c

See more details on using hashes here.

File details

Details for the file mpy_cross-1.17-py2.py3-none-manylinux2014_aarch64.whl.

File metadata

  • Download URL: mpy_cross-1.17-py2.py3-none-manylinux2014_aarch64.whl
  • Upload date:
  • Size: 143.8 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.1

File hashes

Hashes for mpy_cross-1.17-py2.py3-none-manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 593b97e72c9367d0c63e70f12d6bf3b99e639b54792ef454d69b756efe55b8b2
MD5 dd83834bca42b991d0b211d0e376aa2f
BLAKE2b-256 e6d0f66036ca4de411159515b31b144fc2f9ebcd74d8d2ad13deab93e444aed9

See more details on using hashes here.

File details

Details for the file mpy_cross-1.17-py2.py3-none-manylinux1_x86_64.whl.

File metadata

  • Download URL: mpy_cross-1.17-py2.py3-none-manylinux1_x86_64.whl
  • Upload date:
  • Size: 120.9 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.7

File hashes

Hashes for mpy_cross-1.17-py2.py3-none-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 eb9a32cbde0ad81adce7b4a6d35158d17edd7186544adab65d1164af8810ce9d
MD5 6f4d9a69f6b9e0930687564f32c4e6d0
BLAKE2b-256 8b6bcde6bb82f25f10196db90e6940728b9f7f94be405cf5dd5dc50bcdb84fa6

See more details on using hashes here.

File details

Details for the file mpy_cross-1.17-py2.py3-none-manylinux1_i686.whl.

File metadata

  • Download URL: mpy_cross-1.17-py2.py3-none-manylinux1_i686.whl
  • Upload date:
  • Size: 121.1 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.7

File hashes

Hashes for mpy_cross-1.17-py2.py3-none-manylinux1_i686.whl
Algorithm Hash digest
SHA256 9c3bbf32f205e47c5e797da74908ad44d3f0440981117cf09c1eaa1ec9e17e99
MD5 4d1ae90ab9bb2abacfd4350f49b0851c
BLAKE2b-256 a6576074a763a995e1f1122d9e569188bf423261d8ec40c7fce67ab41170b458

See more details on using hashes here.

File details

Details for the file mpy_cross-1.17-py2.py3-none-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl.

File metadata

File hashes

Hashes for mpy_cross-1.17-py2.py3-none-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Algorithm Hash digest
SHA256 c86ca8e1b817a2336035ae56849fe9538244a5dbae6c5ea13f2659229c812210
MD5 24be61cacff14533ad7c5dbbabb5ec22
BLAKE2b-256 d89dc68ccc112261fd7ccbc247e5d7aa988c47756e80fdb52b3467ebb88bafca

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page