Instructions
# Install GNU ARM embedded GCC on macOS.
brew tap ArmMbed/homebrew-formulae
brew install arm-none-eabi-gcc
# Get the MicroPython sources.
git clone https://github.com/micropython/micropython
cd micropython
# Build MicroPython cross-compiler.
make -j6 --directory=mpy-cross
# Build firmware for specific architecture and board.
make -j6 --directory=ports/stm32 BOARD=PYBD_SF2
With module freezing
export FROZEN_MPY_DIR=~/dev/hiveeyes/sources/hiveeyes-micropython-firmware/dist-packages
With threading
Unsure which counts, so let’s just define both.
export MICROPY_PY_THREAD=1
export CFLAGS_EXTRA='-DMICROPY_PY_THREAD=1'
References
- micropython/ports/stm32 at master · micropython/micropython · GitHub
- GitHub - ARMmbed/homebrew-formulae: homebrew ("the missing package manager for OS X") formulae from the mbed team.
- http://dfu-util.sourceforge.net/
- travis: Build an stm32 board with threading enabled to test it with CI. · micropython/micropython@8f55a8f · GitHub