diff --git a/IOB-WIN/IobFanuc.cs b/IOB-WIN/IobFanuc.cs index 0ec13149..db321294 100644 --- a/IOB-WIN/IobFanuc.cs +++ b/IOB-WIN/IobFanuc.cs @@ -227,6 +227,7 @@ namespace IOB_WIN { if (getOptPar("PZCOUNT_MODE").StartsWith("STD")) { + lgInfo("Init contapezzi FANUC: pzCntReload(true)"); pzCntReload(true); // refresh associazione Macchina - IOB sendM2IOB(); diff --git a/IOB-WIN/IobGeneric.cs b/IOB-WIN/IobGeneric.cs index d9ecc457..9d041e0c 100644 --- a/IOB-WIN/IobGeneric.cs +++ b/IOB-WIN/IobGeneric.cs @@ -1017,7 +1017,7 @@ namespace IOB_WIN lastIdxODL = utils.callUrl(urlGetCurrODL); lgInfo("Lettura ODL dall'url {0} --> {1}", urlGetCurrODL, lastIdxODL); // se ho valori in coda da trasmettere uso dati REDIS - if (QueueIN.Count > 0 && !forceCountRec) + if (QueueIN.Count > 0 || !forceCountRec) { currServerCount = utils.callUrl(urlGetPzCount); lgInfo("Lettura contapezzi dall'url {0}", urlGetPzCount); @@ -1250,8 +1250,9 @@ namespace IOB_WIN else if (ciclo == gatherCycle.VLF) { if (utils.CRB("enableContapezzi")) - { - // rilettura contapezzi da server... SE ABILITATA + { + // rilettura contapezzi da server... SE ABILITATA + lgInfo("Ciclo VLF: pzCntReload(false)"); pzCntReload(false); // refresh associazione Macchina - IOB sendM2IOB(); @@ -1413,6 +1414,7 @@ namespace IOB_WIN private void svuotaCodaContapezzi() { + lgInfo("Inizio svuotaCodaContapezzi"); // se ho contapezzi OLTRE limite... while (lastCountCNC > contapezzi + minSendPzCountBlock) { @@ -1421,8 +1423,6 @@ namespace IOB_WIN trySendPzCountBlock(); // aspetto x dare tempo calcolo Thread.Sleep(300); - //// rileggo - //pzCntReload(true); } } @@ -4167,6 +4167,7 @@ namespace IOB_WIN // se oltre 1 min NON era online --> check pezzi! if (DateTime.Now.Subtract(lastIobOnline).TotalMinutes > 1) { + lgInfo($"sendDataBlock --> offline timeaout ({lastIobOnline}) --> pzCntReload(true)"); pzCntReload(true); } lastIobOnline = DateTime.Now; @@ -4239,6 +4240,7 @@ namespace IOB_WIN // se oltre 1 min NON era online --> check pezzi! if (DateTime.Now.Subtract(lastIobOnline).TotalMinutes > 1) { + lgInfo($"sendToMoonPro --> offline timeaout ({lastIobOnline}) --> pzCntReload(true)"); pzCntReload(true); } lastIobOnline = DateTime.Now; diff --git a/IOB-WIN/IobKawasaki.cs b/IOB-WIN/IobKawasaki.cs index 34dfac94..833cf7b6 100644 --- a/IOB-WIN/IobKawasaki.cs +++ b/IOB-WIN/IobKawasaki.cs @@ -349,6 +349,7 @@ namespace IOB_WIN { if (getOptPar("PZCOUNT_MODE").StartsWith("STD")) { + lgInfo("Init contapezzi KAWASAKI: pzCntReload(true)"); pzCntReload(true); // refresh associazione Macchina - IOB sendM2IOB(); diff --git a/IOB-WIN/IobOSAI.cs b/IOB-WIN/IobOSAI.cs index c7946623..61a0e57b 100644 --- a/IOB-WIN/IobOSAI.cs +++ b/IOB-WIN/IobOSAI.cs @@ -127,6 +127,7 @@ namespace IOB_WIN { if (getOptPar("PZCOUNT_MODE").StartsWith("OVAR")) { + lgInfo("Init contapezzi OSAI: pzCntReload(true)"); pzCntReload(true); // refresh associazione Macchina - IOB sendM2IOB(); diff --git a/IOB-WIN/IobSiemens.cs b/IOB-WIN/IobSiemens.cs index c4945a33..1cdc37dc 100644 --- a/IOB-WIN/IobSiemens.cs +++ b/IOB-WIN/IobSiemens.cs @@ -891,6 +891,7 @@ namespace IOB_WIN { if (getOptPar("PZCOUNT_MODE").StartsWith("STD")) { + lgInfo("Init contapezzi SIEMENS: pzCntReload(true)"); pzCntReload(true); // refresh associazione Macchina - IOB sendM2IOB(); diff --git a/IOB-WIN/IobSimula.cs b/IOB-WIN/IobSimula.cs index 03a150bd..4d443ec7 100644 --- a/IOB-WIN/IobSimula.cs +++ b/IOB-WIN/IobSimula.cs @@ -122,6 +122,7 @@ namespace IOB_WIN } setParamPlc(); // ricarico da server i dati dei pezzi fatti... + lgInfo("Init contapezzi SIMULA: pzCntReload(true)"); pzCntReload(true); // imposto pezzi CNC ai pezzi contati da server... lastCountCNC = contapezzi;