ETL Secondary Calculation
Overview
Secondary calculation solves the conversion of cumulative values from electricity and water meters into usage amounts. It calculates usage for virtual sub-meters by splitting a main meter based on business requirements, ensuring data accuracy. Specifically, based on the device data reported by electricity and water meters, combined with meter characteristics, it calculates the usage for each meter, then performs split calculations for the main meter, providing a reliable basis for energy management.
The system provides two calculation methods: Usage and Virtual Device.
Usage performs difference calculations based on the cumulative values reported by devices, suitable for various electricity and water meter devices.
Virtual Device splits the main meter into multiple virtual device meters based on business needs and performs calculations defined by operator rules, suitable for devices with mixed meter operations.
Access Method and Prerequisites
How to access
Click the menu bar "System Settings", click the "ETL Calculate" button to enter the secondary calculation module, as shown below.

Before You Start
Permission Configuration
To ensure the following operational processes proceed normally, please confirm that you have Project Administrator permissions.
Prerequisite Configuration
Before configuring secondary calculation, you need to confirm whether the ETL Converter has been configured. For operations, see ETL Converter.
Usage
Usage List
The system supports querying by device twins and Point.
Select the device twins you want to query. The system will refresh the usage calculation list, as shown below.

Add Usage
Configure Usage for Device Twins
Before adding, you need to configure the usage for the Function type under the device twins.
Click the 'Device Twins' menu, select 'Device Twins List' to enter the device twins management module.
As shown above, on the device twins list page, click the "Modify" button on the right side of the device twins that needs modification.
On the device twins modification page, modify the Function type information, as shown below.
After turning on the calculation attribute, two options appear. Specific information is as follows:
Selecting "Calc hourly usage": The system will automatically calculate the hourly usage of the device for this Function type under the device twins.
Selecting "Sync hourly usage": The system will automatically calculate and synchronize the hourly usage of the device for this Function type under the device twins.
Turning on this switch will enable hourly usage calculation for the Points of all devices under this device twins.

Configure Usage by Selecting Devices
Click the menu bar "System Settings", click the "ETL Calculate" button to return to the secondary calculation module.
As shown above, click the "+" button above to enter the usage addition page, as shown below.
First, select the required device twins, then select the required Point, and finally check the devices that require usage calculation. Submit to save and complete the usage addition.
"Submit selection": Configures usage calculation for the Points of all selected devices.
"Submit All": Configures usage calculation for the Points of all devices under this device twins.

View Usage Data
As shown above, on the usage list page, click "Details" in the operation area to view usage data, as shown below.
The system defaults to querying data for the current day. You can switch the time range to view calculated data.

Modify/Delete Usage

Delete Usage for One or Multiple Devices
As shown above, on the usage list page, click "Modify" in the operation area to modify usage, as shown below.
The system supports adding or removing devices for usage calculation.
Check the devices that require usage calculation and uncheck those that do not to complete the usage modification.

Delete Usage for All Devices under a Device Twins
As shown above, on the usage list page, click "Delete" in the operation area to delete the calculation configuration for the Points of all devices under this device twins.
Virtual Device
Virtual Device, based on business requirements and real water/electricity meter data, performs split usage calculations for the main meter. For example, when one floor has only one main meter, water/electricity usage is reasonably allocated based on factors like usage area to achieve accurate measurement and fair accounting.
As shown above, click "Virtual device" to switch to the virtual device list page, as shown below.

Add Virtual Device
As shown above, click the "+" button above to enter the virtual device addition page, as shown below.

Field descriptions are as follows:
- Name: Globally unique. The system will generate a virtual device that can be used and viewed in the APP;
- Project: Platform project. After binding to a project, all devices under the project can be configured to participate in the calculation;
- Calculation Dimension: Defaults to hourly calculation;
- Function Point: The name of the virtual device point generated after calculation;
- Location: Location configuration for the virtual device;
- Description: Descriptive information for this device;
- Add Formula: Click this button to select three types for formula configuration, as shown below;
- Device: You can select the function points of a device and participate in the virtual device calculation with formulas;
- Expression: You can select operators, such as +, -, etc;
- Number: You can perform operations with fixed values in expressions.
- Add Device: Click this button to view already configured devices and select new devices to participate in the calculation.
Modify Virtual Device
Only virtual devices that have not started calculating can be modified. For virtual devices that have already started calculating, they can be deleted and recreated.
As shown above, in the operation area of the virtual device to be modified, click the "Modify" button to enter the virtual device modification page, as shown below.

View Virtual Device Data
Data viewing defaults to viewing data calculated for the current day. The time range can be modified to view data for different time periods.
As shown above, in the operation area of the virtual device to be viewed, click the "Details" button to enter the virtual device modification page, as shown below.

Delete Virtual Device
As shown above, in the operation area of the virtual device to be deleted, click the "Delete" button. After confirmation, the virtual device deletion is completed.