Skip to content

Commit a75d163

Browse files
Merge pull request #223497 from dominicbetts/central-transformer
IoT Central: Update data transformation article
2 parents 56d8505 + adeda16 commit a75d163

File tree

5 files changed

+41
-27
lines changed

5 files changed

+41
-27
lines changed

articles/iot-central/core/how-to-connect-devices-x509.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Connect devices with X.509 certificates to your application
3-
titleSuffix: IoT Central
3+
titleSuffix: Azure IoT Central
44
description: This article describes how devices can use X.509 certificates to authenticate to your application.
55
author: dominicbetts
66
ms.author: dobett

articles/iot-central/core/howto-connect-eflow.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Connect Azure IoT Edge for Linux on Windows (EFLOW)
3-
titleSuffix: IoT Central
3+
titleSuffix: Azure IoT Central
44
description: Learn how to connect an Azure IoT Edge for Linux on Windows (EFLOW) device to an IoT Central application
55
author: dominicbetts
66
ms.author: dobett

articles/iot-central/core/howto-migrate-to-iot-hub.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Migrate devices from Azure IoT Central to Azure IoT Hub
3-
titleSuffix: IoT Central
3+
titleSuffix: Azure IoT Central
44
description: Describes how to use the migration tool to migrate devices that currently connect to an Azure IoT Central application to an Azure IoT hub.
55
author: dominicbetts
66
ms.author: dobett

articles/iot-central/core/howto-transform-data.md

