NC config per lettura assi (per ora 0 da core_library)

This commit is contained in:
Samuele Locatelli
2020-09-23 19:04:16 +02:00
parent ec9e23071f
commit 147b84ab19
2 changed files with 93 additions and 93 deletions
+8 -1
View File
@@ -29,6 +29,7 @@ using static Thermo.Active.Utils.ExceptionManager;
public static class ThreadsFunctions
{
public static int axisRtCounter = 0;
public static int recipeRtCounter = 0;
public static int modulesRtCounter = 0;
public static bool reconnectionIsRunning = false;
@@ -498,12 +499,18 @@ public static class ThreadsFunctions
while (true)
{
// ogni n counter leggo anche dati NON RT
axisRtCounter--;
bool onlyRt = axisRtCounter > 0;
//check reset...
axisRtCounter = axisRtCounter < 0 ? 4 : axisRtCounter;
sw.Restart();
if (ncAdapter.numericalControl.NC_IsConnected())
{
// Get Data from config and PLC
libraryError = ncAdapter.ReadAxisData(out Dictionary<int,DTOAxisInfoModel> axisData);
libraryError = ncAdapter.ReadAxisData(onlyRt, out Dictionary<int, DTOAxisInfoModel> axisData);
if (libraryError.errorCode != 0)
ManageLibraryError(libraryError);
else