# Windows

## Install gcc toolchain

The installer will install itself into C:\Program Files (x86)\GNU Tools ARM Embedded\5.4 2016q3 (the path might vary with different versions).

Ensure it works by opening a command prompt and running the command arm-none-eabi-gcc. If it works you’ll get an error message saying “fatal error: no input files”.

## Install GNU Make

There’s a prebuilt version of GNU Make available at http://gnuwin32.sourceforge.net/packages/make.htm. Download the installer and run it. The PATH environment variable won’t be updated so you’ll have to set it manually. Open a command prompt and use the SETX command to set the path:

SETX PATH %PATH%;"C:\Program Files (x86)\GnuWin32\bin"


## Install Git

You’ll need Git to retrieve the firmware from GitHub. Go to https://git-scm.com/download/gnuwin32 and download the latest version of git.

Download the nRF SDK from http://www.nordicsemi.com/eng/nordic/download_resource/54291/47/66397134 Unzip the file into a suitable location. We’ve chosen C:\Users\corvus\Source\nrf52sdk:

Open a command prompt and clone the firmware. We’re putting it into C:\Users\corvus\Source\ee0x-firmware:

cd \Users\corvus\Source
git clone https://github.com/telenordigital/ee0x-firmware.git
cd ee0x-firmware


## Update the Makefile with the correct paths

The default paths in the Makefile must be set up for your environment. Open the file in your favorite editor and look for the lines with

• GNU_INSTALL_ROOT - This is the location for the gcc toolchain, omit the bin directory from the path. Use forward slashes instead of backslashes to avoid any escaping issues.
• FLASH_DRIVE - this is the name of the flash drive the Segger programmer will appear as. Typically this will be D:\ if you have only one drive attached to your computer.
• NRF52_SDK_ROOT - the location where you unzipped the nRF SDK files.
• RM - this is the delete command. For macOS and Linux this is rm but for Windows this is called del
• CP - this is the copy command used to copy the built hex file to the EE02 board. This is cp on macOS and Linux but for Windows this must be set to copy.
GNU_INSTALL_ROOT := C:/Program Files (x86)/GNU Tools ARM Embedded/5.4 2016q3
FLASH_DRIVE    := E:/
NRF52_SDK_ROOT := C:/Users/corvus/Source/nrf52sdk
RM := del /s
CP := copy


## Build the firmware

You are now ready to build the firmware. Open a command prompt, go to the directory with the firmware and type make:

cd \Users\corvus\Source\ee0x-firmware
make


You should have a file named nrf52lora.hex. Congratulations!