Getting started with Thingy:91

This guide helps you get started with Thingy:91. It tells you how to update the Thingy:91 application and modem firmware and connect the Thingy:91 to nRF Cloud.

If you have already set up your Thingy:91 and want to learn more, see the following documentation:

Requirements for setting up the Thingy:91

Make sure you have all the required hardware and that your computer has one of the supported operating systems.

Hardware

  • nano-Subscriber Identity Module (SIM) card that supports LTE-M or Narrowband Internet of Things (NB-IoT) (The Thingy:91 comes shipped with an iBasis SIM card.)

  • Micro-USB 2.0 cable

  • Computer

Software

  • Microsoft Windows 10

  • macOS X, latest version

  • Ubuntu Linux, latest Long Term Support (LTS) version

Preparing for setup

Before you start updating the modem firmware and application on the Thingy:91, you must do some preliminary configurations.

Complete the following steps to prepare the Thingy:91 for setup:

  1. Install the nRF Connect Programmer application on the computer:

    1. Go to nRF Connect for Desktop Downloads.

    2. Download and install nRF Connect for Desktop.

    3. Open nRF Connect for Desktop.

    4. Find Programmer in the list of applications and click Install.

  1. Download the firmware:

    1. Go to Thingy:91 product website (downloads).

    2. Download the zip file containing the latest Thingy:91 application and modem firmware.

    3. Extract the zip file to a folder of your choice.

    The CONTENTS.txt file in the extracted folder contains the location and names of the different firmware images.

    Note

    You can also use these precompiled firmware image files for restoring the firmware to its initial image.

  2. Prepare the Thingy:91 hardware:

    1. Open the box and take out the Thingy:91 and the iBasis Subscriber Identity Module (SIM) card it comes shipped with.

    2. Plug the Thingy:91 into the computer using a micro-Universal Serial Bus (USB) cable.

    3. Power the Thingy:91 on by switching SW1 to the ON position.

      Thingy:91 Power switch (SW1)

      Thingy:91 Power switch (SW1)

Updating firmware

Thingy:91 (v1.5.0 or lower) comes preloaded with the nRF9160: Asset Tracker firmware and modem firmware on the nRF9160 System in Package (SiP), and the Connectivity bridge application firmware on the nRF52840 System on Chip (SoC) that enable the device to use the environment sensors and track the device using Global Positioning System (GPS). The data is transmitted to nRF Cloud.

Before you start using the Thingy:91, it is recommended that you update the application firmware to nRF9160: Asset Tracker v2. You must also update the modem firmware. You can do this through Universal Serial Bus (USB) (MCUboot) or an external debug probe using the Programmer application.

Note

To update the Thingy:91 through USB, the nRF9160 SiP and nRF52840 SoC bootloaders must be factory-compatible. The bootloaders might not be factory-compatible if the nRF9160 SiP or nRF52840 SoC has been updated with an external debug probe. To restore the bootloaders, program the nRF9160 SiP or nRF52840 SoC with the Thingy:91 firmware files through an external debug probe.

Updating firmware through USB

You can update the Thingy:91 application and modem firmware over Universal Serial Bus (USB) by using MCUboot, which is a secure bootloader that can be used to update applications without an external debugger.

Before you start, make sure the Thingy:91 is connected to the computer with a micro-USB cable.

Note

Do not unplug the Nordic Thingy:91 during this process.

