Connecting a charger · Video 18 of 19
OCPP configuration keys: GetConfiguration and ChangeConfiguration
Read a charger's OCPP configuration keys and change a standard key, then understand its answer: Accepted, Rejected, RebootRequired or NotSupported.
In this video
Shown on a test charger with MeterValueSampleInterval, plus read-only, unknown and manufacturer-specific keys.
Chapters
Transcript
Configuration keys. Read what a charger is set to, and change it from Powerfill. Every OCPP charger keeps a list of settings, called configuration keys. Each has a name and a value. MeterValueSampleInterval, for example: how many seconds between meter readings during a transaction. Or HeartbeatInterval, from the lesson Heartbeat. Others decide what the meter reports, or whether a remote start checks the tag first.
So when readings come too rarely, or a charger behaves differently from its neighbour, look at its keys. Get Configuration asks the charger for its keys. It answers with each value, and marks the read-only ones. A key it does not have comes back as unknown. Always read before you change. Note the value you started from, so you can set it back. Change Configuration sets one key. The charger answers with one of four words.
Accepted: the new value is in use. Rejected: the key is read-only, or the value is not allowed. RebootRequired: the value is stored, and takes effect after a restart. NotSupported: the charger has no such key. After RebootRequired the charger still works with the old value. Restart it with Reset Charger, then read the key again. OCPP defines the standard keys. Manufacturers add keys of their own, and the charger's manual lists them.
Here is a test charger on the Pellio bench. Open All Chargers. Search for its ID, PFU-DEV-02, and open it.
Open Operations. Get Configuration and Change Configuration are in the Configuration group. Click Get Configuration. Leave the key list empty to ask for every key, and click Fetch Configuration. The charger answered with its keys and their values. Each row shows the key, its value, and whether you may change it. NumberOfConnectors is Read-only. The charger decides it, and you cannot change it.
MeterValueSampleInterval is Writable. Let us change it. The pencil on the row changes it right here. We use the command itself: close this window, and click Change Configuration. Standard OCPP Key is already chosen. Pick the key from the list. Powerfill shows the value the charger has now. That is the value to note down before you type a new one. Type the new interval, in seconds. Click Update Configuration.
Powerfill sends the change and waits for the charger's answer. Powerfill confirms the update: the charger answered Accepted. Its next readings come at the new interval. To check it later, run Get Configuration again. That value comes from the charger itself. A manufacturer's key that this charger does not have. Open Change Configuration again. Choose Custom Key, then type the key's name and a value.
Click Update Configuration, and wait for the answer. Powerfill says the operation is not supported. That is the answer NotSupported: the charger has no key with that name. Copy a manufacturer's key name from the manual exactly as it is written. One more habit: after a charger restarts or gets new firmware, read the keys you changed again. That way you know the value the charger really works with, not the one you remember setting.
You can now read a charger's keys, change a standard key, and understand its answer.