diff --git a/CVCncLib/testSam.dll b/CVCncLib/testSam.dll
index 039856f6..daf0039d 100644
Binary files a/CVCncLib/testSam.dll and b/CVCncLib/testSam.dll differ
diff --git a/IOB-WIN/IobFanuc.cs b/IOB-WIN/IobFanuc.cs
index 93c9fb15..5c65e0df 100644
--- a/IOB-WIN/IobFanuc.cs
+++ b/IOB-WIN/IobFanuc.cs
@@ -1,6 +1,4 @@
-using CncLib.CNC;
-using IOB_UT;
-using System;
+using System;
using System.Collections.Generic;
using System.Net;
using System.Net.NetworkInformation;
@@ -275,8 +273,11 @@ namespace IOB_WIN
answ.Add(item.Key, "RESET: SETUP START");
break;
case "stopSetup":
- // reset contapezzi fine setup
- resetContapezziCNC();
+ // reset contapezzi fine setup SE ESPLICITAMENTE IMPOSTATO
+ if (cIobConf.optPar.Count > 0 && getOptPar("ENABLE_PZ_RESET_stopSetup") == "TRUE")
+ {
+ resetContapezziCNC();
+ }
answ.Add(item.Key, "RESET: SETUP END");
break;
default:
@@ -989,7 +990,7 @@ namespace IOB_WIN
}
}
}
- catch(Exception exc)
+ catch (Exception exc)
{
lgError(exc, "Eccezione in processOtherCounters");
}
diff --git a/IOB-WIN/IobGeneric.cs b/IOB-WIN/IobGeneric.cs
index 1adaf792..2629233d 100644
--- a/IOB-WIN/IobGeneric.cs
+++ b/IOB-WIN/IobGeneric.cs
@@ -852,7 +852,7 @@ namespace IOB_WIN
///
public virtual Dictionary executeTasks(Dictionary task2exe)
{
- // Verificare il protocollo: dovrebeb togliere SOLO i task eseguiti...
+ // Verificare il protocollo: dovrebbe togliere SOLO i task eseguiti...
Dictionary taskDone = new Dictionary();
bool taskOk = false;
string taskVal = "";
@@ -870,8 +870,11 @@ namespace IOB_WIN
taskVal = taskOk ? "RESET: SETUP START" : "PZ RESET DISABLED | NO EXEC";
break;
case "stopSetup":
- // reset contapezzi fine setup
- taskOk = resetContapezziCNC();
+ // reset contapezzi fine setup SE ESPLICITAMENTE IMPOSTATO
+ if (cIobConf.optPar.Count > 0 && getOptPar("ENABLE_PZ_RESET_stopSetup") == "TRUE")
+ {
+ taskOk = resetContapezziCNC();
+ }
taskVal = taskOk ? "RESET: SETUP END" : "PZ RESET DISABLED | NO EXEC";
break;
default:
diff --git a/IOB-WIN/IobKawasaki.cs b/IOB-WIN/IobKawasaki.cs
index d692b6c4..910783c1 100644
--- a/IOB-WIN/IobKawasaki.cs
+++ b/IOB-WIN/IobKawasaki.cs
@@ -167,8 +167,10 @@ namespace IOB_WIN
///
public override Dictionary executeTasks(Dictionary task2exe)
{
- // Verificare il protocollo: dovrebeb togliere SOLO i task eseguiti...
- Dictionary answ = new Dictionary();
+ // Verificare il protocollo: dovrebbe togliere SOLO i task eseguiti...
+ Dictionary taskDone = new Dictionary();
+ bool taskOk = false;
+ string taskVal = "";
// cerco task specifici: se ho startSetup --> imposto bit DBB701.DBB0.4
foreach (var item in task2exe)
@@ -178,29 +180,31 @@ namespace IOB_WIN
{
case "forceResetPzCount":
// reset contapezzi inizio setup
- resetContapezziCNC();
- answ.Add(item.Key, "FORCE RESET PZ COUNT");
+ taskOk = resetContapezziCNC();
+ taskVal = taskOk ? "FORCE RESET PZ COUNT" : "FORCE RESET DISABLED | NO EXEC";
break;
case "startSetup":
// reset contapezzi inizio setup
- resetContapezziCNC();
- answ.Add(item.Key, "RESET: SETUP START");
+ taskOk = resetContapezziCNC();
+ taskVal = taskOk ? "RESET: SETUP START" : "PZ RESET DISABLED | NO EXEC";
break;
-#if false
case "stopSetup":
- // reset contapezzi fine setup
- resetContapezziCNC();
- answ.Add(item.Key, "RESET: SETUP END");
+ // reset contapezzi fine setup // reset contapezzi fine setup SE ESPLICITAMENTE IMPOSTATO
+ if (cIobConf.optPar.Count > 0 && getOptPar("ENABLE_PZ_RESET_stopSetup") == "TRUE")
+ {
+ resetContapezziCNC();
+ }
+ taskVal = taskOk ? "RESET: SETUP END" : "PZ RESET DISABLED | NO EXEC";
break;
-#endif
default:
- // anche se non faccio nulla SEGNO con value = NOT DONE
- answ.Add(item.Key, "UNKNOWN KEY | NO EXEC");
+ // anche se non faccio nulla SEGNO con value = SKIPPED
+ taskVal = "SKIPPED | NO EXEC";
break;
}
+ taskDone.Add(item.Key, taskVal);
}
- return answ;
+ return taskDone;
}
///
/// Effettua reset del contapezzi
diff --git a/IOB-WIN/IobSiemensTorri.cs b/IOB-WIN/IobSiemensTorri.cs
index 71352a8c..0c83b33f 100644
--- a/IOB-WIN/IobSiemensTorri.cs
+++ b/IOB-WIN/IobSiemensTorri.cs
@@ -34,30 +34,15 @@ namespace IOB_WIN
public override Dictionary executeTasks(Dictionary task2exe)
{
// Verificare il protocollo: dovrebeb togliere SOLO i task eseguiti...
- Dictionary answ = new Dictionary();
+ Dictionary taskDone = new Dictionary();
+ bool taskOk = false;
+ string taskVal = "";
// inizio con 1 byte VUOTO
byte[] MemBlock = new byte[1];
- string taskVal = "";
// cerco task specifici: se ho startSetup --> imposto bit DBB701.DBB0.4
foreach (var item in task2exe)
- {
-#if false
- // primo metodo: sul VALORE
- switch (item.Value)
- {
- case "startSetup":
- MemBlock[0] += (1 << 4);
- answ.Add(item.Key, item.Value);
- break;
- case "stopSetup":
- answ.Add(item.Key, item.Value);
- break;
- default:
- // anche se non faccio nulla SEGNO con value = NOT DONE
- break;
- }
-#endif
+ {
taskVal = "";
// controllo sulal KEY
switch (item.Key)
@@ -74,12 +59,12 @@ namespace IOB_WIN
taskVal = "UNKNOWN KEY | NO EXEC";
break;
}
- answ.Add(item.Key, taskVal);
+ taskDone.Add(item.Key, taskVal);
}
// scrivo comunque!
bool fatto = S7WriteBB(ref MemBlock);
- return answ;
+ return taskDone;
}
#region da verificare