diff --git a/iso15118/secc/controller/interface.py b/iso15118/secc/controller/interface.py index 3d7f2074..3a710005 100644 --- a/iso15118/secc/controller/interface.py +++ b/iso15118/secc/controller/interface.py @@ -1057,6 +1057,13 @@ async def session_ended(self, current_state: str, reason: str): """ raise NotImplementedError + @abstractmethod + async def send_display_params(self): + """ + Share display params with CS. + """ + raise NotImplementedError + @abstractmethod async def send_rated_limits(self): """ diff --git a/iso15118/secc/controller/simulator.py b/iso15118/secc/controller/simulator.py index 1b59ad9f..6bbc1c7f 100644 --- a/iso15118/secc/controller/simulator.py +++ b/iso15118/secc/controller/simulator.py @@ -1091,6 +1091,12 @@ async def session_ended(self, current_state: str, reason: str): """ logger.info(f"Session ended in {current_state} ({reason}).") + async def send_display_params(self): + """ + Share display params with CS. + """ + logger.info("Send display params to CS.") + async def send_rated_limits(self): """ Overrides EVSEControllerInterface.send_rated_limits diff --git a/iso15118/secc/states/din_spec_states.py b/iso15118/secc/states/din_spec_states.py index d623be89..5c518b91 100644 --- a/iso15118/secc/states/din_spec_states.py +++ b/iso15118/secc/states/din_spec_states.py @@ -840,7 +840,7 @@ async def process_message( await self.comm_session.evse_controller.get_evse_max_power_limit() ), ) - + await self.comm_session.evse_controller.send_display_params() self.create_next_message( None, current_demand_res, diff --git a/iso15118/secc/states/iso15118_20_states.py b/iso15118/secc/states/iso15118_20_states.py index 90949d58..a354451f 100644 --- a/iso15118/secc/states/iso15118_20_states.py +++ b/iso15118/secc/states/iso15118_20_states.py @@ -1474,7 +1474,7 @@ async def process_message( ), meter_info=meter_info, ) - + await self.comm_session.evse_controller.send_display_params() self.create_next_message( None, ac_charge_loop_res, @@ -1800,7 +1800,7 @@ async def process_message( ResponseCode.FAILED, ) return - + await self.comm_session.evse_controller.send_display_params() dc_charge_loop_res = await self._build_dc_charge_loop_res( dc_charge_loop_req.meter_info_requested ) diff --git a/iso15118/secc/states/iso15118_2_states.py b/iso15118/secc/states/iso15118_2_states.py index 6f1c35b0..5a0cae7a 100644 --- a/iso15118/secc/states/iso15118_2_states.py +++ b/iso15118/secc/states/iso15118_2_states.py @@ -2445,6 +2445,8 @@ async def process_message( ) return + await self.comm_session.evse_controller.send_display_params() + # We don't care about signed meter values from the EVCC, but if you # do, then set receipt_required to True and set the field meter_info evse_controller = self.comm_session.evse_controller diff --git a/tests/shared/messages/test_interface.py b/tests/shared/messages/test_interface.py index 3db25c60..ecddb00b 100644 --- a/tests/shared/messages/test_interface.py +++ b/tests/shared/messages/test_interface.py @@ -140,6 +140,9 @@ def ready_to_charge(self): async def session_ended(self, _): pass + async def send_display_params(self): + pass + async def send_rated_limits(self): pass