Data Source Value Arithmetic Plugin
Posted: Thu 29 Jan 2015, 22:00
This plugin is used to perform arithmetic operations (plus, minus, multiplication, division and absolute difference) on values from two different data sources and make the result available in a third data source. It is possible to create chains of calculations where the data source holding the result from one calculation may be used as input for another calculation.
The data source value holding the result can be used when defining rules for group schedules. Examples of usage:
- Control circulation pump based on temperature difference
- Control ventilation based on difference in humidity or temperature
- Other stuff yet to explore
In this example "INDATA 1" and "INDATA 2" are the sources for the calculation. Several data sources have been created for the results, "RESULTAT ...", to show the different arithmetic operators being available.
Instructions:
- Put the files in the Binaries folder (found in the zip file) in the Plugins folder where the Switch King Server is installed.
- Open the DSVArithmeticPlugin.dll.config file (using e.g. Notepad) and follow the instructions.
- Restart the Switch King Server
Create a new data source to publish the results from the calculation:
- Select File > New > Data Source
- Select option "Values provided from external system"
- Configure the remaining options for the data source at will and finish
- Open the newly created data source and make a note of the Data Source ID found on the General tab
- Use this ID in the .config file to save the results from the calculation
(Use the same approach to find out the Data Source IDs for your data sources on which to perform the calculation.)
Source code and Binaries are included in the zip file.
Source code is available for further development and please share your enhancements with the community. Thanks!
Filename: DSVArithmeticPlugin_0.1.zip
Version: 0.1
Date: 2015-01-29
Requirements: Switch King Server v 3.2.3 and later
Developer: Switch King
(Det går bra att posta frågor/kommentarer på svenska också i denna tråden.)
The data source value holding the result can be used when defining rules for group schedules. Examples of usage:
- Control circulation pump based on temperature difference
- Control ventilation based on difference in humidity or temperature
- Other stuff yet to explore

In this example "INDATA 1" and "INDATA 2" are the sources for the calculation. Several data sources have been created for the results, "RESULTAT ...", to show the different arithmetic operators being available.
Instructions:
- Put the files in the Binaries folder (found in the zip file) in the Plugins folder where the Switch King Server is installed.
- Open the DSVArithmeticPlugin.dll.config file (using e.g. Notepad) and follow the instructions.
- Restart the Switch King Server
Create a new data source to publish the results from the calculation:
- Select File > New > Data Source
- Select option "Values provided from external system"
- Configure the remaining options for the data source at will and finish
- Open the newly created data source and make a note of the Data Source ID found on the General tab
- Use this ID in the .config file to save the results from the calculation
(Use the same approach to find out the Data Source IDs for your data sources on which to perform the calculation.)
Source code and Binaries are included in the zip file.
Source code is available for further development and please share your enhancements with the community. Thanks!
Filename: DSVArithmeticPlugin_0.1.zip
Version: 0.1
Date: 2015-01-29
Requirements: Switch King Server v 3.2.3 and later
Developer: Switch King
(Det går bra att posta frågor/kommentarer på svenska också i denna tråden.)