Added precharging to SafetyCheck
This commit is contained in:
@@ -510,7 +510,11 @@ CASE _iState OF
|
||||
IF xEnable AND (NOT xStartBalancing) AND xAllModulesInAutoMode AND xRepairSwitchOk THEN
|
||||
_xEnable := TRUE;
|
||||
eStatus := E_COMPONENT_STATUS.STARTING;
|
||||
_iState := 5;
|
||||
IF xInSafetyCheckMode THEN
|
||||
_iState := 1;
|
||||
ELSE
|
||||
_iState := 5;
|
||||
END_IF
|
||||
END_IF
|
||||
|
||||
// Start in balancing mode
|
||||
@@ -521,6 +525,13 @@ CASE _iState OF
|
||||
_iState := 7;
|
||||
END_IF
|
||||
|
||||
1: // Wait for ready in safety check mode
|
||||
IF _xAllModulesReady THEN
|
||||
xResetSafetyDCCB := TRUE;
|
||||
_tonResetPulseLength.IN := TRUE;
|
||||
_iState := 10;
|
||||
END_IF
|
||||
|
||||
5: // Wait for all modules to be ready in normal mode
|
||||
IF _xAllModulesReady AND _xBalanceOk THEN
|
||||
xResetSafetyDCCB := TRUE;
|
||||
@@ -596,7 +607,11 @@ CASE _iState OF
|
||||
_xEnableInverter := TRUE;
|
||||
_rPowerInverterInternal := rPowerInverter;
|
||||
//_rPowerInverterInternal := 0.0;
|
||||
_iState := 21;
|
||||
IF xInSafetyCheckMode THEN
|
||||
_iState := 29;
|
||||
ELSE
|
||||
_iState := 21;
|
||||
END_IF
|
||||
END_IF
|
||||
IF _tonErrorDCCBNotClosed.Q THEN
|
||||
_xEnable := FALSE;
|
||||
@@ -648,6 +663,14 @@ CASE _iState OF
|
||||
_xEnable := FALSE;
|
||||
_tonInverterStartupTimeout(IN := FALSE);
|
||||
END_IF
|
||||
|
||||
29: // Ready in safety check mode
|
||||
IF (NOT xEnable) THEN
|
||||
_xEnable := FALSE;
|
||||
_xReleaseLimitErrorsInternal := FALSE;
|
||||
eStatus := E_COMPONENT_STATUS.SHUTDOWN;
|
||||
_iState := 31;
|
||||
END_IF
|
||||
|
||||
30: // All modules ready
|
||||
// !!! ATTENTION !!!
|
||||
|
||||
Reference in New Issue
Block a user