Insert the MicroSIM card in the NB-IoT radio module as indicated on the image below
Attach NB-IoT radio module & antenna (without the range is very limited). If attached properly you will notice that one UBee pin VBAT 2G/3G is not inserted in the MBili Bee Socket
Connect the Sodaq Mbili to your computer over USB
Make sure the Mbili board is powered up by flipping the power switch SW2 to ON
Write your first program
Load the example sketch
Open your Arduino IDE
Go to Tools > Board and select the SODAQ Mbili board as indicated on the image below
Under Tools > Port select the USB port automatically assigned by your computer to which your device is connected
In your Arduino IDE, go to and open File > Examples > arduino-nbiot-sdk-master > counter.
Setup device credentials
Browse and open the keys.h file located in the arduino-nbiot-sdk-master Library folder, by default you can find it in:
Mydocuments/Arduino/Libraries/Arduino-nbiot-sdk-master folder for Windows
Documents/Arduino/Libraries/Arduino-nbiot-sdk-master folder for MacOS
Change the DeviceID and DeviceToken values with the values that can be found under Device Settings > Authentication section of your device in the Maker Application. In the keys.h file you will notice that the APN is already pre configured and should not be changed.
Run the example
Simply hit the upload icon in the Arduino IDE. This will save the sketch, compile it and upload it to your Arduino.
NOTE: After uploading, you might need to flip the power switch SW2 on the Sodaq Mbili OFF and back ON to make sure the Mbili reboots and starts up our sketch.
Now your device should increase the value of a counter and send each 10 seconds its state to AllThingsTalk. This will be represented by an incrementing Asset “Counter” in the Maker application.
On first use it can take some time (up to 1,5min) to set up the NB-IoT connection.
Alternatively, you can also open the Tools > Serial monitor of the Arduino IDE. This can be very useful when debugging your own sketches. Make sure you select the correct COM port to listen (under Tools > Port ). When the monitor is open, make sure the Baud rate is set to 57600*
As a next step, please try these basic experiments connecting the Grove sensors from the kit
Count visits | count visits for just-in-time facility maintenance
The SDK supports either CBOR or our custom ABCL language file to code and decode your messages. You can add multiple sensor values into 1 payload. Please read how to work with binary payloads for more information about CBOR and ABCL language files. Below is an example how to send a simple boolean value in a binary format.