To update the firmware, complete the following steps:

  1. Open nRF Connect for Desktop and launch the Programmer application.

  2. Scroll down in the menu on the left and make sure Enable MCUboot is selected.

    Programmer - Enable MCUboot

    Programmer - Enable MCUboot

  3. Update the nRF52840 System on Chip (SoC) application:

    1. Switch off the Thingy:91.

    2. Press SW4 while switching SW1 to the ON position.

      thingy91_sw1_sw4

      Thingy:91 - SW1 SW4 switch

    1. In the Programmer navigation bar, click Select device. A drop-down menu appears.

      Programmer - Select device

      Programmer - Select device

    2. In the menu, select the entry corresponding to your device.

      Note

      The device entry might not be the same in all cases and can vary depending on the application version.

    3. In the menu on the left, click Add file in the File section, and select Browse. A file explorer window appears.

      Programmer - Add file

      Programmer - Add file

    4. Navigate to the folder you downloaded and extracted from the Nordic Semiconductor website in the Download firmware step.

    5. Open the folder that contains the HEX files for updating over USB. See the CONTENTS.txt file for information on which file you need.

    6. Select the Connectivity bridge firmware file.

    7. Click Open.

    8. Scroll down in the menu on the left to Device and click Write.

      Programmer - Writing of HEX files

      Programmer - Writing of HEX files

      The MCUboot DFU window appears.

      Programmer - MCUboot DFU

      Programmer - MCUboot DFU

    9. In the MCUboot DFU window, click Write. When the update is complete, a Completed successfully message appears.

    10. Scroll up in the menu on the left to File and click Clear files.

  4. Update the modem firmware on the nRF9160 System in Package (SiP):

    1. Switch off the Thingy:91.

    2. Press SW3 while switching SW1 to the ON position.

      Thingy:91 - SW1 SW3 switch

      Thingy:91 - SW1 SW3 switch

    3. In the menu, select Thingy:91.

    4. In the menu on the left, click Add file in the File section, and select Browse. A file explorer window appears.

      Programmer - Add file

      Programmer - Add file

    1. Navigate to the folder you downloaded and extracted from the Nordic Semiconductor website in the Download firmware step.

    2. Find the modem firmware zip file with the name similar to mfw_nrf9160_*.zip and the number of the latest version.

      Note

      Do not extract the modem firmware zip file.

    3. Select the zip file and click Open.

    1. In the Programmer application, scroll down in the menu on the left to Device and click Write.

      Programmer - Update modem

      Programmer - Update modem

      The Modem DFU via MCUboot window appears.

      Programmer - Modem DFU via MCUboot

      Programmer - Modem DFU via MCUboot

    2. In the Modem DFU via MCUboot window, click Write. When the update is complete, a Completed successfully message appears.

  5. Update the nRF9160 SiP application:

    1. Switch off the Thingy:91.

    2. Press SW3 while switching SW1 to the ON position.

      Thingy:91 - SW1 SW3 switch

      Thingy:91 - SW1 SW3 switch

    3. In the Programmer navigation bar, click Select device. A drop-down menu appears.

      Programmer - Select device

      Programmer - Select device

    4. In the menu, select Thingy:91.

    5. In the menu on the left, click Add file in the File section, and select Browse. A file explorer window appears.

      Programmer - Add file

      Programmer - Add file

    6. Navigate to the folder you downloaded and extracted from the Nordic Semiconductor website in the Download firmware step.

    7. Open the folder that contains the HEX files for updating over USB. See the CONTENTS.txt file for information on which file you need.

    8. Select the appropriate Asset Tracker v2 firmware file.

      Note

      If you are connecting over NB-IoT and your operator does not support ePCO, select the file that has legacy Protocol Configuration Options (PCO) mode enabled.

    9. Click Open.

    10. Scroll down in the menu on the left to Device and click Write.

      Programmer - Writing of HEX files

      Programmer - Writing of HEX files

      The MCUboot DFU window appears.

      Programmer - MCUboot DFU

      Programmer - MCUboot DFU

    11. In the MCUboot DFU window, click Write. When the update is complete, a Completed successfully message appears.

    12. Scroll up in the menu on the left to File and click Clear files.

    You can now disconnect the Thingy:91 from the computer.

Next, you need to create an nRF Cloud account if you do not have one already.

Updating firmware through external debug probe

You can update the Thingy:91 application and modem firmware by using an external debug probe.

Note

The external debug probe must support Arm Cortex-M33, such as the nRF9160 DK. You need a 10-pin 2x5 socket-socket 1.27 mm IDC (Serial Wire Debug (SWD)) JTAG cable to connect to the external debug probe.

