-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Add device-energy-management cluster example app code for 1.4 #33910
Add device-energy-management cluster example app code for 1.4 #33910
Conversation
PR #33910: Size comparison from 4a16aaa to c683503 Increases above 0.2%:
Full report (65 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, mbed, nxp, psoc6, qpg, stm32, tizen)
|
src/app/clusters/device-energy-management-server/device-energy-management-server.h
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some initial review comments on the easier ones
examples/energy-management-app/energy-management-common/include/DEMManufacturerDelegate.h
Outdated
Show resolved
Hide resolved
.../energy-management-app/energy-management-common/include/DeviceEnergyManagementDelegateImpl.h
Outdated
Show resolved
Hide resolved
examples/energy-management-app/energy-management-common/include/DEMManufacturerDelegate.h
Outdated
Show resolved
Hide resolved
examples/energy-management-app/energy-management-common/src/DEMUtils.cpp
Outdated
Show resolved
Hide resolved
examples/energy-management-app/energy-management-common/src/DEMUtils.cpp
Outdated
Show resolved
Hide resolved
examples/energy-management-app/energy-management-common/src/DEMUtils.cpp
Outdated
Show resolved
Hide resolved
examples/energy-management-app/energy-management-common/src/DEMUtils.cpp
Outdated
Show resolved
Hide resolved
examples/energy-management-app/energy-management-common/src/DEMUtils.cpp
Outdated
Show resolved
Hide resolved
examples/energy-management-app/energy-management-common/src/DEMUtils.cpp
Outdated
Show resolved
Hide resolved
examples/energy-management-app/energy-management-common/src/DEMUtils.cpp
Outdated
Show resolved
Hide resolved
examples/energy-management-app/energy-management-common/src/DEMUtils.cpp
Outdated
Show resolved
Hide resolved
PR #33910: Size comparison from 4a16aaa to 3cb089f Increases above 0.2%:
Full report (8 builds for cc32xx, mbed, qpg, stm32, tizen)
|
PR #33910: Size comparison from 4a16aaa to 6688c42 Increases above 0.2%:
Full report (96 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, mbed, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
PR #33910: Size comparison from 4a16aaa to e9c2f5f Full report (28 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, efr32, mbed, nxp, qpg, stm32)
|
PR #33910: Size comparison from 667cae8 to a45e6dd Full report (25 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, mbed, nxp, qpg, stm32)
|
PR #33910: Size comparison from 667cae8 to fe103a9 Increases above 0.2%:
Full report (96 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, mbed, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
… the EVSE_Add_Get_Set_Clear_Targets_Support branch
PR #33910: Size comparison from 3bc5667 to 932c0c3 Increases above 0.2%:
Full report (96 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, mbed, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
…e variable lengths of time to run
PR #33910: Size comparison from 3bc5667 to 48014ef Increases above 0.2%:
Full report (8 builds for cc32xx, mbed, qpg, stm32, tizen)
|
...es/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp
Show resolved
Hide resolved
...es/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp
Outdated
Show resolved
Hide resolved
...es/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp
Outdated
Show resolved
Hide resolved
...es/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp
Outdated
Show resolved
Hide resolved
examples/energy-management-app/energy-management-common/src/EnergyTimeUtils.cpp
Outdated
Show resolved
Hide resolved
…viceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]>
…ergyTimeUtils.cpp Co-authored-by: Boris Zbarsky <[email protected]>
…viceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove DEMTESTBase.py since it is renamed in the other DEM TESTs PR and isn't needed here.
PR #33910: Size comparison from c91a779 to a955ceb Full report (3 builds for cc32xx, stm32)
|
PR #33910: Size comparison from c91a779 to 07ed1fa Increases above 0.2%:
Full report (96 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, mbed, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
PR #33910: Size comparison from ba949bf to eecd532 Increases above 0.2%:
Full report (96 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, mbed, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
…t-chip#33910) * Get the EVSE app building and test TC_DEM_2_2 passing * Get all targets building * Address JamesH review comments * Rename utils.cpp to DEMUtils.cpp * Address JamesH review comments * Restyled by whitespace * Restyled by clang-format * Restyled by gn * Restyled by prettier-markdown * Restyled by autopep8 * Restyled by isort * Fix compilation problem by including lib/core/DataModelTypes.h * Fix compilation problem by including * Save examples/all-clusters-app/all-clusters-common/all-clusters-app.zap to update it * Restyled by clang-format * Apply further code review changes * Restyled by clang-format * Restyled by gn * Address code review comments from AndreiL * Restyled by whitespace * Restyled by clang-format * Fix ESP build * Fix ESP build * Restyled by clang-format * Rename src/python_testing/TC_DEM_Utils.py src/python_testing/DEMTestBase.py * Put time util funtions into namespace + drop the Utils prefix * Restyled by whitespace * Restyled by isort * Try to address setForecast comments from Boris * Remove unnecessary SetXXX methods from the device energy management cluster interface * Restyled by clang-format * Apply code review changes suggested by Louis-Philip Beliveau * Document the API for GetForecast and GetPowerAdjustmentCapability * Document the GetForecast and GetPowerAdjustmentCapability APIs * Update src/app/clusters/device-energy-management-server/device-energy-management-server.h Co-authored-by: Boris Zbarsky <[email protected]> * Update src/app/clusters/device-energy-management-server/device-energy-management-server.h Co-authored-by: Boris Zbarsky <[email protected]> * Address review comments from Boris * Sync up with code review comments from PR34234 * Sync up with code review comments from PR34234 that caused some return codes to change * Restyled by clang-format * modifyForecastRequest: Failure should be returned if a slot number > num slots in a forecast * Update examples/energy-management-app/energy-management-common/include/DeviceEnergyManagementDelegateImpl.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/include/DeviceEnergyManagementManager.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/include/EVSECallbacks.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/include/EVSEManufacturerImpl.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/include/EnergyEvseDelegateImpl.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DEMTestEventTriggers.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/include/EnergyEvseManager.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DEMTestEventTriggers.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DEMTestEventTriggers.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Address review comments from Boris * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Address further review comments from Boris * Address further review comments from Boris * Address further review comments from Boris * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementManager.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Address further review comments from Boris * Update examples/energy-management-app/energy-management-common/src/DEMTestEventTriggers.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/EnergyTimeUtils.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Apply further review comments from Boris * Used a bitmap rather than uint8_t and sync EnergyTimeUtils files from the EVSE_Add_Get_Set_Clear_Targets_Support branch * Update following review comments from Boris * Allow more time for forecast.startTime in test setup as tests can take variable lengths of time to run * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/EnergyTimeUtils.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Addressing further review comments from Boris * Fix small issue found as a result of the DEM test script review * Protect against forecast being null * Remove src/python_testing/DEMTestBase.py as renamed in PR34234 * Update following review comment from Andrei * Restyled by clang-format --------- Co-authored-by: Restyled.io <[email protected]> Co-authored-by: Boris Zbarsky <[email protected]>
…t-chip#33910) * Get the EVSE app building and test TC_DEM_2_2 passing * Get all targets building * Address JamesH review comments * Rename utils.cpp to DEMUtils.cpp * Address JamesH review comments * Restyled by whitespace * Restyled by clang-format * Restyled by gn * Restyled by prettier-markdown * Restyled by autopep8 * Restyled by isort * Fix compilation problem by including lib/core/DataModelTypes.h * Fix compilation problem by including * Save examples/all-clusters-app/all-clusters-common/all-clusters-app.zap to update it * Restyled by clang-format * Apply further code review changes * Restyled by clang-format * Restyled by gn * Address code review comments from AndreiL * Restyled by whitespace * Restyled by clang-format * Fix ESP build * Fix ESP build * Restyled by clang-format * Rename src/python_testing/TC_DEM_Utils.py src/python_testing/DEMTestBase.py * Put time util funtions into namespace + drop the Utils prefix * Restyled by whitespace * Restyled by isort * Try to address setForecast comments from Boris * Remove unnecessary SetXXX methods from the device energy management cluster interface * Restyled by clang-format * Apply code review changes suggested by Louis-Philip Beliveau * Document the API for GetForecast and GetPowerAdjustmentCapability * Document the GetForecast and GetPowerAdjustmentCapability APIs * Update src/app/clusters/device-energy-management-server/device-energy-management-server.h Co-authored-by: Boris Zbarsky <[email protected]> * Update src/app/clusters/device-energy-management-server/device-energy-management-server.h Co-authored-by: Boris Zbarsky <[email protected]> * Address review comments from Boris * Sync up with code review comments from PR34234 * Sync up with code review comments from PR34234 that caused some return codes to change * Restyled by clang-format * modifyForecastRequest: Failure should be returned if a slot number > num slots in a forecast * Update examples/energy-management-app/energy-management-common/include/DeviceEnergyManagementDelegateImpl.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/include/DeviceEnergyManagementManager.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/include/EVSECallbacks.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/include/EVSEManufacturerImpl.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/include/EnergyEvseDelegateImpl.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DEMTestEventTriggers.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/include/EnergyEvseManager.h Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DEMTestEventTriggers.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DEMTestEventTriggers.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Address review comments from Boris * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Address further review comments from Boris * Address further review comments from Boris * Address further review comments from Boris * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementManager.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Address further review comments from Boris * Update examples/energy-management-app/energy-management-common/src/DEMTestEventTriggers.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/EnergyTimeUtils.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Apply further review comments from Boris * Used a bitmap rather than uint8_t and sync EnergyTimeUtils files from the EVSE_Add_Get_Set_Clear_Targets_Support branch * Update following review comments from Boris * Allow more time for forecast.startTime in test setup as tests can take variable lengths of time to run * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/EnergyTimeUtils.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Update examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp Co-authored-by: Boris Zbarsky <[email protected]> * Addressing further review comments from Boris * Fix small issue found as a result of the DEM test script review * Protect against forecast being null * Remove src/python_testing/DEMTestBase.py as renamed in PR34234 * Update following review comment from Andrei * Restyled by clang-format --------- Co-authored-by: Restyled.io <[email protected]> Co-authored-by: Boris Zbarsky <[email protected]>
Add device-energy-management cluster example app code based on latest cluster spec. One Python test case has been included (more will come in separate PRs - please see #34234).
This is the second of several pull-requests that implement and test the DEM cluster in Matter 1.4.
Note DEM did not make Matter 1.3 SVE and is only provisional.
The spec can be found at: https://github.com/CHIP-Specifications/connectedhomeip-spec/blob/master/src/app_clusters/DeviceEnergyManagement.adoc.
The test spec can be found at: https://github.com/CHIP-Specifications/chip-test-plans/blob/48027890ec720f3eb00890448119d0979cbb1e4b/src/cluster/device_energy_management.adoc
Partially resolves some of the TODOs in #31147