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, xtensa

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

mpy_cross-1.11-py2.py3-none-win_amd64.whl (151.8 kB view details)

Uploaded Python 2 Python 3 Windows x86-64

mpy_cross-1.11-py2.py3-none-win32.whl (141.8 kB view details)

Uploaded Python 2 Python 3 Windows x86

mpy_cross-1.11-py2.py3-none-manylinux2014_armv7l.whl (136.8 kB view details)

Uploaded Python 2 Python 3

mpy_cross-1.11-py2.py3-none-manylinux2014_aarch64.whl (149.7 kB view details)

Uploaded Python 2 Python 3

mpy_cross-1.11-py2.py3-none-manylinux1_x86_64.whl (133.6 kB view details)

Uploaded Python 2 Python 3

mpy_cross-1.11-py2.py3-none-manylinux1_i686.whl (133.0 kB view details)

Uploaded Python 2 Python 3

mpy_cross-1.11-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 (167.4 kB view details)

Uploaded Python 2 Python 3 macOS 10.10+ intel macOS 10.10+ x86-64 macOS 10.6+ intel macOS 10.9+ intel macOS 10.9+ x86-64

File details

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

File metadata

  • Download URL: mpy_cross-1.11-py2.py3-none-win_amd64.whl
  • Upload date:
  • Size: 151.8 kB
  • Tags: Python 2, Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3

File hashes

Hashes for mpy_cross-1.11-py2.py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 c854684c9c3cd4d0667bccafb19321221b2e3784b90c5090bb158eb6c1aee010
MD5 c2f8815f02a56853244db5421d0439c5
BLAKE2b-256 ce1706b06b738387703291b5798551515de840089779cf9cb0cb67e3f14f7689

See more details on using hashes here.

File details

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

File metadata

  • Download URL: mpy_cross-1.11-py2.py3-none-win32.whl
  • Upload date:
  • Size: 141.8 kB
  • Tags: Python 2, Python 3, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3

File hashes

Hashes for mpy_cross-1.11-py2.py3-none-win32.whl
Algorithm Hash digest
SHA256 048a8e5fc2e7eba38afebcdcbcf8378774d01a9ad8dbc29237a89fe6e2e61647
MD5 eb2768f27eea719fecaaa9c37a94b4ff
BLAKE2b-256 31207ac42be640add0f93fd3bf3c2fb196491d77623f1ae60f05fe923fe745ae

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for mpy_cross-1.11-py2.py3-none-manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 a88df22ea5e954d8357fec09c06d92e022f7e7bbb249dcc2b9e7bbe3931ddf63
MD5 dce8854686632df7526a346d883917d2
BLAKE2b-256 9112354067dd9118ecdca8d8f2507f46d3d8107a5de62fb3901f27857536651b

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for mpy_cross-1.11-py2.py3-none-manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 20fd05c112b0d9934490c9dcd7b59523830992bb8c4c37f2a40ebd551c2d98ed
MD5 66a4bbde696e999cb5ee562dd7dc17ef
BLAKE2b-256 98a70297ce151e9c5308a676f37c362f6996aeb14350a466218504a56554f839

See more details on using hashes here.

File details

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

File metadata

  • Download URL: mpy_cross-1.11-py2.py3-none-manylinux1_x86_64.whl
  • Upload date:
  • Size: 133.6 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3

File hashes

Hashes for mpy_cross-1.11-py2.py3-none-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 a991edb4eec01aa83f65ee30c9eb8658d9edf571ce1f9c6a29479177b0bd41d8
MD5 fc826608e6e18f4b7eeb296704cfa174
BLAKE2b-256 446442d4254252a2115244b075f74a25531b4a2399f01c9c7cbb3399e8e910f4

See more details on using hashes here.

File details

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

File metadata

  • Download URL: mpy_cross-1.11-py2.py3-none-manylinux1_i686.whl
  • Upload date:
  • Size: 133.0 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3

File hashes

Hashes for mpy_cross-1.11-py2.py3-none-manylinux1_i686.whl
Algorithm Hash digest
SHA256 7a25a9905e8bec37dfb26c7307fb93aa247ffd4ba4ba1169d057d1e31cc48d5b
MD5 a03b0fbf7a5c4914aba161d4bcc557ca
BLAKE2b-256 88b6dc5d8a9d0a89a2b2d3869bd41358ca3257b68fcf463424e24d46027987bf

See more details on using hashes here.

File details

Details for the file mpy_cross-1.11-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.11-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 d4a900b785b66fdeacbd79020dfe41a7cf8fd7e0ca039d912b3f6c04a7cb9042
MD5 577df0cc8da5c53cefe03c1259479521
BLAKE2b-256 b266dac9919335709889e56a05ecb030cd665e8fa7ca2a09bc11cdd823f93e81

See more details on using hashes here.

Supported by

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