From 2e27eaeb3515cb4cc9b9365ef5433befd1773d4e Mon Sep 17 00:00:00 2001 From: Roland Drabesch Date: Wed, 30 Nov 2022 09:36:31 +0100 Subject: [PATCH] comm --- Common/.vs/config/applicationhost.config | 2 +- .../Interfaces/Ports/SerialPorts/BaseSerialPort.cs | 8 ++++++++ .../WaterMeterRegisters.csproj.CoreCompileInputs.cache | 2 +- Common/Ui/GenesisToolBox/FrmLutUpdate.Designer.cs | 1 + Common/Ui/GenesisToolBox/FrmLutUpdate.cs | 5 +++++ 5 files changed, 16 insertions(+), 2 deletions(-) diff --git a/Common/.vs/config/applicationhost.config b/Common/.vs/config/applicationhost.config index 1b9332b4..40cde372 100644 --- a/Common/.vs/config/applicationhost.config +++ b/Common/.vs/config/applicationhost.config @@ -155,7 +155,7 @@ - + diff --git a/Common/Hardware/Interfaces/Ports/SerialPorts/BaseSerialPort.cs b/Common/Hardware/Interfaces/Ports/SerialPorts/BaseSerialPort.cs index 47445680..64fee313 100644 --- a/Common/Hardware/Interfaces/Ports/SerialPorts/BaseSerialPort.cs +++ b/Common/Hardware/Interfaces/Ports/SerialPorts/BaseSerialPort.cs @@ -605,8 +605,16 @@ namespace Xylem.Common.Hardware.Interfaces.Ports.SerialPorts if (_serialPort.IsOpen) { _serialPort.Close(); + if (_serialPort.IsOpen) + { + _byteDataLogger.Info($"{Ident} Port close delay!"); + Thread.Sleep(50); + _serialPort.Close(); + } _serialPort.Dispose(); _byteDataLogger.Info($"{Ident} Port is closed"); + + } } } diff --git a/Common/Hardware/WaterMeter/WaterMeterCore/WaterMeterRegisters/obj/Debug/WaterMeterRegisters.csproj.CoreCompileInputs.cache b/Common/Hardware/WaterMeter/WaterMeterCore/WaterMeterRegisters/obj/Debug/WaterMeterRegisters.csproj.CoreCompileInputs.cache index d8b5c8f6..f22623aa 100644 --- a/Common/Hardware/WaterMeter/WaterMeterCore/WaterMeterRegisters/obj/Debug/WaterMeterRegisters.csproj.CoreCompileInputs.cache +++ b/Common/Hardware/WaterMeter/WaterMeterCore/WaterMeterRegisters/obj/Debug/WaterMeterRegisters.csproj.CoreCompileInputs.cache @@ -1 +1 @@ -1a3d4919c9c702245832d925951f2b7cb72fc333 +5ed75d99ee45ff67821090f1b3dbb001dd9e4fe3 diff --git a/Common/Ui/GenesisToolBox/FrmLutUpdate.Designer.cs b/Common/Ui/GenesisToolBox/FrmLutUpdate.Designer.cs index b5eb6fa0..05edd61b 100644 --- a/Common/Ui/GenesisToolBox/FrmLutUpdate.Designer.cs +++ b/Common/Ui/GenesisToolBox/FrmLutUpdate.Designer.cs @@ -387,6 +387,7 @@ this.rbtProd.TabStop = true; this.rbtProd.Text = "Prod Database"; this.rbtProd.UseVisualStyleBackColor = true; + this.rbtProd.CheckedChanged += new System.EventHandler(this.rbtProd_CheckedChanged); this.rbtProd.Click += new System.EventHandler(this.SwitchView); // // cbxDbLuts diff --git a/Common/Ui/GenesisToolBox/FrmLutUpdate.cs b/Common/Ui/GenesisToolBox/FrmLutUpdate.cs index 5cfcdbf6..342c08cc 100644 --- a/Common/Ui/GenesisToolBox/FrmLutUpdate.cs +++ b/Common/Ui/GenesisToolBox/FrmLutUpdate.cs @@ -810,6 +810,11 @@ namespace Xylem.Common.Ui.GenesisToolBox _resetTimeMeasurement = true; } } + + private void rbtProd_CheckedChanged(Object sender, EventArgs e) + { + + } } }