---
title: "How to use the Digital Twin Orchestrator?"
canonical: "https://onesaitplatform.refined.site/space/DOCT/2220797017/How%20to%20use%20the%20Digital%20Twin%20Orchestrator%3F"
format: markdown
---
> Macro (toc)

# Introduction

You can interact with and orchestrate the different digital twins registered in the Platform from the FlowEngine.

In this case, we will explain the different components to interact with a [SenseHat-type Digital Twin](https://onesaitplatform.atlassian.net/wiki/spaces/DOCT/pages/2220796757).

To do this, in FlowEngine's node palette (menu **DEVELOPMENT > My Digital Flows**), you have this:

![image](media://88963acc-aa46-4921-8eda-b4d8e9f9c39e)

The "OnesaitPlatform DigitalTwin" node is the digital twin allowing us to send actions to the device (input) and receive messages for every submitted event or every state change in its properties (outputs).

To configure this, you need to fill in the following properties:

- Name: name with which you want the node to be viewed.
- <span style="color: #444444">Digital Twin Types available: select the Digital Twin type you need.</span>
- <span style="color: #444444">Digital Twin Devices available: once the Digital Twin type has been selected, you will be shown a list of devices of such type. Select the device you need.</span>

# Example: SenseHat

To go on with our example, configure the node to interact with the "SensehatHelsinki" Digital Twin.

![image](media://e4db92fc-13c8-4b6c-9193-0be2cade555a)

<span style="color: #444444">Once the node is configured, you see that the node changes in appearance, to adapt the amount of outputs to the amount of events that this digital twin type can send.</span>

<span style="color: #444444">The first exit, starting in the upper part, will generate a message every time the Digital Twin changes its status.</span>

![image](media://63807911-ec88-43a8-b4e6-422005b5a8ea)

<span style="color: #444444">The other exits correspond with the different events that the Digital Twin can trigger. You can see the event name as a tooltip if you place the cursor over each output:</span>

![image](media://6c06956e-bbf5-46c3-9064-2411bff27182)

<span style="color: #444444">In the input, include the actions you want to send to the configured Digital Twin device. At this point, the "OnesaitPlatform DigitalTwin Action" node comes into play. With it you can select the action you want to start. To configure the node, you have to fill in the following properties:</span>

- Name: name with which you want the node to be viewed.
- <span style="color: #444444">Digital Twin Types available: select the Digital Twin type on which you want to see the actions.</span>
- <span style="color: #444444">Digital Twin Devices available: once the Digital Twin type has been selected, you will be shown the different actions you can start.</span>

<span style="color: #444444">In this case, select the action to turn the joystick to the right:</span>

![image](media://f36f407f-4729-478b-a5e7-41d4fa7488f0)

Once you have selected the action, you only need to join it to the Digital Twin's input. Besides, for this example, start it with an "Inject" node. Every time "Send Action" is pressed, an action will be sent to the device. Similarly, every time the device generates an event or changes its status, you will receive the message via the outputs:

![image](media://b31cebb9-034c-43da-9f0d-d2aecdc1618d)