Getting Started with nRF Connect SDK and Zephyr

<\/script>\n
'; }, get iframeSnippet() { const domain = '{ SITE_DOMAIN }'; const type = '{ embed_type }'; const slug = '{ embed_slug }'; return ''; }, get activeSnippet() { return this.method === 'script' ? this.scriptSnippet : this.iframeSnippet; }, copySnippet() { navigator.clipboard.writeText(this.activeSnippet).then(() => { this.copied = true; setTimeout(() => { this.copied = false; }, 2000); }); } }" @keydown.escape.window="open = false" @click.outside="open = false">

Embed This Widget

Theme


      
    

Widget powered by . Free, no account required.

Setting up your first Nordic BLE project

| 2 min read

nRF Connect SDK Development

The nRF Connect SDK (NCS) is Nordic Semiconductor's unified development kit for nRF52, nRF53, and nRF54 SoC families. It is built on Zephyr RTOS and provides BLE, Wi-Fi, Thread, and Zigbee support through a curated set of libraries and samples.

SDK Setup

NCS uses west, a meta-tool for multi-repository workspaces.

pip3 install west
west init -m https://github.com/nrfconnect/sdk-nrf --mr v2.7.0 ncs
cd ncs && west update
pip3 install -r zephyr/scripts/requirements.txt

The nRF Connect for VS Code extension provides a GUI for board selection, build, and flash workflows.

Zephyr Kconfig for BLE

Key Kconfig symbols for BLE projects:

Symbol Effect
CONFIG_BT=y Enable BLE stack
CONFIG_BT_PERIPHERAL=y GAP Peripheral role
CONFIG_BT_CENTRAL=y GAP Central role
CONFIG_BT_GATT_CLIENT=y ATT">GATT Client
CONFIG_BT_CTLR_TX_PWR_PLUS_8=y Set +8 dBm TX power
CONFIG_MCUBOOT_BOOTLOADER_MODE_SWAP_WITHOUT_SCRATCH=y OTA swap mode

Device Tree

Zephyr uses Device Tree (DTS) to describe hardware. Board-specific overlays are placed in the boards/ directory and merged at build time.

/ {
    leds {
        compatible = "gpio-leds";
        led0: led_0 {
            gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
            label = "BLE Connected LED";
        };
    };
};

Building, Flashing, and OTA

west build -b nrf52840dk_nrf52840 -- -DCONFIG_BT_DEVICE_NAME='"MySensor"'
west flash

OTA update support uses MCUboot with the SMP protocol over BLE:

OTA Method Transport NCS Config
nRF DFU BLE (SMP) CONFIG_MCUMGR_TRANSPORT_BT=y
FOTA LTE-M/NB-IoT CONFIG_FOTA_DOWNLOAD=y
Matter OTA Wi-Fi/Thread Matter OTA Provider

The SDK supports both software and hardware Link Layers. Hardware LL (closed-source) provides better radio performance; software LL enables SoC portability.

Use the BLE Chip Selector to compare nRF52 variants by flash, RAM, and crypto acceleration — critical for sizing MCUboot partitions. For GATT service patterns, see GATT Server Implementation.

Frequently Asked Questions

The legacy nRF5 SDK is a standalone Nordic-specific SDK based on a proprietary RTOS and SoftDevice Bluetooth stack. nRF Connect SDK (NCS) is built on the open-source Zephyr RTOS and uses Zephyr's BLE host stack, making applications more portable and compatible with the broader Zephyr ecosystem. Nordic targets all new hardware development on NCS.

No. NCS uses Zephyr's built-in BLE host stack (subsys/bluetooth) combined with Nordic's nRF BLE Controller (formerly SoftDevice Controller, now open-source). The monolithic SoftDevice firmware blobs (S132, S140) used in the legacy SDK are not required in NCS projects.

The nRF52840 DK (PCA10056) is the most commonly recommended starter board because it supports USB, all BLE 5.3 features, 1 MB flash, 256 KB RAM, and has Arduino-compatible headers. The nRF52833 DK is a good second choice for size-constrained projects. Both are fully supported by NCS with pre-built board definitions.

Kconfig is a hierarchical configuration system where each module exposes boolean and integer symbols (e.g., CONFIG_BT=y, CONFIG_BT_MAX_CONN=4). Values are set in a prj.conf file in the application root. Running west build triggers CMake to resolve all Kconfig dependencies and generate an autoconf.h used by the compiler. Conflicting or missing dependencies cause build errors with descriptive messages.

Yes, our guides range from beginner introductions to advanced topics. Each guide indicates its difficulty level and prerequisites so you can find the right starting point.