Skip to content

v0.3.0

Choose a tag to compare

@github-actions github-actions released this 27 Nov 07:15
· 1 commit to main since this release
83c3624

A site file can now say what state each charger is in, and keep it so: plugged in, faulted, offline or left off, each time the charger powers on.

Before you update

A Finishing connector now accepts a new start. In v0.2.1 a connector whose transaction had ended with the EV still plugged in refused every start until the EV was unplugged. Now an accepted tap or a RemoteStartTransaction starts a new transaction, and the CSMS sees Preparing, then Charging (OCPP 1.6 section 4.9, transition F2).

  • A test that expects Rejected from a Finishing connector needs changing. A faulted, unavailable or busy connector still answers Rejected.
  • A remote start that names no connector picks one with an EV waiting, then one that is Finishing, then the lowest-numbered free one.
  • A rejected tag leaves the connector Finishing, and nothing starts by itself there, even with startOn: plug.
  • Site files, Chargerfiles, scenarios and saved chargers work as before. A charger with no state block behaves as it did.

New

Declared state in the site file

A charger entry may carry a state block: the state the charger is in each time it powers on.

chargers:
  lobby: { model: ./wallbox.Chargerfile, id: LOBBY-1, state: { connectors: { 1: { ev: longrange } } } }   # Preparing
  bay:   { model: ./Chargerfile, id: BAY-1, state: { connectors: { 2: { fault: { code: GroundFailure, info: RCD tripped } } } } }
  gone:  { model: ./Chargerfile, id: GONE-1, state: { connection: offline } }      # stays away
  spare: { model: ./Chargerfile, id: SPARE-1, state: { connection: stopped } }     # never started
  • It is applied at every power-on: site up, site start, start, restart, a start after kill, and the restart plugyard update does. A reboot and a Reset from the CSMS are not a power-on.
  • A change made by hand lasts until the next power-on. plugyard restart BAY-1 puts one charger back.
  • A connector that is listed is declared whole; one that is not listed follows the saved state. What the CSMS set, such as Unavailable, meters, configuration and charging profiles, is untouched.
  • A charger declared stopped is created and left off; plugyard start SPARE-1 powers it on.
  • inspect and site validate show what is declared.

Renewing a declared EV

A plugged-in EV fills up in the end, and every transaction after that ends at once. A declared EV may now say renew:

state:
  connectors:
    1: { ev: longrange, renew: 5m }
  • Once the EV is full and its connector has no transaction, it leaves after the renew time, and a fresh EV of the same preset arrives after the same time again. The connector reports Finishing, Available, Preparing.
  • The time is real time, whatever the speed of the site.
  • With startOn: plug the fresh EV starts a transaction, so the connector keeps cycling. With onEvFull: suspend the transaction stays open and the EV is not renewed.
  • Only the declared EV is renewed. Plugging in or unplugging by hand ends it until the charger next powers on.

What's Changed

  • Pin the compose example to 0.2.1 by @Amraa1 in #38
  • Start a new transaction on a Finishing connector by @Amraa1 in #41
  • Declare each charger's state in the site file by @Amraa1 in #43
  • Renew a declared EV when it is full by @Amraa1 in #44

Full Changelog: v0.2.1...v0.3.0