Skip to main content
Planet Zephyr

Using the Nordic nRF7002-DK for Zephyr Training

By April 27, 2023No Comments

Golioth hosts a lot of training on Zephyr RTOS. It’s the fastest growing RTOS and Zephyr is great for Golioth because it delivers a ton of cross-platform support, includes a built in networking stack, and it’s an open source project guided by the Linux Foundation. The only problem we’ve had is finding target hardware to use during training. Until now! The nRF7002 Development Kit from Nordic is what we are targeting for upcoming training. Let’s look at why that is.

Golioth’s hardware needs for Zephyr Training

Nordic nRF7002-DK board

Nordic’s new nRF7002 Development Kit

We have a few base requirements when choosing hardware for training:

  • In-Tree Zephyr support
  • WiFi – although we support Cellular, WiFi, Ethernet, and Thread, we find WiFi is ubiquitous and usually the most straight-forward to get connected during training.
  • USB-based firmware update we don’t want to require a separate programmer
  • User Interface – there should be some way for the user to interact with the hardware
  • Integrated sensor – Golioth makes it easy to stream sensor data to the cloud, it’s nice to show this happening live during training
  • All-in-one – we don’t want the added complexity of the user having to wire up modules.
  • Inexpensive – there’s a chance people will never use this device again after the training. So it should be inexpensive, and generate as little waste as possible.
  • Available – see also: chip shortage

Released earlier this year, the Nordic nRF7002-DK ticks almost all of these boxes. It includes the nRF7002 which is a WiFi connectivity IC, along with the nRF5340 that runs the applications. It uses the Segger on-board programmer via the USB port. It includes two user buttons and two LEDs for user interaction. There is no integrated sensor but we’re working around that.

It is inexpensive at an MSRP of $59, however production is still ramping up since the product launch. As a result, there are some stock shortages right now which we hope will improve soon. This board is a great way to try out Golioth, Nordic, and Zephyr all at the same time. All around, we think it’s likely that anyone learning to use Zephyr will find this board useful far beyond the Golioth session, helping to reduce the chance of training hardware becoming e-waste.

An early glimpse at the code

If you happen to already have an nRF7002-DK on your bench, you can give our training repository an early look. We’d love to have your feedback!

nRF7002dk simulating temperature sensor readings

Temperature values streaming to Golioth

At the time of writing, only one module has been published. It’s a “kitchen sink” demo that shows off all of the Golioth services.

I mentioned we are working around the lack of a built-in sensor, this is done with an algorithm that simulates temperature sensor data. That’s being recorded on the cloud using the LightDB Stream service which adds timestamps to each data set received.

The user-interface includes a blinking LED for output. Pressing the buttons on the board selects which of the two LEDs is currently blinking, and reports that LED number to the Golioth LightDB State service. The blinking speed can be updated remotely using our Settings service. And of course our Remote Logging service is enable on this demo so you can access the logging output as the application runs.

If you want to try this out, just follow the README and keep a few things in mind:

  1. Use `west init` to set up your workspace, and do not directly clone. That way, when you call `west update` it will pull in all dependencies (including the nRF Connect SDK and Golioth Zephyr SDK)
  2. These boards will require WiFi credentials to connect to your network, and device credentials to connect to Golioth. Both are entered via serial terminal after flashing firmware, and will be persistent (in the Zephyr settings partition) over power cycle and future firmware upgrades

Wait, what about the Zephyr training?

This post is a sneak peek. We are still actively developing this new training module and will add more subdirectories to this repository over time. I recommend starring the repo so you are notified.

The most immediate plans are to implement modules that show how to blink an LED using timers and threads, and how to react to button input. We’ll show how to define your own LEDs and buttons using Devicetree overlays and how to add sensors and enable the in-tree drivers. Of course we’d love your feedback on what else to include, please let us know!

You’re invited to Golioth’s free Zephyr training

Get up to speed with Zephyr and Golioth, sign up for our free training which is held virtually. You’ll be the first notified when our next session is scheduled.

Zephyr Project