Skip to content

Added support of OCPP 2.0.1 #218

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 19 commits into from
Jun 19, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
082ecca
Move OCPP 1.6 specific classes in dedicated directories
c-jimenez Jul 15, 2024
2edcedb
Move OCPP 1.6 specific classes in dedicated namespaces
c-jimenez Jul 15, 2024
1e126bf
[schemas] Add OCPP 2.0.1 messages schemas
c-jimenez Aug 11, 2024
6e5244a
[ocpp20] Add generated types and messages
c-jimenez Sep 8, 2024
d6556fb
[ocpp20] Add central system and local controller classes
c-jimenez Oct 22, 2024
8d03440
[ocpp20] Rename messages and types with ocpp version suffix to avoid …
c-jimenez Oct 22, 2024
015ecc9
[ocpp20] Add quick start central system and local controller examples
c-jimenez Oct 22, 2024
9e78820
[ocpp20] Add charge point interfaces and classes
c-jimenez Oct 22, 2024
e27235c
[ocpp20] Add quick start charge point example
c-jimenez Oct 22, 2024
c137e49
[ocpp20] Update messages and types names
c-jimenez Oct 23, 2024
208f132
[ocpp20] Add OCPP 2.0.1 schemas to install dir
c-jimenez Oct 23, 2024
6ccb828
[ocpp20] Fix clang build
c-jimenez Oct 23, 2024
348e333
[ocpp20] Add device model serialization to/from JSON
c-jimenez Oct 27, 2024
89929e2
[messages] Use rapidjson::kObjectType constructor instead of Parse({}…
c-jimenez Oct 27, 2024
1440c49
[ocpp20] Allow multiple instances of same variable in device model
c-jimenez Oct 28, 2024
203e2a9
[ocpp20] Add device model implementation + GetBaseReport implementati…
c-jimenez Oct 28, 2024
46dc333
[ocpp20] Start of BasicChargePoint implementation
c-jimenez Nov 15, 2024
f5ca3e3
Fix build after rebase on last revision of develop branch
c-jimenez May 28, 2025
54eee50
[readme] Update with OCPP2.X features
c-jimenez Jun 19, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
25 changes: 19 additions & 6 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "gdb",
"request": "launch",
"name": "x86 CP debug",
"target": "${workspaceRoot}/bin/gcc_native/quick_start_chargepoint",
"target": "${workspaceRoot}/bin/gcc_native/quick_start_chargepoint20",
"cwd": "${workspaceRoot}/bin/gcc_native/",
"arguments": "-r",
"valuesFormatting": "parseText"
},
{
"type": "gdb",
"request": "launch",
"name": "x86 Basic CP debug",
"target": "${workspaceRoot}/bin/gcc_native/quick_start_basicchargepoint20",
"cwd": "${workspaceRoot}/bin/gcc_native/",
"arguments": "-r",
"valuesFormatting": "parseText"
Expand All @@ -17,7 +23,7 @@
"type": "gdb",
"request": "launch",
"name": "x86 CS debug",
"target": "${workspaceRoot}/bin/gcc_native/quick_start_centralsystem",
"target": "${workspaceRoot}/bin/gcc_native/quick_start_centralsystem20",
"cwd": "${workspaceRoot}/bin/gcc_native/",
"arguments": "-r",
"valuesFormatting": "parseText"
Expand All @@ -26,7 +32,7 @@
"type": "gdb",
"request": "launch",
"name": "x86 LC debug",
"target": "${workspaceRoot}/bin/gcc_native/quick_start_localcontroller",
"target": "${workspaceRoot}/bin/gcc_native/quick_start_localcontroller20",
"cwd": "${workspaceRoot}/bin/gcc_native/",
"arguments": "-r",
"valuesFormatting": "parseText"
Expand Down Expand Up @@ -58,6 +64,13 @@
"ignoreFailures": true
}
]
},
{
"name": "json2cpp",
"type": "debugpy",
"request": "launch",
"program": "${workspaceRoot}/tools/json2cpp/json2cpp.py",
"args": ["-i", "${workspaceRoot}/schemas/ocpp20", "-o", "${workspaceRoot}/out", "-t", "${workspaceRoot}/tools/json2cpp/templates", "-v", "ocpp20"]
}
]
}
25 changes: 20 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

cmake_minimum_required(VERSION 3.13)

project(OpenOCPP DESCRIPTION "Open Source C++ implementation of the OCPP 1.6 protocol"
VERSION 1.5.8
project(OpenOCPP DESCRIPTION "Open Source C++ implementation of the OCPP 1.6 and 2.0.1 protocols"
VERSION 2.0.0
)

# Definitions for Version.h file
Expand Down Expand Up @@ -72,9 +72,15 @@ if(${BUILD_STATIC_LIBRARY})
centralsystem
chargepoint
localcontroller
centralsystem20
chargepoint20
localcontroller20
config
database
messages
messages16
messages20
types20
rpc
helpers
log
Expand All @@ -96,9 +102,15 @@ if (${BUILD_SHARED_LIBRARY})
centralsystem
chargepoint
localcontroller
centralsystem20
chargepoint20
localcontroller20
config
database
messages
messages16
messages20
types20
rpc
helpers
log
Expand All @@ -121,16 +133,19 @@ include(GNUInstallDirs)

file(GLOB_RECURSE PUBLIC_HEADERS
LIST_DIRECTORIES false RELATIVE ${CMAKE_SOURCE_DIR} "${CMAKE_SOURCE_DIR}/src/*.h")
file(GLOB OCPP_SCHEMAS
LIST_DIRECTORIES false RELATIVE ${CMAKE_SOURCE_DIR} "${CMAKE_SOURCE_DIR}/schemas/*.json")
file(GLOB OCPP16_SCHEMAS
LIST_DIRECTORIES false RELATIVE ${CMAKE_SOURCE_DIR} "${CMAKE_SOURCE_DIR}/schemas/ocpp16/*.json")
file(GLOB OCPP20_SCHEMAS
LIST_DIRECTORIES false RELATIVE ${CMAKE_SOURCE_DIR} "${CMAKE_SOURCE_DIR}/schemas/ocpp20/*.json")

install(TARGETS ${OPEN_OCPP_SHARED_TARGET} ${OPEN_OCPP_STATIC_TARGET}
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
)
install(FILES ${PUBLIC_HEADERS} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/openocpp)
install(FILES ${OCPP_SCHEMAS} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/openocpp/schemas)
install(FILES ${OCPP16_SCHEMAS} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/openocpp/schemas/ocpp16)
install(FILES ${OCPP20_SCHEMAS} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/openocpp/schemas/ocpp20)

if(${INSTALL_RAPID_JSON})
file(GLOB RAPIDJSON_HEADERS
Expand Down
Loading
Loading