diff --git a/Common/Hardware/WaterMeter/Genesis/GenesisFile/MeterFwUpdate.cs b/Common/Hardware/WaterMeter/Genesis/GenesisFile/MeterFwUpdate.cs
index 57a18ed3..9c89ba43 100644
--- a/Common/Hardware/WaterMeter/Genesis/GenesisFile/MeterFwUpdate.cs
+++ b/Common/Hardware/WaterMeter/Genesis/GenesisFile/MeterFwUpdate.cs
@@ -176,6 +176,11 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.GenesisFile
///
public Boolean StoreConfigEnable = true;
+ ///
+ /// Allow update of genesis flow application
+ ///
+ public Boolean UpdateGenesisFlowEnable;
+
///
/// Enable partial file writes from first failed part to the end
///
@@ -245,6 +250,7 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.GenesisFile
/// Ctor
///
///
+ /// enable update of genesis flow app
///
/// - Initial
///
@@ -254,13 +260,17 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.GenesisFile
///
/// - Check installed application before require access to registers.
///
- public MeterFwUpdate(GenesisMeter genesisMeter)
+ ///
+ /// - Enable update of Genesis Flow on request.
+ ///
+ public MeterFwUpdate(GenesisMeter genesisMeter, Boolean updateGenesisFlowEnable = false)
{
if (genesisMeter == null)
{
return;
}
+ UpdateGenesisFlowEnable = updateGenesisFlowEnable;
AssignGenesis(genesisMeter);
if (genesisMeter.MeterAppListVersion.Any(f => f.AppName == "GENESISFLOW" && f.IsInstalled))
@@ -277,6 +287,11 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.GenesisFile
{
_registersBeforeUpdate.Add(Register.Sensusradio.WakeupInterval, new Byte[] { 6 });
}
+
+ if (UpdateGenesisFlowEnable)
+ {
+ _registersBeforeUpdate.Add(Register.System.MetrologyUpgradePermission, new Byte[] { 0xFF, 0, 0, 0 });
+ }
}
///
@@ -1829,15 +1844,20 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.GenesisFile
///
/// - Extended timeout.
///
+ ///
+ /// - Set retry counter to 0,
+ /// - reduce timeout from 5000 to 2000 ms.
+ ///
private Boolean TriggerUpgrade()
{
Boolean returnValue;
//trigger upgrade
_actualOperation = Resources.StrFwUpdateStateTriggerUpgrade;
+ _updateProcedureRetryCtr = 0;
var triggerCtr = 0;
//set extended timeout for trigger upgrade response delay
- _genesisMeter.TransmitProtocol.SetResponseTimeout(5000);
+ _genesisMeter.TransmitProtocol.SetResponseTimeout(2000);
do
{
returnValue = _genesisMeter.WriteRegister(Register.System.TriggerFwUpgrade, 1);
diff --git a/Common/Metrology/Docu/CordonelCalFactorCalculationCheck_JustageVerscheidenWerte.xlsx b/Common/Metrology/Docu/CordonelCalFactorCalculationCheck_JustageVerscheidenWerte.xlsx
new file mode 100644
index 00000000..c0de7756
Binary files /dev/null and b/Common/Metrology/Docu/CordonelCalFactorCalculationCheck_JustageVerscheidenWerte.xlsx differ
diff --git a/Common/ProductionUiCordonel/App.xaml.cs b/Common/ProductionUiCordonel/App.xaml.cs
index e252be06..b5d91a56 100644
--- a/Common/ProductionUiCordonel/App.xaml.cs
+++ b/Common/ProductionUiCordonel/App.xaml.cs
@@ -1,4 +1,5 @@
-using System.Windows;
+using System;
+using System.Windows;
using System.Windows.Input;
namespace ProductionUiCordonel
@@ -13,7 +14,7 @@ namespace ProductionUiCordonel
//this.StartupUri = new Uri("MainWindow.xaml");
//this.StartupUri = new Uri("MultiMode.xaml");
}
- private void Application_Startup(object sender, StartupEventArgs e)
+ private void Application_Startup(Object sender, StartupEventArgs e)
{
if (true)
diff --git a/Common/ProductionUiCordonel/ApplicationSettings.cs b/Common/ProductionUiCordonel/ApplicationSettings.cs
index 20369925..28c2e56a 100644
--- a/Common/ProductionUiCordonel/ApplicationSettings.cs
+++ b/Common/ProductionUiCordonel/ApplicationSettings.cs
@@ -14,40 +14,40 @@ namespace ProductionUiCordonel
public class Pos
{
- public double Left { get; set; }
- public double Top { get; set; }
- public double Height { get; set; }
- public double Width { get; set; }
+ public Double Left { get; set; }
+ public Double Top { get; set; }
+ public Double Height { get; set; }
+ public Double Width { get; set; }
}
public class MultiFormChilds
{
public Type ViewModelType { get; set; }
- public bool Visisble { get; set; }
- public string Name { get; set; }
- public int Slot { get; set; }
- public string TextPort { get; set; }
+ public Boolean Visisble { get; set; }
+ public String Name { get; set; }
+ public Int32 Slot { get; set; }
+ public String TextPort { get; set; }
public Pos StartPos { get; set; }
}
- public int Slot { get; set; }
+ public Int32 Slot { get; set; }
- public int? PressureStationId { get; set; }
- public bool AutoDetect { get; set; }
+ public Int32? PressureStationId { get; set; }
+ public Boolean AutoDetect { get; set; }
- public bool AccessToPresuretestTab { get; set; }
- public bool AccessToMarrieTab { get; set; }
- public bool AccessToFinalcheckTab { get; set; }
+ public Boolean AccessToPresuretestTab { get; set; }
+ public Boolean AccessToMarrieTab { get; set; }
+ public Boolean AccessToFinalcheckTab { get; set; }
- public bool AccessToSettingTab { get; set; }
- public bool AccessToStatusTab { get; set; }
- public bool AccessToPickingTab { get; set; }
+ public Boolean AccessToSettingTab { get; set; }
+ public Boolean AccessToStatusTab { get; set; }
+ public Boolean AccessToPickingTab { get; set; }
- public int? SirtComport433 { get; set; }
- public int? SirtComport866 { get; set; }
- public int? SirtBoxNr { get; set; }
+ public Int32? SirtComport433 { get; set; }
+ public Int32? SirtComport866 { get; set; }
+ public Int32? SirtBoxNr { get; set; }
- public int? StationId { get; set; }
+ public Int32? StationId { get; set; }
public List ChildForms { get; set; }
diff --git a/Common/ProductionUiCordonel/Data/FinalTestState.cs b/Common/ProductionUiCordonel/Data/FinalTestState.cs
new file mode 100644
index 00000000..1981f6d7
--- /dev/null
+++ b/Common/ProductionUiCordonel/Data/FinalTestState.cs
@@ -0,0 +1,101 @@
+namespace ProductionUiCordonel.Data
+{
+ ///
+ /// Genesis meter final test states
+ ///
+ public enum FinalTestState
+ {
+ ///
+ /// Idle (nothing to do)
+ ///
+ Idle,
+ ///
+ /// Start the initial execution
+ ///
+ StartInitial,
+ ///
+ /// Error handling
+ ///
+ Error,
+ ///
+ /// Single processing step failed
+ ///
+ StepFailed,
+ ///
+ /// Repeat last step
+ ///
+ RepeatStep,
+ ///
+ /// Repeat the entire final test
+ ///
+ RepeatFinalTest,
+ ///
+ /// Final test failed
+ ///
+ FinalTestFailed,
+ ///
+ /// Check the actual shipping state
+ ///
+ CheckShippingState,
+ ///
+ /// Check the attachments
+ ///
+ CheckAttachments,
+ ///
+ /// Check the order number
+ ///
+ CheckOrderNumber,
+ ///
+ /// Check the serial number
+ ///
+ CheckSerialNumber,
+ ///
+ /// Connect to Cordonel
+ ///
+ ConnectCordonel,
+ ///
+ /// Store all configurations to FLASH memory
+ ///
+ StoreAllConfigurations,
+ ///
+ /// Reboot the Cordonel to check all parameters being stored to FLASH memory
+ ///
+ RebootCordonel,
+ ///
+ /// Finalize process
+ ///
+ FinalizeProcess,
+ ///
+ /// Final parametrization fixed values
+ ///
+ FinalParametrizationFix,
+ ///
+ /// Final parametrization with VAKO and CSD
+ ///
+ FinalParametrizationVakoCsd,
+ ///
+ /// Read out all parametrization values
+ ///
+ FullReadOutParametrization,
+ ///
+ /// Check all settings for against required values
+ ///
+ ConfigurationCheck,
+ ///
+ /// Acquire, process set the password file
+ ///
+ ProcessPasswordFile,
+ ///
+ /// Process special configuration
+ ///
+ ProcessSpecialConfig,
+ ///
+ /// Prepare shipping mode
+ ///
+ PrepareShippingMode,
+ ///
+ /// Delimiter for list
+ ///
+ StateListDelimiter
+ }
+}
\ No newline at end of file
diff --git a/Common/ProductionUiCordonel/Data/FinalTestStateInfo.cs b/Common/ProductionUiCordonel/Data/FinalTestStateInfo.cs
new file mode 100644
index 00000000..bfcbca55
--- /dev/null
+++ b/Common/ProductionUiCordonel/Data/FinalTestStateInfo.cs
@@ -0,0 +1,52 @@
+using System;
+using System.Linq;
+using ProductionUiCordonel.Properties;
+
+namespace ProductionUiCordonel.Data
+{
+ ///
+ /// Concatenation of state and string
+ ///
+ public static class FinalTestStateInfo
+ {
+ ///
+ /// Build state information
+ ///
+ private static readonly FinalTestStateText[] StateInfos;
+
+ ///
+ /// Ctor
+ ///
+ static FinalTestStateInfo()
+ {
+ StateInfos = new FinalTestStateText[(Int32)FinalTestState.StateListDelimiter];
+ StateInfos[(Int32)FinalTestState.Idle].State = FinalTestState.Idle;
+ StateInfos[(Int32)FinalTestState.Idle].Message = Resources.StrStateIdle;
+
+ StateInfos[(Int32)FinalTestState.StartInitial].State = FinalTestState.StartInitial;
+ StateInfos[(Int32)FinalTestState.StartInitial].Message = Resources.StrStateStartInitial;
+
+ }
+
+ ///
+ /// Get the current information
+ ///
+ /// state to search for information text
+ public static String GetTextFromState(FinalTestState state)
+ {
+ return (from stateInfo in StateInfos
+ where stateInfo.State == state
+ select stateInfo.Message).FirstOrDefault();
+ }
+ ///
+ /// Get the state of the text
+ ///
+ /// information text to search if state is assigned
+ public static FinalTestState GetStateFromText(String text)
+ {
+ return (from stateInfo in StateInfos
+ where stateInfo.Message == text
+ select stateInfo.State).FirstOrDefault();
+ }
+ }
+}
diff --git a/Common/ProductionUiCordonel/Data/FinalTestStateText.cs b/Common/ProductionUiCordonel/Data/FinalTestStateText.cs
new file mode 100644
index 00000000..4bfd80cf
--- /dev/null
+++ b/Common/ProductionUiCordonel/Data/FinalTestStateText.cs
@@ -0,0 +1,19 @@
+using System;
+
+namespace ProductionUiCordonel.Data
+{
+ ///
+ /// Concatenation between final test state and text
+ ///
+ public struct FinalTestStateText
+ {
+ ///
+ /// The state of the final test
+ ///
+ public FinalTestState State;
+ ///
+ /// The message text of the final test state
+ ///
+ public String Message;
+ }
+}
diff --git a/Common/ProductionUiCordonel/Data/PickingResultData.cs b/Common/ProductionUiCordonel/Data/PickingResultData.cs
index 3f6c5f93..4d12f73f 100644
--- a/Common/ProductionUiCordonel/Data/PickingResultData.cs
+++ b/Common/ProductionUiCordonel/Data/PickingResultData.cs
@@ -10,23 +10,23 @@ namespace ProductionUiCordonel.Data
{
public class PickingItemCheckReturn
{
- public bool? Result;
- public string Msg;
+ public Boolean? Result;
+ public String Msg;
}
public abstract class PickingResultBaseData : IPickingResultData
{
- public string Ident { get; set; }
+ public String Ident { get; set; }
- public int Index { get; set; }
+ public Int32 Index { get; set; }
- public string CheckText { get; set; }
+ public String CheckText { get; set; }
- public string CurrentValueText { get; set; }
+ public String CurrentValueText { get; set; }
- public bool? Result { get; set; }
+ public Boolean? Result { get; set; }
- public bool HasError { get; set; }
+ public Boolean HasError { get; set; }
public System.Windows.Media.Brush ResultColor { get { return getColorFromResult(); } }
public abstract Func Action { get; }
@@ -54,16 +54,16 @@ public abstract class PickingResultBaseData : IPickingResultData
}
public interface IPickingResultData
{
- string Ident { get; set; }
+ String Ident { get; set; }
- int Index { get; set; }
- string CheckText { get; set; }
+ Int32 Index { get; set; }
+ String CheckText { get; set; }
- string CurrentValueText { get; set; }
+ String CurrentValueText { get; set; }
- bool? Result { get; set; }
+ Boolean? Result { get; set; }
- bool HasError { get; set; }
+ Boolean HasError { get; set; }
System.Windows.Media.Brush ResultColor { get; }
@@ -71,11 +71,11 @@ public abstract class PickingResultBaseData : IPickingResultData
}
public class PickingResultRegisterData : PickingResultBaseData
{
- public string RegisterIdent { get; set; }
+ public String RegisterIdent { get; set; }
public GenesisMeter ReadMeter { get; set; }
- public object CompareObject { get; set; }
+ public Object CompareObject { get; set; }
public override Func Action { get { return staticReadAndCompareAction(); } }
@@ -97,7 +97,7 @@ public abstract class PickingResultBaseData : IPickingResultData
}
else if (CompareObject is Boolean boolCompare)
{
- retComp.Result = boolCompare.Equals(RegisterConverter.ConvertTo(r));
+ retComp.Result = boolCompare.Equals(RegisterConverter.ConvertTo(r));
retComp.Msg = boolCompare.ToString();
}
diff --git a/Common/ProductionUiCordonel/Data/PressureResultDataNotifyable.cs b/Common/ProductionUiCordonel/Data/PressureResultDataNotifyable.cs
index b0fe1932..10c41039 100644
--- a/Common/ProductionUiCordonel/Data/PressureResultDataNotifyable.cs
+++ b/Common/ProductionUiCordonel/Data/PressureResultDataNotifyable.cs
@@ -39,12 +39,12 @@ namespace ProductionUiCordonel.Data
}
- public string PcbId;
+ public String PcbId;
- private int rev = 0;
+ private Int32 rev = 0;
- public int Rev
+ public Int32 Rev
{
get { return rev; }
set
@@ -53,8 +53,8 @@ namespace ProductionUiCordonel.Data
InternalPropertyChanged(nameof(Rev));
}
}
- private bool? passed = false;
- public bool? Passed
+ private Boolean? passed = false;
+ public Boolean? Passed
{
get { return passed; }
set
@@ -66,7 +66,7 @@ namespace ProductionUiCordonel.Data
- private string testerName = "C. Röhl";
+ private String testerName = "C. Röhl";
public String TesterName
{
get { return testerName; }
@@ -77,7 +77,7 @@ namespace ProductionUiCordonel.Data
}
}
- private string testPressure = "6";
+ private String testPressure = "6";
public String TestPressure
{
get { return testPressure; }
@@ -89,7 +89,7 @@ namespace ProductionUiCordonel.Data
}
- private string leakRate = " 0,00001";
+ private String leakRate = " 0,00001";
public String LeakRate
{
get { return leakRate; }
@@ -100,7 +100,7 @@ namespace ProductionUiCordonel.Data
}
}
- private string remark = "";
+ private String remark = "";
public String Remark
{
get { return remark; }
@@ -134,7 +134,7 @@ namespace ProductionUiCordonel.Data
}
}
- internal void SetAllTestPoints(string input)
+ internal void SetAllTestPoints(String input)
{
foreach (var item in Testpoints)
{
diff --git a/Common/ProductionUiCordonel/Event/StringArgs.cs b/Common/ProductionUiCordonel/Event/StringArgs.cs
index fc7afaba..0b96e4e8 100644
--- a/Common/ProductionUiCordonel/Event/StringArgs.cs
+++ b/Common/ProductionUiCordonel/Event/StringArgs.cs
@@ -8,8 +8,8 @@ namespace ProductionUiCordonel.Event
{
public class StringArgs : EventArgs
{
- public readonly string Content;
- public StringArgs(string content)
+ public readonly String Content;
+ public StringArgs(String content)
{
Content = content;
}
diff --git a/Common/ProductionUiCordonel/FinalTest.xaml.cs b/Common/ProductionUiCordonel/FinalTest.xaml.cs
index 7f459f80..986376c8 100644
--- a/Common/ProductionUiCordonel/FinalTest.xaml.cs
+++ b/Common/ProductionUiCordonel/FinalTest.xaml.cs
@@ -1,11 +1,8 @@
-using Newtonsoft.Json;
-using ProductionUiCordonel.ProductionProcesses;
-using ProductionUiCordonel.ProductionProcesses.Actions;
-using ProductionUiCordonel.ProductionProcesses.Enum;
-using ProductionUiCordonel.UserControls.FinalTest;
-using System;
+using System;
using System.Collections.Generic;
+using System.ComponentModel;
using System.Data;
+using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Net;
@@ -14,7 +11,13 @@ using System.Threading.Tasks;
using System.Timers;
using System.Windows;
using System.Windows.Controls;
+using System.Windows.Input;
using System.Windows.Threading;
+using Newtonsoft.Json;
+using ProductionUiCordonel.ProductionProcesses;
+using ProductionUiCordonel.ProductionProcesses.Actions;
+using ProductionUiCordonel.ProductionProcesses.Enum;
+using ProductionUiCordonel.UserControls.FinalTest;
using Xylem.Common.CommonCore.Configuration;
using Xylem.Common.CommonCore.Consts;
using Xylem.Common.Hardware.WaterMeter.Genesis.GenesisConfig;
@@ -38,7 +41,7 @@ namespace ProductionUiCordonel
private GenesisMeter genesisMeter;
public GenesisMeter CurrentGenesisMeter
{
- get { return genesisMeter; }
+ get => genesisMeter;
set
{
var oldMeter = genesisMeter;
@@ -47,14 +50,11 @@ namespace ProductionUiCordonel
}
}
- private int orderNumber = 0;
- public int OrderNumber
+ private Int32 orderNumber;
+ public Int32 OrderNumber
{
////lblOrderNumber
- get
- {
- return orderNumber;
- }
+ get => orderNumber;
set
{
orderNumber = value;
@@ -66,37 +66,31 @@ namespace ProductionUiCordonel
}
}
- private long radioAdress = 0;
- public long RadioAdress
+ private Int64 radioAddress;
+ public Int64 RadioAdress
{
- get
- {
- return radioAdress;
- }
+ get => radioAddress;
set
{
- radioAdress = value;
+ radioAddress = value;
updateContentControl(lblRadioAdress, "-");
- if (radioAdress != 0)
+ if (radioAddress != 0)
{
- updateContentControl(lblRadioAdress, radioAdress.ToString());
+ updateContentControl(lblRadioAdress, radioAddress.ToString());
}
}
}
- private string serialNumber = "-";
- public string SerialNumber
+ private String serialNumber = "-";
+ public String SerialNumber
{
- get
- {
- return serialNumber;
- }
+ get => serialNumber;
set
{
serialNumber = value;
updateContentControl(lblSerialNumber, "-");
- if (!String.IsNullOrEmpty(serialNumber))
+ if (!string.IsNullOrEmpty(serialNumber))
{
updateContentControl(lblSerialNumber, serialNumber);
}
@@ -104,19 +98,16 @@ namespace ProductionUiCordonel
}
}
- private string lastPcbID;
- private string currentProcess = "-";
- public string CurrentProcess
+ private String lastPcbID;
+ private String currentProcess = "-";
+ public String CurrentProcess
{
- get
- {
- return currentProcess;
- }
+ get => currentProcess;
set
{
currentProcess = value;
updateContentControl(lblCurrentProcess, "-");
- if (!String.IsNullOrEmpty(currentProcess))
+ if (!string.IsNullOrEmpty(currentProcess))
{
updateContentControl(lblCurrentProcess, currentProcess);
}
@@ -139,14 +130,14 @@ namespace ProductionUiCordonel
}
public EventHandler OnPcbIdDetect;
- private int intervalWithoutDetect = 1000;
- private int intervalWithDetect = 10000;
- private string _currentPcbID;
+ private Int32 intervalWithoutDetect = 1000;
+ private Int32 intervalWithDetect = 10000;
+ private String _currentPcbID;
private Timer tmrAutoDetect;
public ApplicationSettings Settings { get; set; }
- private void Window_Initialized(object sender, EventArgs e)
+ private void Window_Initialized(Object sender, EventArgs e)
{
- var configfile = System.IO.Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), nameof(Xylem.Common.Hardware.WaterMeter.Genesis), ProgramConfig.SerialConfigFileName);
+ var configfile = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), nameof(Xylem.Common.Hardware.WaterMeter.Genesis), ProgramConfig.SerialConfigFileName);
if (!File.Exists(configfile))
{
@@ -172,11 +163,11 @@ namespace ProductionUiCordonel
useSetting(true);
}
- private void Window_Closing(object sender, System.ComponentModel.CancelEventArgs e)
+ private void Window_Closing(Object sender, CancelEventArgs e)
{
DisposeAllConnections();
}
- private void useSetting(bool setSlot = false)
+ private void useSetting(Boolean setSlot = false)
{
tmrAutoDetect.Enabled = Settings.AutoDetect;
tblkAutodetectState.Text = "Off";
@@ -207,11 +198,11 @@ namespace ProductionUiCordonel
}
private MeterBatch CurrentBatch;
- private bool detectIsLocked;
+ private Boolean detectIsLocked;
- private string _lastMsg;
- public string LastMsg
+ private String _lastMsg;
+ public String LastMsg
{
set
{
@@ -223,22 +214,22 @@ namespace ProductionUiCordonel
return _lastMsg;
}
}
- private void updateUi(ContentControl c, string content)
+ private void updateUi(ContentControl c, String content)
{
c.Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() => { c.Content = content; }));
}
- private void updateUi(TextBox c, string content)
+ private void updateUi(TextBox c, String content)
{
c.Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() => { c.Text = content; }));
}
- private void updateUi(TextBlock c, string content)
+ private void updateUi(TextBlock c, String content)
{
c.Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() => { c.Text = content; }));
}
- public string CurrentPcbID
+ public String CurrentPcbID
{
set
{
@@ -275,7 +266,7 @@ namespace ProductionUiCordonel
return _currentPcbID;
}
}
- private void GetPcbMapping(string pcbID)
+ private void GetPcbMapping(String pcbID)
{
if (string.IsNullOrEmpty(pcbID))
{
@@ -288,14 +279,14 @@ namespace ProductionUiCordonel
try
{
var responseJson = LocalWebRequest.GetRequest(url);
- var a = JsonConvert.DeserializeObject(responseJson);
+ var a = JsonConvert.DeserializeObject(responseJson);
var tmpInt = 0;
int.TryParse(a[1], out tmpInt);
OrderNumber = tmpInt;
- long tmpLong = 0;
+ Int64 tmpLong = 0;
if (a.Length > 2)
{
long.TryParse(a[2], out tmpLong);
@@ -325,13 +316,13 @@ namespace ProductionUiCordonel
}
});
}
- private bool Detect(bool IgnorErrors, int slot)
+ private Boolean Detect(Boolean IgnorErrors, Int32 slot)
{
if (!detectIsLocked)
{
LastMsg = "Start Detect";
CurrentProcess = "Suche Cordonel";
- bool hasDetect = false;
+ Boolean hasDetect = false;
if (string.IsNullOrEmpty(CurrentPcbID) || CurrentGenesisMeter == null)
{
var mb = new MeterBatch();
@@ -359,7 +350,7 @@ namespace ProductionUiCordonel
else
{
CurrentProcess = "Cordonel nicht gefunden";
- LastMsg = $"No Meter found";
+ LastMsg = "No Meter found";
DisposeAllConnections();
}
@@ -381,7 +372,6 @@ namespace ProductionUiCordonel
if (string.IsNullOrEmpty(ret) || ret != CurrentPcbID)
{
LastMsg = "Meter connection lost";
- hasDetect = false;
DisposeAllConnections();
CurrentPcbID = "";
@@ -396,13 +386,11 @@ namespace ProductionUiCordonel
}
return hasDetect;
}
- else
- {
- LastMsg = "Meter is still connected (locked)";
- return true;
- }
+
+ LastMsg = "Meter is still connected (locked)";
+ return true;
}
- private void TmrAutoDetect_Elapsed(object sender, ElapsedEventArgs e)
+ private void TmrAutoDetect_Elapsed(Object sender, ElapsedEventArgs e)
{
tmrAutoDetect.Enabled = false;
var hasDetect = Detect(true, 1);
@@ -419,7 +407,7 @@ namespace ProductionUiCordonel
private ProductionProcessCheckOrderNumber orderBarcode;
private ProductionProcessCheckSerialNumber serialBarcode;
- public void SetUpBlank(bool retry, bool abort = false)
+ public void SetUpBlank(Boolean retry, Boolean abort = false)
{
pc.Processes = new List();
@@ -456,7 +444,7 @@ namespace ProductionUiCordonel
var radioCheck = new ProductionProcessRadioCheck();
- orderBarcode.isDone += delegate (object sender, EventArgs e)
+ orderBarcode.isDone += delegate (Object sender, EventArgs e)
{
radioCheck.Ordernumber = ((ProductionProcessCheckOrderNumber)sender).Ordernumber;
};
@@ -485,7 +473,7 @@ namespace ProductionUiCordonel
errorP.isDone += allProcessesDone;
pc.ErrorProcess = errorP;
- var successeP = new ProductionProcessDone(false);
+ var successeP = new ProductionProcessDone();
successeP.isDone += allProcessesDone;
pc.DoneProcess = successeP;
@@ -504,7 +492,7 @@ namespace ProductionUiCordonel
}
}
- private void CheckOrder_isDone(object sender, EventArgs e)
+ private void CheckOrder_isDone(Object sender, EventArgs e)
{
OrderNumber = ((ProductionProcessCheckOrderNumber)sender).Ordernumber;
@@ -512,7 +500,7 @@ namespace ProductionUiCordonel
}
- private void Radio_CheckOrder_isDone(object sender, EventArgs e)
+ private void Radio_CheckOrder_isDone(Object sender, EventArgs e)
{
OrderNumber = ((ProductionProcessCheckOrderNumber)sender).Ordernumber;
@@ -520,7 +508,7 @@ namespace ProductionUiCordonel
}
- private void allProcessesDone(object sender, Tuple e)
+ private void allProcessesDone(Object sender, Tuple e)
{
detectIsLocked = false;
if (e.Item3)
@@ -565,7 +553,7 @@ namespace ProductionUiCordonel
}
- private void UiElmEnable(UIElement elm, bool isEnabled)
+ private void UiElmEnable(UIElement elm, Boolean isEnabled)
{
elm.Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() =>
@@ -575,14 +563,14 @@ namespace ProductionUiCordonel
}
));
}
- private void PcOnProcessLogHandler(object sender, PopUpProcessLogArgs e)
+ private void PcOnProcessLogHandler(Object sender, PopUpProcessLogArgs e)
{
txtLog.Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() =>
{
if (e != null)
{
- txtLog.Text = e.Data + System.Environment.NewLine + txtLog.Text;
+ txtLog.Text = e.Data + Environment.NewLine + txtLog.Text;
}
}
));
@@ -616,7 +604,7 @@ namespace ProductionUiCordonel
}
}
- private void updateContentControl(ContentControl ctl, string text)
+ private void updateContentControl(ContentControl ctl, String text)
{
ctl.Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() =>
@@ -670,7 +658,7 @@ namespace ProductionUiCordonel
}
- private void Pc_ProcessStateChangedHandler(object sender, EventArgs e)
+ private void Pc_ProcessStateChangedHandler(Object sender, EventArgs e)
{
if (sender is IProductionProcess)
{
@@ -705,14 +693,14 @@ namespace ProductionUiCordonel
}
- private void BtnSwitchAutoDetect_Click(object sender, RoutedEventArgs e)
+ private void BtnSwitchAutoDetect_Click(Object sender, RoutedEventArgs e)
{
Settings.AutoDetect = !Settings.AutoDetect;
storeSetting();
useSetting();
}
- private void CbxSlotBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
+ private void CbxSlotBox_SelectionChanged(Object sender, SelectionChangedEventArgs e)
{
}
@@ -721,11 +709,11 @@ namespace ProductionUiCordonel
Settings.Update("ProductionUiConfig.json");
}
- private void BtnConntect_Click(object sender, RoutedEventArgs e)
+ private void BtnConntect_Click(Object sender, RoutedEventArgs e)
{
- var hasDetect = Detect(false, (int)cbxSlotBox.SelectedValue);
+ var hasDetect = Detect(false, (Int32)cbxSlotBox.SelectedValue);
- Settings.Slot = (int)cbxSlotBox.SelectedValue;
+ Settings.Slot = (Int32)cbxSlotBox.SelectedValue;
storeSetting();
}
private void runDetect()
@@ -742,7 +730,7 @@ namespace ProductionUiCordonel
pc.Start(CurrentGenesisMeter);
}
}
- private void BtnDetect_Click(object sender, RoutedEventArgs e)
+ private void BtnDetect_Click(Object sender, RoutedEventArgs e)
{
runDetect();
}
@@ -751,23 +739,23 @@ namespace ProductionUiCordonel
var sb = new StringBuilder();
var fileName = $"{DateTime.Now.ToString("yyyyMMddHHmmss")}_ReturnNoteTxt_{lblPcbID.Content}.txt";
sb.AppendLine($"Aufallschein {DateTime.Now}");
- sb.AppendLine($"----------------------------------");
+ sb.AppendLine("----------------------------------");
sb.AppendLine($"PcbId {lblPcbID.Content}");
sb.AppendLine($"Auftrag {lblOrderNumber.Content}");
sb.AppendLine($"Seriennummer {lblSerialNumber.Content}");
sb.AppendLine($"Status {lblMessage.Text}");
- sb.AppendLine($"-------------Meldung---------------");
+ sb.AppendLine("-------------Meldung---------------");
sb.Append($"{txtLog.Text}");
File.WriteAllText(fileName, sb.ToString());
//txtLog.Text
- System.Diagnostics.Process.Start(fileName);
+ Process.Start(fileName);
}
- private void Window_PreviewKeyDown(object sender, System.Windows.Input.KeyEventArgs e)
+ private void Window_PreviewKeyDown(Object sender, KeyEventArgs e)
{
txtInputHidden.Focus();
- if (e.Key == System.Windows.Input.Key.Enter)
+ if (e.Key == Key.Enter)
{
if (serialBarcode?.GetUserControl() is UcBarcodeInput bar)
{
diff --git a/Common/ProductionUiCordonel/MainWindow.xaml.cs b/Common/ProductionUiCordonel/MainWindow.xaml.cs
index d1ab3a52..0825efaa 100644
--- a/Common/ProductionUiCordonel/MainWindow.xaml.cs
+++ b/Common/ProductionUiCordonel/MainWindow.xaml.cs
@@ -62,14 +62,14 @@ namespace ProductionUiCordonel
public EventHandler OnPcbIdDetect;
- private int intervalWithoutDetect = 1000;
- private int intervalWithDetect = 10000;
- private string _currentPcbID;
+ private Int32 intervalWithoutDetect = 1000;
+ private Int32 intervalWithDetect = 10000;
+ private String _currentPcbID;
public PickingViewModel PickingData = new PickingViewModel();
- public string CurrentPcbID
+ public String CurrentPcbID
{
set
{
@@ -127,8 +127,8 @@ namespace ProductionUiCordonel
}
}
- private string _lastMsg;
- public string LastMsg
+ private String _lastMsg;
+ public String LastMsg
{
set
{
@@ -160,7 +160,7 @@ namespace ProductionUiCordonel
}
public ApplicationSettings Settings { get; set; }
- private void Window_Initialized(object sender, EventArgs e)
+ private void Window_Initialized(Object sender, EventArgs e)
{
var configfile = System.IO.Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), nameof(Xylem.Common.Hardware.WaterMeter.Genesis), ProgramConfig.SerialConfigFileName);
@@ -189,7 +189,7 @@ namespace ProductionUiCordonel
useSetting(true);
}
- private void TmrAutoDetect_Elapsed(object sender, ElapsedEventArgs e)
+ private void TmrAutoDetect_Elapsed(Object sender, ElapsedEventArgs e)
{
tmrAutoDetect.Enabled = false;
var hasDetect = Detect(true, 1);
@@ -205,25 +205,25 @@ namespace ProductionUiCordonel
}
- private void BtnConntect_Click(object sender, RoutedEventArgs e)
+ private void BtnConntect_Click(Object sender, RoutedEventArgs e)
{
- var hasDetect = Detect(false, (int)cbxSlotBox.SelectedValue);
+ var hasDetect = Detect(false, (Int32)cbxSlotBox.SelectedValue);
- Settings.Slot = (int)cbxSlotBox.SelectedValue;
+ Settings.Slot = (Int32)cbxSlotBox.SelectedValue;
storeSetting();
}
- private void updateUi(ContentControl c, string content)
+ private void updateUi(ContentControl c, String content)
{
c.Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() => { c.Content = content; }));
}
- private void updateUi(TextBox c, string content)
+ private void updateUi(TextBox c, String content)
{
c.Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() => { c.Text = content; }));
}
- private void updateUi(TextBlock c, string content)
+ private void updateUi(TextBlock c, String content)
{
c.Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() => { c.Text = content; }));
@@ -231,7 +231,7 @@ namespace ProductionUiCordonel
private MeterBatch CurrentBatch;
private GenesisMeter _currentMeter;
- private bool detectIsLocked;
+ private Boolean detectIsLocked;
private GenesisMeter CurrentMeter
{
@@ -254,12 +254,12 @@ namespace ProductionUiCordonel
}
}
- private bool Detect(bool IgnorErrors, int slot)
+ private Boolean Detect(Boolean IgnorErrors, Int32 slot)
{
if (!detectIsLocked)
{
LastMsg = "Start Detect";
- bool hasDetect = false;
+ Boolean hasDetect = false;
if (string.IsNullOrEmpty(CurrentPcbID) || CurrentMeter == null)
{
var mb = new MeterBatch();
@@ -327,7 +327,7 @@ namespace ProductionUiCordonel
- private void Window_Closing(object sender, System.ComponentModel.CancelEventArgs e)
+ private void Window_Closing(Object sender, System.ComponentModel.CancelEventArgs e)
{
DisposeAllConnections();
}
@@ -351,7 +351,7 @@ namespace ProductionUiCordonel
- private void GetPcbMapping(string pcbID)
+ private void GetPcbMapping(String pcbID)
{
if (string.IsNullOrEmpty(pcbID))
{
@@ -364,7 +364,7 @@ namespace ProductionUiCordonel
try
{
var responseJson = LocalWebRequest.GetRequest(url);
- var a = JsonConvert.DeserializeObject(responseJson);
+ var a = JsonConvert.DeserializeObject(responseJson);
if (ucFinalRadioTest != null)
@@ -405,38 +405,38 @@ namespace ProductionUiCordonel
- private void Button_Click(object sender, RoutedEventArgs e)
+ private void Button_Click(Object sender, RoutedEventArgs e)
{
}
- private void UcFinalRadioTest_Loaded(object sender, RoutedEventArgs e)
+ private void UcFinalRadioTest_Loaded(Object sender, RoutedEventArgs e)
{
ucFinalRadioTest.OnLockMeter += UcFinalRadioTest_OnLockMeter;
ucFinalRadioTest.OnReleaseMeter += UcFinalRadioTest_OnReleaseMeter;
}
- private void UcFinalRadioTest_OnLockMeter(object sender, EventArgs e)
+ private void UcFinalRadioTest_OnLockMeter(Object sender, EventArgs e)
{
detectIsLocked = true;
}
- private void UcFinalRadioTest_OnReleaseMeter(object sender, EventArgs e)
+ private void UcFinalRadioTest_OnReleaseMeter(Object sender, EventArgs e)
{
detectIsLocked = false;
ucFinalRadioTest.SetUpBlank(false);
}
- private void BtnSwitchAutoDetect_Click(object sender, RoutedEventArgs e)
+ private void BtnSwitchAutoDetect_Click(Object sender, RoutedEventArgs e)
{
Settings.AutoDetect = !Settings.AutoDetect;
storeSetting();
useSetting();
}
- private void CbxSlotBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
+ private void CbxSlotBox_SelectionChanged(Object sender, SelectionChangedEventArgs e)
{
}
@@ -447,7 +447,7 @@ namespace ProductionUiCordonel
- private void useSetting(bool setSlot = false)
+ private void useSetting(Boolean setSlot = false)
{
tmrAutoDetect.Enabled = Settings.AutoDetect;
tblkAutodetectState.Text = "Off";
@@ -474,7 +474,7 @@ namespace ProductionUiCordonel
}
- private void StackPanel_SizeChanged(object sender, SizeChangedEventArgs e)
+ private void StackPanel_SizeChanged(Object sender, SizeChangedEventArgs e)
{
ucFinalRadioTest.Height = e.NewSize.Height;
diff --git a/Common/ProductionUiCordonel/Model/FinalTestModel.cs b/Common/ProductionUiCordonel/Model/FinalTestModel.cs
new file mode 100644
index 00000000..c6a9c6a3
--- /dev/null
+++ b/Common/ProductionUiCordonel/Model/FinalTestModel.cs
@@ -0,0 +1,193 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Runtime.CompilerServices;
+using System.Text;
+using System.Threading;
+using System.Threading.Tasks;
+using ProductionUiCordonel.Data;
+using Xylem.Common.Hardware.WaterMeter.Genesis.GenesisFile.Consts;
+using Xylem.Common.Utils.ProcessExec.EventArguments;
+
+namespace ProductionUiCordonel.Model
+{
+ ///
+ /// Final test model preparing the Cordonel for shipping:
+ /// - Setup device with standard parameters covered by the VAKO or customer specific CSD,
+ /// - If radio is installed: radio test,
+ /// - Requiring radio key from LuDB,
+ /// - Requiring 7 passwords for the Cordonel access levels,
+ /// - Building the password file (Level 3 is the modified skeleton key),
+ /// - Store all configurations,
+ /// - Reboot the Cordonel to load all settings from FLASH to RAM,
+ /// - Configuration check of all parameters defined by VAKO and CSD.
+ ///
+ class FinalTestModel
+ {
+
+ #region Variables
+
+ ///
+ /// Port scan result event for message dispatcher to caller
+ ///
+ public event EventHandler OnProcessUpdate;
+
+ // Text for caller to inform about actual process being carried out
+ private String _actualOperation;
+
+ // states of the state machine, the backup state locks against repeated execution
+ private FinalTestState _finalTestState;
+ private FinalTestState _finalTestBackupState;
+
+ // Process counter for caller to monitor actual progress
+ private Int32 _overallProcessedStepsCtr;
+ private Int32 _singleProcessedStepsCtr;
+
+ // maximum processing steps for calculation of progress bar
+ private const Int32 MaxOverallProcessSteps = 20;
+ private Int32 _maxSingleProcessSteps;
+
+ // processing retries
+ private const Int32 MaxProcessRetries = 2;
+ private Int32 _processRetryCtr;
+
+ #endregion
+
+ #region Events
+ ///
+ /// Process event
+ ///
+ ///
+ ///
+ ///
+ /// - Initial
+ ///
+ public virtual void ProcessUpdate_Event(Object sender, ProcessExecEventArgs e)
+ {
+ // copy text from overall messages to actual, because this is from sub-routine
+ OnProcessUpdate?.Invoke(this, new ProcessExecEventArgs(GetActualStateText(),
+ OverallProcessPercent, _actualOperation, e.OverallProcessPercent));
+ }
+
+ #endregion
+
+ #region ProcessInformation
+
+ ///
+ /// Process counter in percent
+ ///
+ ///
+ /// - Initial
+ ///
+ public Double OverallProcessPercent => 100.0d *
+ (_overallProcessedStepsCtr + _singleProcessedStepsCtr) / MaxOverallProcessSteps;
+
+ ///
+ /// Single file process counter in percent
+ ///
+ ///
+ /// - Initial
+ ///
+ public Double SingleFileProcessPercent => 100.0d * _singleProcessedStepsCtr / _maxSingleProcessSteps;
+
+ ///
+ /// Returns the final test state text information for display
+ ///
+ ///
+ ///
+ /// - Initial
+ ///
+ public String GetActualStateText()
+ {
+ // search text assigned to current state
+ var text = FinalTestStateInfo.GetTextFromState(_finalTestState);
+ if (_finalTestState == FinalTestState.Idle)
+ {
+ return text;
+ }
+
+ text += _processRetryCtr > 0 ? $"{_processRetryCtr}" : "";
+ if (_overallProcessedStepsCtr > 0)
+ {
+ text += $"{_overallProcessedStepsCtr}/{MaxOverallProcessSteps}";
+ }
+
+ return text;
+ }
+
+ #endregion
+ #region CtorAssignment
+
+ ///
+ /// Ctor
+ ///
+ ///
+ /// - Initial
+ ///
+ public FinalTestModel()
+ {
+ }
+
+
+ ///
+ /// Dispose
+ ///
+ public void Dispose()
+ {
+ }
+ #endregion
+
+ #region StateMachine
+ ///
+ /// State machine of FinalTestModel.
+ ///
+ ///
+ /// - Initial
+ ///
+ public void StateMachine()
+ {
+
+ // avoid repeated execution of the state machine of identical state
+ if (_finalTestState == _finalTestBackupState)
+ {
+ Thread.Sleep(1);
+ }
+ else
+ {
+ // remind backup state to avoid repeated execution and side effects
+ _finalTestBackupState = _finalTestState;
+ switch (_finalTestState)
+ {
+ case FinalTestState.Idle:
+ break;
+
+ case FinalTestState.StartInitial:
+ _overallProcessedStepsCtr = 0;
+ _singleProcessedStepsCtr = 0;
+ _finalTestState = FinalTestState.Idle;
+ break;
+
+ case FinalTestState.StepFailed:
+ _finalTestState = _processRetryCtr++ < MaxProcessRetries
+ ? FinalTestState.RepeatFinalTest
+ : FinalTestState.FinalTestFailed;
+ break;
+
+ case FinalTestState.RepeatFinalTest:
+ _overallProcessedStepsCtr = 0;
+ _singleProcessedStepsCtr = 0;
+ _finalTestState = FinalTestState.Idle;
+ break;
+
+ default:
+ _finalTestState = FinalTestState.Idle;
+ break;
+
+ }
+ }// lock repeated execution of identical state
+
+ #endregion
+
+ }
+ }
+}
diff --git a/Common/ProductionUiCordonel/Model/IMultiModeChildViewModel.cs b/Common/ProductionUiCordonel/Model/IMultiModeChildViewModel.cs
index 4b736cd1..2ab80257 100644
--- a/Common/ProductionUiCordonel/Model/IMultiModeChildViewModel.cs
+++ b/Common/ProductionUiCordonel/Model/IMultiModeChildViewModel.cs
@@ -10,8 +10,8 @@ namespace ProductionUiCordonel.Model
{
public interface IMultiModeChildViewModel : INotifyPropertyChanged, IDisposable
{
- string GetChildIdent();
+ String GetChildIdent();
- void InputText(string text);
+ void InputText(String text);
}
}
diff --git a/Common/ProductionUiCordonel/Model/MarriageMultiModeViewModel.cs b/Common/ProductionUiCordonel/Model/MarriageMultiModeViewModel.cs
index c261e621..b71ada3b 100644
--- a/Common/ProductionUiCordonel/Model/MarriageMultiModeViewModel.cs
+++ b/Common/ProductionUiCordonel/Model/MarriageMultiModeViewModel.cs
@@ -12,8 +12,8 @@ namespace ProductionUiCordonel.Model
{
public class MarriageMultiModeViewModel : BaseMultiModeChildViewModel
{
- private bool canMarry = false;
- public bool CanMarry
+ private Boolean canMarry = false;
+ public Boolean CanMarry
{
get { return canMarry; }
set
@@ -24,8 +24,8 @@ namespace ProductionUiCordonel.Model
}
- private int serialNr;
- public int SerialNr
+ private Int32 serialNr;
+ public Int32 SerialNr
{
get { return serialNr; }
set
@@ -36,18 +36,18 @@ namespace ProductionUiCordonel.Model
}
- private bool locked = false;
- public MarriageMultiModeViewModel(string ctrName, int slotNR, List barcodeTrigger, int? stationID = null) : base(ctrName, slotNR, barcodeTrigger, stationID)
+ private Boolean locked = false;
+ public MarriageMultiModeViewModel(String ctrName, Int32 slotNR, List barcodeTrigger, Int32? stationID = null) : base(ctrName, slotNR, barcodeTrigger, stationID)
{
base.VisibilityMarriage = System.Windows.Visibility.Visible;
base.MeterDetectedHandler += PickingMultiModeViewModel_MeterDetectedHandler;
}
- internal async Task Store()
+ internal async Task Store()
{
var url = $"{ServiceUrls.MarriageServiceUrl()}SetPcbToSerial?PcbId={CurrentPcbID}&SerialNumber={SerialNr}&returnMetroData=0";
- return await Task.Run(() =>
+ return await Task.Run(() =>
{
try
{
@@ -102,7 +102,7 @@ namespace ProductionUiCordonel.Model
});
}
- private void PickingMultiModeViewModel_MeterDetectedHandler(object sender, EventArgs e)
+ private void PickingMultiModeViewModel_MeterDetectedHandler(Object sender, EventArgs e)
{
CheckBtnEnable();
}
@@ -122,7 +122,7 @@ namespace ProductionUiCordonel.Model
- public override void InputText(string text)
+ public override void InputText(String text)
{
try
{
@@ -152,7 +152,7 @@ namespace ProductionUiCordonel.Model
}
- public override bool SlotIsLocked()
+ public override Boolean SlotIsLocked()
{
return locked;
}
diff --git a/Common/ProductionUiCordonel/Model/MultiModeChildViewModel.cs b/Common/ProductionUiCordonel/Model/MultiModeChildViewModel.cs
index 0229981c..947867d6 100644
--- a/Common/ProductionUiCordonel/Model/MultiModeChildViewModel.cs
+++ b/Common/ProductionUiCordonel/Model/MultiModeChildViewModel.cs
@@ -20,11 +20,11 @@ namespace ProductionUiCordonel
private Timer tmrAutoDetect;
public EventHandler OnPcbIdDetect;
- public List BarcodeTrigger = new List();
+ public List BarcodeTrigger = new List();
- private int intervalWithoutDetect = 1000;
- private int intervalWithDetect = 10000;
- private string _currentPcbID;
+ private Int32 intervalWithoutDetect = 1000;
+ private Int32 intervalWithDetect = 10000;
+ private String _currentPcbID;
private MeterBatch Batch = new MeterBatch();
private Visibility visibilityMarriage = Visibility.Collapsed;
public Visibility VisibilityMarriage
@@ -72,8 +72,8 @@ namespace ProductionUiCordonel
}
- public string currentSlotStateText = "none";
- public string CurrentSlotStateText
+ public String currentSlotStateText = "none";
+ public String CurrentSlotStateText
{
get
{
@@ -134,7 +134,7 @@ namespace ProductionUiCordonel
}
- private string slotInfo = "-";
+ private String slotInfo = "-";
public String SlotInfo
{
get { return slotInfo; }
@@ -157,7 +157,7 @@ namespace ProductionUiCordonel
Error,
Fatal
}
- private string childName = "asd";
+ private String childName = "asd";
public String ChildName
{
get { return childName; }
@@ -168,7 +168,7 @@ namespace ProductionUiCordonel
}
}
- private string order;
+ private String order;
public String Order
{
get { return order; }
@@ -180,7 +180,7 @@ namespace ProductionUiCordonel
}
- public string CurrentPcbID
+ public String CurrentPcbID
{
get
{
@@ -204,14 +204,14 @@ namespace ProductionUiCordonel
PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
}
- public string GetChildIdent()
+ public String GetChildIdent()
{
return ChildName;
}
- public int SlotNr;
- public BaseMultiModeChildViewModel(string ctrName, int slotNR,List barcodeTrigger, int? StationId = null, bool useTimer = true)
+ public Int32 SlotNr;
+ public BaseMultiModeChildViewModel(String ctrName, Int32 slotNR,List barcodeTrigger, Int32? StationId = null, Boolean useTimer = true)
{
_logger = NLogHelper.CreateOrGetLogger("ProductionUI");
ChildName = ctrName;
@@ -227,7 +227,7 @@ namespace ProductionUiCordonel
BarcodeTrigger = barcodeTrigger;
}
- public void TmrAutoDetect_Elapsed(object sender, EventArgs e)
+ public void TmrAutoDetect_Elapsed(Object sender, EventArgs e)
{
CurrentSlotState = SlotState.IsDetecting;
tmrAutoDetect.Enabled = false;
@@ -255,24 +255,24 @@ namespace ProductionUiCordonel
}
}
- public virtual void InputText(string text)
+ public virtual void InputText(String text)
{
Order = text;
}
- public void Log(string txt)
+ public void Log(String txt)
{
_logger?.Info(txt);
}
- public abstract bool SlotIsLocked();
+ public abstract Boolean SlotIsLocked();
public event EventHandler MeterDetectedHandler;
- private bool Detect(int slot)
+ private Boolean Detect(Int32 slot)
{
if (!SlotIsLocked())
{
Log("Start Detect");
- bool hasDetect = false;
+ Boolean hasDetect = false;
if (string.IsNullOrEmpty(CurrentPcbID) || CurrentMeter == null)
{
Batch = new MeterBatch();
diff --git a/Common/ProductionUiCordonel/Model/MultiModeMasterViewModel.cs b/Common/ProductionUiCordonel/Model/MultiModeMasterViewModel.cs
index c5a336f8..8fc53dda 100644
--- a/Common/ProductionUiCordonel/Model/MultiModeMasterViewModel.cs
+++ b/Common/ProductionUiCordonel/Model/MultiModeMasterViewModel.cs
@@ -19,10 +19,10 @@ namespace ProductionUiCordonel.Model
{
internal class MultiModeMasterViewModel : INotifyPropertyChanged
{
- private string pickingState = "Warte auf Scanner";
- private string pickingScanner = "keine Verbindung";
- private string pickingSlot = "-";
- private string pickingResult = "-";
+ private String pickingState = "Warte auf Scanner";
+ private String pickingScanner = "keine Verbindung";
+ private String pickingSlot = "-";
+ private String pickingResult = "-";
private System.Windows.Media.Brush pickingResultColor;
public System.Windows.Media.Brush PickingResultColor
@@ -37,7 +37,7 @@ namespace ProductionUiCordonel.Model
NotifyPropertyChanged(nameof(PickingResultColor));
}
}
- public string PickingState
+ public String PickingState
{
get
{
@@ -49,7 +49,7 @@ namespace ProductionUiCordonel.Model
NotifyPropertyChanged(nameof(PickingState));
}
}
- public string PickingScanner
+ public String PickingScanner
{
get
{
@@ -61,7 +61,7 @@ namespace ProductionUiCordonel.Model
NotifyPropertyChanged(nameof(PickingScanner));
}
}
- public string PickingSlot
+ public String PickingSlot
{
get
{
@@ -73,7 +73,7 @@ namespace ProductionUiCordonel.Model
NotifyPropertyChanged(nameof(PickingSlot));
}
}
- public string PickingResult
+ public String PickingResult
{
get
{
@@ -117,12 +117,12 @@ namespace ProductionUiCordonel.Model
private class BarScanner : IDisposable
{
- private bool isRuning = false;
+ private Boolean isRuning = false;
public String Input = "";
private String Port;
private CancellationToken Cancellation;
private Task WaitForScannerTask;
- public BarScanner(string port, CancellationToken cancellation)
+ public BarScanner(String port, CancellationToken cancellation)
{
Port = port;
Cancellation = cancellation;
@@ -175,7 +175,7 @@ namespace ProductionUiCordonel.Model
}
- public bool Compare(Dictionary checkAppsIdVersion, uint Frequency, uint MeterSize, bool PressurePresent)
+ public Boolean Compare(Dictionary checkAppsIdVersion, UInt32 Frequency, UInt32 MeterSize, Boolean PressurePresent)
{
using (var Batch = new MeterBatch())
{
@@ -186,7 +186,7 @@ namespace ProductionUiCordonel.Model
meter.SetupFromConfigFile(PickingSlotNr);
Batch.AddMeter(meter);
PickingState = "Am Zähler anmelden";
- if ((bool)meter.Login())
+ if ((Boolean)meter.Login())
{
meter.SetProcessState(Xylem.Common.Hardware.WaterMeter.WaterMeterCore.Consts.DisplayCodes.PickingStarted);
var ret = RunCheck(checkAppsIdVersion, Frequency, MeterSize, PressurePresent, meter);
@@ -214,7 +214,7 @@ namespace ProductionUiCordonel.Model
return false;
}
- private bool RunCheck(Dictionary checkAppsIdVersion, uint Frequency, uint MeterSize, bool PressurePresent, GenesisMeter meter)
+ private Boolean RunCheck(Dictionary checkAppsIdVersion, UInt32 Frequency, UInt32 MeterSize, Boolean PressurePresent, GenesisMeter meter)
{
PickingState = $"Üperprüfe Parameter";
var FrequencyReadOut = RegisterConverter.ConvertTo(meter.ReadRegister("SENSUSRADIO_FrequencyIndicator"));
@@ -232,7 +232,7 @@ namespace ProductionUiCordonel.Model
}
- var PressureReadOut = RegisterConverter.ConvertTo(meter.ReadRegister("METROLOGYASST_PressurePresent"));
+ var PressureReadOut = RegisterConverter.ConvertTo(meter.ReadRegister("METROLOGYASST_PressurePresent"));
if (PressureReadOut != PressurePresent)
{
if (PressurePresent)
@@ -293,12 +293,12 @@ namespace ProductionUiCordonel.Model
private PickingCompareItem PickingOrderDetails;
private BarScanner PickingBarScanner;
- private string PickingOrder;
- private string PickingPcbId;
+ private String PickingOrder;
+ private String PickingPcbId;
- private string PickingScannerPort = "COM6";
- private int PickingSlotNr = 1;
+ private String PickingScannerPort = "COM6";
+ private Int32 PickingSlotNr = 1;
//PickingState,PickingScanner,PickingSlot,PickingResult
private void PickingLoop(CancellationToken token)
{
@@ -328,7 +328,7 @@ namespace ProductionUiCordonel.Model
case PickingStateMachine.WaitForScanning:
PickingScanner = $"Offen {PickingScannerPort}";
PickingState = $"Warte auf Scannereingabe({PickingScannerPort})";
- if (PickingBarScanner != null && !String.IsNullOrEmpty(PickingBarScanner.Input))
+ if (PickingBarScanner != null && !string.IsNullOrEmpty(PickingBarScanner.Input))
{
PickingOrder = PickingBarScanner.Input;
PickingScanner = $"Geschlossen {PickingScannerPort}";
@@ -459,7 +459,7 @@ namespace ProductionUiCordonel.Model
break;
case PickingStateMachine.WaitForBuildingMeterReady:
- if (PickingBarScanner != null && !String.IsNullOrEmpty(PickingBarScanner.Input))
+ if (PickingBarScanner != null && !string.IsNullOrEmpty(PickingBarScanner.Input))
{
if (PickingBarScanner.Input == "%Cordonel_SAP_100%")
@@ -493,7 +493,7 @@ namespace ProductionUiCordonel.Model
break;
case PickingStateMachine.WaitForBuildingPressureReady:
- if (PickingBarScanner != null && !String.IsNullOrEmpty(PickingBarScanner.Input))
+ if (PickingBarScanner != null && !string.IsNullOrEmpty(PickingBarScanner.Input))
{
if (PickingBarScanner.Input == "%Cordonel_SAP_101%")
@@ -522,7 +522,7 @@ namespace ProductionUiCordonel.Model
}
- private void Log(string v)
+ private void Log(String v)
{
//throw new NotImplementedException();
}
diff --git a/Common/ProductionUiCordonel/Model/PickingMultiModeViewModel.cs b/Common/ProductionUiCordonel/Model/PickingMultiModeViewModel.cs
index 4a3257ae..ed517287 100644
--- a/Common/ProductionUiCordonel/Model/PickingMultiModeViewModel.cs
+++ b/Common/ProductionUiCordonel/Model/PickingMultiModeViewModel.cs
@@ -21,8 +21,8 @@ namespace ProductionUiCordonel.Model
public class PickingMultiModeViewModel : BaseMultiModeChildViewModel
{
- private bool inputIsEnabled = false;
- public bool InputIsEnabled
+ private Boolean inputIsEnabled = false;
+ public Boolean InputIsEnabled
{
get { return inputIsEnabled; }
set
@@ -34,31 +34,31 @@ namespace ProductionUiCordonel.Model
- private bool locked = false;
- public PickingMultiModeViewModel(string ctrName, int slotNR, List barcodeTrigger, int? stationID = null) : base(ctrName, slotNR, barcodeTrigger, stationID,false)
+ private Boolean locked = false;
+ public PickingMultiModeViewModel(String ctrName, Int32 slotNR, List barcodeTrigger, Int32? stationID = null) : base(ctrName, slotNR, barcodeTrigger, stationID,false)
{
VisibilityPicking = Visibility.Visible;
base.MeterDetectedHandler += PickingMultiModeViewModel_MeterDetectedHandler;
}
- private void PickingMultiModeViewModel_MeterDetectedHandler(object sender, EventArgs e)
+ private void PickingMultiModeViewModel_MeterDetectedHandler(Object sender, EventArgs e)
{
}
- public override bool SlotIsLocked()
+ public override Boolean SlotIsLocked()
{
return locked;
}
- public override void InputText(string text)
+ public override void InputText(String text)
{
Order = text;
ReloadData(false);
TextForceUpdate();
}
- internal void ReloadData(bool reset)
+ internal void ReloadData(Boolean reset)
{
Task.Run(() =>
@@ -113,7 +113,7 @@ namespace ProductionUiCordonel.Model
//Init(CurrentMeter, new Dictionary(), OrderDteails.FrequencyIndicator, OrderDteails.MeterSize, OrderDteails.PressurePresent);
- var a = new Dictionary();
+ var a = new Dictionary();
a.Add(0, 486);
a.Add(15, 287);
if (OrderDteails.FrequencyIndicator == 868)
@@ -167,7 +167,7 @@ namespace ProductionUiCordonel.Model
});
}
- private void UpdatePickingUi(string state, System.Windows.Media.Brush StateColor, string order, int toDo, int done)
+ private void UpdatePickingUi(String state, System.Windows.Media.Brush StateColor, String order, Int32 toDo, Int32 done)
{
Message = state;
Order = order;
@@ -228,7 +228,7 @@ namespace ProductionUiCordonel.Model
}
}
- public string Message { get; set; }
+ public String Message { get; set; }
private enum OverallStatus
{
NoDetect,
@@ -237,7 +237,7 @@ namespace ProductionUiCordonel.Model
CheckingIsNoMatch,
CheckingIsHasError,
}
- public string StatusText
+ public String StatusText
{
get
{
@@ -278,10 +278,10 @@ namespace ProductionUiCordonel.Model
}
}
- public int ToDo { get; private set; }
- public int Done { get; private set; }
+ public Int32 ToDo { get; private set; }
+ public Int32 Done { get; private set; }
- public void Init(GenesisMeter meter, Dictionary checkAppsIdVersion, uint Frequency, uint MeterSize, bool PressurePresent)
+ public void Init(GenesisMeter meter, Dictionary checkAppsIdVersion, UInt32 Frequency, UInt32 MeterSize, Boolean PressurePresent)
{
@@ -361,7 +361,7 @@ namespace ProductionUiCordonel.Model
OnDataChanged?.Invoke(Data, EventArgs.Empty);
}
- public bool Run(string pcbID, String OrderNr)
+ public Boolean Run(String pcbID, String OrderNr)
{
var tmpData = Data.ToList();
foreach (var item in tmpData.Where(a => !a.Result.HasValue).OrderBy(a => a.Index))
diff --git a/Common/ProductionUiCordonel/Model/PickingViewModel.cs b/Common/ProductionUiCordonel/Model/PickingViewModel.cs
index 2f03e41a..8c2425f7 100644
--- a/Common/ProductionUiCordonel/Model/PickingViewModel.cs
+++ b/Common/ProductionUiCordonel/Model/PickingViewModel.cs
@@ -47,7 +47,7 @@ namespace ProductionUiCordonel.Model
CheckingIsNoMatch,
CheckingIsHasError,
}
- public string StatusText
+ public String StatusText
{
get
{
@@ -89,7 +89,7 @@ namespace ProductionUiCordonel.Model
}
- public void Init(GenesisMeter meter, Dictionary checkAppsIdVersion, uint Frequency, uint MeterSize, bool PressurePresent)
+ public void Init(GenesisMeter meter, Dictionary checkAppsIdVersion, UInt32 Frequency, UInt32 MeterSize, Boolean PressurePresent)
{
@@ -168,7 +168,7 @@ namespace ProductionUiCordonel.Model
OnDataChanged?.Invoke(Data, EventArgs.Empty);
}
- public bool Run(string pcbID, String OrderNr)
+ public Boolean Run(String pcbID, String OrderNr)
{
var tmpData = Data.ToList();
foreach (var item in tmpData.Where(a => !a.Result.HasValue).OrderBy(a => a.Index))
diff --git a/Common/ProductionUiCordonel/Model/PressureMultiModeViewModel.cs b/Common/ProductionUiCordonel/Model/PressureMultiModeViewModel.cs
index feff6163..f18b2d9a 100644
--- a/Common/ProductionUiCordonel/Model/PressureMultiModeViewModel.cs
+++ b/Common/ProductionUiCordonel/Model/PressureMultiModeViewModel.cs
@@ -30,8 +30,8 @@ namespace ProductionUiCordonel.Model
}
- private bool inputIsEnabled = false;
- public bool InputIsEnabled
+ private Boolean inputIsEnabled = false;
+ public Boolean InputIsEnabled
{
get { return inputIsEnabled; }
set
@@ -42,16 +42,16 @@ namespace ProductionUiCordonel.Model
}
- public bool Locked { get; set; } = false;
- public int? StationID { get; set; } = null;
+ public Boolean Locked { get; set; } = false;
+ public Int32? StationID { get; set; } = null;
- public PressureMultiModeViewModel(string ctrName, int slotNR, List barcodeTrigger, int? stationID = null) : base(ctrName, slotNR, barcodeTrigger, stationID)
+ public PressureMultiModeViewModel(String ctrName, Int32 slotNR, List barcodeTrigger, Int32? stationID = null) : base(ctrName, slotNR, barcodeTrigger, stationID)
{
base.VisibilityPressure = System.Windows.Visibility.Visible;
StationID = stationID;
}
- public bool isHydraulicStaion()
+ public Boolean isHydraulicStaion()
{
if (!StationID.HasValue || StationID.Value == 1)
@@ -60,12 +60,12 @@ namespace ProductionUiCordonel.Model
}
return true;
}
- public override bool SlotIsLocked()
+ public override Boolean SlotIsLocked()
{
return false;
}
- internal void ReloadData(bool reset)
+ internal void ReloadData(Boolean reset)
{
if (Result != null && Result.PcbId != CurrentPcbID)
@@ -112,7 +112,7 @@ namespace ProductionUiCordonel.Model
}
}
- internal void StoreData(bool successfull)
+ internal void StoreData(Boolean successfull)
{
if (Result != null && Result.PcbId == CurrentPcbID)
diff --git a/Common/ProductionUiCordonel/MultiMode.xaml.cs b/Common/ProductionUiCordonel/MultiMode.xaml.cs
index 692c3aaa..3424a063 100644
--- a/Common/ProductionUiCordonel/MultiMode.xaml.cs
+++ b/Common/ProductionUiCordonel/MultiMode.xaml.cs
@@ -51,7 +51,7 @@ namespace ProductionUiCordonel
InitializeComponent();
this.Topmost = false;
}
- private void keyUp(object sender, KeyEventArgs e)
+ private void keyUp(Object sender, KeyEventArgs e)
{
}
@@ -76,7 +76,7 @@ namespace ProductionUiCordonel
}
CancellationTokenSource cts;
- private void Window_Loaded(object sender, RoutedEventArgs e)
+ private void Window_Loaded(Object sender, RoutedEventArgs e)
{
cts = new CancellationTokenSource();
AppSettings = new ApplicationSettings("MultiProductionUiConfig.json");
@@ -164,12 +164,12 @@ namespace ProductionUiCordonel
//SetBaseFocus();
}
- private void delegeChild_PosChange(object sender, EventArgs e)
+ private void delegeChild_PosChange(Object sender, EventArgs e)
{
throw new NotImplementedException();
}
- private void TxtBarcodeInput_TextChanged(object sender, System.Windows.Controls.TextChangedEventArgs e)
+ private void TxtBarcodeInput_TextChanged(Object sender, System.Windows.Controls.TextChangedEventArgs e)
{
//if (sender is TextBox text)
//{
@@ -192,7 +192,7 @@ namespace ProductionUiCordonel
}
- private void Window_Closed(object sender, System.EventArgs e)
+ private void Window_Closed(Object sender, System.EventArgs e)
{
cts.Cancel();
diff --git a/Common/ProductionUiCordonel/MultiModeChild.xaml.cs b/Common/ProductionUiCordonel/MultiModeChild.xaml.cs
index 89a9f069..a867e692 100644
--- a/Common/ProductionUiCordonel/MultiModeChild.xaml.cs
+++ b/Common/ProductionUiCordonel/MultiModeChild.xaml.cs
@@ -16,7 +16,7 @@ namespace ProductionUiCordonel
{
public IMultiModeChildViewModel ViewModel;
- public bool UseDefaultPos { get; internal set; } = true;
+ public Boolean UseDefaultPos { get; internal set; } = true;
public event EventHandler PosChanged;
@@ -55,7 +55,7 @@ namespace ProductionUiCordonel
}
}
- internal void StartTextInputListener(string port, CancellationToken cancellation)
+ internal void StartTextInputListener(String port, CancellationToken cancellation)
{
if (port == null)
{
@@ -95,22 +95,22 @@ namespace ProductionUiCordonel
}
- internal void InputText(string text)
+ internal void InputText(String text)
{
ViewModel.InputText(text);
}
- private void BtnPresueFailed_Click(object sender, RoutedEventArgs e)
+ private void BtnPresueFailed_Click(Object sender, RoutedEventArgs e)
{
}
- private void TxtPresurePcbId_TextChanged(object sender, TextChangedEventArgs e)
+ private void TxtPresurePcbId_TextChanged(Object sender, TextChangedEventArgs e)
{
}
- private void PressureControl_OnBarcodeInput(object sender, Event.StringArgs e)
+ private void PressureControl_OnBarcodeInput(Object sender, Event.StringArgs e)
{
InputText(e.Content);
}
@@ -121,7 +121,7 @@ namespace ProductionUiCordonel
}
- private void Button_Click(object sender, RoutedEventArgs e)
+ private void Button_Click(Object sender, RoutedEventArgs e)
{
if (sender is Button btn)
{
@@ -129,7 +129,7 @@ namespace ProductionUiCordonel
}
}
- private void Button_Click_1(object sender, RoutedEventArgs e)
+ private void Button_Click_1(Object sender, RoutedEventArgs e)
{
PosChanged?.Invoke(this, EventArgs.Empty);
}
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionCheckShippingState.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionCheckShippingState.cs
index 6d04c025..636038fd 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionCheckShippingState.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionCheckShippingState.cs
@@ -52,12 +52,12 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
var url = $"{ServiceUrls.MeterInfoForTestBench()}{Meter.PcbId}";
var csdRet = LocalWebRequest.GetRequest(url);
- var res = Newtonsoft.Json.JsonConvert.DeserializeObject(csdRet);
+ var res = Newtonsoft.Json.JsonConvert.DeserializeObject(csdRet);
var CalibrationRun = res[4];
var LastTestBechState = 0;
- bool? HyState = null;
- bool? preState = null;
+ Boolean? HyState = null;
+ Boolean? preState = null;
if (!string.IsNullOrEmpty(res[5]))
{
var tmp = 0;
@@ -129,8 +129,8 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
//// Time Span in h in mAhr In % with one battery is 100%
////(((total used change difference / (Time span / 3600) ) / 3600000) / 19000)*100
- var loadAtH = ((((double)nowChargeV / ((double)nowSecondsV / 3600)) / 3600000) / (19000 * 2)) * 100;
- var totalUsed = (((double)nowChargeV / 1000000 / 3.6) / ((19000 * 2))) * 100;
+ var loadAtH = ((((Double)nowChargeV / ((Double)nowSecondsV / 3600)) / 3600000) / (19000 * 2)) * 100;
+ var totalUsed = (((Double)nowChargeV / 1000000 / 3.6) / ((19000 * 2))) * 100;
//lastFrame
Meter.WriteLog($"totalUsed at EOL {totalUsed}");
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckAttachment.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckAttachment.cs
index 2ad158f7..80f373bd 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckAttachment.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckAttachment.cs
@@ -25,9 +25,9 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
Error,
Acknowledge
}
- public bool DialogIsDone { get; private set; }
- public int OrderNumber { get; set; }
- public ProductionProcessCheckAttachment(int orderNumber)
+ public Boolean DialogIsDone { get; private set; }
+ public Int32 OrderNumber { get; set; }
+ public ProductionProcessCheckAttachment(Int32 orderNumber)
{
OrderNumber = orderNumber;
DialogIsDone = false;
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckOrderNumber.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckOrderNumber.cs
index 6ed01bb2..9e0f24ae 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckOrderNumber.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckOrderNumber.cs
@@ -28,14 +28,14 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
Print,
Abort
}
- public bool DialogIsDone { get; private set; }
- public int SerialNumber { get; private set; }
- public int Ordernumber { get; private set; }
+ public Boolean DialogIsDone { get; private set; }
+ public Int32 SerialNumber { get; private set; }
+ public Int32 Ordernumber { get; private set; }
- private int? OldOrderNumber { get; set; }
+ private Int32? OldOrderNumber { get; set; }
- private bool Error = false;
- public ProductionProcessCheckOrderNumber(int? oldOrderNumber = null)
+ private Boolean Error = false;
+ public ProductionProcessCheckOrderNumber(Int32? oldOrderNumber = null)
{
OldOrderNumber = oldOrderNumber;
@@ -70,19 +70,19 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
isDone?.Invoke(this, EventArgs.Empty);
}
- private void StepMismatch(string msg)
+ private void StepMismatch(String msg)
{
UserControl.SetDesc(msg);
UserControl.SetFocusMe();
//UserControl.Focus();
- base.NewStatus(msg);
+ NewStatus(msg);
UserControl.BarcodeInput += UserControl_KeyDown;
}
- private void UserControl_KeyDown(object sender, string input)
+ private void UserControl_KeyDown(Object sender, String input)
{
var a = input;
@@ -120,7 +120,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
}
- private void GetPcbMapping(string pcbID)
+ private void GetPcbMapping(String pcbID)
{
if (string.IsNullOrEmpty(pcbID))
{
@@ -148,7 +148,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
using (var sr = new StreamReader(responseStream))
{
var responseJson = sr.ReadToEnd();
- var a = JsonConvert.DeserializeObject(responseJson);
+ var a = JsonConvert.DeserializeObject(responseJson);
SerialNumber = Convert.ToInt32(a[0]);
Ordernumber = Convert.ToInt32(a[1]);
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckSerialNumber.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckSerialNumber.cs
index 9ee88c3f..b93f17f9 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckSerialNumber.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessCheckSerialNumber.cs
@@ -28,13 +28,13 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
Print,
Abort
}
- public bool DialogIsDone { get; private set; }
- public string PcbSerialNumber { get; private set; }
+ public Boolean DialogIsDone { get; private set; }
+ public String PcbSerialNumber { get; private set; }
- public string AltRadio { get; private set; }
+ public String AltRadio { get; private set; }
- private bool Error = false;
- public ProductionProcessCheckSerialNumber(String pcbSerialNumber, string altRadio = null)
+ private Boolean Error = false;
+ public ProductionProcessCheckSerialNumber(String pcbSerialNumber, String altRadio = null)
{
PcbSerialNumber = pcbSerialNumber;
@@ -69,7 +69,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
isDone?.Invoke(this, EventArgs.Empty);
}
- private void StepMismatch(string msg)
+ private void StepMismatch(String msg)
{
base.currentProcessState = ProductionProcessState.Error;
base.NewStatus(msg);
@@ -79,7 +79,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
}
- private void UserControl_KeyDown(object sender, string input)
+ private void UserControl_KeyDown(Object sender, String input)
{
var a = input;
PcbSerialNumber = Meter.SerialNumber;
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessDone.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessDone.cs
index 85cae768..52ac9230 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessDone.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessDone.cs
@@ -14,7 +14,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
{
public class ProductionProcessDone : BaseProductionProcess
{
- public event EventHandler> isDone;
+ public event EventHandler> isDone;
private UcDialog UserControl;
public DialogResult Result = DialogResult.None;
public enum DialogResult
@@ -24,9 +24,9 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
Print,
Abort
}
- public bool DialogIsDone { get; private set; }
- private bool Error = false;
- public ProductionProcessDone(bool error = false)
+ public Boolean DialogIsDone { get; private set; }
+ private Boolean Error = false;
+ public ProductionProcessDone(Boolean error = false)
{
Error = error;
DialogIsDone = false;
@@ -78,10 +78,10 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
break;
}
}
- isDone?.Invoke(null, new Tuple(retry, abort, print));
+ isDone?.Invoke(null, new Tuple(retry, abort, print));
}
- private void StepError(string ErrorText = "Ein Fehler ist aufgetreten")
+ private void StepError(String ErrorText = "Ein Fehler ist aufgetreten")
{
UserControl.SetDesc(ErrorText);
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessFinalParameterizationFix.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessFinalParameterizationFix.cs
index 2bcabab6..46e3050a 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessFinalParameterizationFix.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessFinalParameterizationFix.cs
@@ -59,7 +59,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
public Task> wirteRegisterInBetweenCheck(String reg, Int32 value, Boolean waitForResult = true,
- Boolean checkRegister = false, int addToCheck = 10, int addFromCheck = 0)
+ Boolean checkRegister = false, Int32 addToCheck = 10, Int32 addFromCheck = 0)
{
return new Task>(() =>
{
@@ -299,7 +299,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
- var funkadresse = new List();
+ var funkadresse = new List();
funkadresse.AddRange((new Byte[] { 0x0E, 0x9F, 0xAC, 0xC6 }).ToArray());
funkadresse.AddRange((new Byte[] { 0xA0, 0xE1, 0xEF, 0x1C }).ToArray());
funkadresse.AddRange((new Byte[] { 0x3B, 0x27, 0xA4, 0x9B }).ToArray());
@@ -349,7 +349,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
var ret = true;
- int done = 0;
+ Int32 done = 0;
foreach (var cTask in overAllResult)
{
cTask.RunSynchronously();
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessFinalParameterizationVakoCsd.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessFinalParameterizationVakoCsd.cs
index a982e8cd..357c8a66 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessFinalParameterizationVakoCsd.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessFinalParameterizationVakoCsd.cs
@@ -15,9 +15,9 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
{
private UcPlain UserControl;
private ProductionProcessConnect connectProcess;
- private bool hasRadio;
+ private Boolean hasRadio;
- public ProductionProcessFinalParameterizationVakoCsd(ProductionProcessConnect connectProcess, bool registerHasRadio = true)
+ public ProductionProcessFinalParameterizationVakoCsd(ProductionProcessConnect connectProcess, Boolean registerHasRadio = true)
{
this.connectProcess = connectProcess;
name = "Kunden Parametrierung";
@@ -66,7 +66,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
public Task> wirteRegisterInBetweenCheck(String reg, Int32 value, Boolean waitForResult = true,
- Boolean checkRegister = false, int addToCheck = 10, int addFromCheck = 0)
+ Boolean checkRegister = false, Int32 addToCheck = 10, Int32 addFromCheck = 0)
{
return new Task>(() =>
{
@@ -126,7 +126,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
//SENSUSRADIO_EncryptionKey dont reserve SENSUSRADIO_EncryptionKey!
if (item.RegisterName.ToLower().Contains("displaypow".ToLower()) || item.RegisterName.ToLower().Contains("METROLOGYASST_FlowPoint".ToLower()))
{
- overAllResult.Add(_currentGenesis_WriteRegister(item.RegisterName, new byte[] { item.RegisterValue.ToArray()[0] }, true, true));
+ overAllResult.Add(_currentGenesis_WriteRegister(item.RegisterName, new Byte[] { item.RegisterValue.ToArray()[0] }, true, true));
}
else if (item.RegisterName.ToLower().Contains("SENSUSRADIO_EncryptionKey".ToLower()))
{
@@ -146,9 +146,9 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
//}
}
- overAllResult.Add(_currentGenesis_WriteRegister("CUSTOMER_AlarmEnableMask", new byte[] { 0x00, 0x00, 0x80, 0x53 }.Reverse().ToArray(), true, false)); ;
- overAllResult.Add(_currentGenesis_WriteRegister("CUSTOMER_AlarmBroadcastMask", new byte[] { 0x00, 0x00, 0x1f, 0xdc }.Reverse().ToArray(), true, false));
- overAllResult.Add(_currentGenesis_WriteRegister("CUSTOMER_AlarmVisualMask", new byte[] { 0x00, 0x00, 0x1f, 0xdc }.Reverse().ToArray(), true, false));
+ overAllResult.Add(_currentGenesis_WriteRegister("CUSTOMER_AlarmEnableMask", new Byte[] { 0x00, 0x00, 0x80, 0x53 }.Reverse().ToArray(), true, false)); ;
+ overAllResult.Add(_currentGenesis_WriteRegister("CUSTOMER_AlarmBroadcastMask", new Byte[] { 0x00, 0x00, 0x1f, 0xdc }.Reverse().ToArray(), true, false));
+ overAllResult.Add(_currentGenesis_WriteRegister("CUSTOMER_AlarmVisualMask", new Byte[] { 0x00, 0x00, 0x1f, 0xdc }.Reverse().ToArray(), true, false));
foreach (var item in myJsonResponse.Where(m => m.Source == ProgrammingSource.Csd))
@@ -194,7 +194,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
}
var ret = true;
- int done = 0;
+ Int32 done = 0;
foreach (var cTask in overAllResult)
{
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessPasswordFile.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessPasswordFile.cs
index 4213afb5..19c293f5 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessPasswordFile.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessPasswordFile.cs
@@ -38,9 +38,9 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
return UserControl;
}
- private void updateImage(Image ctlImage, bool? success = null)
+ private void updateImage(Image ctlImage, Boolean? success = null)
{
- string path = "/Resources/iconWating.png";
+ String path = "/Resources/iconWating.png";
if (success.HasValue)
{
if (success.Value)
@@ -60,7 +60,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
{
base.currentProcessState = ProductionProcessState.Done;
return;
- bool ret = RequestPassword();
+ Boolean ret = RequestPassword();
updateImage(UserControl.RequestPassword, ret);
base.Progress = base.Progress + 16;
@@ -137,14 +137,14 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
{
public Int64? orderNumber = null;
public Int64? radioAdress = null;
- public string Skeleton = "";
- public List listOfHashes = new List();
- public List listOfPasswords = new List();
+ public String Skeleton = "";
+ public List listOfHashes = new List();
+ public List listOfPasswords = new List();
}
private MeterPasswordContainer pwContainer = new MeterPasswordContainer();
private MeterPwdFile meterPwdFile;
- public bool RequestPassword()
+ public Boolean RequestPassword()
{
base.NewStatus($"Request Passwords");
var url = ServiceUrls.GenesisGetPasswordContainerServiceUrl();
@@ -152,7 +152,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
url = ($"{url}{Meter.PcbId}");
var errorCode = 0;
- var header = new Dictionary();
+ var header = new Dictionary();
header.Add("Cache-Control", "no-cache");
header.Add("X-Node-Token", "d5b8c0b2-81f6-4421-80d0-44eb2093e616");
var resp = LocalWebRequest.GetRequestWithError(url, out errorCode, 20000, header,true);
@@ -166,13 +166,13 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
}
- public bool CreatePasswordFile()
+ public Boolean CreatePasswordFile()
{
meterPwdFile = new MeterPwdFile(Meter);
return meterPwdFile.BuildPwdFile(pwContainer.listOfPasswords, 1, pwContainer.Skeleton);
}
- public bool WritePasswordFileToMeter()
+ public Boolean WritePasswordFileToMeter()
{
if (meterPwdFile.UnlockEraseWriteMeterPwdFile())
{
@@ -180,7 +180,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
}
return false;
}
- public bool UpdatePasswordinDb()
+ public Boolean UpdatePasswordinDb()
{
var newPs = Encoding.UTF8.GetString(pwContainer.listOfPasswords.Last());
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessRadioCheck.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessRadioCheck.cs
index b3e22253..172c63f5 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessRadioCheck.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessRadioCheck.cs
@@ -122,24 +122,24 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
private SIRTCOM.Statemashine stm;
private static HttpClient httpclient;
- private byte? RSSI_PAM_Min;
- private byte? RSSI_PAM_Max;
- private byte? RSSI_PAM;
- private byte? RSSI_SEMI_Min;
- private byte? RSSI_SEMI_Max;
- private byte? RSSI_SEMI;
+ private Byte? RSSI_PAM_Min;
+ private Byte? RSSI_PAM_Max;
+ private Byte? RSSI_PAM;
+ private Byte? RSSI_SEMI_Min;
+ private Byte? RSSI_SEMI_Max;
+ private Byte? RSSI_SEMI;
- public byte BoxNr;
+ public Byte BoxNr;
- public int Ordernumber;
+ public Int32 Ordernumber;
public UInt32 RadioAdress;
- public byte Comport;
+ public Byte Comport;
- public string EncyptionKey = "";
+ public String EncyptionKey = "";
- private void enableBtn(Button btn, bool enable)
+ private void enableBtn(Button btn, Boolean enable)
{
btn.Dispatcher.Invoke(DispatcherPriority.Send,
new Action(() =>
@@ -179,7 +179,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
await GetRssiMinMaxAsync(BoxNr, Ordernumber);
SetUi();
- GetRSSI((int)RadioAdress, Comport, EncyptionKey);
+ GetRSSI((Int32)RadioAdress, Comport, EncyptionKey);
SetUi();
}
catch (Exception ex)
@@ -216,10 +216,10 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
private class SaveData
{
public Int32 RadioAdress { get; set; }
- public byte RSSI_PAM { get; set; }
- public byte RSSI_SEMI { get; set; }
- public int LimitId { get; set; }
- public byte Result { get; set; }
+ public Byte RSSI_PAM { get; set; }
+ public Byte RSSI_SEMI { get; set; }
+ public Int32 LimitId { get; set; }
+ public Byte Result { get; set; }
}
@@ -231,9 +231,9 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
DebugMessage("Calling SaveRSSI Webservice...", true);
try
{
- saveData.RadioAdress = (int)RadioAdress; // 0-4294967295
- string url = $"{ServiceUrls.GenesisRadioCheckServiceUrl()}SaveRSSI";
- string body = JsonConvert.SerializeObject(saveData);
+ saveData.RadioAdress = (Int32)RadioAdress; // 0-4294967295
+ String url = $"{ServiceUrls.GenesisRadioCheckServiceUrl()}SaveRSSI";
+ String body = JsonConvert.SerializeObject(saveData);
await PostDataAsync(url, body);
DebugMessage(" Ready\r\n", true);
}
@@ -244,14 +244,14 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
}
- private async Task GetRssiMinMaxAsync(byte BoxNr, Int32 FaNr)
+ private async Task GetRssiMinMaxAsync(Byte BoxNr, Int32 FaNr)
{
//DebugMessage("Calling GetLimits Webservice...", true);
try
{
// TODO anpassen
- string url = $"{ServiceUrls.GenesisRadioCheckServiceUrl()}GetLimits/{BoxNr}/{FaNr}";
- string body = await GetResponseAsync(url);
+ String url = $"{ServiceUrls.GenesisRadioCheckServiceUrl()}GetLimits/{BoxNr}/{FaNr}";
+ String body = await GetResponseAsync(url);
JObject o = JObject.Parse(body);
saveData.LimitId = Convert.ToInt32(o.SelectToken("LimitId").ToString());
@@ -276,7 +276,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
}
}
- private void GetRSSI(Int32 RadioAdress, Int32 ByteCOMPort, string strKey)
+ private void GetRSSI(Int32 RadioAdress, Int32 ByteCOMPort, String strKey)
{
RSSI_PAM = null;
@@ -284,11 +284,11 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
stm = new SIRTCOM.Statemashine();
- byte P81_1 = 0;
+ Byte P81_1 = 0;
saveData.RadioAdress = RadioAdress;
- stm.initialise((byte)ByteCOMPort);
+ stm.initialise((Byte)ByteCOMPort);
SIRTCOM.Wrapper wrp = new SIRTCOM.Wrapper();
stm.StartLoggin("C:\\GenesisLog\\log.txt");
@@ -332,12 +332,12 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
}
- public void DebugMessage(string value, Boolean Append = false)
+ public void DebugMessage(String value, Boolean Append = false)
{
NewStatus(value);
}
- private void GotRSSICallback(byte Rssi_Semi_Sirt, byte Rssi_Pam_Cord)
+ private void GotRSSICallback(Byte Rssi_Semi_Sirt, Byte Rssi_Pam_Cord)
{
// RSSI beim Empfangen der PAM gemessen vom Cordonel (Sendestärke des SIRT verpackt in SEMI, byte 20)
DebugMessage($"RSSI Cord of PAM (Sirt => Cord):{Rssi_Pam_Cord}\r\n", true);
@@ -383,7 +383,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
- private void Stm_OnStateChanged(object sender, SIRTCOM.MyEventArgs e)
+ private void Stm_OnStateChanged(Object sender, SIRTCOM.MyEventArgs e)
{
// our Pam
SIRTCOM.PAM Pam = stm.GetPAM(1);
@@ -401,20 +401,20 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
stm.Stop();
stm.ClearPam();
- string HexbytesSEMI = Pam.Semi.HexData.Replace(" ", "");
- byte[] SEMI_bytes = new byte[HexbytesSEMI.Length / 2];
+ String HexbytesSEMI = Pam.Semi.HexData.Replace(" ", "");
+ Byte[] SEMI_bytes = new Byte[HexbytesSEMI.Length / 2];
- for (int i = 0; i < HexbytesSEMI.Length; i += 2)
+ for (Int32 i = 0; i < HexbytesSEMI.Length; i += 2)
SEMI_bytes[i / 2] = Convert.ToByte(HexbytesSEMI.Substring(i, 2), 16);
// SEMI Status
if (SEMI_bytes[19] == 0)
{
// RSSI beim Empfangen der SEMI gemessen vom Sirt
- byte Semi_Rssi_Sirt = SEMI_bytes[2];
+ Byte Semi_Rssi_Sirt = SEMI_bytes[2];
// RSSI beim Empfangen der PAM gemessen vom Cordonel
- byte Pam_Rssi_Cord = SEMI_bytes[20];
+ Byte Pam_Rssi_Cord = SEMI_bytes[20];
GotRSSICallback(Semi_Rssi_Sirt, Pam_Rssi_Cord);
}
@@ -431,7 +431,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
}
}
- public static async Task PostDataAsync(string url, string data)
+ public static async Task PostDataAsync(String url, String data)
{
httpclient = new HttpClient();
// 20 Sekunden Timeout
@@ -441,11 +441,11 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
HttpResponseMessage response = await httpclient.PostAsync(url, queryString);
response.EnsureSuccessStatusCode();
- string content = await response.Content.ReadAsStringAsync();
+ String content = await response.Content.ReadAsStringAsync();
return content;
}
- static async Task GetResponseAsync(string url)
+ static async Task GetResponseAsync(String url)
{
httpclient = new HttpClient();
// 20 Sekunden Timeout
@@ -454,7 +454,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
HttpResponseMessage response = httpclient.GetAsync(url).Result;
response.EnsureSuccessStatusCode();
- string content = await response.Content.ReadAsStringAsync();
+ String content = await response.Content.ReadAsStringAsync();
return content;
}
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessShippingMode.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessShippingMode.cs
index d532467a..95fee41c 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessShippingMode.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessShippingMode.cs
@@ -13,9 +13,9 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
public class ProductionProcessShippingMode : BaseProductionProcess
{
private UcPlain UserControl;
- private bool doRestart = false;
- private bool hasRadio = false;
- public ProductionProcessShippingMode(bool restart = false, bool registerHasRadio = true)
+ private Boolean doRestart = false;
+ private Boolean hasRadio = false;
+ public ProductionProcessShippingMode(Boolean restart = false, Boolean registerHasRadio = true)
{
name = "Versandbereitschaft herstellen";
currentProcessState = ProductionProcessState.Waiting;
@@ -48,7 +48,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
{
Meter.ResetAlarm(GenesisMeter.Alarm.ALL);//(true, new byte[] { 0x00, 0x00, 0x00, 0x01 });
- Meter.SetLcdText(true, new byte[] { 0x00, 0x00, 0x00, 0x01 });
+ Meter.SetLcdText(true, new Byte[] { 0x00, 0x00, 0x00, 0x01 });
Meter.ResetAlarm(GenesisMeter.Alarm.EMPTY_PIPE);//(true, new byte[] { 0x00, 0x00, 0x00, 0x01 });
@@ -58,7 +58,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
if (Meter.StoreAllConfigurations())
{
- var writeList = new List();
+ var writeList = new List();
writeList.Add(Meter.WriteRegister("SENSUSRADIO_SystemState", 1, true, false));
writeList.Add(Meter.WriteRegister("SENSUSRADIO_MainAlarmMask", 0, true, false));
@@ -90,12 +90,12 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
{
if (doRestart)
{
- var CheckValuesAufterBoot = new List>();
- CheckValuesAufterBoot.Add(new Tuple("METROLOGYASST_PulseLength", Meter.ReadRegister("METROLOGYASST_PulseLength")));
- CheckValuesAufterBoot.Add(new Tuple("POWERMON_BatteryQuantity", Meter.ReadRegister("POWERMON_BatteryQuantity")));
- CheckValuesAufterBoot.Add(new Tuple("GENESISFLOW_MeterSize", Meter.ReadRegister("GENESISFLOW_MeterSize")));
- CheckValuesAufterBoot.Add(new Tuple("GENESISFLOW_CalFactor1", Meter.ReadRegister("GENESISFLOW_CalFactor1")));
- CheckValuesAufterBoot.Add(new Tuple("SENSUSRADIO_RadioAddress", Meter.ReadRegister("SENSUSRADIO_RadioAddress")));
+ var CheckValuesAufterBoot = new List>();
+ CheckValuesAufterBoot.Add(new Tuple("METROLOGYASST_PulseLength", Meter.ReadRegister("METROLOGYASST_PulseLength")));
+ CheckValuesAufterBoot.Add(new Tuple("POWERMON_BatteryQuantity", Meter.ReadRegister("POWERMON_BatteryQuantity")));
+ CheckValuesAufterBoot.Add(new Tuple("GENESISFLOW_MeterSize", Meter.ReadRegister("GENESISFLOW_MeterSize")));
+ CheckValuesAufterBoot.Add(new Tuple("GENESISFLOW_CalFactor1", Meter.ReadRegister("GENESISFLOW_CalFactor1")));
+ CheckValuesAufterBoot.Add(new Tuple("SENSUSRADIO_RadioAddress", Meter.ReadRegister("SENSUSRADIO_RadioAddress")));
var _meterResetPsu = new MeterResetPsu(Meter)
{
StoreConfigEnable = true
@@ -106,7 +106,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
Meter.Login();
- bool? hasDiffrences = null;
+ Boolean? hasDiffrences = null;
foreach (var item in CheckValuesAufterBoot)
{
if (!item.Item2.SequenceEqual(Meter.ReadRegister(item.Item1)))
@@ -187,11 +187,11 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
{
if (doRestart)
{
- var CheckValuesAufterBoot = new List>();
- CheckValuesAufterBoot.Add(new Tuple("METROLOGYASST_PulseLength", Meter.ReadRegister("METROLOGYASST_PulseLength")));
- CheckValuesAufterBoot.Add(new Tuple("POWERMON_BatteryQuantity", Meter.ReadRegister("POWERMON_BatteryQuantity")));
- CheckValuesAufterBoot.Add(new Tuple("GENESISFLOW_MeterSize", Meter.ReadRegister("GENESISFLOW_MeterSize")));
- CheckValuesAufterBoot.Add(new Tuple("GENESISFLOW_CalFactor1", Meter.ReadRegister("GENESISFLOW_CalFactor1")));
+ var CheckValuesAufterBoot = new List>();
+ CheckValuesAufterBoot.Add(new Tuple("METROLOGYASST_PulseLength", Meter.ReadRegister("METROLOGYASST_PulseLength")));
+ CheckValuesAufterBoot.Add(new Tuple("POWERMON_BatteryQuantity", Meter.ReadRegister("POWERMON_BatteryQuantity")));
+ CheckValuesAufterBoot.Add(new Tuple("GENESISFLOW_MeterSize", Meter.ReadRegister("GENESISFLOW_MeterSize")));
+ CheckValuesAufterBoot.Add(new Tuple("GENESISFLOW_CalFactor1", Meter.ReadRegister("GENESISFLOW_CalFactor1")));
var _meterResetPsu = new MeterResetPsu(Meter)
{
@@ -203,7 +203,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
Meter.Login();
- bool? hasDiffrences = null;
+ Boolean? hasDiffrences = null;
foreach (var item in CheckValuesAufterBoot)
{
if (!item.Item2.SequenceEqual(Meter.ReadRegister(item.Item1)))
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessSpecialConfig.cs b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessSpecialConfig.cs
index 5d3392a4..ee890fe2 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessSpecialConfig.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Actions/ProductionProcessSpecialConfig.cs
@@ -16,7 +16,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
{
private UcDialog UserControl;
- public bool DialogIsDone { get; private set; }
+ public Boolean DialogIsDone { get; private set; }
public ProductionProcessSpecialConfig()
{
@@ -57,7 +57,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
var radioDefault = new UcDialog.DialogOption("old default", "same as iperl", () =>
{
- var funkadresse = new List();
+ var funkadresse = new List();
funkadresse.AddRange((new Byte[] { 0xE6, 0xC8, 0x88, 0x00 }).ToArray());
funkadresse.AddRange((new Byte[] { 0xDE, 0xB8, 0x68, 0xC0 }).ToArray());
funkadresse.AddRange((new Byte[] { 0xD6, 0xA8, 0x48, 0x80 }).ToArray());
@@ -79,7 +79,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Actions
var optOneLiter = new UcDialog.DialogOption("new default", "new default key", () =>
{
- var funkadresse = new List();
+ var funkadresse = new List();
funkadresse.AddRange((new Byte[] { 0x0E, 0x9F, 0xAC, 0xC6 }).ToArray());
funkadresse.AddRange((new Byte[] { 0xA0, 0xE1, 0xEF, 0x1C }).ToArray());
funkadresse.AddRange((new Byte[] { 0x3B, 0x27, 0xA4, 0x9B }).ToArray());
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/BaseProductionProcess.cs b/Common/ProductionUiCordonel/ProductionProcesses/BaseProductionProcess.cs
index 54596056..ca8334f3 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/BaseProductionProcess.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/BaseProductionProcess.cs
@@ -12,8 +12,8 @@ namespace ProductionUiCordonel.ProductionProcesses
{
public abstract class BaseProductionProcess : IProductionProcess
{
- private int _progress = 0;
- public int Progress
+ private Int32 _progress = 0;
+ public Int32 Progress
{
get { return _progress; }
set
@@ -23,7 +23,7 @@ namespace ProductionUiCordonel.ProductionProcesses
}
}
public ProductionProcessState currentProcessState;
- public string name;
+ public String name;
public GenesisMeter Meter { get; internal set; }
@@ -34,7 +34,7 @@ namespace ProductionUiCordonel.ProductionProcesses
StringBuilder sbLog = new StringBuilder();
- public string GetName()
+ public String GetName()
{
return name;
}
@@ -73,7 +73,7 @@ namespace ProductionUiCordonel.ProductionProcesses
}
- internal void NewStatus(string v)
+ internal void NewStatus(String v)
{
PopUpProcessLogHandler?.Invoke(this, new PopUpProcessLogArgs(v));
sbLog.AppendLine(v);
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/Enum/ProductionProcessState.cs b/Common/ProductionUiCordonel/ProductionProcesses/Enum/ProductionProcessState.cs
index 20583a9c..76b6c12c 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/Enum/ProductionProcessState.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/Enum/ProductionProcessState.cs
@@ -16,7 +16,7 @@ namespace ProductionUiCordonel.ProductionProcesses.Enum
public static class ProductionProcessStateHelper
{
- public static string GetTextFromProductionProcessState(ProductionProcessState sate)
+ public static String GetTextFromProductionProcessState(ProductionProcessState sate)
{
switch (sate)
{
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/IProductionProcess.cs b/Common/ProductionUiCordonel/ProductionProcesses/IProductionProcess.cs
index 5ca8999c..4e98a4e3 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/IProductionProcess.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/IProductionProcess.cs
@@ -17,7 +17,7 @@ namespace ProductionUiCordonel.ProductionProcesses
event EventHandler PopUpProcessProgressChangedHandler;
event EventHandler PopUpProcessLogHandler;
- string GetName();
+ String GetName();
ProductionProcessState GetState();
UserControl GetUserControl();
void Start(GenesisMeter Meter,CancellationToken cancellationToken);
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/MultiProcessController.cs b/Common/ProductionUiCordonel/ProductionProcesses/MultiProcessController.cs
index 9c663f06..1775d000 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/MultiProcessController.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/MultiProcessController.cs
@@ -96,12 +96,12 @@ namespace ProductionUiCordonel.ProductionProcesses
}
- private void Process_PopUpProcessProgressChangedHandler(object sender, PopUpProcessProgressArgs e)
+ private void Process_PopUpProcessProgressChangedHandler(Object sender, PopUpProcessProgressArgs e)
{
ProcessProgressHandler?.Invoke(sender,e);
}
- private void Process_PopUpProcessLogHandler(object sender, PopUpProcessLogArgs e)
+ private void Process_PopUpProcessLogHandler(Object sender, PopUpProcessLogArgs e)
{
ProcessLogHandler?.Invoke(sender,e);
}
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/PopUpProcessLogArgs.cs b/Common/ProductionUiCordonel/ProductionProcesses/PopUpProcessLogArgs.cs
index d07f5c58..8a16e1cb 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/PopUpProcessLogArgs.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/PopUpProcessLogArgs.cs
@@ -8,8 +8,8 @@ namespace ProductionUiCordonel.ProductionProcesses
{
public class PopUpProcessLogArgs : EventArgs
{
- public readonly string Data;
- public PopUpProcessLogArgs(string text)
+ public readonly String Data;
+ public PopUpProcessLogArgs(String text)
{
Data = text;
}
diff --git a/Common/ProductionUiCordonel/ProductionProcesses/PopUpProcessProgressArgs.cs b/Common/ProductionUiCordonel/ProductionProcesses/PopUpProcessProgressArgs.cs
index 59c75c76..59035ad3 100644
--- a/Common/ProductionUiCordonel/ProductionProcesses/PopUpProcessProgressArgs.cs
+++ b/Common/ProductionUiCordonel/ProductionProcesses/PopUpProcessProgressArgs.cs
@@ -14,8 +14,8 @@ namespace ProductionUiCordonel.ProductionProcesses
SubProcess,
}
public readonly ProcessProgessType ProgressType;
- public readonly int Progress;
- public PopUpProcessProgressArgs(int progress, ProcessProgessType type)
+ public readonly Int32 Progress;
+ public PopUpProcessProgressArgs(Int32 progress, ProcessProgessType type)
{
Progress = progress;
ProgressType = type;
diff --git a/Common/ProductionUiCordonel/ProductionUiCordonel.csproj b/Common/ProductionUiCordonel/ProductionUiCordonel.csproj
index 8e43cfb5..6c43179f 100644
--- a/Common/ProductionUiCordonel/ProductionUiCordonel.csproj
+++ b/Common/ProductionUiCordonel/ProductionUiCordonel.csproj
@@ -139,9 +139,13 @@
ctlMultiModePressure.xaml
+
+
+
+
@@ -177,6 +181,11 @@
+
+ Resources.de.resx
+ True
+ True
+
UcBarcodeInput.xaml
@@ -273,9 +282,15 @@
Settings.settings
True
+
+ ResXFileCodeGenerator
+ Resources.de.Designer.cs
+ Designer
+
ResXFileCodeGenerator
Resources.Designer.cs
+ Designer
@@ -347,6 +362,10 @@
{4B88B0D3-E791-4774-9521-EABEACDC420E}
Logging
+
+ {2fd60cf1-45cd-4060-b8e5-4f39fba7f1cb}
+ ProcessExec
+
diff --git a/Common/ProductionUiCordonel/Properties/Resources.Designer.cs b/Common/ProductionUiCordonel/Properties/Resources.Designer.cs
index bc038f93..25759934 100644
--- a/Common/ProductionUiCordonel/Properties/Resources.Designer.cs
+++ b/Common/ProductionUiCordonel/Properties/Resources.Designer.cs
@@ -129,5 +129,23 @@ namespace ProductionUiCordonel.Properties {
return ((System.Drawing.Bitmap)(obj));
}
}
+
+ ///
+ /// Looks up a localized string similar to Idle.
+ ///
+ internal static string StrStateIdle {
+ get {
+ return ResourceManager.GetString("StrStateIdle", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Initial start.
+ ///
+ internal static string StrStateStartInitial {
+ get {
+ return ResourceManager.GetString("StrStateStartInitial", resourceCulture);
+ }
+ }
}
}
diff --git a/Common/ProductionUiCordonel/Properties/Resources.de.Designer.cs b/Common/ProductionUiCordonel/Properties/Resources.de.Designer.cs
new file mode 100644
index 00000000..e69de29b
diff --git a/Common/ProductionUiCordonel/Properties/Resources.de.resx b/Common/ProductionUiCordonel/Properties/Resources.de.resx
new file mode 100644
index 00000000..379bca46
--- /dev/null
+++ b/Common/ProductionUiCordonel/Properties/Resources.de.resx
@@ -0,0 +1,148 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+
+ ..\Resources\ConnectPlugged_16x.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\Connect_16x.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\iconCheck.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\iconWarn.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\iconWating.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\Refresh_16x.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\CLEARMAtrix.JPG;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ Leerlauf
+
+
+ Neustart
+
+
\ No newline at end of file
diff --git a/Common/ProductionUiCordonel/Properties/Resources.resx b/Common/ProductionUiCordonel/Properties/Resources.resx
index a8ca6250..0d3ffc2d 100644
--- a/Common/ProductionUiCordonel/Properties/Resources.resx
+++ b/Common/ProductionUiCordonel/Properties/Resources.resx
@@ -139,4 +139,10 @@
..\Resources\CLEARMAtrix.JPG;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+ Idle
+
+
+ Initial start
+
\ No newline at end of file
diff --git a/Common/ProductionUiCordonel/UserControls/FinalTest/UcBarcodeInput.xaml.cs b/Common/ProductionUiCordonel/UserControls/FinalTest/UcBarcodeInput.xaml.cs
index be091ebd..f6f0caf3 100644
--- a/Common/ProductionUiCordonel/UserControls/FinalTest/UcBarcodeInput.xaml.cs
+++ b/Common/ProductionUiCordonel/UserControls/FinalTest/UcBarcodeInput.xaml.cs
@@ -12,7 +12,7 @@ namespace ProductionUiCordonel.UserControls.FinalTest
public partial class UcBarcodeInput : UserControl
{
- public event EventHandler BarcodeInput;
+ public event EventHandler BarcodeInput;
public UcBarcodeInput()
{
@@ -21,15 +21,15 @@ namespace ProductionUiCordonel.UserControls.FinalTest
public class DialogOption
{
- public DialogOption(string headLine, string desc, Action selectedAction)
+ public DialogOption(String headLine, String desc, Action selectedAction)
{
HeadLine = headLine;
Desc = desc;
SelectedAction = selectedAction;
}
private Action SelectedAction;
- private string HeadLine = "Hl";
- private string Desc = "descr";
+ private String HeadLine = "Hl";
+ private String Desc = "descr";
public UIElement GeneratBtn()
{
var btn = new Button();
@@ -51,7 +51,7 @@ namespace ProductionUiCordonel.UserControls.FinalTest
}
- internal void SetDesc(string v)
+ internal void SetDesc(String v)
{
lblDescription.Dispatcher.Invoke(DispatcherPriority.Send,
new Action(() =>
@@ -74,7 +74,7 @@ namespace ProductionUiCordonel.UserControls.FinalTest
));
}
- public void inputKey(string input)
+ public void inputKey(String input)
{
this.Dispatcher.Invoke(DispatcherPriority.Send,
new Action(() =>
@@ -84,7 +84,7 @@ namespace ProductionUiCordonel.UserControls.FinalTest
));
}
- private void txtHiddenInput_KeyDown(object sender, KeyEventArgs e)
+ private void txtHiddenInput_KeyDown(Object sender, KeyEventArgs e)
{
//if (e.Key == Key.Enter)
//{
@@ -99,7 +99,7 @@ namespace ProductionUiCordonel.UserControls.FinalTest
}
- private void UserControl_MouseDown(object sender, MouseButtonEventArgs e)
+ private void UserControl_MouseDown(Object sender, MouseButtonEventArgs e)
{
this.Dispatcher.Invoke(DispatcherPriority.Send,
new Action(() =>
@@ -109,7 +109,7 @@ namespace ProductionUiCordonel.UserControls.FinalTest
));
}
- private void LblInput_MouseDown(object sender, MouseButtonEventArgs e)
+ private void LblInput_MouseDown(Object sender, MouseButtonEventArgs e)
{
this.Dispatcher.Invoke(DispatcherPriority.Send,
new Action(() =>
diff --git a/Common/ProductionUiCordonel/UserControls/FinalTest/UcDialog.xaml.cs b/Common/ProductionUiCordonel/UserControls/FinalTest/UcDialog.xaml.cs
index 7a5b4077..ddac27ec 100644
--- a/Common/ProductionUiCordonel/UserControls/FinalTest/UcDialog.xaml.cs
+++ b/Common/ProductionUiCordonel/UserControls/FinalTest/UcDialog.xaml.cs
@@ -29,15 +29,15 @@ namespace ProductionUiCordonel.UserControls.FinalTest
public class DialogOption
{
- public DialogOption(string headLine, string desc, Action selectedAction)
+ public DialogOption(String headLine, String desc, Action selectedAction)
{
HeadLine = headLine;
Desc = desc;
SelectedAction = selectedAction;
}
private Action SelectedAction;
- private string HeadLine = "Hl";
- private string Desc = "descr";
+ private String HeadLine = "Hl";
+ private String Desc = "descr";
public UIElement GeneratBtn()
{
var btn = new Button();
@@ -59,7 +59,7 @@ namespace ProductionUiCordonel.UserControls.FinalTest
}
- internal void SetDesc(string v)
+ internal void SetDesc(String v)
{
lblDescription.Dispatcher.Invoke(DispatcherPriority.Send,
new Action(() =>
diff --git a/Common/ProductionUiCordonel/UserControls/FinalTest/UcRadioCheck.xaml.cs b/Common/ProductionUiCordonel/UserControls/FinalTest/UcRadioCheck.xaml.cs
index f4c9c894..995e36a3 100644
--- a/Common/ProductionUiCordonel/UserControls/FinalTest/UcRadioCheck.xaml.cs
+++ b/Common/ProductionUiCordonel/UserControls/FinalTest/UcRadioCheck.xaml.cs
@@ -30,10 +30,10 @@ namespace ProductionUiCordonel.UserControls.FinalTest
{
public class UIContainerElement
{
- public int? Value = null;
+ public Int32? Value = null;
public System.Drawing.Color Color;
- public UIContainerElement(int? value)
+ public UIContainerElement(Int32? value)
{
Value = value;
if (!value.HasValue)
@@ -46,7 +46,7 @@ namespace ProductionUiCordonel.UserControls.FinalTest
}
}
- public string GetText()
+ public String GetText()
{
return Value.HasValue ? Value.Value.ToString() : "-";
}
@@ -63,7 +63,7 @@ namespace ProductionUiCordonel.UserControls.FinalTest
public UIContainerElement CordMax;
public UIContainerElement SirtMax;
- public UIContainer(int? cordMin = null, int? sirtMin = null, int? cordRssi = null, int? sirtRssi = null, int? cordMax = null, int? sirtMax = null)
+ public UIContainer(Int32? cordMin = null, Int32? sirtMin = null, Int32? cordRssi = null, Int32? sirtRssi = null, Int32? cordMax = null, Int32? sirtMax = null)
{
CordMin = new UIContainerElement(cordMin);
SirtMin = new UIContainerElement(sirtMin);
@@ -75,7 +75,7 @@ namespace ProductionUiCordonel.UserControls.FinalTest
//only when results from semi are prensent
if (CordRssi.Value.HasValue && SirtRssi.Value.HasValue)
{
- bool success = true;
+ Boolean success = true;
if (!CordMin.Value.HasValue || CordRssi.Value.Value < CordMin.Value.Value)
{
@@ -151,17 +151,17 @@ namespace ProductionUiCordonel.UserControls.FinalTest
InitializeComponent();
}
- private void btnReset_Click(object sender, RoutedEventArgs e)
+ private void btnReset_Click(Object sender, RoutedEventArgs e)
{
Task.Run(() => { OnResetRequested?.Invoke(sender, e); });
}
- private void Button_Click(object sender, RoutedEventArgs e)
+ private void Button_Click(Object sender, RoutedEventArgs e)
{
Task.Run(() => { OnRetryRequested?.Invoke(sender, e); });
}
- internal void ViewResult(int WaitSeconds = 10)
+ internal void ViewResult(Int32 WaitSeconds = 10)
{
@@ -189,18 +189,18 @@ namespace ProductionUiCordonel.UserControls.FinalTest
});
}
- private void BtnDone_Click(object sender, RoutedEventArgs e)
+ private void BtnDone_Click(Object sender, RoutedEventArgs e)
{
Task.Run(() => { OnDoneRequested?.Invoke(sender, e); });
BtnDone.IsEnabled = false;
}
- private void BtnDone_Copy_Click(object sender, RoutedEventArgs e)
+ private void BtnDone_Copy_Click(Object sender, RoutedEventArgs e)
{
Task.Run(() => { OnDoneRequested?.Invoke(sender, e); });
}
- private void BtnfrocePam_Click(object sender, RoutedEventArgs e)
+ private void BtnfrocePam_Click(Object sender, RoutedEventArgs e)
{
Task.Run(() => { OnForceAPam?.Invoke(sender, e); });
}
diff --git a/Common/ProductionUiCordonel/ctls/ctlMultiModeMarriage.xaml.cs b/Common/ProductionUiCordonel/ctls/ctlMultiModeMarriage.xaml.cs
index 9f63937b..70db61bf 100644
--- a/Common/ProductionUiCordonel/ctls/ctlMultiModeMarriage.xaml.cs
+++ b/Common/ProductionUiCordonel/ctls/ctlMultiModeMarriage.xaml.cs
@@ -1,4 +1,5 @@
-using ProductionUiCordonel.Model;
+using System;
+using ProductionUiCordonel.Model;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
@@ -22,9 +23,9 @@ namespace ProductionUiCordonel.ctls
//ViewModel.Store();
}
- private void btnMarry_Click(object sender, RoutedEventArgs e)
+ private void btnMarry_Click(Object sender, RoutedEventArgs e)
{
- Task.Run(() =>
+ Task.Run(() =>
{
return ViewModel.Store();
}).ContinueWith(a =>
diff --git a/Common/ProductionUiCordonel/ctls/ctlMultiModePicking.xaml.cs b/Common/ProductionUiCordonel/ctls/ctlMultiModePicking.xaml.cs
index 0ab71c0f..2fb36d16 100644
--- a/Common/ProductionUiCordonel/ctls/ctlMultiModePicking.xaml.cs
+++ b/Common/ProductionUiCordonel/ctls/ctlMultiModePicking.xaml.cs
@@ -39,12 +39,12 @@ namespace ProductionUiCordonel.ctls
ViewModel.OnUpdateUi += UpdatePickingUi;
}
- private void ViewModel_MeterDetectedHandler(object sender, EventArgs e)
+ private void ViewModel_MeterDetectedHandler(Object sender, EventArgs e)
{
Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() =>
{
- bool update = false;
+ Boolean update = false;
if (sender is null)
{
ViewModel.InputIsEnabled = false;
@@ -58,7 +58,7 @@ namespace ProductionUiCordonel.ctls
ViewModel.CurrentMeter.WriteRegister("GENESISFLOW_SealDisplay", 0);
ViewModel.CurrentMeter.WriteRegister("POWERMON_WarnFromClamp", (UInt32)473040000);
ViewModel.CurrentMeter.WriteRegister("SYSTEM_CalendarSeconds", Convert.ToInt32(ts.TotalSeconds));
- ViewModel.CurrentMeter.SetLcdText(false, new byte[] { 0x12, 0x34 });
+ ViewModel.CurrentMeter.SetLcdText(false, new Byte[] { 0x12, 0x34 });
//ViewModel.ReloadData(false);
@@ -67,7 +67,7 @@ namespace ProductionUiCordonel.ctls
));
}
- private void UpdatePickingUi(object sender, EventArgs e)
+ private void UpdatePickingUi(Object sender, EventArgs e)
{
icPicking.Dispatcher.Invoke(DispatcherPriority.Normal, new Action(() =>
{
@@ -84,7 +84,7 @@ namespace ProductionUiCordonel.ctls
}
- private void PickingData_OnDataChanged(object sender, EventArgs e)
+ private void PickingData_OnDataChanged(Object sender, EventArgs e)
{
if (sender is ObservableCollection newData)
{
diff --git a/Common/ProductionUiCordonel/ctls/ctlMultiModePressure.xaml.cs b/Common/ProductionUiCordonel/ctls/ctlMultiModePressure.xaml.cs
index 4fc8a26d..fc6a95f9 100644
--- a/Common/ProductionUiCordonel/ctls/ctlMultiModePressure.xaml.cs
+++ b/Common/ProductionUiCordonel/ctls/ctlMultiModePressure.xaml.cs
@@ -48,12 +48,12 @@ namespace ProductionUiCordonel.ctls
- private void ViewModel_MeterDetectedHandler(object sender, EventArgs e)
+ private void ViewModel_MeterDetectedHandler(Object sender, EventArgs e)
{
Dispatcher.Invoke(DispatcherPriority.Normal,
new Action(() =>
{
- bool update = false;
+ Boolean update = false;
if (sender is null)
{
ViewModel.InputIsEnabled = false;
@@ -66,23 +66,23 @@ namespace ProductionUiCordonel.ctls
));
}
- private void BtnPresueOk_Click(object sender, RoutedEventArgs e)
+ private void BtnPresueOk_Click(Object sender, RoutedEventArgs e)
{
ViewModel.StoreData(true);
}
- private void BtnPresueFailed_Click(object sender, RoutedEventArgs e)
+ private void BtnPresueFailed_Click(Object sender, RoutedEventArgs e)
{
ViewModel.StoreData(false);
}
- private void ViewModel_OnStoreDone(object sender, StringArgs e)
+ private void ViewModel_OnStoreDone(Object sender, StringArgs e)
{
MessageBox.Show(e.Content);
}
- private int? BarcodeInputActiveOffset = null;
- private string BarcodeInput = "";
+ private Int32? BarcodeInputActiveOffset = null;
+ private String BarcodeInput = "";
- private void TextBox_TextChanged(object sender, TextChangedEventArgs e)
+ private void TextBox_TextChanged(Object sender, TextChangedEventArgs e)
{
if (sender is TextBox txtSender)
{
@@ -120,9 +120,9 @@ namespace ProductionUiCordonel.ctls
}
- private void Button_Click(object sender, RoutedEventArgs e)
+ private void Button_Click(Object sender, RoutedEventArgs e)
{
- string input = "";
+ String input = "";
var obj = ((FrameworkElement)sender).DataContext;
if (obj is PressureTestPoints ptp)
{
diff --git a/Common/Ui/GenesisToolBox/FrmFwUpdate.cs b/Common/Ui/GenesisToolBox/FrmFwUpdate.cs
index de901d7d..fede9de0 100644
--- a/Common/Ui/GenesisToolBox/FrmFwUpdate.cs
+++ b/Common/Ui/GenesisToolBox/FrmFwUpdate.cs
@@ -145,6 +145,9 @@ namespace Xylem.Common.Ui.GenesisToolBox
///
/// Clear data table and set genesis to not connected
///
+ ///
+ /// - Enable update of Genesis Flow in Genesis Tool Box.
+ ///
private void Init()
{
ProcessViewControl(false);
@@ -1198,6 +1201,9 @@ namespace Xylem.Common.Ui.GenesisToolBox
}
+ ///
+ /// - Enable update of Genesis Flow in Genesis Tool Box.
+ ///
private void btnOpenPackageControlFile_Click(Object sender, EventArgs e)
{
//reload last path
@@ -1220,7 +1226,7 @@ namespace Xylem.Common.Ui.GenesisToolBox
tbxPackageFilePathName.Text = packageFilePathName;
if (_meterFwUpdate == null)
{
- _meterFwUpdate = new MeterFwUpdate(_currentGenesis);
+ _meterFwUpdate = new MeterFwUpdate(_currentGenesis, true);
}
if (_meterFwUpdate == null)
@@ -1261,7 +1267,7 @@ namespace Xylem.Common.Ui.GenesisToolBox
tbxBinaryPath.Text = binaryFilePath;
- var meterFwUpdate = new MeterFwUpdate(_currentGenesis);
+ var meterFwUpdate = new MeterFwUpdate(_currentGenesis, true);
if (meterFwUpdate.LoadFileApps(binaryFilePath))
{
lblFileAppsLoadedInfo.ForeColor = Color.Green;
@@ -1583,6 +1589,9 @@ namespace Xylem.Common.Ui.GenesisToolBox
///
///
///
+ ///
+ /// - Enable update of Genesis Flow in Genesis Tool Box.
+ ///
public Boolean Prepare(Int32 slot, String binaryPath, String packageInfoPath)
{
_updateGui = false;
@@ -1604,7 +1613,7 @@ namespace Xylem.Common.Ui.GenesisToolBox
tbxBinaryPath.Text = binaryPath;
if (_meterFwUpdate == null)
{
- _meterFwUpdate = new MeterFwUpdate(_currentGenesis);
+ _meterFwUpdate = new MeterFwUpdate(_currentGenesis, true);
}
if (_meterFwUpdate == null)
@@ -1638,7 +1647,7 @@ namespace Xylem.Common.Ui.GenesisToolBox
tbxPackageFilePathName.Text = packageInfoPath;
if (_meterFwUpdate == null)
{
- _meterFwUpdate = new MeterFwUpdate(_currentGenesis);
+ _meterFwUpdate = new MeterFwUpdate(_currentGenesis, true);
}
if (_meterFwUpdate == null)
@@ -1826,6 +1835,9 @@ namespace Xylem.Common.Ui.GenesisToolBox
dgvFiles.AutoResizeColumns();
}
+ ///
+ /// - Enable update of Genesis Flow in Genesis Tool Box.
+ ///
private void dgvFiles_CellContentClick(Object sender, DataGridViewCellEventArgs e)
{
@@ -1839,7 +1851,7 @@ namespace Xylem.Common.Ui.GenesisToolBox
lblFwNameSelected.Text = dgvFiles.Rows[e.RowIndex].Cells[1].Value.ToString();
lblSelectedID.Text = parentFilId.ToString();
- _meterFwUpdate = new MeterFwUpdate(_currentGenesis);
+ _meterFwUpdate = new MeterFwUpdate(_currentGenesis, true);
var fileApps = new List();
diff --git a/Common/Ui/GenesisToolBox/FrmLutUpdate.Designer.cs b/Common/Ui/GenesisToolBox/FrmLutUpdate.Designer.cs
index e85c58c2..9df88456 100644
--- a/Common/Ui/GenesisToolBox/FrmLutUpdate.Designer.cs
+++ b/Common/Ui/GenesisToolBox/FrmLutUpdate.Designer.cs
@@ -30,6 +30,7 @@
{
this.components = new System.ComponentModel.Container();
this.grpSetup = new System.Windows.Forms.GroupBox();
+ this.btnClearDisplay = new System.Windows.Forms.Button();
this.label10 = new System.Windows.Forms.Label();
this.tbxRadio = new System.Windows.Forms.TextBox();
this.tbxRegion = new System.Windows.Forms.TextBox();
@@ -76,7 +77,6 @@
this.label9 = new System.Windows.Forms.Label();
this.lblUpdateTime = new System.Windows.Forms.Label();
this.label7 = new System.Windows.Forms.Label();
- this.btnClearDisplay = new System.Windows.Forms.Button();
this.grpSetup.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
this.groupBox1.SuspendLayout();
@@ -107,6 +107,16 @@
this.grpSetup.TabStop = false;
this.grpSetup.Text = "Cordonel";
//
+ // btnClearDisplay
+ //
+ this.btnClearDisplay.Location = new System.Drawing.Point(128, 239);
+ this.btnClearDisplay.Name = "btnClearDisplay";
+ this.btnClearDisplay.Size = new System.Drawing.Size(116, 25);
+ this.btnClearDisplay.TabIndex = 33;
+ this.btnClearDisplay.Text = "Release Display";
+ this.btnClearDisplay.UseVisualStyleBackColor = true;
+ this.btnClearDisplay.Click += new System.EventHandler(this.btnClearDisplay_Click);
+ //
// label10
//
this.label10.AutoSize = true;
@@ -557,16 +567,6 @@
this.label7.TabIndex = 32;
this.label7.Text = "Cordonel LUT Update";
//
- // btnClearDisplay
- //
- this.btnClearDisplay.Location = new System.Drawing.Point(128, 239);
- this.btnClearDisplay.Name = "btnClearDisplay";
- this.btnClearDisplay.Size = new System.Drawing.Size(116, 25);
- this.btnClearDisplay.TabIndex = 33;
- this.btnClearDisplay.Text = "Clear Display";
- this.btnClearDisplay.UseVisualStyleBackColor = true;
- this.btnClearDisplay.Click += new System.EventHandler(this.btnClearDisplay_Click);
- //
// FrmLutUpdate
//
this.AccessibleRole = System.Windows.Forms.AccessibleRole.Sound;
diff --git a/Common/Ui/GenesisToolBox/FrmLutUpdate.cs b/Common/Ui/GenesisToolBox/FrmLutUpdate.cs
index 5c7737cd..2112d5c9 100644
--- a/Common/Ui/GenesisToolBox/FrmLutUpdate.cs
+++ b/Common/Ui/GenesisToolBox/FrmLutUpdate.cs
@@ -286,6 +286,8 @@ namespace Xylem.Common.Ui.GenesisToolBox
{
_tryConnectPcb = false;
ProcessViewControl(false);
+ btnClearDisplay.Enabled = true;
+
}));
}
}