Skip to content

Commit

Permalink
Add Method ReaddatasetValue
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidDKo committed Oct 27, 2023
1 parent 9a4f8cf commit 04cedf8
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions src/Blocks/Drives/classReadDriveParams.st
Original file line number Diff line number Diff line change
Expand Up @@ -468,5 +468,33 @@ NAMESPACE Simatic.Ax.LAcycCom

End_Method

Method public ReaddatasetValue : real
VAR_INPUT
element_no : int := int#0;
end_VAR
VAR_TEMP
tempLoopIndex : Int;
end_VAR

If element_no >= 0 and element_no <= typeconstantsint#LACYCCOM_READ_PARAMETERS_UPPER_LIM Then
ReaddatasetValue := dataset[element_no].value;
end_if;

End_Method

Method public ReaddatasetDWValue : DWORD
VAR_INPUT
element_no : int := int#0;
end_VAR
VAR_TEMP
tempLoopIndex : Int;
end_VAR

If element_no >= 0 and element_no <= typeconstantsint#LACYCCOM_READ_PARAMETERS_UPPER_LIM Then
ReaddatasetDWValue := dataset[element_no].DWvalue;
end_if;

End_Method

END_CLASS
END_NAMESPACE

0 comments on commit 04cedf8

Please sign in to comment.