Calculate a KPI on Visual Flow Creator

Create a basic flow

On the Visual Flow Creator app, create a basic flow

  1. Drag and drop on the main page
    - Input node e.g inject. Input nodes trigger data to the
    - Mindsphere node e.g read
    - Output node e.g. debug. Output nodes send the data from the flow to other services or to the debug tag
  2. Double click on the node to edit the content
    e.g on inject node edit the repeat option
    e.g on read timeseries node on topic choose an asset, variables and period
  3. Connect the nodes to create a flow
  4. Save your creation
  5. Trigger data to the flow with the inject node
  6. Check the debug tab to visualize the results
    The messages displayed in the debug window can be filtered using the filter button.

Add a function and filter node with an email sender

Drag and drop between the time series node and the debug node 

A function node 

  1. Double click on the node to edit properties
  2. Edit the name of the function and on the code window write in Javascript a simple function
  3. On the code block window below copy the entire text
    The function reads the last value on the string. On this case the Current last value
var newMsg = {payload: msg.payload[msg.payload.length-1].Current};
return newMsg;

A filter node

  1. Double click on the node to edit properties
  2. Edit the name of the filter and on the code window write in Javascript the filter function
  3. On the code block window below copy the entire text
    On this case all values of the Current bigger then 45[A] will be shown
element.Current >45

A send email node

  1. Double click on the node to edit properties
    Add Recipients, email Subject and choose the priority 
  2. Add a customized message
  3. Save your creation

Trigger data to the flow with the inject node
Edit the Repeat inside the inject node to trigger data between an interval or at a specific time

On each node notice that:

The orange border indicates that the node is selected

The blue circle identifies nodes that have not yet been saved

The red triangle indicates missing inputs or errors in the node properties

The text below the node shows status and error messages

Go to Visual Flow Creator Access

Go to Visual Flow Creator Dashboard