For the all common tasks we have a prepared a simple to use graphical guides which will generate a code skeleton for you. Graphical guides are located at the top toolbar of the edited script:
View Script Version
Server Side Scripts Version
Now we will walk you to using each graphical guide.
Creating Timer
To create a timer, click on a Timer Icon in the toolbar.
New dialog will appear:
Select an time period and tick repeat if you want to trigger the timer periodically. Once you press OK, myDESIGNER will automatically create a code for you and insert it into the edited script.
Creating Scheduled Event (Server Side Scripts Only)
To create a scheduled event, you can use the CRON tool. To activate it, please press the Schedule Icon:
New Dialog will appear:
Now select the dates and times, when you want your code to be run and press OK button. myDESIGNER will automatically create a code for you and insert it into the edited script.
Export to CSV and Microsoft Power BI
You can make periodic export of data-log data into CSV file. This file is easily readable by Microsoft Power BI. To do so, please click on the button Export.
For detail description, please see section Simple Periodic Export to CSV and Microsoft Power BI in this manual.
Read Historical data from data-logs
You can easily read and process historical data from data-logs. To do so, click on the Data-log Icon
New Dialog will be opened:
In the provided dialog, please start by selecting a data-log from which you want to read data. Then select an items you want to process, or leave all selected. Other options follow:
Limit by time: first you can limit the data by provided time. Time is specified in UTC format in seconds since 1.1.1970. You can enter a value or provide a variable where the value is stored.
Filter: if the data-log contains a keyed value, you can limit results shown in your project by specifying a filter value. Again this can be a hard value or variable.
Limit records to: please provide limits for the number of records loaded. You can also specify if the limit is taken from the beginning eg. “from start” or from end.
Loop over results: if this option is checked, you will have an option to loop over the retrieved records and process them in your script.
Export to CSV (Server side scripts only): if you choose this option, the retrieved historical data will be exported into a CSV format and saved into a file. File is saved under a provided name into user data folder accessible over FTP or HTTP and HTTPS.
press OK button. myDESIGNER will automatically create a code for you and insert it into the edited script.
Reading and processing Alarms
You can read and process online and historical alarms. To do so, please click on the Alarms Icon:
New dialog will open:
In this dialog, you can choose if to process Online or Historical alarms. We will start with Historical alarms:
Historical alarms dialog has several sections. We will explain in details each section.
Columns:
Columns allows you to select all the data retrievable from the history. Please select what columns you want to process.
Filters:
Currently, you can filter retrieved data based on time interval. Future versions will allow to extend the filter for Message, Area and Device as well.
Aggregates:
If you need historical alarms in the form they have been stored, leave aggregates to none. If you want to retrieve an aggregated data based on alarm occurrence count and overall activation time, please tick the occurrence option.
Limit records to: please provide limits for the number of records loaded. You can also specify if the limit is taken from the beginning eg. “from start” or from end.
Loop over results: if this option is checked, you will have an option to loop over the retrieved records and process them in your script.
Export to CSV (Server side scripts only): if you choose this option, the retrieved historical data will be exported into a CSV format and saved into a file. File is saved under a provided name into user data folder accessible over FTP or HTTP and HTTPS.
press OK button. myDESIGNER will automatically create a code for you and insert it into the edited script.
Online Alarms can be processed as well. To do so, click on the tab Online and dialog will change accordingly:
This function will retrieve active or non-acknowledge alarms at the time script is run. You can select which columns you want to process or maximum severity level. Other options are:
Loop over results: if this option is checked, you will have an option to loop over the retrieved records and process them in your script.
Export to CSV (Server side scripts only): if you choose this option, the retrieved historical data will be exported into a CSV format and saved into a file. File is saved under a provided name into user data folder accessible over FTP or HTTP and HTTPS.
press OK button. myDESIGNER will automatically create a code for you and insert it into the edited script.