Set Charging Profiles
For advanced smart charging via OCPP 1.6J smart charging profiles
Developers that want a higher degree of control over power delivery beyond Chargestation Power Limits and Real Time Session Power Management can use native charging profiles as provided by the OCPP protocol.
Please see "Open Charge Point Protocol 1.6 - 5.16. Set Charging Profile"
Charging profiles comprise charging schedules that encompass time intervals, their corresponding maximum charge power or current, and additional configurations to specify the time period and recurrence. By leveraging these advanced features, developers can implement more complex smart charging systems.
Using eDRV APIs to Set and Clear Charging Profiles
Set a Charging Profile
Use the SetChargingProfile endpoint to send a native OCPP charging profile to your chargestation.
Using SetChargingProfile in your application
When using the
SetChargingProfile
API, you are required to generate and store the charging profile object within your application data storage.For example you are required to generate a unique
chargingProfileId
per charging profile. You will need to refer to this id when trying to clear the charging profile in the future.You will also need to keep a track of
stackLevel
in your application and ensure that it does not clash with levels reserved for eDRV APIs. See Reserved Stack Levels below.
Clearing a Charging Profile
In order to clear a charging profile with the ClearChargingProfile endpoint, your application will need to store the chargingProfileId
.
Webhooks
Your application should listen for the following Webhooks
chargestation.set_charging_profile.requested
chargestation.set_charging_profile.accepted
chargestation.set_charging_profile.rejected
chargestation.clear_charging_profile.requested
chargestation.clear_charging_profile.accepted
chargestation.clear_charging_profile.rejected
Types of Charging Profile Purposes
- ChargePointMaxProfile
- TxDefaultProfile
- TxProfile
ChargePointMaxProfile
The profile is used to set limits at the charge station. When configuring the limit value, it is important to consider the combined limit for all the connectors in order to ensure optimal performance.
Notes
ChargePointMaxProfile can only be set at Charge Point ConnectorId 0.
The following example sets a recurring 20 kW power limit for the charge station.
{
"connectorId": 0,
"csChargingProfiles": {
"chargingProfileId": 11,
"stackLevel": 11,
"chargingProfilePurpose": "ChargePointMaxProfile",
"chargingProfileKind": "Recurring",
"recurrencyKind": "Daily",
"chargingSchedule": {
"startSchedule": "2023-06-27T10:46:13.857Z",
"duration": 86400,
"chargingRateUnit": "W",
"chargingSchedulePeriod": [
{
"startPeriod": 0,
"limit": 20000
}
]
}
}
}
The following example sets a relative 20 Amps limit for the charge station.
{
"connectorId": 0,
"csChargingProfiles": {
"chargingProfileId": 12,
"stackLevel": 12,
"chargingProfilePurpose": "ChargePointMaxProfile",
"chargingProfileKind": "Relative",
"chargingSchedule": {
"chargingRateUnit": "A",
"chargingSchedulePeriod": [
{
"startPeriod": 0,
"limit": 20
}
]
}
}
}
Note: Relative Schedule periods are relative to a situation-specific start point (such as the start of a Transaction) that is determined by the charge point.
TxDefaultProfile
This profile is used to set default limits at the connector level. When a new session is started, this profile SHALL be used, unless the session is started using RemoteStartTransaction.req with a ChargeProfile.
Note
If TxDefaultProfile is set to ConnectorId 0, the TxDefaultProfile is applicable to all Connectors.
If ConnectorId is set >0, it only applies to that specific connector.
In the event a TxDefaultProfile for connector 0 is installed, and the Central System sends a new profile with ConnectorId >0, the TxDefaultProfile SHALL be replaced only for that specific connector.
The following example sets a recurring 10kW power limit on connector 1
{
"connectorId": 1,
"csChargingProfiles": {
"chargingProfileId": 13,
"stackLevel": 13,
"chargingProfilePurpose": "TxDefaultProfile",
"chargingProfileKind": "Recurring",
"recurrencyKind": "Daily",
"chargingSchedule": {
"startSchedule": "2023-06-28T14:48:55.176Z",
"duration": 86400,
"chargingRateUnit": "W",
"chargingSchedulePeriod": [
{
"startPeriod": 0,
"limit": 10000
}
]
}
}
}
The following example sets an absolute profile for a short duration on connector 2
{
"connectorId": 2,
"csChargingProfiles": {
"chargingProfileId": 14,
"stackLevel": 14,
"chargingProfilePurpose": "TxDefaultProfile",
"chargingProfileKind": "Absolute",
"chargingSchedule": {
"startSchedule": "2023-06-28T15:36:25.000Z",
"duration": 240,
"chargingRateUnit": "W",
"chargingSchedulePeriod": [
{
"startPeriod": 0,
"limit": 13000
}
]
}
}
}
The following example sets a relative profile with varying power limits vs. time on connector 1
{
"connectorId": 1,
"csChargingProfiles": {
"chargingProfileId": 15,
"stackLevel": 15,
"chargingProfilePurpose": "TxDefaultProfile",
"chargingProfileKind": "Relative",
"chargingSchedule": {
"chargingRateUnit": "W",
"chargingSchedulePeriod": [
{
"startPeriod": 0,
"limit": 0
},
{
"startPeriod": 30,
"limit": 8000
},
{
"startPeriod": 60,
"limit": 10000
}
]
}
}
}
TxProfile
OCPP transactionId
When using /v1.1/chargestations/{id}/set_charging_profile with
chargingProfilePurpose
asTxProfile
, you do not need to include the OCPP transactionId. eDRV will insert this in your request to the chargestation based on the Session Id.
TXProfile is used to set a power limit for a specific session. As the limits are applied at the session level it should automatically expire at the end of a session. If there is no session active on the connector specified, the charge station rejects the profile request.
Note on using
duration
with TxProfileTxProfile overrules any default charging profile set by TxDefaultProfile
With an Absolute profile kind for a session, the startSchedule should be a session start time and duration must be calculated considering the time that has already elapsed since session start time.
startSchedule
= session.createdAtduration
= (currentTime - session.createdAt (in sec))+ desired_duration(in sec)
The following example sets an Absolute 13 kW limit on a session with a duration
{
"connectorId": 1,
"csChargingProfiles": {
"chargingProfileId": 16,
"stackLevel": 16,
"chargingProfilePurpose": "TxProfile",
"chargingProfileKind": "Absolute",
"chargingSchedule": {
"startSchedule": "2023-06-28T14:31:32.898Z",
"duration": 1660,
"chargingRateUnit": "W",
"chargingSchedulePeriod": [
{
"startPeriod": 0,
"limit": 13000
}
]
}
}
}
Combining Multiple Profiles
Charging profiles can be used in combination with each other. It is possible to stack multiple profiles where the stack level denotes their priority. For instance, we can establish a safety limit at the connector level using the TxDefaultProfile and subsequently overwrite it for individual charging sessions using the TxProfile.
Reserved Stack Levels
eDRV reserves stack levels [0-10] for eDRV power management APIs. Please avoid using these stack levels where possible.
To apply these limits using the Charging Profile API, the following examples can be used for reference:
Apply a safe limit of 10 kW using TxDefaultProfile
{
"connectorId": 1,
"csChargingProfiles": {
"chargingProfileId": 17,
"stackLevel": 17,
"chargingProfilePurpose": "TxDefaultProfile",
"chargingProfileKind": "Recurring",
"recurrencyKind": "Daily",
"chargingSchedule": {
"startSchedule": "2023-06-28T14:48:55.176Z",
"duration": 86400,
"chargingRateUnit": "W",
"chargingSchedulePeriod": [
{
"startPeriod": 0,
"limit": 10000
}
]
}
}
}
Apply a more ambitious limit of 13 kW using TxDefaultProfile that auto-expires
{
"connectorId": 1,
"csChargingProfiles": {
"chargingProfileId": 20,
"stackLevel": 20,
"chargingProfilePurpose": "TxDefaultProfile",
"chargingProfileKind": "Absolute",
"chargingSchedule": {
"startSchedule": "2023-06-28T15:28:25.000Z",
"duration": 180,
"chargingRateUnit": "W",
"chargingSchedulePeriod": [
{
"startPeriod": 0,
"limit": 13000
}
]
}
}
}
Note
startSchedule is a required field. This profile's expiry time = startSchedule + duration
Apply a 13 kW limit for a session using TxProfile
{
"connectorId": 1,
"csChargingProfiles": {
"chargingProfileId": 21,
"stackLevel": 21,
"chargingProfilePurpose": "TxProfile",
"chargingProfileKind": "Absolute",
"chargingSchedule": {
"startSchedule": "2023-06-28T14:31:32.898Z",
"duration": 1660,
"chargingRateUnit": "W",
"chargingSchedulePeriod": [
{
"startPeriod": 0,
"limit": 13000
}
]
}
}
}
Track the Charging Profiles Status
via admin panel
Go to Chargestation Details > Events Tab, filter by Event Type Set Charging Profile
or Clear Charging Profile
Use Get Composite Schedule
You can also use the Get composite schedule feature to check the power or current limits that have been applied to the charge station or connector.
Updated over 1 year ago