nRF9160 Thing Plus Hookup Guide

Pages
Contributors: Circuit Dojo, Ell C
Favorited Favorite 0

SDK Setup - Mac

This page is all about getting your Mac compiling code for the nRF9160 Thing Plus. Run into trouble during the process? Post your questions on the community forum.

IDE Setup

Install or use the code editor of your choice. I personally use Microsoft Visual Studio Code. The download link is here or you can download by clicking the button below. If you decide to use Visual Studio Code, make sure you install the C/C++ and Cortex-Debug extentions using the built in extension marketplace.

Installing SDK

Installing the latest SDK is a snap and only takes a few steps. Let's walk through them here.

nRF Connect For Desktop is the utility that you can use to manipulate your nRF9160 Thing Plus. Download and install nRF Connect For Desktop.

Mac download highlighted

Copy the app to your Applications folder

nrf copy dialog

Open up the app and install the Toolchain Manager

Dialog to install toolchain manager

Then open it up.

Click on the small arrow to the right of the "Open" button

Scroll to the bottom and click Install package from other source:

Small text all the way at the bottom of the dialog

Then paste this url into the box and click OK:

language:c
http://developer.nordicsemi.com/.pc-tools/toolchain/ncs-toolchain-v1.5.0-20210225-607a0e0-minimal.dmg

Install toolchain package dialog - paste the above into the dialog and click okay

The download and install will take a few minutes. Hang out, take a walk, sing a song, and come back later.

Finally, once installed you'll have a dropdown that you can access. Click on it and then the Open Terminal option.

To get the nRF9160 Thing Plus examples we'll update /opt/nordic/ncs/v1.4.1/nrf/west.yml.

First in the remotes section add:

language:c
name: circuitdojo
url-base: https://github.com/circuitdojo

Then in the projects section add at the bottom:

language:c
name: nfed
repo-path: nrf9160-feather-examples-and-drivers
revision: v1.4.x
path: nfed
remote: circuitdojo

Then run west update in your freshly created terminal session. This will fetch the nRF9160 Thing Plus examples.

Installing newtmgr

If you're on a newer version of OSX you'll need to install the drivers.

For loading code to your nRF9160 Thing Plus, you'll need to download and copy a custom version of newtmgr. Open a terminal window and run:

language:c
cd ~/Downloads
wget "https://docs.jaredwolff.com/files/newtmgr/darwin/newtmgr.zip"
unzip newtmgr.zip
mv newtmgr /opt/nordic/ncs/v1.4.1/toolchain/bin
rm newtmgr.zip

Then you'll need to add your serial profile to make it easier to download/update your device:

language:c
newtmgr conn add serial type=serial connstring='dev=/dev/tty.SLAB_USBtoUART,baud=1000000'

If you have multiple Silicon Labs CP2102 connected to your machine your serial port may be named differently. I recommend you unplug all devices that could be named tty.SLAB_USBtoUART to ensure you're targeting the correct device during programming.

For more info in using newtmgr checkout the programming section.

Now you can get to playing around with some of the nRF9160 Thing Plus example code! Remember you'll always have to open a terminal using the Toolchain Manager to build code!