Skip to content

Simulation

Simulated energy asset implementations for testing and development without physical hardware.

Overview

The Voltimax.Edge.Control.Simulation library provides comprehensive simulation of energy assets, load profiles, and grid interactions for:

  • Testing control strategies without physical devices
  • Development and debugging of energy management algorithms
  • Validating site orchestration with realistic profiles
  • Evaluating demand response and time-of-use pricing scenarios

Quick Start

Add a simulated battery to your assets.json:

json
{
  "Name": "home-battery",
  "DeviceClass": "SimulatedBattery",
  "AssetType": "Battery",
  "SimulatedBattery": {
    "ConfigurationModel": "MediumResidential"
  }
}

That's it - the gateway will create a realistic 15 kWh battery with proper physics, efficiency losses, and thermal behavior.

Simulated Assets

AssetDeviceClassDescription
BatterySimulatedBatteryFull-featured battery with cell/pack tracking, inverter, thermal simulation
Solar PVSimulatedSolarInverterSolar inverter with panel characteristics and generation profiles
Grid MeterSimulatedGridMeterExternally controlled meter for site energy balance
LoadSimulatedLoadConfigurable load with residential/commercial/constant profiles
EV ChargerSimulatedChargeStationEV charging station with commuter profiles

Site Orchestration

The SiteOrchestrator maintains energy balance across all simulated assets:

text
Grid = Load - Solar + EV_Charging ± Battery

It automatically discovers assets from configuration and updates the grid meter every 5 seconds.

Profiles & Providers

Simulation behavior is driven by pluggable profile providers:

ProviderInterfacePurpose
Load profilesILoadProfileProviderBuilding consumption patterns
Solar profilesISolarProfileProviderPV generation curves
EV chargingIEvChargingProfileProviderCharging session patterns
PricingIElectricityPricingProviderTime-of-use electricity rates
Demand responseIDemandResponseProviderDR event simulation
Grid statusIGridStatusProviderOutage simulation

Full Site Example

json
{
  "Assets": [
    {
      "Name": "grid-meter",
      "DeviceClass": "SimulatedGridMeter",
      "AssetType": "Grid"
    },
    {
      "Name": "solar-inverter",
      "DeviceClass": "SimulatedSolarInverter",
      "AssetType": "Solar",
      "SimulatedSolarInverter": {
        "InstalledCapacityW": 10000.0
      }
    },
    {
      "Name": "battery",
      "DeviceClass": "SimulatedBattery",
      "AssetType": "Battery",
      "SimulatedBattery": {
        "ConfigurationModel": "MediumResidential"
      }
    },
    {
      "Name": "ev-charger",
      "DeviceClass": "SimulatedChargeStation",
      "AssetType": "ChargeStation"
    }
  ]
}

Register the orchestrator in DI:

csharp
services.AddSingleton<ILoadProfileProvider, ResidentialLoadProfile>();
services.AddHostedService<SiteOrchestrator>();