diff --git a/BaseComponents.tsproj b/BaseComponents.tsproj index fbb86b1..b80a879 100644 --- a/BaseComponents.tsproj +++ b/BaseComponents.tsproj @@ -136,7 +136,7 @@ - + BasicComponents Instance {08500001-0000-0000-F000-000000000064} diff --git a/BasicComponents.library b/BasicComponents.library index 322d4da..fcde18e 100644 Binary files a/BasicComponents.library and b/BasicComponents.library differ diff --git a/BasicComponents/BasicComponents.plcproj b/BasicComponents/BasicComponents.plcproj index b1aa1ab..964e427 100644 --- a/BasicComponents/BasicComponents.plcproj +++ b/BasicComponents/BasicComponents.plcproj @@ -21,7 +21,7 @@ false Heisig GmbH BaseComponents - 1.3.2 + 1.3.3 BC M.Heisig Basic components fb's (Valves, AI, AO, Motors, etc.) @@ -112,6 +112,9 @@ Code + + Code + Code @@ -301,8 +304,8 @@ - - + + "<ProjectRoot>" {192FAD59-8248-4824-A8DE-9177C94C195A} @@ -2683,16 +2686,16 @@ - - - System.Boolean - System.Collections.Hashtable - System.Int32 - {54dd0eac-a6d8-46f2-8c27-2f43c7e49861} - System.String - System.UInt32 - - + + + System.Boolean + System.Collections.Hashtable + System.Int32 + {54dd0eac-a6d8-46f2-8c27-2f43c7e49861} + System.String + System.UInt32 + + \ No newline at end of file diff --git a/BasicComponents/POUs/Components/Controller/FB_PI.TcPOU b/BasicComponents/POUs/Components/Controller/FB_PI.TcPOU index 27c711f..68589e5 100644 --- a/BasicComponents/POUs/Components/Controller/FB_PI.TcPOU +++ b/BasicComponents/POUs/Components/Controller/FB_PI.TcPOU @@ -33,7 +33,7 @@ END_VAR _xFirstCycle := FALSE; // Get current task time - _rT := LREAL_TO_REAL(UDINT_TO_LREAL(_TaskInfo[GETCURTASKINDEXEX()].CycleTime) * 1E-7); + _rT := F_GetTaskCycleTime(); END_IF diff --git a/BasicComponents/POUs/Components/Controller/FB_PID.TcPOU b/BasicComponents/POUs/Components/Controller/FB_PID.TcPOU index beb1782..a8d8682 100644 --- a/BasicComponents/POUs/Components/Controller/FB_PID.TcPOU +++ b/BasicComponents/POUs/Components/Controller/FB_PID.TcPOU @@ -39,7 +39,7 @@ END_VAR _xFirstCycle := FALSE; // Get current task time - _rT := LREAL_TO_REAL(UDINT_TO_LREAL(_TaskInfo[GETCURTASKINDEXEX()].CycleTime) * 1E-7); + _rT := F_GetTaskCycleTime(); _rPVLast := rPV; END_IF diff --git a/BasicComponents/POUs/Components/Controller/FB_RampGenerator.TcPOU b/BasicComponents/POUs/Components/Controller/FB_RampGenerator.TcPOU index 6a05817..7c87943 100644 --- a/BasicComponents/POUs/Components/Controller/FB_RampGenerator.TcPOU +++ b/BasicComponents/POUs/Components/Controller/FB_RampGenerator.TcPOU @@ -27,7 +27,7 @@ END_VAR]]> _xFirstCycle := FALSE; // Get cycle time - _rT := LREAL_TO_REAL(UDINT_TO_LREAL(_TaskInfo[GETCURTASKINDEXEX()].CycleTime) * 1E-7); + _rT := F_GetTaskCycleTime(); END_IF // If not enabled output equals input diff --git a/BasicComponents/POUs/Components/Utilities/F_GetTaskCycleTime.TcPOU b/BasicComponents/POUs/Components/Utilities/F_GetTaskCycleTime.TcPOU new file mode 100644 index 0000000..86e9d1e --- /dev/null +++ b/BasicComponents/POUs/Components/Utilities/F_GetTaskCycleTime.TcPOU @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file