variables
{
int AutoFill_body = 0; // Used to re-enable the autofill after sending a message
}
on fct_called EVSE.OnLastReceivedMessageIdChanged
{
@Common::LastReceivedMessageId = $EVSE.OnLastReceivedMessageIdChanged.LatestCall.lastRxMessageId;
// Enable AutoBodyFill if it was previously disabled at the Req/Resp loop
if (AutoFill_body == 0)
{
EVSE.EnableAutoBodyFill.Call(1);
AutoFill_body = 1;
}
}
on value_change EVSE.ISO20.ServiceDetail_Request
{
if(IsEVSERolePassive())
return;
FUNC_Set_ServiceDetailRes();
}
void FUNC_Set_ServiceDetailRes()
{
// Selection of ServiceID (e.g. DC_BPT)
if ($EVSE.ISO20.ServiceDetail_Request.ServiceID == 6)
{
// Disable AutoBodyFill for manual definition of the parameter set
if (AutoFill_body == 1)
{
EVSE.EnableAutoBodyFill.Call(0);
AutoFill_body = 0;
}
// Definition of required service ID (shall be equal to the if query)
$EVSE.ISO20.ServiceDetail_Response.ServiceID = $EVSE.ISO20.ServiceDetail_Request.ServiceID;
_ServiceDetail_PrepareResponseContent_DC_BPT_List();
}
}