Modem not responding?

Finally got the time to play with the NB-IOT shield.

Starting to get famillair with it. Using a UNO and the HTS221 sketch.
After some testing i got the , and 20416 on the modem serial.
On the debug serial i got the “connected succesfully”.
I thought that’s a start !

But wait …
Started to rewrite the sketch since i had no sensor attached.
Just trying to send zero’s.
But after uploading my sketch the modem was not responding anymore.
On modem serial only ATAT AT and no response from modem, resulting in a dreadfull “Failed to connect!” on the debug serial.

Tried everything to get a succes back with no luck.

Who can help me with this one?

Did you remove the shield before uploading a new sketch?

Yes i did. I know of the shared serial connection. Disconnected the shield every time i programmed the UNO.

Leonardo with native USB programming interface works for Sodaq NBIOT shield.

Do you send a carriage return and linefeed, \r\n ,after the AT commands?

Here is a simple example to send a String:

#include <Arduino.h>
#include <Wire.h>
// #include <SoftwareSerial.h> // Uno
#include <Sodaq_nbIOT.h>

#define DEBUG_STREAM Serial 
#define MODEM_STREAM Serial1

#elif defined(ARDUINO_AVR_UNO)
SoftwareSerial softSerial(10, 11); // RX, TX
// You can connect an uartsbee or other board (e.g. 2nd Uno) to connect the softserial.
#define DEBUG_STREAM softSerial 
#define MODEM_STREAM Serial

#define DEBUG_STREAM SerialUSB
#define MODEM_STREAM Serial

#elif defined(ARDUINO_SAM_ZERO)
#define DEBUG_STREAM SerialUSB
#define MODEM_STREAM Serial1

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

Sodaq_nbIOT nbiot;

void setup() 
  //while ((!DEBUG_STREAM));// Wait for serial monitor
	DEBUG_STREAM.println("\r\nSODAQ NB-IoT Hello World Arduino Example\r\n");

  nbiot.init(MODEM_STREAM, 7);


  if (nbiot.connect("", "", "20416")) {
      DEBUG_STREAM.println("Connected succesfully!");
  else {
      DEBUG_STREAM.println("Failed to connect!");

void loop() 
  // Create the message
  String message = "Hello world!!";

  // Print the message we want to send

  // Send the message

  // Wait some time between messages
	delay(10000); // 1000 = 1 sec

Finally got the time to free up my Leonardo from another project.

Tried the AT command passthrough program -> failed !
Tried the “Hello world” example from Jan (above this post) -> Geronimo !

I stick to the Leonardo for now.
Suspect that the modem for some reason does not like to connect to the UNO / software combination.

Thank you all for the replies.

After digging through the used code i found the reason:
I used hardcoded speed for the ublox serial connection:


The code that worked contains this serial speed config: