Skip to content

EV charging

How the EMS shares power between your EV chargers, the grid connection and the battery, always giving the cars priority.

The EMS controls your EV chargers alongside the battery and solar. Its aim is to give the cars as much power as they can take while keeping the whole site within your grid connection limit, and to give EV charging priority over the battery. The battery is never charged at the expense of the cars, and it will even discharge to help power the cars when they want more than the grid alone can supply.

EV charging behaves the same way whether the site runs cost optimization or self-supply.

The cars come first

Within the grid connection limit, available power is shared in a fixed order:

Consumption Source Building 120 kW EV charging 480 kW EV PV 100 kW Grid 400 kW Battery 100 kW grid import limit 400 kW
During the day the site uses 600 kW: 120 kW for the building and 480 kW for EV charging (up). It comes from PV (100 kW), the grid (400 kW, the limit) and the battery (100 kW). The grid stays at its limit; the battery covers the shortfall.

So the battery and the cars never compete for the grid. The battery charges from whatever the cars leave free, and when the cars need more than the grid can deliver, it discharges to make up the difference.

How much power the cars can get

At every moment the EMS works out how much power is available for EV charging. It is the grid connection limit, plus what the battery can add by discharging, minus whatever the rest of the site is consuming (solar production reduces that consumption, so sunshine leaves more room for the cars).

That total comes in two parts:

  • What the grid can give: available straight away.
  • What the battery can add on top: phased in gradually (see below).

A few things worth knowing:

  • The cars get this power regardless of what the battery is doing at that instant. EV priority is built in, not a balancing act.
  • The battery's contribution is what it can actually sustain right now: as it gets close to empty it can deliver less power, so the extra room it adds for the cars shrinks on its own.
  • When an external trading party directly commands the battery (see selling energy to the grid), the battery is following that command and cannot back the cars at the same time. The cars then get the grid part of the budget only.
  • If the rest of the site is already using everything the grid and battery can supply, there is no room left for EV charging.
  • Chargers the EMS does not manage simply count as normal site consumption.

Ramping up smoothly

The grid gives what it can straight away. What the battery adds comes in gradually: the cars' allowance rises in small steps and follows their actual draw, so the battery can keep up without exceeding the grid limit. If a car draws less, the allowance drops with it. If less power becomes available, the limit is lowered immediately.

Sharing the grid with scheduled battery charging

Scheduled battery charging only uses the room the cars do not need. If the cars draw more, they give that room back step by step. Once they have settled, the unused margin goes to battery charging, and it is immediately available again as soon as a car draws more.

When several cars charge at once

Available power is shared across the active sessions. Connectors have a priority (1 = highest, 3 = lowest): sessions with a higher priority are served first, and sessions with the same priority share in proportion to what each car wants. Every session is guaranteed a minimum charging power.

  • DC fast chargers report the maximum the car negotiated, and that is the ceiling within the shared budget.
  • AC chargers do not report it. The EMS estimates demand from what the car actually draws, and that estimate only drops after the car has drawn noticeably less for a while.

The power the EMS allows a charger is a ceiling: the most the car is allowed to draw, not a target. A nearly-full car that only draws a few kilowatts simply keeps charging under its ceiling; this is harmless, because the battery only ever helps with the power the car is actually drawing.

Example: a second car arrives

Grid connection limit 400 kW, a battery that can deliver 400 kW, and no other consumption on site. One car starts charging; a second starts two minutes later at another station; the first stops a few minutes after that. Both cars can take 400 kW.

Moment Car A Car B From the grid From the battery
Car A starts 400 kW – 400 kW 0
Car B starts 200 kW 200 kW 400 kW 0
…a short while later… rising rising 400 kW rising
Both ramped up 400 kW 400 kW 400 kW 400 kW
Car A stops – 400 kW 400 kW 0
0 400 800 grid limit 400 kW A starts B starts Ramp-up Both full A stops From the grid From the battery
Car A starts alone, then car B starts and they share the grid. The battery builds up the power until both reach 400 kW, and the grid stays at its 400 kW limit.

The first car gets its full 400 kW straight from the grid. When the second car arrives, the grid can feed both only at 200 kW each at that instant, so they share, and then the battery ramps up over the next minute or two to lift both back to 400 kW. When the first car leaves, the grid alone covers the second car again and the battery stops discharging, without ever interrupting the second car.

Staying within the grid limit

The EMS continuously checks the measured power at the grid connection and trims the cars' power if reality drifts over the limit, for example because of a brief measurement delay or a charger that is slow to follow. In normal operation the gradual ramp keeps the site at the limit on its own, so this only steps in on short transients.

EV charging and the peak shaving reserve

Battery discharge to support the cars is a form of peak shaving: it exists to keep the grid import at its limit, whatever causes the peak. That has two consequences:

  • Supporting the cars is always allowed, all the way down to the battery's minimum state of charge. The peak shaving reserve does not block it; the reserve only blocks discharging for other purposes (such as price arbitrage), precisely so that energy stays available for peaks like EV fast charging.
  • A site with heavy EV fast charging can set a peak shaving reserve to make sure the battery keeps enough energy on hand for the next charging session, instead of spending it on other optimizations.

Settings that affect EV charging

Setting What it does
Grid connection limit The ceiling the whole site (cars, consumption and battery charging together) must stay under
Connector priority Which charging sessions are served first when power is tight (1 = highest, 3 = lowest)
Peak shaving reserve Battery energy set aside for shaving import peaks, so it stays available to help power the cars

Relationship to the control strategies

EV charging works the same way under cost optimization and self-supply: the cars are always served first, and the battery's own charging takes only what the cars leave free. For the chargers the EMS supports, see EV chargers.