Register IoT devices

In order for an appliance or other asset to become "smart" and connect to an IoT backend, it must have sensors that can take device readings and send that information to the cloud. We call these sensors IoT devices.

Field technicians might need to interact with IoT devices in several ways:

  1. If a field technician is installing an entirely new asset like an air conditioner, and that air conditioner has an embedded IoT device or devices, they must register that device with the appropriate IoT backend in order for it to start working.

  2. Field technicians might need to service an existing asset, and then install a new IoT device that will start sending signals to an IoT backend.

  3. While onsite, a field technician might need to interact with and receive data from existing IoT devices in order to better troubleshoot their maintenance or repairs.

In this article, we’re going to look at a few ways to register a new IoT device in Connected Field Service, and make sure that IoT device is associated with the correct customer asset in Field Service. While you can use custom IoT providers with Connected Field Service, we're going to use Azure IoT Hub in the following examples.

For a guided walkthrough, check out the following video.

Prerequisites

Connected Field Service must be connected to Azure IoT Hub or another custom IoT provider. For more information, see the article on getting set up with Azure IoT Hub, or the article on setting up custom IoT providers.

Create and register an IoT device from IoT Hub

First, let's look at how to register a new device from Azure IoT Hub.

Go to Azure IoT Hub and select an environment.

Screenshot of Azure IoT hub, showing environments.

From the environment, go to IoT devices > +New.

Screenshot of the IoT devices screen in Azure IoT Hub.

Give the device a descriptive ID (in our example, we name it "HVACtemp1") and Save.

Screenshot of the create a device dialog in Azure IoT Hub.

Head over to Dynamics 365 Field Service, then to Assets > IoT Devices, and select Import Devices.

Screenshot of Field Service on the Active IoT Devices list, showing the import message.

Any new devices registered back in Azure IoT Hub will now appear in the list of active IoT devices in Field Service.

We’ll still need to connect this new device to the relevant customer asset, which will we do later in this article.

Create and register an IoT device from Field Service

You can also create an IoT device directly in Field Service.

From Field Service > Assets > IoT Devices > +New. Give the IoT device a descriptive name, then Save. Finally, select Register in the top ribbon.

Screenshot of the register option on an IoT device in Field Service.

Selecting Register sends the new device information back to Azure IoT Hub, which the system tells you with a message seen in the following screenshot.

Screenshot of the confirmation message that the device is being registered in the background in Field Service.

Once the device is synced back to Azure IoT Hub, a device ID will be generated and synced back to the IoT device in Field Service.

Screenshot of the new IoT device in Field Service, with a populated device ID.

Back in Azure IoT Hub, we now see the IoT device we created in Field Service, with its new device ID.

Screenshot of Azure IoT Hub, showing the new device in the list of devices.

Connect to asset

After we've created the IoT device record, we'll need to associate it with a new or existing customer asset. For instance: in our example, we have a new IoT device sensor that has been installed in an air conditioning unit.

In Field Service, go to Assets and find the customer asset you need to associate with the new IoT device.

From the customer asset, select Connect Device in the top ribbon, and look up the newly created IoT device.

Screenshot of the connect device dialog on an asset record in Field Service.

Once the IoT device has been associated with the asset, a new section will appear called Connected Devices, where you can see information about the new IoT device.

Screenshot of the Connected Devices section on the customer asset record in Field Service.

Note

  • Multiple IoT devices can be associated with a single customer asset. On the asset, go to Related > Connections to associate additional IoT devices.
  • When you're associating a device with an asset, you can set a primary device ID for the asset. If you associate multiple devices with the asset, the primary device ID for the asset won't be displayed in the form; however, a device ID link'll still exist in the background. Also, the first or the oldest device that's associated with the asset will be the primary device ID for the asset. If you delete the link to the primary device ID, then the next oldest-connected device ID will be set as the primary ID.

Registration error

When a device does not register, you'll see an error in the Registration Status field of the asset record. For assets with multiple devices, device status will show the error message for each device.

This error may occur if Dynamics 365 is not connected to Azure or if Azure is offline.

Additional notes

  • Use the Check IoT Setup ribbon button to check for information about the IoT setup such as, is IoT deployed, are there any devices in the environment. Manually doing this refresh may display more CFS ribbon items.

    Screenshot of a the "Check IoT Setup" option in the top ribbon.