Loading...


Data processing of a data stream

Florian Bauernfeind

Data processing makes it possible to process captured information on the server side with formulas or other information.

To process data further, data streams can be edited on the Asset Details page.

Bildschirmfoto 2022 12 12 Um 01.01.30

After that, you can navigate to the "Data Processing" tab.

Bildschirmfoto 2022 12 12 Um 01.04.00

Formula syntax

The syntax is based on the PHP programming language and allows the user to execute various formulas in a secure environment. Only a few guidelines have to be followed:

  • The calculated value must be returned via the return statement.
  • Each line/statement must be terminated with a semicolon ( ; ).
  • Other values of the same object can be added via the right bar by clicking on the value.
  • All available functions can be viewed via the right bar by clicking on the "Functions" tab.
  • Variables can be defined with a $ sign

Examples

The following example always returns the value 12:

Bildschirmfoto 2022 12 12 Um 01.13.08

The following example assigns the value of the data stream Current to the variable $strom and multiplies it by 4 before returning it:

Bildschirmfoto 2022 12 12 Um 01.13.55

The following example calculates the difference between 2 data points and returns the result:

Bildschirmfoto 2022 12 12 Um 01.15.08

Common formula notations are also possible. The . is used as the comma character.

Bildschirmfoto 2022 12 12 Um 01.15.54

This function rounds the $percentage variable to the nearest value.

Bildschirmfoto 2022 12 12 Um 01.16.57

Preview

For formulas, the preview can also be activated before saving. This shows the expected result of the formula.

Bildschirmfoto 2022 12 12 Um 01.21.29

If information is missing or a formula is to be tested with special values of data, the values can be changed independently.

Newsletter Icon

Don’t miss a single update!

Subscribe to our newsletter to receive latest updates to your inbox monthly.

Register now for the newsletter
Top Top