Console Output (Options --pe,--ppe): Wrong transitions
cepsdev opened this issue · 1 comments
cepsdev commented
kind Event;
kind Guard;
kind Systemstate;
Guard CP_StateA;
Guard CP_StateB;
Guard CP_StateC;
Guard CP_StateD;
Guard CP_OutOfBounds_StateB;
Guard CP_OutOfBounds_StateC;
Guard CP_OutOfBounds_StateD;
Guard CPVoltageInBoundsForCurrentState;
Guard TooManyPeaksInARow;
Guard PeakdelayIntervalElapsed;
Guard NoPeakDetected;
Guard PeakDetected;
Event ReadValuesFromChargingBus;
Event PeakDetectionCompleted;
Systemstate current_cp_voltage;
Systemstate peak_counter;
Systemstate max_peaks_in_a_row;
Systemstate peakdelay_interval;
current_cp_voltage = 0.0;
peak_counter = 0;
max_peaks_in_a_row = 8;
peakdelay_interval = 10;
sm{
evse;
sm{
secc;
sm{
secc_serial;
sm{
peak_detect;
states{Initial;CheckPeakCondition;NoPeak;Peak;Plateau;};
t{Initial;CheckPeakCondition;};
t{CheckPeakCondition;Peak;CP_OutOfBounds_StateB;};
t{CheckPeakCondition;Peak;CP_OutOfBounds_StateC;};
t{CheckPeakCondition;Peak;CP_OutOfBounds_StateD;};
t{CheckPeakCondition;NoPeak;CPVoltageInBoundsForCurrentState;};
t{Peak;CheckPeakCondition;ReadValuesFromChargingBus;};
t{NoPeak;CheckPeakCondition;ReadValuesFromChargingBus;};
t{Peak;Plateau;TooManyPeaksInARow;};
t{Plateau;CheckPeakCondition;ReadValuesFromChargingBus;PeakdelayIntervalElapsed;};
};
sm{
analyzePhysicalValues;
states{Initial;
WaitForNewValuesFromChargingBus;
WaitForPeakDetection;
DoComputationsBasedOnCPVoltage;
AnalyzeBCPToggle;};
t{Initial;WaitForNewValuesFromChargingBus;};
t{WaitForNewValuesFromChargingBus;WaitForPeakDetection;ReadValuesFromChargingBus;};
t{WaitForPeakDetection;DoComputationsBasedOnCPVoltage;PeakDetectionCompleted;NoPeakDetected;};
t{WaitForPeakDetection;AnalyzeBCPToggle;PeakDetectionCompleted;PeakDetected;};
t{DoComputationsBasedOnCPVoltage;AnalyzeBCPToggle;};
t{AnalyzeBCPToggle;WaitForNewValuesFromChargingBus;};
};
states{Initial;};
t{Initial;peak_detect;};
t{Initial;analyzePhysicalValues;};
};
states{Initial;};
t{Initial;secc_serial;};
};
sm{
low_level_charging_bus;
states{Initial;};
sm{
ControlPilot;
states{Initial;A;B;C;D;};
t{Initial;A;};
};
sm{
ProximityPilot;
states{Initial;Connected;Disconnected;};
};
t{Initial;ControlPilot;};
t{Initial;ProximityPilot;};
};
states{Initial;};
t{Initial;low_level_charging_bus;};
t{Initial;secc;};
};
Produces the output:
State Machine evse:
States:
Initial
Transitions:
Initial --▶ low_level_charging_bus
Initial --▶ secc
State Machine secc:
States:
Initial
Transitions:
A --▶
State Machine secc_serial:
States:
Initial
Transitions:
Plateau --▶
CheckPeakCondition --▶
State Machine peak_detect:
States:
Initial, CheckPeakCondition, NoPeak, Peak, Plateau
Transitions:
--▶ Initial
Peak -[PeakDetectionCompleted]-▶ analyzePhysicalValues
Initial -[ReadValuesFromChargingBus]-▶ WaitForNewValuesFromChargingBus
DoComputationsBasedOnCPVoltage -[CP_OutOfBounds_StateB]-▶ CheckPeakCondition
-[CP_OutOfBounds_StateC]-▶ Plateau
Initial -CP_OutOfBounds_StateD-▶ CheckPeakCondition
-CPVoltageInBoundsForCurrentState-▶
CheckPeakCondition -[ReadValuesFromChargingBus]-▶ Peak
CheckPeakCondition -PeakDetectionCompleted[NoPeakDetected]-▶ Peak
State Machine analyzePhysicalValues:
States:
Initial, WaitForNewValuesFromChargingBus, WaitForPeakDetection, DoComputationsBasedOnCPVoltage, AnalyzeBCPToggle
Transitions:
--▶ NoPeak
Peak -ReadValuesFromChargingBus-▶
Peak -CPVoltageInBoundsForCurrentState[CP_OutOfBounds_StateD]-▶
-CP_OutOfBounds_StateC[CP_OutOfBounds_StateB]-▶ Plateau
Initial --▶ CheckPeakCondition
CheckPeakCondition --▶ Peak
State Machine low_level_charging_bus:
States:
Initial
Transitions:
Initial --▶ ControlPilot
Initial --▶ ProximityPilot
State Machine ControlPilot:
States:
Initial, A, B, C, D
Transitions:
--▶ Initial
State Machine ProximityPilot:
States:
Initial, Connected, Disconnected
Almost all transitions are wrong