To update the firmware, complete the following steps. In these steps, the nRF9160 DK is used as the external debug probe.

  1. Open nRF Connect for Desktop and launch the Programmer application.

  2. Prepare the hardware:

    1. Connect the Thingy:91 to the debug out port on a 10-pin external debug probe using a JTAG cable.

      Thingy:91 - Connecting external debug probe

      Thingy:91 - Connecting external debug probe

      Note

      When using nRF9160 DK as the debug probe, make sure that VDD_IO (SW11) is set to 1.8 V on the nRF9160 DK.

    2. Make sure that the Thingy:91 and the external debug probe are powered on.

      Note

      Do not unplug or power off the devices during this process.

    3. Connect the external debug probe to the computer with a micro-USB cable.

      In the Programmer navigation bar, No devices available changes to Select device.

      Programmer - Select device

      Programmer - Select device

    4. Click Select device and select the appropriate debug probe entry from the drop-down list.

      You can identify the nRF9160 DK by the fact that it has three COM ports.

      Programmer - COM ports

      Programmer - COM ports

      If the three COM ports are not visible, press Ctrl+R in Windows or command+R in macOS to restart the Programmer application. The button text changes to the SEGGER ID of the selected device, and the Device Memory Layout section indicates that the device is connected.

  3. Update the nRF52840 System on Chip (SoC) application:

    1. Set the SWD selection switch SW2 to nRF52. See SWD Select for more information on the switch.

    2. In the menu on the left, click Add file in the File section, and select Browse. A file explorer window appears.

      Programmer - Add file

      Programmer - Add file

    3. Navigate to the folder you downloaded and extracted from the Nordic Semiconductor website in the Download firmware step.

    4. Open the folder that contains the HEX files for updating over USB. See the CONTENTS.txt file for information on which file you need.

    5. Select the Connectivity bridge firmware file.

    1. Click Open.

    2. Scroll down in the menu on the left to Device and click Erase & write. The update is completed when the animation in Programmer’s Device memory layout window ends.

      Programming using External debug probe

      Programming using External debug probe

    3. Scroll up in the menu on the left to File and click Clear files.

  1. Update the modem firmware on the nRF9160 System in Package (SiP):

    1. Set the SWD selection switch SW2 to nRF91.

    2. In the menu on the left, click Add file in the File section, and select Browse. A file explorer window appears.

      Programmer - Add file

      Programmer - Add file

    3. Navigate to the folder you downloaded and extracted from the Nordic Semiconductor website in the Download firmware step.

    4. Find the modem firmware zip file with the name similar to mfw_nrf9160_*.zip and the number of the latest version and click Open.

      Note

      Do not extract the modem firmware zip file.

    5. Select the zip file and click Open.

    6. In the Programmer application, scroll down in the menu on the left to Device and click Write.

      Programmer - Update modem

      Programmer - Update modem

      The Modem DFU window appears.

      Programmer - Modem DFU

      Programmer - Modem DFU

    7. In the Modem DFU window, click Write. When the update is complete, a Completed successfully message appears.

      Note

      If you have issues updating modem firmware, click Erase all before trying to update the modem again. In this case, the contents of the flash memory are deleted and the applications must be reprogrammed.

  2. Update the nRF9160 SiP application:

    1. Make sure the SWD selection switch SW2 is set to nRF91.

    2. In the menu on the left, click Add file in the File section, and select Browse. A file explorer window appears.

      Programmer - Add file

      Programmer - Add file

    3. Navigate to the folder you downloaded and extracted from the Nordic Semiconductor website in the Download firmware step.

    4. Open the folder that contains the HEX files for updating over USB. See the CONTENTS.txt file for information on which file you need.

    5. Select the appropriate Asset Tracker v2 firmware file.

  1. Click Open.

  2. Scroll down in the menu on the left to Device and click Erase & write. The update is completed when the animation in Programmer’s Device memory layout window ends.

    Programming using External debug probe

    Programming using External debug probe

  3. Scroll up in the menu on the left to File and click Clear files.

Creating an nRF Cloud account

You must sign up with nRF Cloud before you can start using the service.

To create an nRF Cloud account, complete the following steps:

  1. Open the nRF Cloud landing page and click Register.

  2. Enter your email address and choose a password, then click Create Account. nRF Cloud will send you a verification email.

  3. Copy the 6-digit verification code and paste it into the registration dialog box. If you do not see the verification email, check your junk mail for an email from no-reply@verificationemail.com.

    If you closed the registration dialog box, you can repeat Step 1 and then click Already have a code?. Then enter your email and the verification code.

