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:
-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

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.9.3-py2.py3-none-win_amd64.whl (109.8 kB view details)

Uploaded Python 2 Python 3 Windows x86-64

mpy_cross-1.9.3-py2.py3-none-win32.whl (102.1 kB view details)

Uploaded Python 2 Python 3 Windows x86

mpy_cross-1.9.3-py2.py3-none-manylinux2014_armv7l.whl (74.3 kB view details)

Uploaded Python 2 Python 3

mpy_cross-1.9.3-py2.py3-none-manylinux2014_aarch64.whl (87.1 kB view details)

Uploaded Python 2 Python 3

mpy_cross-1.9.3-py2.py3-none-manylinux1_x86_64.whl (75.7 kB view details)

Uploaded Python 2 Python 3

mpy_cross-1.9.3-py2.py3-none-manylinux1_i686.whl (75.0 kB view details)

Uploaded Python 2 Python 3

mpy_cross-1.9.3-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 (88.5 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.9.3-py2.py3-none-win_amd64.whl.

File metadata

File hashes

Hashes for mpy_cross-1.9.3-py2.py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 170504fb5e6d7a3e134b23c6bc042a0acbfd34ef2af2b403238fe48c9965bb45
MD5 4d6f1e368048d1c06dc61274ebe43e78
BLAKE2b-256 be89c3c6850b0f6f1795065808dcafc2a21d6e3c49b6cd8d8ffc0c4f060a9a61

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for mpy_cross-1.9.3-py2.py3-none-win32.whl
Algorithm Hash digest
SHA256 30f568b143ec223965959f62d07cafa685b5a4fd305bc23b7c57157a9da82de1
MD5 dc50bd909786936ddb23755ac30e8c7a
BLAKE2b-256 befffc85fe1edcc61b6ce1c998f3459e933d0886bc2279ade613ccf7c9071f5e

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for mpy_cross-1.9.3-py2.py3-none-manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 1135116c43613cb9d07ead14ef0958e8286a57300a2181fac675e1d33bbaa67c
MD5 272f5a42d6f40150427e29c19dc5c138
BLAKE2b-256 a2eafcb5896e62bb3ff434d8cd1da96d94ad8cb99ae9874c573c3ce9e9c94e33

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for mpy_cross-1.9.3-py2.py3-none-manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 f6f9423825c38da42421abdbe1f75961b32144ec27ff49efad945ae8b73e37a0
MD5 6132b8f2c15fddb89830edeb112607a9
BLAKE2b-256 ff1af73792a650e0d0346ebab451191bfd788a482484142cdf5c813ec9ea1a71

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for mpy_cross-1.9.3-py2.py3-none-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 72fc793b152e75f37f16702916e019265349f068931643f82a5788b666547756
MD5 410548ef1ceb808c8af18edfc15076c7
BLAKE2b-256 b766d2a75d71c8ed23835f95d70a575b93ca4ba9ca5bc57e4048abcac33069a3

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for mpy_cross-1.9.3-py2.py3-none-manylinux1_i686.whl
Algorithm Hash digest
SHA256 d7bb2d59840504f481fca782e078c831b03f579911059feb387eeedefbe2ccb7
MD5 077e1732fc976ade57b6f37f96b03603
BLAKE2b-256 a7be70dd6e78fdc9a83e996769203c4d385cd7d590445a5ef97a15725e2d0ddf

See more details on using hashes here.

Provenance

File details

Details for the file mpy_cross-1.9.3-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.9.3-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 16f40622d0fb2b95fc41d47e62e0a499e1c6d0f1c5f47eb3a33eaee3e491ba20
MD5 72d3266564f307567ccbeb764f8afffd
BLAKE2b-256 818c6e10745e07b4bccfa79137ad1584b3b8f334f8fe1c9668f57759838dfce0

See more details on using hashes here.

Provenance

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