Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
sjuergen committed Oct 18, 2024
1 parent 0d587c2 commit 5a152c6
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 8 deletions.
2 changes: 0 additions & 2 deletions src/Actuator/TimeBasedActuator.st
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@ NAMESPACE Simatic.Ax.axftcmlib
IF (Q_ToWorkPosition = NULL) THEN
THIS.SetError(WORD#16#8101);
RETURN;
ELSE
THIS.SetError(FALSE);
END_IF;
_tonOnDuration(signal := Q_ToWorkPosition.IsOn(), Duration := OnDuration);
CASE _state OF
Expand Down
2 changes: 0 additions & 2 deletions src/Actuator/TwoWayActuator.st
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ NAMESPACE Simatic.Ax.axftcmlib
IF (Q_ToWorkPosition = NULL) THEN
THIS.SetError(WORD#16#8101);
RETURN;
ELSE
THIS.SetError(FALSE);
END_IF;
CASE _state OF
// Switch all outputs off, when actuator is idle in home position
Expand Down
5 changes: 1 addition & 4 deletions test/TwoWayActuatorTest.st
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,7 @@ NAMESPACE Simatic.Ax.axftcmlib
busy := cmd.Busy();
IF NOT(busy) THEN
done := cmd.Done();
ELSE
busy := TRUE;
END_IF;
busy := TRUE;
END_IF;
AxUnit.Assert.Equal(expected := TRUE, actual := busy);
AxUnit.Assert.Equal(expected := FALSE, actual := done);
AxUnit.Assert.Equal(expected := TRUE, actual := _qToWork.IsOn());
Expand Down

0 comments on commit 5a152c6

Please sign in to comment.