Skip to content
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

Move firmware update to new functional block #952

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

maaikez
Copy link
Contributor

@maaikez maaikez commented Jan 21, 2025

Describe your changes

Move firmware update functions to a functional block

Issue ticket number and link

#951

Checklist before requesting a review

  • I have performed a self-review of my code
  • [n/a] I have made corresponding changes to the documentation
  • [n/a] If OCPP 2.0.1: I have updated the OCPP 2.0.1 status document
  • I read the contribution documentation and made sure that my changes meet its requirements

@maaikez maaikez force-pushed the feature/move-availability-callbacks-and-handlers-to-new-functional-block branch from bce747f to 98360d6 Compare January 23, 2025 16:36
Base automatically changed from feature/move-availability-callbacks-and-handlers-to-new-functional-block to main January 24, 2025 13:33
@maaikez maaikez force-pushed the feature/move-firmware-update-to-new-functional-block branch from 283d4b8 to be09ba7 Compare January 24, 2025 13:53
@maaikez maaikez linked an issue Jan 24, 2025 that may be closed by this pull request
@maaikez maaikez force-pushed the feature/move-firmware-update-to-new-functional-block branch from be09ba7 to 4d3736a Compare January 29, 2025 16:50
@Pietfried Pietfried self-assigned this Jan 30, 2025
Comment on lines 6 to 8
#include <ocpp/v201/message_handler.hpp>

#include <ocpp/common/message_dispatcher.hpp>

#include <ocpp/v201/messages/UpdateFirmware.hpp>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
#include <ocpp/v201/message_handler.hpp>
#include <ocpp/common/message_dispatcher.hpp>
#include <ocpp/v201/messages/UpdateFirmware.hpp>
#include <ocpp/common/message_dispatcher.hpp>
#include <ocpp/v201/message_handler.hpp>
#include <ocpp/v201/messages/UpdateFirmware.hpp>

this->device_model.get_value<std::string>(ControllerComponentVariables::FirmwareVersion));
this->security.security_event_notification_req(CiString<50>(ocpp::security_events::FIRMWARE_UPDATED),
std::optional<CiString<255>>(firmwareVersionMessage), true,
true); // L01.FR.31
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we need to call this->restore_all_connector_states(); here as well, otherwise evses may stay in unavailable after a successful install. Could you please double check?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well it was not there, so I am not sure if it should be there. But it seems logical to me.

Asked @RobertDeLeeuw about it, as he added the call to this function.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Talked with @hikinggrass that we probably just want this to be called when a firmware update end state is reached. Added code for that.

@maaikez maaikez force-pushed the feature/move-firmware-update-to-new-functional-block branch 2 times, most recently from 07f505d to feb8b18 Compare February 3, 2025 14:50
Signed-off-by: Maaike Zijderveld, iolar <git.mail@iolar.nl>
…ity and security. Make it compile.

Signed-off-by: Maaike Zijderveld, iolar <git.mail@iolar.nl>
Signed-off-by: Maaike Zijderveld, iolar <git.mail@iolar.nl>
Signed-off-by: Maaike Zijderveld, iolar <git.mail@iolar.nl>
Signed-off-by: Maaike Zijderveld, iolar <git.mail@iolar.nl>
@maaikez maaikez force-pushed the feature/move-firmware-update-to-new-functional-block branch from feb8b18 to ad072e3 Compare February 3, 2025 16:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Move 'Firmware Update' handlers and callbacks to functional block
2 participants