From 5a4d8586f2a1f6937fcd468f1e46f3c51703a1a3 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Thu, 12 Jun 2025 15:16:28 +0200 Subject: [PATCH] =?UTF-8?q?Fix=20gestione=20invio=20dati=20a=20Mitsubishi:?= =?UTF-8?q?=20-=20nuova=20gestione=20conf=20per=20gestire=20funzionalit?= =?UTF-8?q?=C3=A0=20minima=20porting=20-=20aggiunto=20forceDynData=20x=20r?= =?UTF-8?q?ecupero=20valori=20-=20ripetuto=20in=20read=20parametri=20invia?= =?UTF-8?q?ti?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- IOB-WIN-MITSUBISHI/DATA/CONF/VL28.ini | 1 + IOB-WIN-MITSUBISHI/DATA/CONF/VL28.json | 44 ++++++++++++++++++++++++++ IOB-WIN-MITSUBISHI/Iob/Mitsubishi.cs | 5 +-- 3 files changed, 48 insertions(+), 2 deletions(-) diff --git a/IOB-WIN-MITSUBISHI/DATA/CONF/VL28.ini b/IOB-WIN-MITSUBISHI/DATA/CONF/VL28.ini index 90469029..8e952847 100644 --- a/IOB-WIN-MITSUBISHI/DATA/CONF/VL28.ini +++ b/IOB-WIN-MITSUBISHI/DATA/CONF/VL28.ini @@ -56,6 +56,7 @@ BLINK_FILT=0 EZNC_SYS=EZNC_SYS_MELDAS700L ENABLE_PZCOUNT=TRUE ENABLE_DYN_DATA=TRUE +FORCE_DYN_DATA=TRUE PZCOUNT_MODE=STD.PAR.8002 PZGTOT_MODE=STD.PAR.8001 PZREQ_MODE=STD.PAR.8003 diff --git a/IOB-WIN-MITSUBISHI/DATA/CONF/VL28.json b/IOB-WIN-MITSUBISHI/DATA/CONF/VL28.json index f02081c4..836dd18b 100644 --- a/IOB-WIN-MITSUBISHI/DATA/CONF/VL28.json +++ b/IOB-WIN-MITSUBISHI/DATA/CONF/VL28.json @@ -56,6 +56,50 @@ } }, "mMapRead": { + "setArtNum": { + "name": "setArtNum", + "description": "CodArt", + "memAddr": "VAR.501", + "tipoMem": "Int", + "func": "POINT", + "period": 60, + "index": 966, + "size": 4, + "displOrdinal": 2 + }, + "setCommNum": { + "name": "setCommNum", + "description": "ODL", + "memAddr": "VAR.500", + "tipoMem": "Int", + "func": "POINT", + "period": 60, + "index": 965, + "size": 4, + "displOrdinal": 4 + }, + "setPzComm": { + "name": "setPzComm", + "description": "Qta Richiesta", + "memAddr": "PAR.8003", + "tipoMem": "Int", + "func": "POINT", + "period": 60, + "index": 8003, + "size": 4, + "displOrdinal": 5 + }, + "setPzCommOdl": { + "name": "setPzCommOdl", + "description": "PzOdl", + "memAddr": "VAR.502", + "tipoMem": "Int", + "func": "POINT", + "period": 60, + "index": 502, + "size": 4, + "displOrdinal": 6 + }, "PZ_GTOT": { "name": "PZ_GTOT", "description": "Contatore GTot", diff --git a/IOB-WIN-MITSUBISHI/Iob/Mitsubishi.cs b/IOB-WIN-MITSUBISHI/Iob/Mitsubishi.cs index c671bf1a..1bb50aac 100644 --- a/IOB-WIN-MITSUBISHI/Iob/Mitsubishi.cs +++ b/IOB-WIN-MITSUBISHI/Iob/Mitsubishi.cs @@ -467,7 +467,8 @@ namespace IOB_WIN_MITSUBISHI.Iob { // cerco in dizionario... if (DictVar.ContainsKey(iVar)) - {// se NON presente... + { + // se NON presente... if (!outVal.ContainsKey(item.Key)) { outVal.Add(item.Key, $"{DictVar[iVar]}"); @@ -850,7 +851,7 @@ namespace IOB_WIN_MITSUBISHI.Iob { bool answ = false; // ...SE abilitato da conf IOB - if (IOBConfFull.OptPar.Count > 0 && getOptPar("ENABLE_PZ_REQ") == "TRUE") + if (IOBConfFull.OptPar.Count > 0 && IOBConfFull.Counters.EnableSetPzReq) { // scrivo valore 0 x il contapezzi try