Skip to main content

How to Use NX15 with PlatformIO

NX15 with PlatformIO for building, uploading, and monitoring applications

Use the PlatformIO IDE extension for Visual Studio Code to build an Arduino application for the KORLINX NX15 Dev Kit and upload it through a SEGGER J-Link probe.

Package baseline

This guide uses KORLINX-PlatformIO 1.1.0, board ID nx15, and KORLINX ArduinoCore-zephyr 0.2.3.

The repository provides an NX15 Blink environment and supports J-Link upload. PlatformIO debugging with pio debug is not supported for NX15 in this release.

What you will build​

Create a PlatformIO project that switches the NX15 user LED on and off every 500 ms. PlatformIO compiles the sketch with the KORLINX Zephyr-based Arduino core and programs the board through J-Link over SWD.

The development setup uses two host connections:

  • J-Link over SWD for firmware upload.
  • USB Type-C through the onboard USB-to-UART bridge for board power and Serial communication.

Before you begin​

Required hardware​

ItemRequirement
Development boardKORLINX NX15 Dev Kit
Debug probeSEGGER J-Link compatible with the nRF54L15
Debug wiringSWD cable or adapter for NRESET, SWDCLK, GND, SWDIO, and VTref
USB cablesData-capable cables for the NX15 Dev Kit and J-Link
Host computerA system supported by Visual Studio Code, PlatformIO Core 6, and J-Link

Required software​

  • Visual Studio Code.
  • PlatformIO IDE.
  • Git for installing the KORLINX platform from GitHub.
  • SEGGER J-Link software if required by the host setup.
  • USB-to-UART drivers or serial-port permissions where required.

Step 1: Install PlatformIO IDE​

  1. Install Visual Studio Code.
  2. Open Extensions in the Activity Bar.
  3. Search for PlatformIO IDE and install the extension published by PlatformIO.
  4. Wait for PlatformIO Core to initialize, then reload Visual Studio Code if requested.
  5. Open a PlatformIO terminal and verify the included PlatformIO Core version:
pio --version

KORLINX-PlatformIO 1.1.0 declares PlatformIO Core 6 or later.

PlatformIO IDE extension installed in Visual Studio Code

Install the official PlatformIO IDE extension in Visual Studio Code.

Step 2: Install KORLINX-PlatformIO​

Open a PlatformIO terminal and install the tagged platform globally:

pio pkg install -g -p https://github.com/KORLINX/KORLINX-PlatformIO.git#1.1.0

Pinning #1.1.0 keeps the platform, framework, and tools consistent with this guide. When the URL has no tag, PlatformIO uses its cached repository revision until the package is updated.

The NX15 configuration supplied by this release is:

SettingNX15 value
Platform packagekorlinx 1.1.0
Board IDnx15
Display nameKORLINX NX15 nRF54L15
MCUnRF54L15, 128 MHz Cortex-M33
FrameworkArduino
Arduino coreKORLINX ArduinoCore-zephyr 0.2.3
Variantnx15_nrf54l15_cpuapp
Upload protocolJ-Link
Sketch offset0x60000

Step 3: Create an NX15 project​

  1. Open PlatformIO Home > New Project.
  2. Name the project nx15_blink.
  3. Select KORLINX NX15 nRF54L15.
  4. Select the Arduino framework.
  5. Choose a project location and finish project creation.
New Project action in PlatformIO Home

Open PlatformIO Home and select New Project.

PlatformIO Project Wizard configured for KORLINX NX15 nRF54L15 and Arduino

Name the project, then select KORLINX NX15 nRF54L15 and the Arduino framework.

If NX15 does not appear after package installation, reload Visual Studio Code. You can also create a project folder manually with platformio.ini and src/main.cpp.

Project itemPurpose
platformio.iniSelects the platform release, NX15 board, framework, and serial settings
src/main.cppContains the application source
include/Stores project headers
lib/Stores project-local libraries
.pio/Contains generated build files and downloaded packages

Step 4: Configure platformio.ini​

Replace the generated configuration with:

[platformio]
default_envs = nx15

[env:nx15]
platform = https://github.com/KORLINX/KORLINX-PlatformIO.git#1.1.0
board = nx15
framework = arduino
monitor_speed = 115200
NX15 PlatformIO project with board, framework, and monitor speed configured

Configure the NX15 environment and set the Serial Monitor speed to 115200 baud.

The full repository URL lets the project resolve the pinned release directly. If the platform was installed globally in Step 2, the repository examples use the shorter platform = korlinx.

When several J-Link probes are connected, specify the selected probe serial number:

upload_port = 12345678

Replace 12345678 with the serial number printed on or reported by the selected J-Link probe.

Replace src/main.cpp with the NX15-compatible Blink example:

#include <Arduino.h>

bool on;

void setup() {
pinMode(LED_BUILTIN, OUTPUT);
}

void loop() {
on = !on;
digitalWrite(LED_BUILTIN, on);
delay(500);
}

This follows the Blink example supplied by KORLINX-PlatformIO 1.1.0. PlatformIO compiles main.cpp as C++, so include Arduino.h explicitly.

NX15 Dev Kit connected to a SEGGER J-Link probe through SWD

J-Link programs the NX15 through the board's SWD interface.