Lines changed: 37 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
---
2-
title: Transform data for Azure IoT Central | Microsoft Docs
3-
description: IoT devices send data in various formats that you may need to transform. This article describes how to transform data both on the way into IoT Central and on the way out. The scenarios described use IoT Edge and Azure Functions.
2+
title: Transform data for an IoT Central application
3+
titleSuffix: Azure IoT Central
4+
description: IoT devices send data in various formats that you may need to transform. This article describes how to transform data both on the way in and out of IoT Central.
45
author: dominicbetts
56
ms.author: dobett
6-
ms.date: 10/11/2022
7+
ms.date: 01/10/2023
78
ms.topic: how-to
89
ms.service: iot-central
910
services: iot-central
@@ -152,13 +153,13 @@ In this example, the downstream device doesn't need a device template. The downs
152153
153154
To create a device template for the IoT Edge gateway device:
154155
155-
1. Save a copy of the deployment manifest to your local development machine: [moduledeployment.json](https://raw.githubusercontent.com/iot-for-all/iot-central-transform-with-iot-edge/main/edgemodule/moduledeployment.json).
156+
1. Save a copy of the deployment manifest to your local development machine: [moduledeployment.json](https://raw.githubusercontent.com/Azure-Samples/iot-central-docs-samples/main/iotedge/moduledeployment.json).
156157
157158
1. Open your local copy of the *moduledeployment.json* manifest file in a text editor.
158159
159-
1. Find the `registryCredentials` section and replace the placeholders with the values you made a note of when you created the Azure container registry. The `address` value looks like `<username>.azurecr.io`.
160+
1. Find the `registryCredentials` section and replace the placeholders with the values you made a note of when you created the Azure container registry. The `address` value looks like `{your username}.azurecr.io`.
160161
161-
1. Find the `settings` section for the `transformmodule`. Replace `<acr or docker repo>` with the same `address` value you used in the previous step. Save the changes.
162+
1. Find the `settings` section for the `transformmodule`. Replace `{your username}` with the same value you used in the previous step. Save the changes.
162163
163164
1. In your IoT Central application, navigate to the **Edge manifests** page.
164165
@@ -170,7 +171,7 @@ To create a device template for the IoT Edge gateway device:
170171
171172
1. Select **+ New**, select **Azure IoT Edge**, and then select **Next: Customize**.
172173
173-
1. Enter *IoT Edge gateway device* as the device template name. Don't select **This is a gateway device**.
174+
1. Enter *IoT Edge gateway device* as the device template name. Select **This is a gateway device**.
174175
175176
1. Select **Next: Review**, then select **Create**.
176177
@@ -221,13 +222,19 @@ The deployment manifest doesn't specify the telemetry the module sends. To add t
221222
222223
Save your changes.
223224
225+
1. In the model, select **Relationships**. Don't select **Relationships** in the **transformmodule** module.
226+
227+
1. Select **Add relationship**.
228+
229+
1. Enter *Downstream Sensor* as the display name, *sensor* as the name, and select **Any** as the target. Select **Save**.
230+
224231
1. Select **Publish** to publish the device template.
225232
226233
To register a gateway device in IoT Central:
227234
228235
1. In your IoT Central application, navigate to the **Devices** page.
229236
230-
1. Select **IoT Edge gateway device** and select **Create a device**. Enter *IoT Edge gateway device* as the device name, enter *gateway-01* as the device ID, make sure **IoT Edge gateway device** is selected as the device template and **No** is selected as **Simulate this device?**. Select **Transformer** as the edge manifest. Select **Create**.
237+
1. Select **IoT Edge gateway device** and select **+ New**. Enter *IoT Edge gateway device* as the device name, enter *gateway-01* as the device ID, make sure **IoT Edge gateway device** is selected as the device template and **No** is selected as **Simulate this device?**. Select **Transformer** as the edge manifest. Select **Create**.
231238
232239
1. In the list of devices, click on the **IoT Edge gateway device**, and then select **Connect**.
233240
@@ -239,13 +246,17 @@ To register a downstream device in IoT Central:
239246
240247
1. Don't select a device template. Select **+ New**. Enter *Downstream 01* as the device name, enter *downstream-01* as the device ID, make sure that the device template is **Unassigned** and **No** is selected as **Simulate this device?**. Select **Create**.
241248
242-
1. In the list of devices, click on the **Downstream 01** device, and then select **Connect**.
249+
1. In the list of devices, click on the **Downstream 01** device, then select **Manage device > Attach to gateway**.
250+
251+
1. In the **Attach to a gateway** dialog, select the **IoT Edge gateway device** device template, and the **IoT Edge gateway device** device instance. Select **Attach**.
252+
253+
1. On the **Downstream 01** device, select **Connect**.
243254
244255
1. Make a note of the **ID scope**, **Device ID**, and **Primary key** values for the **Downstream 01** device. You use them later.
245256
246257
### Deploy the gateway and downstream devices
247258
248-
For convenience, this article uses Azure virtual machines to run the gateway and downstream devices. To create the two Azure virtual machines, select the **Deploy to Azure** button below and use the information in the following table to complete the **Custom deployment** form:
259+
For convenience, this article uses Azure virtual machines to run the gateway and downstream devices. To create the two Azure virtual machines, select the **Deploy to Azure** button shown after the following table. Use the information in the table to complete the **Custom deployment** form:
249260
250261
| Field | Value |
251262
| ----- | ----- |
@@ -258,7 +269,7 @@ For convenience, this article uses Azure virtual machines to run the gateway and
258269
| Authentication Type | Password |
259270
| Admin Password Or Key | Your choice of password for the **AzureUser** account on both virtual machines. |
260271
261-
[![Deploy to Azure Button](https://aka.ms/deploytoazurebutton)](https://portal.azure.com/#create/Microsoft.Template/uri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure-Samples%2Fiot-central-docs-samples%2Fmain%2Ftransparent-gateway-1-1%2FDeployGatewayVMs.json)
272+
[![Deploy to Azure Button](https://aka.ms/deploytoazurebutton)](https://portal.azure.com/#create/Microsoft.Template/uri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure-Samples%2Fiot-central-docs-samples%2Fmain%2Ftransparent-gateway-1-4%2FDeployGatewayVMs.json)
262273
263274
Select **Review + Create**, and then **Create**. It takes a couple of minutes to create the virtual machines in the **ingress-scenario** resource group.
264275
@@ -301,24 +312,27 @@ To generate the demo certificates and install them on your gateway device:
301312
302313
To learn more about these demo certificates, see [Create demo certificates to test IoT Edge device features](../../iot-edge/how-to-create-test-certificates.md).
303314
304-
1. Open the *config.yaml* file in a text editor. For example:
315+
1. Open the *config.toml* file in a text editor. For example:
305316
306317
```bash
307-
sudo nano /etc/iotedge/config.yaml
318+
sudo nano /etc/aziot/config.toml
308319
```
309320
310-
1. Locate the `Certificate settings` settings. Uncomment and modify the certificate settings as follows:
321+
1. Uncomment and modify the certificate settings as follows:
311322
312323
```text
313-
certificates:
314-
device_ca_cert: "file:///home/AzureUser/certs/certs/iot-edge-device-ca-mycacert-full-chain.cert.pem"
315-
device_ca_pk: "file:///home/AzureUser/certs/private/iot-edge-device-ca-mycacert.key.pem"
316-
trusted_ca_certs: "file:///home/AzureUser/certs/certs/azure-iot-test-only.root.ca.cert.pem"
324+
trust_bundle_cert = "file:///home/AzureUser/certs/certs/azure-iot-test-only.root.ca.cert.pem"
325+
326+
...
327+
328+
[edge_ca]
329+
cert = "file:///home/AzureUser/certs/certs/iot-edge-device-ca-mycacert-full-chain.cert.pem"
330+
pk = "file:///home/AzureUser/certs/private/iot-edge-device-ca-mycacert.key.pem"
317331
```
318332
319-
The example shown above assumes you're signed in as **AzureUser** and created a device CA certificated called "mycacert".
333+
The previous example assumes you're signed in as **AzureUser** and created a device CA certificated called "mycacert".
320334
321-
1. Save the changes and run the following command to verify that the *config.yaml* file is correct:
335+
1. Save the changes and run the following command to verify that the *config.toml* file is correct:
322336
323337
```bash
324338
sudo iotedge check
@@ -327,12 +341,12 @@ To generate the demo certificates and install them on your gateway device:
327341
1. Restart the IoT Edge runtime:
328342
329343
```bash
330-
sudo systemctl restart iotedge
344+
sudo iotedge config apply
331345
```
332346
333347
If the IoT Edge runtime starts successfully after your changes, the status of the **$edgeAgent** and **$edgeHub** modules changes to **Running**. You can see these status values on the **Modules** page for your gateway device in IoT Central.
334348
335-
If the runtime doesn't start, check the changes you made in *config.yaml* and see [Troubleshoot your IoT Edge device](../../iot-edge/troubleshoot.md).
349+
If the runtime doesn't start, check the changes you made in *config.toml* and see [Troubleshoot your IoT Edge device](../../iot-edge/troubleshoot.md).
336350
337351
### Connect downstream device to IoT Edge device
338352
@@ -482,7 +496,7 @@ Before you set up this scenario, you need to get some connection settings from y
482496

483497
### Set up a compute engine
484498

485-
This scenario uses the same Azure Functions deployment as the IoT Central device bridge. To deploy the device bridge, select the **Deploy to Azure** button below and use the information in the following table to complete the **Custom deployment** form:
499+
This scenario uses the same Azure Functions deployment as the IoT Central device bridge. To deploy the device bridge, select the **Deploy to Azure** button shown after the following table. Use the information in the table to complete the **Custom deployment** form:
486500

487501
| Field | Value |
488502
| ----- | ----- |

articles/iot-central/core/tutorial-connect-iot-edge-device.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Tutorial - Connect an IoT Edge device to your application
3-
titleSuffix: IoT Central
3+
titleSuffix: Azure IoT Central
44
description: This tutorial shows you how to register, provision, and connect an IoT Edge device to your IoT Central application.
55
author: dominicbetts
66
ms.author: dobett

0 commit comments

Comments
 (0)