How to creat dashboard for a device?

Version 14.1 by Chxy on 2024/10/23 15:59

 

Table of Contents:

1. Overview:

After device data arrive to the platform via the method of Connect Device to ThingsEye. We can creat the Dashboard for the specify device. so to view the sensor detail of each device.

Note: We can create only one rule chain, device profile and dashboard for one type of devices.

2. For devices which already have dashboard / profile/ rule chain.

2.1 Get the json files

where to get:https://github.com/ThingsEye-io/te-platform/tree/main/Devices/Dragino

what files to get:Select the model you need and download three JSON files from it

Such as:

2.2 Import Rule chain

Firstly, we need to import the rule chain. The rule chain tells platform how we should handel the uplink and downlink for this device.

Open rule chains, click on the "+" in the upper right corner,

select "import rule chain", and then drag the downloaded JSON file with the suffix "_rule_chain" into the text box

  • Only need to import once for same type of devices.

​​​​​1729040952504-811.png

1729066864346-718.png

2.3 Import Device profile and select the rule chain

2.3.1 Import Device profile

At this step, we need to import the device profile first, as shown in the figure.

First, we need to open the device profiles, click on the "+" in the upper right corner, select "import device profile",

and then select the file with the suffix "_device_defiles" that we have already downloaded. Drag it into the text box.

1729041156898-931.png

1729066636027-958.png

2.3.2 Modify the rule chain in the device profiles

After importing the rule chain and device profile, we need to link them together.

At this point, we need to modify the rule chain on the device profiles page.

In this section, first we need to open the device profiles module again,

click on the newly imported device profile file, and then click on the top right corner“ 🖊” After entering the editing mode,

we will see the Default rule chain under the details section.

Click on it and select the corresponding rule chain we have newly imported,

then click the "√" in the upper right corner to save it.

1729041627624-611.png

1729041918618-753.png

2.4 Import Dashboard and link to each device

After importing the rule chain and device profile, we need to import the dashboard and configure its  datasource.

 2.4.1 Import dashboard

Firstly, we need to open the dashboard module,

click on the "+" in the upper right corner, select "import dashboard",

then we shoud drag the downloaded _dashboard file into the text box.

1728978901199-201.png

1729066158155-749.png

2.4.2 Modify the datasource of each module in the dashboard

After importing the dashboard, we need to link it with our input device,

So we need to change the input device of each module in the dashboard , and the corresponding device name is the IMEI of the device we are connected to.

(For example, if our input device IMEI is 863663062789483, then our input device name is 863663062789483)

In this section, we should first open our newly imported dashboard and click on "Edit mode" in the upper right corner to edit it.

Afterwards, select the module to be modified and click on the top right corner of the module“ 🖊” Enter the editing interface,

then find the Datasource section, select the corresponding device name, and click "Apply" in the upper right corner.

  • Need to repeat for every new device.
  • Make sure the device already creat in the platform.

1729042442077-819.png

1729042599152-568.png

1729042895928-321.png

Now our dashboard has been successfully imported and the data can be displayed after processing.

Next, we only need to transfer the data in and we can see the data displayed on the dashboard.

1728978901221-951.png

3. For devices doesn't have dashboard / profile/ rule chain.

Hope this article can be helpful to you.Good luck to you!