Skip to main content

Start sending BESS data

Pleevi supports Battery Energy Storage Systems (BESS) as part of its optimization platform. This page explains everything you need to know for configuring and sending BESS data. Unlike charging poles, BESS devices don't use transactions - they only require site configuration and measurement data.

Publishing BESS Measurements to MQTT

For BESS devices, measurements must include the currentStateOfCharge field. This is crucial for the optimizer to understand how much energy is stored in the battery and make informed decisions about charging and discharging. The currentStateOfCharge concerns the oprational state of charge of the BESS.

The measurement format is the same as for other devices, with energyValue tracking the cumulative energy, powerValue indicating current power flow (positive for charging, negative for discharging), and currentStateOfCharge showing the battery's current charge level as a percentage.

An example measurement could look like:

{
"assetId": "charger-A1",
"timestamp": "2024-07-29T15:51:28.071Z",
"energyValue": 1030404,
"powerValue": 7000,
"currentStateOfCharge": 85.49
}

For reference, the full schema for a BESS Measurement is:

BESS MQTT Measurement

    assetIdAssetid (string)required

    The unique identifier of the asset. This matches the name in the site configuration. This can be a metered device such as a charging pole or a battery, a subcollector meter or any (virtual) device supplying energy data (metered, estimated or calculated).

    timestampstring<date-time>required

    The timestamp when the measurement was taken

    energyValueEnergyvalue (number)required

    The energy (in Wh) that has been delivered/received by the asset up to the timestamp. This can be an absolute value that indicates the meter value across the lifetime of the meter (e.g. for a charging pole that keeps increasing across transactions). For charging poles, it can also be a relative one, that only includes the energy charged since the start of the transaction.

    powerValuePowervalue (number)required

    The power (in W) measured at the timestamp for this asset

    currentStateOfCharge object

    State of charge of the battery in percentage. Can be null / omitted if not available or if there is no battery connected to this asset. For charging poles, this should be the state of charge of the connected EV.

    anyOf
    number

    State of Charge in percentage (0-100%)

    Possible values: >= 0 and <= 100


Site Configuration

In the device_list of the Site Configuration, you can add a BESS device as follows:

{
"name": "LR34_001",
"collector": "main_collector",
"type": "battery_energy_storage_system",
"charging_efficiency": 0.95,
"discharging_efficiency": 0.95,
"maximum_charging_power": 0,
"maximum_discharging_power": 0,
"operational_battery_capacity": 0,
"charging_priority": 10,
"discharging_priority": 10,
"policies": [
null
]
}

The key parameters for a BESS device include:

  • maximum_charging_power and maximum_discharging_power: Define the battery's power limits in W
  • operational_battery_capacity: The usable battery capacity in Wh
  • charging_efficiency and discharging_efficiency: Account for energy losses during charging/discharging (default 0.95)
  • charging_priority and discharging_priority: Control when the battery should charge or discharge relative to other devices (1-10, default 10)

The full schema is:

BESS Device

    nameName (string)required

    The name of the device itself. This value will be used as the asset ID in the rest of the API.

    collectorCollector (string)required

    The name of the collector to which this device is connected.

    typeType (string)
    Constant value: battery_energy_storage_system
    Default value: battery_energy_storage_system
    charging_efficiencyCharging Efficiency (number)

    Charging efficiency of the battery [0 < x <= 1].

    Possible values: > 0 and <= 1

    Default value: 0.95
    discharging_efficiencyDischarging Efficiency (number)

    Discharging efficiency of the battery [0 < x <= 1].

    Possible values: > 0 and <= 1

    Default value: 0.95
    maximum_charging_powerMaximum Charging Power (number)required

    Maximum charging power of the battery in W.

    Possible values: > 0

    maximum_discharging_powerMaximum Discharging Power (number)required

    Maximum discharging power of the battery in W.

    Possible values: > 0

    operational_battery_capacityOperational Battery Capacity (number)required

    The operational battery capacity in Wh.

    Possible values: > 0

    charging_priorityCharging Priority (integer)

    Priority of charging the battery. Default is 10

    Possible values: >= 1 and <= 10

    Default value: 10
    discharging_priorityDischarging Priority (integer)

    Priority of discharging the battery. Default is 10

    Possible values: >= 1 and <= 10

    Default value: 10
    policiesundefined[]

    List of policies for the BESS device.

    Default value: []

Policies and Schedules

BESS devices support policies that allow you to enforce specific charging behavior. The most common policy type is a scheduled policy, which ensures the battery reaches a target state of charge at specific times.

Scheduled Policies

A scheduled policy allows you to define time windows when the battery must be charged to a specific level. This is useful for ensuring the battery is fully charged before peak demand periods.

For example, you might want to ensure your battery is at least 80% charged every weekday morning at 6 AM to handle the morning demand peak.

{
"type": "schedule",
"minimum_state_of_charge": 85.49,
"maximum_state_of_charge": 85.49
}

Scheduled BESS Policy

    typeType (string)
    Constant value: schedule
    Default value: schedule
    schedulerequired

    The schedule defining when the state of charge should be between minimum_state_of_charge and maximum_state_of_charge.

    minimum_state_of_chargeMinimum State Of Charge (number)required

    The minimum state of charge to reach at the scheduled time. At each timestamp in the schedule, the state of charge will be between minimum_state_of_charge and maximum_state_of_charge.

    Possible values: >= 0 and <= 100

    maximum_state_of_chargeMaximum State Of Charge (number)required

    The maximum state of charge to reach at the scheduled time. At each timestamp in the schedule, the state of charge will be between minimum_state_of_charge and maximum_state_of_charge.

    Possible values: >= 0 and <= 100

The optimizer will automatically charge the BESS to meet these policy requirements while still optimizing for cost and other objectives.