From 8bb0f158b572d0753d3f1ae1361e83e9d5f52cfe Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 20 Dec 2024 10:16:32 +0100 Subject: [PATCH] SPLIT PROGETTO!!! - proj di base con le 2 form da ereditare - progetto globale che contiene TUTTI gli adapter (pronto a venire spezzettato - gettate le basi x "portare fuori" i vari componenti oppure fare compilazione condizonale --- IOB-UT-NEXT/Enums.cs | 62 +- IOB-UT-NEXT/IOB-UT-NEXT.csproj | 1 + .../iobRefreshedEventArgs.cs | 5 +- .../AdapterForm.Designer.cs | 2 +- {IOB-WIN-NEXT => IOB-WIN-FORM}/AdapterForm.cs | 480 +--- .../AdapterForm.resx | 0 IOB-WIN-FORM/ControlExtensions.cs | 36 + IOB-WIN-FORM/IOB-WIN-FORM.csproj | 127 ++ {IOB-WIN-NEXT => IOB-WIN-FORM}/Iob/BaseObj.cs | 4 +- {IOB-WIN-NEXT => IOB-WIN-FORM}/Iob/Generic.cs | 54 +- IOB-WIN-FORM/Iob/Simula.cs | 1987 +++++++++++++++++ IOB-WIN-FORM/MainForm.Designer.cs | 325 +++ {IOB-WIN-NEXT => IOB-WIN-FORM}/MainForm.cs | 3 +- {IOB-WIN-NEXT => IOB-WIN-FORM}/MainForm.resx | 0 IOB-WIN-FORM/Properties/AssemblyInfo.cs | 33 + IOB-WIN-FORM/app.config | 39 + IOB-WIN-FORM/packages.config | 9 + IOB-WIN-NEXT.sln | 22 +- IOB-WIN-NEXT/AdapterFormNext.cs | 379 ++++ IOB-WIN-NEXT/DATA/CONF/MAIN.ini | 4 +- IOB-WIN-NEXT/Enums.cs | 20 - IOB-WIN-NEXT/FodyWeavers.xml | 3 - IOB-WIN-NEXT/FodyWeavers.xsd | 176 -- IOB-WIN-NEXT/IOB-WIN-NEXT.csproj | 30 +- IOB-WIN-NEXT/Iob/Fanuc.cs | 4 +- IOB-WIN-NEXT/Iob/GenericNext.cs | 119 + IOB-WIN-NEXT/Iob/Kawasaki.cs | 4 +- IOB-WIN-NEXT/Iob/MTConn.cs | 4 +- IOB-WIN-NEXT/Iob/Mitsubishi.cs | 4 +- IOB-WIN-NEXT/Iob/OSAI.cs | 4 +- IOB-WIN-NEXT/Iob/Omron.cs | 4 +- IOB-WIN-NEXT/Iob/Simula.cs | 4 +- IOB-WIN-NEXT/IobBeckhoff/Beckhoff.cs | 4 +- IOB-WIN-NEXT/IobBeckhoff/BeckhoffCpa.cs | 2 +- IOB-WIN-NEXT/IobFile/FileEurom63.cs | 2 +- IOB-WIN-NEXT/IobFile/FileGen.cs | 4 +- IOB-WIN-NEXT/IobFile/IobFileSoitaab.cs | 4 +- IOB-WIN-NEXT/IobModbusTCP/ModbusTCP.cs | 4 +- IOB-WIN-NEXT/IobModbusTCP/ModbusTCPCedax.cs | 2 +- .../IobModbusTCP/ModbusTCPCenterfrigo.cs | 2 +- IOB-WIN-NEXT/IobModbusTCP/ModbusTCPFimat.cs | 2 +- IOB-WIN-NEXT/IobModbusTCP/ModbusTCPHam.cs | 2 +- IOB-WIN-NEXT/IobModbusTCP/ModbusTCPHelpi.cs | 2 +- .../IobModbusTCP/ModbusTCPImaxAeromec.cs | 2 +- IOB-WIN-NEXT/IobModbusTCP/ModbusTCPRimor.cs | 2 +- IOB-WIN-NEXT/IobModbusTCP/ModbusTCPSaim.cs | 2 +- .../IobModbusTCP/ModbusTCPZetapack.cs | 2 +- IOB-WIN-NEXT/IobNet/Ftp.cs | 4 +- IOB-WIN-NEXT/IobNet/IcoelSoap.cs | 4 +- IOB-WIN-NEXT/IobNet/Ping.cs | 4 +- IOB-WIN-NEXT/IobNet/WebPageScrap.cs | 4 +- IOB-WIN-NEXT/IobOpc/OpcUa.cs | 4 +- IOB-WIN-NEXT/IobOpc/OpcUaCMS.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaEwon.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaEwonAdige.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaEwonBLM.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaEwonMecolpress.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaEwonMonti.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaImas.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaKpw.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaKpwRama.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaMBH.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaMBHCimolai.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaOmron.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaOmronIcoel.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaSiemens.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaSiemensOMP.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaSiemensRama.cs | 2 +- IOB-WIN-NEXT/IobOpc/OpcUaUlma.cs | 2 +- IOB-WIN-NEXT/IobRest/Base.cs | 4 +- IOB-WIN-NEXT/IobRest/Citizen.cs | 2 +- IOB-WIN-NEXT/IobSiemens/Siemens.cs | 4 +- IOB-WIN-NEXT/IobSiemens/SiemensAprochim.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensAt2001.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensComeca.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensComur.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensCosmap.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensFape.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensFapeV2.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensIngenia.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensLasco.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensNWSE.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensPressoilCei.cs | 2 +- .../IobSiemens/SiemensRobotService.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensSaet.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensSimec.cs | 2 +- IOB-WIN-NEXT/IobSiemens/SiemensTorri.cs | 2 +- IOB-WIN-NEXT/IobSoap/Gomba.cs | 4 +- IOB-WIN-NEXT/IobSql/IcoelDb.cs | 4 +- IOB-WIN-NEXT/IobSql/SqlServLantek.cs | 4 +- IOB-WIN-NEXT/IobSql/SqlServPama.cs | 4 +- IOB-WIN-NEXT/MainForm.Designer.cs | 325 --- IOB-WIN-NEXT/Program.cs | 2 +- VersGen/VersGen.cs | 2 +- VersGen/VersGen.vb | 2 +- 95 files changed, 3340 insertions(+), 1087 deletions(-) rename {IOB-WIN-NEXT/Iob => IOB-UT-NEXT}/iobRefreshedEventArgs.cs (93%) rename {IOB-WIN-NEXT => IOB-WIN-FORM}/AdapterForm.Designer.cs (99%) rename {IOB-WIN-NEXT => IOB-WIN-FORM}/AdapterForm.cs (82%) rename {IOB-WIN-NEXT => IOB-WIN-FORM}/AdapterForm.resx (100%) create mode 100644 IOB-WIN-FORM/ControlExtensions.cs create mode 100644 IOB-WIN-FORM/IOB-WIN-FORM.csproj rename {IOB-WIN-NEXT => IOB-WIN-FORM}/Iob/BaseObj.cs (99%) rename {IOB-WIN-NEXT => IOB-WIN-FORM}/Iob/Generic.cs (99%) create mode 100644 IOB-WIN-FORM/Iob/Simula.cs create mode 100644 IOB-WIN-FORM/MainForm.Designer.cs rename {IOB-WIN-NEXT => IOB-WIN-FORM}/MainForm.cs (99%) rename {IOB-WIN-NEXT => IOB-WIN-FORM}/MainForm.resx (100%) create mode 100644 IOB-WIN-FORM/Properties/AssemblyInfo.cs create mode 100644 IOB-WIN-FORM/app.config create mode 100644 IOB-WIN-FORM/packages.config create mode 100644 IOB-WIN-NEXT/AdapterFormNext.cs delete mode 100644 IOB-WIN-NEXT/Enums.cs delete mode 100644 IOB-WIN-NEXT/FodyWeavers.xml delete mode 100644 IOB-WIN-NEXT/FodyWeavers.xsd create mode 100644 IOB-WIN-NEXT/Iob/GenericNext.cs delete mode 100644 IOB-WIN-NEXT/MainForm.Designer.cs diff --git a/IOB-UT-NEXT/Enums.cs b/IOB-UT-NEXT/Enums.cs index f6e83645..345c3a0e 100644 --- a/IOB-UT-NEXT/Enums.cs +++ b/IOB-UT-NEXT/Enums.cs @@ -38,26 +38,6 @@ namespace IOB_UT_NEXT /// prod } - /// - /// Tipo di IOB (SW) - /// - public enum IobSwType - { - /// - /// Non definito - /// - ND, - - /// - /// IOB rPI - /// - rPi, - - /// - /// IOB Windows - /// - WIN - } /// /// Elenco MODI CNC @@ -209,6 +189,27 @@ namespace IOB_UT_NEXT VLF } + /// + /// Tipo di IOB (SW) + /// + public enum IobSwType + { + /// + /// Non definito + /// + ND, + + /// + /// IOB rPI + /// + rPi, + + /// + /// IOB Windows + /// + WIN + } + /// /// Modalità gestione setup macchina /// @@ -234,6 +235,27 @@ namespace IOB_UT_NEXT HoldingRegister = 4 } + /// + /// Modalità avvio APP IOB-WIN + /// + public enum StartMode + { + /// + /// modalità standard (standalone, multi IOB) + /// + STD = 0, + + /// + /// Modalità managed (da IOB-MAN) + /// + MAN = 1, + + /// + /// Modalità update (per aggiornare IOB-WIN) senza IOB + /// + UPD = 2 + } + /// /// StFlag32: set di 32 bit (4 word) contente semaforo di variabili /// diff --git a/IOB-UT-NEXT/IOB-UT-NEXT.csproj b/IOB-UT-NEXT/IOB-UT-NEXT.csproj index d1b47cbf..6c03b3ef 100644 --- a/IOB-UT-NEXT/IOB-UT-NEXT.csproj +++ b/IOB-UT-NEXT/IOB-UT-NEXT.csproj @@ -168,6 +168,7 @@ + diff --git a/IOB-WIN-NEXT/Iob/iobRefreshedEventArgs.cs b/IOB-UT-NEXT/iobRefreshedEventArgs.cs similarity index 93% rename from IOB-WIN-NEXT/Iob/iobRefreshedEventArgs.cs rename to IOB-UT-NEXT/iobRefreshedEventArgs.cs index b9fa89eb..7b7b9d4a 100644 --- a/IOB-WIN-NEXT/Iob/iobRefreshedEventArgs.cs +++ b/IOB-UT-NEXT/iobRefreshedEventArgs.cs @@ -1,7 +1,6 @@ -using IOB_UT_NEXT; -using System; +using System; -namespace IOB_WIN_NEXT.Iob +namespace IOB_UT_NEXT { /// /// Evento per incapsulare dati x refresh pagina diff --git a/IOB-WIN-NEXT/AdapterForm.Designer.cs b/IOB-WIN-FORM/AdapterForm.Designer.cs similarity index 99% rename from IOB-WIN-NEXT/AdapterForm.Designer.cs rename to IOB-WIN-FORM/AdapterForm.Designer.cs index 6c8102fa..79df7326 100644 --- a/IOB-WIN-NEXT/AdapterForm.Designer.cs +++ b/IOB-WIN-FORM/AdapterForm.Designer.cs @@ -1,4 +1,4 @@ -namespace IOB_WIN_NEXT +namespace IOB_WIN_FORM { partial class AdapterForm { diff --git a/IOB-WIN-NEXT/AdapterForm.cs b/IOB-WIN-FORM/AdapterForm.cs similarity index 82% rename from IOB-WIN-NEXT/AdapterForm.cs rename to IOB-WIN-FORM/AdapterForm.cs index 6c6bab39..b6833ffc 100644 --- a/IOB-WIN-NEXT/AdapterForm.cs +++ b/IOB-WIN-FORM/AdapterForm.cs @@ -1,6 +1,4 @@ using IOB_UT_NEXT; -using IOB_WIN_NEXT.Iob; -using IOB_WIN_NEXT.IobSoap; using MapoSDK; using Newtonsoft.Json; using NLog; @@ -14,7 +12,7 @@ using System.Linq; using System.Threading; using System.Windows.Forms; -namespace IOB_WIN_NEXT +namespace IOB_WIN_FORM { public partial class AdapterForm : Form { @@ -196,6 +194,30 @@ namespace IOB_WIN_NEXT } } + /// + /// Button restart encapsulato x gestione da classi derivate + /// + public Button btnRestart + { + get => restart; + } + + /// + /// Button start encapsulato x gestione da classi derivate + /// + public Button btnStart + { + get => start; + } + + /// + /// Button stop encapsulato x gestione da classi derivate + /// + public Button btnStop + { + get => stop; + } + /// /// Visualizzazione stato di comunicazione attiva con PLC /// @@ -454,6 +476,18 @@ namespace IOB_WIN_NEXT /// public bool isVerboseLog { get; set; } = utils.CRB("verbose"); + public string lblCncText + { + get => lblCNC.Text; + set => lblCNC.Text = value; + } + + public string lblSrvUrlText + { + get => lblSrvUrl.Text; + set => lblSrvUrl.Text = value; + } + /// /// Logwatcher (in modalità "accodamento in testa" ultimi messaggi...) /// @@ -1088,6 +1122,17 @@ namespace IOB_WIN_NEXT base.Dispose(disposing); } + /// + /// GEstione evento refresh + /// + /// + /// + protected void IobObj_eh_refreshed(object sender, iobRefreshedEventArgs e) + { + // aggiorno! + updateFormDisplay(e.DisplayDataObject); + } + /// /// Effettua logging DEBUG corretto impostanto anche la variabile IOB prima di scrivere... /// @@ -1150,6 +1195,34 @@ namespace IOB_WIN_NEXT updateFormDisplay(currDispData); } + /// + /// carica IOB richiesto + /// + protected virtual void loadIobType() + { + if (IOBConf != null) + { + switch (tipoScelto) + { + case tipoAdapter.ND: + default: + iobObj = new Iob.Simula(this, IOBConf); + start.Enabled = false; + break; + } + lblCNC.Text = $"CNC: {IOBConf.tipoIob} [{IOBConf.cncIpAddr}:{IOBConf.cncPort}]"; + lblSrvUrl.Text = $"SRV: {IOBConf.serverData.MPIP} | URL: {IOBConf.serverData.MPURL}{IOBConf.serverData.CMDBASE}"; + + // aggancio evento refresh + iobObj.eh_refreshed += IobObj_eh_refreshed; + + // carico i default values su interfaccia + setDefaults(); + + displayTaskAndLog($"Caricata conf per adapter {tipoScelto}"); + } + } + /// /// Init form (grafica) con helper x testi e varie /// @@ -1171,6 +1244,21 @@ namespace IOB_WIN_NEXT ttForceSend.SetToolTip(this.chkForceDequeue, "Forza invio eventi allo stop"); } + /// + /// impostazione valori defaults + /// + protected void setDefaults() + { + stop.Enabled = false; + + alQueueLen = 0; + flQueueLen = 0; + msQueueLen = 0; + rtrQueueLen = 0; + ulQueueLen = 0; + nLine2show = utils.CRI("numRowConsole"); + } + /// /// MOstra info su coda complessiva /// @@ -1391,7 +1479,7 @@ namespace IOB_WIN_NEXT updateFormDisplay(currDispData); } } - catch(Exception exc) + catch (Exception exc) { lgError($"Errore in chiusura:{Environment.NewLine}{exc}"); } @@ -1520,17 +1608,6 @@ namespace IOB_WIN_NEXT } } - /// - /// GEstione evento refresh - /// - /// - /// - private void IobObj_eh_refreshed(object sender, Iob.iobRefreshedEventArgs e) - { - // aggiorno! - updateFormDisplay(e.DisplayDataObject); - } - /// /// Carica file ini della configurazione richiesta /// @@ -1631,364 +1708,6 @@ namespace IOB_WIN_NEXT } } - /// - /// carica IOB richiesto - /// - private void loadIobType() - { - if (IOBConf != null) - { - switch (tipoScelto) - { - case tipoAdapter.SIMULA: - iobObj = new Iob.Simula(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.BECKHOFF: - case tipoAdapter.BECKHOFF_CPA: - iobObj = new IobBeckhoff.BeckhoffCpa(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.FILE_GEN: - iobObj = new IobFile.FileGen(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.FILE_EUROM63: - iobObj = new IobFile.FileEurom63(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.FILE_SOITAAB: - iobObj = new IobFile.IobFileSoitaab(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.FANUC: - iobObj = new Iob.Fanuc(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.FTP: - iobObj = new IobNet.Ftp(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.KAWASAKI: - iobObj = new Iob.Kawasaki(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.IcoelDb: - iobObj = new IobSql.IcoelDb(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.IcoelSoap: - iobObj = new IobNet.IcoelSoap(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MITSUBISHI: - iobObj = new Mitsubishi(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MODBUS_TCP: - iobObj = new IobModbusTCP.ModbusTCP(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MODBUS_TCP_CEDAX: - iobObj = new IobModbusTCP.ModbusTCPCedax(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MODBUS_TCP_CENTERFRIGO: - iobObj = new IobModbusTCP.ModbusTCPCenterfrigo(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MODBUS_TCP_FIMAT: - iobObj = new IobModbusTCP.ModbusTCPFimat(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MODBUS_TCP_HAM: - iobObj = new IobModbusTCP.ModbusTCPHam(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MODBUS_TCP_HELPI: - iobObj = new IobModbusTCP.ModbusTCPHelpi(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MODBUS_TCP_IMAS_AEROMEC: - iobObj = new IobModbusTCP.ModbusTCPImaxAeromec(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MODBUS_TCP_RIMOR: - iobObj = new IobModbusTCP.ModbusTCPRimor(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MODBUS_TCP_SAIM: - iobObj = new IobModbusTCP.ModbusTCPSaim(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MODBUS_TCP_ZETAPACK: - iobObj = new IobModbusTCP.ModbusTCPZetapack(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.MTConnect: - iobObj = new Iob.MTConn(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OMRON: - iobObj = new Iob.Omron(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUa: - iobObj = new IobOpc.OpcUa(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaCMS: - case tipoAdapter.OpcUaSCM: - iobObj = new IobOpc.OpcUaCMS(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaEwon: - iobObj = new IobOpc.OpcUaEwon(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaEwonAdige: - iobObj = new IobOpc.OpcUaEwonAdige(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaEwonBLM: - iobObj = new IobOpc.OpcUaEwonBLM(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaEwonMonti: - iobObj = new IobOpc.OpcUaEwonMonti(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaEwonMecolpress: - iobObj = new IobOpc.OpcUaEwonMecolpress(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaKwp: - iobObj = new IobOpc.OpcUaKpw(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaKwpRama: - iobObj = new IobOpc.OpcUaKpwRama(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaImasAeromec: - iobObj = new IobOpc.OpcUaImas(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaMBH: - iobObj = new IobOpc.OpcUaMBH(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaMBHCimolai: - iobObj = new IobOpc.OpcUaMBHCimolai(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaOmron: - iobObj = new IobOpc.OpcUaOmron(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaOmronIcoel: - iobObj = new IobOpc.OpcUaOmronIcoel(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaSiemens: - iobObj = new IobOpc.OpcUaSiemens(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaSiemensOMP: - iobObj = new IobOpc.OpcUaSiemensOMP(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaSiemensRama: - iobObj = new IobOpc.OpcUaSiemensRama(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OpcUaUlma: - iobObj = new IobOpc.OpcUaUlma(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.PingWatchdog: - iobObj = new IobNet.Ping(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.OSAI_OPEN: - case tipoAdapter.OSAI_CNDEX: - case tipoAdapter.OSAI_VB6: - // versione EgwProxy.OsaiCncLib - iobObj = new Iob.OSAI(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.REST: - iobObj = new IobRest.Base(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.REST_CITIZEN: - iobObj = new IobRest.Citizen(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS: - iobObj = new IobSiemens.Siemens(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_APROCHIM: - iobObj = new IobSiemens.SiemensAprochim(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_AT2001: - iobObj = new IobSiemens.SiemensAt2001(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_COMECA: - iobObj = new IobSiemens.SiemensComeca(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_COMUR: - iobObj = new IobSiemens.SiemensComur(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_COSMAP: - iobObj = new IobSiemens.SiemensCosmap(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_FAPE: - iobObj = new IobSiemens.SiemensFape(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_FAPE_2: - iobObj = new IobSiemens.SiemensFapeV2(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_INGENIA: - iobObj = new IobSiemens.SiemensIngenia(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_LASCO: - iobObj = new IobSiemens.SiemensLasco(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_NWSE: - iobObj = new IobSiemens.SiemensNWSE(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_PRESSOIL_CEI: - iobObj = new IobSiemens.SiemensPressoilCei(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_ROBOTSERVICE: - iobObj = new IobSiemens.SiemensRobotService(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_SAET: - iobObj = new IobSiemens.SiemensSaet(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_SIMEC: - iobObj = new IobSiemens.SiemensSimec(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SIEMENS_TORRI: - iobObj = new IobSiemens.SiemensTorri(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SOAP_GOMBA: - iobObj = new IobSoap.Gomba(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SQLSERVER_LANTEK: - iobObj = new IobSql.SqlServLantek(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.SQLSERVER_PAMA: - iobObj = new IobSql.SqlServPama(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.WPS: - iobObj = new IobNet.WebPageScrap(this, IOBConf); - start.Enabled = true; - break; - - case tipoAdapter.ND: - default: - iobObj = new Iob.Simula(this, IOBConf); - start.Enabled = false; - break; - } - lblCNC.Text = $"CNC: {IOBConf.tipoIob} [{IOBConf.cncIpAddr}:{IOBConf.cncPort}]"; - lblSrvUrl.Text = $"SRV: {IOBConf.serverData.MPIP} | URL: {IOBConf.serverData.MPURL}{IOBConf.serverData.CMDBASE}"; - - // aggancio evento refresh - iobObj.eh_refreshed += IobObj_eh_refreshed; - - // carico i default values su interfaccia - setDefaults(); - - displayTaskAndLog($"Caricata conf per adapter {tipoScelto}"); - } - } - /// /// Verifica se il log di un dato errore sia permesso /// @@ -2163,21 +1882,6 @@ namespace IOB_WIN_NEXT } } - /// - /// impostazione valori defaults - /// - private void setDefaults() - { - stop.Enabled = false; - - alQueueLen = 0; - flQueueLen = 0; - msQueueLen = 0; - rtrQueueLen = 0; - ulQueueLen = 0; - nLine2show = utils.CRI("numRowConsole"); - } - private void splitContainer1_Panel1_Paint(object sender, PaintEventArgs e) { } diff --git a/IOB-WIN-NEXT/AdapterForm.resx b/IOB-WIN-FORM/AdapterForm.resx similarity index 100% rename from IOB-WIN-NEXT/AdapterForm.resx rename to IOB-WIN-FORM/AdapterForm.resx diff --git a/IOB-WIN-FORM/ControlExtensions.cs b/IOB-WIN-FORM/ControlExtensions.cs new file mode 100644 index 00000000..48a888bb --- /dev/null +++ b/IOB-WIN-FORM/ControlExtensions.cs @@ -0,0 +1,36 @@ +using System; +using System.Windows.Forms; + +namespace IOB_WIN_FORM +{ + /// + /// Helper gestione UITHread e deleghe + /// https://www.codeproject.com/Articles/37642/Avoiding-InvokeRequired + /// + internal static class ControlExtensions + { + #region Public Methods + + public static void UIThread(this Control control, Action code) + { + if (control.InvokeRequired) + { + control.BeginInvoke(code); + return; + } + code.Invoke(); + } + + public static void UIThreadInvoke(this Control control, Action code) + { + if (control.InvokeRequired) + { + control.Invoke(code); + return; + } + code.Invoke(); + } + + #endregion Public Methods + } +} \ No newline at end of file diff --git a/IOB-WIN-FORM/IOB-WIN-FORM.csproj b/IOB-WIN-FORM/IOB-WIN-FORM.csproj new file mode 100644 index 00000000..2d5843fe --- /dev/null +++ b/IOB-WIN-FORM/IOB-WIN-FORM.csproj @@ -0,0 +1,127 @@ + + + + + Debug + AnyCPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097} + Library + IOB_WIN_FORM + IOB-WIN-FORM + v4.6.2 + 512 + true + + + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + ..\packages\Autoupdater.NET.Official.1.8.4\lib\net45\AutoUpdater.NET.dll + + + ..\packages\MapoSDK.6.14.2411.518\lib\MapoSDK.dll + + + ..\packages\MathNet.Numerics.4.15.0\lib\net461\MathNet.Numerics.dll + + + ..\packages\Microsoft.Web.WebView2.1.0.1823.32\lib\net45\Microsoft.Web.WebView2.Core.dll + + + ..\packages\Microsoft.Web.WebView2.1.0.1823.32\lib\net45\Microsoft.Web.WebView2.WinForms.dll + + + ..\packages\Microsoft.Web.WebView2.1.0.1823.32\lib\net45\Microsoft.Web.WebView2.Wpf.dll + + + ..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll + + + ..\packages\NLog.5.2.3\lib\net46\NLog.dll + + + + + + + + + + + + + + + + + + + + + + VersGen.cs + + + Form + + + AdapterForm.cs + + + + + + + Form + + + MainForm.cs + + + + + + + AdapterForm.cs + + + MainForm.cs + + + + + {90512e12-29fc-460d-94cc-648c2a072dbd} + IOB-UT-NEXT + + + + + + + + + + + + This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}. + + + + \ No newline at end of file diff --git a/IOB-WIN-NEXT/Iob/BaseObj.cs b/IOB-WIN-FORM/Iob/BaseObj.cs similarity index 99% rename from IOB-WIN-NEXT/Iob/BaseObj.cs rename to IOB-WIN-FORM/Iob/BaseObj.cs index 9e025cb1..50ed3097 100644 --- a/IOB-WIN-NEXT/Iob/BaseObj.cs +++ b/IOB-WIN-FORM/Iob/BaseObj.cs @@ -8,7 +8,7 @@ using System.Net.NetworkInformation; using System.Threading; using static IOB_UT_NEXT.BaseAlarmConf; -namespace IOB_WIN_NEXT.Iob +namespace IOB_WIN_FORM.Iob { /// /// Classe di base per IOB @@ -86,7 +86,7 @@ namespace IOB_WIN_NEXT.Iob /// /// /// - protected void lgError(string message, params object[] args) + public void lgError(string message, params object[] args) { bool doVeto = checkLogVeto(2, ref message); // se non ho veto --> loggo diff --git a/IOB-WIN-NEXT/Iob/Generic.cs b/IOB-WIN-FORM/Iob/Generic.cs similarity index 99% rename from IOB-WIN-NEXT/Iob/Generic.cs rename to IOB-WIN-FORM/Iob/Generic.cs index cfe20682..9a6ecf85 100644 --- a/IOB-WIN-NEXT/Iob/Generic.cs +++ b/IOB-WIN-FORM/Iob/Generic.cs @@ -1,10 +1,6 @@ -using EgwProxy.Ftp; -using EgwProxy.MultiCncLib.App.Native; -using IOB_UT_NEXT; +using IOB_UT_NEXT; using MapoSDK; using MathNet.Numerics.Statistics; -using MTConnect; -using MTConnect.Clients; using Newtonsoft.Json; using Newtonsoft.Json.Linq; using NLog; @@ -26,7 +22,7 @@ using static IOB_UT_NEXT.CustomObj; using static IOB_UT_NEXT.DataModel.Fimat; using static MapoSDK.WharehouseData; -namespace IOB_WIN_NEXT.Iob +namespace IOB_WIN_FORM.Iob { public class Generic : BaseObj { @@ -42,7 +38,7 @@ namespace IOB_WIN_NEXT.Iob /// inizializzo l'oggetto sulla form SULLA BASE DEL FILE DI CONFIGURAZIONE letto /// /// - /// + /// public Generic(AdapterForm caller, IobConfiguration IOBConf) { if (IOBConf != null) @@ -2725,23 +2721,6 @@ namespace IOB_WIN_NEXT.Iob } } - /// - /// retituisce data-ora dell'ODL corrente - /// - /// - private DateTime currOdlStart() - { - DateTime inizioOdl = DateTime.Now; - string rawDataInizio = callUrl(urlInizioOdlIob, false); - DateTime.TryParse(rawDataInizio, out inizioOdl); - return inizioOdl; - } - - /// - /// Periodo Veto prima di eseguire processAutoOdl - /// - private DateTime VetoProcessAutoOdl = DateTime.Now; - /// /// Verifica e processing x gestione ODL automatica /// @@ -4370,12 +4349,6 @@ namespace IOB_WIN_NEXT.Iob #endregion Public Methods - #region Internal Properties - - internal bool disDynDataRangeCheck { get; set; } = false; - - #endregion Internal Properties - #region Protected Fields protected bool _connOk = false; @@ -4746,6 +4719,8 @@ namespace IOB_WIN_NEXT.Iob protected Dictionary DictNumArt { get; set; } = new Dictionary(); + protected bool disDynDataRangeCheck { get; set; } = false; + /// /// Folder in cui è presente il tool import excel + file json di conf /// @@ -5717,6 +5692,7 @@ namespace IOB_WIN_NEXT.Iob protected virtual bool iobSendFTP(string folderDir) { bool answ = false; +#if false //leggo CONF string ftpServ = getOptPar("FTP_SERVER"); string ftpUser = getOptPar("FTP_USER"); @@ -5785,6 +5761,7 @@ namespace IOB_WIN_NEXT.Iob lgInfo($"FTP: Archived dir content {localPath} --> {archPath}"); } } +#endif return answ; } @@ -7730,6 +7707,11 @@ namespace IOB_WIN_NEXT.Iob /// private int vetoPeriodMin = 15; + /// + /// Periodo Veto prima di eseguire processAutoOdl + /// + private DateTime VetoProcessAutoOdl = DateTime.Now; + /// /// Dizionario dei valori bloccati x evitare log basato su veto temporale /// @@ -8029,6 +8011,18 @@ namespace IOB_WIN_NEXT.Iob } } + /// + /// retituisce data-ora dell'ODL corrente + /// + /// + private DateTime currOdlStart() + { + DateTime inizioOdl = DateTime.Now; + string rawDataInizio = callUrl(urlInizioOdlIob, false); + DateTime.TryParse(rawDataInizio, out inizioOdl); + return inizioOdl; + } + /// /// Mostra i dati grezzi letti in esadecimale Parametri da /// aggiornare x display in form diff --git a/IOB-WIN-FORM/Iob/Simula.cs b/IOB-WIN-FORM/Iob/Simula.cs new file mode 100644 index 00000000..a7ed9810 --- /dev/null +++ b/IOB-WIN-FORM/Iob/Simula.cs @@ -0,0 +1,1987 @@ +using IOB_UT_NEXT; +using MapoSDK; +using Newtonsoft.Json; +using System; +using System.Collections.Generic; +using System.Globalization; +using System.IO; +using System.Linq; +using static IOB_UT_NEXT.CustomObj; + +namespace IOB_WIN_FORM.Iob +{ + /// + /// Configuraizone eventi da simulare + /// + public class simPar + { + #region Public Fields + + /// + /// Durata dell'evento + /// + public int duration = 1; + + /// + /// DateTime ultimo evento + /// + public DateTime lastEv = DateTime.Now; + + /// + /// Attesa per evento + /// + public int wait = 10; + + #endregion Public Fields + } + + public class Simula : Iob.Generic + { + #region Public Fields + + /// + /// Ora spegniemnto (standard) + /// + public int tOff = 22; + + /// + /// Ora dia ccensione (standard) + /// + public int tOn = 6; + + #endregion Public Fields + + #region Public Constructors + + /// + /// estende l'init della classe base... + /// + /// + /// + public Simula(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + { + // gestione invio ritardato contapezzi + pzCountDelay = utils.CRI("pzCountDelay"); + DateTime adesso = DateTime.Now; + lastPzCountSend = adesso; + lastWarnODL = adesso; + lastEvCheck = adesso; + lastSimData = adesso; + lastRedDuration = adesso; + // abilito subito scrittura coda IN + queueInEnabCurr = true; + // setup allarmi simulati + for (int i = 1; i <= 8; i++) + { + alarmMessages.Add($"Allarme {i:000}"); + } + // sistemo parametri x simulazione... + if (cIobConf.optPar.Count > 0) + { + if (!string.IsNullOrEmpty(getOptPar("PER_BASE"))) + { + int.TryParse(getOptPar("PER_BASE"), out periodoMSec); + // aggiungo NOISE... +/- 10% + Random rnd = new Random(); + int noise = rnd.Next(1, periodoMSec / 5); + periodoMSec += noise - (periodoMSec / 10); + } + simPowerOnOff = false; + bool.TryParse(getOptPar("SIM_POW_ON_OFF"), out simPowerOnOff); + int.TryParse(getOptPar("T_ON"), out tOn); + int.TryParse(getOptPar("T_OFF"), out tOff); + bit2 = setupSimPar("SIM_PZCNT"); + bit3 = setupSimPar("SIM_ALARM"); + bit4 = setupSimPar("SIM_MANU"); + bit5 = setupSimPar("SIM_SLOW"); + bit6 = setupSimPar("SIM_WUCD"); + bit7 = setupSimPar("SIM_EMRG"); + int.TryParse(getOptPar("MIN_DURATA_ODL"), out minDurataODL); + var strDisableSim = getOptPar("DISABLE_SIM_STATUS"); + if (!string.IsNullOrEmpty(strDisableSim)) + { + bool.TryParse(strDisableSim, out disableSimStatus); + } + // simulazioni azioni utente + simRC = setupSimPar("SIM_RC"); + simRS = setupSimPar("SIM_RS"); + simDich = setupSimPar("SIM_DICH"); + int.TryParse(getOptPar("SIM_MATR_OPR"), out matrOpr); + } + + string sFluxOnRead = getOptPar("sendFluxOnRead"); + if (!string.IsNullOrEmpty("sendFluxOnRead")) + { + bool.TryParse(sFluxOnRead, out sendFluxOnRead); + } + + // gestione override contatore articoli... + if (!string.IsNullOrEmpty(getOptPar("NUM_ART_CHR_TRIM"))) + { + string NUM_ART_CHR_TRIM = getOptPar("NUM_ART_CHR_TRIM"); + bool.TryParse(NUM_ART_CHR_TRIM, out numArtCharTrim); + } + + // riesegue setup PLC + setParamPlc(); + // ricarico da server i dati dei pezzi fatti... + lgInfo("Init contapezzi SIMULA: pzCntReload(true)"); + if (!isMulti) + { + pzCntReload(true); + } + // imposto pezzi CNC ai pezzi contati da server... + contapezziPLC = contapezziIOB; + lgInfo($"Impostazione iniziale contatori: contapezzi macchina contapezziPLC: {contapezziPLC} | contapezziIOB: {contapezziIOB}"); + + // parto processando dynData + processDynData(); + + if (!string.IsNullOrEmpty(getOptPar("FTP_AT_START")) || !string.IsNullOrEmpty(getOptPar("DATA_SYNC_AT_START"))) + { + // simulazione processo FTP (Cimolai) - FIXME TODO DeleteME + processDataSync(); + } + // test ricetta + if (hasRecipe) + { + Calendar cal = new CultureInfo("it-IT").Calendar; + int week = cal.GetWeekOfYear(adesso, CalendarWeekRule.FirstFourDayWeek, DayOfWeek.Monday); + string tempPath = Path.Combine(pathList["path-locBase"], pathList["path-01-Temp"]); + string archPath = Path.Combine(pathList["path-locBase"], pathList["path-02-Sent"], $"{adesso:yyyy}", $"{week:00}"); + string remoPath = Path.Combine(pathList["path-locBase"], pathList["path-04-remReq"]); + baseUtils.checkDir(tempPath); + baseUtils.checkDir(archPath); + try + { + // recupero elenco PODL da processare, check PODL già inviati, save locale + bool create = RecipeReqWriteLocal(tempPath, useLocalRecipe); + // invio ricette a impianto + bool trasmitted = RecipeSend(tempPath, archPath, remoPath); + } + catch (Exception exc) + { + lgError($"Eccezione in TEST processDataSync{Environment.NewLine}{exc}"); + } + } + + // test gestione fileImport... + if (!string.IsNullOrEmpty(fileImportFolder)) + { + processFileImport(); + } + if (hasRecipe) + { + try + { + // effettua process ritorno ricette + processRecipeFileRet(); + } + catch (Exception exc) + { + lgError($"Eccezione in TEST processRecipeFileRet{Environment.NewLine}{exc}"); + } + try + { + // eseguo verifica/lancio ricette + RecipeDoProcCons(); + } + catch (Exception exc) + { + lgError($"Eccezione in TEST RecipeDoProcCons{Environment.NewLine}{exc}"); + } + } + // commentato post test x Soitaab + if (EnabelPodlManFull) + { + // test decodifica log (tipo soitaab) + try + { + // eseguo subito un ciclo acquisizione log + processing + bool acquireLog = getRemoteLog(); + if (acquireLog) + { + bool sentSignLog = processSignLogTable(adesso); + bool sentFluxLog = processFluxLogTable(adesso); + } + } + catch (Exception exc) + { + lgError($"Eccezione in IobFileSoitaab{Environment.NewLine}{exc}"); + } + } + } + + #endregion Public Constructors + + #region Public Methods + + /// + /// Processo i task richiesti e li elimino dalla coda 1:1 (in realtà SOLO forceSetPzCount x ora) + /// + /// + public override Dictionary executeTasks(Dictionary task2exe) + { + // Verificare il protocollo: dovrebeb togliere SOLO i task eseguiti... + Dictionary taskDone = new Dictionary(); + // controlo SE sia disabilitata simulazione principale + if (!disableSimStatus) + { + string taskVal = ""; + string newVal = ""; + // verifico non sia null + if (task2exe != null) + { + // cerco task specifici + foreach (var item in task2exe) + { + taskVal = ""; + newVal = ""; + // converto richiesta in enum... + taskType tName = taskType.nihil; + Enum.TryParse(item.Key, out tName); + // controllo sulla KEY + switch (tName) + { + case taskType.setArt: + case taskType.setComm: + case taskType.setProg: + case taskType.setPzComm: + // da memMap... + if (memMap != null && memMap.mMapWrite != null) + { + if (memMap.mMapWrite.ContainsKey(item.Key)) + { + dataConf currMem = memMap.mMapWrite[item.Key]; + string addr = currMem.memAddr; + taskVal = $"SET task: {item.Key} --> {item.Value} | mem: {currMem.memAddr} - {currMem.size} byte"; + // salvo il nuovo valore nella memoria... così prox invio lo trasmetterà + memMap.mMapWrite[item.Key].value = item.Value; + } + else + { + taskVal = $"NO DATA MEM, SET task: {item.Key} --> {item.Value} ({item.Value})"; + } + } + else + { + taskVal = $"NO MemMap found, SET task: {item.Key} --> {item.Value}"; + } + // salvo in currProd.. + upsertKey(item.Key, item.Value); + //taskVal = processMemWriteRequests(); + break; + + case taskType.setParameter: + // richiedo da URL i parametri WRITE da popolare + lgInfo("Chiamata processMemWriteRequests"); + taskVal = processMemWriteRequests(); + // se restituiscce "" faccio altra prova... + if (string.IsNullOrEmpty(taskVal)) + { + // i parametri me li aspetto come stringa composta paramName|paramvalue + if (item.Value.Contains("|")) + { + string[] paramsJob = item.Value.Split('|'); + taskVal = $"REQUEST SET PARAMETERS: {paramsJob[0]} --> {paramsJob[1]}"; + } + else + { + taskVal = $"WRONG REQUEST FOR SET PARAMETERS: {item.Value} doesnt contain pipe for splitting key/value"; + } + } + break; + + case taskType.setArtNum: + // in primis faccio una chiamata per tutta la tab SE fosse vuoto il + // dict di traduzione + if (DictNumArt == null || DictNumArt.Count == 0) + { + getNumArt(""); + } + // chiamo server x avere decodifica valore INT + newVal = getNumArt(item.Value); + if (numArtCharTrim) + { + string rawData = item.Value; + newVal = baseUtils.GetNumbers(rawData); + int newValInt = 0; + int.TryParse(newVal, out newValInt); + } + // procedo come il resto cercando mappatura in memMap: recupero dati + // da memMap... + if (memMap != null && memMap.mMapWrite != null) + { + if (memMap.mMapWrite.ContainsKey(item.Key)) + { + dataConf currMem = memMap.mMapWrite[item.Key]; + string addr = currMem.memAddr; + taskVal = $"SET task: {item.Key} --> {newVal} | mem: {currMem.memAddr} - {currMem.size} byte"; + // salvo il nuovo valore nella memoria... così prox invio lo trasmetterà + memMap.mMapWrite[item.Key].value = newVal; + } + else + { + taskVal = $"NO DATA MEM, SET task: {item.Key} --> {newVal} ({item.Value})"; + } + } + else + { + taskVal = $"NO MemMap found, SET task: {item.Key} --> {newVal} ({item.Value})"; + } + + // salvo in currProd.. + upsertKey(item.Key, newVal); + break; + + case taskType.setCommNum: + // chiamo server x avere decodifica valore INT + newVal = getNumComm(item.Value); + // procedo come il resto cercando mappatura in memMap: recupero dati + // da memMap... + if (memMap != null && memMap.mMapWrite != null) + { + if (memMap.mMapWrite.ContainsKey(item.Key)) + { + dataConf currMem = memMap.mMapWrite[item.Key]; + string addr = currMem.memAddr; + taskVal = $"SET task: {item.Key} --> {newVal} | mem: {currMem.memAddr} - {currMem.size} byte"; + // salvo il nuovo valore nella memoria... così prox invio lo trasmetterà + memMap.mMapWrite[item.Key].value = newVal; + } + else + { + taskVal = $"NO DATA MEM, SET task: {item.Key} --> {newVal} ({item.Value})"; + } + } + else + { + taskVal = $"NO MemMap found, SET task: {item.Key} --> {newVal} ({item.Value})"; + } + + // salvo in currProd.. + upsertKey(item.Key, newVal); + break; + + case taskType.nihil: + case taskType.fixStopSetup: + case taskType.sendWatchDogMes2Plc: + case taskType.startSetup: + case taskType.stopSetup: + taskVal = $"taskReq: {tName} | key: {item.Key} | val: {item.Value} | SKIPPED | NO EXEC"; + break; + + case taskType.forceResetPzCount: + // forzo sul SIM il valore a ZERO x l'IOB... + contapezziPLC = 0; + taskVal = "RESET contapezziPLC: 0"; + break; + + case taskType.forceSetPzCount: + // forzo sul SIM il valore pzCount dell'IOB... + int newPzCount = contapezziPLC; + bool fatto = int.TryParse(item.Value, out newPzCount); + if (fatto) + { + // forzo update + contapezziPLC = newPzCount; + taskVal = $"Set new contapezziPLC: {contapezziPLC}"; + } + break; + + case taskType.syncDbData: + processDataSync(); + lgInfo("Richiesta syncDbData"); + break; + + default: + taskVal = "SKIPPED | NO EXEC"; + break; + } + // aggiungo task! + taskDone.Add(item.Key, taskVal); + } + } + } + return taskDone; + } + + /// + /// Recupera e processa allarmi CNC... + /// + public override Dictionary getCncAlarms() + { + Dictionary outVal = new Dictionary(); + return outVal; + } + + /// + /// Recupero dati dinamici... + /// + public override Dictionary getDynData() + { + bool useLUT = true; + // valore non presente in vers default... se gestito fare override + Dictionary outVal = new Dictionary(); + // verificare periodo SIM parametri... se passato li invio altrimenti NO... FIX a 20 sec + if (lastSimData.AddSeconds(waitSimPar) < DateTime.Now) + { + Random rnd = new Random(); + // controllo conf memorie json (se ci sono...) + try + { + if (memMap.mMapWrite.Count > 0) + { + foreach (var item in memMap.mMapWrite) + { + if (useLUT) + { + saveValueString(ref outVal, item.Key, item.Value.value); + } + else + { + outVal.Add(item.Key, item.Value.value); + } + } + } + if (memMap.mMapRead.Count > 0) + { + foreach (var item in memMap.mMapRead) + { + // se il TIPO di valore è livello --> simulo variazione da MAX --> min, + // con un delta in CALO pari a factor * (80-120)% + if (item.Value.name == "SIM_LEVEL") + { + // verifico last value + double lastVal = 0; + double.TryParse(item.Value.value, out lastVal); + if (lastVal == 0) + { + lastVal = item.Value.maxVal - (double)item.Value.factor; + } + // decremento casuale... + double newVal = lastVal - ((double)item.Value.factor * rnd.Next(40, 120) / 100); + // se inferiore a minimo --> massimo! + if (newVal < item.Value.minVal) + { + newVal = item.Value.maxVal; + } + // salvo il suo VALUE... + item.Value.value = $"{newVal}"; + if (useLUT) + { + saveValue(ref outVal, item.Key, newVal); + } + else + { + outVal.Add(item.Key, $"{newVal}"); + } + } + // altrimenti simulazione random walk... + else + { + double randVal = 0; + if (item.Value.factor == 1) + { + // uso factor come valore MAX ammesso + randVal = rnd.Next(item.Value.minVal, item.Value.maxVal); + } + else + { + // uso factor come fattore di divisione x simulare decimali + randVal = ((float)rnd.Next(item.Value.minVal, item.Value.maxVal)) / (float)item.Value.factor; + } + // verifico uso LUT + if (useLUT) + { + saveValue(ref outVal, item.Key, randVal); + } + else + { + outVal.Add(item.Key, $"{randVal}"); + } + } + } + } + } + catch + { } + lastSimData = DateTime.Now; + } + return outVal; + } + + /// + /// Recupero programma in lavorazione + /// + /// + public override string getPrgName() + { + // NOME DEL SIM! + string prgName = $"PROG_{cIobConf.codIOB}"; + return prgName; + } + + /// + /// Recupero info sistema generiche + /// + /// + public override Dictionary getSysInfo() + { + // valore non presente in vers default... se gestito fare override + Dictionary outVal = new Dictionary(); + outVal.Add("MACHINE", "IOB_SIM"); + return outVal; + } + + /// + /// Effettua vero processing contapezzi + /// + public override void processContapezzi() + { + } + + /// + /// Processo contatori eventi... + /// + public override void processVHF() + { + if (lastEvCheck.AddMilliseconds(periodoMSec) < DateTime.Now) + { + // decremento contatore ultimo evento + try + { + if (bit2 != null) + bit2.wait--; + + if (bit3 != null) + bit3.wait--; + + if (bit4 != null) + bit4.wait--; + + if (bit5 != null) + bit5.wait--; + + if (simDich != null) + simDich.wait--; + + if (simRC != null) + simRC.wait--; + + if (simRS != null) + simRS.wait--; + } + catch + { } + lastEvCheck = DateTime.Now; + } + } + + /// + /// Effettua lettura semafori principale Parametri da + /// aggiornare x display in form + /// + public override void readSemafori(ref newDisplayData currDispData) + { + base.readSemafori(ref currDispData); + + // controlo SE sia disabilitata simulazione principale + if (!disableSimStatus) + { + // decodifica e gestione + decodeToBaseBitmap(); + decodeOtherData(); + reportRawInput(ref currDispData); + } + } + + /// + /// Effettua reset del contapezzi + /// + /// + public override bool resetContapezziPLC() + { + bool answ = false; + // ...SE abilitato da conf IOB + if (cIobConf.optPar.Count > 0 && getOptPar("ENABLE_PZ_RESET") == "TRUE") + { + // fingo di aver fatto... + answ = true; + } + return answ; + } + + public override void tryConnect() + { + base.tryConnect(); + connectionOk = true; + } + + public override void tryDisconnect() + { + base.tryDisconnect(); + connectionOk = false; + } + + /// + /// Formatta URL x invio in DataBlock Json dei dati FLog / eventi OVERRIDE x invio come tav + /// 1/2 per USER LOG.... + /// + /// + /// + public override string urlDataBlock(urlType tipoUrl) + { + // recupero tipo base + string answ = base.urlDataBlock(tipoUrl); + // se fosse una macchina doppio pallet... + if (isMulti) + { + // SOLO x la parte USER LOG + switch (tipoUrl) + { + case urlType.ULog: + string[] elencoMulti = null; + // devo chiamare cambio ODL x OGNI tavola: mi servono i parametri opzionali... + string IOB_MULTI_CNAME = getOptPar("IOB_MULTI_CNAME"); + elencoMulti = IOB_MULTI_CNAME.Split(','); + // aggiungo tav 1 / 2 a caso secondo secondi attuali, se pari/dispari + int idxTav = DateTime.Now.Second % 2; + answ += $"#{elencoMulti[idxTav]}"; + break; + + default: + break; + } + } + return answ; + } + + #endregion Public Methods + + #region Protected Fields + + /// + /// Parametri simulazione oscillazione bit 2 + /// + protected simPar bit2; + + /// + /// Parametri simulazione oscillazione bit 3 + /// + protected simPar bit3; + + /// + /// Parametri simulazione oscillazione bit 4 + /// + protected simPar bit4; + + /// + /// Parametri simulazione oscillazione bit 5 + /// + protected simPar bit5; + + /// + /// Parametri simulazione oscillazione bit 6 + /// + protected simPar bit6; + + /// + /// Parametri simulazione oscillazione bit 7 + /// + protected simPar bit7; + + /// + /// pallet corrente + /// + protected int cP = 1; + + protected bool disableSimStatus = false; + + /// + /// ultimo controllo decremento eventi + /// + protected DateTime lastEvCheck; + + /// + /// Ultimo istante in cui sono stati ridotti dati simulazione duration + /// + protected DateTime lastRedDuration; + + /// + /// Ultimo istante in cui sono stati generati dati di simulazione + /// + protected DateTime lastSimData; + + /// + /// Cartella logfile x test import (tipo Soitaab) + /// + protected string logDirPath = "C:\\MesData\\TestSoitaab"; + + /// + /// Matricola OPR simulato + /// + protected int matrOpr = 1; + + /// + /// Durata minima ODL x reset quando pezzi iob > pezzi macchina... + /// + protected int minDurataODL = 480; + + /// + /// pallet successivo (next) + /// + protected int nP = 1; + + /// + /// periodo base del simulatore (in millisecondi) + /// + protected int periodoMSec = 1000; + + protected bool sendFluxOnRead = false; + + /// + /// variabile di appoggio x stato segnale contapezzo + /// + protected bool sigPzCount = false; + + /// + /// Simulazione registrazione dichiarazioni utente + /// + protected simPar simDich; + + /// + /// BOOL: indica se simulare powerOn/Off (bit 0 e 1) compresi WarmUp e CoolDown + /// + protected bool simPowerOnOff; + + /// + /// Simulazione effettuazione controlli utente + /// + protected simPar simRC; + + /// + /// Simulazione registro scarti utente + /// + protected simPar simRS; + + /// + /// Tempo di MINIMO attesa x simulazione parametri + /// + protected int waitSimPar = utils.CRI("waitSimPar"); + + #endregion Protected Fields + + #region Protected Methods + + /// + /// Recupera file log da analizzare + /// + /// + protected override bool getRemoteLog() + { + bool answ = false; + + // leggo direttamente il file di test in area C:\MesData\TestSoitaab + if (Directory.Exists(logDirPath)) + { + string filePath = Path.Combine(logDirPath, $"Report-{DateTime.Today.Day}.txt"); + bool hasDaily = File.Exists(filePath); + // cerco file quotidiano... + if (!hasDaily) + { + var fileList = Directory.GetFiles(logDirPath, "Report-*.txt"); + DateTime lastMod = DateTime.Today.AddYears(-1); + foreach (var cFile in fileList) + { + var tempFile = Path.Combine(logDirPath, cFile); + var lwTime = File.GetLastWriteTime(tempFile); + if (lwTime >= lastMod) + { + lastMod = lwTime; + filePath = tempFile; + } + } + } + // leggo file + string rawVal = File.ReadAllText(Path.Combine(logDirPath, filePath)); + if (!string.IsNullOrEmpty(rawVal)) + { + // salvo in redis + string redKey = redisMan.redHash($"IOB:CurrData:{cIobConf.codIOB}:LogFile:Act"); + redisMan.setRSV(redKey, rawVal); + answ = true; + } + } + return answ; + } + + /// + /// Recupera da server set di dati specifici x IOB : qui per testare + /// - versione std: compilazione files CSV (ex FTP Cimolai) + /// - versione Kepware: test recupero parametri ricetta + /// + /// + protected override bool iobGetDataFromServer() + { + bool answ = false; + if (!string.IsNullOrEmpty(getOptPar("SIM_KWP"))) + { + answ = iobGetSendDossierKepware(); + } + else + { + answ = iobGetDataFromServerToFtp(); + } + return answ; + } + + /// + /// Salvo valori PLC + /// + /// + protected override void plcWriteParams(ref List updatedPar) + { + dataConf currMem = null; + int byteSize = 0; + byte[] MemBlock = new byte[1]; + string memAddrWrite = ""; + string serObj = ""; + if (updatedPar != null) + { + // controllo i parametri... ne gestisco 4... + foreach (var item in updatedPar) + { + try + { + memAddrWrite = ""; + // cerco in area memMapWrite... + if (memMap.mMapWrite.ContainsKey(item.uid)) + { + // recupero! + currMem = memMap.mMapWrite[item.uid]; + byteSize = currMem.size; + memAddrWrite = currMem.memAddr; + // salvo in memMap... + currMem.value = item.reqValue; + // registro x invio + item.value = item.reqValue; + item.reqValue = ""; + + MemBlock = new byte[byteSize]; + serObj = JsonConvert.SerializeObject(item, Formatting.Indented); + lgInfo($"Inizio processing plcWriteParams per {currMem.name} | valore richiesto {currMem.value}{Environment.NewLine}---------------UPDATED PARAM---------------{Environment.NewLine}{serObj}{Environment.NewLine}---------------"); + serObj = JsonConvert.SerializeObject(currMem, Formatting.Indented); + lgInfo($"---------------MEMORY CONTENT---------------{Environment.NewLine}{serObj}{Environment.NewLine}---------------"); + lgInfo($"---------------MemBlock data---------------{Environment.NewLine}{BitConverter.ToString(MemBlock)}{Environment.NewLine}--------------- END data ---------------"); + + // salvo + upsertKey(item.uid, item.value); + } + else + { + lgInfo($"Errore uid non trovato in area write memory: {item.uid}, ci sono {memMap.mMapWrite.Count} in area write"); + } + } + catch (Exception exc) + { + lgError($"Eccezione in fase di plcWriteParams per item {item.uid} con valore {item.value}{Environment.NewLine}{exc}"); + } + } + } + } + + /// + /// Effettua sync dati + /// + protected override void processDataSync() + { + try + { + // fixme todo: test scrittura file csv... + var taskGet = iobGetDataFromServer(); + var taskWrite = iobWriteLocalCSV(); + var taskSend = iobSendFTP(""); + // richiesta check autoODL + processAutoOdl(); + // richiesta generazione quotidiana dossiers + processAutoDossier(); + // effettua gestione import file... + processFileImport(); + // effettua process ritorno ricette + processRecipeFileRet(); + } + catch (Exception exc) + { + lgError($"Eccezione in processDataSync:{Environment.NewLine}{exc}"); + } + } + + /// + /// Decremento duration del bit indicato secondo stesse regole di ritardo dei bit di wait + /// + /// + protected void tryRedDuration(int bit2proc) + { + if (lastRedDuration.AddMilliseconds(periodoMSec / 20) < DateTime.Now) + { + switch (bit2proc) + { + case 2: + bit2.duration--; + break; + + case 3: + bit3.duration--; + break; + + case 4: + bit4.duration--; + break; + + case 5: + bit5.duration--; + break; + + case 6: + bit6.duration--; + break; + + case 7: + bit7.duration--; + break; + + default: + break; + } + lastRedDuration = DateTime.Now; + } + } + + #endregion Protected Methods + + #region Private Fields + + private List alarmMessages = new List(); + + private int currSimAlarmCode = 0; + + private Random rnd = new Random(); + + #endregion Private Fields + + #region Private Methods + + /// + /// Decodifica signal log x soitaab | FixMe ToDo: eliminare + /// + /// + /// + private static int decodeSoitaabLog(string val2test) + { + // di default NON EMERGENZA... + int valInt = 128; + switch (val2test) + { + case "START;1": + valInt = 1 + 2 + 128; + break; + + case "END;1": + valInt = 1 + 128; + break; + + case "START;0": + case "END;0": + case "HOLD;": + valInt = 1 + 16 + 128; + break; + + default: + break; + } + + return valInt; + } + + /// + /// Decodifica il resto dell'area x i dati accessori (allarmi, ...) + /// + private void decodeOtherData() + { + } + + /// + /// Effettua decodifica aree memoria alla bitmap usata x MAPO + /// + private void decodeToBaseBitmap() + { + // init a zero... + B_input = 0; + bool sendContapezzi = false; + /* ----------------------------------------------------- + * bitmap MAPO + * B0: POWER_ON + * B1: RUN + * B2: pzCount + * B3: allarme + * B4: manuale + * B5: allarme TCiclo (SLOW) + * B6: WarmUp_CoolDown + * B7: EmergArmed (1 = NON emergenza, 0 = emergenza) + * B8: pallet 1 (SE doppio pallet) + * B9: pallet 2 (SE doppio pallet) + ----------------------------------------------------- */ + + // di base macchina in RUN + B_input = 3; + + /*---------------------------------------- + * Simulazione segnali con priorità: + * - Power ON / OFF (bit0/1) + * - ALLARMI + * - MANUALE + * - SLOW + * - contapezzi + * - emergenza + * + *----------------------------------------*/ + + // se simulo PowerOn/Off --> spegnimento con CoolDown e accensione con WarmUp.. + if (simPowerOnOff) + { + DateTime adesso = DateTime.Now; + // se l'orario è dopo le tOff (tipicamente 22) --> NO RUN... + if (adesso.Hour >= tOff || adesso.Hour <= tOn) + { + // se prima/ultima mezz'ora è ancora accesa NON in run... + if (adesso.AddMinutes(-30).Hour < tOff || adesso.AddMinutes(30).Hour > tOn) + { + B_input = 1; + } + else + { + B_input = 0; + } + // aggiungo NON emergenza... + B_input += (1 << 7); + } + } + // in primis verifico SE posso inviare in blocco i pezzi...... SE MP online e SE NON E' MULTI + if (MPOnline) + { + // SE IOB online... + if (IobOnline) + { + // se il contapezzi è OLTRE il valore inviato.... + if (contapezziPLC > contapezziIOB) + { + string machName = ""; + if (isMulti) + { + machName = $"{cIobConf.codIOB}|TAV_{nP}"; + } + // invio SOLO SE sono OLTRE i numSim pz e li invio TUTTI in blocco + if ((contapezziPLC - contapezziIOB) > minSendPzCountBlock) + { + sigPzCount = true; + trySendPzCountBlock(machName); + sigPzCount = false; + } + // altrimenti invio 1 segnale + else + { + // se NON STAVA inviando di già... + if (!sigPzCount) + { + // segnalo BIT (1 pz) + B_input += (1 << 2); + sigPzCount = true; + // salvo nuovo contapezzi (incremento di 1...) + richiesta refresh conteggio + contapezziIOB++; + needRefreshPzCount = true; + // invio conferma contapezzi.. + string fullUrl = $"{urlSetPzCount}{contapezziIOB}"; + if (isMulti) + { + fullUrl = $"{urlSetPzCount.Replace(cIobConf.codIOB, $"{cIobConf.codIOB}|TAV_{nP}")}{contapezziPLC}"; + } + string retVal = utils.callUrl(fullUrl); + // verifica salvataggio + if (retVal != contapezziIOB.ToString()) + { + // errore salvataggio contapezzi + lgInfo($"Errore salvataggio Contapezzi SIMULA 01: contapezziIOB {contapezziIOB} | risposta: {retVal}"); + // rileggo il counter pezzi da server + pzCntReload(true, machName); + } + } + else + { + string retVal = utils.callUrl($"{urlSetPzCount}{contapezziIOB}"); + if (retVal != contapezziIOB.ToString()) + { + // errore salvataggio contapezzi + lgInfo($"Errore salvataggio Contapezzi SIMULA 02: contapezziIOB {contapezziIOB} | risposta: {retVal}"); + if (!isMulti) + { + // rileggo il counter pezzi da server + pzCntReload(true, machName); + } + } + sigPzCount = false; + } + } + lgInfo($"S01: Valori contatori: contapezzi macchina contapezziPLC: {contapezziPLC} | contapezziIOB: {contapezziIOB} | contapezziPLC > contapezziIOB"); + } + } + else + { + // imposto currODL a vuoto! + currODL = ""; + if (periodicLog) + { + lgInfo($"SIMULA | Lettura ODL non effettuata: IobOnline: {IobOnline} | currODL impostato a vuoto"); + } + } + } + + // questa parte la processo SOLO SE sono in run --> B_input == 3 + if (B_input == 3 || B_input == 7) + { + // di base NON emergenza + B_input += (1 << 7); + // ora controllo il resto... + if (bit3 != null && bit3.wait <= 0) + { + // segnalo BIT + B_input += (1 << 3); + // se non ancora fatto, simulo insorgenza allarme + if (currSimAlarmCode == 0) + { + // simulo una bitmap di max 8 allarmi, 1..255 + currSimAlarmCode = rnd.Next(1, 255); + // invio allarme, 0 --> sim + sendAlarmVariations("SIM_BANK", 0, 0, (uint)currSimAlarmCode, alarmMessages); + } + // decremento duration + tryRedDuration(3); + // controllo se sia scaduta la duration... in quel caso reset... + if (bit3.duration <= 0) + { + bit3 = setupSimPar("SIM_ALARM"); + // invio fine allarme: sim --> 0 + sendAlarmVariations("SIM_BANK", 0, (uint)currSimAlarmCode, 0, alarmMessages); + // simulo terminazione allarme + currSimAlarmCode = 0; + } + + tryConfirm(); + } + else if (bit6 != null && bit6.wait <= 0) + { + // segnalo BIT + B_input += (1 << 6); + // decremento duration + tryRedDuration(6); + // controllo se sia scaduta la duration... in quel caso reset... + if (bit6.duration <= 0) + { + bit6 = setupSimPar("SIM_WUCD"); + } + // in warm up: provo split ODL + processAutoOdl(); + } + else if (bit7 != null && bit7.wait <= 0) + { + // segnalo BIT NEGATO (emergenza) + B_input -= (1 << 7); + // decremento duration + tryRedDuration(7); + // controllo se sia scaduta la duration... in quel caso reset... + if (bit7.duration <= 0) + { + bit7 = setupSimPar("SIM_EMRG"); + } + // in emergenza: provo split ODL + processAutoOdl(); + } + else if (bit4 != null && bit4.wait <= 0) + { + // segnalo BIT + B_input += (1 << 4); + // decremento duration + tryRedDuration(4); + // controllo se sia scaduta la duration... in quel caso reset... + if (bit4.duration <= 0) + { + bit4 = setupSimPar("SIM_MANU"); + } + // in manuale: provo split ODL + processAutoOdl(); + } + else if (bit2 != null && bit2.wait <= 0) + { + // salvo nuovo contapezziPLC + var rand = new Random(); + // se online vero delta (1..10) altrimenti 1 + int delta = IobOnline ? rand.Next(1, 10) : 1; + if (MPOnline) + { + // solo se MP online... + contapezziPLC += delta; + lgInfo($"S01: Valori contatori: contapezzi macchina contapezziPLC: {contapezziPLC} | contapezziIOB: {contapezziIOB} | aggiunto delta {delta}"); + } + // SOLO SE sono online... + if (IobOnline) + { + // se multipallet --> cP a zero! + if (isMulti) + { + cP = 0; + } + // se NON Multi fa contapezzi... + else + { + // SE NON SONO GIA' OLTRE il contapezzi + if (contapezziIOB < contapezziPLC) + { + // segnalo BIT (1 pz) + B_input += (1 << 2); + } + } + // decremento duration + tryRedDuration(2); + // controllo se sia scaduta la duration... in quel caso reset... + if (bit2.duration <= 0) + { + bit2 = setupSimPar("SIM_PZCNT"); + // salvo nuovo contapezzi (incremento di 1...) + richiesta refresh conteggio + contapezziIOB++; + needRefreshPzCount = true; + lgInfo($"S01: Valori contatori: contapezzi macchina contapezziPLC: {contapezziPLC} | contapezziIOB: {contapezziIOB} - incremento contapezzi per bit2.duration <= 0"); + // invio SOLO SE il contapezzi PLC è != contapezzi IOB... + if (contapezziPLC != contapezziIOB) + { + sendContapezzi = true; + } + } + if (sendContapezzi) + { + // controllo se ALMENO sia pingabile il server + if (checkServerAlive) + { + string fullUrl = $"{urlSetPzCount}{contapezziIOB}"; + // invio a server contapezzi (aggiornato) + if (isMulti) + { + fullUrl = $"{urlSetPzCount.Replace(cIobConf.codIOB, $"{cIobConf.codIOB}|TAV_{nP}")}{contapezziIOB}"; + } + string retVal = utils.callUrl(fullUrl); + // verifica se tutto OK + if (retVal != contapezziIOB.ToString()) + { + // errore salvataggio contapezzi + lgInfo($"Errore salvataggio Contapezzi SIMULA 03: contapezziIOB {contapezziIOB} | risposta: {retVal}"); + // se non sono multi... + if (!isMulti) + { + // rileggo il counter pezzi da server + pzCntReload(true); + } + } + // resetto timer... + lastPzCountSend = DateTime.Now; + } + } + // provo a fare split ODL... + processAutoOdl(); + } + else + { + // decremento duration + tryRedDuration(2); + if (bit2.duration <= 0) + { + bit2 = setupSimPar("SIM_PZCNT"); + } + } + } + else if (bit5 != null && bit5.wait <= 0 || tcMan.alarmDelayTC) + { + // segnalo BIT + B_input += (1 << 5); + // decremento duration + tryRedDuration(5); + // controllo se sia scaduta la duration... in quel caso reset... + if (bit5.duration <= 0) + { + bit5 = setupSimPar("SIM_SLOW"); + } + } + // se multi gestisco il bit delle tavole... + if (isMulti) + { + // se sono in fase di fronte d'uscita (invio contapezzi) INVERTO nP... + if (sendContapezzi) + { + nP = nP == 1 ? 2 : 1; + // assegno a cP il valore nP... + cP = nP; + contapezziPLC++; + // invio contapezzi... + string fullUrl = $"{urlSetPzCount.Replace(cIobConf.codIOB, $"{cIobConf.codIOB}|TAV_{nP}")}{contapezziIOB}"; + string retVal = utils.callUrl(fullUrl); + } + // se cP > 0 --> segnalo bit tavola... + if (cP == 1) + { + B_input += (1 << 8); + } + else if (cP == 2) + { + B_input += (1 << 9); + } + } + + // gestione simulazione utente + if (simRC != null && simRC.wait <= 0) + { + // preparo record controlli... guasto se mi esce un secondo divisibile x 25 + DateTime adesso = DateTime.Now; + int esitoNum = adesso.Second % 25 == 0 ? 0 : 1; + string note = esitoNum == 1 ? "" : $"SIM Controllo fallito alle {DateTime.Now:yyyy-MM-dd HH:mm:ss}"; + string sVal = $"MatrOpr: {matrOpr} | Esito: {esitoNum} | note: {note}"; + // accodo x invio + accodaUserLog(sVal, qEncodeULog("RC", note, matrOpr, "", esitoNum)); + // decremento duration + simRC.duration--; + // controllo se sia scaduta la duration... in quel caso reset... + if (simRC.duration <= 0) + { + simRC = setupSimPar("SIM_RC"); + } + } + if (simRS != null && simRS.wait <= 0) + { + // preparo record controlli... guasto se mi esce un secondo divisibile x 25 + DateTime adesso = DateTime.Now; + int causaleInt = adesso.Second % 7 + 1; + int numSca = adesso.Second % 5 + 1; + string causale = $"{causaleInt:00}"; + string note = $"SIM Scarto [{causale} x {numSca}] {DateTime.Now:yyyy-MM-dd HH:mm:ss}"; + string sVal = $"MatrOpr: {matrOpr} | Causale: {causale} | note: {note}"; + // accodo x invio + accodaUserLog(sVal, qEncodeULog("RS", note, matrOpr, causale, numSca)); + // decremento duration + simRS.duration--; + // controllo se sia scaduta la duration... in quel caso reset... + if (simRS.duration <= 0) + { + simRS = setupSimPar("SIM_RS"); + } + } + if (simDich != null && simDich.wait <= 0) + { + // preparo record dichiarazione... + DateTime adesso = DateTime.Now; + bool recLogin = adesso.Second % 5 == 0 ? false : true; + string note = recLogin ? "SIM Login Utente STEAMWARE USER" : $"SIM Nota automatica alle {DateTime.Now:yyyy-MM-dd HH:mm:ss}"; + string codTag = recLogin ? "UserLogin" : "Nota"; + string sVal = $"MatrOpr: {matrOpr} | codTag: {codTag} | nota: {note}"; + // accodo x invio + accodaUserLog(sVal, qEncodeULog("DI", note, matrOpr, codTag, 0)); + // decremento duration + simDich.duration--; + // controllo se sia scaduta la duration... in quel caso reset... + if (simDich.duration <= 0) + { + simDich = setupSimPar("SIM_DICH"); + } + } + + // init obj display + newDisplayData currDispData = new newDisplayData(); + currDispData.counter = contapezziIOB; + currDispData.semOut = Semaforo.SV; + raiseRefresh(currDispData); + } + } + + /// + /// Recupero dati da server x costruzione files CSV da inviare via FTP (ex: Cimolai) + /// + /// + private bool iobGetDataFromServerToFtp() + { + bool answ; + bool okArt = false; + bool okDoss = false; + bool okPodl = false; + bool okLVFasi = false; + List listaPODL = new List(); + List listaDoss = new List(); + List listaArt = new List(); + List anagLVFasi = new List(); + Dictionary dictAF = new Dictionary(); + // recupera dati da server tramite chiamate REST a MP/IO/IOB... + var rawListArt = callUrl(urlGetCurrArt, false); + var rawListDOSS = callUrl(urlGetCurrDOSS, false); + var rawListPODL = callUrl(urlGetCurrPODL, false); + var rawLVFasi = callUrl(urlGetListValFasiPodl, false); + if (!string.IsNullOrEmpty(rawListArt)) + { + try + { + listaArt = JsonConvert.DeserializeObject>(rawListArt); + okArt = listaArt.Count > 0; + } + catch (Exception exc) + { + lg.Error($"Errore: chiamata elenco ART ha restituito errore{Environment.NewLine}{exc}"); + } + } + else + { + lg.Error($"Errore: chiamata elenco ART ({urlGetCurrArt}) ha restituito valore vuoto"); + } + if (!string.IsNullOrEmpty(rawListDOSS)) + { + try + { + listaDoss = JsonConvert.DeserializeObject>(rawListDOSS); + okDoss = listaDoss.Count > 0; + } + catch (Exception exc) + { + lg.Error($"Errore: chiamata elenco DOSSIER ha restituito errore{Environment.NewLine}{exc}"); + } + } + else + { + lg.Error($"Errore: chiamata elenco DOSSIER ({urlGetCurrDOSS}) ha restituito valore vuoto"); + } + if (!string.IsNullOrEmpty(rawListPODL)) + { + try + { + listaPODL = JsonConvert.DeserializeObject>(rawListPODL); + okPodl = listaPODL.Count > 0; + } + catch (Exception exc) + { + lg.Error($"Errore: chiamata elenco DOSSIER ha restituito errore{Environment.NewLine}{exc}"); + } + } + else + { + lg.Error($"Errore: chiamata elenco PODL ({urlGetCurrPODL}) ha restituito valore vuoto"); + } + if (!string.IsNullOrEmpty(rawLVFasi)) + { + try + { + anagLVFasi = JsonConvert.DeserializeObject>(rawLVFasi); + dictAF = anagLVFasi.ToDictionary(x => x.value, x => x.label); + okLVFasi = listaArt.Count > 0; + } + catch (Exception exc) + { + lg.Error($"Errore: chiamata elenco ListVal ha restituito errore{Environment.NewLine}{exc}"); + } + } + else + { + lg.Error($"Errore: chiamata elenco ListVal ({urlGetListValFasiPodl}) ha restituito valore vuoto"); + } + answ = okPodl && okDoss && okArt && okLVFasi; + if (answ) + { + // predispongo dati PODL + ListaJobs = listaPODL + .Select(x => new JobRow() { Matricola = x.CodArticolo, Commessa = $"PODL{x.IdxPromessa:00000000}", Articolo = x.CodArticolo, Descrizione = x.CodArticolo, DataIns = $"{x.InsertDate:dd/MM/yyyy}", OraIns = $"{x.InsertDate:HH:mm}", Lavorazione = $"{getLV(dictAF, x.KeyRichiesta)} {x.Note}".Trim() }) + .ToList(); + + // predispongo dati articoli + ListaArticoli = listaArt + .Select(a => new ArtRow() { Matricola = a.CodArticolo, Articolo = a.Disegno, Descrizione = a.DescArticolo, LimiteVel = 100 }) + .Distinct() + .ToList(); + + // completo con dati DOSSIER + foreach (var item in ListaArticoli) + { + string codArt = item.Matricola; + var currDoss = listaDoss.Where(x => x.CodArticolo == codArt).FirstOrDefault(); + if (currDoss != null) + { + DossierFluxLogDTO resultSet = JsonConvert.DeserializeObject(currDoss.Valore); + // traduco AD MENTULAM... + item.Peso_01 = getFluxValInt(resultSet, "POS_X"); + item.Peso_02 = getFluxValInt(resultSet, "POS_Y"); + item.Peso_03 = getFluxValInt(resultSet, "RAPID_OVER"); + item.Peso_04 = getFluxValInt(resultSet, "POS_Z"); + item.PosizCarrello_01 = getFluxValInt(resultSet, "TEMP_01"); + item.PosizCarrello_02 = getFluxValInt(resultSet, "RAPID_OVER"); + item.PosizCarrello_03 = getFluxValInt(resultSet, "POWER_01"); + item.PosizCarrello_04 = getFluxValInt(resultSet, "POS_X"); + } + } + } + return answ; + } + + /// + /// Recupero dati da server x invio dati ricetta a KepWare (Ex RAMA x TFT) + /// + /// + private bool iobGetSendDossierKepware() + { + bool answ; + + lg.Info("iobGetSendDossier: Inizio scrittura dati a KepWare"); + /*----------------------------------------- + * STEPS processo: + * - recupero ARTICOLI (solo quelli dei PODL attivi) + * - recupero PODL (tutti) + * - recupero elenco DOSSIER last x macchina (legato ai PODL attivi) + * - prendo SOLO PODL attivi, e prendo il + vecchio + * - se trovo dossier x articolo del PODL + vecchio (e dovrebbe...) procedo + * - uso Dictionary RecipeKeyTranslate x tradurre l'elenco fluxLog in nuovi valori + * - preparo il set di valori da scrivere con traduzione + * - invio scritture (sim test --> scrivo su file?) + * - aggiungo info articolo (+ ODL...) + * - aggiungo il valore di "scrittura effettuata" + *----------------------------------------- */ + + bool okArt = false; + bool okDoss = false; + bool okPodl = false; + List listaArt = new List(); + List listaPODL = new List(); + List listaDoss = new List(); + // recupera dati da server tramite chiamate REST a MP/IO/IOB... + var rawListArt = callUrl(urlGetCurrArt, false); + var rawListDOSS = callUrl(urlGetCurrDOSS, false); + var rawListPODL = callUrl(urlGetCurrPODL, false); + if (!string.IsNullOrEmpty(rawListArt)) + { + try + { + listaArt = JsonConvert.DeserializeObject>(rawListArt); + okArt = listaArt.Count > 0; + } + catch (Exception exc) + { + lg.Error($"Errore: chiamata elenco ART ha restituito errore{Environment.NewLine}{exc}"); + } + } + else + { + lg.Error($"Errore: chiamata elenco ART ({urlGetCurrArt}) ha restituito valore vuoto"); + } + if (!string.IsNullOrEmpty(rawListDOSS)) + { + try + { + listaDoss = JsonConvert.DeserializeObject>(rawListDOSS); + okDoss = listaDoss.Count > 0; + } + catch (Exception exc) + { + lg.Error($"Errore: chiamata elenco DOSSIER ha restituito errore{Environment.NewLine}{exc}"); + } + } + else + { + lg.Error($"Errore: chiamata elenco DOSSIER ({urlGetCurrDOSS}) ha restituito valore vuoto"); + } + if (!string.IsNullOrEmpty(rawListPODL)) + { + try + { + listaPODL = JsonConvert.DeserializeObject>(rawListPODL); + okPodl = listaPODL.Count > 0; + } + catch (Exception exc) + { + lg.Error($"Errore: chiamata elenco DOSSIER ha restituito errore{Environment.NewLine}{exc}"); + } + } + else + { + lg.Error($"Errore: chiamata elenco PODL ({urlGetCurrPODL}) ha restituito valore vuoto"); + } + + answ = okArt && okPodl && okDoss; + if (answ) + { + // verifico i PODL attivi... + var listPodlAct = listaPODL.Where(x => x.Attivabile).OrderBy(x => x.InsertDate).ToList(); + if (listPodlAct.Count > 0) + { + string codArt = listPodlAct.FirstOrDefault().CodArticolo; + // verifico di avere il dossier e l'articolo x questo PODL + var selArt = listaArt.Where(x => x.CodArticolo == codArt).FirstOrDefault(); + var selDoss = listaDoss.Where(x => x.CodArticolo == codArt).FirstOrDefault(); + // prendo il primo e recupero... + if (selArt != null && selDoss != null) + { + // recupero il resultset dei valori FluxLog da caricare + DossierFluxLogDTO resultSet = JsonConvert.DeserializeObject(selDoss.Valore); + List listFluxLog = resultSet.ODL; + + // preparo elenco parametri da inviare... + ListaCalcParams = new List(); + // per ogni valore ricevuto nel dossier --> calcolo parametro da inviare + foreach (var item in listFluxLog) + { + objItem currData = new objItem() + { + // valori dentro OPC-UA + //uid = $"{opcUaParams.BaseKeyTranslate}{item.CodFlux}", + uid = item.CodFlux, + reqValue = item.Valore, + name = item.CodFlux + }; + + // aggiungo! + ListaCalcParams.Add(currData); + } + // effettua chiamata scrittura verso impianto... + plcWriteParams(ref ListaCalcParams); + } + } + } + return answ; + } + + /// + /// Esegue processing + invio dati tab SignLog | FixMe ToDo: eliminare + /// + /// + /// + private bool processFluxLogTable(DateTime adesso) + { + bool fatto = false; + // leggo eventuali dati di fluxlog ed invio... + if (fluxLogData != null && fluxLogData.Count > 0) + { + string sVal = ""; + foreach (var fLog2send in fluxLogData) + { + var kvpFlux = fLog2send.valString.Split(';'); + if (kvpFlux.Count() > 1) + { + sVal = $"[DYNDATA] |{fLog2send.dtRif:yyyy-MM-dd HH:mm:ss}|{kvpFlux[0]}|{kvpFlux[1]}"; + // chiamo accodamento con dataora corretta... + accodaFLog(sVal, qEncodeFLog(fLog2send.dtRif, kvpFlux[0], kvpFlux[1])); + } + } + // svuoto coda invio fluxlog... + fluxLogData = new List(); + // fatto! + fatto = true; + } + return fatto; + } + + /// + /// Esegue processing + invio dati tab SignLog + /// + /// + /// + private bool processSignLogTable(DateTime adesso) + { + bool fatto = false; + // init oggetto x processing + Dictionary sigLogFromFile = new Dictionary(); + // recupero i dati dai logs files, attuale e nuovo... + string fileAct = redisMan.getRSV(redKeyLogfileAct); + string fileLast = redisMan.getRSV(redKeyLogfileLast); + // confronto con i dati dell'ultimo LOG FILE processato + int lenghtAct = fileAct != null ? fileAct.Length : 0; + int lenghtLast = fileLast != null ? fileLast.Length : 0; + //if (lenghtAct > 0 && lenghtAct != lenghtLast) + if (lenghtAct > 0) + { + List logNew = new List(); + List sigLogData = new List(); + List logLast = getGenLogFromMachineLog(fileLast); + List logAct = getGenLogFromMachineLog(fileAct); + // SE c'è prendo ultima riga inviata x confronto... + var fileLastEnd = logLast.LastOrDefault(); + if (fileLastEnd != null) + { + // ora prendo SOLAMENTE le righe nuove + logNew = logAct + .Where(x => x.dtRif > fileLastEnd.dtRif) + .ToList(); + } + else + { + logNew = logAct; + } + // solo SE ho nuovi dati.... + if (logNew.Count > 0) + { + // processo le righe nuove e le accodo in redis come elenco FluxLog da inviare + // (appoggio in redis)... andando ad accodarle... + var currFLD = fluxLogData; + currFLD.AddRange(logNew); + fluxLogData = currFLD; + + // estraggo solo info x sig log + sigLogData = logNew + .Where(x => x.valString.StartsWith("START") || x.valString.StartsWith("HOLD") || x.valString.StartsWith("END")) + .OrderBy(x => x.dtRif) + .ToList(); + + // processo le righe nuove trasformando al volo SOLO eventi... + foreach (var sLog2send in sigLogData) + { + /* ----------------------------------------------------- + * bitmap MAPO STANDARD 60 + * B0: 001 POWER_ON + * B1: 002 RUN + * B2: 004 pzCount + * B3: 008 allarme + * B4: 016 manuale + * B5: 032 slowTC + * B6: 064 WarmUpCoolDown + * B7: 128 EmergArmata + * + ----------------------------------------------------- */ + + int valInt = decodeSoitaabLog(sLog2send.valString); + + string currVal = getEncodSigLog(sLog2send.dtRif, valInt, counterSigIN); + // verifico non sia in veto invio iniziale... + if (queueInEnabCurr) + { + // --> accodo (valore già formattato)! + QueueIN.Enqueue(currVal); + // loggo! + lgTrace(string.Format("[QUEUE-IN] {0}", currVal)); + counterSigIN++; + if (counterSigIN > 9999) + { + counterSigIN = 0; + } + } + else + { + lgDebug($"[VETO FOR QUEUE-IN] | {currVal} - MESSAGE NOT SENT | {adesso:yyyyMMdd_HHmmss}"); + checkVetoQueueIn(); + } + } + + /* ---------------------------------------------------------- + * processo righe x costruire una lista di eventi produzione: + * - elenco di eventi contapezzi + * - lista xODL come articolo + quantità prodotta (_1, _2, ...) + * - eventuale ultimo xODL che resta aperto + * + * successivamente processing + invio info raccolte + * - recupero PODL aperti + * - apertura/chiusura PODL esistenti + * - creazione PODL mancanti + * - dichiarazione contapezzi + * + * ---------------------------------------------------------- */ + + string sVal = ""; + string descrArt = ""; + List elencoProdBatch = new List(); + ProdBatchData lastProdBatch = new ProdBatchData(); + + // ora processo TUTTO x il generico caso fluxLog...... + foreach (var fLog2send in logNew) + { + // separo per ";" + var currData = fLog2send.valString.Split(';'); + if (currData.Length > 1) + { + if (sendFluxOnRead) + { + // per prima cosa fluxLog a prescindere... + sVal = $"[LOGFILE]{currData[0]}|{currData[1]}"; + // ...e chiamo accodamento + accodaFLog(sVal, qEncodeFLog(fLog2send.dtRif, currData[0], currData[1])); + } + + switch (currData[0]) + { + case "END": + // se è un end --> è comunque NON + running + isRunningState = false; // chiudo batch precedente + in elenco (SE era valido...) + if (!string.IsNullOrEmpty(lastProdBatch.codArt)) + { + lastProdBatch.dtEnd = fLog2send.dtRif; + elencoProdBatch.Add(lastProdBatch); + } + // reset articolo.. + lastArtDescr = ""; + // nuovo batch VUOTO + lastProdBatch = new ProdBatchData(); + contapezziPLC = 0; + break; + + case "START": + isRunningState = currData[1] == "1"; + break; + + case "PARTCODE": + // inizio confronto articolo con precedente x capire se sia NUOVO + descrArt = currData[1]; + // devo scartare i "doppi percorsi" + if (descrArt != lastArtDescr) + { + // verifico se sia DAVVERO cambiato articolo... prendo + // articolo senza indice (_1, _2, _3, ...) + var artDataLast = lastArtDescr.Split('_'); + var artDataNew = descrArt.Split('_'); + // nuovo articolo (NON vuoto) + if (!string.IsNullOrEmpty(artDataNew[0]) && artDataLast[0] != artDataNew[0]) + { + // chiudo batch precedente + in elenco (SE era valido...) + if (!string.IsNullOrEmpty(lastProdBatch.codArt)) + { + // chiudo prod + lastProdBatch.dtEnd = fLog2send.dtRif; + elencoProdBatch.Add(lastProdBatch); + } + // nuovo batch + lastProdBatch = new ProdBatchData() + { + codArt = artDataNew[0], + dtStart = fLog2send.dtRif, + numPz = 1 + }; + } + // solo nuova copia articolo + else + { + // aumento numPezzi batch + lastProdBatch.numPz++; + } + + // salvo nuovo art processato + lastArtDescr = descrArt; + } + break; + + default: + break; + } + } + } + + // recupero elenco PODL corrente... + List reqPOdlList = MachineNextPodl(); + // adesso processo tutti i prodBatch collezionati x invio + foreach (var item in elencoProdBatch) + { + int currIdxPOdl = 0; + // cerco se articolo sia in elenco PODL + var listPOdl = reqPOdlList + .Where(x => x.CodArticolo.Equals(item.codArt, StringComparison.InvariantCultureIgnoreCase)) + .ToList(); + + // se trovato --> invio start/stop PODL + if (listPOdl != null && listPOdl.Count > 0) + { + var currPodl = listPOdl.OrderBy(x => x.IdxPromessa).FirstOrDefault(); + if (currPodl != null) + { + currIdxPOdl = currPodl.IdxPromessa; + // elimino da elenco PODL + reqPOdlList.Remove(currPodl); + } + } + else + { + // se NON trovato --> creo PODL, poi avvio/chiudo + currIdxPOdl = TryCreatePodl(item.codArt, CodGruppoIob, item.numPz); + } + // se idxPOdl valido + if (currIdxPOdl > 0) + { + // mando apertura PODL + SendStartPodl(currIdxPOdl, item.dtStart); + // chiudo PODL... + if (item.dtEnd != null) + { + // invio pezzi 3 sec prima di chiusura + SendPzIncrAtDate(item.numPz, ((DateTime)item.dtEnd).AddSeconds(-3)); + // chiudo + SendClosePOdl(currIdxPOdl, (DateTime)item.dtEnd); + } + } + } + + // salvo in last il valore di act... + redisMan.setRSV(redKeyLogfileLast, fileAct); + } + fatto = true; + } + return fatto; + } + + /// + /// Setup parametri di simulazione per BIT indicato + /// + /// + private simPar setupSimPar(string keyName) + { + simPar answ = new simPar(); + if (cIobConf.optPar.Count > 0) + { + if (cIobConf.optPar.ContainsKey(keyName)) + { + string fullVal = getOptPar(keyName); + if (!string.IsNullOrEmpty(fullVal) && fullVal.IndexOf("|") > 0) + { + string[] param = fullVal.Split('|'); + int.TryParse(param[0], out answ.wait); + int.TryParse(param[1], out answ.duration); + // simulo valore wait: in media target, range +/- 80% + answ.wait = rnd.Next(answ.wait / 5, answ.wait * 9 / 5); + // simulo valore duration: in media target, range +/- 50% + answ.duration = rnd.Next(answ.duration / 2, answ.duration * 3 / 2); + // verifico siano > 0... + answ.wait = answ.wait > 1 ? answ.wait : 2; + answ.duration = answ.duration > 1 ? answ.duration : 2; + } + } + } + return answ; + } + + /// + /// Provo ad effettuare conferma pezzi SE sono oltre uno scalino del 10% dall'ultima conferma... + /// + /// + private void tryConfirm() + { + } + + /// + /// provo a chiamare split ODL + /// + private void trySplitOdl() + { + // solo se ODL è in lavorazione da ALMENO minDurataODL minuti... + DateTime inizioOdl = DateTime.Now.AddDays(-1); + string rawDataInizio = callUrl(urlInizioOdlIob, false); + DateTime.TryParse(rawDataInizio, out inizioOdl); + if (DateTime.Now.Subtract(inizioOdl).TotalMinutes > minDurataODL) + { + // invio reset ODL... + forceSplitOdl(); + } + } + + #endregion Private Methods + } +} \ No newline at end of file diff --git a/IOB-WIN-FORM/MainForm.Designer.cs b/IOB-WIN-FORM/MainForm.Designer.cs new file mode 100644 index 00000000..38122bb0 --- /dev/null +++ b/IOB-WIN-FORM/MainForm.Designer.cs @@ -0,0 +1,325 @@ +namespace IOB_WIN_FORM +{ + partial class MainForm + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.components = new System.ComponentModel.Container(); + System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm)); + this.statusStrip1 = new System.Windows.Forms.StatusStrip(); + this.lblApp = new System.Windows.Forms.ToolStripStatusLabel(); + this.lblVers = new System.Windows.Forms.ToolStripStatusLabel(); + this.MainProgrBar = new System.Windows.Forms.ToolStripProgressBar(); + this.lblComStats = new System.Windows.Forms.ToolStripStatusLabel(); + this.toolStripStatusLabel3 = new System.Windows.Forms.ToolStripStatusLabel(); + this.lblStatus = new System.Windows.Forms.ToolStripStatusLabel(); + this.toolStripStatusLabel1 = new System.Windows.Forms.ToolStripStatusLabel(); + this.tslRunTime = new System.Windows.Forms.ToolStripStatusLabel(); + this.menuStrip1 = new System.Windows.Forms.MenuStrip(); + this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.mCheckUpdates = new System.Windows.Forms.ToolStripMenuItem(); + this.mShowMainLog = new System.Windows.Forms.ToolStripMenuItem(); + this.closeChildToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.closeALLAdaptersToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.restartALLAdaptersToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.uploadIOBConfToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.downloadIOBConfToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.sendIOBAssignmentsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.getIOBAssignmentsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.windowToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.arrangeWindowsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.minimizeALLToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.MainTimer = new System.Windows.Forms.Timer(this.components); + this.notifyIcon1 = new System.Windows.Forms.NotifyIcon(this.components); + this.trayMenu = new System.Windows.Forms.ContextMenuStrip(this.components); + this.statusStrip1.SuspendLayout(); + this.menuStrip1.SuspendLayout(); + this.SuspendLayout(); + // + // statusStrip1 + // + this.statusStrip1.ImageScalingSize = new System.Drawing.Size(20, 20); + this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { + this.lblApp, + this.lblVers, + this.MainProgrBar, + this.lblComStats, + this.toolStripStatusLabel3, + this.lblStatus, + this.toolStripStatusLabel1, + this.tslRunTime}); + this.statusStrip1.Location = new System.Drawing.Point(0, 507); + this.statusStrip1.Name = "statusStrip1"; + this.statusStrip1.Padding = new System.Windows.Forms.Padding(1, 0, 10, 0); + this.statusStrip1.Size = new System.Drawing.Size(713, 23); + this.statusStrip1.TabIndex = 1; + this.statusStrip1.Text = "statusStrip1"; + // + // lblApp + // + this.lblApp.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold); + this.lblApp.Name = "lblApp"; + this.lblApp.Size = new System.Drawing.Size(22, 18); + this.lblApp.Text = "---"; + // + // lblVers + // + this.lblVers.Name = "lblVers"; + this.lblVers.Size = new System.Drawing.Size(16, 18); + this.lblVers.Text = "..."; + // + // MainProgrBar + // + this.MainProgrBar.Name = "MainProgrBar"; + this.MainProgrBar.Size = new System.Drawing.Size(75, 17); + this.MainProgrBar.Step = 1; + this.MainProgrBar.Style = System.Windows.Forms.ProgressBarStyle.Marquee; + // + // lblComStats + // + this.lblComStats.Name = "lblComStats"; + this.lblComStats.Size = new System.Drawing.Size(32, 18); + this.lblComStats.Text = "Stats"; + // + // toolStripStatusLabel3 + // + this.toolStripStatusLabel3.Name = "toolStripStatusLabel3"; + this.toolStripStatusLabel3.Size = new System.Drawing.Size(10, 18); + this.toolStripStatusLabel3.Text = "|"; + // + // lblStatus + // + this.lblStatus.Name = "lblStatus"; + this.lblStatus.Size = new System.Drawing.Size(22, 18); + this.lblStatus.Text = "---"; + // + // toolStripStatusLabel1 + // + this.toolStripStatusLabel1.Name = "toolStripStatusLabel1"; + this.toolStripStatusLabel1.Size = new System.Drawing.Size(10, 18); + this.toolStripStatusLabel1.Text = "|"; + // + // tslRunTime + // + this.tslRunTime.Name = "tslRunTime"; + this.tslRunTime.Size = new System.Drawing.Size(16, 18); + this.tslRunTime.Text = "..."; + // + // menuStrip1 + // + this.menuStrip1.ImageScalingSize = new System.Drawing.Size(20, 20); + this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { + this.fileToolStripMenuItem, + this.closeChildToolStripMenuItem, + this.windowToolStripMenuItem}); + this.menuStrip1.Location = new System.Drawing.Point(0, 0); + this.menuStrip1.Name = "menuStrip1"; + this.menuStrip1.Padding = new System.Windows.Forms.Padding(4, 2, 0, 2); + this.menuStrip1.Size = new System.Drawing.Size(713, 24); + this.menuStrip1.TabIndex = 2; + this.menuStrip1.Text = "menuStrip1"; + // + // fileToolStripMenuItem + // + this.fileToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { + this.mCheckUpdates, + this.mShowMainLog}); + this.fileToolStripMenuItem.Name = "fileToolStripMenuItem"; + this.fileToolStripMenuItem.Size = new System.Drawing.Size(37, 20); + this.fileToolStripMenuItem.Text = "&File"; + // + // mCheckUpdates + // + this.mCheckUpdates.Name = "mCheckUpdates"; + this.mCheckUpdates.Size = new System.Drawing.Size(186, 22); + this.mCheckUpdates.Text = "Check for &Updates"; + this.mCheckUpdates.Click += new System.EventHandler(this.mCheckUpdates_Click); + // + // mShowMainLog + // + this.mShowMainLog.Name = "mShowMainLog"; + this.mShowMainLog.Size = new System.Drawing.Size(186, 22); + this.mShowMainLog.Text = "Open &LogFile (MAIN)"; + this.mShowMainLog.Click += new System.EventHandler(this.MShowMainLog_Click); + // + // closeChildToolStripMenuItem + // + this.closeChildToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { + this.closeALLAdaptersToolStripMenuItem, + this.restartALLAdaptersToolStripMenuItem, + this.uploadIOBConfToolStripMenuItem, + this.downloadIOBConfToolStripMenuItem, + this.sendIOBAssignmentsToolStripMenuItem, + this.getIOBAssignmentsToolStripMenuItem}); + this.closeChildToolStripMenuItem.Name = "closeChildToolStripMenuItem"; + this.closeChildToolStripMenuItem.Size = new System.Drawing.Size(121, 20); + this.closeChildToolStripMenuItem.Text = "A&dapters Functions"; + // + // closeALLAdaptersToolStripMenuItem + // + this.closeALLAdaptersToolStripMenuItem.Name = "closeALLAdaptersToolStripMenuItem"; + this.closeALLAdaptersToolStripMenuItem.Size = new System.Drawing.Size(203, 22); + this.closeALLAdaptersToolStripMenuItem.Text = "&Close ALL Adapters"; + this.closeALLAdaptersToolStripMenuItem.Click += new System.EventHandler(this.closeALLAdaptersToolStripMenuItem_Click); + // + // restartALLAdaptersToolStripMenuItem + // + this.restartALLAdaptersToolStripMenuItem.Name = "restartALLAdaptersToolStripMenuItem"; + this.restartALLAdaptersToolStripMenuItem.ShortcutKeyDisplayString = "ALT-R"; + this.restartALLAdaptersToolStripMenuItem.ShowShortcutKeys = false; + this.restartALLAdaptersToolStripMenuItem.Size = new System.Drawing.Size(203, 22); + this.restartALLAdaptersToolStripMenuItem.Text = "&Restart ALL Adapters"; + this.restartALLAdaptersToolStripMenuItem.Click += new System.EventHandler(this.restartALLAdaptersToolStripMenuItem_Click); + // + // uploadIOBConfToolStripMenuItem + // + this.uploadIOBConfToolStripMenuItem.Name = "uploadIOBConfToolStripMenuItem"; + this.uploadIOBConfToolStripMenuItem.Size = new System.Drawing.Size(203, 22); + this.uploadIOBConfToolStripMenuItem.Text = "Upload IOB Conf files"; + this.uploadIOBConfToolStripMenuItem.Click += new System.EventHandler(this.uploadIOBConfToolStripMenuItem_Click); + // + // downloadIOBConfToolStripMenuItem + // + this.downloadIOBConfToolStripMenuItem.Name = "downloadIOBConfToolStripMenuItem"; + this.downloadIOBConfToolStripMenuItem.Size = new System.Drawing.Size(203, 22); + this.downloadIOBConfToolStripMenuItem.Text = "Download IOB Conf files"; + this.downloadIOBConfToolStripMenuItem.Click += new System.EventHandler(this.downloadIOBConfToolStripMenuItem_Click); + // + // sendIOBAssignmentsToolStripMenuItem + // + this.sendIOBAssignmentsToolStripMenuItem.Enabled = false; + this.sendIOBAssignmentsToolStripMenuItem.Name = "sendIOBAssignmentsToolStripMenuItem"; + this.sendIOBAssignmentsToolStripMenuItem.Size = new System.Drawing.Size(203, 22); + this.sendIOBAssignmentsToolStripMenuItem.Text = "Send IOB Assignments"; + this.sendIOBAssignmentsToolStripMenuItem.Click += new System.EventHandler(this.sendIOBAssignmentsToolStripMenuItem_Click); + // + // getIOBAssignmentsToolStripMenuItem + // + this.getIOBAssignmentsToolStripMenuItem.Enabled = false; + this.getIOBAssignmentsToolStripMenuItem.Name = "getIOBAssignmentsToolStripMenuItem"; + this.getIOBAssignmentsToolStripMenuItem.Size = new System.Drawing.Size(203, 22); + this.getIOBAssignmentsToolStripMenuItem.Text = "Get IOB Assignments"; + this.getIOBAssignmentsToolStripMenuItem.Click += new System.EventHandler(this.getIOBAssignmentsToolStripMenuItem_Click); + // + // windowToolStripMenuItem + // + this.windowToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { + this.arrangeWindowsToolStripMenuItem, + this.minimizeALLToolStripMenuItem}); + this.windowToolStripMenuItem.Name = "windowToolStripMenuItem"; + this.windowToolStripMenuItem.Size = new System.Drawing.Size(63, 20); + this.windowToolStripMenuItem.Text = "&Window"; + // + // arrangeWindowsToolStripMenuItem + // + this.arrangeWindowsToolStripMenuItem.Name = "arrangeWindowsToolStripMenuItem"; + this.arrangeWindowsToolStripMenuItem.Size = new System.Drawing.Size(184, 22); + this.arrangeWindowsToolStripMenuItem.Text = "Re-arran&ge Windows"; + this.arrangeWindowsToolStripMenuItem.Click += new System.EventHandler(this.arrangeWindowsToolStripMenuItem_Click); + // + // minimizeALLToolStripMenuItem + // + this.minimizeALLToolStripMenuItem.Name = "minimizeALLToolStripMenuItem"; + this.minimizeALLToolStripMenuItem.Size = new System.Drawing.Size(184, 22); + this.minimizeALLToolStripMenuItem.Text = "&Minimize ALL"; + this.minimizeALLToolStripMenuItem.Click += new System.EventHandler(this.minimizeALLToolStripMenuItem_Click); + // + // MainTimer + // + this.MainTimer.Enabled = true; + this.MainTimer.Interval = 20; + this.MainTimer.Tick += new System.EventHandler(this.MainTimer_Tick); + // + // notifyIcon1 + // + this.notifyIcon1.ContextMenuStrip = this.trayMenu; + this.notifyIcon1.Text = "IOB-WIN-NEXT"; + this.notifyIcon1.Visible = true; + this.notifyIcon1.DoubleClick += new System.EventHandler(this.notifyIcon1_DoubleClick); + // + // trayMenu + // + this.trayMenu.ImageScalingSize = new System.Drawing.Size(20, 20); + this.trayMenu.Name = "trayMenu"; + this.trayMenu.Size = new System.Drawing.Size(61, 4); + this.trayMenu.ItemClicked += new System.Windows.Forms.ToolStripItemClickedEventHandler(this.trayMenu_ItemClicked); + // + // MainForm + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(713, 530); + this.Controls.Add(this.statusStrip1); + this.Controls.Add(this.menuStrip1); + this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); + this.IsMdiContainer = true; + this.MainMenuStrip = this.menuStrip1; + this.Margin = new System.Windows.Forms.Padding(2); + this.Name = "MainForm"; + this.Text = "IOB WIN 2025"; + this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.MainForm_FormClosing); + this.Shown += new System.EventHandler(this.MainForm_Shown); + this.Resize += new System.EventHandler(this.MainForm_Resize); + this.statusStrip1.ResumeLayout(false); + this.statusStrip1.PerformLayout(); + this.menuStrip1.ResumeLayout(false); + this.menuStrip1.PerformLayout(); + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + + private System.Windows.Forms.StatusStrip statusStrip1; + private System.Windows.Forms.MenuStrip menuStrip1; + private System.Windows.Forms.ToolStripMenuItem fileToolStripMenuItem; + private System.Windows.Forms.ToolStripMenuItem mCheckUpdates; + private System.Windows.Forms.ToolStripMenuItem windowToolStripMenuItem; + private System.Windows.Forms.ToolStripStatusLabel lblApp; + private System.Windows.Forms.ToolStripStatusLabel lblVers; + private System.Windows.Forms.ToolStripProgressBar MainProgrBar; + private System.Windows.Forms.ToolStripStatusLabel lblComStats; + private System.Windows.Forms.ToolStripStatusLabel lblStatus; + private System.Windows.Forms.ToolStripStatusLabel toolStripStatusLabel1; + private System.Windows.Forms.Timer MainTimer; + private System.Windows.Forms.NotifyIcon notifyIcon1; + private System.Windows.Forms.ContextMenuStrip trayMenu; + private System.Windows.Forms.ToolStripStatusLabel tslRunTime; + private System.Windows.Forms.ToolStripStatusLabel toolStripStatusLabel3; + private System.Windows.Forms.ToolStripMenuItem closeChildToolStripMenuItem; + private System.Windows.Forms.ToolStripMenuItem uploadIOBConfToolStripMenuItem; + private System.Windows.Forms.ToolStripMenuItem downloadIOBConfToolStripMenuItem; + private System.Windows.Forms.ToolStripMenuItem sendIOBAssignmentsToolStripMenuItem; + private System.Windows.Forms.ToolStripMenuItem getIOBAssignmentsToolStripMenuItem; + private System.Windows.Forms.ToolStripMenuItem restartALLAdaptersToolStripMenuItem; + private System.Windows.Forms.ToolStripMenuItem arrangeWindowsToolStripMenuItem; + private System.Windows.Forms.ToolStripMenuItem minimizeALLToolStripMenuItem; + private System.Windows.Forms.ToolStripMenuItem closeALLAdaptersToolStripMenuItem; + private System.Windows.Forms.ToolStripMenuItem mShowMainLog; + } +} \ No newline at end of file diff --git a/IOB-WIN-NEXT/MainForm.cs b/IOB-WIN-FORM/MainForm.cs similarity index 99% rename from IOB-WIN-NEXT/MainForm.cs rename to IOB-WIN-FORM/MainForm.cs index 89f3a5d8..876245d7 100644 --- a/IOB-WIN-NEXT/MainForm.cs +++ b/IOB-WIN-FORM/MainForm.cs @@ -14,7 +14,7 @@ using System.Text; using System.Threading; using System.Windows.Forms; -namespace IOB_WIN_NEXT +namespace IOB_WIN_FORM { public partial class MainForm : Form { @@ -451,7 +451,6 @@ namespace IOB_WIN_NEXT protected string urlUploadFileCloud { get => $"{baseUrl}IOB/uploadFile/"; - } #endregion Protected Properties diff --git a/IOB-WIN-NEXT/MainForm.resx b/IOB-WIN-FORM/MainForm.resx similarity index 100% rename from IOB-WIN-NEXT/MainForm.resx rename to IOB-WIN-FORM/MainForm.resx diff --git a/IOB-WIN-FORM/Properties/AssemblyInfo.cs b/IOB-WIN-FORM/Properties/AssemblyInfo.cs new file mode 100644 index 00000000..f6072281 --- /dev/null +++ b/IOB-WIN-FORM/Properties/AssemblyInfo.cs @@ -0,0 +1,33 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("IOB-WIN-FORM")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +//[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("IOB-WIN-FORM")] +//[assembly: AssemblyCopyright("Copyright © 2024")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("9ba331bb-9bf1-40e0-ac03-74b43d73a097")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +//[assembly: AssemblyVersion("1.0.0.0")] +//[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/IOB-WIN-FORM/app.config b/IOB-WIN-FORM/app.config new file mode 100644 index 00000000..cc309607 --- /dev/null +++ b/IOB-WIN-FORM/app.config @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/IOB-WIN-FORM/packages.config b/IOB-WIN-FORM/packages.config new file mode 100644 index 00000000..e55d1665 --- /dev/null +++ b/IOB-WIN-FORM/packages.config @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file diff --git a/IOB-WIN-NEXT.sln b/IOB-WIN-NEXT.sln index 68b50623..3c7a3e16 100644 --- a/IOB-WIN-NEXT.sln +++ b/IOB-WIN-NEXT.sln @@ -12,6 +12,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "IOB-UT-NEXT", "IOB-UT-NEXT\IOB-UT-NEXT.csproj", "{90512E12-29FC-460D-94CC-648C2A072DBD}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "IOB-WIN-FORM", "IOB-WIN-FORM\IOB-WIN-FORM.csproj", "{9BA331BB-9BF1-40E0-AC03-74B43D73A097}" +EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "IOB-WIN-NEXT", "IOB-WIN-NEXT\IOB-WIN-NEXT.csproj", "{B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}" EndProject Global @@ -58,6 +60,22 @@ Global {90512E12-29FC-460D-94CC-648C2A072DBD}.SIEMENS|Any CPU.Build.0 = Release|Any CPU {90512E12-29FC-460D-94CC-648C2A072DBD}.SIEMENS|x86.ActiveCfg = Debug|x86 {90512E12-29FC-460D-94CC-648C2A072DBD}.SIEMENS|x86.Build.0 = Debug|x86 + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Debug|Any CPU.Build.0 = Debug|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Debug|x86.ActiveCfg = Debug|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Debug|x86.Build.0 = Debug|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Release|Any CPU.ActiveCfg = Release|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Release|Any CPU.Build.0 = Release|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Release|x86.ActiveCfg = Release|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Release|x86.Build.0 = Release|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Remote_DEBUG|Any CPU.ActiveCfg = Release|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Remote_DEBUG|Any CPU.Build.0 = Release|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Remote_DEBUG|x86.ActiveCfg = Release|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.Remote_DEBUG|x86.Build.0 = Release|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.SIEMENS|Any CPU.ActiveCfg = Debug|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.SIEMENS|Any CPU.Build.0 = Debug|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.SIEMENS|x86.ActiveCfg = Debug|Any CPU + {9BA331BB-9BF1-40E0-AC03-74B43D73A097}.SIEMENS|x86.Build.0 = Debug|Any CPU {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.Debug|Any CPU.Build.0 = Debug|Any CPU {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.Debug|x86.ActiveCfg = Debug|x86 @@ -70,8 +88,8 @@ Global {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.Remote_DEBUG|Any CPU.Build.0 = Remote_DEBUG|Any CPU {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.Remote_DEBUG|x86.ActiveCfg = Remote_DEBUG|x86 {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.Remote_DEBUG|x86.Build.0 = Remote_DEBUG|x86 - {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.SIEMENS|Any CPU.ActiveCfg = Release|Any CPU - {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.SIEMENS|Any CPU.Build.0 = Release|Any CPU + {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.SIEMENS|Any CPU.ActiveCfg = Debug|Any CPU + {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.SIEMENS|Any CPU.Build.0 = Debug|Any CPU {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.SIEMENS|x86.ActiveCfg = Debug|x86 {B2ABB009-C046-4F9C-956C-52DCAA9FE5A9}.SIEMENS|x86.Build.0 = Debug|x86 EndGlobalSection diff --git a/IOB-WIN-NEXT/AdapterFormNext.cs b/IOB-WIN-NEXT/AdapterFormNext.cs new file mode 100644 index 00000000..424d08cd --- /dev/null +++ b/IOB-WIN-NEXT/AdapterFormNext.cs @@ -0,0 +1,379 @@ +using IOB_UT_NEXT; +using IOB_WIN_NEXT.Iob; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace IOB_WIN_NEXT +{ + public class AdapterFormNext: IOB_WIN_FORM.AdapterForm + { + + /// + /// Avvio MainForm + /// + /// + public AdapterFormNext(string codIOB): base(codIOB) + { + } + /// + /// carica IOB richiesto + /// + protected override void loadIobType() + { + if (IOBConf != null) + { + switch (tipoScelto) + { + case tipoAdapter.SIMULA: + iobObj = new Iob.Simula(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.BECKHOFF: + case tipoAdapter.BECKHOFF_CPA: + iobObj = new IobBeckhoff.BeckhoffCpa(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.FILE_GEN: + iobObj = new IobFile.FileGen(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.FILE_EUROM63: + iobObj = new IobFile.FileEurom63(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.FILE_SOITAAB: + iobObj = new IobFile.IobFileSoitaab(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.FANUC: + iobObj = new Iob.Fanuc(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.FTP: + iobObj = new IobNet.Ftp(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.KAWASAKI: + iobObj = new Iob.Kawasaki(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.IcoelDb: + iobObj = new IobSql.IcoelDb(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.IcoelSoap: + iobObj = new IobNet.IcoelSoap(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MITSUBISHI: + iobObj = new Mitsubishi(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MODBUS_TCP: + iobObj = new IobModbusTCP.ModbusTCP(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MODBUS_TCP_CEDAX: + iobObj = new IobModbusTCP.ModbusTCPCedax(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MODBUS_TCP_CENTERFRIGO: + iobObj = new IobModbusTCP.ModbusTCPCenterfrigo(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MODBUS_TCP_FIMAT: + iobObj = new IobModbusTCP.ModbusTCPFimat(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MODBUS_TCP_HAM: + iobObj = new IobModbusTCP.ModbusTCPHam(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MODBUS_TCP_HELPI: + iobObj = new IobModbusTCP.ModbusTCPHelpi(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MODBUS_TCP_IMAS_AEROMEC: + iobObj = new IobModbusTCP.ModbusTCPImaxAeromec(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MODBUS_TCP_RIMOR: + iobObj = new IobModbusTCP.ModbusTCPRimor(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MODBUS_TCP_SAIM: + iobObj = new IobModbusTCP.ModbusTCPSaim(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MODBUS_TCP_ZETAPACK: + iobObj = new IobModbusTCP.ModbusTCPZetapack(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.MTConnect: + iobObj = new Iob.MTConn(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OMRON: + iobObj = new Iob.Omron(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUa: + iobObj = new IobOpc.OpcUa(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaCMS: + case tipoAdapter.OpcUaSCM: + iobObj = new IobOpc.OpcUaCMS(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaEwon: + iobObj = new IobOpc.OpcUaEwon(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaEwonAdige: + iobObj = new IobOpc.OpcUaEwonAdige(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaEwonBLM: + iobObj = new IobOpc.OpcUaEwonBLM(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaEwonMonti: + iobObj = new IobOpc.OpcUaEwonMonti(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaEwonMecolpress: + iobObj = new IobOpc.OpcUaEwonMecolpress(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaKwp: + iobObj = new IobOpc.OpcUaKpw(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaKwpRama: + iobObj = new IobOpc.OpcUaKpwRama(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaImasAeromec: + iobObj = new IobOpc.OpcUaImas(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaMBH: + iobObj = new IobOpc.OpcUaMBH(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaMBHCimolai: + iobObj = new IobOpc.OpcUaMBHCimolai(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaOmron: + iobObj = new IobOpc.OpcUaOmron(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaOmronIcoel: + iobObj = new IobOpc.OpcUaOmronIcoel(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaSiemens: + iobObj = new IobOpc.OpcUaSiemens(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaSiemensOMP: + iobObj = new IobOpc.OpcUaSiemensOMP(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaSiemensRama: + iobObj = new IobOpc.OpcUaSiemensRama(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OpcUaUlma: + iobObj = new IobOpc.OpcUaUlma(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.PingWatchdog: + iobObj = new IobNet.Ping(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.OSAI_OPEN: + case tipoAdapter.OSAI_CNDEX: + case tipoAdapter.OSAI_VB6: + // versione EgwProxy.OsaiCncLib + iobObj = new Iob.OSAI(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.REST: + iobObj = new IobRest.Base(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.REST_CITIZEN: + iobObj = new IobRest.Citizen(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS: + iobObj = new IobSiemens.Siemens(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_APROCHIM: + iobObj = new IobSiemens.SiemensAprochim(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_AT2001: + iobObj = new IobSiemens.SiemensAt2001(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_COMECA: + iobObj = new IobSiemens.SiemensComeca(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_COMUR: + iobObj = new IobSiemens.SiemensComur(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_COSMAP: + iobObj = new IobSiemens.SiemensCosmap(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_FAPE: + iobObj = new IobSiemens.SiemensFape(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_FAPE_2: + iobObj = new IobSiemens.SiemensFapeV2(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_INGENIA: + iobObj = new IobSiemens.SiemensIngenia(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_LASCO: + iobObj = new IobSiemens.SiemensLasco(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_NWSE: + iobObj = new IobSiemens.SiemensNWSE(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_PRESSOIL_CEI: + iobObj = new IobSiemens.SiemensPressoilCei(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_ROBOTSERVICE: + iobObj = new IobSiemens.SiemensRobotService(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_SAET: + iobObj = new IobSiemens.SiemensSaet(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_SIMEC: + iobObj = new IobSiemens.SiemensSimec(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SIEMENS_TORRI: + iobObj = new IobSiemens.SiemensTorri(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SOAP_GOMBA: + iobObj = new IobSoap.Gomba(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SQLSERVER_LANTEK: + iobObj = new IobSql.SqlServLantek(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.SQLSERVER_PAMA: + iobObj = new IobSql.SqlServPama(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.WPS: + iobObj = new IobNet.WebPageScrap(this, IOBConf); + btnStart.Enabled = true; + break; + + case tipoAdapter.ND: + default: + iobObj = new Iob.Simula(this, IOBConf); + btnStart.Enabled = false; + break; + } + lblCncText = $"CNC: {IOBConf.tipoIob} [{IOBConf.cncIpAddr}:{IOBConf.cncPort}]"; + lblSrvUrlText = $"SRV: {IOBConf.serverData.MPIP} | URL: {IOBConf.serverData.MPURL}{IOBConf.serverData.CMDBASE}"; + + // aggancio evento refresh + iobObj.eh_refreshed += IobObj_eh_refreshed; + + // carico i default values su interfaccia + setDefaults(); + + displayTaskAndLog($"Caricata conf per adapter {tipoScelto}"); + } + } + } +} diff --git a/IOB-WIN-NEXT/DATA/CONF/MAIN.ini b/IOB-WIN-NEXT/DATA/CONF/MAIN.ini index abb55b7d..2533e40d 100644 --- a/IOB-WIN-NEXT/DATA/CONF/MAIN.ini +++ b/IOB-WIN-NEXT/DATA/CONF/MAIN.ini @@ -52,8 +52,8 @@ CLI_INST=SteamWareSim ;STARTLIST=Tend_RAMA_10_47 ;STARTLIST=3024-PING ;STARTLIST=2015 -;STARTLIST=SIMUL_01 -STARTLIST=3024 +STARTLIST=SIMUL_01 +;STARTLIST=3024 MAXCNC=10 \ No newline at end of file diff --git a/IOB-WIN-NEXT/Enums.cs b/IOB-WIN-NEXT/Enums.cs deleted file mode 100644 index 5d83a707..00000000 --- a/IOB-WIN-NEXT/Enums.cs +++ /dev/null @@ -1,20 +0,0 @@ -namespace IOB_WIN_NEXT -{ - public enum StartMode - { - /// - /// modalità standard (standalone, multi IOB) - /// - STD = 0, - - /// - /// Modalità managed (da IOB-MAN) - /// - MAN = 1, - - /// - /// Modalità update (per aggiornare IOB-WIN) senza IOB - /// - UPD = 2 - } -} \ No newline at end of file diff --git a/IOB-WIN-NEXT/FodyWeavers.xml b/IOB-WIN-NEXT/FodyWeavers.xml deleted file mode 100644 index 5029e706..00000000 --- a/IOB-WIN-NEXT/FodyWeavers.xml +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/IOB-WIN-NEXT/FodyWeavers.xsd b/IOB-WIN-NEXT/FodyWeavers.xsd deleted file mode 100644 index f2dbece7..00000000 --- a/IOB-WIN-NEXT/FodyWeavers.xsd +++ /dev/null @@ -1,176 +0,0 @@ - - - - - - - - - - - - A list of assembly names to exclude from the default action of "embed all Copy Local references", delimited with line breaks - - - - - A list of assembly names to include from the default action of "embed all Copy Local references", delimited with line breaks. - - - - - A list of runtime assembly names to exclude from the default action of "embed all Copy Local references", delimited with line breaks - - - - - A list of runtime assembly names to include from the default action of "embed all Copy Local references", delimited with line breaks. - - - - - Obsolete, use UnmanagedWinX86Assemblies instead - - - - - A list of unmanaged X86 (32 bit) assembly names to include, delimited with line breaks. - - - - - Obsolete, use UnmanagedWinX64Assemblies instead. - - - - - A list of unmanaged X64 (64 bit) assembly names to include, delimited with line breaks. - - - - - A list of unmanaged Arm64 (64 bit) assembly names to include, delimited with line breaks. - - - - - The order of preloaded assemblies, delimited with line breaks. - - - - - - This will copy embedded files to disk before loading them into memory. This is helpful for some scenarios that expected an assembly to be loaded from a physical file. - - - - - Controls if .pdbs for reference assemblies are also embedded. - - - - - Controls if runtime assemblies are also embedded. - - - - - Controls whether the runtime assemblies are embedded with their full path or only with their assembly name. - - - - - Embedded assemblies are compressed by default, and uncompressed when they are loaded. You can turn compression off with this option. - - - - - As part of Costura, embedded assemblies are no longer included as part of the build. This cleanup can be turned off. - - - - - The attach method no longer subscribes to the `AppDomain.AssemblyResolve` (.NET 4.x) and `AssemblyLoadContext.Resolving` (.NET 6.0+) events. - - - - - Costura by default will load as part of the module initialization. This flag disables that behavior. Make sure you call CosturaUtility.Initialize() somewhere in your code. - - - - - Costura will by default use assemblies with a name like 'resources.dll' as a satellite resource and prepend the output path. This flag disables that behavior. - - - - - A list of assembly names to exclude from the default action of "embed all Copy Local references", delimited with | - - - - - A list of assembly names to include from the default action of "embed all Copy Local references", delimited with |. - - - - - A list of runtime assembly names to exclude from the default action of "embed all Copy Local references", delimited with | - - - - - A list of runtime assembly names to include from the default action of "embed all Copy Local references", delimited with |. - - - - - Obsolete, use UnmanagedWinX86Assemblies instead - - - - - A list of unmanaged X86 (32 bit) assembly names to include, delimited with |. - - - - - Obsolete, use UnmanagedWinX64Assemblies instead - - - - - A list of unmanaged X64 (64 bit) assembly names to include, delimited with |. - - - - - A list of unmanaged Arm64 (64 bit) assembly names to include, delimited with |. - - - - - The order of preloaded assemblies, delimited with |. - - - - - - - - 'true' to run assembly verification (PEVerify) on the target assembly after all weavers have been executed. - - - - - A comma-separated list of error codes that can be safely ignored in assembly verification. - - - - - 'false' to turn off automatic generation of the XML Schema file. - - - - - \ No newline at end of file diff --git a/IOB-WIN-NEXT/IOB-WIN-NEXT.csproj b/IOB-WIN-NEXT/IOB-WIN-NEXT.csproj index e4ab01ee..b449dea0 100644 --- a/IOB-WIN-NEXT/IOB-WIN-NEXT.csproj +++ b/IOB-WIN-NEXT/IOB-WIN-NEXT.csproj @@ -526,6 +526,9 @@ VersGen.cs + + Form + @@ -535,8 +538,6 @@ - - @@ -564,7 +565,6 @@ - @@ -601,19 +601,7 @@ - - - Form - - - AdapterForm.cs - - - Form - - - MainForm.cs - + @@ -845,12 +833,6 @@ Always - - AdapterForm.cs - - - MainForm.cs - ResXFileCodeGenerator Resources.Designer.cs @@ -1128,6 +1110,10 @@ {90512e12-29fc-460d-94cc-648c2a072dbd} IOB-UT-NEXT + + {9ba331bb-9bf1-40e0-ac03-74b43d73a097} + IOB-WIN-FORM + diff --git a/IOB-WIN-NEXT/Iob/Fanuc.cs b/IOB-WIN-NEXT/Iob/Fanuc.cs index cec3d233..72091b78 100644 --- a/IOB-WIN-NEXT/Iob/Fanuc.cs +++ b/IOB-WIN-NEXT/Iob/Fanuc.cs @@ -13,7 +13,7 @@ using System.Net.NetworkInformation; namespace IOB_WIN_NEXT.Iob { - public class Fanuc : Iob.Generic + public class Fanuc : Iob.GenericNext { #region Public Constructors @@ -22,7 +22,7 @@ namespace IOB_WIN_NEXT.Iob /// /// /// - public Fanuc(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Fanuc(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Start init Fanuc"); // i dati RAW principali sono 6 byte... diff --git a/IOB-WIN-NEXT/Iob/GenericNext.cs b/IOB-WIN-NEXT/Iob/GenericNext.cs new file mode 100644 index 00000000..76a1e168 --- /dev/null +++ b/IOB-WIN-NEXT/Iob/GenericNext.cs @@ -0,0 +1,119 @@ +using EgwProxy.Ftp; +using EgwProxy.MultiCncLib.App.Native; +using IOB_UT_NEXT; +using IOB_WIN_FORM; +using MapoSDK; +using MathNet.Numerics.Statistics; +using MTConnect; +using MTConnect.Clients; +using Newtonsoft.Json; +using Newtonsoft.Json.Linq; +using NLog; +using System; +using System.Collections; +using System.Collections.Generic; +using System.Globalization; +using System.IO; +using System.Linq; +using System.Net; +using System.Net.NetworkInformation; +using System.Text; +using System.Threading; +using System.Threading.Tasks; +using System.Windows.Forms; +using System.Xml.Serialization; +using static IOB_UT_NEXT.BaseAlarmConf; +using static IOB_UT_NEXT.CustomObj; +using static IOB_UT_NEXT.DataModel.Fimat; +using static MapoSDK.WharehouseData; + +namespace IOB_WIN_NEXT.Iob +{ + public class GenericNext : IOB_WIN_FORM.Iob.Generic + { + + public GenericNext(AdapterFormNext caller, IobConfiguration IOBConf): base((IOB_WIN_FORM.AdapterForm)caller, IOBConf) + { + } + + /// + /// Effettua upload verso server FTP della macchina dei files nella folder indicata + /// + /// + /// + protected override bool iobSendFTP(string folderDir) + { + bool answ = false; + //leggo CONF + string ftpServ = getOptPar("FTP_SERVER"); + string ftpUser = getOptPar("FTP_USER"); + string ftpPass = getOptPar("FTP_PWD"); + string ftpCert = getOptPar("FTP_CERT"); + string doSkip = getOptPar("FTP_SKIP"); + string remDir = getOptPar("FTP_REM_DIR"); + string locDir = getOptPar("FTP_LOC_DIR"); + // procedo SE TROVO conf... + if (string.IsNullOrEmpty($"{ftpServ}{ftpUser}{ftpPass}")) + { + lgError($"Impossibile eseguire iobSendFTP x mancanza parametri | ftpServ: {ftpServ} | ftpUser: {ftpUser} | ftpPass: {ftpPass}"); + } + else + { + bool ftpSkip = false; + bool.TryParse(doSkip, out ftpSkip); + var ftpClient = new Manager(ftpServ, ftpUser, ftpPass, ftpCert, ftpSkip); + var testServer = ftpClient.ServerOk(); + if (testServer) + { + lgInfo($"FTP: server found at {ftpServ}"); + var srvType = ftpClient.ServerType(); + lgInfo($"FTP Server type: {srvType}"); + + var preTest = ftpClient.DirExists(remDir); + if (!preTest) + { + var dirCreate = ftpClient.CreateDir(remDir); + lgInfo($"FTP: created remote dir {remDir}"); + } + + // test directory... + string basePath = Application.StartupPath; + + string localPath = Path.Combine(basePath, locDir); + lgInfo($"basePath: {basePath} | localPath: {localPath}"); + var fileList = Directory.GetFiles(localPath, "*.csv"); + int numfile = 0; + foreach (var file in fileList) + { + string fName = file.Split('\\').Last(); + string remName = $"{remDir}\\{fName}"; + ftpClient.SendFile(file, remName); + numfile++; + } + var dirUploaded = (numfile == fileList.Count()); + if (dirUploaded) + { + lgInfo($"FTP: uploaded dir content {locDir} --> {remDir}"); + } + // se ok --> sposto invio + DateTime adesso = DateTime.Now; + string archBasePath = Path.Combine(basePath, "DATA", "HIST", $"{adesso:yyyy}"); + baseUtils.checkDir(archBasePath); + string archPath = Path.Combine(archBasePath, $"{adesso:MMddHHmmss}"); + baseUtils.checkDir(archPath); + lgInfo($"Richiesta Dir Move | {localPath} | {archPath}"); + foreach (var item in fileList) + { + string fName = item.Split('\\').Last(); + string destName = $"{archPath}\\{fName}"; + File.Move(item, destName); + } + //Directory.Move(localPath, archBasePath); + lgInfo($"FTP: Archived dir content {localPath} --> {archPath}"); + } + } + return answ; + } + + } +} \ No newline at end of file diff --git a/IOB-WIN-NEXT/Iob/Kawasaki.cs b/IOB-WIN-NEXT/Iob/Kawasaki.cs index fe5130ba..cbafcf2f 100644 --- a/IOB-WIN-NEXT/Iob/Kawasaki.cs +++ b/IOB-WIN-NEXT/Iob/Kawasaki.cs @@ -6,7 +6,7 @@ using System.Net.NetworkInformation; namespace IOB_WIN_NEXT.Iob { - public class Kawasaki : Iob.Generic, IDisposable + public class Kawasaki : Iob.GenericNext, IDisposable { #region Public Constructors @@ -15,7 +15,7 @@ namespace IOB_WIN_NEXT.Iob /// /// /// - public Kawasaki(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Kawasaki(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { // gestione invio ritardato contapezzi pzCountDelay = utils.CRI("pzCountDelay"); diff --git a/IOB-WIN-NEXT/Iob/MTConn.cs b/IOB-WIN-NEXT/Iob/MTConn.cs index a5997632..487e4de8 100644 --- a/IOB-WIN-NEXT/Iob/MTConn.cs +++ b/IOB-WIN-NEXT/Iob/MTConn.cs @@ -17,7 +17,7 @@ using System.Xml.Linq; namespace IOB_WIN_NEXT.Iob { - public class MTConn : Iob.Generic + public class MTConn : Iob.GenericNext { #region Public Constructors @@ -26,7 +26,7 @@ namespace IOB_WIN_NEXT.Iob /// /// /// - public MTConn(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public MTConn(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { // gestione invio ritardato contapezzi pzCountDelay = utils.CRI("pzCountDelay"); diff --git a/IOB-WIN-NEXT/Iob/Mitsubishi.cs b/IOB-WIN-NEXT/Iob/Mitsubishi.cs index d7248558..08d3b264 100644 --- a/IOB-WIN-NEXT/Iob/Mitsubishi.cs +++ b/IOB-WIN-NEXT/Iob/Mitsubishi.cs @@ -16,7 +16,7 @@ using System.Threading; namespace IOB_WIN_NEXT.Iob { - public class Mitsubishi : Iob.Generic + public class Mitsubishi : Iob.GenericNext { #region Public Constructors @@ -25,7 +25,7 @@ namespace IOB_WIN_NEXT.Iob /// /// /// - public Mitsubishi(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Mitsubishi(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Start init Mitsubishi"); // gestione invio ritardato contapezzi diff --git a/IOB-WIN-NEXT/Iob/OSAI.cs b/IOB-WIN-NEXT/Iob/OSAI.cs index a5244f89..f8a42204 100644 --- a/IOB-WIN-NEXT/Iob/OSAI.cs +++ b/IOB-WIN-NEXT/Iob/OSAI.cs @@ -9,7 +9,7 @@ using System.Net.NetworkInformation; namespace IOB_WIN_NEXT.Iob { - public class OSAI : Iob.Generic + public class OSAI : Iob.GenericNext { #region Public Fields @@ -32,7 +32,7 @@ namespace IOB_WIN_NEXT.Iob /// /// /// - public OSAI(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OSAI(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { // gestione invio ritardato contapezzi pzCountDelay = utils.CRI("pzCountDelay"); diff --git a/IOB-WIN-NEXT/Iob/Omron.cs b/IOB-WIN-NEXT/Iob/Omron.cs index 029a9ecc..c6eb73f6 100644 --- a/IOB-WIN-NEXT/Iob/Omron.cs +++ b/IOB-WIN-NEXT/Iob/Omron.cs @@ -8,7 +8,7 @@ using System.Threading; namespace IOB_WIN_NEXT.Iob { - public class Omron : Iob.Generic + public class Omron : Iob.GenericNext { #region Public Constructors @@ -17,7 +17,7 @@ namespace IOB_WIN_NEXT.Iob /// /// /// - public Omron(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Omron(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { // gestione invio ritardato contapezzi pzCountDelay = utils.CRI("pzCountDelay"); diff --git a/IOB-WIN-NEXT/Iob/Simula.cs b/IOB-WIN-NEXT/Iob/Simula.cs index e6180107..099fbb90 100644 --- a/IOB-WIN-NEXT/Iob/Simula.cs +++ b/IOB-WIN-NEXT/Iob/Simula.cs @@ -35,7 +35,7 @@ namespace IOB_WIN_NEXT.Iob #endregion Public Fields } - public class Simula : Iob.Generic + public class Simula : Iob.GenericNext { #region Public Fields @@ -58,7 +58,7 @@ namespace IOB_WIN_NEXT.Iob /// /// /// - public Simula(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Simula(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { // gestione invio ritardato contapezzi pzCountDelay = utils.CRI("pzCountDelay"); diff --git a/IOB-WIN-NEXT/IobBeckhoff/Beckhoff.cs b/IOB-WIN-NEXT/IobBeckhoff/Beckhoff.cs index 81e07522..e16a4bd7 100644 --- a/IOB-WIN-NEXT/IobBeckhoff/Beckhoff.cs +++ b/IOB-WIN-NEXT/IobBeckhoff/Beckhoff.cs @@ -4,7 +4,7 @@ using System.Collections.Generic; namespace IOB_WIN_NEXT.IobBeckhoff { - public class Beckhoff : Iob.Generic + public class Beckhoff : Iob.GenericNext { #region Public Fields @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobBeckhoff /// /// /// - public Beckhoff(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Beckhoff(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IobBeckhoff Adapter"); // gestione invio ritardato contapezzi diff --git a/IOB-WIN-NEXT/IobBeckhoff/BeckhoffCpa.cs b/IOB-WIN-NEXT/IobBeckhoff/BeckhoffCpa.cs index 5ee77375..b13367a6 100644 --- a/IOB-WIN-NEXT/IobBeckhoff/BeckhoffCpa.cs +++ b/IOB-WIN-NEXT/IobBeckhoff/BeckhoffCpa.cs @@ -14,7 +14,7 @@ namespace IOB_WIN_NEXT.IobBeckhoff /// /// /// - public BeckhoffCpa(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public BeckhoffCpa(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("START IobBeckhoffCPA Adapter specifico"); diff --git a/IOB-WIN-NEXT/IobFile/FileEurom63.cs b/IOB-WIN-NEXT/IobFile/FileEurom63.cs index 85f86ffd..1daccf57 100644 --- a/IOB-WIN-NEXT/IobFile/FileEurom63.cs +++ b/IOB-WIN-NEXT/IobFile/FileEurom63.cs @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobFile /// /// /// - public FileEurom63(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public FileEurom63(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("INIT IobFileEurom63"); appPath = Path.GetDirectoryName(Application.ExecutablePath); diff --git a/IOB-WIN-NEXT/IobFile/FileGen.cs b/IOB-WIN-NEXT/IobFile/FileGen.cs index 7f1ccea7..1c081754 100644 --- a/IOB-WIN-NEXT/IobFile/FileGen.cs +++ b/IOB-WIN-NEXT/IobFile/FileGen.cs @@ -10,7 +10,7 @@ namespace IOB_WIN_NEXT.IobFile /// /// Generica classe per implementare IOB basato su scambio FILE /// - public class FileGen : Iob.Generic, IDisposable + public class FileGen : Iob.GenericNext, IDisposable { /* -------------------------------------------------------------------------------- * Controlli dotati di GENERICA funzionalità scambio info tramite file @@ -24,7 +24,7 @@ namespace IOB_WIN_NEXT.IobFile /// /// /// - public FileGen(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public FileGen(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("INIT FileGen"); //reloadAdapterConf(); diff --git a/IOB-WIN-NEXT/IobFile/IobFileSoitaab.cs b/IOB-WIN-NEXT/IobFile/IobFileSoitaab.cs index c64f35fc..d2bb11bb 100644 --- a/IOB-WIN-NEXT/IobFile/IobFileSoitaab.cs +++ b/IOB-WIN-NEXT/IobFile/IobFileSoitaab.cs @@ -18,7 +18,7 @@ namespace IOB_WIN_NEXT.IobFile /// --> fluxLog /// - public class IobFileSoitaab : Iob.Generic + public class IobFileSoitaab : Iob.GenericNext { #region Public Constructors @@ -27,7 +27,7 @@ namespace IOB_WIN_NEXT.IobFile /// /// AdapterForm chiamante /// Configurazione IOB per avvio - public IobFileSoitaab(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public IobFileSoitaab(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { DateTime adesso = DateTime.Now; string VetoReadSec = getOptPar("VetoReadSec"); diff --git a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCP.cs b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCP.cs index 97f33207..515662e0 100644 --- a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCP.cs +++ b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCP.cs @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP * * -------------------------------------------------------------------------------- */ - public class ModbusTCP : Iob.Generic + public class ModbusTCP : Iob.GenericNext { #region Public Constructors @@ -28,7 +28,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP /// /// /// - public ModbusTCP(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public ModbusTCP(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB ModBus TCP"); diff --git a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPCedax.cs b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPCedax.cs index e0376238..7610ab38 100644 --- a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPCedax.cs +++ b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPCedax.cs @@ -26,7 +26,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP /// /// /// - public ModbusTCPCedax(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public ModbusTCPCedax(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB ModBus TCP Cedax"); diff --git a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPCenterfrigo.cs b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPCenterfrigo.cs index 09233551..60623444 100644 --- a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPCenterfrigo.cs +++ b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPCenterfrigo.cs @@ -29,7 +29,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP /// /// /// - public ModbusTCPCenterfrigo(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public ModbusTCPCenterfrigo(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB ModBus TCP Centerfrigo"); diff --git a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPFimat.cs b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPFimat.cs index 90ae1419..766818ef 100644 --- a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPFimat.cs +++ b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPFimat.cs @@ -24,7 +24,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP /// /// /// - public ModbusTCPFimat(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public ModbusTCPFimat(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB ModBus TCP FIMAT"); diff --git a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPHam.cs b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPHam.cs index 1e8533b5..8112af75 100644 --- a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPHam.cs +++ b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPHam.cs @@ -24,7 +24,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP /// /// /// - public ModbusTCPHam(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public ModbusTCPHam(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB ModBus TCP HAM"); diff --git a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPHelpi.cs b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPHelpi.cs index 85fb11e3..6c06894d 100644 --- a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPHelpi.cs +++ b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPHelpi.cs @@ -43,7 +43,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP /// /// /// - public ModbusTCPHelpi(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public ModbusTCPHelpi(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB ModBus TCP Helpi"); diff --git a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPImaxAeromec.cs b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPImaxAeromec.cs index 6a765189..ad4ed28b 100644 --- a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPImaxAeromec.cs +++ b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPImaxAeromec.cs @@ -24,7 +24,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP /// /// /// - public ModbusTCPImaxAeromec(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public ModbusTCPImaxAeromec(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB ModBus TCP IMAS Aeromec"); diff --git a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPRimor.cs b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPRimor.cs index c6060027..20d860c9 100644 --- a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPRimor.cs +++ b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPRimor.cs @@ -24,7 +24,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP /// /// /// - public ModbusTCPRimor(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public ModbusTCPRimor(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB ModBus TCP Rimor"); diff --git a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPSaim.cs b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPSaim.cs index e090b648..4b980d34 100644 --- a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPSaim.cs +++ b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPSaim.cs @@ -23,7 +23,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP /// /// /// - public ModbusTCPSaim(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public ModbusTCPSaim(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB ModBus TCP Saim"); diff --git a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPZetapack.cs b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPZetapack.cs index 98000aea..5744f429 100644 --- a/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPZetapack.cs +++ b/IOB-WIN-NEXT/IobModbusTCP/ModbusTCPZetapack.cs @@ -23,7 +23,7 @@ namespace IOB_WIN_NEXT.IobModbusTCP /// /// /// - public ModbusTCPZetapack(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public ModbusTCPZetapack(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB ModBus TCP Zetapack"); diff --git a/IOB-WIN-NEXT/IobNet/Ftp.cs b/IOB-WIN-NEXT/IobNet/Ftp.cs index 2dc8c0e0..cd5b48f7 100644 --- a/IOB-WIN-NEXT/IobNet/Ftp.cs +++ b/IOB-WIN-NEXT/IobNet/Ftp.cs @@ -21,7 +21,7 @@ namespace IOB_WIN_NEXT.IobNet /// /// Classe gestione sync via FTP /// - public class Ftp : Iob.Generic + public class Ftp : Iob.GenericNext { #region Public Constructors @@ -32,7 +32,7 @@ namespace IOB_WIN_NEXT.IobNet /// /// /// - public Ftp(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Ftp(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init IobFtp Client"); // imposto diff --git a/IOB-WIN-NEXT/IobNet/IcoelSoap.cs b/IOB-WIN-NEXT/IobNet/IcoelSoap.cs index 5078a4b6..730b83a2 100644 --- a/IOB-WIN-NEXT/IobNet/IcoelSoap.cs +++ b/IOB-WIN-NEXT/IobNet/IcoelSoap.cs @@ -11,7 +11,7 @@ namespace IOB_WIN_NEXT.IobNet /// /// Adapter specializzato per ICOEL e le chiamate tramite WS Soap al Sizer, con libreria EgwProxy.Icoel /// - public class IcoelSoap : Iob.Generic + public class IcoelSoap : Iob.GenericNext { #region Public Constructors @@ -20,7 +20,7 @@ namespace IOB_WIN_NEXT.IobNet /// /// AdapterForm chiamante /// Configurazione IOB per avvio - public IcoelSoap(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public IcoelSoap(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { /* -------------------------------------- * todo's diff --git a/IOB-WIN-NEXT/IobNet/Ping.cs b/IOB-WIN-NEXT/IobNet/Ping.cs index 50823d43..6dbac65c 100644 --- a/IOB-WIN-NEXT/IobNet/Ping.cs +++ b/IOB-WIN-NEXT/IobNet/Ping.cs @@ -9,7 +9,7 @@ using System.Threading.Tasks; namespace IOB_WIN_NEXT.IobNet { - public class Ping : Iob.Generic + public class Ping : Iob.GenericNext { #region Public Constructors @@ -18,7 +18,7 @@ namespace IOB_WIN_NEXT.IobNet /// /// /// - public Ping(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Ping(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IobPing (WatchDog)"); // init datetime counters diff --git a/IOB-WIN-NEXT/IobNet/WebPageScrap.cs b/IOB-WIN-NEXT/IobNet/WebPageScrap.cs index 0471b659..5d5d6bcf 100644 --- a/IOB-WIN-NEXT/IobNet/WebPageScrap.cs +++ b/IOB-WIN-NEXT/IobNet/WebPageScrap.cs @@ -18,7 +18,7 @@ namespace IOB_WIN_NEXT.IobNet /// Generica classe per implementare WebPageScraping (scaricamento web pages anche js-based x /// recupero informazioni) /// - public class WebPageScrap : Iob.Generic, IDisposable + public class WebPageScrap : Iob.GenericNext, IDisposable { /* -------------------------------------------------------------------------------- * Controlli dotati di GENERICA pagina WEB in cui cercare e recuperare informazioni @@ -35,7 +35,7 @@ namespace IOB_WIN_NEXT.IobNet /// /// /// - public WebPageScrap(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public WebPageScrap(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("INIT IobWPS"); //reloadAdapterConf(); diff --git a/IOB-WIN-NEXT/IobOpc/OpcUa.cs b/IOB-WIN-NEXT/IobOpc/OpcUa.cs index 41346b26..bca0dd4a 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUa.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUa.cs @@ -21,7 +21,7 @@ using static IOB_UT_NEXT.ByteDataConverter; namespace IOB_WIN_NEXT.IobOpc { - public class OpcUa : Iob.Generic + public class OpcUa : Iob.GenericNext { #region Public Constructors @@ -30,7 +30,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUa(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUa(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init OpcUa"); // gestione invio ritardato contapezzi diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaCMS.cs b/IOB-WIN-NEXT/IobOpc/OpcUaCMS.cs index 850b6e81..3003efcd 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaCMS.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaCMS.cs @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaCMS(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaCMS(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { // inizializzo classe base... if (!string.IsNullOrEmpty(getOptPar("CHANGE_ODL_MODE"))) diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaEwon.cs b/IOB-WIN-NEXT/IobOpc/OpcUaEwon.cs index 7aa20775..9e2d4d4c 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaEwon.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaEwon.cs @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaEwon(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaEwon(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { // inizializzo classe base... if (!string.IsNullOrEmpty(getOptPar("CHANGE_ODL_MODE"))) diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaEwonAdige.cs b/IOB-WIN-NEXT/IobOpc/OpcUaEwonAdige.cs index 25f4c625..bf566254 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaEwonAdige.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaEwonAdige.cs @@ -17,7 +17,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaEwonAdige(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaEwonAdige(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init Ewon versione Adige/BLM"); diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaEwonBLM.cs b/IOB-WIN-NEXT/IobOpc/OpcUaEwonBLM.cs index 7516394d..c989cfc6 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaEwonBLM.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaEwonBLM.cs @@ -15,7 +15,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaEwonBLM(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaEwonBLM(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init Ewon versione BLM (Mecart)"); diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaEwonMecolpress.cs b/IOB-WIN-NEXT/IobOpc/OpcUaEwonMecolpress.cs index 31006286..109f5688 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaEwonMecolpress.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaEwonMecolpress.cs @@ -17,7 +17,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaEwonMecolpress(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaEwonMecolpress(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init Ewon versione Mecolpress (STEL)"); diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaEwonMonti.cs b/IOB-WIN-NEXT/IobOpc/OpcUaEwonMonti.cs index b014ae5d..a0bdf346 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaEwonMonti.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaEwonMonti.cs @@ -18,7 +18,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaEwonMonti(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaEwonMonti(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init Ewon versione Monti (Tenditalia)"); // inizializzo classe base... diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaImas.cs b/IOB-WIN-NEXT/IobOpc/OpcUaImas.cs index 78bd28c3..464d9463 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaImas.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaImas.cs @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaImas(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaImas(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init OpcUa IMAS"); // inizializzo classe base... diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaKpw.cs b/IOB-WIN-NEXT/IobOpc/OpcUaKpw.cs index 8545872e..d761977c 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaKpw.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaKpw.cs @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaKpw(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaKpw(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init OpcUa Kepware"); // inizializzo classe base... diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaKpwRama.cs b/IOB-WIN-NEXT/IobOpc/OpcUaKpwRama.cs index c75be8be..ffc531ae 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaKpwRama.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaKpwRama.cs @@ -22,7 +22,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaKpwRama(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaKpwRama(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init OpcUa Kepware x RAMA"); // inizializzo classe base... diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaMBH.cs b/IOB-WIN-NEXT/IobOpc/OpcUaMBH.cs index f4c5db3e..a84fb601 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaMBH.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaMBH.cs @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaMBH(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaMBH(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init OpcUa MBH"); // inizializzo classe base... diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaMBHCimolai.cs b/IOB-WIN-NEXT/IobOpc/OpcUaMBHCimolai.cs index 5adc0c98..3d0c26a4 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaMBHCimolai.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaMBHCimolai.cs @@ -20,7 +20,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaMBHCimolai(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaMBHCimolai(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init OpcUa MBH versione Cimolai (Baglietto)"); diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaOmron.cs b/IOB-WIN-NEXT/IobOpc/OpcUaOmron.cs index 91f33929..b7a06e26 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaOmron.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaOmron.cs @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaOmron(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaOmron(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { // inizializzo classe base... if (!string.IsNullOrEmpty(getOptPar("CHANGE_ODL_MODE"))) diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaOmronIcoel.cs b/IOB-WIN-NEXT/IobOpc/OpcUaOmronIcoel.cs index 8d48929e..8c92970c 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaOmronIcoel.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaOmronIcoel.cs @@ -208,7 +208,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaOmronIcoel(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaOmronIcoel(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { // inizializzo classe base... if (!string.IsNullOrEmpty(getOptPar("CHANGE_ODL_MODE"))) diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaSiemens.cs b/IOB-WIN-NEXT/IobOpc/OpcUaSiemens.cs index e7b8be68..9ae41f38 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaSiemens.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaSiemens.cs @@ -21,7 +21,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaSiemens(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaSiemens(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init OpcUa Siemens"); // inizializzo classe base... diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaSiemensOMP.cs b/IOB-WIN-NEXT/IobOpc/OpcUaSiemensOMP.cs index 15b3e112..577db3dd 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaSiemensOMP.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaSiemensOMP.cs @@ -17,7 +17,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaSiemensOMP(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaSiemensOMP(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init OpcUa Siemens versione OMP (Cereria Finassi)"); diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaSiemensRama.cs b/IOB-WIN-NEXT/IobOpc/OpcUaSiemensRama.cs index cb026890..0841c37a 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaSiemensRama.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaSiemensRama.cs @@ -23,7 +23,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaSiemensRama(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaSiemensRama(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init OpcUa Siemens x RAMA"); doByteRead = true; diff --git a/IOB-WIN-NEXT/IobOpc/OpcUaUlma.cs b/IOB-WIN-NEXT/IobOpc/OpcUaUlma.cs index 4422734e..bfd4dab3 100644 --- a/IOB-WIN-NEXT/IobOpc/OpcUaUlma.cs +++ b/IOB-WIN-NEXT/IobOpc/OpcUaUlma.cs @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobOpc /// /// /// - public OpcUaUlma(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public OpcUaUlma(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("Init OpcUa ULMA"); // inizializzo classe base... diff --git a/IOB-WIN-NEXT/IobRest/Base.cs b/IOB-WIN-NEXT/IobRest/Base.cs index c24ca897..bd2d8ae3 100644 --- a/IOB-WIN-NEXT/IobRest/Base.cs +++ b/IOB-WIN-NEXT/IobRest/Base.cs @@ -14,7 +14,7 @@ namespace IOB_WIN_NEXT.IobRest /// /// Adapter base per sviluppo chiamate con servizi REST /// - public class Base : Iob.Generic + public class Base : Iob.GenericNext { #region Public Constructors @@ -23,7 +23,7 @@ namespace IOB_WIN_NEXT.IobRest /// /// AdapterForm chiamante /// Configurazione IOB per avvio - public Base(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Base(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo($"Richiesto Adapter IobRest.Base con i parametri seguenti | ADDR: {IOBConf.cncIpAddr} | PORT: {IOBConf.cncPort}"); lastPING = DateTime.Now.AddHours(-1); diff --git a/IOB-WIN-NEXT/IobRest/Citizen.cs b/IOB-WIN-NEXT/IobRest/Citizen.cs index 7c6115f3..8810f02b 100644 --- a/IOB-WIN-NEXT/IobRest/Citizen.cs +++ b/IOB-WIN-NEXT/IobRest/Citizen.cs @@ -24,7 +24,7 @@ namespace IOB_WIN_NEXT.IobRest /// /// AdapterForm chiamante /// Configurazione IOB per avvio - public Citizen(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Citizen(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo($"Richiesto Adapter IobRest.RestCitizen con i parametri seguenti | ADDR: {IOBConf.cncIpAddr} | PORT: {IOBConf.cncPort}"); lastPING = DateTime.Now.AddHours(-1); diff --git a/IOB-WIN-NEXT/IobSiemens/Siemens.cs b/IOB-WIN-NEXT/IobSiemens/Siemens.cs index 9863933e..e55ddc7d 100644 --- a/IOB-WIN-NEXT/IobSiemens/Siemens.cs +++ b/IOB-WIN-NEXT/IobSiemens/Siemens.cs @@ -12,7 +12,7 @@ using System.Threading; namespace IOB_WIN_NEXT.IobSiemens { - public class Siemens : Iob.Generic, IDisposable + public class Siemens : Iob.GenericNext, IDisposable { /* -------------------------------------------------------------------------------- * Controlli SIEMENS tramite libreria S7.net @@ -39,7 +39,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public Siemens(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Siemens(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { memMap = new plcMemMapExt(); writePre = true; diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensAprochim.cs b/IOB-WIN-NEXT/IobSiemens/SiemensAprochim.cs index ed507845..5c41ae5c 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensAprochim.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensAprochim.cs @@ -38,7 +38,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensAprochim(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensAprochim(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione APROCHIM"); // imposto i parametri speciali x calcolo... diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensAt2001.cs b/IOB-WIN-NEXT/IobSiemens/SiemensAt2001.cs index b6a1246c..1a69c0d8 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensAt2001.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensAt2001.cs @@ -26,7 +26,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensAt2001(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensAt2001(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione VIPA AT2001"); lastPLCWatchDog = DateTime.Now.AddMinutes(-1); diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensComeca.cs b/IOB-WIN-NEXT/IobSiemens/SiemensComeca.cs index 57fbad8d..8cb974c2 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensComeca.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensComeca.cs @@ -43,7 +43,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensComeca(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensComeca(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione Comeca"); } diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensComur.cs b/IOB-WIN-NEXT/IobSiemens/SiemensComur.cs index 5dac30ef..c7194eec 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensComur.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensComur.cs @@ -57,7 +57,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensComur(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensComur(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione COMUR"); } diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensCosmap.cs b/IOB-WIN-NEXT/IobSiemens/SiemensCosmap.cs index ebfd8611..36ca5013 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensCosmap.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensCosmap.cs @@ -43,7 +43,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensCosmap(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensCosmap(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione Cosmap"); } diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensFape.cs b/IOB-WIN-NEXT/IobSiemens/SiemensFape.cs index eb38bebc..07ae3980 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensFape.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensFape.cs @@ -32,7 +32,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensFape(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensFape(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione FAPE 1.0 - 2018"); } diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensFapeV2.cs b/IOB-WIN-NEXT/IobSiemens/SiemensFapeV2.cs index bcf58e03..7f1f72cd 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensFapeV2.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensFapeV2.cs @@ -56,7 +56,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensFapeV2(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensFapeV2(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { string sFapeVers = getOptPar("FAPE_VERS"); if (!string.IsNullOrEmpty(sFapeVers)) diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensIngenia.cs b/IOB-WIN-NEXT/IobSiemens/SiemensIngenia.cs index 61bc96db..38ec8cd2 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensIngenia.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensIngenia.cs @@ -66,7 +66,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensIngenia(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensIngenia(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione VIPA INGENIA"); lastPLCWatchDog = DateTime.Now.AddMinutes(-1); diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensLasco.cs b/IOB-WIN-NEXT/IobSiemens/SiemensLasco.cs index 93805657..73c0bcdc 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensLasco.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensLasco.cs @@ -30,7 +30,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensLasco(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensLasco(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione LASCO"); lastPLCWatchDog = DateTime.Now.AddMinutes(-1); diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensNWSE.cs b/IOB-WIN-NEXT/IobSiemens/SiemensNWSE.cs index 34a8980a..d951cb0a 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensNWSE.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensNWSE.cs @@ -44,7 +44,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensNWSE(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensNWSE(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione NWS"); diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensPressoilCei.cs b/IOB-WIN-NEXT/IobSiemens/SiemensPressoilCei.cs index fe85b250..6e3aa1a2 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensPressoilCei.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensPressoilCei.cs @@ -26,7 +26,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensPressoilCei(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensPressoilCei(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione PRESSOIL - CEI"); } diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensRobotService.cs b/IOB-WIN-NEXT/IobSiemens/SiemensRobotService.cs index 534cf48a..6a8ff331 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensRobotService.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensRobotService.cs @@ -52,7 +52,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensRobotService(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensRobotService(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione RobotService"); diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensSaet.cs b/IOB-WIN-NEXT/IobSiemens/SiemensSaet.cs index c19e3f76..efa3e302 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensSaet.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensSaet.cs @@ -67,7 +67,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensSaet(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensSaet(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione SAET"); lastPLCWatchDog = DateTime.Now.AddMinutes(-1); diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensSimec.cs b/IOB-WIN-NEXT/IobSiemens/SiemensSimec.cs index c1c6a6bb..ff068920 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensSimec.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensSimec.cs @@ -53,7 +53,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensSimec(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensSimec(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo("NEW IOB SIEMENS versione SIMEC"); } diff --git a/IOB-WIN-NEXT/IobSiemens/SiemensTorri.cs b/IOB-WIN-NEXT/IobSiemens/SiemensTorri.cs index 32054264..5dcd3f37 100644 --- a/IOB-WIN-NEXT/IobSiemens/SiemensTorri.cs +++ b/IOB-WIN-NEXT/IobSiemens/SiemensTorri.cs @@ -25,7 +25,7 @@ namespace IOB_WIN_NEXT.IobSiemens /// /// /// - public SiemensTorri(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SiemensTorri(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { // gestione restart OpcUa client... if (!string.IsNullOrEmpty(getOptPar("ENABLE_ALARM_LEGACY"))) diff --git a/IOB-WIN-NEXT/IobSoap/Gomba.cs b/IOB-WIN-NEXT/IobSoap/Gomba.cs index 2321c05e..773bbbf5 100644 --- a/IOB-WIN-NEXT/IobSoap/Gomba.cs +++ b/IOB-WIN-NEXT/IobSoap/Gomba.cs @@ -14,7 +14,7 @@ namespace IOB_WIN_NEXT.IobSoap /// /// Adapter specializzato per GOMA e le chiamate tramite WS Soap alla bilancia, libreria EgwProxy.Gomba /// - public class Gomba : Iob.Generic + public class Gomba : Iob.GenericNext { #region Public Constructors @@ -23,7 +23,7 @@ namespace IOB_WIN_NEXT.IobSoap /// /// AdapterForm chiamante /// Configurazione IOB per avvio - public Gomba(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public Gomba(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { lgInfo($"Richiesto Adapter IobSoap.Gomba con i parametri seguenti | ADDR: {IOBConf.cncIpAddr} | PORT: {IOBConf.cncPort}"); redKeyPesate = redisMan.redHash($"IOB:Status:{cIobConf.codIOB}:ListPesate"); diff --git a/IOB-WIN-NEXT/IobSql/IcoelDb.cs b/IOB-WIN-NEXT/IobSql/IcoelDb.cs index 2011c013..21cf7cc5 100644 --- a/IOB-WIN-NEXT/IobSql/IcoelDb.cs +++ b/IOB-WIN-NEXT/IobSql/IcoelDb.cs @@ -15,7 +15,7 @@ namespace IOB_WIN_NEXT.IobSql /// - tracciabilità (confezioni /// - public class IcoelDb : Iob.Generic + public class IcoelDb : Iob.GenericNext { #region Public Constructors @@ -24,7 +24,7 @@ namespace IOB_WIN_NEXT.IobSql /// /// AdapterForm chiamante /// Configurazione IOB per avvio - public IcoelDb(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public IcoelDb(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { /* -------------------------------------- * todo's diff --git a/IOB-WIN-NEXT/IobSql/SqlServLantek.cs b/IOB-WIN-NEXT/IobSql/SqlServLantek.cs index 1f991c4a..4be0ca31 100644 --- a/IOB-WIN-NEXT/IobSql/SqlServLantek.cs +++ b/IOB-WIN-NEXT/IobSql/SqlServLantek.cs @@ -18,7 +18,7 @@ namespace IOB_WIN_NEXT.IobSql /// - ProdLog (da NestingDaLantek + RigheNestingDaLantek) /// - public class SqlServLantek : Iob.Generic + public class SqlServLantek : Iob.GenericNext { #region Public Constructors @@ -27,7 +27,7 @@ namespace IOB_WIN_NEXT.IobSql /// /// AdapterForm chiamante /// Configurazione IOB per avvio - public SqlServLantek(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SqlServLantek(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { DateTime adesso = DateTime.Now; string SyncStateServ = getOptPar("SyncStateServer"); diff --git a/IOB-WIN-NEXT/IobSql/SqlServPama.cs b/IOB-WIN-NEXT/IobSql/SqlServPama.cs index c1f9d8c6..4a2db88b 100644 --- a/IOB-WIN-NEXT/IobSql/SqlServPama.cs +++ b/IOB-WIN-NEXT/IobSql/SqlServPama.cs @@ -19,7 +19,7 @@ namespace IOB_WIN_NEXT.IobSql /// - FluxLog (da stato macchina) /// - ProdLog (da stato Prod) /// - public class SqlServPama : Iob.Generic + public class SqlServPama : Iob.GenericNext { #region Public Constructors @@ -28,7 +28,7 @@ namespace IOB_WIN_NEXT.IobSql /// /// AdapterForm chiamante /// Configurazione IOB per avvio - public SqlServPama(AdapterForm caller, IobConfiguration IOBConf) : base(caller, IOBConf) + public SqlServPama(AdapterFormNext caller, IobConfiguration IOBConf) : base(caller, IOBConf) { string SyncStateServ = getOptPar("SyncStateServer"); string SyncStateDb = getOptPar("SyncStateDb"); diff --git a/IOB-WIN-NEXT/MainForm.Designer.cs b/IOB-WIN-NEXT/MainForm.Designer.cs deleted file mode 100644 index d33fa58a..00000000 --- a/IOB-WIN-NEXT/MainForm.Designer.cs +++ /dev/null @@ -1,325 +0,0 @@ -namespace IOB_WIN_NEXT -{ - partial class MainForm - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.components = new System.ComponentModel.Container(); - System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm)); - this.statusStrip1 = new System.Windows.Forms.StatusStrip(); - this.lblApp = new System.Windows.Forms.ToolStripStatusLabel(); - this.lblVers = new System.Windows.Forms.ToolStripStatusLabel(); - this.MainProgrBar = new System.Windows.Forms.ToolStripProgressBar(); - this.lblComStats = new System.Windows.Forms.ToolStripStatusLabel(); - this.toolStripStatusLabel3 = new System.Windows.Forms.ToolStripStatusLabel(); - this.lblStatus = new System.Windows.Forms.ToolStripStatusLabel(); - this.toolStripStatusLabel1 = new System.Windows.Forms.ToolStripStatusLabel(); - this.tslRunTime = new System.Windows.Forms.ToolStripStatusLabel(); - this.menuStrip1 = new System.Windows.Forms.MenuStrip(); - this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.mCheckUpdates = new System.Windows.Forms.ToolStripMenuItem(); - this.mShowMainLog = new System.Windows.Forms.ToolStripMenuItem(); - this.closeChildToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.closeALLAdaptersToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.restartALLAdaptersToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.uploadIOBConfToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.downloadIOBConfToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.sendIOBAssignmentsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.getIOBAssignmentsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.windowToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.arrangeWindowsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.minimizeALLToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.MainTimer = new System.Windows.Forms.Timer(this.components); - this.notifyIcon1 = new System.Windows.Forms.NotifyIcon(this.components); - this.trayMenu = new System.Windows.Forms.ContextMenuStrip(this.components); - this.statusStrip1.SuspendLayout(); - this.menuStrip1.SuspendLayout(); - this.SuspendLayout(); - // - // statusStrip1 - // - this.statusStrip1.ImageScalingSize = new System.Drawing.Size(20, 20); - this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.lblApp, - this.lblVers, - this.MainProgrBar, - this.lblComStats, - this.toolStripStatusLabel3, - this.lblStatus, - this.toolStripStatusLabel1, - this.tslRunTime}); - this.statusStrip1.Location = new System.Drawing.Point(0, 507); - this.statusStrip1.Name = "statusStrip1"; - this.statusStrip1.Padding = new System.Windows.Forms.Padding(1, 0, 10, 0); - this.statusStrip1.Size = new System.Drawing.Size(713, 23); - this.statusStrip1.TabIndex = 1; - this.statusStrip1.Text = "statusStrip1"; - // - // lblApp - // - this.lblApp.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold); - this.lblApp.Name = "lblApp"; - this.lblApp.Size = new System.Drawing.Size(22, 18); - this.lblApp.Text = "---"; - // - // lblVers - // - this.lblVers.Name = "lblVers"; - this.lblVers.Size = new System.Drawing.Size(16, 18); - this.lblVers.Text = "..."; - // - // MainProgrBar - // - this.MainProgrBar.Name = "MainProgrBar"; - this.MainProgrBar.Size = new System.Drawing.Size(75, 17); - this.MainProgrBar.Step = 1; - this.MainProgrBar.Style = System.Windows.Forms.ProgressBarStyle.Marquee; - // - // lblComStats - // - this.lblComStats.Name = "lblComStats"; - this.lblComStats.Size = new System.Drawing.Size(32, 18); - this.lblComStats.Text = "Stats"; - // - // toolStripStatusLabel3 - // - this.toolStripStatusLabel3.Name = "toolStripStatusLabel3"; - this.toolStripStatusLabel3.Size = new System.Drawing.Size(10, 18); - this.toolStripStatusLabel3.Text = "|"; - // - // lblStatus - // - this.lblStatus.Name = "lblStatus"; - this.lblStatus.Size = new System.Drawing.Size(22, 18); - this.lblStatus.Text = "---"; - // - // toolStripStatusLabel1 - // - this.toolStripStatusLabel1.Name = "toolStripStatusLabel1"; - this.toolStripStatusLabel1.Size = new System.Drawing.Size(10, 18); - this.toolStripStatusLabel1.Text = "|"; - // - // tslRunTime - // - this.tslRunTime.Name = "tslRunTime"; - this.tslRunTime.Size = new System.Drawing.Size(16, 18); - this.tslRunTime.Text = "..."; - // - // menuStrip1 - // - this.menuStrip1.ImageScalingSize = new System.Drawing.Size(20, 20); - this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.fileToolStripMenuItem, - this.closeChildToolStripMenuItem, - this.windowToolStripMenuItem}); - this.menuStrip1.Location = new System.Drawing.Point(0, 0); - this.menuStrip1.Name = "menuStrip1"; - this.menuStrip1.Padding = new System.Windows.Forms.Padding(4, 2, 0, 2); - this.menuStrip1.Size = new System.Drawing.Size(713, 24); - this.menuStrip1.TabIndex = 2; - this.menuStrip1.Text = "menuStrip1"; - // - // fileToolStripMenuItem - // - this.fileToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.mCheckUpdates, - this.mShowMainLog}); - this.fileToolStripMenuItem.Name = "fileToolStripMenuItem"; - this.fileToolStripMenuItem.Size = new System.Drawing.Size(37, 20); - this.fileToolStripMenuItem.Text = "&File"; - // - // mCheckUpdates - // - this.mCheckUpdates.Name = "mCheckUpdates"; - this.mCheckUpdates.Size = new System.Drawing.Size(186, 22); - this.mCheckUpdates.Text = "Check for &Updates"; - this.mCheckUpdates.Click += new System.EventHandler(this.mCheckUpdates_Click); - // - // mShowMainLog - // - this.mShowMainLog.Name = "mShowMainLog"; - this.mShowMainLog.Size = new System.Drawing.Size(186, 22); - this.mShowMainLog.Text = "Open &LogFile (MAIN)"; - this.mShowMainLog.Click += new System.EventHandler(this.MShowMainLog_Click); - // - // closeChildToolStripMenuItem - // - this.closeChildToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.closeALLAdaptersToolStripMenuItem, - this.restartALLAdaptersToolStripMenuItem, - this.uploadIOBConfToolStripMenuItem, - this.downloadIOBConfToolStripMenuItem, - this.sendIOBAssignmentsToolStripMenuItem, - this.getIOBAssignmentsToolStripMenuItem}); - this.closeChildToolStripMenuItem.Name = "closeChildToolStripMenuItem"; - this.closeChildToolStripMenuItem.Size = new System.Drawing.Size(121, 20); - this.closeChildToolStripMenuItem.Text = "A&dapters Functions"; - // - // closeALLAdaptersToolStripMenuItem - // - this.closeALLAdaptersToolStripMenuItem.Name = "closeALLAdaptersToolStripMenuItem"; - this.closeALLAdaptersToolStripMenuItem.Size = new System.Drawing.Size(203, 22); - this.closeALLAdaptersToolStripMenuItem.Text = "&Close ALL Adapters"; - this.closeALLAdaptersToolStripMenuItem.Click += new System.EventHandler(this.closeALLAdaptersToolStripMenuItem_Click); - // - // restartALLAdaptersToolStripMenuItem - // - this.restartALLAdaptersToolStripMenuItem.Name = "restartALLAdaptersToolStripMenuItem"; - this.restartALLAdaptersToolStripMenuItem.ShortcutKeyDisplayString = "ALT-R"; - this.restartALLAdaptersToolStripMenuItem.ShowShortcutKeys = false; - this.restartALLAdaptersToolStripMenuItem.Size = new System.Drawing.Size(203, 22); - this.restartALLAdaptersToolStripMenuItem.Text = "&Restart ALL Adapters"; - this.restartALLAdaptersToolStripMenuItem.Click += new System.EventHandler(this.restartALLAdaptersToolStripMenuItem_Click); - // - // uploadIOBConfToolStripMenuItem - // - this.uploadIOBConfToolStripMenuItem.Name = "uploadIOBConfToolStripMenuItem"; - this.uploadIOBConfToolStripMenuItem.Size = new System.Drawing.Size(203, 22); - this.uploadIOBConfToolStripMenuItem.Text = "Upload IOB Conf files"; - this.uploadIOBConfToolStripMenuItem.Click += new System.EventHandler(this.uploadIOBConfToolStripMenuItem_Click); - // - // downloadIOBConfToolStripMenuItem - // - this.downloadIOBConfToolStripMenuItem.Name = "downloadIOBConfToolStripMenuItem"; - this.downloadIOBConfToolStripMenuItem.Size = new System.Drawing.Size(203, 22); - this.downloadIOBConfToolStripMenuItem.Text = "Download IOB Conf files"; - this.downloadIOBConfToolStripMenuItem.Click += new System.EventHandler(this.downloadIOBConfToolStripMenuItem_Click); - // - // sendIOBAssignmentsToolStripMenuItem - // - this.sendIOBAssignmentsToolStripMenuItem.Enabled = false; - this.sendIOBAssignmentsToolStripMenuItem.Name = "sendIOBAssignmentsToolStripMenuItem"; - this.sendIOBAssignmentsToolStripMenuItem.Size = new System.Drawing.Size(203, 22); - this.sendIOBAssignmentsToolStripMenuItem.Text = "Send IOB Assignments"; - this.sendIOBAssignmentsToolStripMenuItem.Click += new System.EventHandler(this.sendIOBAssignmentsToolStripMenuItem_Click); - // - // getIOBAssignmentsToolStripMenuItem - // - this.getIOBAssignmentsToolStripMenuItem.Enabled = false; - this.getIOBAssignmentsToolStripMenuItem.Name = "getIOBAssignmentsToolStripMenuItem"; - this.getIOBAssignmentsToolStripMenuItem.Size = new System.Drawing.Size(203, 22); - this.getIOBAssignmentsToolStripMenuItem.Text = "Get IOB Assignments"; - this.getIOBAssignmentsToolStripMenuItem.Click += new System.EventHandler(this.getIOBAssignmentsToolStripMenuItem_Click); - // - // windowToolStripMenuItem - // - this.windowToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.arrangeWindowsToolStripMenuItem, - this.minimizeALLToolStripMenuItem}); - this.windowToolStripMenuItem.Name = "windowToolStripMenuItem"; - this.windowToolStripMenuItem.Size = new System.Drawing.Size(63, 20); - this.windowToolStripMenuItem.Text = "&Window"; - // - // arrangeWindowsToolStripMenuItem - // - this.arrangeWindowsToolStripMenuItem.Name = "arrangeWindowsToolStripMenuItem"; - this.arrangeWindowsToolStripMenuItem.Size = new System.Drawing.Size(184, 22); - this.arrangeWindowsToolStripMenuItem.Text = "Re-arran&ge Windows"; - this.arrangeWindowsToolStripMenuItem.Click += new System.EventHandler(this.arrangeWindowsToolStripMenuItem_Click); - // - // minimizeALLToolStripMenuItem - // - this.minimizeALLToolStripMenuItem.Name = "minimizeALLToolStripMenuItem"; - this.minimizeALLToolStripMenuItem.Size = new System.Drawing.Size(184, 22); - this.minimizeALLToolStripMenuItem.Text = "&Minimize ALL"; - this.minimizeALLToolStripMenuItem.Click += new System.EventHandler(this.minimizeALLToolStripMenuItem_Click); - // - // MainTimer - // - this.MainTimer.Enabled = true; - this.MainTimer.Interval = 20; - this.MainTimer.Tick += new System.EventHandler(this.MainTimer_Tick); - // - // notifyIcon1 - // - this.notifyIcon1.ContextMenuStrip = this.trayMenu; - this.notifyIcon1.Text = "IOB-WIN-NEXT"; - this.notifyIcon1.Visible = true; - this.notifyIcon1.DoubleClick += new System.EventHandler(this.notifyIcon1_DoubleClick); - // - // trayMenu - // - this.trayMenu.ImageScalingSize = new System.Drawing.Size(20, 20); - this.trayMenu.Name = "trayMenu"; - this.trayMenu.Size = new System.Drawing.Size(61, 4); - this.trayMenu.ItemClicked += new System.Windows.Forms.ToolStripItemClickedEventHandler(this.trayMenu_ItemClicked); - // - // MainForm - // - this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(713, 530); - this.Controls.Add(this.statusStrip1); - this.Controls.Add(this.menuStrip1); - this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); - this.IsMdiContainer = true; - this.MainMenuStrip = this.menuStrip1; - this.Margin = new System.Windows.Forms.Padding(2); - this.Name = "MainForm"; - this.Text = "IOB WIN"; - this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.MainForm_FormClosing); - this.Shown += new System.EventHandler(this.MainForm_Shown); - this.Resize += new System.EventHandler(this.MainForm_Resize); - this.statusStrip1.ResumeLayout(false); - this.statusStrip1.PerformLayout(); - this.menuStrip1.ResumeLayout(false); - this.menuStrip1.PerformLayout(); - this.ResumeLayout(false); - this.PerformLayout(); - - } - - #endregion - - private System.Windows.Forms.StatusStrip statusStrip1; - private System.Windows.Forms.MenuStrip menuStrip1; - private System.Windows.Forms.ToolStripMenuItem fileToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem mCheckUpdates; - private System.Windows.Forms.ToolStripMenuItem windowToolStripMenuItem; - private System.Windows.Forms.ToolStripStatusLabel lblApp; - private System.Windows.Forms.ToolStripStatusLabel lblVers; - private System.Windows.Forms.ToolStripProgressBar MainProgrBar; - private System.Windows.Forms.ToolStripStatusLabel lblComStats; - private System.Windows.Forms.ToolStripStatusLabel lblStatus; - private System.Windows.Forms.ToolStripStatusLabel toolStripStatusLabel1; - private System.Windows.Forms.Timer MainTimer; - private System.Windows.Forms.NotifyIcon notifyIcon1; - private System.Windows.Forms.ContextMenuStrip trayMenu; - private System.Windows.Forms.ToolStripStatusLabel tslRunTime; - private System.Windows.Forms.ToolStripStatusLabel toolStripStatusLabel3; - private System.Windows.Forms.ToolStripMenuItem closeChildToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem uploadIOBConfToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem downloadIOBConfToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem sendIOBAssignmentsToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem getIOBAssignmentsToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem restartALLAdaptersToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem arrangeWindowsToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem minimizeALLToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem closeALLAdaptersToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem mShowMainLog; - } -} \ No newline at end of file diff --git a/IOB-WIN-NEXT/Program.cs b/IOB-WIN-NEXT/Program.cs index 621d64c5..e099b171 100644 --- a/IOB-WIN-NEXT/Program.cs +++ b/IOB-WIN-NEXT/Program.cs @@ -16,7 +16,7 @@ namespace IOB_WIN_NEXT { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); - Application.Run(new MainForm(args)); + Application.Run(new IOB_WIN_FORM.MainForm(args)); } #endregion Private Methods diff --git a/VersGen/VersGen.cs b/VersGen/VersGen.cs index f50f8382..f9851db4 100644 --- a/VersGen/VersGen.cs +++ b/VersGen/VersGen.cs @@ -5,5 +5,5 @@ using System.Reflection; [assembly: AssemblyVersion("0.0.0.0")] [assembly: AssemblyFileVersion("0.0.0.0")] -[assembly: AssemblyCopyright("EgalWare © 2006")] +[assembly: AssemblyCopyright("EgalWare © 2006+")] [assembly: AssemblyCompany("EgalWare")] \ No newline at end of file diff --git a/VersGen/VersGen.vb b/VersGen/VersGen.vb index f61cd57b..718fc6b0 100644 --- a/VersGen/VersGen.vb +++ b/VersGen/VersGen.vb @@ -5,4 +5,4 @@ Imports System.Runtime.InteropServices - +