Some refactoring after static code analysis
This commit is contained in:
@@ -14,7 +14,13 @@ VAR
|
||||
END_VAR
|
||||
]]></Declaration>
|
||||
<Implementation>
|
||||
<ST><![CDATA[_tonTimer(IN := TRUE, PT := timPeriod);
|
||||
<ST><![CDATA[// Check for possible division by zero
|
||||
IF TIME_TO_REAL(timPeriod) = 0 THEN
|
||||
xOutput := FALSE;
|
||||
RETURN;
|
||||
END_IF
|
||||
|
||||
_tonTimer(IN := TRUE, PT := timPeriod);
|
||||
IF _tonTimer.Q THEN
|
||||
_tonTimer(IN := FALSE);
|
||||
END_IF
|
||||
|
||||
Reference in New Issue
Block a user