NX15 Dev Kit SWD pads labeled NRESET, SWDCLK, GND, SWDIO, and 3V3
J-Link signalNX15 padFunction
nRESETNRESETTarget reset
SWCLKSWDCLKSWD clock
GNDGNDCommon ground
SWDIOSWDIOBidirectional SWD data
VTref3V3Target-voltage reference
  1. Disconnect the NX15 Dev Kit and J-Link from USB before wiring the SWD signals.
  2. Connect the probe signals to the corresponding NX15 pads.
  3. Connect the NX15 Dev Kit to the host through USB Type-C for power and USB serial communication.
  4. Connect the J-Link probe to the host through USB.

VTref senses the board's 3.3 V I/O level. Power the board through its intended input unless the documentation for the exact probe and board setup explicitly permits probe-supplied target power.

Step 7: Build and upload​

Run PlatformIO: Build, or use:

pio run -e nx15
Successful PlatformIO build of the NX15 Blink application

The Build task compiles the NX15 application and reports memory usage and SUCCESS.

After the build succeeds, select Project Tasks > nx15 > General > Upload, or run:

pio run -e nx15 -t upload
Successful PlatformIO upload to NX15 through J-Link

The Upload task programs NX15 through J-Link and reports SUCCESS.

The NX15 sketch runs inside the loader firmware supplied by ArduinoCore-zephyr. During the first upload, the J-Link workflow writes both the loader and the sketch. During later uploads, J-Link skips matching flash regions, so it writes only the changed content.

The board manifest places the sketch at 0x60000. Use the packaged uploader instead of manually programming an arbitrary binary at a guessed address.

Debugging support

KORLINX-PlatformIO 1.1.0 supports NX15 upload through J-Link. Interactive debugging with pio debug is not supported yet.

Step 8: Confirm the result​

After uploading and resetting the board, the user LED should change state every 500 ms. If the LED does not blink:

  • Confirm that the selected environment and board are both nx15.
  • Check that J-Link detected nRF54L15_M33.
  • Confirm that the upload completed without an error.
  • Check the NX15 variant and LED mapping supplied by core 0.2.3.
  • Reset or power-cycle the board, then test again.

Optional: Verify Serial output​

For NX15, Serial uses the board's USB-to-UART interface at 115200 baud. Replace src/main.cpp with:

#include <Arduino.h>

void setup() {
Serial.begin(115200);
}

void loop() {
Serial.println("KORLINX NX15 PlatformIO is running");
delay(1000);
}

Build and upload the sketch again, then list the available ports:

pio device list

Open PlatformIO: Serial Monitor, or run:

pio device monitor --port YOUR_SERIAL_PORT --baud 115200
PlatformIO Upload and Monitor task showing repeated NX15 Serial output

Upload and Monitor programs NX15 through J-Link and displays the USB serial output.

Replace YOUR_SERIAL_PORT with the USB serial port reported by the operating system. This connection carries serial data; firmware upload continues to use J-Link over SWD.

NX15 code examples​

The examples directory on the repository's main branch provides the following NX15 projects. These examples use platform = korlinx, board = nx15, and framework = arduino.

Main branch and release baseline

The examples below reflect the repository's main branch. The installation and upload procedure earlier in this guide remains pinned to release 1.1.0. Content on main may change before the next tagged release.

ExampleWhat it demonstrates
arduino-blinkBlinks LED_BUILTIN every 500 ms
arduino-ledsCycles through the four Dev Kit LEDs
arduino-fadeFades the red LED with PWM
arduino-buttonCounts button presses and controls the blue LED
arduino-analogReads NX15 analog aliases A0–A4; J3 exposes A0 and A1
arduino-serial-echoEchoes complete lines received through the USB-to-UART interface
arduino-imuReads acceleration and angular rate from the onboard LSM6DSL
arduino-shtc3Reads temperature and relative humidity from the onboard SHTC3

The repository also contains arduino-ble-uart and arduino-usb-serial. Their current platformio.ini files do not define an NX15 environment, so they are not included as NX15 examples.

Download and run an example​

Clone the repository, then build the required project with its nx15 environment:

git clone https://github.com/KORLINX/KORLINX-PlatformIO.git
cd KORLINX-PlatformIO
pio run -d examples/arduino-blink -e nx15
pio run -d examples/arduino-blink -e nx15 -t upload

Replace arduino-blink with another project name from the table. For an example that prints output, open the NX15 USB serial port at 115200 baud:

pio device monitor --port YOUR_SERIAL_PORT --baud 115200

Troubleshooting​

SymptomWhat to check
NX15 is absent from the project wizardInstall KORLINX-PlatformIO 1.1.0 globally and reload Visual Studio Code
Unknown board or package errorUse board = nx15 and the tagged platform URL
UnknownBoard: Unknown board ID 'nx15' with platform = korlinxThe globally installed KORLINX platform may predate 1.1.0; update it or use the pinned repository URL in platformio.ini
Build uses nRF52840Check that the environment did not select nx40; NX15 must report nRF54L15
J-Link cannot detect NX15Check power, VTref, GND, SWDIO, SWDCLK, NRESET, cable orientation, and probe support
The wrong probe is selectedAdd the required J-Link serial number as upload_port
First upload takes longerThe first upload writes the loader and sketch; later uploads can skip matching flash
pio debug failsInteractive PlatformIO debugging is not supported for NX15 in release 1.1.0
Serial Monitor is blankSelect the USB serial port, use 115200 baud, and confirm host serial permissions