You can now log in to nRF Cloud with your email and the password your chose. After logging in, you are directed to the dashboard view that displays your device count and service usage. Next, you need to activate the SIM card for the Thingy:91.

Activating the iBasis SIM card

If you are using the iBasis Subscriber Identity Module (SIM) card that comes shipped with the Thingy:91, you need to activate it in nRF Cloud.

To activate the SIM card, complete the following steps:

  1. Scratch off the bottom area on the back of the iBasis SIM to reveal the Personal Unblocking Key (PUK) code. The Integrated Circuit Card Identifier (ICCID) code is the first 18 digits printed on the back.

    iBASIS SIM

    iBASIS SIM

  2. Make a note of the ICCID and PUK codes. You will need them later.

  3. Pop out the nano-SIM card.

  4. Take off the silicone cover on the Thingy:91, and put the card in the nano-SIM card holder.

    Inserting SIM

    Inserting SIM

  5. Log in to the nRF Cloud portal.

  6. Click the large plus sign in the upper-left corner. The Add New window appears.

    nRF Cloud

    nRF Cloud

  7. In the Add New window, click LTE Device. The Activate SIM Card window appears.

    nRF Cloud - Add new device

    nRF Cloud - Add new device

    nRF Cloud - Activating SIM Card

    nRF Cloud - Activating SIM Card

  8. In the SIM ICCID field, enter the ICCID code that you wrote down.

  9. In the PUK field, enter the PUK code that you wrote down.

  10. Read the Terms and Privacy Policy. Then select the checkbox next to them.

  11. Click Activate SIM.

  12. The Activate SIM Card window appears.

  13. Enter your information in the Activate SIM Card window. Then, click Submit .

    The SIM Activated successfully message appears.

Connecting to nRF Cloud

To start using nRF Cloud, you need to associate the Thingy:91 to your user account.

To connect the Thingy:91 to nRF Cloud and to associate it with your user account, complete the following steps:

  1. Make sure the Thingy:91 is switched on.

  2. Wait for the Thingy:91 to connect to the LTE network and to nRF Cloud.

    After a few moments, the nRF Cloud user association process starts. This is indicated by white double pulse blinking of the Thingy:91’s RGB LED as indicated in Operating states.

  3. To complete the user association, open the nRF Cloud portal.

  4. Click the large plus sign in the upper-left corner. The Add New window appears.

    nRF Cloud

    nRF Cloud

  5. In the Add New window, click LTE Device.

    The Activate SIM Card window appears.

    nRF Cloud - Activating SIM Card

    nRF Cloud - Activating SIM Card

  6. Skip the Active SIM Card section by clicking on Skip this step.

    The Add LTE Device window appears.

    Add LTE Device

    Add LTE Device

  7. In the Device ID field, enter the text nrf- and after it the Thingy:91 International Mobile (Station) Equipment Identity (IMEI) code.

    The IMEI is the 15 digit code which you can find on a white sticker on the Thingy:91. The Device ID is case sensitive, so make sure all the letters are lower-case.

    PIN and IMEI on Thingy:91

    PIN and IMEI on Thingy:91

  8. In the PIN/HWID field, enter the Personal Identification Number (PIN) which is printed on the white sticker on the Thingy:91.

  9. Click Add Device.

    The message Device added to account. Waiting for it to connect… appears.

    Note

    If you see an error message, check the error code and see nRF Cloud REST API (v1) to find out what is causing the error.

  10. When the message has disappeared, go to the menu on the left and click Devices.

    You can see the Thingy:91 in your device list and all the sensor data being transmitted to the cloud from the Thingy:91. The LED on the Thingy:91 should be blinking green, which indicates that it is transmitting all the data to the cloud.

    Note

    It might take a while for the sensor data to appear in the nRF Cloud portal, depending on the duration of time GNSS uses to search for a fix.

Next steps

You have now completed getting started with the Thingy:91. See the following links for where to go next: