NB-IoT AT Commands

The SODAQ NB-IoT shield is using the uBlox Sara Nxx series NB-IoT module, which is based on the Neul chipset.
The AT Commands are depending on the firmware version of the NB-IoT module on your board.

The Neul chipset is controlled by AT Commands. These are ASCII commands that are sent to the module over the serial interface at 9600bps.
If the command is executed correctly, the module replies with OK.

You can write an embedded application that communicates with the module, or you can send the commands directly from your computer over the USB interface. To do so you must load the following Arduino sketch on your board:


#include "Arduino.h"

#define USB Serial 
#define UBLOX Serial1

#define USB SerialUSB
#define UBLOX Serial

#elif defined(ARDUINO_SAM_ZERO)
#define USB SerialUSB
#define UBLOX Serial1

#error "Please select a Sodaq ExpLoRer, Arduino Leonardo or add your board."

// Pin to turn on/off the nb-iot module
#define powerPin 7 
unsigned long baud = 9600;  //start at 9600 allow the USB port to change the Baudrate

void setup() 
  // Turn the nb-iot module on
  pinMode(powerPin, OUTPUT); 
  digitalWrite(powerPin, HIGH);

  // Start communication

// Forward every message to the other serial
void loop() 
  while (USB.available())
    uint8_t c = USB.read();

  while (UBLOX.available())

  // check if the USB virtual serial wants a new baud rate
  if (USB.baud() != baud) {
    baud = USB.baud();

Below are all the commands you need to establish a connection and send and receive data over NB-IoT.

You can reboot to bring it into a ‘clean’ mode by:


Depending on the firmware version of your board and the carrier you are using you will have to make some basic settings. For T-Mobile in the Netherlands you will have to set all NCONFIG settings to FALSE like:


While for Vodafone the SCRAMBLING setting must be TRUE.

Note that for the latest firmware on the 02B modules the syntax on a few commands is changed (notice the quotes).


You can check if these settings are now on FALSE by the following command:


Switch the radio off by:


Then select the CDP (in this case Ocean Connect on the T-Mobile platform).


On the latest firmware on the 02B modules this must be:


The Vodafone network doesn’t use the Neul messaging protocol so there is no need for the AT+NCDP command.

Then set the APN for authentication. For the T-Mobile Netherlands platform this is:


While for Vodafone it is:

 AT+CGDCONT=1, "IP","nb.inetd.gdsp"

Then switch on the radio. The previous commands are ‘sticky’ (stored in NVRAM) so only need to be entered once.
Next time you can just start with this command:


Then select the right band (in case of T-Mobile BAND 8, for Vodafone use Band 20)


Forces an attempt to select and register with the network operator (20416 is T-Mobile NL, while for Vodafone it is 20404)


You can now check the signal quality. Keep repeating this until you get something else than 99,99.


You can now check if you are attached to the network. If you get a value of 1 you are!


You can check your IP address. This is from a private IP range.


For T-Mobile you can ping the CDP if you like, while Vodafone allows you to ping


Also with this command the the IP address must be in quotes for the latest firmware on the 02B modules.

You are now ready to send the first message. On the T-Mobile network we use the messaging protocol. You can first switch on the Send Message Indicator (optionally)


And send a message (in this case 11 bytes, encode in HEX)


Also with this command the payload must be in quotes for the latest firmware on the 02B modules.


Check you send message queue:


Here are a few more commands.
Check the manufacturer of the module:


Check the firmware version:


Check the IMEI Number


Display network statistics: