# How to integrate the IAM Decentlab device with TTN on akenza

![IAM device from Decentlab](https://2165942204-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MMKXTFIN5ZlLOjBlfC4%2F-MYp0oyez3U8p75ei3T5%2F-MYp0rb6UZiZsS5WZ8RW%2Fimage.png?alt=media\&token=28d03940-5a5a-4a85-9f81-9a42499d360f)

{% hint style="success" %}
**Applications**:

* Indoor air quality monitoring in offices, classrooms, hospitals, store&#x73;**,** or malls
* Office occupancy monitoring
* Motion/activity monitoring of people in a room
* Heating, ventilation, air conditioning (HVAC) control: for good indoor air quality and energy savings
* Process yield and economic efficiency: e.g. in greenhouses, mushroom farming, food packaging, transportation/storage, chicken hatcheries, and incubators
* Personal safety: in confined spaces where combustion is present or gas leakage could occur such as garages, tunnels, public bars, restaurants, or burners

**Product features**:&#x20;

* State-of-the-art CO2 and VOC (volatile organic compounds) sensors
* Industry-standard humidity and temperature sensor
* High accuracy barometric pressure sensor
* Ambient light sensor
* Motion / presence detector
* Unattended real-time monitoring for more than a year without replacing batteries

You will find more information about the IAM device from **Decentlab** [here](https://static1.squarespace.com/static/5c80d350ab1a62362b81c9d1/t/5e60b640633a0705fb47e389/1583396423807/Decentlab-DL-IAM-datasheet.pdf).
{% endhint %}

In this tutorial, you will learn how to add the IAM device from Decentlab to the connectivity provider The Things Network (TTN) on akenza.&#x20;

To create a new device, you first need an **Integration** to TTN and a **Data Flow**. You can simply make use of the [**Connectivity-as-a-Service**](https://docs.akenza.io/get-started/your-integration) that akenza offers with its own LoRaWAN Connector or you can integrate your own TTN account.

### Add your TTN account

To add your TTN Account as an Integration provider, select TTN and complete your integration by inserting the authentication details of your TTN account. If all details are provided, the initial synchronization will start. This can take several minutes, depending on the size of your IoT deployment.

![Integrations](https://2165942204-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MMKXTFIN5ZlLOjBlfC4%2Fuploads%2FZQRb30ajnlX5AN45Y5HK%2Fimage.png?alt=media\&token=c1811daf-2406-4a3f-85bd-c2590c558e87)

If the synchronization was successful, the Integration will be displayed on the **Integration Overview**.

Proceed with the creation of the [**Data Flow**](https://docs.akenza.io/akenza.io/get-started/your-data-flow).&#x20;

### Create a Data Flow

#### Device Connector

To create a **Data Flow**,  go to Data Flow and select *Create Data Flow*.&#x20;

Choose *LoRa* as your Device Connector. If you have integrated your TTN account, you will see it listed here. If you do not have your own account, you simply can make use of the [**Connectivity-as-a-Service**](https://docs.akenza.io/get-started/your-integration)**.** In this example, we choose the CaaS offer of TTN.

![Device connector](https://2165942204-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MMKXTFIN5ZlLOjBlfC4%2Fuploads%2FWSPTIXDi1p7bVKKE7esM%2Fimage.png?alt=media\&token=8511e328-89b0-4d00-abc2-d096ee5d1863)

#### **Device Type**

Use the search field to find the **IAM** and select the Device Type accordingly. Proceed further to Output connectors.

![Device type](https://2165942204-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MMKXTFIN5ZlLOjBlfC4%2Fuploads%2F6oYrblDqJct6HFXS5sJW%2Fimage.png?alt=media\&token=25f0dc8b-6761-4184-ade4-29309373195f)

#### **Output Connector**

Choose one or multiple Output connectors for your Data Flow. **Output Connectors** define what is done with the results of the device types.

In this tutorial, we proceed with choosing Akenza DB. With the connection to the **Akenza DB,** we ensure that all data passing through this data flow is saved in the Akenza Database and thereby becomes accessible to you. Save your **Data Flow** and give it a name.

![AkenzaDB as output connector](https://2165942204-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MMKXTFIN5ZlLOjBlfC4%2Fuploads%2FZB5QUMGODcpUH7aa79BE%2Fimage.png?alt=media\&token=f7d1e0bc-b5a1-42cd-b21d-a66f221fcf72)

### Create the IAM device of Decentlab

To create a new device, select *Create Device* within the menu of **Assets Inventory**. Add a device name and optionally a description, a tag or custom fields.&#x20;

![Create new device](https://2165942204-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MMKXTFIN5ZlLOjBlfC4%2Fuploads%2Fpw44kgJZfMAmlFZwNAAb%2Fscreely-1640816236580%20tags%20device%20create.png?alt=media\&token=ff35deb6-087c-419e-a091-9373a5f00406)

Fill in now all **Connectivity Parameters** about your IAM LoRa device. Your device will get created now.

![Connectivity parameters](https://2165942204-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MMKXTFIN5ZlLOjBlfC4%2Fuploads%2FswMgHq3xWYnEPuuhFoeP%2Fscreely-1640814168489%20device%20create%20last%20step.png?alt=media\&token=d817ef32-d9bc-4cc8-9969-3bf549887f0d)

In the Overview of **Asset Inventory**, you will see your newly created **IAM** LoRa device from Decentlab.

To check incoming data of your device, select your device from the list and check the status on the **Data Overview.**

![Device detail page](https://2165942204-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MMKXTFIN5ZlLOjBlfC4%2Fuploads%2FbJw0YHlSWssHODPfQ3Mh%2Fscreely-1640814344289%20ddp%20decentlab.png?alt=media\&token=1da45969-dd64-4542-81ee-6df12aad27ce)

**Congratulations**, you have successfully integrated the IAM device from Decentlab with TTN on akenza.
