Variables

Variables in ControlCom Connect represent the individual data points collected from your devices or calculated from other variables. They form the foundation of your IoT data and enable monitoring, visualization, and automation.

What are Variables

In ControlCom Connect, variables are the individual data points that represent specific measurements, states, or calculated values. They are the basic units of data that flow through the platform and enable you to:

  • Monitor real-time conditions
  • Track historical trends
  • Set up alerts and notifications
  • Create visualizations and dashboards
  • Generate reports and analytics
  • Trigger automated actions

Variables come in two main types:

  1. Device Variables: Data collected directly from connected devices
  2. Virtual Variables: Calculated values derived from other variables

Each variable has a specific data type, configuration settings, and can be associated with devices and assets.

Device Variables

Device variables represent data collected directly from your connected IoT devices:

Data Types

ControlCom Connect supports three primary data types for device variables:

  • Number: Numerical values like temperature, voltage, or pressure
  • String: Text values for status messages, serial numbers, etc.
  • Boolean: True/false values for states like on/off or open/closed

Data Sources

Device variables can come from various sources:

  • Sensor Readings: Physical measurements from sensors
  • Device States: Status information from devices
  • Diagnostic Data: Information about device health and performance
  • Configuration Values: Current device settings and parameters

Virtual Variables

Virtual variables are calculated values derived from other variables:

Creating Virtual Variables

To create a virtual variable:

  1. Navigate to the Variables section in the platform
  2. Click "Add Virtual Variable"
  3. Enter a name and description
  4. Select the data type (number, string, or boolean)
  5. Define the calculation expression
  6. Select the source variables used in the calculation
  7. Configure additional settings like units and logging
  8. Save the virtual variable

Expression Language

Virtual variables use a powerful expression language that supports:

  • Basic arithmetic operations (+, -, *, /)
  • Mathematical functions (min, max, avg, sum)
  • Conditional logic (if, then, else)
  • Time-based functions (timeShift, movingAverage)
  • String operations (concat, substring)
  • Boolean operations (and, or, not)

Use Cases

Common uses for virtual variables include:

  • Aggregation: Combining data from multiple sources
  • Conversion: Transforming units or formats
  • Calculation: Deriving new values from raw measurements
  • Filtering: Removing noise or invalid data
  • Thresholds: Creating boolean indicators based on numeric values

Variable Configuration

Variables in ControlCom Connect can be configured with various settings:

Basic Settings

  • Name: Human-readable identifier
  • Description: Detailed explanation of the variable
  • Data Type: Number, String, or Boolean
  • Unit: Optional unit of measurement (for number variables)

Data Collection

For device variables, you can configure:

  • Topic Path: MQTT topic
  • Logging Enabled: Whether to store historical data
  • Short ID: Optional abbreviated identifier for the variable

Data Processing

Optional processing settings include:

  • Scaling: Apply multipliers or offsets to raw values
  • Validation: Define valid ranges or patterns
  • Filtering: Remove outliers or invalid values
  • Deadband: Only record changes that exceed a threshold

Historical Data

ControlCom Connect can store and manage historical variable data:

Data Storage

When logging is enabled for a variable:

  • Data points are stored with timestamps
  • Storage duration is based on your subscription plan
  • Data can be accessed for visualization and analysis
  • Historical data can be exported for external use

Data Resolution

Historical data can be accessed at different resolutions:

  • Raw Data: Original values as received from devices
  • Interval Aggregates: Data aggregated at selected intervals

Data Aggregation

When accessing aggregated data, you can choose different aggregation methods:

  • Average: Mean value over the time period
  • Minimum: Lowest value in the time period
  • Maximum: Highest value in the time period
  • Sum: Total of all values in the time period
  • Count: Number of data points in the time period
  • First/Last: First or last value in the time period

Data Access

Historical data can be accessed through:

  • Dashboards: Visualize trends and patterns
  • Explorer: Interactive tool for data exploration
  • Reports: Generate scheduled or on-demand reports
  • API: Programmatic access for integration with other systems
  • Export: Download data in CSV or JSON format

Guides

Sending Data

Learn how to send data to ControlCom Connect using MQTT or HTTP.

Read more

MQTT Integration

Send data to ControlCom Connect using the MQTT protocol.

Read more

HTTP Integration

Send data to ControlCom Connect using the HTTP API.

Read more

Node-RED Integration

Connect your devices to ControlCom Connect using Node-RED.

Read more

Was this page helpful?