Mynewt relies on two command line utilities (newt and newtmgr), both of which are described elsewhere in this learning guide, as well as the presence of an ARM cross-compiling toolchain (arm-none-eabi-gcc, etc.).

Both of these need to be installed and available on your system to work with Mynewt projects.

Cut auto-reset trace

Windows serial has a somewhat annoying thing it does where it toggles the DTR/RTS lines when you open a serial port. This will make debugging impossible since you keep resetting the board. Before you continue you must cut the trace-jumper on the bottom of the board:

Install newt & newtmgr Binaries

The official Mynewt documention for setting devices up on Windows is available here newt & newtmgr.

  • Firstly you need to install MSYS2/MinGW and Git, Our guide on Mingw and git installation may be useful!
  • Add a new user variable named MSYS2_PATH_TYPE and set the value to inherit in your Windows environment. This enables the MSYS2 and MinGW bash to inherit your Windows user Path values.
  • Add the MinGW bin path to your Windows Path. For example: if you install MSYS2/MinGW in the C:\msys64 directory, add C:\msys64\usr\bin to your Windows Path. Note: If you are using Windows 10 WSL, ensure that you use the C:\msys64\usr\bin\base.exe and not the Windows 10 WSL bash.
  • Download the latest newt & newtmgr binaries from http://www.apache.org/dyn/closer.lua/mynewt/ (click on suggested hosting mirrors), currently the latest version is apache-mynewt-1.5.0. You should now have both apache-mynewt-newt-bin-windows-1.5.0.tgz and apache-mynewt-newtmgr-bin-windows-1.5.0.tgz on your PC.
  • Extract them and copy newt.exe and newtmgr.exe to your C:\msys64\usr\binand you are good to
newt & newtmgr binaries are tested with Windows 7 and 10 on 64-bit platform. If you are using different (older) Windows version, please refer to mynewt guide to install it from source.

You can test it by running newt and newtmgr from the shell

$ newt version
Apache Newt version: 1.5.0

$ newtmgr version
Apache Newtmgr 1.5.0

ARM Cross-Compiler

You will also need an cross-compiling toolchain for the ARM architecture, specifically GCC 4.9, since newt will call arm-none-eabi-gcc from the command line.

For details on installing this see the official Mynewt documentation here: https://mynewt.apache.org/latest/get_started/native_install/cross_tools.html

NOTE: arm-none-eabi-gcc also needs to be available in the system PATH variable to work with newt!

This guide was first published on Aug 18, 2017. It was last updated on Aug 18, 2017.

This page (Native Installation (Win)) was last updated on Aug 18, 2017.

Text editor powered by tinymce.