Setup mbed CLI using ARM gcc on BoW (Bash on Windows, almost the same as Ubuntu)

Basically, follow instructions below.

https://github.com/ARMmbed/mbed-cli

install the toolchain

install native toolchain

$ sudo apt-get install build-essential

install cross-development toolchain for embedded ARM (Cortex-M)

for Ubuntu 14.04

$ sudo add-apt-repository ppa:team-gcc-arm-embedded/ppa
$ sudo apt-get update
$ sudo apt-get install gcc-arm-embedded

for Ubuntu 16.04

$ sudo apt-get install gcc-arm-none-eabi

install dependencies

install python 2.7

$ sudo apt-get install python
$ sudo apt-get install python-pip

install scm

$ sudo apt-get install git
$ sudo apt-get install mercurial

install mbed-cli

from source

$ git clone https://github.com/ARMmbed/mbed-cli
$ cd mbed-cli
$ sudo python setup.py install
$ mbed config --global GCC_ARM_PATH /usr/bin

from pipy

$ sudo pip install mbed-cli

test mbed CLI

$ mbed new mbed-os-program
$ cd mbed-os-program
$ vi main.cpp
  write some code
$ mbed toolchain GCC_ARM
$ mbed target NUCLEO_F401RE
$ mbed compile

Your binary will be created "./BUILD/NUCLEO_F401RE/GCC_ARM/mbed-os-program.bin"


Please log in to post comments.