How to use the Digital Twin Orchestrator?

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.

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

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.

  • Digital Twin Types available: select the Digital Twin type you need.

  • 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.

Example: SenseHat

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

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.

The first exit, starting in the upper part, will generate a message every time the Digital Twin changes its status.

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:

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:

  • Name: name with which you want the node to be viewed.

  • Digital Twin Types available: select the Digital Twin type on which you want to see the actions.

  • Digital Twin Devices available: once the Digital Twin type has been selected, you will be shown the different actions you can start.

In this case, select the action to turn the joystick to the right:

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: