A powerful IP-Symcon module for creating virtual devices that consolidate variables from multiple real devices with bidirectional synchronization and optional data type conversion.
- Variable Consolidation: Aggregate variables from multiple real devices into a single virtual device
- Bidirectional Synchronization:
- Changes to source variables are automatically reflected in virtual variables
- Changes to virtual variables can be synced back to source variables
- Configurable sync direction per variable (bidirectional, from source only, to source only)
- Data Type Conversion:
- Convert between Boolean, Integer, Float, and String types
- Automatic intelligent type conversion with sensible defaults
- Useful for integrating incompatible devices or creating unified interfaces
- Flexible Naming: Custom names and descriptions for each virtual variable
- Standalone Variables: Create virtual variables without a source for manual control
- Action Support: Virtual variables with bidirectional sync can be controlled via WebFront or scripts
- Clean Management: Automatically cleans up old virtual variables when mappings change
- Full Localization: German and English language support
- IP-Symcon 8.1 or higher
- Open IP-Symcon Console
- Navigate to Modules > Module Store
- Search for "VariableAggregator" or "Variable Aggregator"
- Click Install
- Open IP-Symcon Console
- Navigate to Modules > Modules
- Click Add (Plus icon)
- Select Add Module from URL
- Enter:
https://github.com/mwlf01/IPSymcon-VariableAggregator.git - Click OK
- Clone or download this repository
- Copy the folder to your IP-Symcon modules directory:
- Windows:
C:\ProgramData\Symcon\modules\ - Linux:
/var/lib/symcon/modules/ - Docker: Check your volume mapping
- Windows:
- Reload modules in IP-Symcon Console
After installation, create a new instance:
- Navigate to Objects > Add Object > Instance
- Search for "VariableAggregator" or "Variable Aggregator"
- Click OK to create the instance
Configure which variables to include in the virtual device:
| Setting | Description |
|---|---|
| Source Variable | Select any variable from your IP-Symcon installation (optional for standalone variables) |
| Name | Display name for the virtual variable (uses source name if empty) |
| Target Type | Data type for the virtual variable: Boolean, Integer, Float, or String (cannot be changed after creation) |
| Sync Direction | How changes are synchronized: Bidirectional, From Source Only, or To Source Only |
| Description | Optional description for documentation purposes |
| ID | Auto-generated unique identifier (read-only, format: VA_ID_XXXXXXXX) |
- Bidirectional: Changes sync both ways - source changes update the virtual variable, and virtual variable changes are sent back to the source
- From Source Only: The virtual variable is read-only and only reflects source changes
- To Source Only: Changes to the virtual variable are sent to the source, but source changes don't update the virtual variable
You can create virtual variables without a source by providing a Name and Target Type. These are useful for manual control or scripting purposes.
Virtual variables are created dynamically based on your mappings. Each mapped source variable creates a corresponding virtual variable under the instance.
The virtual variables:
- Support actions if sync direction allows writing to source
- Are automatically removed when mappings are deleted
The module provides the following public functions for use in scripts:
Synchronize all virtual variables from their source variables (respects sync direction setting, skips "To Source Only" variables).
VA_SyncAllFromSource(int $InstanceID);Example:
// Refresh all virtual variables from source
VA_SyncAllFromSource(12345);Synchronize all virtual variables to their source variables (respects sync direction setting, skips "From Source Only" variables).
VA_SyncAllToSource(int $InstanceID);Example:
// Push all virtual variable values to source
VA_SyncAllToSource(12345);Get the value of a virtual variable by its identifier.
mixed VA_GetVirtualValue(int $InstanceID, string $Ident);Parameters:
$InstanceID- ID of the VariableAggregator instance$Ident- Identifier of the virtual variable
Returns: The current value of the virtual variable
Example:
$value = VA_GetVirtualValue(12345, 'VA_ID_12345678');
echo "Value: {$value}";Set the value of a virtual variable (also syncs to source if allowed).
VA_SetVirtualValue(int $InstanceID, string $Ident, mixed $Value);Parameters:
$InstanceID- ID of the VariableAggregator instance$Ident- Identifier of the virtual variable$Value- New value to set
Example:
// Set a virtual variable and sync to source
VA_SetVirtualValue(12345, 'VA_ID_12345678', true);Get a list of all virtual variables with their details.
array VA_GetVirtualVariables(int $InstanceID);Returns: Array of virtual variable information
Example:
$variables = VA_GetVirtualVariables(12345);
foreach ($variables as $var) {
echo "Ident: {$var['Ident']}, Name: {$var['Name']}, ID: {$var['VariableID']}\n";
}Consolidate temperature, humidity, light status, and window contacts from different devices into a single "Room" virtual device.
Create a unified interface for similar devices from different manufacturers with different variable types.
Convert a float temperature sensor to an integer for simpler display, or convert a boolean to a string for logging.
Create read-only copies of critical variables for visualization without accidental modification.
Create control interfaces that send commands to devices without reflecting device state changes.
- Initial release
- Variable mapping with bidirectional synchronization
- Data type conversion (Boolean, Integer, Float, String)
- Configurable sync direction per variable
- Standalone variables without source
- Automatic cleanup of removed mappings
- Full German localization
For issues, feature requests, or contributions, please visit:
This project is licensed under the MIT License - see the LICENSE file for details.
mwlf01
- GitHub: @mwlf01