Docs › OCPP 2.0.1 › MeterValues

MeterValues OCPP 2.0.1

Der Simulator sendet diese Nachricht als Ladepunkt.

Auch in: OCPP 1.6, OCPP 2.1

Request

FeldTypEinschränkungen / Beschreibung
evseIdintegerPflichtRequest_ Body. EVSEID. Numeric_ Identifier urn:x-enexis:ecdm:uid:1:571101 This contains a number (>0) designating an EVSE of the Charging Station. ‘0’ (zero) is used to designate the main power meter.
meterValuearray<object>PflichtminItems 1
meterValue[].sampledValuearray<object>PflichtminItems 1
meterValue[].sampledValue[].valuenumberPflichtSampled_ Value. Value. Measure urn:x-oca:ocpp:uid:1:569260 Indicates the measured value.
meterValue[].sampledValue[].contextstringenum: Interruption.Begin, Interruption.End, Other, Sample.Clock, Sample.Periodic, Transaction.Begin, Transaction.End, Trigger
Sampled_ Value. Context. Reading_ Context_ Code urn:x-oca:ocpp:uid:1:569261 Type of detail value: start, end or sample. Default = "Sample.Periodic"
meterValue[].sampledValue[].measurandstringenum: Current.Export, Current.Import, Current.Offered, Energy.Active.Export.Register, Energy.Active.Import.Register, Energy.Reactive.Export.Register, Energy.Reactive.Import.Register, Energy.Active.Export.Interval, Energy.Active.Import.Interval, Energy.Active.Net, Energy.Reactive.Export.Interval, Energy.Reactive.Import.Interval, Energy.Reactive.Net, Energy.Apparent.Net, Energy.Apparent.Import, Energy.Apparent.Export, Frequency, Power.Active.Export, Power.Active.Import, Power.Factor, Power.Offered, Power.Reactive.Export, Power.Reactive.Import, SoC, Voltage
Sampled_ Value. Measurand. Measurand_ Code urn:x-oca:ocpp:uid:1:569263 Type of measurement. Default = "Energy.Active.Import.Register"
meterValue[].sampledValue[].phasestringenum: L1, L2, L3, N, L1-N, L2-N, L3-N, L1-L2, L2-L3, L3-L1
Sampled_ Value. Phase. Phase_ Code urn:x-oca:ocpp:uid:1:569264 Indicates how the measured value is to be interpreted. For instance between L1 and neutral (L1-N) Please note that not all values of phase are applicable to all Measurands. When phase is absent, the measured value is interpreted as an overall value.
meterValue[].sampledValue[].locationstringenum: Body, Cable, EV, Inlet, Outlet
Sampled_ Value. Location. Location_ Code urn:x-oca:ocpp:uid:1:569265 Indicates where the measured value has been sampled. Default = "Outlet"
meterValue[].sampledValue[].signedMeterValueobjectRepresent a signed version of the meter value.
meterValue[].sampledValue[].signedMeterValue.signedMeterDatastringPflichtmaxLength 2500
Base64 encoded, contains the signed data which might contain more then just the meter value. It can contain information like timestamps, reference to a customer etc.
meterValue[].sampledValue[].signedMeterValue.signingMethodstringPflichtmaxLength 50
Method used to create the digital signature.
meterValue[].sampledValue[].signedMeterValue.encodingMethodstringPflichtmaxLength 50
Method used to encode the meter values before applying the digital signature algorithm.
meterValue[].sampledValue[].signedMeterValue.publicKeystringPflichtmaxLength 2500
Base64 encoded, sending depends on configuration variable _PublicKeyWithSignedMeterValue_.
meterValue[].sampledValue[].unitOfMeasureobjectRepresents a UnitOfMeasure with a multiplier
meterValue[].sampledValue[].unitOfMeasure.unitstringmaxLength 20
Unit of the value. Default = "Wh" if the (default) measurand is an "Energy" type. This field SHALL use a value from the list Standardized Units of Measurements in Part 2 Appendices. If an applicable unit is available in that list, otherwise a "custom" unit might be used.
meterValue[].sampledValue[].unitOfMeasure.multiplierintegerMultiplier, this value represents the exponent to base 10. I.e. multiplier 3 means 10 raised to the 3rd power. Default is 0.
meterValue[].timestampstringPflichtformat date-time
Meter_ Value. Timestamp. Date_ Time urn:x-oca:ocpp:uid:1:569259 Timestamp for measured value(s).
JSON-Schema (Request)
{
  "$schema": "http://json-schema.org/draft-06/schema#",
  "description": "Request_ Body\r\nurn:x-enexis:ecdm:uid:2:234744\r\n",
  "comment": "OCPP 2.0.1 FINAL",
  "definitions": {
    "CustomDataType": {
      "description": "This class does not get 'AdditionalProperties = false' in the schema generation, so it can be extended with arbitrary JSON properties to allow adding custom data.",
      "javaType": "CustomData",
      "type": "object",
      "properties": {
        "vendorId": {
          "type": "string",
          "maxLength": 255
        }
      },
      "required": [
        "vendorId"
      ]
    },
    "LocationEnumType": {
      "description": "Sampled_ Value. Location. Location_ Code\r\nurn:x-oca:ocpp:uid:1:569265\r\nIndicates where the measured value has been sampled. Default =  \"Outlet\"\r\n\r\n",
      "javaType": "LocationEnum",
      "type": "string",
      "default": "Outlet",
      "additionalProperties": false,
      "enum": [
        "Body",
        "Cable",
        "EV",
        "Inlet",
        "Outlet"
      ]
    },
    "MeasurandEnumType": {
      "description": "Sampled_ Value. Measurand. Measurand_ Code\r\nurn:x-oca:ocpp:uid:1:569263\r\nType of measurement. Default = \"Energy.Active.Import.Register\"\r\n",
      "javaType": "MeasurandEnum",
      "type": "string",
      "default": "Energy.Active.Import.Register",
      "additionalProperties": false,
      "enum": [
        "Current.Export",
        "Current.Import",
        "Current.Offered",
        "Energy.Active.Export.Register",
        "Energy.Active.Import.Register",
        "Energy.Reactive.Export.Register",
        "Energy.Reactive.Import.Register",
        "Energy.Active.Export.Interval",
        "Energy.Active.Import.Interval",
        "Energy.Active.Net",
        "Energy.Reactive.Export.Interval",
        "Energy.Reactive.Import.Interval",
        "Energy.Reactive.Net",
        "Energy.Apparent.Net",
        "Energy.Apparent.Import",
        "Energy.Apparent.Export",
        "Frequency",
        "Power.Active.Export",
        "Power.Active.Import",
        "Power.Factor",
        "Power.Offered",
        "Power.Reactive.Export",
        "Power.Reactive.Import",
        "SoC",
        "Voltage"
      ]
    },
    "PhaseEnumType": {
      "description": "Sampled_ Value. Phase. Phase_ Code\r\nurn:x-oca:ocpp:uid:1:569264\r\nIndicates how the measured value is to be interpreted. For instance between L1 and neutral (L1-N) Please note that not all values of phase are applicable to all Measurands. When phase is absent, the measured value is interpreted as an overall value.\r\n",
      "javaType": "PhaseEnum",
      "type": "string",
      "additionalProperties": false,
      "enum": [
        "L1",
        "L2",
        "L3",
        "N",
        "L1-N",
        "L2-N",
        "L3-N",
        "L1-L2",
        "L2-L3",
        "L3-L1"
      ]
    },
    "ReadingContextEnumType": {
      "description": "Sampled_ Value. Context. Reading_ Context_ Code\r\nurn:x-oca:ocpp:uid:1:569261\r\nType of detail value: start, end or sample. Default = \"Sample.Periodic\"\r\n",
      "javaType": "ReadingContextEnum",
      "type": "string",
      "default": "Sample.Periodic",
      "additionalProperties": false,
      "enum": [
        "Interruption.Begin",
        "Interruption.End",
        "Other",
        "Sample.Clock",
        "Sample.Periodic",
        "Transaction.Begin",
        "Transaction.End",
        "Trigger"
      ]
    },
    "MeterValueType": {
      "description": "Meter_ Value\r\nurn:x-oca:ocpp:uid:2:233265\r\nCollection of one or more sampled values in MeterValuesRequest and TransactionEvent. All sampled values in a MeterValue are sampled at the same point in time.\r\n",
      "javaType": "MeterValue",
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "customData": {
          "$ref": "#/definitions/CustomDataType"
        },
        "sampledValue": {
          "type": "array",
          "additionalItems": false,
          "items": {
            "$ref": "#/definitions/SampledValueType"
          },
          "minItems": 1
        },
        "timestamp": {
          "description": "Meter_ Value. Timestamp. Date_ Time\r\nurn:x-oca:ocpp:uid:1:569259\r\nTimestamp for measured value(s).\r\n",
          "type": "string",
          "format": "date-time"
        }
      },
      "required": [
        "timestamp",
        "sampledValue"
      ]
    },
    "SampledValueType": {
      "description": "Sampled_ Value\r\nurn:x-oca:ocpp:uid:2:233266\r\nSingle sampled value in MeterValues. Each value can be accompanied by optional fields.\r\n\r\nTo save on mobile data usage, default values of all of the optional fields are such that. The value without any additional fields will be interpreted, as a register reading of active import energy in Wh (Watt-hour) units.\r\n",
      "javaType": "SampledValue",
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "customData": {
          "$ref": "#/definitions/CustomDataType"
        },
        "value": {
          "description": "Sampled_ Value. Value. Measure\r\nurn:x-oca:ocpp:uid:1:569260\r\nIndicates the measured value.\r\n\r\n",
          "type": "number"
        },
        "context": {
          "$ref": "#/definitions/ReadingContextEnumType"
        },
        "measurand": {
          "$ref": "#/definitions/MeasurandEnumType"
        },
        "phase": {
          "$ref": "#/definitions/PhaseEnumType"
        },
        "location": {
          "$ref": "#/definitions/LocationEnumType"
        },
        "signedMeterValue": {
          "$ref": "#/definitions/SignedMeterValueType"
        },
        "unitOfMeasure": {
          "$ref": "#/definitions/UnitOfMeasureType"
        }
      },
      "required": [
        "value"
      ]
    },
    "SignedMeterValueType": {
      "description": "Represent a signed version of the meter value.\r\n",
      "javaType": "SignedMeterValue",
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "customData": {
          "$ref": "#/definitions/CustomDataType"
        },
        "signedMeterData": {
          "description": "Base64 encoded, contains the signed data which might contain more then just the meter value. It can contain information like timestamps, reference to a customer etc.\r\n",
          "type": "string",
          "maxLength": 2500
        },
        "signingMethod": {
          "description": "Method used to create the digital signature.\r\n",
          "type": "string",
          "maxLength": 50
        },
        "encodingMethod": {
          "description": "Method used to encode the meter values before applying the digital signature algorithm.\r\n",
          "type": "string",
          "maxLength": 50
        },
        "publicKey": {
          "description": "Base64 encoded, sending depends on configuration variable _PublicKeyWithSignedMeterValue_.\r\n",
          "type": "string",
          "maxLength": 2500
        }
      },
      "required": [
        "signedMeterData",
        "signingMethod",
        "encodingMethod",
        "publicKey"
      ]
    },
    "UnitOfMeasureType": {
      "description": "Represents a UnitOfMeasure with a multiplier\r\n",
      "javaType": "UnitOfMeasure",
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "customData": {
          "$ref": "#/definitions/CustomDataType"
        },
        "unit": {
          "description": "Unit of the value. Default = \"Wh\" if the (default) measurand is an \"Energy\" type.\r\nThis field SHALL use a value from the list Standardized Units of Measurements in Part 2 Appendices. \r\nIf an applicable unit is available in that list, otherwise a \"custom\" unit might be used.\r\n",
          "type": "string",
          "default": "Wh",
          "maxLength": 20
        },
        "multiplier": {
          "description": "Multiplier, this value represents the exponent to base 10. I.e. multiplier 3 means 10 raised to the 3rd power. Default is 0.\r\n",
          "type": "integer",
          "default": 0
        }
      }
    }
  },
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "customData": {
      "$ref": "#/definitions/CustomDataType"
    },
    "evseId": {
      "description": "Request_ Body. EVSEID. Numeric_ Identifier\r\nurn:x-enexis:ecdm:uid:1:571101\r\nThis contains a number (&gt;0) designating an EVSE of the Charging Station. ‘0’ (zero) is used to designate the main power meter.\r\n",
      "type": "integer"
    },
    "meterValue": {
      "type": "array",
      "additionalItems": false,
      "items": {
        "$ref": "#/definitions/MeterValueType"
      },
      "minItems": 1
    }
  },
  "required": [
    "evseId",
    "meterValue"
  ]
}

Response

Leeres Objekt {}.

JSON-Schema (Response)
{
  "$schema": "http://json-schema.org/draft-06/schema#",
  "comment": "OCPP 2.0.1 FINAL",
  "definitions": {
    "CustomDataType": {
      "description": "This class does not get 'AdditionalProperties = false' in the schema generation, so it can be extended with arbitrary JSON properties to allow adding custom data.",
      "javaType": "CustomData",
      "type": "object",
      "properties": {
        "vendorId": {
          "type": "string",
          "maxLength": 255
        }
      },
      "required": [
        "vendorId"
      ]
    }
  },
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "customData": {
      "$ref": "#/definitions/CustomDataType"
    }
  }
}

Quelle: Open Charge Alliance, OCPP 2.0.1 – JSON-Schemas, unverändert wiedergegeben. © Open Charge Alliance. Lizenz: CC BY-ND 4.0. Die vollständige Spezifikation gibt es bei der Open Charge Alliance. ocpp-sim ist nicht mit der OCA verbunden.