Skip to content

Building and Running a first example

This section details how to build and run the Hello World example.

Before you start building, remember to set up the nRF5 SDK development environment first. See Setup the nRF5 SDK for details.

Building the example

Now it's ready to build the first example. Will use the Hello World example here to keep it simple.

The Hello World example shows how to blink the RGB LED and print Hello World! to the console. It is located in pitaya-go/examples/peripheral/hello_world.

Open terminal and navigate to the directory with the example Makefile:

cd ./pitaya-go/examples/peripheral/hello_world/armgcc

Run make to build the example:

make

Programming the firmware

After compiled, the firmware is located in hello_world/armgcc/_build with the name nrf52840_xxaa.hex.

Now let Pitaya Go enter the DFU (Device Firmware Update) mode, and program the firmware using the nRF Connect for Desktop tool.

Tip

See Programming section for details about how to program your Pitaya Go.

Testing

Once the firmware is programmed successfully, observe that the LEDs are blinking:

Run a terminal application like PuTTY or screen to print Hello World!:

screen /dev/cu.usbmodemD2E39D222D781 115200
where /dev/cu.usbmodemD2E39D222D781 is the port name of the board. Replace it with your owns.

Next Steps

Check out more nRF5 SDK examples for Pitaya Go:

Create an Issue

Interested in contributing to this project? Want to report a bug? Feel free to click here: