Compare commits

...
Author SHA1 Message Date
Milan Hanajik 87572252a8 Reconfigured for Fuzhou PT300 2020-02-24 08:36:03 +01:00
Milan Hanajik efd5a2c2f1 ControlComWrap change for FUZHOU_300, ver. 2.18.1422 2020-02-24 08:35:28 +01:00
Milan Hanajik dbc8be0553 'Custom query' added to ResultsBrowser, ver. 2.18.1413 2020-02-14 16:22:44 +01:00
Milan Hanajik ca576e3448 ver. 2.18.1413 2020-02-10 14:19:36 +01:00
Milan Hanajik 3a55002027 ver. 2.18.1412 2020-02-10 13:55:58 +01:00
Milan Hanajik bbadacf7d3 Minor change 2020-02-10 12:13:05 +01:00
Milan Hanajik 2ff7b02e72 Output.Printers.Label with water meter s/n printed as a QR code, ver. 2.18.1411 2020-02-10 09:49:22 +01:00
Milan Hanajik 65c441d929 ver. 2.18.1406 2020-01-31 09:01:05 +01:00
Milan Hanajik 9390dc95c2 Solution upgraded to VS2012, ver. 2.18.1401 2020-01-17 08:27:46 +01:00
Milan Hanajik 97c612e49b ver. 2.18.1388 2019-12-19 11:25:30 +01:00
Milan Hanajik 4a185ed35b Output.DB.ProductionTracing : Alternative profuction tracing DB possible. 2019-12-18 17:48:11 +01:00
Milan Hanajik 2718c4021c RestoreAndFixBatch functionality modified. 2019-12-18 15:04:28 +01:00
Milan Hanajik ebb2950e84 (1) Bug fix in sending FM pump frequencies to control board, (2) More logging, ver. 2.18.1387 2019-12-18 13:25:05 +01:00
Milan Hanajik 67a53909f8 FixedstartDeferredEvalSeq : Delay time before grabbing images introduced. 2019-12-11 14:21:37 +01:00
Milan Hanajik fbfbbecca4 E5 fixed, ver. 2.18.1380 2019-12-11 14:21:24 +01:00
Milan Hanajik e8db0f46c3 MainSeq bug fix : Program crashed when OuterLoop.Start was started as the first test, ver. 2.18.1374 2019-12-05 14:52:00 +01:00
Milan Hanajik c1705713df ALZIR_25 : French language 2019-11-26 17:18:07 +01:00
Milan Hanajik 0fd1d9e141 Elde.RegisterReader.RegisterReader.Position, IRegisterReader.Position, etc. introduced, ver. 2.18.1367 2019-11-26 17:17:55 +01:00
Milan Hanajik 5ee66205a9 ALZIR_25 symbol and component (22.11.2019) added 2019-11-26 17:14:20 +01:00
Milan Hanajik 03e8108704 FixedStartDeferredEval a FixedStartMassCollDeferredEval, ver. 2.18.1362 2019-11-15 16:55:55 +01:00
Milan Hanajik ed4179be5f All three TesttMethods.Adjustment.WMErrorsForm-s are more robust. 2019-11-15 16:55:53 +01:00
Milan Hanajik bedbecbcc3 TestMethods.FixedStart.FixedStartSeq code cleanup, references to scale/tank/draining/mass measurement removed. 2019-11-15 16:55:29 +01:00
Milan Hanajik e81de2267b ver. 2.18.1361 2019-11-12 07:57:44 +01:00
Milan Hanajik 3dfff4ad70 New iPerlCommunication.iPerlHead porc. parameter DoQ2CorrInside05pct and related functionality. 2019-11-11 11:28:39 +01:00
Milan Hanajik 7a640621ac Bug fixes : (1) FlowMeterDewa, (2) ControlComWrap.ReferenceFreqs(int i), ver. 2.18.1360 2019-11-11 09:46:25 +01:00
Milan Hanajik 807daf2bcd ver. 2.18.1357 2019-10-29 13:37:16 +01:00
Milan Hanajik ede1773b4f ver. 2.18.1356 2019-10-28 15:45:35 +01:00
102 changed files with 9682 additions and 2262 deletions
+3 -2
View File
@@ -18,7 +18,7 @@
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>TRACE;DEBUG;MUNICH</DefineConstants>
<DefineConstants>TRACE;DEBUG;FUZHOU_300</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<AllowUnsafeBlocks>false</AllowUnsafeBlocks>
@@ -28,7 +28,7 @@
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE;MUNICH</DefineConstants>
<DefineConstants>TRACE;FUZHOU_300</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
@@ -125,6 +125,7 @@
<ItemGroup>
<EmbeddedResource Include="Resources\Strings.cs.resx" />
<EmbeddedResource Include="Resources\Strings.de.resx" />
<EmbeddedResource Include="Resources\Strings.fr.resx" />
<EmbeddedResource Include="Resources\Strings.it.resx" />
<EmbeddedResource Include="Resources\Strings.pl.resx" />
<EmbeddedResource Include="Resources\Strings.resx">
+1 -1
View File
@@ -62,7 +62,7 @@ namespace Config
public const int CompoundWMsCount = 1;
public const int HeatMetersCount = 0;
public const int MaxPartNr = 1;
#elif TORUN_50 || CEVAK_40 || MURES_40 || FUZHOU_50 || PETERSBURG_50 || KEMPNO_50 || BAHRAIN_50 || KRAKOW_50 || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50
#elif TORUN_50 || CEVAK_40 || MURES_40 || FUZHOU_50 || PETERSBURG_50 || KEMPNO_50 || BAHRAIN_50 || KRAKOW_50 || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || ALZIR_25
public const int WMsCount = 20;
public const int LineSize = 10;
public const int CompoundWMsCount = 1;
+48 -4
View File
@@ -90,6 +90,10 @@ namespace Config.Entities
[Description("Wasserzähler")] Single,
[Description("Verbundwasserzähler")] Combined,
[Description("Wärmezähler")] HeatMeter,
#elif LANG_FR
[Description("Compteurs eau")] Single,
[Description("Mètres composés")] Combined,
[Description("Thermomètres")] HeatMeter,
#elif LANG_CS
[Description("Vodoměry")] Single,
[Description("Kombinované vodoměry")] Combined,
@@ -125,6 +129,9 @@ namespace Config.Entities
#elif LANG_IT
[Description("freddo")] ColdWater,
[Description("caldo")] HotWater,
#elif LANG_FR
[Description("eau froide")] ColdWater,
[Description("eau chaude")] HotWater,
#else
[Description("cold")] ColdWater,
[Description("hot")] HotWater,
@@ -240,6 +247,11 @@ namespace Config.Entities
[Description("immer")] Always = 1,
[Description("Bildschirm")] OnScreen = 2,
[Description("intern")] Internal = 3,
#elif LANG_FR
[Description("jamais")] Never = 0,
[Description("toujours")] Always = 1,
[Description("À l'écran")] OnScreen = 2,
[Description("interne")] Internal = 3,
#elif LANG_CS
/// czech
[Description("nikdy")] Never = 0,
@@ -281,6 +293,10 @@ namespace Config.Entities
[Description("Waage")] Scale,
[Description("Spanne")] Spread,
[Description("Standardabw.")] StdDev,
#elif LANG_FR
[Description("Balance")] Scale,
[Description("Envergure")] Spread,
[Description("Déviation std.")] StdDev,
#elif LANG_CS
/// cesky
[Description("váhou")] Scale,
@@ -291,7 +307,7 @@ namespace Config.Entities
[Description("Spread")] Spread,
[Description("Std.dev.")] StdDev,
#endif
Count
Count
}
public enum TestRedType
@@ -345,6 +361,14 @@ namespace Config.Entities
[Description("Prüfpunktergebnisse")] TestResult,
[Description("Wasserzelledaten")] MeterData,
[Description("Wasserzelleergebnisse")] MeterResult,
#elif LANG_FR
[Description("Autres")] Other,
[Description("Données de banc")] BenchData,
[Description("Résultats du banc")] BenchResult,
[Description("Données de test")] TestData,
[Description("Résultats de test")] TestResult,
[Description("Données du compteur d'eau")] MeterData,
[Description("Résultats du compteur d'eau")] MeterResult,
#else
[Description("Other")] Other,
[Description("Bench data")] BenchData,
@@ -354,7 +378,7 @@ namespace Config.Entities
[Description("Meter data")] MeterData,
[Description("Meter result")] MeterResult,
#endif
Count,
Count,
}
/// <summary> Possible modes of operation of components and devices. </summary>
@@ -371,6 +395,17 @@ namespace Config.Entities
[Description("Reply")] Reply,
[Description("Simuliert")] Simulate, /// Test bench simulation, this mode does not require any hardware
[Description("Geerbt")] Inherit,
#elif LANG_FR
[Description("Détection automatique: Éteindre")] DetectedOff = -2,
[Description("Détection automatique: Allumé")] DetectedOn = -1,
[Description("Ordinaire")] Normal = 0,
[Description("Détection automatique")] AutoDetect,
[Description("Erreur d'exécution")] FailureDuringOperation,
[Description("Éteindre")] Off,
[Description("Record")] Record,
[Description("Répondre")] Reply,
[Description("Simuler")] Simulate,
[Description("Hériter")] Inherit,
#else
[Description("Detected off")] DetectedOff = -2,
[Description("Detected on")] DetectedOn = -1,
@@ -383,7 +418,7 @@ namespace Config.Entities
[Description("Simulate")] Simulate, /// Test bench simulation, this mode does not require any hardware
[Description("Inherit")] Inherit,
#endif
Count,
Count,
}
public enum LogLevel
@@ -430,6 +465,11 @@ namespace Config.Entities
[Description("zentriert")] Center,
[Description("rechts")] Right,
[Description("angepasst")] Justified,
#elif LANG_FR
[Description("gauche")] Left,
[Description("centré")] Center,
[Description("droit")] Right,
[Description("justifié")] Justified,
#else
[Description("Left")] Left,
[Description("Center")] Center,
@@ -479,6 +519,10 @@ namespace Config.Entities
[Description("aus")] Off,
[Description("info")] Info,
[Description("ein")] On,
#elif LANG_FR
[Description("éteindre")] Off,
[Description("info")] Info,
[Description("allumé")] On,
#elif LANG_CS
[Description("vypnuto")] Off,
[Description("info")] Info,
@@ -496,7 +540,7 @@ namespace Config.Entities
[Description("info")] Info,
[Description("on")] On,
#endif
Count
Count
}
+153
View File
@@ -0,0 +1,153 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="Administrator" xml:space="preserve">
<value>Administrateur</value>
</data>
<data name="Calibration_Specialist" xml:space="preserve">
<value>Spécialiste en calibration</value>
</data>
<data name="Head_of_Lab" xml:space="preserve">
<value>Chef de laboratoire</value>
</data>
<data name="Maintenance_Specialist" xml:space="preserve">
<value>Spécialiste en maintenance</value>
</data>
<data name="Metrologist" xml:space="preserve">
<value>Métrologue</value>
</data>
<data name="Tester" xml:space="preserve">
<value>Testeur</value>
</data>
<data name="Testing_Specialist" xml:space="preserve">
<value>Spécialiste d'essais</value>
</data>
<data name="Failed" xml:space="preserve">
<value>Échoué</value>
</data>
<data name="Passed" xml:space="preserve">
<value>Passé</value>
</data>
<data name="Cannot_open_DB_Cause_0" xml:space="preserve">
<value>Impossible d'ouvrir la base de données Cause\\r\\n{0}</value>
</data>
<data name="Error" xml:space="preserve">
<value>Erreur</value>
</data>
</root>
+3
View File
@@ -97,6 +97,7 @@ namespace Results.Entities
public virtual object CompleteTestInfos { get; set; } /// SensusTestInfo[] obtained as a best match at the beginning of the cycle, not mapped to DB !!!
#endif
public virtual int ProcessId { get; set; } /// Not mapped to DB !!! Tracing DB Process ID
public virtual int SessionId { get; set; } /// Not mapped to DB !!! 1 (regular tracing DB session) or 2 (alternative tracing DB session)
public virtual bool LastRecordIsNok { get; set; } /// Not mapped to DB !!! Previous record verification result
public virtual WaterMeterData WaterMeterData { get; set; }
@@ -359,6 +360,7 @@ namespace Results.Entities
CompleteTestInfos = null;
#endif
ProcessId = 0;
SessionId = 0;
ErrorFlags = 0;
LastRecordIsNok = false;
}
@@ -419,6 +421,7 @@ namespace Results.Entities
CompleteTestInfos = src.CompleteTestInfos;
#endif
ProcessId = src.ProcessId;
SessionId = src.SessionId;
LastRecordIsNok = src.LastRecordIsNok;
foreach (var mtr in MeterTestRslts)
@@ -4,8 +4,10 @@
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Drawing.Drawing2D;
using System.Drawing.Printing;
using System.IO;
using Gma.QrCodeNet.Encoding;
using Config.Entities;
using Results.Resources;
@@ -13,7 +15,9 @@ namespace Results.Output.Printers.Label
{
public class LabelPrintDocument : PrintersCommon
{
/// Size of the printed area without margins, after taking into account 'pageOrientation'
static QrEncoder encoder = new QrEncoder();
/// Size of the printed area without margins, after taking into account 'pageOrientation'
readonly int printHeight;
readonly int printWidth;
@@ -93,6 +97,44 @@ namespace Results.Output.Printers.Label
e.Graphics.DrawString(item.Print(wm), this.font, Brushes.Black, printArea);
}
}
if (cfg.DrawSNasBarcode)
{
if (cfg.IsQR)
{
QrCode qrCode = encoder.Encode(wm.SerialNr);
DrawQR(e.Graphics, qrCode, cfg.BarcodeLeft, cfg.BarcodeTop, cfg.BarcodeWidth, cfg.BarcodeHeight);
}
else
{
/// TODO
}
}
}
public static void DrawQR(Graphics g, QrCode qrCode, float left, float top, float width, float height)
{
/// Assuming 100 dpi (printer)
g.SmoothingMode = SmoothingMode.AntiAlias;
g.InterpolationMode = InterpolationMode.HighQualityBicubic;
g.PixelOffsetMode = PixelOffsetMode.HighQuality;
float qrPixWidth = width / qrCode.Matrix.Width;
float qrPixHeight = height / qrCode.Matrix.Height;
for (int i = 0; i < qrCode.Matrix.Height; i++)
{
for (int j = 0; j < qrCode.Matrix.Width; j++)
{
if (qrCode.Matrix[j, i])
{
g.FillRectangle(Brushes.Black, new RectangleF(left + j * qrPixWidth,
top + i * qrPixHeight,
qrPixWidth,
qrPixHeight));
}
}
}
}
}
}
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2018 Sensus Slovensko a.s.
/// Copyright (c) 2018-2020 Sensus Slovensko a.s.
///
namespace Results.Output.Printers.Label
@@ -17,5 +17,11 @@ namespace Results.Output.Printers.Label
public System.Globalization.CultureInfo CultureInfo;
public bool GoodOnly;
public bool SupressPrinting; /// true = Bypass printing
}
public bool DrawSNasBarcode;
public bool IsQR;
public int BarcodeLeft;
public int BarcodeTop;
public int BarcodeWidth;
public int BarcodeHeight;
}
}
+807
View File
@@ -0,0 +1,807 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="Add" xml:space="preserve">
<value>Ajouter &gt;</value>
</data>
<data name="Alignment" xml:space="preserve">
<value>Alignement</value>
</data>
<data name="Approval" xml:space="preserve">
<value>Approbation</value>
</data>
<data name="Available_results" xml:space="preserve">
<value>Résultats disponibles</value>
</data>
<data name="Batch_nr" xml:space="preserve">
<value>Numéro de lot</value>
</data>
<data name="Bench" xml:space="preserve">
<value>Banc</value>
</data>
<data name="CancelBtnText" xml:space="preserve">
<value>Annuler</value>
</data>
<data name="Caption" xml:space="preserve">
<value>Légende</value>
</data>
<data name="Configuration" xml:space="preserve">
<value>Configuration</value>
</data>
<data name="Density" xml:space="preserve">
<value>Densité</value>
</data>
<data name="DownBtnText" xml:space="preserve">
<value>Vers le bas</value>
</data>
<data name="End" xml:space="preserve">
<value>Fin</value>
</data>
<data name="EndState_aux" xml:space="preserve">
<value>État final aux</value>
</data>
<data name="EndState_main" xml:space="preserve">
<value>État final principal</value>
</data>
<data name="End_state" xml:space="preserve">
<value>État final</value>
</data>
<data name="ErrLimHi" xml:space="preserve">
<value>Err LimHi</value>
</data>
<data name="ErrLimLo" xml:space="preserve">
<value>Err LimLo</value>
</data>
<data name="Error" xml:space="preserve">
<value>Erreur</value>
</data>
<data name="ErrRef" xml:space="preserve">
<value>Err Ref</value>
</data>
<data name="Err_aux" xml:space="preserve">
<value>Err aux</value>
</data>
<data name="Err_main" xml:space="preserve">
<value>Err principale</value>
</data>
<data name="Flow" xml:space="preserve">
<value>Couler</value>
</data>
<data name="Format" xml:space="preserve">
<value>Format</value>
</data>
<data name="H_amb" xml:space="preserve">
<value>Hamb</value>
</data>
<data name="Item" xml:space="preserve">
<value>Article</value>
</data>
<data name="MClass" xml:space="preserve">
<value>MClass</value>
</data>
<data name="OkBtnText" xml:space="preserve">
<value>Oui</value>
</data>
<data name="PO" xml:space="preserve">
<value>Commande</value>
</data>
<data name="Pos" xml:space="preserve">
<value>Pos.</value>
</data>
<data name="Precision" xml:space="preserve">
<value>Précision</value>
</data>
<data name="Procedure" xml:space="preserve">
<value>Procédure</value>
</data>
<data name="Producer" xml:space="preserve">
<value>Producteur</value>
</data>
<data name="Protocol" xml:space="preserve">
<value>Protocole</value>
</data>
<data name="Pulses" xml:space="preserve">
<value>Impulsion</value>
</data>
<data name="PulsesLiter" xml:space="preserve">
<value>Impulsion/litre</value>
</data>
<data name="P_amb" xml:space="preserve">
<value>P amb</value>
</data>
<data name="P_dn_end" xml:space="preserve">
<value>P dn fin</value>
</data>
<data name="P_dn" xml:space="preserve">
<value>P dn</value>
</data>
<data name="P_dn_start" xml:space="preserve">
<value>P dn début</value>
</data>
<data name="P_up_end" xml:space="preserve">
<value>P up fin</value>
</data>
<data name="P_up" xml:space="preserve">
<value>P up</value>
</data>
<data name="P_up_start" xml:space="preserve">
<value>P up début</value>
</data>
<data name="Q_fall" xml:space="preserve">
<value>Q tomber</value>
</data>
<data name="Q_from" xml:space="preserve">
<value>Q de</value>
</data>
<data name="Q_rise" xml:space="preserve">
<value>Q monter</value>
</data>
<data name="Q_to" xml:space="preserve">
<value>Q à</value>
</data>
<data name="RefPulses" xml:space="preserve">
<value>Ref Puls</value>
</data>
<data name="Remove" xml:space="preserve">
<value>&lt; Retirer</value>
</data>
<data name="Remove_all" xml:space="preserve">
<value>Enlever tout</value>
</data>
<data name="Result" xml:space="preserve">
<value>Résultat</value>
</data>
<data name="Selected_results" xml:space="preserve">
<value>Résultats sélectionnés</value>
</data>
<data name="sn" xml:space="preserve">
<value>s/n</value>
</data>
<data name="sn_aux" xml:space="preserve">
<value>s/n aux</value>
</data>
<data name="sn_main" xml:space="preserve">
<value>s/n principale</value>
</data>
<data name="Start" xml:space="preserve">
<value>Début</value>
</data>
<data name="Test" xml:space="preserve">
<value>Test</value>
</data>
<data name="Test_ID" xml:space="preserve">
<value>Test ID</value>
</data>
<data name="Test_method" xml:space="preserve">
<value>Méthode d'essai</value>
</data>
<data name="Test_vol" xml:space="preserve">
<value>Test vol</value>
</data>
<data name="T_amb" xml:space="preserve">
<value>T amb</value>
</data>
<data name="T_div" xml:space="preserve">
<value>T div</value>
</data>
<data name="T_end" xml:space="preserve">
<value>T fin</value>
</data>
<data name="T_in" xml:space="preserve">
<value>T dans</value>
</data>
<data name="T_out" xml:space="preserve">
<value>T en dehors</value>
</data>
<data name="T_s" xml:space="preserve">
<value>T [s]</value>
</data>
<data name="T_start" xml:space="preserve">
<value>T début</value>
</data>
<data name="Uncertainty" xml:space="preserve">
<value>Incertitude</value>
</data>
<data name="Units" xml:space="preserve">
<value>Unités</value>
</data>
<data name="UpBtnText" xml:space="preserve">
<value>En haut</value>
</data>
<data name="User" xml:space="preserve">
<value>Utilisateur</value>
</data>
<data name="User_nr" xml:space="preserve">
<value>N° Utilisateur</value>
</data>
<data name="Ver" xml:space="preserve">
<value>Ver.</value>
</data>
<data name="VolRef" xml:space="preserve">
<value>Vol ref.</value>
</data>
<data name="Volume" xml:space="preserve">
<value>Le volume</value>
</data>
<data name="Width" xml:space="preserve">
<value>Largeur</value>
</data>
<data name="WMs" xml:space="preserve">
<value>CEs</value>
</data>
<data name="WM_Type" xml:space="preserve">
<value>CE Type</value>
</data>
<data name="Year" xml:space="preserve">
<value>Année</value>
</data>
<data name="Results" xml:space="preserve">
<value>Résultats</value>
</data>
<data name="Remark" xml:space="preserve">
<value>Remarque</value>
</data>
<data name="Result_code" xml:space="preserve">
<value>Code de résultat</value>
</data>
<data name="Mounting" xml:space="preserve">
<value>Montage</value>
</data>
<data name="Energy" xml:space="preserve">
<value>Énergie</value>
</data>
<data name="Energy_ref" xml:space="preserve">
<value>Énergie ref</value>
</data>
<data name="P_delta" xml:space="preserve">
<value>P delta</value>
</data>
<data name="P_delta_end" xml:space="preserve">
<value>P delta fin</value>
</data>
<data name="P_delta_mean" xml:space="preserve">
<value>P delta moyenne</value>
</data>
<data name="P_delta_start" xml:space="preserve">
<value>P delta début</value>
</data>
<data name="Meter_type" xml:space="preserve">
<value>Type de compteur</value>
</data>
<data name="Compound" xml:space="preserve">
<value>Composé</value>
</data>
<data name="Heat_meter" xml:space="preserve">
<value>Thermomètre</value>
</data>
<data name="Single" xml:space="preserve">
<value>Unique</value>
</data>
<data name="Page" xml:space="preserve">
<value>Page</value>
</data>
<data name="End_volume" xml:space="preserve">
<value>Volume fin</value>
</data>
<data name="Start_volume" xml:space="preserve">
<value>Volume début</value>
</data>
<data name="End_volume_aux" xml:space="preserve">
<value>Fin volume aux</value>
</data>
<data name="End_volume_main" xml:space="preserve">
<value>Fin volume principale</value>
</data>
<data name="Start_volume_aux" xml:space="preserve">
<value>Début volume aux</value>
</data>
<data name="Start_volume_main" xml:space="preserve">
<value>Début volume principale</value>
</data>
<data name="Volume_aux" xml:space="preserve">
<value>Volume aux</value>
</data>
<data name="Volume_main" xml:space="preserve">
<value>Volume principale</value>
</data>
<data name="End_mass" xml:space="preserve">
<value>Fin masse</value>
</data>
<data name="Start_mass" xml:space="preserve">
<value>Début masse</value>
</data>
<data name="Category" xml:space="preserve">
<value>Catégorie</value>
</data>
<data name="Quantity" xml:space="preserve">
<value>Quantité</value>
</data>
<data name="Water_Meter" xml:space="preserve">
<value>Compteur d'eau</value>
</data>
<data name="VName_Flow" xml:space="preserve">
<value>Q</value>
</data>
<data name="VName_Press" xml:space="preserve">
<value>Press.</value>
</data>
<data name="VName_Temp" xml:space="preserve">
<value>Temp.</value>
</data>
<data name="VName_Dens" xml:space="preserve">
<value>Ro</value>
</data>
<data name="VName_Humi" xml:space="preserve">
<value>Hu.</value>
</data>
<data name="VName_Mass" xml:space="preserve">
<value>Masse</value>
</data>
<data name="VName_TstTime" xml:space="preserve">
<value>Tau</value>
</data>
<data name="VName_Vol" xml:space="preserve">
<value>Vol.</value>
</data>
<data name="Tooltip_P_de_ac" xml:space="preserve">
<value>Différence de pression mesurée par delta P mètre - réelle</value>
</data>
<data name="Tooltip_P_de_avg" xml:space="preserve">
<value>Différence de pression mesurée par delta P mètre - moyenne</value>
</data>
<data name="Tooltip_P_de_en" xml:space="preserve">
<value>Différence de pression mesurée par delta P mètre - à la fin de l'essai</value>
</data>
<data name="Tooltip_P_de_me" xml:space="preserve">
<value>Différence de pression mesurée par delta P mètre - moyenne</value>
</data>
<data name="Tooltip_P_de_st" xml:space="preserve">
<value>Différence de pression mesurée par delta P mètre - au début de l'essai</value>
</data>
<data name="Tooltip_P_dw_ac" xml:space="preserve">
<value>Pression à la sortie réelle</value>
</data>
<data name="Tooltip_P_dw_avg" xml:space="preserve">
<value>Pression moyenne à la sortie</value>
</data>
<data name="Tooltip_P_dw_en" xml:space="preserve">
<value>Pression à la sortie à la fin du test</value>
</data>
<data name="Tooltip_P_dw_me" xml:space="preserve">
<value>Pression moyenne à la sortie</value>
</data>
<data name="Tooltip_P_dw_st" xml:space="preserve">
<value>Pression à la sortie au début du test</value>
</data>
<data name="Tooltip_P_up_ac" xml:space="preserve">
<value>Pression à l'entrée réelle</value>
</data>
<data name="Tooltip_P_up_avg" xml:space="preserve">
<value>Pression moyenne à l'entrée</value>
</data>
<data name="Tooltip_P_up_en" xml:space="preserve">
<value>Pression à l'entrée à la fin de l'essai</value>
</data>
<data name="Tooltip_P_up_me" xml:space="preserve">
<value>Pression moyenne à l'entrée</value>
</data>
<data name="Tooltip_P_up_st" xml:space="preserve">
<value>Pression à l'entrée au début de l'essai</value>
</data>
<data name="Tooltip_Q_m_r" xml:space="preserve">
<value>Débit calculé à partir de la masse vraie et du temps conventionnels</value>
</data>
<data name="Tooltip_Q_riac" xml:space="preserve">
<value>Débit obtenu à partir du compteur principal - réel</value>
</data>
<data name="Tooltip_Q_rim" xml:space="preserve">
<value>Débit obtenu à partir du compteur principal - moyenne</value>
</data>
<data name="Tooltip_Q_v_r" xml:space="preserve">
<value>Débit mesuré par le débitmètre de référence</value>
</data>
<data name="Tooltip_T_di_ac" xml:space="preserve">
<value>Température réelle au déviateur</value>
</data>
<data name="Tooltip_T_di_avg" xml:space="preserve">
<value>Température moyenne au déviateur</value>
</data>
<data name="Tooltip_T_di_en" xml:space="preserve">
<value>Température au déviateur à la fin du test - 4 dernières mesures avant la fin</value>
</data>
<data name="Tooltip_T_di_me" xml:space="preserve">
<value>Température moyenne au déviateur</value>
</data>
<data name="Tooltip_T_di_st" xml:space="preserve">
<value>Température au déviateur au début du test - 4 premières mesures après le début</value>
</data>
<data name="Tooltip_T_dw_ac" xml:space="preserve">
<value>Température réelle à la sortie</value>
</data>
<data name="Tooltip_T_dw_avg" xml:space="preserve">
<value>Température moyenne à la sortie</value>
</data>
<data name="Tooltip_T_dw_en" xml:space="preserve">
<value>Température à la sortie à la fin du test - 4 dernières mesures avant la fin</value>
</data>
<data name="Tooltip_T_dw_me" xml:space="preserve">
<value>Température moyenne à la sortie</value>
</data>
<data name="Tooltip_T_dw_st" xml:space="preserve">
<value>Température à la sortie au début du test - 4 premières mesures après le début</value>
</data>
<data name="Tooltip_T_up_ac" xml:space="preserve">
<value>Température réelle à l'entrée</value>
</data>
<data name="Tooltip_T_up_avg" xml:space="preserve">
<value>Température moyenne à l'entrée lors d'un test</value>
</data>
<data name="Tooltip_T_up_en" xml:space="preserve">
<value>Température à l'entrée à la fin de l'essai - 4 dernières mesures avant la fin</value>
</data>
<data name="Tooltip_T_up_me" xml:space="preserve">
<value>Température moyenne à l'entrée lors d'un test</value>
</data>
<data name="Tooltip_T_up_st" xml:space="preserve">
<value>Température d'entrée au début du test - 4 premières mesures après le début</value>
</data>
<data name="aux" xml:space="preserve">
<value>aux.</value>
</data>
<data name="main" xml:space="preserve">
<value>principale</value>
</data>
<data name="Tooltip_E_rel" xml:space="preserve">
<value>Erreur relative d'un compteur</value>
</data>
<data name="Tooltip_E_rel_ref" xml:space="preserve">
<value>Erreur relative du compteur maître</value>
</data>
<data name="Tooltip_sn" xml:space="preserve">
<value>Numéro de série du compteur</value>
</data>
<data name="Tooltip_sn_aux" xml:space="preserve">
<value>Numéro de série du compteur auxiliaire d'un compteur d'eau composé</value>
</data>
<data name="Tooltip_sn_main" xml:space="preserve">
<value>Numéro de série du compteur principal d'un compteur d'eau composé</value>
</data>
<data name="Tooltip_Vol_Mt" xml:space="preserve">
<value>Volume mesuré par le compteur testé</value>
</data>
<data name="Tooltip_Vol_rm" xml:space="preserve">
<value>Volume de référence pour compteur testé</value>
</data>
<data name="VName_Error" xml:space="preserve">
<value>E</value>
</data>
<data name="fall" xml:space="preserve">
<value>tomber</value>
</data>
<data name="from" xml:space="preserve">
<value>de</value>
</data>
<data name="rise" xml:space="preserve">
<value>monter</value>
</data>
<data name="to" xml:space="preserve">
<value>à</value>
</data>
<data name="Tooltip_Hu_Amb_M" xml:space="preserve">
<value>Humidité ambiante pendant le test</value>
</data>
<data name="Tooltip_P_Amb_M" xml:space="preserve">
<value>Pression ambiante pendant le test</value>
</data>
<data name="Tooltip_T_Amb_M" xml:space="preserve">
<value>Température ambiante pendant le test</value>
</data>
<data name="Test_done" xml:space="preserve">
<value>Test fait</value>
</data>
<data name="Test_passed" xml:space="preserve">
<value>Test réussi</value>
</data>
<data name="No" xml:space="preserve">
<value>Non</value>
</data>
<data name="Yes" xml:space="preserve">
<value>Oui</value>
</data>
<data name="Density_correction" xml:space="preserve">
<value>Correction densité</value>
</data>
<data name="Error_flags" xml:space="preserve">
<value>Drapeaux erreur</value>
</data>
<data name="Legalizator" xml:space="preserve">
<value>Légalisateur</value>
</data>
<data name="User_description" xml:space="preserve">
<value>Description utilisateur</value>
</data>
<data name="Failed_meters_count" xml:space="preserve">
<value>Compteur échoué</value>
</data>
<data name="Passed_meters_count" xml:space="preserve">
<value>Mètres passés</value>
</data>
<data name="sensitivity" xml:space="preserve">
<value>sensibilité</value>
</data>
<data name="Tooltip_Q_end" xml:space="preserve">
<value>Débit obtenu à partir du compteur principal - fin</value>
</data>
<data name="Tooltip_Q_max" xml:space="preserve">
<value>Débit obtenu à partir du compteur principal - max.</value>
</data>
<data name="Tooltip_Q_min" xml:space="preserve">
<value>Débit obtenu à partir du compteur principal - min</value>
</data>
<data name="Tooltip_Q_start" xml:space="preserve">
<value>Débit obtenu à partir du compteur principal - départ</value>
</data>
<data name="Tooltip_P_dw_max" xml:space="preserve">
<value>Pression maximale à la sortie pendant le test</value>
</data>
<data name="Tooltip_P_dw_min" xml:space="preserve">
<value>Pression minimale à la sortie pendant le test</value>
</data>
<data name="Tooltip_P_up_max" xml:space="preserve">
<value>Pression maximale à l'entrée pendant l'essai</value>
</data>
<data name="Tooltip_P_up_min" xml:space="preserve">
<value>Pression minimale à l'entrée lors de l'essai</value>
</data>
<data name="Tooltip_T_di_max" xml:space="preserve">
<value>Température maximale au déviateur pendant le test</value>
</data>
<data name="Tooltip_T_di_min" xml:space="preserve">
<value>Température minimale au déviateur pendant le test</value>
</data>
<data name="Tooltip_T_dw_max" xml:space="preserve">
<value>Température maximale à la sortie pendant le test</value>
</data>
<data name="Tooltip_T_dw_min" xml:space="preserve">
<value>Température minimale à la sortie pendant le test</value>
</data>
<data name="Tooltip_T_up_max" xml:space="preserve">
<value>Température maximale à l'entrée pendant le test</value>
</data>
<data name="Tooltip_T_up_min" xml:space="preserve">
<value>Température minimale à l'entrée pendant l'essai</value>
</data>
<data name="Tooltip_P_de_max" xml:space="preserve">
<value>Différence de pression mesurée par delta P mètre - maximum pendant le test</value>
</data>
<data name="Tooltip_P_de_min" xml:space="preserve">
<value>Différence de pression mesurée par delta P mètre - minimum pendant l'essai</value>
</data>
<data name="Tooltip_Rho_Wa_calc" xml:space="preserve">
<value>Densité calculée de l'eau à partir d'une table ou d'une formule à la température d'étalonnage de la densité de l'eau (r)</value>
</data>
<data name="Tooltip_T_rho_0" xml:space="preserve">
<value>Température de l'échantillon d'eau lors de l'étalonnage de la densité de l'eau</value>
</data>
<data name="Tooltip_T_ln_ac" xml:space="preserve">
<value>Température réelle dans la ligne</value>
</data>
<data name="Tooltip_T_ln_avg" xml:space="preserve">
<value>Température moyenne dans la ligne pendant un test</value>
</data>
<data name="Tooltip_T_ln_en" xml:space="preserve">
<value>Température dans la ligne à la fin du test - 4 dernières mesures avant la fin</value>
</data>
<data name="Tooltip_T_ln_max" xml:space="preserve">
<value>Température maximale dans la ligne pendant le test</value>
</data>
<data name="Tooltip_T_ln_me" xml:space="preserve">
<value>Température moyenne dans la ligne pendant un test</value>
</data>
<data name="Tooltip_T_ln_min" xml:space="preserve">
<value>Température minimale dans la ligne pendant le test</value>
</data>
<data name="Tooltip_T_ln_st" xml:space="preserve">
<value>Température dans la ligne au début du test - 4 premières mesures après le début</value>
</data>
<data name="Unit" xml:space="preserve">
<value>Unité</value>
</data>
<data name="Procedure_description" xml:space="preserve">
<value>Description procédure</value>
</data>
<data name="Bench_ID" xml:space="preserve">
<value>ID banc</value>
</data>
<data name="Bench_name" xml:space="preserve">
<value>Nom banc</value>
</data>
<data name="Address" xml:space="preserve">
<value>Adresse</value>
</data>
<data name="Tooltip_E_rel_last" xml:space="preserve">
<value>Erreur relative d'un compteur dans un test précédent / en production</value>
</data>
<data name="Batch" xml:space="preserve">
<value>Lot</value>
</data>
<data name="repetition" xml:space="preserve">
<value>répétition</value>
</data>
<data name="Invalid_Q2_correction_factors" xml:space="preserve">
<value>Facteurs correction Q2 non valides</value>
</data>
<data name="Previous_step_is_missing_or_NOK" xml:space="preserve">
<value>L'étape précédente est manquante ou NOK</value>
</data>
<data name="Test_repetition_count_exceeded_upper_limit" xml:space="preserve">
<value>nombre répétitions test dépasse limite supérieure</value>
</data>
<data name="Wrong_iPerl_counting_direction" xml:space="preserve">
<value>Mauvais sens comptage iPerl</value>
</data>
<data name="Failed" xml:space="preserve">
<value>Échoué</value>
</data>
<data name="Passed" xml:space="preserve">
<value>Passé</value>
</data>
<data name="Test_in_progress" xml:space="preserve">
<value>Test en cours</value>
</data>
<data name="Counter_0" xml:space="preserve">
<value>Compteur {0}</value>
</data>
<data name="Date_and_time" xml:space="preserve">
<value>Date et heure</value>
</data>
<data name="Name" xml:space="preserve">
<value>Prénom</value>
</data>
<data name="Step" xml:space="preserve">
<value>Étape</value>
</data>
<data name="Workplace" xml:space="preserve">
<value>Lieu travail</value>
</data>
<data name="Workflow" xml:space="preserve">
<value>Flux travail</value>
</data>
<data name="Production_tracing_results" xml:space="preserve">
<value>Résultats production</value>
</data>
<data name="Code" xml:space="preserve">
<value>Code</value>
</data>
<data name="Part" xml:space="preserve">
<value>Partie</value>
</data>
<data name="All_results" xml:space="preserve">
<value>Tous résultats</value>
</data>
<data name="Graphs" xml:space="preserve">
<value>Graphiques</value>
</data>
<data name="No_water_meter" xml:space="preserve">
<value>Pas de compteur</value>
</data>
<data name="Serial_number_is_missing" xml:space="preserve">
<value>Numérotation en série</value>
</data>
</root>
+6 -2
View File
@@ -18,7 +18,7 @@
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>TRACE;DEBUG;MUNICH</DefineConstants>
<DefineConstants>TRACE;DEBUG;FUZHOU_300</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<PlatformTarget>x86</PlatformTarget>
@@ -27,7 +27,7 @@
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE;MUNICH</DefineConstants>
<DefineConstants>TRACE;FUZHOU_300</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
@@ -35,6 +35,9 @@
<Reference Include="FluentNHibernate">
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
</Reference>
<Reference Include="Gma.QrCodeNet.Encoding">
<HintPath>..\packages\QrCode.Net.0.4.0.0\net40\Gma.QrCodeNet.Encoding.dll</HintPath>
</Reference>
<Reference Include="Iesi.Collections">
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
</Reference>
@@ -217,6 +220,7 @@
<EmbeddedResource Include="Resources\Strings.de.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="Resources\Strings.fr.resx" />
<EmbeddedResource Include="Resources\Strings.it.resx" />
<EmbeddedResource Include="Resources\Strings.pl.resx" />
<EmbeddedResource Include="Resources\Strings.resx">
+6 -6
View File
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2018 Sensus Slovensko a.s.
/// Copyright (c) 2018-2020 Sensus Slovensko a.s.
///
using System;
using System.IO;
@@ -116,11 +116,11 @@ namespace ResultsBrowser
Bench4 = "WR14";
Bench5 = "WR15";
Bench6 = "PT7";
ConnectionString1 = "SERVER=10.42.128.93; DATABASE=st-wr10-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
ConnectionString2 = "SERVER=10.42.128.102; DATABASE=st-wr11-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
ConnectionString3 = "SERVER=10.42.128.89; DATABASE=st-wr13-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
ConnectionString4 = "SERVER=10.42.128.213; DATABASE=st-wr14-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
ConnectionString5 = "SERVER=10.42.128.214; DATABASE=st-wr15-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
ConnectionString1 = "SERVER=10.42.130.69; DATABASE=st-wr10-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
ConnectionString2 = "SERVER=10.42.129.27; DATABASE=st-wr11-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
ConnectionString3 = "SERVER=10.42.128.61; DATABASE=st-wr13-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
ConnectionString4 = "SERVER=10.42.130.72; DATABASE=st-wr14-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
ConnectionString5 = "SERVER=10.42.130.71; DATABASE=st-wr15-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
ConnectionString6 = "SERVER=10.42.129.26; DATABASE=iperlspecial-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;";
Language = "SK";
#endif
+30
View File
@@ -0,0 +1,30 @@
using System;
namespace ResultsBrowser
{
public class OraData
{
public string PO;
public string PcbNr;
public int TestBenchId;
public int MaxPruefIx;
public int SN;
public int TestId;
public int WMPosition;
public int HydrPruefung;
public double AdjErr;
public double AdjErrA4;
public double Q3RlErr;
public double Q3LrErr;
public double Q2RlErr;
public double Q2LrErr;
public double Q1RlErr;
public double Q1LrErr;
public int CalibFactor;
public int CalibFactorLNA;
public int Q2CorrectionRl;
public int Q2CorrectionLr;
public OraData() { }
}
}
+3 -3
View File
@@ -10,7 +10,7 @@ using System.Runtime.InteropServices;
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Sensus")]
[assembly: AssemblyProduct("ResultsBrowser")]
[assembly: AssemblyCopyright("Copyright © 2015 - 2018 Sensus Slovensko a.s.")]
[assembly: AssemblyCopyright("Copyright © 2015 - 2020 Sensus Slovensko a.s.")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
@@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2.18.1273.0")]
[assembly: AssemblyFileVersion("2.18.1273.0")]
[assembly: AssemblyVersion("2.18.1413.0")]
[assembly: AssemblyFileVersion("2.18.1413.0")]
+306
View File
@@ -0,0 +1,306 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="Error" xml:space="preserve">
<value>Erreur</value>
</data>
<data name="Test_bench" xml:space="preserve">
<value>Banc essai</value>
</data>
<data name="Name" xml:space="preserve">
<value>Prénom</value>
</data>
<data name="CancelBtnText" xml:space="preserve">
<value>Annuler</value>
</data>
<data name="OkBtnText" xml:space="preserve">
<value>Ok</value>
</data>
<data name="ConfigureDatabaseText" xml:space="preserve">
<value>Configurer les bancs d'essai (mot de passe requis)</value>
</data>
<data name="ExitBtnText" xml:space="preserve">
<value>Quitter </value>
</data>
<data name="Procedure" xml:space="preserve">
<value>Procédure</value>
</data>
<data name="Test" xml:space="preserve">
<value>Tester</value>
</data>
<data name="Component" xml:space="preserve">
<value>Composant</value>
</data>
<data name="Configure" xml:space="preserve">
<value>Configurer</value>
</data>
<data name="Printer" xml:space="preserve">
<value>Imprimante</value>
</data>
<data name="Question" xml:space="preserve">
<value>Question</value>
</data>
<data name="Connection_string" xml:space="preserve">
<value>Chaîne connexion</value>
</data>
<data name="Add" xml:space="preserve">
<value>&amp;Ajouter &gt;</value>
</data>
<data name="Message" xml:space="preserve">
<value>Message</value>
</data>
<data name="Data" xml:space="preserve">
<value>Données</value>
</data>
<data name="Protocol" xml:space="preserve">
<value>Protocole</value>
</data>
<data name="Serial_Number" xml:space="preserve">
<value>Numéro série</value>
</data>
<data name="Language" xml:space="preserve">
<value>Langue</value>
</data>
<data name="Add_filter" xml:space="preserve">
<value>Ajouter filtre</value>
</data>
<data name="Clear_filters" xml:space="preserve">
<value>Effacer filtres</value>
</data>
<data name="Execute_query" xml:space="preserve">
<value>Exécuter ordre</value>
</data>
<data name="Export_query_results" xml:space="preserve">
<value>Résultats exportation</value>
</data>
<data name="Filters" xml:space="preserve">
<value>Filtres</value>
</data>
<data name="Format_of_results" xml:space="preserve">
<value>Configurer la sortie</value>
</data>
<data name="Load_filters" xml:space="preserve">
<value>charge filters</value>
</data>
<data name="Print_query_results" xml:space="preserve">
<value>Résultats impression</value>
</data>
<data name="Query_results" xml:space="preserve">
<value>Résultats requête</value>
</data>
<data name="Results_Browser" xml:space="preserve">
<value>Résultats Browser</value>
</data>
<data name="Save_filters" xml:space="preserve">
<value>Enregistrer filtres</value>
</data>
<data name="Settings" xml:space="preserve">
<value>Réglages</value>
</data>
<data name="Test_benches" xml:space="preserve">
<value>Bancs essai</value>
</data>
<data name="RetryDatabaseText" xml:space="preserve">
<value>Recommencez</value>
</data>
<data name="Date" xml:space="preserve">
<value>Date</value>
</data>
<data name="From" xml:space="preserve">
<value>De</value>
</data>
<data name="To" xml:space="preserve">
<value>À</value>
</data>
<data name="Statistics" xml:space="preserve">
<value>Statistiques</value>
</data>
<data name="Columns" xml:space="preserve">
<value>colonnes</value>
</data>
<data name="Rows" xml:space="preserve">
<value>Lignes</value>
</data>
<data name="Select_a_filter" xml:space="preserve">
<value>Sélectionnez filtre</value>
</data>
<data name="Error_displaying_results" xml:space="preserve">
<value>Erreur affichage résultats</value>
</data>
<data name="All_files" xml:space="preserve">
<value>Tous fichiers</value>
</data>
<data name="Error_saving_file" xml:space="preserve">
<value>Fichier sauvegarde erreurs</value>
</data>
<data name="Error_serializing_filters" xml:space="preserve">
<value>Erreurs sérialisation filtres</value>
</data>
<data name="Query_files" xml:space="preserve">
<value>Fichiers requête</value>
</data>
<data name="No_program_settings_found" xml:space="preserve">
<value>Aucun paramètre programme trouvé</value>
</data>
<data name="Using_default_settings" xml:space="preserve">
<value>Utilisation valeurs par défaut</value>
</data>
<data name="Selected_language_not_supported" xml:space="preserve">
<value>Langue sélectionnée non prise en charge</value>
</data>
<data name="Using_English" xml:space="preserve">
<value>Utilisation anglais</value>
</data>
<data name="Warning" xml:space="preserve">
<value>Attention</value>
</data>
<data name="Count" xml:space="preserve">
<value>Compter</value>
</data>
<data name="Format" xml:space="preserve">
<value>Format</value>
</data>
<data name="Page_orientation" xml:space="preserve">
<value>Page orientation</value>
</data>
<data name="Yes_Portrait_No_Landscape" xml:space="preserve">
<value>Oui portrait non paysage</value>
</data>
<data name="Print" xml:space="preserve">
<value>Impression</value>
</data>
<data name="Configure_printer" xml:space="preserve">
<value>Configurer impréssion</value>
</data>
<data name="No_printer_defined" xml:space="preserve">
<value>Aucune imprimante définie</value>
</data>
<data name="Printing_failed" xml:space="preserve">
<value>Impression échouée</value>
</data>
<data name="Printing_completed" xml:space="preserve">
<value>Impression terminée</value>
</data>
<data name="Error_exporting_results" xml:space="preserve">
<value>Erreur exportation résultats</value>
</data>
<data name="Histograms" xml:space="preserve">
<value>histogrammes</value>
</data>
</root>
+4 -2
View File
@@ -21,7 +21,7 @@
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>TRACE;DEBUG;MUNICH</DefineConstants>
<DefineConstants>TRACE;DEBUG;FUZHOU_300</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<AllowUnsafeBlocks>false</AllowUnsafeBlocks>
@@ -31,7 +31,7 @@
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE;MUNICH</DefineConstants>
<DefineConstants>TRACE;FUZHOU_300</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
@@ -177,6 +177,7 @@
<DependentUpon>StatisticsOptionsDlg.cs</DependentUpon>
</Compile>
<Compile Include="LocalSettings.cs" />
<Compile Include="OraData.cs" />
<Compile Include="Output\Printers\Statistics\StatisticsPrintDocument.cs">
<SubType>Component</SubType>
</Compile>
@@ -254,6 +255,7 @@
</Compile>
<EmbeddedResource Include="Resources\Strings.cs.resx" />
<EmbeddedResource Include="Resources\Strings.de.resx" />
<EmbeddedResource Include="Resources\Strings.fr.resx" />
<EmbeddedResource Include="Resources\Strings.it.resx" />
<EmbeddedResource Include="Resources\Strings.pl.resx">
<SubType>Designer</SubType>
+13
View File
@@ -34,6 +34,7 @@
this.filtersFlowLayoutPanel = new System.Windows.Forms.FlowLayoutPanel();
this.resultsGroupBox = new System.Windows.Forms.GroupBox();
this.resultsListView = new System.Windows.Forms.ListView();
this.customQueryButton = new System.Windows.Forms.Button();
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.histogramBtn = new System.Windows.Forms.Button();
this.statisticsBtn = new System.Windows.Forms.Button();
@@ -84,6 +85,7 @@
//
// vSplitContainer.Panel2
//
this.vSplitContainer.Panel2.Controls.Add(this.customQueryButton);
this.vSplitContainer.Panel2.Controls.Add(this.groupBox1);
this.vSplitContainer.Panel2.Controls.Add(this.outputGroupBox);
this.vSplitContainer.Panel2.Controls.Add(this.printerConfigBtn);
@@ -158,6 +160,16 @@
this.resultsListView.UseCompatibleStateImageBehavior = false;
this.resultsListView.View = System.Windows.Forms.View.Details;
//
// customQueryButton
//
this.customQueryButton.Location = new System.Drawing.Point(31, 437);
this.customQueryButton.Name = "customQueryButton";
this.customQueryButton.Size = new System.Drawing.Size(85, 23);
this.customQueryButton.TabIndex = 14;
this.customQueryButton.Text = "Custom query";
this.customQueryButton.UseVisualStyleBackColor = true;
this.customQueryButton.Click += new System.EventHandler(this.customQueryButton_Click);
//
// groupBox1
//
this.groupBox1.Controls.Add(this.histogramBtn);
@@ -443,5 +455,6 @@
private System.Windows.Forms.GroupBox groupBox1;
private System.Windows.Forms.GroupBox outputGroupBox;
private System.Windows.Forms.Button histogramBtn;
private System.Windows.Forms.Button customQueryButton;
}
}
+246 -1
View File
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2016-2019 Sensus Slovensko a.s.
/// Copyright (c) 2016-2020 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
@@ -12,6 +12,8 @@ using TBF.BenchControl.Generic;
using TBF.BenchControl.GenericDevices;
using ResultsBrowser.Filters;
using ResultsBrowser.Resources;
using Oracle;
using Oracle.DataAccess.Client;
namespace ResultsBrowser
{
@@ -32,6 +34,8 @@ namespace ResultsBrowser
static IList<IComponent> tbfComponents;
static IList<IDevice> tbfDevices;
OracleConnection oracleConnection; /// Oracle database connection
public ResultsBrowserWnd(string[] args)
{
InitializeComponent();
@@ -543,5 +547,246 @@ namespace ResultsBrowser
return null;
}
private void customQueryButton_Click(object sender, EventArgs e)
{
try
{
string[] orders = new string[] { "3137303", "3137301", "3142304", "3137302", "3137300" };
IList<OraData> oraDatas = new List<OraData>(); /// List of water meters
IList<int> testBenches = new List<int>(); /// List of test benches used to produce water meters
///
/// Get list of water meters satisfying (custom) criteria
///
Console.WriteLine("Collecting water meters");
foreach (var order in orders)
{
oracleConnection = new OracleConnection("Data Source=STARA01.WORLD;User Id=deltachef;Password=deltachef;");
oracleConnection.Open();
OracleCommand cmd = new OracleCommand("select VT_FERNUM, MAX_PRUEFINDEX, ZAEHLERNUMMER from VT_ZAEHLER_PD where AUFTRAGSNUMMER = :1 AND ANBID = 4 order by ZAEHLERNUMMER", oracleConnection);
cmd.Parameters.Add(new OracleParameter { ParameterName = "1", OracleDbType = OracleDbType.Varchar2, Value = order });
OracleDataReader dr = cmd.ExecuteReader();
int count = 0;
while (dr.Read())
{
int i = 0;
string pcbNr = dr.GetString(i++);
int maxPruefIx = dr.GetInt32(i++);
int testBenchId = maxPruefIx / 100;
maxPruefIx = maxPruefIx % 100;
int sn = dr.GetInt32(i++);
oraDatas.Add(new OraData() { PO = order, PcbNr = pcbNr, TestBenchId = testBenchId, MaxPruefIx = maxPruefIx, SN = sn });
if (!testBenches.Contains(testBenchId)) testBenches.Add(testBenchId);
count++;
}
dr.Close();
Console.WriteLine(string.Format("Order = {0} ... {1} water meters found", order, count));
}
Console.WriteLine("Collecting water meters completed");
Console.WriteLine();
///
/// Get required information about each water meter
///
Console.WriteLine("Reading additional data from Oracle");
int counter = 0;
foreach (var oraD in oraDatas)
{
Console.Write("{0} ", ++counter);
if (counter % 40 == 0) Console.WriteLine();
///
/// Read from VT_ZAEHLER_PINDEX_PD: TestId(ID_WZPRUEFREIHE))
///
OracleCommand cmd = new OracleCommand("select ID_PRUEFSTAND, ID_WZPRUEFREIHE, WT_PLATZ_NR, HYDR_PRUEFUNG from VT_ZAEHLER_PINDEX_PD where VT_FERNUM = :1 AND ANBID = 4 AND WZGUT = 1", oracleConnection);
cmd.Parameters.Add(new OracleParameter { ParameterName = "1", OracleDbType = OracleDbType.Varchar2, Value = oraD.PcbNr });
OracleDataReader dr = cmd.ExecuteReader();
while (dr.Read())
{
int i = 0;
int testBenchId = dr.GetInt32(i++) % 100;
oraD.TestId = dr.GetInt32(i++);
oraD.WMPosition = dr.GetInt32(i++);
oraD.HydrPruefung = dr.GetInt32(i++);
}
dr.Close();
///
/// Read from VT_IP_ZAEHLER_PINDEX_PD: Q2CorrectionRl, Q2CorrectionLr
///
cmd = new OracleCommand("select PRUEFINDEX, Q2CORRECTIONLEFT, Q2CORRECTIONRIGHT from VT_IP_ZAEHLER_PINDEX_PD where VT_FERNUM = :1 AND ANBID = 4", oracleConnection);
/// pruefindex, Q2_correction_RL, Q2_correction_LR, Q2_error_before_correction
cmd.Parameters.Add(new OracleParameter { OracleDbType = OracleDbType.Varchar2, Value = oraD.PcbNr });
dr = cmd.ExecuteReader();
while (dr.Read())
{
int i = 0;
int prfix = (dr.GetInt32(i++) % 100);
if (prfix == oraD.MaxPruefIx)
{
oraD.Q2CorrectionRl = dr.GetInt32(i++);
oraD.Q2CorrectionLr = dr.GetInt32(i++);
}
}
dr.Close();
///
/// Read data from VT_PRUEFREIHE_IST_PD
///
/// testID, flow, rel.err., passed
cmd = new OracleCommand("select PRUEFUNGSNR, Q_WZ, Q_FEHLER, Q_BEST from VT_PRUEFREIHE_IST_PD where VT_FERNUM = :1 AND PRUEFINDEX = :2 AND ANBID = 4", oracleConnection);
cmd.Parameters.Add(new OracleParameter { OracleDbType = OracleDbType.Varchar2, Value = oraD.PcbNr });
cmd.Parameters.Add(new OracleParameter { OracleDbType = OracleDbType.Int32, Value = 100 * oraD.TestBenchId + oraD.MaxPruefIx });
dr = cmd.ExecuteReader();
while (dr.Read())
{
int i = 0;
int testId = dr.GetInt32(i++); /// PRUEFUNGSNR
double flow = dr.GetDouble(i++); /// Q_WZ
double error = dr.GetDouble(i++); /// Q_FEHLER
bool testPassed = (dr.GetInt32(i++) != 0);
/// SUEZ specific
switch (testId)
{
case -2:
oraD.AdjErrA4 = error;
break;
case -1:
oraD.AdjErr = error;
break;
case 5:
oraD.Q3LrErr = error;
break;
case 10:
oraD.Q3RlErr = error;
break;
default:
break;
}
}
dr.Close();
} /// end of foreach (var oraD in OraDatas)
Console.WriteLine();
Console.WriteLine("Reading additional data from Oracle completed");
Console.WriteLine();
oracleConnection.Close();
Console.WriteLine("Reading additional data from MySQL");
counter = 0;
foreach (var testBenchId in testBenches)
{
Console.WriteLine((testBenchId == 8) ? "WR13" : (testBenchId == 9) ? "WR15" : (testBenchId == 10) ? "WR14" : "other");
switch (testBenchId)
{
case 8:
Results.DB.ConnectionString = "SERVER=localhost; DATABASE=st-wr13-r; UID=root; PASSWORD=kraken; CharSet=utf8;";
break;
case 9:
Results.DB.ConnectionString = "SERVER=localhost; DATABASE=st-wr15-r; UID=root; PASSWORD=kraken; CharSet=utf8;";
break;
case 10:
Results.DB.ConnectionString = "SERVER=localhost; DATABASE=st-wr14-r; UID=root; PASSWORD=kraken; CharSet=utf8;";
break;
default:
Results.DB.ConnectionString = string.Empty;
break;
}
if (!string.IsNullOrEmpty(Results.DB.ConnectionString))
{
ISession session = Results.DB.CreateSession();
foreach (var oraD in oraDatas)
{
if (oraD.TestBenchId == testBenchId)
{
Console.Write("{0} ", ++counter);
if (counter % 40 == 0) Console.WriteLine();
IList<WaterMeter> wms = session.QueryOver<WaterMeter>()
.Where(x => x.SerialNr == oraD.PcbNr)
.And(x => x.Passed)
.List();
if (wms.Count == 1)
{
oraD.CalibFactor = (int)Math.Round(wms[0].CalibFactor);
oraD.CalibFactorLNA = (int)Math.Round(wms[0].CalibFactorLNA);
}
else
{
foreach (var wm in wms)
{
if (wm.Batch.BatchNr == oraD.TestId)
{
oraD.CalibFactor = (int)Math.Round(wm.CalibFactor);
oraD.CalibFactorLNA = (int)Math.Round(wm.CalibFactorLNA);
break;
}
}
}
}
}
Console.WriteLine();
session.Close();
}
}
Console.WriteLine("Reading additional data from MySQL");
Console.WriteLine();
Console.WriteLine("CSV data begin");
foreach (var oraD in oraDatas)
{
//Console.WriteLine(string.Format("S/N={0} PCB={1} bench={2} Batch={3} Pos={4} AdjA0={5} AdjA4={6} Q3RL={7} Q3LR={8} CalF={9} CAlF_LNA={10} HP={11} Q2cRL={12} Q2cLR={13}",
// oraD.SN,
// oraD.PcbNr,
// (oraD.TestBenchId == 8) ? "WR13" : (oraD.TestBenchId == 9) ? "WR15" : (oraD.TestBenchId == 10) ? "WR14" : "other",
// oraD.TestId,
// oraD.WMPosition,
// oraD.AdjErr.ToString("F1"),
// oraD.AdjErrA4.ToString("F1"),
// oraD.Q3RlErr.ToString("F1"),
// oraD.Q3LrErr.ToString("F1"),
// oraD.CalibFactor,
// oraD.CalibFactorLNA,
// oraD.HydrPruefung,
// oraD.Q2CorrectionRl,
// oraD.Q2CorrectionLr));
Console.WriteLine(string.Format("{0}; =(\"{1}\"); {2}; {3}; {4}; {5}; {6}; {7}; {8}; {9}; {10}; {12}; {13}",
oraD.SN,
oraD.PcbNr,
(oraD.TestBenchId == 8) ? "WR13" : (oraD.TestBenchId == 9) ? "WR15" : (oraD.TestBenchId == 10) ? "WR14" : "other",
oraD.TestId,
oraD.WMPosition,
oraD.AdjErr.ToString("F2"),
oraD.AdjErrA4.ToString("F2"),
oraD.Q3RlErr.ToString("F2"),
oraD.Q3LrErr.ToString("F2"),
oraD.CalibFactor,
oraD.CalibFactorLNA,
oraD.HydrPruefung,
oraD.Q2CorrectionRl,
oraD.Q2CorrectionLr));
}
Console.WriteLine("CSV data end");
}
catch (Exception exc)
{
MessageBox.Show(exc.Message);
}
}
}
}
+2 -10
View File
@@ -1,14 +1,12 @@
Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2012
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TBF", "TBF\TBF.csproj", "{8648FD92-CDA1-4C3A-B5F9-FE547CE1FA48}"
ProjectSection(ProjectDependencies) = postProject
{EFEC8A31-3022-4DA7-A8F6-16D30A94C3FF} = {EFEC8A31-3022-4DA7-A8F6-16D30A94C3FF}
{0C0A1F4D-1363-4544-A7C5-196C76D26CCA} = {0C0A1F4D-1363-4544-A7C5-196C76D26CCA}
EndProjectSection
EndProject
Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "TBFSetup", "TBFSetup\TBFSetup.vdproj", "{4890DE5C-9F68-40D7-B075-92C8EAB79833}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Results", "Results\Results.csproj", "{9D0DCC88-DC81-47EB-9FDD-4C3907871BFB}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Config", "Config\Config.csproj", "{743DF7DB-C7B6-42EB-986D-0F485E5588E4}"
@@ -74,12 +72,6 @@ Global
{8648FD92-CDA1-4C3A-B5F9-FE547CE1FA48}.Release|Mixed Platforms.Build.0 = Release|x86
{8648FD92-CDA1-4C3A-B5F9-FE547CE1FA48}.Release|x86.ActiveCfg = Release|x86
{8648FD92-CDA1-4C3A-B5F9-FE547CE1FA48}.Release|x86.Build.0 = Release|x86
{4890DE5C-9F68-40D7-B075-92C8EAB79833}.Debug|Any CPU.ActiveCfg = Debug
{4890DE5C-9F68-40D7-B075-92C8EAB79833}.Debug|Mixed Platforms.ActiveCfg = Debug
{4890DE5C-9F68-40D7-B075-92C8EAB79833}.Debug|x86.ActiveCfg = Debug
{4890DE5C-9F68-40D7-B075-92C8EAB79833}.Release|Any CPU.ActiveCfg = Release
{4890DE5C-9F68-40D7-B075-92C8EAB79833}.Release|Mixed Platforms.ActiveCfg = Release
{4890DE5C-9F68-40D7-B075-92C8EAB79833}.Release|x86.ActiveCfg = Release
{9D0DCC88-DC81-47EB-9FDD-4C3907871BFB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{9D0DCC88-DC81-47EB-9FDD-4C3907871BFB}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{9D0DCC88-DC81-47EB-9FDD-4C3907871BFB}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
+1 -1
View File
@@ -19,7 +19,7 @@ namespace TBF.BenchControl.Elde
EnduranceCycleStop = 13,
}
#if FUZHOU_300 || IZRAEL_200 || TORINO_50 || BADGER_MALA_TRAT || BADGER_STREDNA_TRAT || TURA_IPERL || TURA_IPERL_NEW || TURA_SPECIAL || BADGER_VELKA_TRAT || PUCHONG_200 || SLM_50 || GENESIS || MALTA_WSD25 || SLM_END || WARSAW_END || BERLIN || SLM_150 || PETERSBURG_50 || PETERSBURG_200 || DEWA_300 || KEMPNO_50 || BAHRAIN_50 || RUM_MOB || KRAKOW_50 || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || SENTEC || FUZHOU_100 || CEVAK_200 || IZRAEL_50
#if FUZHOU_300 || IZRAEL_200 || TORINO_50 || BADGER_MALA_TRAT || BADGER_STREDNA_TRAT || TURA_IPERL || TURA_IPERL_NEW || TURA_SPECIAL || BADGER_VELKA_TRAT || PUCHONG_200 || SLM_50 || GENESIS || MALTA_WSD25 || SLM_END || WARSAW_END || BERLIN || SLM_150 || PETERSBURG_50 || PETERSBURG_200 || DEWA_300 || KEMPNO_50 || BAHRAIN_50 || RUM_MOB || KRAKOW_50 || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || SENTEC || FUZHOU_100 || CEVAK_200 || IZRAEL_50 || ALZIR_25
public enum StatusP : ulong
{
RefFlowMeterMask = 0x7, /// bits 0,1,2
+35 -18
View File
@@ -128,7 +128,7 @@ namespace TBF.BenchControl.Elde
{100,500}, {100,500}, {100,500}, {100,500} };
public byte[] MeretRS485Address = new byte[4];
public float[] EtCalib = new float[8] { 1, 1, 1, 1, 1, 1, 1, 1 };
#elif MUNICH || TORINO_50 || BADGER_MALA_TRAT || BADGER_STREDNA_TRAT || TORUN_50 || CEVAK_40 || TURA_IPERL || TURA_IPERL_NEW || TURA_SPECIAL || MURES_40 || FUZHOU_50 || SLM_50 || PETERSBURG_50 || KEMPNO_50 || BAHRAIN_50 || KRAKOW_50 || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || FUZHOU_100
#elif MUNICH || TORINO_50 || BADGER_MALA_TRAT || BADGER_STREDNA_TRAT || TORUN_50 || CEVAK_40 || TURA_IPERL || TURA_IPERL_NEW || TURA_SPECIAL || MURES_40 || FUZHOU_50 || SLM_50 || PETERSBURG_50 || KEMPNO_50 || BAHRAIN_50 || KRAKOW_50 || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || FUZHOU_100 || ALZIR_25
public uint[,] RegValveCalib = new uint[8,2] {{100,500},{100,500},{100,500},{100,500},{100,500},{100,500},{100,500},{100,500}};
public byte[] MeretRS485Address = new byte[4];
public float[] EtCalib = new float[5] { 1, 1, 1, 1, 1 };
@@ -213,20 +213,27 @@ namespace TBF.BenchControl.Elde
}
#endif
if (index >= 0 && index < FMFreq.Length && FMFreq[index] != power)
{
FMFreq[index] = power;
if (index >= 0 && index < FMFreq.Length)
{
if (FMFreq[index] != power)
{
FMFreq[index] = power;
pumpPowerChanged = true; /// Forces sending a command using Command.None
pumpPowerChanged = true; /// Forces sending a command using Command.None
log.DebugFormat("FMFreq=[{0}{1}{2}{3}{4}{5}]",
FMFreq[0].ToString(),
(FMFreq.Length > 1) ? ("," + FMFreq[1].ToString()) : "",
(FMFreq.Length > 2) ? ("," + FMFreq[2].ToString()) : "",
(FMFreq.Length > 3) ? ("," + FMFreq[3].ToString()) : "",
(FMFreq.Length > 4) ? ("," + FMFreq[4].ToString()) : "",
(FMFreq.Length > 5) ? ("," + FMFreq[5].ToString()) : "");
}
string s = string.Format("FMFreq=[{0}{1}{2}{3}{4}{5}]", FMFreq[0].ToString(),
(FMFreq.Length > 1) ? ("," + FMFreq[1].ToString()) : "",
(FMFreq.Length > 2) ? ("," + FMFreq[2].ToString()) : "",
(FMFreq.Length > 3) ? ("," + FMFreq[3].ToString()) : "",
(FMFreq.Length > 4) ? ("," + FMFreq[4].ToString()) : "",
(FMFreq.Length > 5) ? ("," + FMFreq[5].ToString()) : "");
log.Warn(s);
}
}
else
{
log.ErrorFormat("Wrong FM pump: index = {0}, power = {1}", index, power);
}
}
@@ -312,7 +319,7 @@ namespace TBF.BenchControl.Elde
#else /// all newer benches
ControlComponent_Torino2015.UserControl1 ctrlBrdComponent,
#endif
UInt128 valvesToInvert,
UInt128 valvesToInvert,
double[] tankCapacities)
{
this.valvesToInvert = valvesToInvert;
@@ -442,15 +449,20 @@ namespace TBF.BenchControl.Elde
if (cbCommandQueue.Count > 0)
{
///
/// There is a command in the queue
///
controlCom.SendCommand(cbCommandQueue.Dequeue(), (benchModelRoute & routeMask), uintFilters, FMFreq, regConst, shortImp);
lastSentRoute = (benchModelRoute & routeMask);
lastSentFilters = uintFilters;
lastSentFMFreq = FMFreq;
lastsentRegConst = regConst;
lastSentShortImp = shortImp;
/// Deep copy of arrays lastSentFilters and lastSentFMFreq
if ((lastSentFilters == null) || (lastSentFilters.Length != uintFilters.Length)) lastSentFilters = new uint[(uintFilters == null) ? 0 : uintFilters.Length];
for (int i = 0; i < lastSentFilters.Length; i++) lastSentFilters[i] = uintFilters[i];
if ((lastSentFMFreq == null) || (lastSentFMFreq.Length != FMFreq.Length)) lastSentFMFreq = new float[(FMFreq == null) ? 0 : FMFreq.Length];
for (int i = 0; i < lastSentFMFreq.Length; i++) lastSentFMFreq[i] = FMFreq[i];
}
else if (((benchModelRoute & routeMask) != lastSentRoute) ||
filtersAreDifferent ||
@@ -458,15 +470,20 @@ namespace TBF.BenchControl.Elde
(lastsentRegConst != regConst) ||
(lastSentShortImp != shortImp))
{
///
/// Command queue is mepty, but 'route', pump frequency, PID coef., filters or shortImp have changed
///
controlCom.SendCommand(new SendCommandArgs(Command.None, 0, 0, 0, 0, 0), (benchModelRoute & routeMask), uintFilters, FMFreq, regConst, shortImp);
lastSentRoute = (benchModelRoute & routeMask);
lastSentFilters = uintFilters;
lastSentFMFreq = FMFreq;
lastsentRegConst = regConst;
lastSentShortImp = shortImp;
/// Deep copy of arrays lastSentFilters and lastSentFMFreq
if ((lastSentFilters == null) || (lastSentFilters.Length != uintFilters.Length)) lastSentFilters = new uint[(uintFilters == null) ? 0 : uintFilters.Length];
for (int i = 0; i < lastSentFilters.Length; i++) lastSentFilters[i] = uintFilters[i];
if ((lastSentFMFreq == null) || (lastSentFMFreq.Length != FMFreq.Length)) lastSentFMFreq = new float[(FMFreq == null) ? 0 : FMFreq.Length];
for (int i = 0; i < lastSentFMFreq.Length; i++) lastSentFMFreq[i] = FMFreq[i];
}
controlCom.RunDeviceAfter();
+17 -18
View File
@@ -20,31 +20,30 @@ namespace TBF.BenchControl.Elde
public StatusP StatusP { get { return (StatusP)ctrlBrdComponent.StatusP; } }
#if DN100 || MUNICH || FUZHOU_150
public double ReferenceFreq { get { return 1000.0f * ctrlBrdComponent.referenceFreq; } } /// In [Hz] 0..2500, nom.=2000
public double ReferenceFreq { get { return 1000.0f * ctrlBrdComponent.referenceFreq; } } /// Returns in [Hz] 0..2500, nom.=2000
public double ReferenceFreqs(int i) { return 0; }
#else /// all newer benches
#else
/// All newer benches
public double ReferenceFreq { get { return 1000.0 * ctrlBrdComponent.referenceFreq[0]; } } /// Returns in [Hz] 0..2500, nom.=2000
///
/// <summary>
/// In case of I11, I12
/// referenceFreq[0] = I11 + I12
/// referenceFreq[1] = I11
/// referenceFreq[2] = I12
/// cBrd.referenceFreq[0] = I11 + I12
/// cBrd.referenceFreq[1] = I11
/// cBrd.referenceFreq[2] = I12
/// otherwise
/// referenceFreq[0] = I2 or I3 or I4
/// cBrd.referenceFreq[0] = I2 or I3 or I4
/// </summary>
public double ReferenceFreq { get { return 1000.0 * ctrlBrdComponent.referenceFreq[0]; } } /// In [Hz] 0..2500, nom.=2000 ///
/// <returns>Reference frequency in Hz</returns>
public double ReferenceFreqs(int i)
{
if ((i >= 0) && (i < ctrlBrdComponent.referenceFreq.Length))
{
return 1000.0 * ctrlBrdComponent.referenceFreq[0]; /// In [Hz] 0..2500, nom.=2000
}
else return 0;
return ((i >= 0) && (i < ctrlBrdComponent.referenceFreq.Length)) ? (1000.0 * ctrlBrdComponent.referenceFreq[i]) : 0;
}
#endif
public int EtPulses(int wmNr1) { return (int)ctrlBrdComponent.etPulses[wmNr1]; }
#if DN100 || MUNICH || BADGER_MALA_TRAT || BADGER_STREDNA_TRAT || BADGER_VELKA_TRAT || TORINO_50 || TORUN_50 || CEVAK_40 || MURES_40 || IZRAEL_200 || MALTA_WSD25
#if DN100 || MUNICH || BADGER_MALA_TRAT || BADGER_STREDNA_TRAT || BADGER_VELKA_TRAT || TORINO_50 || TORUN_50 || CEVAK_40 || MURES_40 || IZRAEL_200 || MALTA_WSD25 || FUZHOU_300
public int EtPulsesK { get { return 1; } }
#else /// all new benches
public int EtPulsesK { get { return (int)ctrlBrdComponent.etPulsesK; } }
@@ -70,7 +69,7 @@ namespace TBF.BenchControl.Elde
}
public float Pressure(int prsNr0) { return ctrlBrdComponent.pressure[prsNr0]; }
public float Temperature(int tmpNr0) { return ctrlBrdComponent.temperature[tmpNr0]; }
public float Temperature(int tmpNr0) { return (tmpNr0 >= 0 && tmpNr0 < ctrlBrdComponent.temperature.Length) ? ctrlBrdComponent.temperature[tmpNr0] : 0; }
public RegulValveState RegulValveState(int rvNr1) { return (RegulValveState)ctrlBrdComponent.rValveStatus[rvNr1 - 1]; }
#if GENESIS || BERLIN || PETERSBURG_200 || DEWA_300
public UInt128 RRoute { get { return ((UInt128)ctrlBrdComponent.rRouteH << 64) | (UInt128)ctrlBrdComponent.rRoute; } }
@@ -78,7 +77,7 @@ namespace TBF.BenchControl.Elde
public UInt128 RRoute { get { return ctrlBrdComponent.rRoute; } }
#endif
#if GENESIS || KEMPNO_50 || KRAKOW_50 || BAHRAIN_50 || BADGER_STREDNA_TRAT || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || SENTEC || FUZHOU_100 || CEVAK_200 || IZRAEL_50 || DEWA_300 || PUCHONG_200 || TURA_IPERL_NEW
#if GENESIS || KEMPNO_50 || KRAKOW_50 || BAHRAIN_50 || BADGER_STREDNA_TRAT || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || SENTEC || FUZHOU_100 || CEVAK_200 || IZRAEL_50 || DEWA_300 || PUCHONG_200 || TURA_IPERL_NEW || ALZIR_25
public uint DivTime(int id) { return ctrlBrdComponent.divTime[id]; }
public void SetDivLimit(int divNo, uint limLoPct, uint limHiPct)
{
@@ -138,7 +137,7 @@ namespace TBF.BenchControl.Elde
public uint[] WMeterCont { get { return new uint[3]; } } /// Dummy
#endif
#if KEMPNO_50 || KRAKOW_50 || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || FUZHOU_100 || CEVAK_200 || IZRAEL_50
#if KEMPNO_50 || KRAKOW_50 || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || FUZHOU_100 || CEVAK_200 || IZRAEL_50 || ALZIR_25
public float ValveOpenCloseTime { get { return ctrlBrdComponent.ValveMoveTime[0]; } }
#else
public float ValveOpenCloseTime { get { return 0.001f; } }
@@ -261,7 +260,7 @@ namespace TBF.BenchControl.Elde
ctrlBrdComponent.ExternalCom = true;
#if SENTEC || CEVAK_200 || FUZHOU_100 || IZRAEL_25
#if SENTEC || CEVAK_200 || FUZHOU_100 || IZRAEL_25 || ALZIR_25
ctrlBrdComponent.SendCalibData(rvCalib, meretA, (byte)usedCom, tempCalib, etCalib, divEdge, balanceRange, meretProtocol);
#else
ctrlBrdComponent.SendCalibData(rvCalib, meretA, (byte)usedCom, tempCalib, etCalib, divEdge, balanceRange);
@@ -417,7 +416,7 @@ namespace TBF.BenchControl.Elde
(uint)regConst,
(uint)shortImp,
(uint)sendCommandArgs.StopDevs);
#elif JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || SENTEC || FUZHOU_100 || CEVAK_200 || IZRAEL_50
#elif JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || SENTEC || FUZHOU_100 || CEVAK_200 || IZRAEL_50 || ALZIR_25
ctrlBrdComponent.SendCommand((uint)sendCommandArgs.Cmd,
(byte)sendCommandArgs.RefFlowmtrNr,
(ulong)route,
@@ -17,6 +17,15 @@ namespace TBF.BenchControl.Elde.FixedStartRegisterReader
readonly ControlBoardDev controlBoard;
public int Position
{
get
{
int firstDigitPos = Name.IndexOfAny(new char[] { '1', '2', '3', '4', '5', '6', '7', '8', '9', '0' });
int position;
return (firstDigitPos < 0) ? 0 : (int.TryParse(Name.Substring(firstDigitPos), out position) ? position : 0);
}
}
public Config.Entities.RegisterReaderType RegisterReaderType { get { return Config.Entities.RegisterReaderType.Manual; } }
public double PulsesPerLtr { get { return registerReaderCfg.ProcParams.PulsesPerLtr; } }
public double LtrsPerPulse { get { return (PulsesPerLtr <= float.Epsilon) ? 1.0 : (1 / PulsesPerLtr); } }
@@ -52,8 +52,9 @@ namespace TBF.BenchControl.Elde.FlowMeterDewa
double flow1, flow2, flow3;
double contribution1, contribution2, contribution3;
if (refFreq[0] != 0)
if (refPulses[0] != 0)
{
/// Division by zero prevented inside this 'if'
double ltrPerPulseCorrected = 0;
if (flowMeter1 != null)
{
@@ -110,13 +110,12 @@ namespace TBF.BenchControl.Elde.RegisterReader
wmPulses = lastPulses;
wmRefPulses = (int)controlBoard.EtPulses(Position);
log.DebugFormat("{0}:ReadPulses() completed, wmPulses={1} wmRefPulses={2} cb.EtPulses(0)={3}", Name, wmPulses, wmRefPulses, (int)controlBoard.EtPulses(0));
log.DebugFormat("{0}:ReadPulses() completed, wmPulses={1} wmRefPulses={2}", Name, wmPulses, wmRefPulses);
}
/// <summary>Start this operation</summary>
public void Start()
{
log.DebugFormat("{0}:Start()", Name);
lastPulsesValid = false;
ReadPulses();
}
@@ -125,7 +124,6 @@ namespace TBF.BenchControl.Elde.RegisterReader
/// <returns>eventDone</returns>
public Event Run()
{
log.DebugFormat("{0}:Run()", Name);
ReadPulses();
return Event.ReadRegisterDone;
}
@@ -133,7 +131,6 @@ namespace TBF.BenchControl.Elde.RegisterReader
/// <summary>Stop this operation</summary>
public void Stop()
{
log.DebugFormat("{0}:Stop()", Name);
ReadPulses();
}
}
@@ -108,14 +108,9 @@ namespace TBF.BenchControl.Elde.RegulValve
#endif
if (Idx1 < ControlBoard.RegValveCalib.GetLength(0))
{
#if IZRAEL_25
{
this.ControlBoard.RegValveCalib[adcChannel, 0] = (uint)DacValueClosed;
this.ControlBoard.RegValveCalib[adcChannel, 1] = (uint)DacValueOpen;
#else
this.ControlBoard.RegValveCalib[Idx1 - 1, 0] = (uint)DacValueClosed;
this.ControlBoard.RegValveCalib[Idx1 - 1, 1] = (uint)DacValueOpen;
#endif
}
else
{
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2013-2017 Sensus Metering Systems
/// Copyright (c) 2013-2019 Sensus Slovensko a.s.
///
using TBF.BenchControl.Generic;
using TBF.Boxes;
@@ -10,6 +10,7 @@ namespace TBF.BenchControl.GenericDevices
{
Config.Entities.RegisterReaderType RegisterReaderType { get; }
int Position { get; }
double PulsesPerLtr { get; } /// [imp/l] ... water meter or volume measurement part of a heat meter
double LtrsPerPulse { get; } /// [l/imp]
@@ -33,6 +33,15 @@ namespace TBF.BenchControl.Network.Camera.Roi
///
public GenericDevices.ICamera Camera { get { return NetCamera as GenericDevices.ICamera; } }
public int Position
{
get
{
int firstDigitPos = Name.IndexOfAny(new char[] { '1', '2', '3', '4', '5', '6', '7', '8', '9', '0' });
int position;
return (firstDigitPos < 0) ? 0 : (int.TryParse(Name.Substring(firstDigitPos), out position) ? position : 0);
}
}
public Config.Entities.RegisterReaderType RegisterReaderType { get { return Config.Entities.RegisterReaderType.Camera; } }
public double PulsesPerLtr { get { return RoiCfg.ProcParams.PulsesPerLtr; } }
public double LtrsPerPulse { get { return (PulsesPerLtr <= float.Epsilon) ? 1.0 : (1 / PulsesPerLtr); } }
@@ -30,6 +30,15 @@ namespace TBF.BenchControl.Network.Camera.RoiForFixedStart
public readonly CLP1611.Camera NetCamera;
public GenericDevices.ICamera Camera { get { return NetCamera as GenericDevices.ICamera; } }
public int Position
{
get
{
int firstDigitPos = Name.IndexOfAny(new char[] { '1', '2', '3', '4', '5', '6', '7', '8', '9', '0' });
int position;
return (firstDigitPos < 0) ? 0 : (int.TryParse(Name.Substring(firstDigitPos), out position) ? position : 0);
}
}
public Config.Entities.RegisterReaderType RegisterReaderType { get { return Config.Entities.RegisterReaderType.Manual; } }
public double PulsesPerLtr { get { return roiCfg.ProcParams.PulsesPerLtr; } }
public double LtrsPerPulse { get { return (PulsesPerLtr <= float.Epsilon) ? 1.0 : (1 / PulsesPerLtr); } }
@@ -18,6 +18,7 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
public string ConnStr;
public string ConnStr2;
public string NetAdapter;
public bool CheckPreviousRecords;
public bool SaveTracingRecords;
@@ -28,7 +29,8 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
{
ParentName = string.Empty;
NetAdapter = string.Empty;
ConnStr = "SERVER=10.42.128.16; DATABASE=sledovanie2019; UID=vyroba2019; PASSWORD=qwerty; CHARSET=utf8;";
ConnStr = "server=10.42.128.16; database=sledovanie2020; uid=vyroba2020; pwd=qwerty; charset=utf8;";
ConnStr2 = "server=10.42.128.16; database=sledovanie2019; uid=vyroba2019; pwd=qwerty; charset=utf8;";
CheckPreviousRecords = true;
SaveTracingRecords = true;
}
@@ -42,11 +44,12 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
public string ToString(int i)
{
return string.Format("Name={0}, CheckPreviousRecords={1}, SaveTracingRecords={2}, ConnStr={3}",
return string.Format("Name={0}, CheckPrev.={1}, SaveRecords={2}, ConnStr={3}, , ConnStr2={4}",
Name,
CheckPreviousRecords,
SaveTracingRecords,
ConnStr);
ConnStr,
ConnStr2);
}
}
}
@@ -76,11 +76,16 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
Results.Entities.Batch batch;
ISessionFactory sessionFactory; /// Factory to create database sessions that is initialized in the constructor
ISessionFactory sessionFactory; /// Factory to create database sessions that is initialized in the constructor
IList<Process> processes;
Dictionary<int, Process> processDictionary;
Dictionary<int, IList<Workstep>> workstepsDictionary;
ISessionFactory sessionFactory2; /// Factory to create database sessions that is initialized in the constructor
IList<Process> processes2;
Dictionary<int, Process> processDictionary2;
Dictionary<int, IList<Workstep>> workstepsDictionary2;
///
/// Previous workstep verification info
///
@@ -125,6 +130,19 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
.Mappings(m => m.FluentMappings.AddFromAssemblyOf<TracingDB.Entities.Process>())
.ExposeConfiguration(TracingDB.DB.BuildSchema)
.BuildSessionFactory();
///
/// Session factory 2 is used to create the 2nd database sessions
///
if (!string.IsNullOrEmpty(tracingCfg.ConnStr2))
{
sessionFactory2 = FluentNHibernate.Cfg.Fluently.Configure()
.Database(FluentNHibernate.Cfg.Db.MySQLConfiguration.Standard.ConnectionString(tracingCfg.ConnStr2))
.Mappings(m => m.FluentMappings.AddFromAssemblyOf<TracingDB.Entities.Process>())
.ExposeConfiguration(TracingDB.DB.BuildSchema)
.BuildSessionFactory();
}
///
/// Register this test bench in the tracing DB for approx. 2 weeks
///
@@ -290,6 +308,7 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
{
Retv retVal = Retv.Error;
bool isAtLeastOneNOK = false;
using (ISession session = sessionFactory.OpenSession())
{
for (int i = 0; i < waterMeters.Length; i++)
@@ -298,22 +317,45 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
if ((wm != null) && !wm.Disabled)
{
CheckPreviousRecordOfSingleWM(session, wm);
CheckPreviousRecordOfSingleWM(session, wm, 1);
if (wm.LastRecordIsNok)
{
isAtLeastOneNOK = true;
}
}
}
retVal = Retv.OK;
}
if (isAtLeastOneNOK && (sessionFactory2 != null))
{
using (ISession session2 = sessionFactory2.OpenSession())
{
for (int i = 0; i < waterMeters.Length; i++)
{
Results.Entities.WaterMeter wm = waterMeters[i];
if ((wm != null) && !wm.Disabled && wm.LastRecordIsNok)
{
CheckPreviousRecordOfSingleWM(session2, wm, 2);
}
}
retVal = Retv.OK;
}
}
return retVal;
}
Retv CheckPreviousRecordOfSingleWM(ISession session, Results.Entities.WaterMeter wm)
Retv CheckPreviousRecordOfSingleWM(ISession session, Results.Entities.WaterMeter wm, int sessionId)
{
if (string.IsNullOrEmpty(wm.SerialNr))
{
/// S/N is missing
wm.ProcessId = 0;
wm.SessionId = 0;
wm.LastRecordIsNok = false; /// OK, this is an RFID comm. error, not a production tracing error
return Retv.OK;
}
@@ -345,6 +387,7 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
{
/// No records found
wm.ProcessId = 0;
wm.SessionId = sessionId;
wm.LastRecordIsNok = true; /// NOK
///
return Retv.OK;
@@ -403,7 +446,8 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
wm.ProcessId = currentProcess.Id;
wm.LastRecordIsNok = true; /// NOK (=default if no matching record found)
wm.SessionId = sessionId;
wm.LastRecordIsNok = true; /// NOK (=default if no matching record found)
foreach (var rslt in results)
{
if ((verifiedWorkstep.Id == (int)rslt[1]) && (processId == (int)rslt[2]))
@@ -427,6 +471,10 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
{
ITransaction transaction = null;
ISession session = null;
///
/// Save to regular tracing DB
///
try
{
session = sessionFactory.OpenSession();
@@ -435,15 +483,16 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
int writtenRecordsCount = 0;
foreach (var wMtr in batch.WaterMeters)
{
writtenRecordsCount += SaveSingleWM2DB(session, wMtr);
if (wMtr.SessionId == 1)
{
writtenRecordsCount += SaveSingleWM2DB(session, wMtr);
}
}
transaction.Commit();
session.Flush();
log.ErrorFormat("Batch {0}: {1} of {2} watermeters written to production tracing DB",
log.ErrorFormat("Batch {0}: {1} of {2} watermeters written to the regular production tracing DB",
batch.BatchNr, writtenRecordsCount, batch.WaterMeters.Count);
return Retv.OK;
}
catch (Exception exc)
{
@@ -462,7 +511,54 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
session.Dispose();
}
}
}
if (sessionFactory2 != null)
{
///
/// Save to alternative tracing DB
///
transaction = null;
session = null;
try
{
session = sessionFactory2.OpenSession();
transaction = session.BeginTransaction();
int writtenRecordsCount = 0;
foreach (var wMtr in batch.WaterMeters)
{
if (wMtr.SessionId == 2)
{
writtenRecordsCount += SaveSingleWM2DB(session, wMtr);
}
}
transaction.Commit();
session.Flush();
log.ErrorFormat("Batch {0}: {1} of {2} watermeters written to the alternative production tracing DB",
batch.BatchNr, writtenRecordsCount, batch.WaterMeters.Count);
}
catch (Exception exc)
{
if (transaction != null && !transaction.WasCommitted) transaction.Rollback();
log.WarnFormat("Failed to write results of batch {0} to production tracing DB: {1}",
batch.BatchNr, exc.Message);
return Retv.Error;
}
finally
{
if (session != null)
{
session.Close();
session.Dispose();
}
}
}
return Retv.OK;
}
/// <summary>
@@ -47,6 +47,7 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
classNameLabel.Text = config.Factory.ClassName;
nameTextBox.Text = config.Name;
connStrTextBox.Text = config.ConnStr;
connStr2TextBox.Text = config.ConnStr2;
checkPreviousRecordsCheckBox.Checked = config.CheckPreviousRecords;
saveTracingRecordsCheckBox.Checked = config.SaveTracingRecords;
@@ -102,6 +103,7 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
{
nameTextBox.Enabled = true;
connStrTextBox.Enabled = true;
connStr2TextBox.Enabled = true;
netAdapterComboBox.Enabled = true;
checkPreviousRecordsCheckBox.Enabled = true;
saveTracingRecordsCheckBox.Enabled = true;
@@ -125,6 +127,7 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
}
flags |= UpdateDifferent(ref config.ConnStr, connStrTextBox.Text, CfgUpdateFlags.AnyChange | CfgUpdateFlags.RestartRqrd);
flags |= UpdateDifferent(ref config.ConnStr2, connStr2TextBox.Text, CfgUpdateFlags.AnyChange | CfgUpdateFlags.RestartRqrd);
flags |= UpdateDifferent(ref config.CheckPreviousRecords, checkPreviousRecordsCheckBox.Checked, CfgUpdateFlags.AnyChange | CfgUpdateFlags.RestartRqrd);
flags |= UpdateDifferent(ref config.SaveTracingRecords, saveTracingRecordsCheckBox.Checked, CfgUpdateFlags.AnyChange | CfgUpdateFlags.RestartRqrd);
@@ -40,29 +40,31 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
this.checkPreviousRecordsCheckBox = new System.Windows.Forms.CheckBox();
this.netAdapterLabel = new System.Windows.Forms.Label();
this.netAdapterComboBox = new System.Windows.Forms.ComboBox();
this.connStr2TextBox = new System.Windows.Forms.TextBox();
this.connStr2Label = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// nameTextBox
//
this.nameTextBox.Enabled = false;
this.nameTextBox.Location = new System.Drawing.Point(110, 51);
this.nameTextBox.Location = new System.Drawing.Point(117, 32);
this.nameTextBox.Name = "nameTextBox";
this.nameTextBox.Size = new System.Drawing.Size(146, 20);
this.nameTextBox.Size = new System.Drawing.Size(326, 20);
this.nameTextBox.TabIndex = 2;
//
// nameLabel
//
this.nameLabel.AutoSize = true;
this.nameLabel.Location = new System.Drawing.Point(15, 54);
this.nameLabel.Location = new System.Drawing.Point(5, 35);
this.nameLabel.Name = "nameLabel";
this.nameLabel.Size = new System.Drawing.Size(35, 13);
this.nameLabel.Size = new System.Drawing.Size(38, 13);
this.nameLabel.TabIndex = 1;
this.nameLabel.Text = "Name";
this.nameLabel.Text = "Name:";
//
// classNameLabel
//
this.classNameLabel.AutoSize = true;
this.classNameLabel.Location = new System.Drawing.Point(107, 26);
this.classNameLabel.Location = new System.Drawing.Point(114, 10);
this.classNameLabel.Name = "classNameLabel";
this.classNameLabel.Size = new System.Drawing.Size(83, 13);
this.classNameLabel.TabIndex = 0;
@@ -71,25 +73,25 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
// connStrTextBox
//
this.connStrTextBox.Enabled = false;
this.connStrTextBox.Location = new System.Drawing.Point(110, 76);
this.connStrTextBox.Location = new System.Drawing.Point(8, 74);
this.connStrTextBox.Name = "connStrTextBox";
this.connStrTextBox.Size = new System.Drawing.Size(327, 20);
this.connStrTextBox.TabIndex = 6;
this.connStrTextBox.Size = new System.Drawing.Size(435, 20);
this.connStrTextBox.TabIndex = 4;
//
// connStrLabel
//
this.connStrLabel.AutoSize = true;
this.connStrLabel.Location = new System.Drawing.Point(15, 79);
this.connStrLabel.Location = new System.Drawing.Point(5, 58);
this.connStrLabel.Name = "connStrLabel";
this.connStrLabel.Size = new System.Drawing.Size(89, 13);
this.connStrLabel.TabIndex = 5;
this.connStrLabel.Text = "Connection string";
this.connStrLabel.Size = new System.Drawing.Size(92, 13);
this.connStrLabel.TabIndex = 3;
this.connStrLabel.Text = "Connection string:";
//
// saveTracingRecordsCheckBox
//
this.saveTracingRecordsCheckBox.AutoSize = true;
this.saveTracingRecordsCheckBox.Enabled = false;
this.saveTracingRecordsCheckBox.Location = new System.Drawing.Point(110, 159);
this.saveTracingRecordsCheckBox.Location = new System.Drawing.Point(117, 221);
this.saveTracingRecordsCheckBox.Name = "saveTracingRecordsCheckBox";
this.saveTracingRecordsCheckBox.Size = new System.Drawing.Size(177, 17);
this.saveTracingRecordsCheckBox.TabIndex = 10;
@@ -100,7 +102,7 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
//
this.checkPreviousRecordsCheckBox.AutoSize = true;
this.checkPreviousRecordsCheckBox.Enabled = false;
this.checkPreviousRecordsCheckBox.Location = new System.Drawing.Point(110, 136);
this.checkPreviousRecordsCheckBox.Location = new System.Drawing.Point(117, 199);
this.checkPreviousRecordsCheckBox.Name = "checkPreviousRecordsCheckBox";
this.checkPreviousRecordsCheckBox.Size = new System.Drawing.Size(138, 17);
this.checkPreviousRecordsCheckBox.TabIndex = 9;
@@ -110,24 +112,44 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
// netAdapterLabel
//
this.netAdapterLabel.AutoSize = true;
this.netAdapterLabel.Location = new System.Drawing.Point(15, 104);
this.netAdapterLabel.Location = new System.Drawing.Point(5, 147);
this.netAdapterLabel.Name = "netAdapterLabel";
this.netAdapterLabel.Size = new System.Drawing.Size(86, 13);
this.netAdapterLabel.Size = new System.Drawing.Size(89, 13);
this.netAdapterLabel.TabIndex = 7;
this.netAdapterLabel.Text = "Network adapter";
this.netAdapterLabel.Text = "Network adapter:";
//
// netAdapterComboBox
//
this.netAdapterComboBox.Enabled = false;
this.netAdapterComboBox.FormattingEnabled = true;
this.netAdapterComboBox.Location = new System.Drawing.Point(110, 101);
this.netAdapterComboBox.Location = new System.Drawing.Point(8, 163);
this.netAdapterComboBox.Name = "netAdapterComboBox";
this.netAdapterComboBox.Size = new System.Drawing.Size(327, 21);
this.netAdapterComboBox.TabIndex = 11;
this.netAdapterComboBox.Size = new System.Drawing.Size(435, 21);
this.netAdapterComboBox.TabIndex = 8;
//
// connStr2TextBox
//
this.connStr2TextBox.Enabled = false;
this.connStr2TextBox.Location = new System.Drawing.Point(8, 118);
this.connStr2TextBox.Name = "connStr2TextBox";
this.connStr2TextBox.Size = new System.Drawing.Size(434, 20);
this.connStr2TextBox.TabIndex = 6;
//
// connStr2Label
//
this.connStr2Label.AutoSize = true;
this.connStr2Label.Location = new System.Drawing.Point(5, 102);
this.connStr2Label.Name = "connStr2Label";
this.connStr2Label.Size = new System.Drawing.Size(101, 13);
this.connStr2Label.TabIndex = 5;
this.connStr2Label.Text = "Connection string 2:";
//
// TracingCfgCtrl
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.connStr2TextBox);
this.Controls.Add(this.connStr2Label);
this.Controls.Add(this.netAdapterComboBox);
this.Controls.Add(this.netAdapterLabel);
this.Controls.Add(this.saveTracingRecordsCheckBox);
@@ -138,7 +160,7 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
this.Controls.Add(this.nameLabel);
this.Controls.Add(this.classNameLabel);
this.Name = "TracingCfgCtrl";
this.Size = new System.Drawing.Size(450, 230);
this.Size = new System.Drawing.Size(450, 250);
this.Load += new System.EventHandler(this.WriterCfgCtrl_Load);
this.ResumeLayout(false);
this.PerformLayout();
@@ -156,5 +178,7 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
private System.Windows.Forms.CheckBox checkPreviousRecordsCheckBox;
private System.Windows.Forms.Label netAdapterLabel;
private System.Windows.Forms.ComboBox netAdapterComboBox;
private System.Windows.Forms.TextBox connStr2TextBox;
private System.Windows.Forms.Label connStr2Label;
}
}
@@ -1,193 +0,0 @@
///
/// Copyright (c) 2015 Sensus Metering Systems
///
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Drawing.Printing;
using System.IO;
using Config.Entities;
using TBF.Resources;
namespace TBF.BenchControl.Output.Printers.Label
{
public class PrintLabelDocument : PrintDocument
{
const int FontSize = 9;
const string FontFamilyName = "Arial"; //"Times New Roman";
readonly int paperWidth;
readonly int paperHeight;
readonly string templateFile;
/// <summary> Property variable for the Font the user wishes to use </summary>
Font font;
///
/// Data to print
///
Results.Entities.Batch batch;
///
/// Layout and status
///
int nextWMNr; /// nr. of watermeter to be printed as the first one on the next page
int nrPages;
/// <summary>
/// Constructor
/// </summary>
/// <param name="textToPrint">Text to be printed</param>
public PrintLabelDocument(Results.Entities.Batch batch,
PageOrientation pageOrientation,
int paperWidth,
int paperHeight,
string templateFile)
{
this.batch = batch;
this.paperWidth = paperWidth;
this.paperHeight = paperHeight;
this.templateFile = templateFile;
DefaultPageSettings.Landscape = (pageOrientation == PageOrientation.Landscape);
/// Set print area size and margins (in dots using 80 dpi)
int printHeight = base.DefaultPageSettings.PaperSize.Height - base.DefaultPageSettings.Margins.Top - base.DefaultPageSettings.Margins.Bottom;
int printWidth = base.DefaultPageSettings.PaperSize.Width - base.DefaultPageSettings.Margins.Left - base.DefaultPageSettings.Margins.Right;
int leftMargin = base.DefaultPageSettings.Margins.Left; /// X
int topMargin = base.DefaultPageSettings.Margins.Top; /// Y
/// Check if the user selected to print in Landscape mode
/// if they did then we need to swap height/width parameters
if (DefaultPageSettings.Landscape)
{
int tmp = printHeight;
printHeight = printWidth;
printWidth = tmp;
}
/// One watermeter per label/page
nrPages = batch.WaterMeters.Count;
nextWMNr = 0;
}
/// <summary>
/// Override the default onbeginPrint method of the PrintDocument Object
/// </summary>
/// <param name=e></param>
/// <remarks></remarks>
protected override void OnBeginPrint(System.Drawing.Printing.PrintEventArgs e)
{
base.OnBeginPrint(e);
if (font == null) { font = new Font(FontFamilyName, FontSize, FontStyle.Regular); }
}
/// <summary>
/// Override the default OnPrintPage method of the PrintDocument.
/// </summary>
/// <param name=e></param>
/// <remarks>This provides the print logic for our document</remarks>
protected override void OnPrintPage(System.Drawing.Printing.PrintPageEventArgs e)
{
/// Run base code
base.OnPrintPage(e);
if (File.Exists(templateFile))
{
Image img = Image.FromFile(templateFile);
e.Graphics.DrawImage(new Bitmap(img), new Rectangle(0, 0, paperWidth, paperHeight));
}
/// Set print area size and margins (in dots using 80 dpi)
int printHeight = base.DefaultPageSettings.PaperSize.Height - base.DefaultPageSettings.Margins.Top - base.DefaultPageSettings.Margins.Bottom;
int printWidth = base.DefaultPageSettings.PaperSize.Width - base.DefaultPageSettings.Margins.Left - base.DefaultPageSettings.Margins.Right;
int leftMargin = base.DefaultPageSettings.Margins.Left; /// X
int topMargin = base.DefaultPageSettings.Margins.Top; /// Y
/// Check if the user selected to print in Landscape mode
/// if they did then we need to swap height/width parameters
if (base.DefaultPageSettings.Landscape)
{
int tmp = printHeight;
printHeight = printWidth;
printWidth = tmp;
}
int x = leftMargin;
int y = topMargin;
/// Use the StringFormat class for the text layout of our document
StringFormat format = new StringFormat(StringFormatFlags.LineLimit);
///--------
/// Body
///--------
PrintWM(e, nextWMNr);
nextWMNr++;
e.HasMorePages = (nextWMNr < batch.WaterMeters.Count);
}
/// <summary>
/// Print one water meter results
/// </summary>
/// <param name="wmNr">Water meter number (0-based)</param>
void PrintWM(System.Drawing.Printing.PrintPageEventArgs e, int wmNr)
{
if (wmNr >= batch.WaterMeters.Count) return;
Results.Entities.WaterMeter wm = batch.WaterMeters[wmNr];
if (wm == null) return;
/// Serial number
if (!string.IsNullOrEmpty(wm.SerialNr)) PrintAt(e, 20, 62, string.Format("S/N: {0}", wm.SerialNr));
/// Watermeter type
PrintAt(e, 20, 74, batch.ProtocolTitle);
/// Date
PrintAt(e, 135, 74, string.Format("{0:dd/MM/yy", batch.EndTime));
Results.WMeterRsltItemSpec item1 = Results.WMeterRsltItemSpec.GetItem(Results.ItemID.Test_name);
Results.WMeterRsltItemSpec item2 = Results.WMeterRsltItemSpec.GetItem(Results.ItemID.Error);
item2.Units = Config.Unit.Pct;
item2.Precision = "F2";
item2.Format = "{0}%";
int printPosition = 1;
foreach (var mtr in wm.MeterTestRslts)
{
item1.TestID = mtr.Name();
item2.TestID = mtr.Name();
PrintAt(e, 20, 6 + 14 * printPosition, item1.Print(wm));
PrintAt(e, 78, 6 + 14 * printPosition, item2.Print(wm));
printPosition++;
}
}
void PrintAt(System.Drawing.Printing.PrintPageEventArgs e, Point p, string text)
{
PrintAt(e, p.X, p.Y, text);
}
void PrintAt(System.Drawing.Printing.PrintPageEventArgs e, int x, int y, string text)
{
RectangleF printArea = new RectangleF(x, y, 667, 18);
e.Graphics.DrawString(text, this.font, Brushes.Black, printArea);
}
}
}
@@ -76,6 +76,12 @@ namespace TBF.BenchControl.Output.Printers.Label
printerCfg.NrOfCopies = newCfg.NrOfCopies;
printerCfg.GoodOnly = newCfg.GoodOnly;
printerCfg.SupressPrinting = newCfg.SupressPrinting;
printerCfg.DrawSNasBarcode = newCfg.DrawSNasBarcode;
printerCfg.IsQR = newCfg.IsQR;
printerCfg.BarcodeLeft = newCfg.BarcodeLeft;
printerCfg.BarcodeTop = newCfg.BarcodeTop;
printerCfg.BarcodeWidth = newCfg.BarcodeWidth;
printerCfg.BarcodeHeight = newCfg.BarcodeHeight;
ApplyConfig();
}
@@ -131,7 +137,6 @@ namespace TBF.BenchControl.Output.Printers.Label
}
void PrintResults(Results.Entities.Batch batch, Results.Entities.WaterMeter wm, string documentName)
{
LabelPrinterCfg cfg = new LabelPrinterCfg
@@ -147,6 +152,12 @@ namespace TBF.BenchControl.Output.Printers.Label
CultureInfo = (printerCfg.Culture == Culture.system) ? Thread.CurrentThread.CurrentCulture : new CultureInfo(printerCfg.Culture.ToString()),
GoodOnly = printerCfg.GoodOnly,
SupressPrinting = printerCfg.SupressPrinting,
DrawSNasBarcode = printerCfg.DrawSNasBarcode,
IsQR = printerCfg.IsQR,
BarcodeLeft = printerCfg.BarcodeLeft,
BarcodeTop = printerCfg.BarcodeTop,
BarcodeWidth = printerCfg.BarcodeWidth,
BarcodeHeight = printerCfg.BarcodeHeight,
};
for (int i = 1; i <= printerCfg.NrOfCopies; i++)
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2015-2018 Sensus Slovensko a.s.
/// Copyright (c) 2015-2020 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
@@ -33,6 +33,14 @@ namespace TBF.BenchControl.Output.Printers.Label
public bool GoodOnly;
public bool SupressPrinting; /// true = Bypass printing
public bool DrawSNasBarcode;
public bool IsQR;
public int BarcodeLeft;
public int BarcodeTop;
public int BarcodeWidth;
public int BarcodeHeight;
/// Private parameterless constructor invoked by all other (public) constructors
PrinterCfg()
{
@@ -55,18 +63,20 @@ namespace TBF.BenchControl.Output.Printers.Label
NrOfCopies = 1;
GoodOnly = false;
SupressPrinting = false;
DrawSNasBarcode = false;
}
public string ToString(int i)
{
return string.Format("Name={0}, Orientation={1}, PaperWidth={2}, PaperHeight={3}, TemplateFile={4}, GoodOnly={5}, SupressPrinting={6}",
return string.Format("Name={0}, Orientation={1}, PaperWidth={2}, PaperHeight={3}, TemplateFile={4}, GoodOnly={5}, SupressPrinting={6}, Barcode={7}",
Name,
PageOrientation,
PaperWidth,
PaperHeight,
Template,
GoodOnly ? "yes" : "no",
SupressPrinting ? "yes" : "no"
SupressPrinting ? "yes" : "no",
DrawSNasBarcode ? "yes" : "no"
);
}
}
+413 -292
View File
@@ -31,296 +31,407 @@ namespace TBF.BenchControl.Output.Printers.Label
/// </summary>
private void InitializeComponent()
{
this.nameTextBox = new System.Windows.Forms.TextBox();
this.nameLabel = new System.Windows.Forms.Label();
this.classNameLabel = new System.Windows.Forms.Label();
this.supressPrintingCheckBox = new System.Windows.Forms.CheckBox();
this.orientationLabel = new System.Windows.Forms.Label();
this.orientationComboBox = new System.Windows.Forms.ComboBox();
this.templateTextBox = new System.Windows.Forms.TextBox();
this.templateLabel = new System.Windows.Forms.Label();
this.paperWidthTextBox = new System.Windows.Forms.TextBox();
this.paperWidthLabel = new System.Windows.Forms.Label();
this.paperHeightTextBox = new System.Windows.Forms.TextBox();
this.paperHeightLabel = new System.Windows.Forms.Label();
this.italicCheckBox = new System.Windows.Forms.CheckBox();
this.boldCheckBox = new System.Windows.Forms.CheckBox();
this.fontSizeTextBox = new System.Windows.Forms.TextBox();
this.fontFamilyComboBox = new System.Windows.Forms.ComboBox();
this.bodyFontLabel = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.label1 = new System.Windows.Forms.Label();
this.itemsToPrintButton = new System.Windows.Forms.Button();
this.nrOfCopiesLabel = new System.Windows.Forms.Label();
this.nrOfCopiesTextBox = new System.Windows.Forms.TextBox();
this.cultureComboBox = new System.Windows.Forms.ComboBox();
this.cultureLabel = new System.Windows.Forms.Label();
this.goodOnlyCheckBox = new System.Windows.Forms.CheckBox();
this.SuspendLayout();
//
// nameTextBox
//
this.nameTextBox.Enabled = false;
this.nameTextBox.Location = new System.Drawing.Point(122, 35);
this.nameTextBox.Name = "nameTextBox";
this.nameTextBox.Size = new System.Drawing.Size(130, 20);
this.nameTextBox.TabIndex = 2;
//
// nameLabel
//
this.nameLabel.AutoSize = true;
this.nameLabel.Location = new System.Drawing.Point(8, 38);
this.nameLabel.Name = "nameLabel";
this.nameLabel.Size = new System.Drawing.Size(35, 13);
this.nameLabel.TabIndex = 1;
this.nameLabel.Text = "Name";
//
// classNameLabel
//
this.classNameLabel.AutoSize = true;
this.classNameLabel.Location = new System.Drawing.Point(119, 11);
this.classNameLabel.Name = "classNameLabel";
this.classNameLabel.Size = new System.Drawing.Size(61, 13);
this.classNameLabel.TabIndex = 0;
this.classNameLabel.Text = "Class name";
//
// supressPrintingCheckBox
//
this.supressPrintingCheckBox.AutoSize = true;
this.supressPrintingCheckBox.Enabled = false;
this.supressPrintingCheckBox.Location = new System.Drawing.Point(122, 283);
this.supressPrintingCheckBox.Name = "supressPrintingCheckBox";
this.supressPrintingCheckBox.Size = new System.Drawing.Size(101, 17);
this.supressPrintingCheckBox.TabIndex = 11;
this.supressPrintingCheckBox.Text = "Supress printing";
this.supressPrintingCheckBox.UseVisualStyleBackColor = true;
//
// orientationLabel
//
this.orientationLabel.AutoSize = true;
this.orientationLabel.Location = new System.Drawing.Point(8, 84);
this.orientationLabel.Name = "orientationLabel";
this.orientationLabel.Size = new System.Drawing.Size(84, 13);
this.orientationLabel.TabIndex = 3;
this.orientationLabel.Text = "Page orientation";
//
// orientationComboBox
//
this.orientationComboBox.Enabled = false;
this.orientationComboBox.FormattingEnabled = true;
this.orientationComboBox.Location = new System.Drawing.Point(122, 81);
this.orientationComboBox.Name = "orientationComboBox";
this.orientationComboBox.Size = new System.Drawing.Size(130, 21);
this.orientationComboBox.TabIndex = 4;
//
// templateTextBox
//
this.templateTextBox.Enabled = false;
this.templateTextBox.Location = new System.Drawing.Point(122, 58);
this.templateTextBox.Name = "templateTextBox";
this.templateTextBox.Size = new System.Drawing.Size(228, 20);
this.templateTextBox.TabIndex = 10;
//
// templateLabel
//
this.templateLabel.AutoSize = true;
this.templateLabel.Location = new System.Drawing.Point(8, 61);
this.templateLabel.Name = "templateLabel";
this.templateLabel.Size = new System.Drawing.Size(67, 13);
this.templateLabel.TabIndex = 9;
this.templateLabel.Text = "Template file";
//
// paperWidthTextBox
//
this.paperWidthTextBox.Enabled = false;
this.paperWidthTextBox.Location = new System.Drawing.Point(122, 105);
this.paperWidthTextBox.Name = "paperWidthTextBox";
this.paperWidthTextBox.Size = new System.Drawing.Size(51, 20);
this.paperWidthTextBox.TabIndex = 6;
//
// paperWidthLabel
//
this.paperWidthLabel.AutoSize = true;
this.paperWidthLabel.Location = new System.Drawing.Point(8, 108);
this.paperWidthLabel.Name = "paperWidthLabel";
this.paperWidthLabel.Size = new System.Drawing.Size(63, 13);
this.paperWidthLabel.TabIndex = 5;
this.paperWidthLabel.Text = "Paper width";
//
// paperHeightTextBox
//
this.paperHeightTextBox.Enabled = false;
this.paperHeightTextBox.Location = new System.Drawing.Point(122, 128);
this.paperHeightTextBox.Name = "paperHeightTextBox";
this.paperHeightTextBox.Size = new System.Drawing.Size(51, 20);
this.paperHeightTextBox.TabIndex = 8;
//
// paperHeightLabel
//
this.paperHeightLabel.AutoSize = true;
this.paperHeightLabel.Location = new System.Drawing.Point(8, 131);
this.paperHeightLabel.Name = "paperHeightLabel";
this.paperHeightLabel.Size = new System.Drawing.Size(67, 13);
this.paperHeightLabel.TabIndex = 7;
this.paperHeightLabel.Text = "Paper height";
//
// bodyItalicCheckBox
//
this.italicCheckBox.AutoSize = true;
this.italicCheckBox.Enabled = false;
this.italicCheckBox.Location = new System.Drawing.Point(335, 190);
this.italicCheckBox.Name = "bodyItalicCheckBox";
this.italicCheckBox.Size = new System.Drawing.Size(15, 14);
this.italicCheckBox.TabIndex = 47;
this.italicCheckBox.UseVisualStyleBackColor = true;
//
// bodyBoldCheckBox
//
this.boldCheckBox.AutoSize = true;
this.boldCheckBox.Enabled = false;
this.boldCheckBox.Location = new System.Drawing.Point(307, 190);
this.boldCheckBox.Name = "bodyBoldCheckBox";
this.boldCheckBox.Size = new System.Drawing.Size(15, 14);
this.boldCheckBox.TabIndex = 46;
this.boldCheckBox.UseVisualStyleBackColor = true;
//
// bodyFontSizeTextBox
//
this.fontSizeTextBox.Enabled = false;
this.fontSizeTextBox.Location = new System.Drawing.Point(259, 184);
this.fontSizeTextBox.Name = "bodyFontSizeTextBox";
this.fontSizeTextBox.Size = new System.Drawing.Size(29, 20);
this.fontSizeTextBox.TabIndex = 45;
//
// bodyFontFamilyComboBox
//
this.fontFamilyComboBox.Enabled = false;
this.fontFamilyComboBox.FormattingEnabled = true;
this.fontFamilyComboBox.Location = new System.Drawing.Point(122, 184);
this.fontFamilyComboBox.Name = "bodyFontFamilyComboBox";
this.fontFamilyComboBox.Size = new System.Drawing.Size(130, 21);
this.fontFamilyComboBox.TabIndex = 44;
//
// bodyFontLabel
//
this.bodyFontLabel.AutoSize = true;
this.bodyFontLabel.Location = new System.Drawing.Point(8, 187);
this.bodyFontLabel.Name = "bodyFontLabel";
this.bodyFontLabel.Size = new System.Drawing.Size(106, 13);
this.bodyFontLabel.TabIndex = 43;
this.bodyFontLabel.Text = "Font family/size/style";
//
// label2
//
this.label2.AutoSize = true;
this.label2.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Point, ((byte)(238)));
this.label2.Location = new System.Drawing.Point(331, 175);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(24, 13);
this.label2.TabIndex = 49;
this.label2.Text = "Ital.";
//
// label1
//
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(238)));
this.label1.Location = new System.Drawing.Point(297, 175);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(32, 13);
this.label1.TabIndex = 48;
this.label1.Text = "Bold";
//
// itemsToPrintButton
//
this.itemsToPrintButton.Enabled = false;
this.itemsToPrintButton.Location = new System.Drawing.Point(121, 154);
this.itemsToPrintButton.Name = "itemsToPrintButton";
this.itemsToPrintButton.Size = new System.Drawing.Size(132, 23);
this.itemsToPrintButton.TabIndex = 50;
this.itemsToPrintButton.Text = "Items to print";
this.itemsToPrintButton.UseVisualStyleBackColor = true;
this.itemsToPrintButton.Click += new System.EventHandler(this.itemsToPrintButton_Click);
//
// nrOfCopiesLabel
//
this.nrOfCopiesLabel.AutoSize = true;
this.nrOfCopiesLabel.Location = new System.Drawing.Point(8, 235);
this.nrOfCopiesLabel.Name = "nrOfCopiesLabel";
this.nrOfCopiesLabel.Size = new System.Drawing.Size(90, 13);
this.nrOfCopiesLabel.TabIndex = 52;
this.nrOfCopiesLabel.Text = "Number of copies";
//
// nrOfCopiesTextBox
//
this.nrOfCopiesTextBox.Enabled = false;
this.nrOfCopiesTextBox.Location = new System.Drawing.Point(122, 232);
this.nrOfCopiesTextBox.Name = "nrOfCopiesTextBox";
this.nrOfCopiesTextBox.Size = new System.Drawing.Size(51, 20);
this.nrOfCopiesTextBox.TabIndex = 51;
//
// cultureComboBox
//
this.cultureComboBox.Enabled = false;
this.cultureComboBox.FormattingEnabled = true;
this.cultureComboBox.Location = new System.Drawing.Point(122, 208);
this.cultureComboBox.Name = "cultureComboBox";
this.cultureComboBox.Size = new System.Drawing.Size(218, 21);
this.cultureComboBox.TabIndex = 54;
//
// cultureLabel
//
this.cultureLabel.AutoSize = true;
this.cultureLabel.Location = new System.Drawing.Point(8, 211);
this.cultureLabel.Name = "cultureLabel";
this.cultureLabel.Size = new System.Drawing.Size(42, 13);
this.cultureLabel.TabIndex = 53;
this.cultureLabel.Text = "Cullture";
//
// goodOnlyCheckBox
//
this.goodOnlyCheckBox.AutoSize = true;
this.goodOnlyCheckBox.Enabled = false;
this.goodOnlyCheckBox.Location = new System.Drawing.Point(122, 262);
this.goodOnlyCheckBox.Name = "goodOnlyCheckBox";
this.goodOnlyCheckBox.Size = new System.Drawing.Size(74, 17);
this.goodOnlyCheckBox.TabIndex = 55;
this.goodOnlyCheckBox.Text = "Good only";
this.goodOnlyCheckBox.UseVisualStyleBackColor = true;
//
// PrinterCfgCtrl
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.goodOnlyCheckBox);
this.Controls.Add(this.cultureComboBox);
this.Controls.Add(this.cultureLabel);
this.Controls.Add(this.nrOfCopiesLabel);
this.Controls.Add(this.nrOfCopiesTextBox);
this.Controls.Add(this.itemsToPrintButton);
this.Controls.Add(this.italicCheckBox);
this.Controls.Add(this.boldCheckBox);
this.Controls.Add(this.fontSizeTextBox);
this.Controls.Add(this.fontFamilyComboBox);
this.Controls.Add(this.bodyFontLabel);
this.Controls.Add(this.label2);
this.Controls.Add(this.label1);
this.Controls.Add(this.paperHeightTextBox);
this.Controls.Add(this.paperHeightLabel);
this.Controls.Add(this.paperWidthTextBox);
this.Controls.Add(this.paperWidthLabel);
this.Controls.Add(this.templateTextBox);
this.Controls.Add(this.templateLabel);
this.Controls.Add(this.orientationComboBox);
this.Controls.Add(this.orientationLabel);
this.Controls.Add(this.supressPrintingCheckBox);
this.Controls.Add(this.nameTextBox);
this.Controls.Add(this.nameLabel);
this.Controls.Add(this.classNameLabel);
this.Name = "PrinterCfgCtrl";
this.Size = new System.Drawing.Size(372, 327);
this.Load += new System.EventHandler(this.PrinterCfgCtrl_Load);
this.ResumeLayout(false);
this.PerformLayout();
this.nameTextBox = new System.Windows.Forms.TextBox();
this.nameLabel = new System.Windows.Forms.Label();
this.classNameLabel = new System.Windows.Forms.Label();
this.supressPrintingCheckBox = new System.Windows.Forms.CheckBox();
this.orientationLabel = new System.Windows.Forms.Label();
this.orientationComboBox = new System.Windows.Forms.ComboBox();
this.templateTextBox = new System.Windows.Forms.TextBox();
this.templateLabel = new System.Windows.Forms.Label();
this.paperWidthTextBox = new System.Windows.Forms.TextBox();
this.paperWidthLabel = new System.Windows.Forms.Label();
this.paperHeightTextBox = new System.Windows.Forms.TextBox();
this.italicCheckBox = new System.Windows.Forms.CheckBox();
this.boldCheckBox = new System.Windows.Forms.CheckBox();
this.fontSizeTextBox = new System.Windows.Forms.TextBox();
this.fontFamilyComboBox = new System.Windows.Forms.ComboBox();
this.bodyFontLabel = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.label1 = new System.Windows.Forms.Label();
this.itemsToPrintButton = new System.Windows.Forms.Button();
this.nrOfCopiesLabel = new System.Windows.Forms.Label();
this.nrOfCopiesTextBox = new System.Windows.Forms.TextBox();
this.cultureComboBox = new System.Windows.Forms.ComboBox();
this.cultureLabel = new System.Windows.Forms.Label();
this.goodOnlyCheckBox = new System.Windows.Forms.CheckBox();
this.snBarcodeGroupBox = new System.Windows.Forms.GroupBox();
this.barcodeHeightLabel = new System.Windows.Forms.Label();
this.barcodeHeightTextBox = new System.Windows.Forms.TextBox();
this.isQrCheckBox = new System.Windows.Forms.CheckBox();
this.barcodeWidthLabel = new System.Windows.Forms.Label();
this.barcodeWidthTextBox = new System.Windows.Forms.TextBox();
this.barcodeTopLabel = new System.Windows.Forms.Label();
this.barcodeTopTextBox = new System.Windows.Forms.TextBox();
this.barcodeLeftTextBox = new System.Windows.Forms.TextBox();
this.barcodeLeftLabel = new System.Windows.Forms.Label();
this.snBarcodeCheckBox = new System.Windows.Forms.CheckBox();
this.snBarcodeGroupBox.SuspendLayout();
this.SuspendLayout();
//
// nameTextBox
//
this.nameTextBox.Enabled = false;
this.nameTextBox.Location = new System.Drawing.Point(122, 35);
this.nameTextBox.Name = "nameTextBox";
this.nameTextBox.Size = new System.Drawing.Size(130, 20);
this.nameTextBox.TabIndex = 2;
//
// nameLabel
//
this.nameLabel.AutoSize = true;
this.nameLabel.Location = new System.Drawing.Point(8, 38);
this.nameLabel.Name = "nameLabel";
this.nameLabel.Size = new System.Drawing.Size(35, 13);
this.nameLabel.TabIndex = 1;
this.nameLabel.Text = "Name";
//
// classNameLabel
//
this.classNameLabel.AutoSize = true;
this.classNameLabel.Location = new System.Drawing.Point(119, 11);
this.classNameLabel.Name = "classNameLabel";
this.classNameLabel.Size = new System.Drawing.Size(61, 13);
this.classNameLabel.TabIndex = 0;
this.classNameLabel.Text = "Class name";
//
// supressPrintingCheckBox
//
this.supressPrintingCheckBox.AutoSize = true;
this.supressPrintingCheckBox.Enabled = false;
this.supressPrintingCheckBox.Location = new System.Drawing.Point(245, 200);
this.supressPrintingCheckBox.Name = "supressPrintingCheckBox";
this.supressPrintingCheckBox.Size = new System.Drawing.Size(101, 17);
this.supressPrintingCheckBox.TabIndex = 11;
this.supressPrintingCheckBox.Text = "Supress printing";
this.supressPrintingCheckBox.UseVisualStyleBackColor = true;
//
// orientationLabel
//
this.orientationLabel.AutoSize = true;
this.orientationLabel.Location = new System.Drawing.Point(8, 84);
this.orientationLabel.Name = "orientationLabel";
this.orientationLabel.Size = new System.Drawing.Size(84, 13);
this.orientationLabel.TabIndex = 3;
this.orientationLabel.Text = "Page orientation";
//
// orientationComboBox
//
this.orientationComboBox.Enabled = false;
this.orientationComboBox.FormattingEnabled = true;
this.orientationComboBox.Location = new System.Drawing.Point(122, 81);
this.orientationComboBox.Name = "orientationComboBox";
this.orientationComboBox.Size = new System.Drawing.Size(130, 21);
this.orientationComboBox.TabIndex = 4;
//
// templateTextBox
//
this.templateTextBox.Enabled = false;
this.templateTextBox.Location = new System.Drawing.Point(122, 58);
this.templateTextBox.Name = "templateTextBox";
this.templateTextBox.Size = new System.Drawing.Size(228, 20);
this.templateTextBox.TabIndex = 10;
//
// templateLabel
//
this.templateLabel.AutoSize = true;
this.templateLabel.Location = new System.Drawing.Point(8, 61);
this.templateLabel.Name = "templateLabel";
this.templateLabel.Size = new System.Drawing.Size(67, 13);
this.templateLabel.TabIndex = 9;
this.templateLabel.Text = "Template file";
//
// paperWidthTextBox
//
this.paperWidthTextBox.Enabled = false;
this.paperWidthTextBox.Location = new System.Drawing.Point(122, 105);
this.paperWidthTextBox.Name = "paperWidthTextBox";
this.paperWidthTextBox.Size = new System.Drawing.Size(51, 20);
this.paperWidthTextBox.TabIndex = 6;
//
// paperWidthLabel
//
this.paperWidthLabel.AutoSize = true;
this.paperWidthLabel.Location = new System.Drawing.Point(8, 108);
this.paperWidthLabel.Name = "paperWidthLabel";
this.paperWidthLabel.Size = new System.Drawing.Size(103, 13);
this.paperWidthLabel.TabIndex = 5;
this.paperWidthLabel.Text = "Paper width / height";
//
// paperHeightTextBox
//
this.paperHeightTextBox.Enabled = false;
this.paperHeightTextBox.Location = new System.Drawing.Point(176, 105);
this.paperHeightTextBox.Name = "paperHeightTextBox";
this.paperHeightTextBox.Size = new System.Drawing.Size(51, 20);
this.paperHeightTextBox.TabIndex = 8;
//
// italicCheckBox
//
this.italicCheckBox.AutoSize = true;
this.italicCheckBox.Enabled = false;
this.italicCheckBox.Location = new System.Drawing.Point(335, 134);
this.italicCheckBox.Name = "italicCheckBox";
this.italicCheckBox.Size = new System.Drawing.Size(15, 14);
this.italicCheckBox.TabIndex = 47;
this.italicCheckBox.UseVisualStyleBackColor = true;
//
// boldCheckBox
//
this.boldCheckBox.AutoSize = true;
this.boldCheckBox.Enabled = false;
this.boldCheckBox.Location = new System.Drawing.Point(307, 134);
this.boldCheckBox.Name = "boldCheckBox";
this.boldCheckBox.Size = new System.Drawing.Size(15, 14);
this.boldCheckBox.TabIndex = 46;
this.boldCheckBox.UseVisualStyleBackColor = true;
//
// fontSizeTextBox
//
this.fontSizeTextBox.Enabled = false;
this.fontSizeTextBox.Location = new System.Drawing.Point(259, 128);
this.fontSizeTextBox.Name = "fontSizeTextBox";
this.fontSizeTextBox.Size = new System.Drawing.Size(29, 20);
this.fontSizeTextBox.TabIndex = 45;
//
// fontFamilyComboBox
//
this.fontFamilyComboBox.Enabled = false;
this.fontFamilyComboBox.FormattingEnabled = true;
this.fontFamilyComboBox.Location = new System.Drawing.Point(122, 128);
this.fontFamilyComboBox.Name = "fontFamilyComboBox";
this.fontFamilyComboBox.Size = new System.Drawing.Size(130, 21);
this.fontFamilyComboBox.TabIndex = 44;
//
// bodyFontLabel
//
this.bodyFontLabel.AutoSize = true;
this.bodyFontLabel.Location = new System.Drawing.Point(8, 131);
this.bodyFontLabel.Name = "bodyFontLabel";
this.bodyFontLabel.Size = new System.Drawing.Size(106, 13);
this.bodyFontLabel.TabIndex = 43;
this.bodyFontLabel.Text = "Font family/size/style";
//
// label2
//
this.label2.AutoSize = true;
this.label2.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Point, ((byte)(238)));
this.label2.Location = new System.Drawing.Point(331, 119);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(24, 13);
this.label2.TabIndex = 49;
this.label2.Text = "Ital.";
//
// label1
//
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(238)));
this.label1.Location = new System.Drawing.Point(297, 119);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(32, 13);
this.label1.TabIndex = 48;
this.label1.Text = "Bold";
//
// itemsToPrintButton
//
this.itemsToPrintButton.Enabled = false;
this.itemsToPrintButton.Location = new System.Drawing.Point(259, 85);
this.itemsToPrintButton.Name = "itemsToPrintButton";
this.itemsToPrintButton.Size = new System.Drawing.Size(91, 30);
this.itemsToPrintButton.TabIndex = 50;
this.itemsToPrintButton.Text = "Items to print";
this.itemsToPrintButton.UseVisualStyleBackColor = true;
this.itemsToPrintButton.Click += new System.EventHandler(this.itemsToPrintButton_Click);
//
// nrOfCopiesLabel
//
this.nrOfCopiesLabel.AutoSize = true;
this.nrOfCopiesLabel.Location = new System.Drawing.Point(8, 179);
this.nrOfCopiesLabel.Name = "nrOfCopiesLabel";
this.nrOfCopiesLabel.Size = new System.Drawing.Size(90, 13);
this.nrOfCopiesLabel.TabIndex = 52;
this.nrOfCopiesLabel.Text = "Number of copies";
//
// nrOfCopiesTextBox
//
this.nrOfCopiesTextBox.Enabled = false;
this.nrOfCopiesTextBox.Location = new System.Drawing.Point(122, 176);
this.nrOfCopiesTextBox.Name = "nrOfCopiesTextBox";
this.nrOfCopiesTextBox.Size = new System.Drawing.Size(51, 20);
this.nrOfCopiesTextBox.TabIndex = 51;
//
// cultureComboBox
//
this.cultureComboBox.Enabled = false;
this.cultureComboBox.FormattingEnabled = true;
this.cultureComboBox.Location = new System.Drawing.Point(122, 152);
this.cultureComboBox.Name = "cultureComboBox";
this.cultureComboBox.Size = new System.Drawing.Size(228, 21);
this.cultureComboBox.TabIndex = 54;
//
// cultureLabel
//
this.cultureLabel.AutoSize = true;
this.cultureLabel.Location = new System.Drawing.Point(8, 155);
this.cultureLabel.Name = "cultureLabel";
this.cultureLabel.Size = new System.Drawing.Size(42, 13);
this.cultureLabel.TabIndex = 53;
this.cultureLabel.Text = "Cullture";
//
// goodOnlyCheckBox
//
this.goodOnlyCheckBox.AutoSize = true;
this.goodOnlyCheckBox.Enabled = false;
this.goodOnlyCheckBox.Location = new System.Drawing.Point(245, 179);
this.goodOnlyCheckBox.Name = "goodOnlyCheckBox";
this.goodOnlyCheckBox.Size = new System.Drawing.Size(74, 17);
this.goodOnlyCheckBox.TabIndex = 55;
this.goodOnlyCheckBox.Text = "Good only";
this.goodOnlyCheckBox.UseVisualStyleBackColor = true;
//
// snBarcodeGroupBox
//
this.snBarcodeGroupBox.Controls.Add(this.barcodeHeightLabel);
this.snBarcodeGroupBox.Controls.Add(this.barcodeHeightTextBox);
this.snBarcodeGroupBox.Controls.Add(this.isQrCheckBox);
this.snBarcodeGroupBox.Controls.Add(this.barcodeWidthLabel);
this.snBarcodeGroupBox.Controls.Add(this.barcodeWidthTextBox);
this.snBarcodeGroupBox.Controls.Add(this.barcodeTopLabel);
this.snBarcodeGroupBox.Controls.Add(this.barcodeTopTextBox);
this.snBarcodeGroupBox.Controls.Add(this.barcodeLeftTextBox);
this.snBarcodeGroupBox.Controls.Add(this.barcodeLeftLabel);
this.snBarcodeGroupBox.Controls.Add(this.snBarcodeCheckBox);
this.snBarcodeGroupBox.Location = new System.Drawing.Point(11, 227);
this.snBarcodeGroupBox.Name = "snBarcodeGroupBox";
this.snBarcodeGroupBox.Size = new System.Drawing.Size(339, 59);
this.snBarcodeGroupBox.TabIndex = 56;
this.snBarcodeGroupBox.TabStop = false;
//
// barcodeHeightLabel
//
this.barcodeHeightLabel.AutoSize = true;
this.barcodeHeightLabel.Location = new System.Drawing.Point(207, 29);
this.barcodeHeightLabel.Name = "barcodeHeightLabel";
this.barcodeHeightLabel.Size = new System.Drawing.Size(38, 13);
this.barcodeHeightLabel.TabIndex = 18;
this.barcodeHeightLabel.Text = "Height";
//
// barcodeHeightTextBox
//
this.barcodeHeightTextBox.Enabled = false;
this.barcodeHeightTextBox.Location = new System.Drawing.Point(247, 25);
this.barcodeHeightTextBox.Name = "barcodeHeightTextBox";
this.barcodeHeightTextBox.Size = new System.Drawing.Size(32, 20);
this.barcodeHeightTextBox.TabIndex = 17;
//
// isQrCheckBox
//
this.isQrCheckBox.AutoSize = true;
this.isQrCheckBox.Location = new System.Drawing.Point(293, 27);
this.isQrCheckBox.Name = "isQrCheckBox";
this.isQrCheckBox.Size = new System.Drawing.Size(42, 17);
this.isQrCheckBox.TabIndex = 16;
this.isQrCheckBox.Text = "QR";
this.isQrCheckBox.UseVisualStyleBackColor = true;
//
// barcodeWidthLabel
//
this.barcodeWidthLabel.AutoSize = true;
this.barcodeWidthLabel.Location = new System.Drawing.Point(135, 29);
this.barcodeWidthLabel.Name = "barcodeWidthLabel";
this.barcodeWidthLabel.Size = new System.Drawing.Size(35, 13);
this.barcodeWidthLabel.TabIndex = 15;
this.barcodeWidthLabel.Text = "Width";
//
// barcodeWidthTextBox
//
this.barcodeWidthTextBox.Enabled = false;
this.barcodeWidthTextBox.Location = new System.Drawing.Point(171, 25);
this.barcodeWidthTextBox.Name = "barcodeWidthTextBox";
this.barcodeWidthTextBox.Size = new System.Drawing.Size(32, 20);
this.barcodeWidthTextBox.TabIndex = 14;
//
// barcodeTopLabel
//
this.barcodeTopLabel.AutoSize = true;
this.barcodeTopLabel.Location = new System.Drawing.Point(71, 29);
this.barcodeTopLabel.Name = "barcodeTopLabel";
this.barcodeTopLabel.Size = new System.Drawing.Size(26, 13);
this.barcodeTopLabel.TabIndex = 13;
this.barcodeTopLabel.Text = "Top";
//
// barcodeTopTextBox
//
this.barcodeTopTextBox.Enabled = false;
this.barcodeTopTextBox.Location = new System.Drawing.Point(99, 25);
this.barcodeTopTextBox.Name = "barcodeTopTextBox";
this.barcodeTopTextBox.Size = new System.Drawing.Size(32, 20);
this.barcodeTopTextBox.TabIndex = 11;
//
// barcodeLeftTextBox
//
this.barcodeLeftTextBox.Enabled = false;
this.barcodeLeftTextBox.Location = new System.Drawing.Point(35, 25);
this.barcodeLeftTextBox.Name = "barcodeLeftTextBox";
this.barcodeLeftTextBox.Size = new System.Drawing.Size(32, 20);
this.barcodeLeftTextBox.TabIndex = 10;
//
// barcodeLeftLabel
//
this.barcodeLeftLabel.AutoSize = true;
this.barcodeLeftLabel.Location = new System.Drawing.Point(8, 29);
this.barcodeLeftLabel.Name = "barcodeLeftLabel";
this.barcodeLeftLabel.Size = new System.Drawing.Size(25, 13);
this.barcodeLeftLabel.TabIndex = 9;
this.barcodeLeftLabel.Text = "Left";
//
// snBarcodeCheckBox
//
this.snBarcodeCheckBox.AutoSize = true;
this.snBarcodeCheckBox.Location = new System.Drawing.Point(10, 0);
this.snBarcodeCheckBox.Name = "snBarcodeCheckBox";
this.snBarcodeCheckBox.Size = new System.Drawing.Size(176, 17);
this.snBarcodeCheckBox.TabIndex = 0;
this.snBarcodeCheckBox.Text = "Print barcode with serial number";
this.snBarcodeCheckBox.UseVisualStyleBackColor = true;
this.snBarcodeCheckBox.CheckedChanged += new System.EventHandler(this.snBarcodeCheckBox_CheckedChanged);
//
// PrinterCfgCtrl
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.snBarcodeGroupBox);
this.Controls.Add(this.goodOnlyCheckBox);
this.Controls.Add(this.cultureComboBox);
this.Controls.Add(this.cultureLabel);
this.Controls.Add(this.nrOfCopiesLabel);
this.Controls.Add(this.nrOfCopiesTextBox);
this.Controls.Add(this.itemsToPrintButton);
this.Controls.Add(this.italicCheckBox);
this.Controls.Add(this.boldCheckBox);
this.Controls.Add(this.fontSizeTextBox);
this.Controls.Add(this.fontFamilyComboBox);
this.Controls.Add(this.bodyFontLabel);
this.Controls.Add(this.label2);
this.Controls.Add(this.label1);
this.Controls.Add(this.paperHeightTextBox);
this.Controls.Add(this.paperWidthTextBox);
this.Controls.Add(this.paperWidthLabel);
this.Controls.Add(this.templateTextBox);
this.Controls.Add(this.templateLabel);
this.Controls.Add(this.orientationComboBox);
this.Controls.Add(this.orientationLabel);
this.Controls.Add(this.supressPrintingCheckBox);
this.Controls.Add(this.nameTextBox);
this.Controls.Add(this.nameLabel);
this.Controls.Add(this.classNameLabel);
this.Name = "PrinterCfgCtrl";
this.Size = new System.Drawing.Size(372, 327);
this.Load += new System.EventHandler(this.PrinterCfgCtrl_Load);
this.snBarcodeGroupBox.ResumeLayout(false);
this.snBarcodeGroupBox.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
}
@@ -336,8 +447,7 @@ namespace TBF.BenchControl.Output.Printers.Label
private System.Windows.Forms.Label templateLabel;
private System.Windows.Forms.TextBox paperWidthTextBox;
private System.Windows.Forms.Label paperWidthLabel;
private System.Windows.Forms.TextBox paperHeightTextBox;
private System.Windows.Forms.Label paperHeightLabel;
private System.Windows.Forms.TextBox paperHeightTextBox;
private System.Windows.Forms.CheckBox italicCheckBox;
private System.Windows.Forms.CheckBox boldCheckBox;
private System.Windows.Forms.TextBox fontSizeTextBox;
@@ -351,5 +461,16 @@ namespace TBF.BenchControl.Output.Printers.Label
private System.Windows.Forms.ComboBox cultureComboBox;
private System.Windows.Forms.Label cultureLabel;
private System.Windows.Forms.CheckBox goodOnlyCheckBox;
private System.Windows.Forms.GroupBox snBarcodeGroupBox;
private System.Windows.Forms.TextBox barcodeTopTextBox;
private System.Windows.Forms.TextBox barcodeLeftTextBox;
private System.Windows.Forms.Label barcodeLeftLabel;
private System.Windows.Forms.CheckBox snBarcodeCheckBox;
private System.Windows.Forms.Label barcodeWidthLabel;
private System.Windows.Forms.TextBox barcodeWidthTextBox;
private System.Windows.Forms.Label barcodeTopLabel;
private System.Windows.Forms.CheckBox isQrCheckBox;
private System.Windows.Forms.Label barcodeHeightLabel;
private System.Windows.Forms.TextBox barcodeHeightTextBox;
}
}
@@ -1,7 +1,8 @@
///
/// Copyright (c) 2015-2018 Sensus Slovensko a.s.
/// Copyright (c) 2015-2020 Sensus Slovensko a.s.
///
using System;
using System.Drawing;
using System.IO;
using System.Windows.Forms;
using log4net;
@@ -42,7 +43,9 @@ namespace TBF.BenchControl.Output.Printers.Label
{
fontFamilyComboBox.Items.Add(ff.Name);
}
}
ManageCheckGroupBox(snBarcodeCheckBox, snBarcodeGroupBox);
}
private void PrinterCfgCtrl_Load(object sender, EventArgs e)
{
@@ -80,7 +83,14 @@ namespace TBF.BenchControl.Output.Printers.Label
nrOfCopiesTextBox.Text = config.NrOfCopies.ToString();
goodOnlyCheckBox.Checked = config.GoodOnly;
supressPrintingCheckBox.Checked = config.SupressPrinting;
}
snBarcodeCheckBox.Checked = config.DrawSNasBarcode;
isQrCheckBox.Checked = config.IsQR;
barcodeLeftTextBox.Text = config.BarcodeLeft.ToString();
barcodeTopTextBox.Text = config.BarcodeTop.ToString();
barcodeWidthTextBox.Text = config.BarcodeWidth.ToString();
barcodeHeightTextBox.Text = config.BarcodeHeight.ToString();
}
public void Unlock()
{
@@ -98,7 +108,20 @@ namespace TBF.BenchControl.Output.Printers.Label
nrOfCopiesTextBox.Enabled = true;
goodOnlyCheckBox.Enabled = true;
supressPrintingCheckBox.Enabled = true;
}
snBarcodeCheckBox.Enabled = true;
ManageCheckGroupBox(snBarcodeCheckBox, snBarcodeGroupBox);
isQrCheckBox.Enabled = true;
barcodeLeftTextBox.Enabled = true;
barcodeTopTextBox.Enabled = true;
barcodeWidthTextBox.Enabled = true;
barcodeHeightTextBox.Enabled = true;
}
private void snBarcodeCheckBox_CheckedChanged(object sender, EventArgs e)
{
ManageCheckGroupBox(snBarcodeCheckBox, snBarcodeGroupBox);
}
public CfgUpdateFlags VerifyCfg(ref string message)
{
@@ -142,6 +165,26 @@ namespace TBF.BenchControl.Output.Printers.Label
message += Environment.NewLine + "'Number of copies' should be between 0 and 9";
flags |= CfgUpdateFlags.Error;
}
if (!int.TryParse(barcodeLeftTextBox.Text, out dummy) || dummy < 0 || dummy > 2000)
{
message += Environment.NewLine + "Barcode 'Left' should be between 0 and 2000";
flags |= CfgUpdateFlags.Error;
}
if (!int.TryParse(barcodeTopTextBox.Text, out dummy) || dummy < 0 || dummy > 2000)
{
message += Environment.NewLine + "Barcode 'Top' should be between 0 and 2000";
flags |= CfgUpdateFlags.Error;
}
if (!int.TryParse(barcodeWidthTextBox.Text, out dummy) || dummy < 0 || dummy > 200)
{
message += Environment.NewLine + "Barcode 'Width' should be between 0 and 200";
flags |= CfgUpdateFlags.Error;
}
if (!int.TryParse(barcodeHeightTextBox.Text, out dummy) || dummy < 0 || dummy > 200)
{
message += Environment.NewLine + "Barcode 'Height' should be between 0 and 200";
flags |= CfgUpdateFlags.Error;
}
return flags;
}
@@ -193,6 +236,13 @@ namespace TBF.BenchControl.Output.Printers.Label
flags |= UpdateDifferent(ref config.GoodOnly, goodOnlyCheckBox.Checked, CfgUpdateFlags.InvokeCfgChange | CfgUpdateFlags.AnyChange);
flags |= UpdateDifferent(ref config.SupressPrinting, supressPrintingCheckBox.Checked, CfgUpdateFlags.InvokeCfgChange | CfgUpdateFlags.AnyChange);
flags |= UpdateDifferent(ref config.DrawSNasBarcode, snBarcodeCheckBox.Checked, CfgUpdateFlags.InvokeCfgChange | CfgUpdateFlags.AnyChange);
flags |= UpdateDifferent(ref config.IsQR, isQrCheckBox.Checked, CfgUpdateFlags.InvokeCfgChange | CfgUpdateFlags.AnyChange);
flags |= UpdateDifferent(ref config.BarcodeLeft, barcodeLeftTextBox.Text, CfgUpdateFlags.InvokeCfgChange | CfgUpdateFlags.AnyChange);
flags |= UpdateDifferent(ref config.BarcodeTop, barcodeTopTextBox.Text, CfgUpdateFlags.InvokeCfgChange | CfgUpdateFlags.AnyChange);
flags |= UpdateDifferent(ref config.BarcodeWidth, barcodeWidthTextBox.Text, CfgUpdateFlags.InvokeCfgChange | CfgUpdateFlags.AnyChange);
flags |= UpdateDifferent(ref config.BarcodeHeight, barcodeHeightTextBox.Text, CfgUpdateFlags.InvokeCfgChange | CfgUpdateFlags.AnyChange);
if ((flags & CfgUpdateFlags.InvokeCfgChange) != 0)
{
Printer.OnCfgChange(this, new CfgChangeArgs(CfgChangeCmd.CfgChange, config));
@@ -214,6 +264,20 @@ namespace TBF.BenchControl.Output.Printers.Label
}
}
private void ManageCheckGroupBox(CheckBox chk, GroupBox grp)
{
/// Make sure the CheckBox isn't in the GroupBox. This will only happen the first time.
if (chk.Parent == grp)
{
grp.Parent.Controls.Add(chk); /// Reparent the CheckBox so it's not in the GroupBox.
chk.Location = new Point(chk.Left + grp.Left, chk.Top + grp.Top); /// Adjust the CheckBox's location.
chk.BringToFront(); /// Move the CheckBox to the top of the stacking order.
}
/// Enable or disable the GroupBox.
grp.Enabled = chk.Checked;
}
#region Configuration Change Handling
public static void OnCmdResponse(object sender, CmdResponseArgs args)
@@ -18,6 +18,15 @@ namespace TBF.BenchControl.RegisterReaders.KPackE.RegisterReader
readonly TBF.BenchControl.Elde.ControlBoardDev controlBoard;
public int Position
{
get
{
int firstDigitPos = Name.IndexOfAny(new char[] { '1', '2', '3', '4', '5', '6', '7', '8', '9', '0' });
int position;
return (firstDigitPos < 0) ? 0 : (int.TryParse(Name.Substring(firstDigitPos), out position) ? position : 0);
}
}
public Config.Entities.RegisterReaderType RegisterReaderType { get { return Config.Entities.RegisterReaderType.Manual; } }
public double PulsesPerLtr { get { return registerReaderCfg.ProcParams.PulsesPerLtr; } }
public double LtrsPerPulse { get { return (PulsesPerLtr <= float.Epsilon) ? 1.0 : (1 / PulsesPerLtr); } }
@@ -21,6 +21,15 @@ namespace TBF.BenchControl.RegisterReaders.SerialStream
readonly SerialStreamCfg myCfg;
public int Position
{
get
{
int firstDigitPos = Name.IndexOfAny(new char[] { '1', '2', '3', '4', '5', '6', '7', '8', '9', '0' });
int position;
return (firstDigitPos < 0) ? 0 : (int.TryParse(Name.Substring(firstDigitPos), out position) ? position : 0);
}
}
public Config.Entities.RegisterReaderType RegisterReaderType { get { return Config.Entities.RegisterReaderType.DataStream; } }
public double PulsesPerLtr { get { return 1000.0; } }
public double LtrsPerPulse { get { return 1 / PulsesPerLtr; } }
+57 -26
View File
@@ -530,9 +530,18 @@ namespace TBF.BenchControl.Sequences
/// Water meter passed and was already saved to Oracle, do not reload & fix it now
wm.Disabled = true;
}
else if (!wm.Disabled && Users.GlobalData.GetCurrentUserName() == "milan")
else if ((wm.ErrorFlags & (int)ErrorFlagMask.E28) == 0)
{
/// Water meter not passed and not disabled and user is 'milan' => reset flag E28
/// Water meter failed but the failure is not an assembly error
wm.Disabled = true;
}
else if (!wm.Disabled && (Users.GlobalData.GetCurrentUserName() == "milan" ||
Users.GlobalData.GetCurrentUserName() == "augustin" ||
Users.GlobalData.GetCurrentUserName() == "michal" ||
Users.GlobalData.GetCurrentUserName() == "michal2"))
{
/// Water meter failed, is not disabled, there is an assembly error and user is one of above
/// ... => reset flag E28
wm.ErrorFlags = wm.ErrorFlags & (~(int)ErrorFlagMask.E28);
foreach (var mtr in wm.MeterTestRslts)
{
@@ -978,14 +987,22 @@ namespace TBF.BenchControl.Sequences
}
StateMachine.LoadTestParams(test);
ProcessData.RegisterReaders = sensPath.RegisterReaders;
foreach (var rr in sensPath.RegisterReaders)
{
if ((rr is TestMethods.iPerlCommunication.iPerlHead.IperlHead) && (BenchInfo != null))
{
(rr as TestMethods.iPerlCommunication.iPerlHead.IperlHead).BenchName = BenchInfo.TestBenchName;
}
}
if ((sensPath != null) && (sensPath.RegisterReaders != null))
{
ProcessData.RegisterReaders = sensPath.RegisterReaders;
foreach (var rr in sensPath.RegisterReaders)
{
if ((rr is TestMethods.iPerlCommunication.iPerlHead.IperlHead) && (BenchInfo != null))
{
(rr as TestMethods.iPerlCommunication.iPerlHead.IperlHead).BenchName = BenchInfo.TestBenchName;
}
}
}
else
{
ProcessData.RegisterReaders = null;
}
///
/// Execute one test (single repetition of a repeated test)
@@ -1136,15 +1153,22 @@ namespace TBF.BenchControl.Sequences
if (testMethod != null && testMethod.CanTest(StateMachine.Procedure.MetersKind))
{
StateMachine.LoadTestParams(dfrrdData.Test);
ProcessData.RegisterReaders = sensPath.RegisterReaders;
foreach (var rr in sensPath.RegisterReaders)
{
if ((rr is TestMethods.iPerlCommunication.iPerlHead.IperlHead) && (BenchInfo != null))
{
(rr as TestMethods.iPerlCommunication.iPerlHead.IperlHead).BenchName = BenchInfo.TestBenchName;
}
}
if ((sensPath != null) && (sensPath.RegisterReaders != null))
{
ProcessData.RegisterReaders = sensPath.RegisterReaders;
foreach (var rr in sensPath.RegisterReaders)
{
if ((rr is TestMethods.iPerlCommunication.iPerlHead.IperlHead) && (BenchInfo != null))
{
(rr as TestMethods.iPerlCommunication.iPerlHead.IperlHead).BenchName = BenchInfo.TestBenchName;
}
}
}
else
{
ProcessData.RegisterReaders = null;
}
e = testMethod.Execute2ndPass(dfrrdData.Test, dfrrdData.RepetNr, dfrrdData.IntermediateData);
@@ -1195,15 +1219,22 @@ namespace TBF.BenchControl.Sequences
if (testMethod != null && testMethod.CanTest(StateMachine.Procedure.MetersKind))
{
StateMachine.LoadTestParams(test);
ProcessData.RegisterReaders = sensPath.RegisterReaders;
foreach (var rr in sensPath.RegisterReaders)
{
if ((rr is TestMethods.iPerlCommunication.iPerlHead.IperlHead) && (BenchInfo != null))
{
(rr as TestMethods.iPerlCommunication.iPerlHead.IperlHead).BenchName = BenchInfo.TestBenchName;
}
}
if ((sensPath != null) && (sensPath.RegisterReaders != null))
{
ProcessData.RegisterReaders = sensPath.RegisterReaders;
foreach (var rr in sensPath.RegisterReaders)
{
if ((rr is TestMethods.iPerlCommunication.iPerlHead.IperlHead) && (BenchInfo != null))
{
(rr as TestMethods.iPerlCommunication.iPerlHead.IperlHead).BenchName = BenchInfo.TestBenchName;
}
}
}
else
{
ProcessData.RegisterReaders = null;
}
Event rsltTransBefore = Event.Done;
Event rsltTransAfter = Event.Done;
+15 -7
View File
@@ -511,14 +511,14 @@ namespace TBF.BenchControl.Sequences
if (transitionSequence == null)
{
log.WarnFormat("Transition(null, context={0})", context);
///
/// No transition sequence defined --> Default action
///
if ((context == TransitionContext.AfterTest) || (context == TransitionContext.AfterTestWithOverlap))
{
if (inPath.Pump is GenericDevices.IPumpFM) (inPath.Pump as GenericDevices.IPumpFM).TurnOff();
log.WarnFormat("Transition(null, context={0}), turning FM pump off and setting valves to defaults", context);
if (inPath.Pump is GenericDevices.IPumpFM) (inPath.Pump as GenericDevices.IPumpFM).TurnOff();
State.Create("SequenceBase : Transition : TestEnd - Default action")
.AddOperation(checkUiOp)
@@ -536,8 +536,8 @@ namespace TBF.BenchControl.Sequences
}
else
{
///
/// Fetch and execute the transition sequence
///
/// Fetch and execute the transition sequence, it is guaranteed (transitionSequence != null)
///
IList<TransitionStep> transitionSteps = new List<TransitionStep>();
if (StateMachine.TransitionSteps != null)
@@ -553,7 +553,7 @@ namespace TBF.BenchControl.Sequences
int stepsCount = transitionSteps.Count;
log.WarnFormat("Transition(sequence={0} ({1} steps), context={2})", transitionSequence.Name, stepsCount, context);
log.WarnFormat("Transition(sequence={0} ({1} steps), context={2})", transitionSequence.Name, stepsCount, context);
foreach (var step in transitionSteps)
{
@@ -729,13 +729,17 @@ namespace TBF.BenchControl.Sequences
///
if (context == TransitionContext.Stop || errorFlag || stopFlag)
{
///
log.ErrorFormat("Transition({0}, context={1}) errorFlag={2} stopFlag={3} ... stoppng all pumps off",
(transitionSequence != null) ? transitionSequence.Name : "null", context, errorFlag, stopFlag);
///
/// On error or when STOP pressed
///
foreach (var fmPump in PumpsWithFM) fmPump.TurnOff();
if (inPath != null)
{
///
/// Stop the pump
///
State.Create("SequenceBase.Transition() : Test stopped -> Stopping the pump")
@@ -751,6 +755,8 @@ namespace TBF.BenchControl.Sequences
}
else if (context == TransitionContext.BeforeTest)
{
log.WarnFormat("Transition(any, context={0}), setting the required route before a test", context);
///
/// Always set route at the beginning of this test
///
@@ -773,6 +779,8 @@ namespace TBF.BenchControl.Sequences
}
else if ((context == TransitionContext.AfterTestWithOverlap) && (nextInPath != null) && (nextBenchPath != null) && (nextOutPath != null))
{
log.WarnFormat("Transition(., context={0}), overlapped action (next flow regulation)", context);
/// Set route for the next test
State.Create("SequenceBase : AfterTestWithOverlap : Default action")
.AddOperation(checkUiOp)
+6 -1
View File
@@ -634,6 +634,7 @@ namespace TBF.BenchControl
else errorMsg = string.Empty;
if ((isHydroTest && (pfeed == null || pben == null || pout == null)) || (pmtrs == null))
{
log.ErrorFormat("GetPaths({0},...) returns false, wrong configuration", test.Name);
return false;
}
@@ -645,6 +646,7 @@ namespace TBF.BenchControl
#endif
if (heatMetersPathRequired && phmtrs == null)
{
log.ErrorFormat("GetPaths({0},...) returns false, missing heat meters sensors", test.Name);
errorMsg = "Cannot load heat meters sensors";
return false;
}
@@ -658,16 +660,19 @@ namespace TBF.BenchControl
if (isHydroTest && pout.Scale == null)
{
log.ErrorFormat("GetPaths({0},...) returns false, missing scales in output path {1}", test.Name, test.OutputPath);
errorMsg = string.Format("No balance specified in path {0}", test.OutputPath);
return false;
}
if (Program.LocalSettings.RealDensity < 500.0f || Program.LocalSettings.RealDensity > 2000.0f)
{
errorMsg = string.Format("Density was not specified");
log.ErrorFormat("GetPaths({0},...) returns false, density was not specified", test.Name);
errorMsg = string.Format("Density was not specified");
return false;
}
log.WarnFormat("GetPaths({0},...) returns true, paths loaded OK, isHydroTest={1}", test.Name, isHydroTest);
errorMsg = string.Empty;
return true;
}
+7 -5
View File
@@ -61,14 +61,16 @@ namespace TBF.BenchControl
Factories.Add(new TestMethods.FixedStart.Single.Factory());
Factories.Add(new TestMethods.FixedStart.Compound.Factory());
Factories.Add(new TestMethods.FixedStart.HeatMeters.Factory());
Factories.Add(new TestMethods.FixedStartAdvanced.Single.Factory());
Factories.Add(new TestMethods.FixedStartDeferredEvaluation.Single.Factory());
Factories.Add(new TestMethods.FixedStartDeferredEvaluation.Compound.Factory());
Factories.Add(new TestMethods.FixedStartDeferredEvaluation.HeatMeters.Factory());
Factories.Add(new TestMethods.FixedStartDeferredEval.Single.Factory());
Factories.Add(new TestMethods.FixedStartDeferredEval.Compound.Factory());
Factories.Add(new TestMethods.FixedStartDeferredEval.HeatMeters.Factory());
Factories.Add(new TestMethods.FixedStartMassCollection.Single.Factory());
Factories.Add(new TestMethods.FixedStartMassCollection.Compound.Factory());
Factories.Add(new TestMethods.FixedStartMassCollection.HeatMeters.Factory());
Factories.Add(new TestMethods.FixedStartTankCollection.Single.Factory());
Factories.Add(new TestMethods.FixedStartMassCollDeferredEval.Single.Factory());
Factories.Add(new TestMethods.FixedStartMassCollDeferredEval.Compound.Factory());
Factories.Add(new TestMethods.FixedStartMassCollDeferredEval.HeatMeters.Factory());
Factories.Add(new TestMethods.FixedStartTankCollection.Single.Factory());
Factories.Add(new TestMethods.FixedStartTankCollection.Compound.Factory());
Factories.Add(new TestMethods.FlyingStart.Single.Factory());
Factories.Add(new TestMethods.FlyingStart.Compound.Factory());
@@ -402,10 +402,12 @@ namespace TBF.BenchControl.TestMethods.Adjustment
tstRslt.FlowSetTime = flowSetTime;
tstRslt.TestTime = cBrd.TTime; /// [s] measurement time
tstRslt.PulsesMaster = Convert.ToDouble(cBrd.EtPulses(0)); /// Pulses of the master flow meter (test total)
tstRslt.MassStart = 0;
tstRslt.MassEnd = 0;
tstRslt.FlowMass = 0; /// [kg/h]
tstRslt.FlowVolume = 3.6 * LtrPerRefPulse * cBrd.EtPulses(0) / tstRslt.TestTime; /// [m3/h]
tstRslt.MassStartRaw = 0;
tstRslt.MassStart = 0;
tstRslt.MassEndRaw = 0;
tstRslt.MassEnd = 0;
tstRslt.FlowMass = 0; /// [kg/h]
tstRslt.FlowVolume = 3.6 * LtrPerRefPulse * tstRslt.PulsesMaster / tstRslt.TestTime; /// [m3/h]
tstRslt.Buoyancy = Config.Formulas.Buoyancy();
tstRslt.VolumeMaster = LtrPerRefPulse * tstRslt.PulsesMaster; /// [l] volume from the master flow meter
tstRslt.ConstMasterRaw = outPath.FlowMeter.LtrPerPulse; /// Uncorrected master flowmeter coefficient
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2013-2015 Sensus Metering Systems
/// Copyright (c) 2013-2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
@@ -15,6 +15,8 @@ namespace TBF.BenchControl.TestMethods.Adjustment
{
private static readonly ILog log = LogManager.GetLogger(typeof(WMErrorsForm));
const int MaxWMsCount = 6; /// Implementation limit of this form
///
/// Updated in constructor
///
@@ -43,13 +45,16 @@ namespace TBF.BenchControl.TestMethods.Adjustment
public WMErrorsForm(IList<GenericDevices.IWaterMeter> waterMeters)
: this()
{
waterMetersCount = waterMeters.Count;
waterMetersCount = Math.Min(Config.Data.WMsCount, waterMeters.Count);
rects = new Rectangle[waterMetersCount];
for (int i = 0; i < waterMetersCount; i++) rects[i] = new Rectangle(385, 30 + 90 * i, 324, 57);
disabled = new bool[waterMetersCount];
for (int i = 0; i < waterMetersCount; i++) disabled[i] = waterMeters[i].Disabled;
for (int i = 0; i < waterMetersCount; i++)
{
if (i < MaxWMsCount) disabled[i] = waterMeters[i].Disabled;
}
error = new double[waterMetersCount];
}
@@ -123,17 +128,20 @@ namespace TBF.BenchControl.TestMethods.Adjustment
string testName = args.TestName;
Results.Entities.TestRslt tr = TBF.BenchControl.Sequences.ProcessData.BatchRslts.GetTestRslt(testName, 0);
errLimLo = tr.ErrLimLo() + tr.Uncertainty();
errLimHi = tr.ErrLimHi() - tr.Uncertainty();
if (tr != null)
{
errLimLo = tr.ErrLimLo() + tr.Uncertainty();
errLimHi = tr.ErrLimHi() - tr.Uncertainty();
int count = Math.Min(waterMetersCount, TBF.BenchControl.Sequences.ProcessData.BatchRslts.WMPositionsCount);
for (int i = 0; i < count; i++)
{
Results.Entities.MeterTestRslt mtr = TBF.BenchControl.Sequences.ProcessData.BatchRslts.GetMeterTestRslt(testName, i, CompoundMeterId.Single);
if (mtr != null) error[i] = mtr.Error;
int count = Math.Min(waterMetersCount, TBF.BenchControl.Sequences.ProcessData.BatchRslts.WMPositionsCount);
for (int i = 0; i < count; i++)
{
Results.Entities.MeterTestRslt mtr = TBF.BenchControl.Sequences.ProcessData.BatchRslts.GetMeterTestRslt(testName, i, CompoundMeterId.Single);
if (mtr != null) error[i] = mtr.Error;
}
Redraw();
}
Redraw();
}
void Redraw()
@@ -154,7 +162,7 @@ namespace TBF.BenchControl.TestMethods.Adjustment
for (int i = 0; i < waterMetersCount; i++)
{
if (!disabled[i])
if ((i < MaxWMsCount) && (!disabled[i]))
{
PaintOne(graphics, rects[i], error[i], errLimLo, errLimHi);
}
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2015 Sensus Metering Systems
/// Copyright (c) 2015-2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
@@ -90,12 +90,15 @@ namespace TBF.BenchControl.TestMethods.Adjustment
public WMErrorsForm12(IList<GenericDevices.IWaterMeter> waterMeters)
: this()
{
waterMetersCount = waterMeters.Count;
waterMetersCount = Math.Min(Config.Data.WMsCount, waterMeters.Count);
ShuffleTextBoxes(waterMetersCount, Config.Data.LineSize);
disabled = new bool[waterMetersCount];
for (int i = 0; i < waterMetersCount; i++) disabled[i] = waterMeters[i].Disabled;
for (int i = 0; i < waterMetersCount; i++)
{
if (i < MaxWMsCount) disabled[i] = waterMeters[i].Disabled;
}
error = new double[waterMetersCount];
}
@@ -109,7 +112,7 @@ namespace TBF.BenchControl.TestMethods.Adjustment
/// <param name="lineSize">Number of watermeters in one line</param>
void ShuffleTextBoxes(int wmsCount, int lineSize)
{
if (wmsCount < textBoxesCount && lineSize > 0)
if ((wmsCount < textBoxesCount) && (lineSize > 0))
{
int nrLines = (wmsCount + lineSize - 1) / lineSize;
int gap = (textBoxesCount - wmsCount) / nrLines;
@@ -164,17 +167,20 @@ namespace TBF.BenchControl.TestMethods.Adjustment
string testName = args.TestName;
Results.Entities.TestRslt tr = TBF.BenchControl.Sequences.ProcessData.BatchRslts.GetTestRslt(testName, 0);
errLimLo = tr.ErrLimLo() + tr.Uncertainty();
errLimHi = tr.ErrLimHi() - tr.Uncertainty();
if (tr != null)
{
errLimLo = tr.ErrLimLo() + tr.Uncertainty();
errLimHi = tr.ErrLimHi() - tr.Uncertainty();
int count = Math.Min(waterMetersCount, TBF.BenchControl.Sequences.ProcessData.BatchRslts.WMPositionsCount);
for (int i = 0; i < count; i++)
{
Results.Entities.MeterTestRslt mtr = TBF.BenchControl.Sequences.ProcessData.BatchRslts.GetMeterTestRslt(testName, i, CompoundMeterId.Single);
if (mtr != null) error[i] = mtr.Error;
int count = Math.Min(waterMetersCount, TBF.BenchControl.Sequences.ProcessData.BatchRslts.WMPositionsCount);
for (int i = 0; i < count; i++)
{
Results.Entities.MeterTestRslt mtr = TBF.BenchControl.Sequences.ProcessData.BatchRslts.GetMeterTestRslt(testName, i, CompoundMeterId.Single);
if (mtr != null) error[i] = mtr.Error;
}
Redraw();
}
Redraw();
}
void Redraw()
@@ -192,7 +198,7 @@ namespace TBF.BenchControl.TestMethods.Adjustment
for (int i = 0; i < waterMetersCount; i++)
{
if (!disabled[i])
if ((i < MaxWMsCount) && (!disabled[i]))
{
PaintOne(graphics, rects[i], error[i], errLimLo, errLimHi);
}
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2015 Sensus Metering Systems
/// Copyright (c) 2015-2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
@@ -94,12 +94,15 @@ namespace TBF.BenchControl.TestMethods.Adjustment
public WMErrorsForm24(IList<GenericDevices.IWaterMeter> waterMeters)
: this()
{
waterMetersCount = waterMeters.Count;
waterMetersCount = Math.Min(Config.Data.WMsCount, waterMeters.Count);
ShuffleTextBoxes(waterMetersCount, Config.Data.LineSize);
disabled = new bool[waterMetersCount];
for (int i = 0; i < waterMetersCount; i++) disabled[i] = waterMeters[i].Disabled;
for (int i = 0; i < waterMetersCount; i++)
{
if (i < MaxWMsCount) disabled[i] = waterMeters[i].Disabled;
}
error = new double[waterMetersCount];
}
@@ -113,7 +116,7 @@ namespace TBF.BenchControl.TestMethods.Adjustment
/// <param name="lineSize">Number of watermeters in one line</param>
void ShuffleTextBoxes(int wmsCount, int lineSize)
{
if (wmsCount < textBoxesCount && lineSize > 0)
if ((wmsCount < textBoxesCount) && (lineSize > 0))
{
int nrLines = (wmsCount + lineSize - 1) / lineSize;
int gap = (textBoxesCount - wmsCount) / nrLines;
@@ -31,13 +31,6 @@ namespace TBF.BenchControl.TestMethods.FixedStart
HeatMeters.TestParams heatMetersTestParams,
Config.Entities.DebugMode debugLevel)
{
IScale scale = outPath.Scale as IScale;
if (scale == null)
{
Bridge.OnError(this, Strings.Missing_a_scale);
new List<Event> { Event.ConfigurationError }; /// or Event.UiCmdStop
}
int rangeIx = 0; /// Default range, used for non-Elde flowmeters
if (outPath.FlowMeter is Elde.FlowMeter.FlowMeter)
{
@@ -138,61 +131,6 @@ namespace TBF.BenchControl.TestMethods.FixedStart
}
if (!test.DoDraining)
{
///
/// Measure the weight in case there is no unconditional draining
///
State.Create(string.Format("{0}({1}) : Measuring mass of water in the tank", test.Method, test.Name))
.AddOperation(checkUiOp)
.AddOperations(readTempPressOps)
.AddOperation(scale.ReadMassOp(ref Mass))
.AddOperation(heatMetersPromptOp)
.EnterState();
do {
e = StateMachine.WaitRunDevsRunOps();
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.JustStarted));
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
}
while (!e.Contains(Event.BalanceDone));
}
///
/// Skip draining in case there is enough room in the tank
///
if (test.DoDraining || (Mass.Val + test.Volume >= scale.Capacity * Constants.TankFullFactor))
{
///
/// Drain the water tank
///
switch (DrainTheTank(scale, heatMetersPromptOp))
{
case Event.Error: { retVal = Event.Error; goto stopTest; }
case Event.UiCmdStop: { retVal = Event.UiCmdStop; goto stopTest; }
}
}
///
/// Make sure the drain valve is closed
///
State.Create(string.Format("{0}({1}) : Make sure the drain valve is closed", test.Method, test.Name))
.AddOperation(checkUiOp)
.AddOperations(readTempPressOps)
.AddOperation(scale.ReadMassOp(ref Mass))
.AddOperation(heatMetersPromptOp)
.AddOperation(StateMachine.ControlBoard.SetValvesOp(null, scale.DrainValve))
.EnterState();
do {
e = StateMachine.WaitRunDevsRunOps();
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.JustStarted));
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
}
while (!e.Contains(Event.ValvesSet) || !e.Contains(Event.BalanceDone));
//------------------------------------------------
Bridge.OnActivity(this, Strings.Starting_the_pump);
//------------------------------------------------
@@ -371,12 +309,12 @@ namespace TBF.BenchControl.TestMethods.FixedStart
{
double Tw = (TempRefHi1.Val + TempRefHi2.Val) / 2;
double Tc = (TempRefLo1.Val + TempRefLo2.Val) / 2;
if (heatMetersTestParams.TempWarmLo <= Tw && Tw <= heatMetersTestParams.TempWarmHi &&
heatMetersTestParams.TempColdLo <= Tc && Tc <= heatMetersTestParams.TempColdHi &&
Math.Abs(Tw - Tw_last) <= heatMetersTestParams.ChangeInTimeWarm &&
Math.Abs(Tc - Tc_last) <= heatMetersTestParams.ChangeInTimeCold &&
Math.Abs(TempRefHi1.Val - TempRefHi2.Val) <= heatMetersTestParams.DeltaTempWarm &&
Math.Abs(TempRefLo1.Val - TempRefLo2.Val) <= heatMetersTestParams.DeltaTempCold)
if ((heatMetersTestParams.TempWarmLo <= Tw) && (Tw <= heatMetersTestParams.TempWarmHi) &&
(heatMetersTestParams.TempColdLo <= Tc) && (Tc <= heatMetersTestParams.TempColdHi) &&
(Math.Abs(Tw - Tw_last) <= heatMetersTestParams.ChangeInTimeWarm) &&
(Math.Abs(Tc - Tc_last) <= heatMetersTestParams.ChangeInTimeCold) &&
(Math.Abs(TempRefHi1.Val - TempRefHi2.Val) <= heatMetersTestParams.DeltaTempWarm) &&
(Math.Abs(TempRefLo1.Val - TempRefLo2.Val) <= heatMetersTestParams.DeltaTempCold))
{
goto temperature_set;
}
@@ -434,26 +372,6 @@ namespace TBF.BenchControl.TestMethods.FixedStart
double currentFlow = RefFlow.Val;
//------------------------------------------------
Bridge.OnActivity(this, Strings.Measuring_the_weight);
//------------------------------------------------
if (test.TimeFlow2Mass > 0)
{
State.Create(string.Format("{0}({1}) : Waiting before 1st measurement", test.Method, test.Name))
.AddOperation(checkUiOp)
.AddOperations(readTempPressOps)
.AddOperation(new Operations.TimerOp(test.TimeFlow2Mass))
.EnterState();
do {
e = StateMachine.WaitRunDevsRunOps();
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
}
while (!e.Contains(Event.TimerExpired));
}
TestStartTime = DateTime.Now;
LogProcessDataTestInfo(processDataLogger, test.Procedure.Name, test.Name);
int startPulses = 0;
@@ -486,8 +404,7 @@ namespace TBF.BenchControl.TestMethods.FixedStart
}
}
state2.EnterState();
do
{
do {
e = StateMachine.WaitRunDevsRunOps();
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.Test));
@@ -553,12 +470,19 @@ namespace TBF.BenchControl.TestMethods.FixedStart
{
string srcDir = Path.Combine(Program.TempImagesDir, BatchRslts.Batch.BatchNr.ToString(), (i + 1).ToString());
string destDir = Path.Combine(Program.ImagesDir, BatchRslts.Batch.BatchNr.ToString(), (i + 1).ToString());
if (File.Exists(Path.Combine(srcDir, fileName)))
{
Directory.CreateDirectory(destDir);
File.Copy(Path.Combine(srcDir, fileName), Path.Combine(destDir, fileName), true);
try
{
if (File.Exists(Path.Combine(srcDir, fileName)))
{
Directory.CreateDirectory(destDir);
File.Copy(Path.Combine(srcDir, fileName), Path.Combine(destDir, fileName), true);
}
}
}
catch (Exception exc)
{
log.ErrorFormat("Failed to copy image {0} to {1}: {2}", fileName, destDir, exc.Message);
}
}
}
}
}
@@ -603,7 +527,7 @@ namespace TBF.BenchControl.TestMethods.FixedStart
queryEnd1 = cBrd.QueryMeasurementEndOp();
queryEnd2 = cBrd.QueryMeasurementEndOp();
StartNewStatistics(StateMachine.Time, BatchRslts.Batch.BatchNr, test.Name, repetitionNr, Math.Max((int)(test.TstTime/10), 5));
StartNewStatistics(StateMachine.Time, BatchRslts.Batch.BatchNr, test.Name, repetitionNr, Math.Max((int)(test.TstTime / 10), 5));
int estimtdEndTime = StateMachine.Time + (int)test.TstTime;
/// Measurement loop - begin
@@ -696,22 +620,22 @@ namespace TBF.BenchControl.TestMethods.FixedStart
}
while (e.Contains(Event.ValvesBusy));
switchTimeEnd = 0.001f * cBrd.ValveOpenCloseTime;
log.WarnFormat("Start valve switch time on test end = {0} ms", cBrd.ValveOpenCloseTime);
State.Create(string.Format("{0}({1}) : Waiting before 2nd measurement", test.Method, test.Name))
State.Create(string.Format("{0}({1}) : Stopping flow regulation", test.Method, test.Name))
.AddOperation(checkUiOp)
.AddOperations(readTempPressOps)
.AddOperation(scale.ReadMassOp(ref Mass))
.AddOperation(new Operations.TimerOp(test.TimeStop2Mass))
.AddOperation(processDataLoggingOp)
.AddOperation(cBrd.StopFlowRegulationOp(outPath))
.EnterState();
do {
e = StateMachine.WaitRunDevsRunOps();
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
}
while (!e.Contains(Event.TimerExpired));
while (!e.Contains(Event.FlowRegulationStopped));
switchTimeEnd = 0.001f * cBrd.ValveOpenCloseTime;
log.WarnFormat("Start valve switch time on test end = {0} ms", cBrd.ValveOpenCloseTime);
TestEndTime = DateTime.Now;
@@ -780,7 +704,8 @@ namespace TBF.BenchControl.TestMethods.FixedStart
State state = State.Create(string.Format("{0}({1}) : Entering the end-state", test.Method, test.Name));
if (heatMetersTestParams != null && dataEntryCmpnt is GenericDevices.IHasHeatMtrStatesForm)
{
state.AddOperation((dataEntryCmpnt as GenericDevices.IHasHeatMtrStatesForm).ShowTestEndFormOp(sensPath.RegisterReaders,
state.AddOperation((dataEntryCmpnt as GenericDevices.IHasHeatMtrStatesForm).
ShowTestEndFormOp(sensPath.RegisterReaders,
volumeCTV, test.ErrLimLo + test.Uncertainty, test.ErrLimHi - test.Uncertainty,
refEnergy, test.ErrLimLo + test.Uncertainty, test.ErrLimHi - test.Uncertainty));
}
@@ -840,11 +765,18 @@ namespace TBF.BenchControl.TestMethods.FixedStart
{
string srcDir = Path.Combine(Program.TempImagesDir, BatchRslts.Batch.BatchNr.ToString(), (i + 1).ToString());
string destDir = Path.Combine(Program.ImagesDir, BatchRslts.Batch.BatchNr.ToString(), (i + 1).ToString());
if (File.Exists(Path.Combine(srcDir, fileName)))
{
Directory.CreateDirectory(destDir);
File.Copy(Path.Combine(srcDir, fileName), Path.Combine(destDir, fileName), true);
}
try
{
if (File.Exists(Path.Combine(srcDir, fileName)))
{
Directory.CreateDirectory(destDir);
File.Copy(Path.Combine(srcDir, fileName), Path.Combine(destDir, fileName), true);
}
}
catch (Exception exc)
{
log.ErrorFormat("Failed to copy image {0} to {1}: {2}", fileName, destDir, exc.Message);
}
}
}
}
@@ -1060,7 +992,7 @@ namespace TBF.BenchControl.TestMethods.FixedStart
(BenchInfo != null) ? BenchInfo.TestBenchName : "testbench",
inPath.Pump != null ? inPath.Pump.Name : string.Empty,
outPath.FlowMeter != null ? outPath.FlowMeter.Name : string.Empty,
scale != null ? scale.Name : string.Empty,
string.Empty,
outPath.RegulValve != null ? outPath.RegulValve.Name : string.Empty,
outPath.Diverter != null ? outPath.Diverter.Name : string.Empty));
@@ -1,12 +1,12 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
using log4net;
using Config.Entities;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.Compound
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval.Compound
{
public class Component : ComponentBase, GenericDevices.ITestMethodWith2ndPass
{
@@ -35,12 +35,12 @@ namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.Compound
public IList<Event> Execute(Test test, int repetNr, bool isLastRepetition)
{
return (new FixedStartDeferredEvaluationSeq()).Execute(test, repetNr, isLastRepetition, true, null, DebugLevel, out intermediateData);
return (new FixedStartDeferredEvalSeq()).Execute(test, repetNr, isLastRepetition, true, null, DebugLevel, out intermediateData);
}
public IList<Event> Execute2ndPass(Test test, int repetNr, object data)
{
return (new FixedStartDeferredEvaluationSeq()).Execute2ndPass(test, repetNr, data as IntermediateData);
return (new FixedStartDeferredEvalSeq()).Execute2ndPass(test, repetNr, data as IntermediateData);
}
}
}
@@ -1,11 +1,11 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System.Collections.Generic;
using TBF.BenchControl.Generic;
using TBF.BenchControl.Configs.NameOnly;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.Single
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval.Compound
{
public class Factory : IComponentFactory
{
File diff suppressed because it is too large Load Diff
@@ -1,12 +1,12 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
using log4net;
using Config.Entities;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.HeatMeters
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval.HeatMeters
{
public class Component : ComponentBase, GenericDevices.ITestMethodWith2ndPass
{
@@ -38,12 +38,12 @@ namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.HeatMeters
public IList<Event> Execute(Test test, int repetNr, bool isLastRepetition)
{
return (new FixedStartDeferredEvaluationSeq()).Execute(test, repetNr, isLastRepetition, false, testMethodCfg.TestParams, DebugLevel, out intermediateData);
return (new FixedStartDeferredEvalSeq()).Execute(test, repetNr, isLastRepetition, false, testMethodCfg.TestParams, DebugLevel, out intermediateData);
}
public IList<Event> Execute2ndPass(Test test, int repetNr, object data)
{
return (new FixedStartDeferredEvaluationSeq()).Execute2ndPass(test, repetNr, data as IntermediateData);
return (new FixedStartDeferredEvalSeq()).Execute2ndPass(test, repetNr, data as IntermediateData);
}
}
}
@@ -1,10 +1,10 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System.Collections.Generic;
using TBF.BenchControl.Generic;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.HeatMeters
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval.HeatMeters
{
public class Factory : IComponentFactory
{
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
@@ -8,7 +8,7 @@ using System.Xml.Serialization;
using Config.Entities;
using TBF.BenchControl.Generic;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.HeatMeters
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval.HeatMeters
{
public class TestMethodCfg : ComponentCfgBase, Generic.IComponentCfg
{
@@ -1,12 +1,12 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Windows.Forms;
using Config.Entities;
using TBF.BenchControl.Generic;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.HeatMeters
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval.HeatMeters
{
public partial class TestMethodCfgCtrl : UserControl, IComponentCfgCtrl
{
@@ -1,7 +1,7 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.HeatMeters
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval.HeatMeters
{
partial class TestMethodCfgCtrl
{
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.IO;
@@ -9,7 +9,7 @@ using Config.Entities;
using TBF.BenchControl.Generic;
using TBF.Resources;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.HeatMeters
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval.HeatMeters
{
public class TestParams : TestParamsBase, IParamsProvider, ITestParams
{
@@ -1,9 +1,9 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval
{
public class IntermediateData
{
@@ -1,12 +1,12 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
using log4net;
using Config.Entities;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.Single
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval.Single
{
public class Component : ComponentBase, GenericDevices.ITestMethodWith2ndPass
{
@@ -35,12 +35,12 @@ namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.Single
public IList<Event> Execute(Test test, int repetNr, bool isLastRepetition)
{
return (new FixedStartDeferredEvaluationSeq()).Execute(test, repetNr, isLastRepetition, false, null, DebugLevel, out intermediateData);
return (new FixedStartDeferredEvalSeq()).Execute(test, repetNr, isLastRepetition, false, null, DebugLevel, out intermediateData);
}
public IList<Event> Execute2ndPass(Test test, int repetNr, object data)
{
return (new FixedStartDeferredEvaluationSeq()).Execute2ndPass(test, repetNr, data as IntermediateData);
return (new FixedStartDeferredEvalSeq()).Execute2ndPass(test, repetNr, data as IntermediateData);
}
}
}
@@ -1,11 +1,11 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System.Collections.Generic;
using TBF.BenchControl.Generic;
using TBF.BenchControl.Configs.NameOnly;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation.Compound
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEval.Single
{
public class Factory : IComponentFactory
{
@@ -0,0 +1,46 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
using log4net;
using Config.Entities;
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval.Compound
{
public class Component : ComponentBase, GenericDevices.ITestMethodWith2ndPass
{
private static readonly ILog log = LogManager.GetLogger(typeof(Component));
public override string ToString()
{
return string.Format("{0}({1})", this.GetType().Namespace.Substring(17), Cfg.ToString(1));
}
public bool CanTest(MetersKind meters) { return meters == MetersKind.Combined; }
public bool DoTransitions() { return true; }
public Component()
{
}
public Component(Generic.IComponentCfg cfg)
: base(cfg)
{
log.Debug(this.ToString());
}
private IntermediateData intermediateData;
public object IntermediateData { get { return intermediateData; } }
public IList<Event> Execute(Test test, int repetNr, bool isLastRepetition)
{
return (new FixedStartMassCollDeferredEvalSeq()).Execute(test, repetNr, isLastRepetition, true, null, DebugLevel, out intermediateData);
}
public IList<Event> Execute2ndPass(Test test, int repetNr, object data)
{
return (new FixedStartMassCollDeferredEvalSeq()).Execute2ndPass(test, repetNr, data as IntermediateData);
}
}
}
@@ -0,0 +1,27 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System.Collections.Generic;
using TBF.BenchControl.Generic;
using TBF.BenchControl.Configs.NameOnly;
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval.Compound
{
public class Factory : IComponentFactory
{
public string ClassName { get { return this.GetType().Namespace.Substring(17); } }
public void ResetStaticProperties() { Component.ResetStaticProperties(); }
public IComponent DummyComponent() { return new Component(); }
public IComponent GetComponent(IComponentCfg cfg, IList<IComponent> components) { return new Component(cfg); }
public IComponentCfg DefaultConfig() { return new TestMethodCfg(this.GetType().Namespace.Substring(29), this); }
public IComponentCfg CmpntCfgFromCmpntEntity(Config.Entities.Component component)
{
return ComponentCfgBase.CreateFromDbEntity(TestMethodCfg.Serializer, component, this);
}
}
}
@@ -1,5 +1,5 @@
///
/// Copyright (c) 2017 Sensus Slovensko a.s.
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
@@ -12,11 +12,11 @@ using TBF.Resources;
using TBF.UiBridge;
using TBF.BenchControl.GenericDevices;
namespace TBF.BenchControl.TestMethods.FixedStartDeferredEvaluation
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval
{
public class FixedStartDeferredEvaluationSeq : Sequences.SequenceBase
public class FixedStartMassCollDeferredEvalSeq : Sequences.SequenceBase
{
private static readonly ILog log = LogManager.GetLogger(typeof(FixedStartDeferredEvaluationSeq));
private static readonly ILog log = LogManager.GetLogger(typeof(FixedStartMassCollDeferredEvalSeq));
/// <summary>
/// Fixed start mass collection method with deferred evaluation of images
@@ -0,0 +1,49 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
using log4net;
using Config.Entities;
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval.HeatMeters
{
public class Component : ComponentBase, GenericDevices.ITestMethodWith2ndPass
{
private static readonly ILog log = LogManager.GetLogger(typeof(Component));
public override string ToString()
{
return string.Format("{0}({1})", this.GetType().Namespace.Substring(17), Cfg.ToString(1));
}
readonly TestMethodCfg testMethodCfg;
public bool CanTest(MetersKind meters) { return meters == MetersKind.HeatMeter; }
public bool DoTransitions() { return true; }
public Component()
{
}
public Component(Generic.IComponentCfg cfg)
: base(cfg)
{
testMethodCfg = cfg as TestMethodCfg;
log.Debug(this.ToString());
}
private IntermediateData intermediateData;
public object IntermediateData { get { return intermediateData; } }
public IList<Event> Execute(Test test, int repetNr, bool isLastRepetition)
{
return (new FixedStartMassCollDeferredEvalSeq()).Execute(test, repetNr, isLastRepetition, false, testMethodCfg.TestParams, DebugLevel, out intermediateData);
}
public IList<Event> Execute2ndPass(Test test, int repetNr, object data)
{
return (new FixedStartMassCollDeferredEvalSeq()).Execute2ndPass(test, repetNr, data as IntermediateData);
}
}
}
@@ -0,0 +1,26 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System.Collections.Generic;
using TBF.BenchControl.Generic;
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval.HeatMeters
{
public class Factory : IComponentFactory
{
public string ClassName { get { return this.GetType().Namespace.Substring(17); } }
public void ResetStaticProperties() { Component.ResetStaticProperties(); }
public IComponent DummyComponent() { return new Component(); }
public IComponent GetComponent(IComponentCfg cfg, IList<IComponent> components) { return new Component(cfg); }
public IComponentCfg DefaultConfig() { return new TestMethodCfg(this.GetType().Namespace.Substring(29), this); }
public IComponentCfg CmpntCfgFromCmpntEntity(Config.Entities.Component component)
{
return ComponentCfgBase.CreateFromDbEntity(TestMethodCfg.Serializer, component, this);
}
}
}
@@ -0,0 +1,49 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
using System.IO;
using System.Xml.Serialization;
using Config.Entities;
using TBF.BenchControl.Generic;
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval.HeatMeters
{
public class TestMethodCfg : ComponentCfgBase, Generic.IComponentCfg
{
public static XmlSerializer Serializer = XmlSerializer.FromTypes(new[] { typeof(TestMethodCfg) })[0];
public override XmlSerializer GetSerializer() { return Serializer; }
public IComponentCfgCtrl GetControl() { return new TestMethodCfgCtrl(); }
/// <summary> Test parameters </summary>
[XmlIgnore]
public TestParams TestParams; /// Created in constructor
public override IParamsProvider GetRuntimeTestParamsProvider() { return TestParams; }
public override IParamsProvider CreateTestParamsProvider() { return new TestParams(true); }
public override IParamsProvider GetUITestParamsProvider(Test test)
{
return (test.Method == Name) ? base.GetUITestParamsProvider(test) : null;
}
/// Private parameterless constructor invoked by all other (public) constructors
TestMethodCfg()
{
TestParams = new TestParams(true);
}
public TestMethodCfg(string name, IComponentFactory factory)
: this()
{
Name = name;
Factory = factory;
ParentName = string.Empty;
}
public string ToString(int i)
{
return string.Format("Name={0}", Name);
}
}
}
@@ -0,0 +1,69 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Windows.Forms;
using Config.Entities;
using TBF.BenchControl.Generic;
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval.HeatMeters
{
public partial class TestMethodCfgCtrl : UserControl, IComponentCfgCtrl
{
public bool ShowMore { get { return false; } }
TestMethodCfg config;
public IComponentCfg Config
{
get { return config as IComponentCfg; }
set
{
config = value as TestMethodCfg;
Redraw();
}
}
public TestMethodCfgCtrl()
{
InitializeComponent();
}
private void EntryFormCfgCtrl_Load(object sender, EventArgs e)
{
Redraw();
}
public void Closing()
{
}
void Redraw()
{
if (config == null) return; /// Control was not loaded, settings were not changed
classNameLabel.Text = config.Factory.ClassName;
nameTextBox.Text = config.Name;
}
public void Unlock()
{
nameTextBox.Enabled = true;
}
public CfgUpdateFlags VerifyCfg(ref string message)
{
CfgUpdateFlags flags = CfgUpdateFlags.None;
return flags;
}
public CfgUpdateFlags UpdateCfg()
{
CfgUpdateFlags flags = CfgUpdateFlags.RestartRqrd;
if (config == null) return CfgUpdateFlags.Error; /// Control was not loaded, settings were not changed
config.Name = nameTextBox.Text;
return flags;
}
}
}
@@ -0,0 +1,86 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval.HeatMeters
{
partial class TestMethodCfgCtrl
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Component Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.nameTextBox = new System.Windows.Forms.TextBox();
this.nameLabel = new System.Windows.Forms.Label();
this.classNameLabel = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// nameTextBox
//
this.nameTextBox.Enabled = false;
this.nameTextBox.Location = new System.Drawing.Point(137, 57);
this.nameTextBox.Name = "nameTextBox";
this.nameTextBox.Size = new System.Drawing.Size(130, 20);
this.nameTextBox.TabIndex = 5;
//
// nameLabel
//
this.nameLabel.AutoSize = true;
this.nameLabel.Location = new System.Drawing.Point(27, 60);
this.nameLabel.Name = "nameLabel";
this.nameLabel.Size = new System.Drawing.Size(35, 13);
this.nameLabel.TabIndex = 4;
this.nameLabel.Text = "Name";
//
// classNameLabel
//
this.classNameLabel.AutoSize = true;
this.classNameLabel.Location = new System.Drawing.Point(134, 33);
this.classNameLabel.Name = "classNameLabel";
this.classNameLabel.Size = new System.Drawing.Size(83, 13);
this.classNameLabel.TabIndex = 3;
this.classNameLabel.Text = "ComonentName";
//
// BasicPrinterCfgCtrl
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.nameTextBox);
this.Controls.Add(this.nameLabel);
this.Controls.Add(this.classNameLabel);
this.Name = "BasicPrinterCfgCtrl";
this.Size = new System.Drawing.Size(300, 200);
this.Load += new System.EventHandler(this.EntryFormCfgCtrl_Load);
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.TextBox nameTextBox;
private System.Windows.Forms.Label nameLabel;
private System.Windows.Forms.Label classNameLabel;
}
}
@@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>
@@ -0,0 +1,197 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.IO;
using System.Text;
using System.Xml.Serialization;
using Config.Entities;
using TBF.BenchControl.Generic;
using TBF.Resources;
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval.HeatMeters
{
public class TestParams : TestParamsBase, IParamsProvider, ITestParams
{
public static XmlSerializer Serializer = XmlSerializer.FromTypes(new[] { typeof(TestParams) })[0];
public override XmlSerializer GetSerializer() { return Serializer; }
public float ErrorLimitLo; /// [%]
public float ErrorLimitHi; /// [%]
public bool EvaluateVolume; /// true = evaluate also the volume, false = evaluate only energy
public float TempWarmLo; /// Low limit for warm temperature [°C]
public float TempWarmHi; /// High limit for warm temperature [°C]
public float TempColdLo; /// Low limit for cold temperature [°C]
public float TempColdHi; /// High limit for cold temperature [°C]
public bool FlowMeasuredAtHiTempPipe; /// true = flow measured at high temp. pipe, false = flow measured at low temp. pipe
public float DeltaTempWarm;
public float DeltaTempCold;
public float ChangeInTimeWarm;
public float ChangeInTimeCold;
public string Prompt;
public override void InitializeAll()
{
FlowMeasuredAtHiTempPipe = false;
}
string[] paramNames = new string[]
{
Strings.Err_limit_neg_pct_chdr,
Strings.Err_limit_pos_pct_chdr,
Strings.Evaluate_volume,
"T hi min",
"T hi max",
"T lo min",
"T lo max",
"Flow measured at high temp.pipe",
"Delta T warm",
"Delta T cold",
"Change in time T warm",
"Change in time T cold",
Strings.Prompt,
};
public override string ParamName(int i) { return paramNames[i]; }
public override int ParamsCount() { return paramNames.Length; }
public override string ToString(int i)
{
switch (i)
{
case 0: return ErrorLimitLo.ToString();
case 1: return ErrorLimitHi.ToString();
case 2: return (EvaluateVolume ? Strings.yes : Strings.no);
case 3: return TempWarmLo.ToString();
case 4: return TempWarmHi.ToString();
case 5: return TempColdLo.ToString();
case 6: return TempColdHi.ToString();
case 7: return (FlowMeasuredAtHiTempPipe ? Strings.yes : Strings.no);
case 8: return DeltaTempWarm.ToString();
case 9: return DeltaTempCold.ToString();
case 10: return ChangeInTimeWarm.ToString();
case 11: return ChangeInTimeCold.ToString();
case 12: return Prompt;
default: return string.Empty;
}
}
public CfgUpdateFlags UpdateParam(int i, string strValue)
{
switch (i)
{
case 0: ErrorLimitLo = Utils.ParseSFloat(strValue); return CfgUpdateFlags.None;
case 1: ErrorLimitHi = Utils.ParseSFloat(strValue); return CfgUpdateFlags.None;
case 2: EvaluateVolume = strValue.Equals(Strings.yes); return CfgUpdateFlags.None;
case 3: TempWarmLo = Utils.ParseSFloat(strValue); return CfgUpdateFlags.None;
case 4: TempWarmHi = Utils.ParseSFloat(strValue); return CfgUpdateFlags.None;
case 5: TempColdLo = Utils.ParseSFloat(strValue); return CfgUpdateFlags.None;
case 6: TempColdHi = Utils.ParseSFloat(strValue); return CfgUpdateFlags.None;
case 7: FlowMeasuredAtHiTempPipe = strValue.Equals(Strings.yes); return CfgUpdateFlags.None;
case 8: DeltaTempWarm = Utils.ParseUFloat(strValue); return CfgUpdateFlags.None;
case 9: DeltaTempCold = Utils.ParseUFloat(strValue); return CfgUpdateFlags.None;
case 10: ChangeInTimeWarm = Utils.ParseUFloat(strValue); return CfgUpdateFlags.None;
case 11: ChangeInTimeCold = Utils.ParseUFloat(strValue); return CfgUpdateFlags.None;
case 12: Prompt = strValue; return CfgUpdateFlags.None;
default: return CfgUpdateFlags.None;
}
}
public bool ValidateParam(int i, string strValue, out string message)
{
message = string.Empty;
float dummy;
switch (i)
{
case 0:
case 1:
case 3:
case 4:
case 5:
case 6:
if (Utils.TryParseSFloat(strValue, out dummy)) return true;
break;
case 2:
case 7:
if (strValue.Equals(Strings.yes) || strValue.Equals(Strings.no)) return true;
break;
case 8:
case 9:
case 10:
case 11:
if (Utils.TryParseUFloat(strValue, out dummy)) return true;
break;
case 12:
return true;
default:
message = "Invalid index";
return false;
}
message = ParamName(i) + " is invalid";
return false;
}
void CopyContentTo(TestParams prms)
{
prms.ErrorLimitLo = ErrorLimitLo;
prms.ErrorLimitHi = ErrorLimitHi;
prms.EvaluateVolume = EvaluateVolume;
prms.TempWarmLo = TempWarmLo;
prms.TempWarmHi = TempWarmHi;
prms.TempColdLo = TempColdLo;
prms.TempColdHi = TempColdHi;
prms.FlowMeasuredAtHiTempPipe = FlowMeasuredAtHiTempPipe;
prms.DeltaTempWarm = DeltaTempWarm;
prms.DeltaTempCold = DeltaTempCold;
prms.ChangeInTimeWarm = ChangeInTimeWarm;
prms.ChangeInTimeCold = ChangeInTimeCold;
prms.Prompt = Prompt;
}
public IParamsProvider Clone()
{
TestParams pars = new TestParams();
CopyContentTo(pars);
return pars;
}
public override void UpdateFromDbEntity(ComponentTest dbEntity)
{
if (dbEntity == null) return;
try
{
TestParams tmp = Serializer.Deserialize(new StringReader(dbEntity.Parameters)) as TestParams;
testParamsEntity = dbEntity;
componentName = dbEntity.CmpntName;
test = dbEntity.Test;
if (tmp != null) tmp.CopyContentTo(this);
}
catch
{
}
}
/// <summary>
/// Parameterless constructor initializes the parameters
/// </summary>
public TestParams()
{
}
public TestParams(bool initialize)
{
if (initialize) InitializeAll();
}
public TestParams(ComponentTest testParamsEntity, string componentName, Test test)
{
this.testParamsEntity = testParamsEntity;
this.componentName = componentName;
this.test = test;
}
}
}
@@ -0,0 +1,16 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval
{
public class IntermediateData
{
public bool Compound;
public string TestName;
public int TestPart;
public string[] StartImages;
public string[] EndImages;
}
}
@@ -0,0 +1,46 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
using log4net;
using Config.Entities;
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval.Single
{
public class Component : ComponentBase, GenericDevices.ITestMethodWith2ndPass
{
private static readonly ILog log = LogManager.GetLogger(typeof(Component));
public override string ToString()
{
return string.Format("{0}({1})", this.GetType().Namespace.Substring(17), Cfg.ToString(1));
}
public bool CanTest(MetersKind meters) { return meters == MetersKind.Single; }
public bool DoTransitions() { return true; }
public Component()
{
}
public Component(Generic.IComponentCfg cfg)
: base(cfg)
{
log.Debug(this.ToString());
}
private IntermediateData intermediateData;
public object IntermediateData { get { return intermediateData; } }
public IList<Event> Execute(Test test, int repetNr, bool isLastRepetition)
{
return (new FixedStartMassCollDeferredEvalSeq()).Execute(test, repetNr, isLastRepetition, false, null, DebugLevel, out intermediateData);
}
public IList<Event> Execute2ndPass(Test test, int repetNr, object data)
{
return (new FixedStartMassCollDeferredEvalSeq()).Execute2ndPass(test, repetNr, data as IntermediateData);
}
}
}
@@ -0,0 +1,27 @@
///
/// Copyright (c) 2019 Sensus Slovensko a.s.
///
using System.Collections.Generic;
using TBF.BenchControl.Generic;
using TBF.BenchControl.Configs.NameOnly;
namespace TBF.BenchControl.TestMethods.FixedStartMassCollDeferredEval.Single
{
public class Factory : IComponentFactory
{
public string ClassName { get { return this.GetType().Namespace.Substring(17); } }
public void ResetStaticProperties() { Component.ResetStaticProperties(); }
public IComponent DummyComponent() { return new Component(); }
public IComponent GetComponent(IComponentCfg cfg, IList<IComponent> components) { return new Component(cfg); }
public IComponentCfg DefaultConfig() { return new TestMethodCfg(this.GetType().Namespace.Substring(29), this); }
public IComponentCfg CmpntCfgFromCmpntEntity(Config.Entities.Component component)
{
return ComponentCfgBase.CreateFromDbEntity(TestMethodCfg.Serializer, component, this);
}
}
}
@@ -80,7 +80,7 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
foreach (var rr in sensPath.RegisterReaders)
{
TBF.BenchControl.Elde.RegisterReader.RegisterReader eldeRR = rr as TBF.BenchControl.Elde.RegisterReader.RegisterReader;
if (eldeRR != null && eldeRR.Position >= 1 && eldeRR.Position <= 8)
if ((eldeRR != null) && (eldeRR.Position >= 1) && (eldeRR.Position <= 8))
{
filters[eldeRR.Position - 1] = eldeRR.Filter;
}
@@ -618,7 +618,7 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
.AddOperation(checkUiOp)
.AddOperations(readTempPressOps)
.AddOperation(cBrd.StartMeasurementOp(outPath, (Elde.TestMethods.Diverter | Elde.TestMethods.FixedStart),
test.Qfrom, test.Qto, (2 * totalPulses)))
test.Qfrom, test.Qto, 2 * totalPulses))
.EnterState();
do {
e = StateMachine.WaitRunDevsRunOps();
@@ -868,8 +868,7 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
}
}
state2.EnterState();
do
{
do {
e = StateMachine.WaitRunDevsRunOps();
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.Test));
@@ -653,7 +653,7 @@ namespace TBF.BenchControl.TestMethods.FlyingStart
if (regReader.WMPulses >= 1)
{
/// Normal measurement
meterRslt.TestTime = cBrd.ImpulseTime(i + 1);
meterRslt.TestTime = cBrd.ImpulseTime(regReader.Position);
meterRslt.VolumeRef = meterRslt.PulsesMaster * tstRslt.ConstMaster; /// liter
}
else
@@ -933,7 +933,7 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollComparative
meterRslt.PulsesMeter = (isAux == 0 && compoundTestParams.SupressTrills) ? 0 : Convert.ToDouble(regReader.WMPulses);
meterRslt.PulsesMaster = Convert.ToDouble(regReader.WMRefPulses);
meterRslt.TestTime = cBrd.ImpulseTime(2 * i + isAux + 1);
meterRslt.TestTime = cBrd.ImpulseTime(regReader.Position);
meterRslt.VolumeStart = 0;
meterRslt.VolumeEnd = 0;
meterRslt.VolumeRef = tstRslt.VolumeCTV;
@@ -1118,7 +1118,7 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollComparative
if (regReader.WMPulses >= 1)
{
/// Normal measurement
meterRslt.TestTime = cBrd.ImpulseTime(i + 1);
meterRslt.TestTime = cBrd.ImpulseTime(regReader.Position);
meterRslt.VolumeRef = meterRslt.PulsesMaster * tstRslt.ConstMaster; /// liter
}
else
@@ -815,7 +815,7 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollProlonged
meterRslt.PulsesMeter = (isAux == 0 && compoundTestParams.SupressTrills) ? 0 : Convert.ToDouble(regReader.WMPulses);
meterRslt.PulsesMaster = Convert.ToDouble(regReader.WMRefPulses);
meterRslt.TestTime = cBrd.ImpulseTime(2 * i + isAux + 1);
meterRslt.TestTime = cBrd.ImpulseTime(regReader.Position);
meterRslt.VolumeStart = 0;
meterRslt.VolumeEnd = 0;
meterRslt.VolumeRef = tstRslt.VolumeCTV;
@@ -650,20 +650,24 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollection
//------------------------------------------------
Bridge.OnActivity(this, Strings.Measuring_the_weight);
//------------------------------------------------
State.Create(string.Format("{0}({1}) : Waiting before the 2nd mass measurement", test.Method, test.Name))
.AddOperation(checkUiOp)
.AddOperations(readTempPressOps)
.AddOperation(scale.ReadMassOp(ref Mass))
.AddOperation(cBrd.ReadDiverterTransitionOp(outPath.Diverter, CountWhenSendingRdDivCmd, CountWhenReadingDiv, false, DiverterEnd, BatchRslts.Batch.BatchNr, test.Name, repetitionNr))
.AddOperation(processDataLoggingOp)
.AddOperation(new Operations.TimerOp(test.TimeStop2Mass))
.EnterState();
do {
e = StateMachine.WaitRunDevsRunOps();
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
if (TestAndLogUiCmdStop(test,e)) { retVal = Event.UiCmdStop; goto stopTest; }
if (test.TimeStop2Mass > 0)
{
State.Create(string.Format("{0}({1}) : Waiting before the 2nd mass measurement", test.Method, test.Name))
.AddOperation(checkUiOp)
.AddOperations(readTempPressOps)
.AddOperation(scale.ReadMassOp(ref Mass))
.AddOperation(cBrd.ReadDiverterTransitionOp(outPath.Diverter, CountWhenSendingRdDivCmd, CountWhenReadingDiv, false, DiverterEnd, BatchRslts.Batch.BatchNr, test.Name, repetitionNr))
.AddOperation(processDataLoggingOp)
.AddOperation(new Operations.TimerOp(test.TimeStop2Mass))
.EnterState();
do
{
e = StateMachine.WaitRunDevsRunOps();
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
}
while (!e.Contains(Event.TimerExpired) || !e.Contains(Event.BalanceDone));
}
while (!e.Contains(Event.TimerExpired) || !e.Contains(Event.BalanceDone));
if (heatMetersPath == null) LogProcessDataHeader(processDataLogger, "End mass");
@@ -803,7 +807,7 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollection
meterRslt.PulsesMeter = (isAux == 0 && compoundTestParams.SupressTrills) ? 0 : Convert.ToDouble(regReader.WMPulses);
meterRslt.PulsesMaster = Convert.ToDouble(regReader.WMRefPulses);
meterRslt.TestTime = cBrd.ImpulseTime(2 * i + isAux + 1);
meterRslt.TestTime = cBrd.ImpulseTime(regReader.Position);
meterRslt.VolumeStart = 0;
meterRslt.VolumeEnd = 0;
meterRslt.VolumeRef = tstRslt.VolumeCTV;
@@ -988,7 +992,7 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollection
if (regReader.WMPulses >= 1)
{
/// Normal measurement
meterRslt.TestTime = cBrd.ImpulseTime(i + 1);
meterRslt.TestTime = cBrd.ImpulseTime(regReader.Position);
meterRslt.VolumeRef = meterRslt.PulsesMaster * tstRslt.ConstMaster; /// liter
}
else
@@ -563,7 +563,7 @@ namespace TBF.BenchControl.TestMethods.FlyingStartTankCollection
meterRslt.PulsesMeter = (isAux == 0 && compoundTestParams.SupressTrills) ? 0 : Convert.ToDouble(regReader.WMPulses);
meterRslt.PulsesMaster = Convert.ToDouble(regReader.WMRefPulses);
meterRslt.TestTime = cBrd.ImpulseTime(2 * i + isAux + 1);
meterRslt.TestTime = cBrd.ImpulseTime(regReader.Position);
meterRslt.VolumeStart = 0;
meterRslt.VolumeEnd = 0;
meterRslt.VolumeRef = tstRslt.VolumeCTV;
@@ -677,7 +677,7 @@ namespace TBF.BenchControl.TestMethods.FlyingStartTankCollection
if (regReader.WMPulses >= 1)
{
/// Normal measurement
meterRslt.TestTime = cBrd.ImpulseTime(i + 1);
meterRslt.TestTime = cBrd.ImpulseTime(regReader.Position);
meterRslt.VolumeRef = meterRslt.PulsesMaster * tstRslt.ConstMaster; /// liter
}
else
@@ -2162,7 +2162,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication
///
/// Standard process
///
if (Math.Abs(q2adjResult.Error - ihead.CalibTargetQ2) <= 0.5)
if ((Math.Abs(q2adjResult.Error - ihead.CalibTargetQ2) <= 0.5) && !ihead.DoQ2CorrInside05pct)
{
resultStr = string.Format("Q2 correction = 0 (writing bypassed)");
return CommErr.None;
@@ -2176,7 +2176,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication
///
/// Process for DEWA
///
if (Math.Abs(q2adjResult.Error - ihead.CalibTargetQ2) <= 0.5)
if ((Math.Abs(q2adjResult.Error - ihead.CalibTargetQ2) <= 0.5) && !ihead.DoQ2CorrInside05pct)
{
resultStr = string.Format("Q2 correction = 0 (writing bypassed)");
return CommErr.None;
@@ -2191,7 +2191,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication
///
/// Process for Greece
///
if (Math.Abs(q2adjResult.Error - ihead.CalibTargetQ2) <= 0.5)
if ((Math.Abs(q2adjResult.Error - ihead.CalibTargetQ2) <= 0.5) && !ihead.DoQ2CorrInside05pct)
{
resultStr = string.Format("Q2 correction = 0 (writing bypassed)");
return CommErr.None;
@@ -2202,7 +2202,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication
}
else if (q2CorrType == Q2CorrType.RL) /// SUEZ
{
if (Math.Abs(q2adjResult.Error - ihead.CalibTargetQ2) <= 0.5)
if ((Math.Abs(q2adjResult.Error - ihead.CalibTargetQ2) <= 0.5) && !ihead.DoQ2CorrInside05pct)
{
resultStr = string.Format("Q2 correction = 0 (writing bypassed)");
return CommErr.None;
@@ -2212,7 +2212,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication
}
else if (q2CorrType == Q2CorrType.LR) /// SUEZ
{
if (Math.Abs(q2adjResult.Error - ihead.CalibTargetQ2) <= 0.5)
if ((Math.Abs(q2adjResult.Error - ihead.CalibTargetQ2) <= 0.5) && !ihead.DoQ2CorrInside05pct)
{
resultStr = string.Format("Q2 correction = 0 (writing bypassed)");
return CommErr.None;
@@ -31,12 +31,22 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication.iPerlHead
public int MuxBoardNrOrGroup14 { get { return iperlHeadCfg.MuxBoardNr; } }
public int Group { get { return iperlHeadCfg.Group; } }
public int Position
{
get
{
int firstDigitPos = Name.IndexOfAny(new char[] { '1', '2', '3', '4', '5', '6', '7', '8', '9', '0' });
int position;
return (firstDigitPos < 0) ? 0 : (int.TryParse(Name.Substring(firstDigitPos), out position) ? position : 0);
}
}
public Config.Entities.RegisterReaderType RegisterReaderType { get { return Config.Entities.RegisterReaderType.DataStream; } }
public double PulsesPerLtr { get { return 1000.0; } }
public double LtrsPerPulse { get { return 1 / PulsesPerLtr; } }
public double CalibTarget { get { return iperlHeadCfg.ProcParams.CalibTarget; } }
public double CalibTargetQ2 { get { return iperlHeadCfg.ProcParams.CalibTargetQ2; } }
public bool DoQ2CorrInside05pct { get { return iperlHeadCfg.ProcParams.DoQ2CorrInside05pct; } }
public ushort FactorLimitLo { get { return (ushort)iperlHeadCfg.ProcParams.FactorLimitLo; } }
public ushort FactorLimitHi { get { return (ushort)iperlHeadCfg.ProcParams.FactorLimitHi; } }
public Counting InitFlowDir { get { return (iperlHeadCfg != null && iperlHeadCfg.ProcParams != null) ? iperlHeadCfg.ProcParams.Counting : Counting.Arbitrary; } }
@@ -2,11 +2,12 @@
/// Copyright (c) 2015-2019 Sensus Slovensko a.s.
///
using System;
using System.Collections.Generic;
using System.IO;
using System.Xml.Serialization;
using Config.Entities;
using TBF.BenchControl.Generic;
using System.Collections.Generic;
using TBF.Resources;
namespace TBF.BenchControl.TestMethods.iPerlCommunication.iPerlHead
{
@@ -18,6 +19,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication.iPerlHead
public MeterType MeterType;
public float CalibTarget; /// Target error after calibration in [%]
public float CalibTargetQ2; /// Target error at Q2 after Q2 correction in [%]
public bool DoQ2CorrInside05pct; /// true = Q2 correction is performed also when Q2 error is within -0.5% .. 0.5%
public int FactorLimitLo; /// Lower limit for the calibration factor
public int FactorLimitHi; /// Upper limit for the calibration factor
public Counting Counting; /// Initial iPerl counting (Artbitrary, Positive or Negative)
@@ -31,6 +33,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication.iPerlHead
MeterType = MeterType.AutoDetect;
CalibTarget = 0;
CalibTargetQ2 = 0;
DoQ2CorrInside05pct = false;
FactorLimitLo = 1000;
FactorLimitHi = 8000;
Counting = Counting.Arbitrary;
@@ -44,6 +47,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication.iPerlHead
"iPerl type",
"Calib. target [%]",
"Calib. target at Q2 [%]",
"Q2 corr. inside -0.5 - 0.5%",
"Calib. factor Lo",
"Calib. factor Hi",
"Counting",
@@ -62,7 +66,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication.iPerlHead
for (MeterType mt = 0; mt < MeterType.Count; mt++) retVal.Add(mt.ToString());
return retVal;
}
else if (i == 5)
else if (i == 6)
{
IList<string> retVal = new List<string>();
for (Counting c = 0; c < Counting.Count; c++) retVal.Add(c.ToString());
@@ -78,12 +82,13 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication.iPerlHead
case 0: return MeterType.ToString();
case 1: return CalibTarget.ToString();
case 2: return CalibTargetQ2.ToString();
case 3: return FactorLimitLo.ToString();
case 4: return FactorLimitHi.ToString();
case 5: return Counting.ToString();
case 6: return WMType_ID.ToString();
case 7: return InitQ2CorrLR.ToString();
case 8: return InitQ2CorrRL.ToString();
case 3: return (DoQ2CorrInside05pct ? Strings.yes : Strings.no);
case 4: return FactorLimitLo.ToString();
case 5: return FactorLimitHi.ToString();
case 6: return Counting.ToString();
case 7: return WMType_ID.ToString();
case 8: return InitQ2CorrLR.ToString();
case 9: return InitQ2CorrRL.ToString();
default: return string.Empty;
}
}
@@ -100,17 +105,18 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication.iPerlHead
break;
case 1: CalibTarget = Utils.ParseSFloat(strValue); return CfgUpdateFlags.None;
case 2: CalibTargetQ2 = Utils.ParseSFloat(strValue); return CfgUpdateFlags.None;
case 3: FactorLimitLo = int.Parse(strValue); return CfgUpdateFlags.None;
case 4: FactorLimitHi = int.Parse(strValue); return CfgUpdateFlags.None;
case 5:
case 3: DoQ2CorrInside05pct = strValue.ToLower().Equals(Strings.yes.ToLower()); return CfgUpdateFlags.None;
case 4: FactorLimitLo = int.Parse(strValue); return CfgUpdateFlags.None;
case 5: FactorLimitHi = int.Parse(strValue); return CfgUpdateFlags.None;
case 6:
for (Counting c = 0; c < Counting.Count; c++)
{
if (c.ToString().Equals(strValue)) { Counting = c; return CfgUpdateFlags.None; }
}
break;
case 6: WMType_ID = int.Parse(strValue); return CfgUpdateFlags.None;
case 7: InitQ2CorrLR = int.Parse(strValue); return CfgUpdateFlags.None;
case 8: InitQ2CorrRL = int.Parse(strValue); return CfgUpdateFlags.None;
case 7: WMType_ID = int.Parse(strValue); return CfgUpdateFlags.None;
case 8: InitQ2CorrLR = int.Parse(strValue); return CfgUpdateFlags.None;
case 9: InitQ2CorrRL = int.Parse(strValue); return CfgUpdateFlags.None;
default: return CfgUpdateFlags.None;
}
@@ -133,18 +139,21 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication.iPerlHead
case 2:
if (Utils.TryParseSFloat(strValue, out fDummy) && fDummy >= -10.0f && fDummy <= 10.0f) return true;
break;
case 3:
case 3:
if (strValue.Equals(Strings.yes) || strValue.Equals(Strings.no)) return true;
break;
case 4:
case 5:
if (int.TryParse(strValue, out iDummy) && iDummy >= 1000 && iDummy <= 8000) return true;
break;
case 5:
case 6:
for (Counting c = 0; c < Counting.Count; c++) if (c.ToString().Equals(strValue)) return true;
break;
case 6: /// WMType_ID
case 7: /// WMType_ID
if (int.TryParse(strValue, out iDummy)) return true;
break;
case 7: /// InitQ2CorrLR
case 8: /// InitQ2CorrRL
case 8: /// InitQ2CorrLR
case 9: /// InitQ2CorrRL
if (int.TryParse(strValue, out iDummy) || (iDummy < -127) || (iDummy > 127)) return true;
break;
default:
@@ -161,6 +170,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication.iPerlHead
prms.MeterType = this.MeterType;
prms.CalibTarget = this.CalibTarget;
prms.CalibTargetQ2 = this.CalibTargetQ2;
prms.DoQ2CorrInside05pct = this.DoQ2CorrInside05pct;
prms.FactorLimitLo = this.FactorLimitLo;
prms.FactorLimitHi = this.FactorLimitHi;
prms.Counting = this.Counting;
@@ -63,7 +63,7 @@ namespace TBF.BenchControl.Various.ErrorFlags
|| ProcessData.TempDownStat.Max > ProcessData.TempDownStat.Average + errorsCfg.TestParams.Delta_T;
/// Max. absolute value of up and down water temperature difference
bool E5 = ProcessData.TempDiffStat.Max > errorsCfg.TestParams.Delta_Tup_Tdn;
bool E5 = Math.Abs(ProcessData.TempUpStat.Average - ProcessData.TempDownStat.Average) > errorsCfg.TestParams.Delta_Tup_Tdn;
bool E6 = false;
+2 -2
View File
@@ -29,5 +29,5 @@ using System.Runtime.InteropServices;
// Build Number
// Revision
//
[assembly: AssemblyVersion("2.18.1355.0")]
[assembly: AssemblyFileVersion("2.18.1355.0")]
[assembly: AssemblyVersion("2.18.1422.0")]
[assembly: AssemblyFileVersion("2.18.1422.0")]
+64 -10
View File
@@ -150,6 +150,15 @@ namespace TBF.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to Abort session.
/// </summary>
internal static string Abort_session {
get {
return ResourceManager.GetString("Abort_session", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to About Test Bench Framework.
/// </summary>
@@ -1509,6 +1518,15 @@ namespace TBF.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to End session.
/// </summary>
internal static string End_session {
get {
return ResourceManager.GetString("End_session", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to End State.
/// </summary>
@@ -1860,6 +1878,15 @@ namespace TBF.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to Flood.
/// </summary>
internal static string Flood {
get {
return ResourceManager.GetString("Flood", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Flow.
/// </summary>
@@ -1968,6 +1995,15 @@ namespace TBF.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to Grabbing images.
/// </summary>
internal static string Grabbing_images {
get {
return ResourceManager.GetString("Grabbing_images", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Graphs.
/// </summary>
@@ -3138,6 +3174,15 @@ namespace TBF.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to Pipeline.
/// </summary>
internal static string Pipeline {
get {
return ResourceManager.GetString("Pipeline", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Please change the following settings:.
/// </summary>
@@ -4677,6 +4722,15 @@ namespace TBF.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to Start cycle.
/// </summary>
internal static string Start_cycle {
get {
return ResourceManager.GetString("Start_cycle", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Start the pump.
/// </summary>
@@ -4687,7 +4741,7 @@ namespace TBF.Resources {
}
/// <summary>
/// Looks up a localized string similar to Start the test.
/// Looks up a localized string similar to Start test.
/// </summary>
internal static string Start_the_test {
get {
@@ -4749,6 +4803,15 @@ namespace TBF.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to Stop.
/// </summary>
internal static string Stop {
get {
return ResourceManager.GetString("Stop", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Stop the pump.
/// </summary>
@@ -4794,15 +4857,6 @@ namespace TBF.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to .
/// </summary>
internal static string String1 {
get {
return ResourceManager.GetString("String1", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Supress WM trills.
/// </summary>
File diff suppressed because it is too large Load Diff
+22 -4
View File
@@ -487,7 +487,7 @@
<value>Start the pump</value>
</data>
<data name="Start_the_test" xml:space="preserve">
<value>Start the test</value>
<value>Start test</value>
</data>
<data name="Stopping" xml:space="preserve">
<value>Stopping</value>
@@ -1831,9 +1831,6 @@
<data name="Pressure" xml:space="preserve">
<value>Pressure</value>
</data>
<data name="String1" xml:space="preserve">
<value />
</data>
<data name="Flow_adjustment_failed" xml:space="preserve">
<value>Flow adjustment failed</value>
</data>
@@ -2074,4 +2071,25 @@
<data name="Draining_before" xml:space="preserve">
<value>Draining before</value>
</data>
<data name="Abort_session" xml:space="preserve">
<value>Abort session</value>
</data>
<data name="End_session" xml:space="preserve">
<value>End session</value>
</data>
<data name="Flood" xml:space="preserve">
<value>Flood</value>
</data>
<data name="Pipeline" xml:space="preserve">
<value>Pipeline</value>
</data>
<data name="Start_cycle" xml:space="preserve">
<value>Start cycle</value>
</data>
<data name="Stop" xml:space="preserve">
<value>Stop</value>
</data>
<data name="Grabbing_images" xml:space="preserve">
<value>Grabbing images</value>
</data>
</root>
+44 -22
View File
@@ -39,7 +39,7 @@
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>TRACE;DEBUG;MUNICH;CAMERA</DefineConstants>
<DefineConstants>TRACE;DEBUG;FUZHOU_300;STABLE_MASS_EXTRAS</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
@@ -49,7 +49,7 @@
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE;MUNICH;CAMERA</DefineConstants>
<DefineConstants>TRACE;FUZHOU_300;STABLE_MASS_EXTRAS</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<PlatformTarget>x86</PlatformTarget>
@@ -58,7 +58,7 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x86'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>TRACE;DEBUG;MUNICH;CAMERA</DefineConstants>
<DefineConstants>TRACE;DEBUG;FUZHOU_300;STABLE_MASS_EXTRAS</DefineConstants>
<DebugType>full</DebugType>
<PlatformTarget>x86</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
@@ -67,7 +67,7 @@
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'">
<OutputPath>bin\x86\Release\</OutputPath>
<DefineConstants>TRACE;MUNICH;CAMERA</DefineConstants>
<DefineConstants>TRACE;FUZHOU_300;STABLE_MASS_EXTRAS</DefineConstants>
<Optimize>true</Optimize>
<DebugType>pdbonly</DebugType>
<PlatformTarget>x86</PlatformTarget>
@@ -97,8 +97,8 @@
<SignManifests>false</SignManifests>
</PropertyGroup>
<ItemGroup>
<Reference Include="ControlComponent3Munich">
<HintPath>..\packages\ControlBoard\Munich\ControlComponent3Munich.dll</HintPath>
<Reference Include="ControlComponent3U">
<HintPath>..\packages\ControlBoard\Fuzhou300\ControlComponent3U.dll</HintPath>
</Reference>
<Reference Include="FluentNHibernate">
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
@@ -990,9 +990,6 @@
<DependentUpon>PrinterCfgCtrl.cs</DependentUpon>
</Compile>
<Compile Include="BenchControl\Output\Printers\Label\Factory.cs" />
<Compile Include="BenchControl\Output\Printers\Label\PrintLabelDocument.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="BenchControl\Output\Printers\Munich\Printer.cs" />
<Compile Include="BenchControl\Output\Printers\Munich\PrinterCfg.cs" />
<Compile Include="BenchControl\Output\Printers\Munich\PrinterCfgCtrl.cs">
@@ -1148,22 +1145,38 @@
<Compile Include="BenchControl\TestMethods\FixedStartAdvanced\FixedStartAdvancedSeq.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartAdvanced\Single\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartAdvanced\Single\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\Compound\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\Compound\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\FixedStartDeferredEvaluationSeq.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\HeatMeters\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\HeatMeters\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\HeatMeters\TestMethodCfg.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\HeatMeters\TestMethodCfgCtrl.cs">
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\Compound\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\Compound\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\FixedStartDeferredEvalSeq.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\HeatMeters\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\HeatMeters\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\HeatMeters\TestMethodCfg.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\HeatMeters\TestMethodCfgCtrl.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\HeatMeters\TestMethodCfgCtrl.designer.cs">
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\HeatMeters\TestMethodCfgCtrl.designer.cs">
<DependentUpon>TestMethodCfgCtrl.cs</DependentUpon>
</Compile>
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\HeatMeters\TestParams.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\IntermediateData.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\Single\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\Single\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\HeatMeters\TestParams.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\IntermediateData.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\Single\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartDeferredEval\Single\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\Compound\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\Compound\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\FixedStartMassCollDeferredEvalSeq.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\HeatMeters\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\HeatMeters\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\HeatMeters\TestMethodCfg.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\HeatMeters\TestMethodCfgCtrl.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\HeatMeters\TestMethodCfgCtrl.designer.cs">
<DependentUpon>TestMethodCfgCtrl.cs</DependentUpon>
</Compile>
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\HeatMeters\TestParams.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\IntermediateData.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\Single\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\Single\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollection\Compound\Component.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollection\Compound\Factory.cs" />
<Compile Include="BenchControl\TestMethods\FixedStartMassCollection\HeatMeters\Component.cs" />
@@ -2846,7 +2859,10 @@
<EmbeddedResource Include="BenchControl\TestMethods\Endurance\CycleDlg.ru.resx">
<DependentUpon>CycleDlg.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="BenchControl\TestMethods\FixedStartDeferredEvaluation\HeatMeters\TestMethodCfgCtrl.resx">
<EmbeddedResource Include="BenchControl\TestMethods\FixedStartDeferredEval\HeatMeters\TestMethodCfgCtrl.resx">
<DependentUpon>TestMethodCfgCtrl.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="BenchControl\TestMethods\FixedStartMassCollDeferredEval\HeatMeters\TestMethodCfgCtrl.resx">
<DependentUpon>TestMethodCfgCtrl.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="BenchControl\TestMethods\FixedStartTankCollection\Compound\TestMethodCfgCtrl.resx">
@@ -3092,6 +3108,9 @@
<EmbeddedResource Include="UI\MainWnd.de.resx">
<DependentUpon>MainWnd.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="UI\MainWnd.fr.resx">
<DependentUpon>MainWnd.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="UI\MainWnd.it.resx">
<DependentUpon>MainWnd.cs</DependentUpon>
</EmbeddedResource>
@@ -3191,6 +3210,9 @@
<EmbeddedResource Include="UI\Shared\BenchControlPanel.de.resx">
<DependentUpon>BenchControlPanel.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="UI\Shared\BenchControlPanel.fr.resx">
<DependentUpon>BenchControlPanel.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="UI\Shared\BenchControlPanel.it.resx">
<DependentUpon>BenchControlPanel.cs</DependentUpon>
</EmbeddedResource>
+2 -2
View File
@@ -54,7 +54,7 @@ namespace TBF.UI
this.horizontalSplitContainer = new System.Windows.Forms.SplitContainer();
this.mainTabControl = new System.Windows.Forms.TabControl();
this.homeTabPage = new System.Windows.Forms.TabPage();
this.ctrlBrdComponent = new ControlComponent3Munich.UserControl1();
this.ctrlBrdComponent = new ControlComponent3F300.UserControl1();
this.processTabPage = new System.Windows.Forms.TabPage();
this.processTabPageCtrl = new TBF.UI.Process.ProcessTabPageCtrl6();
this.insertTabPage = new System.Windows.Forms.TabPage();
@@ -700,7 +700,7 @@ namespace TBF.UI
#elif BADGER_MALA_TRAT || BADGER_STREDNA_TRAT || BADGER_VELKA_TRAT || SLM_END || WARSAW_END || RUM_MOB || SENTEC || CEVAK_200 || DEWA_300
private ControlComponent_Torino2015.UserControl1 ctrlBrdComponent;
private Process.ProcessTabPageCtrl6 processTabPageCtrl;
#elif TORINO_50 || TORUN_50 || CEVAK_40 || MURES_40 || FUZHOU_50 || MALTA_WSD25 || PETERSBURG_50 || KEMPNO_50 || BAHRAIN_50 || KRAKOW_50 || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || FUZHOU_100
#elif TORINO_50 || TORUN_50 || CEVAK_40 || MURES_40 || FUZHOU_50 || MALTA_WSD25 || PETERSBURG_50 || KEMPNO_50 || BAHRAIN_50 || KRAKOW_50 || JUZNA_AFRIKA_50 || IZRAEL_25 || ZAMBIA || ZODINO || FEWA_50 || FILIPINY_50 || FUZHOU_100 || ALZIR_25
private ControlComponent_Torino2015.UserControl1 ctrlBrdComponent;
private Process.ProcessTabPageCtrl24 processTabPageCtrl;
#elif TURA_SPECIAL || SLM_50
+259
View File
@@ -0,0 +1,259 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="benchComponentsTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="benchComponentsTSMenuItem.Text" xml:space="preserve">
<value>Composants</value>
</data>
<data name="benchPathsTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="benchPathsTSMenuItem.Text" xml:space="preserve">
<value>Routes</value>
</data>
<data name="benchTransitionsToolStripMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="benchTransitionsToolStripMenuItem.Text" xml:space="preserve">
<value>Les transitions</value>
</data>
<data name="benchMetrologyTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="benchMetrologyTSMenuItem.Text" xml:space="preserve">
<value>Métrologie</value>
</data>
<data name="toolStripSeparator1.Size" type="System.Drawing.Size, System.Drawing">
<value>184, 6</value>
</data>
<data name="exitToolStripMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="exitToolStripMenuItem.Text" xml:space="preserve">
<value>Sortie du programme</value>
</data>
<data name="benchTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>45, 20</value>
</data>
<data name="benchTSMenuItem.Text" xml:space="preserve">
<value>Banc</value>
</data>
<data name="homeTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>66, 20</value>
</data>
<data name="homeTSMenuItem.Text" xml:space="preserve">
<value>Domicile</value>
</data>
<data name="logsTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>99, 20</value>
</data>
<data name="logsTSMenuItem.Text" xml:space="preserve">
<value>Enregistrement</value>
</data>
<data name="usersTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="usersTSMenuItem.Text" xml:space="preserve">
<value>Utilisateurs</value>
</data>
<data name="languageTSMItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="languageTSMItem.Text" xml:space="preserve">
<value>Langue</value>
</data>
<data name="databaseSettingsTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="databaseSettingsTSMenuItem.Text" xml:space="preserve">
<value>Les profils</value>
</data>
<data name="backUpResultsTSMItem.Text" xml:space="preserve">
<value>Résultatas</value>
</data>
<data name="backUpTSMItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="backUpTSMItem.Text" xml:space="preserve">
<value>Sauvegarder</value>
</data>
<data name="passwdTSMItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="passwdTSMItem.Text" xml:space="preserve">
<value>Mot passe</value>
</data>
<data name="upgradeTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="upgradeTSMenuItem.Text" xml:space="preserve">
<value>Améliorer</value>
</data>
<data name="iPerlHeadsToolStripMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="clearCountersToolStripMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>187, 22</value>
</data>
<data name="clearCountersToolStripMenuItem.Text" xml:space="preserve">
<value>Effacer les compteurs</value>
</data>
<data name="editTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>78, 20</value>
</data>
<data name="editTSMenuItem.Text" xml:space="preserve">
<value>Paramètres</value>
</data>
<data name="aboutTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>152, 22</value>
</data>
<data name="aboutTSMenuItem.Text" xml:space="preserve">
<value>à propos</value>
</data>
<data name="helpTSMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>74, 20</value>
</data>
<data name="helpTSMenuItem.Text" xml:space="preserve">
<value>Aidez-moi</value>
</data>
<data name="proceduresToolStripMenuItem.Text" xml:space="preserve">
<value>Procédures</value>
</data>
<data name="processToolStripMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>71, 20</value>
</data>
<data name="processToolStripMenuItem.Text" xml:space="preserve">
<value>Processus</value>
</data>
<data name="resultsToolStripMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>66, 20</value>
</data>
<data name="resultsToolStripMenuItem.Text" xml:space="preserve">
<value>Résultats</value>
</data>
<data name="graphsToolStripMenuItem.Size" type="System.Drawing.Size, System.Drawing">
<value>79, 20</value>
</data>
<data name="graphsToolStripMenuItem.Text" xml:space="preserve">
<value>Graphiques</value>
</data>
</root>
+1290 -1290
View File
File diff suppressed because it is too large Load Diff
+8
View File
@@ -153,6 +153,14 @@ namespace TBF.UI.Shared
void Localize()
{
testGroupBox.Text = Strings.Session;
startTestBtn.Text = Strings.Start_the_test;
startCycleBtn.Text = Strings.Start_cycle;
acceptResultsBtn.Text = Strings.End_session;
breakBtn.Text = Strings.Abort_session;
stopBtn.Text = Strings.Stop;
purgeGroupBox.Text = Strings.Pipeline;
purgeBeginBtn.Text = Strings.Flood;
purgeEndBtn.Text = Strings.Drain;
emptyGroupBox.Text = Strings.Drain;
}
+169
View File
@@ -0,0 +1,169 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="stopBtn.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 14.25pt</value>
</data>
<data name="stopBtn.Text" xml:space="preserve">
<value>Arrêtez</value>
</data>
<data name="startTestBtn.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 14.25pt</value>
</data>
<data name="startTestBtn.Text" xml:space="preserve">
<value>Commencer test</value>
</data>
<data name="startCycleBtn.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 14.25pt</value>
</data>
<data name="startCycleBtn.Text" xml:space="preserve">
<value>Commencer cycle</value>
</data>
<data name="purgeBeginBtn.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 12pt</value>
</data>
<data name="purgeBeginBtn.Text" xml:space="preserve">
<value>Inonder</value>
</data>
<data name="purgeEndBtn.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 12pt</value>
</data>
<data name="purgeEndBtn.Text" xml:space="preserve">
<value>Vidanger</value>
</data>
<data name="breakBtn.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 14.25pt</value>
</data>
<data name="breakBtn.Text" xml:space="preserve">
<value>Abandonner</value>
</data>
<data name="acceptResultsBtn.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 14.25pt</value>
</data>
<data name="acceptResultsBtn.Text" xml:space="preserve">
<value>Fin de session</value>
</data>
<data name="purgeGroupBox.Text" xml:space="preserve">
<value>Pipeline</value>
</data>
<data name="emptyGroupBox.Text" xml:space="preserve">
<value>Vidanger réservoir</value>
</data>
</root>
+52 -49
View File
@@ -120,20 +120,16 @@
<data name="emptyTank3Btn.Text" xml:space="preserve">
<value>W3</value>
</data>
<data name="&gt;&gt;sensitivityTestBtn.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="startTestBtn.Text" xml:space="preserve">
<value>Start test</value>
</data>
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<data name="purgeBeginBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="testComboBox.Location" type="System.Drawing.Point, System.Drawing">
<value>8, 68</value>
</data>
<data name="&gt;&gt;emptyTank1Btn.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="startCycleBtn.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 15.75pt</value>
</data>
@@ -149,6 +145,7 @@
<data name="&gt;&gt;emptyGroupBox.ZOrder" xml:space="preserve">
<value>5</value>
</data>
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<data name="startQ2Btn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
@@ -171,6 +168,9 @@
<data name="&gt;&gt;cameraTestBtn.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="groupBox1.Text" xml:space="preserve">
<value>Results</value>
</data>
<data name="&gt;&gt;emptyTank2Btn.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
@@ -189,6 +189,9 @@
<data name="emptyTank3Btn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="acceptResultsBtn.Size" type="System.Drawing.Size, System.Drawing">
<value>190, 38</value>
</data>
<data name="emptyGroupBox.TabIndex" type="System.Int32, mscorlib">
<value>19</value>
</data>
@@ -240,8 +243,8 @@
<data name="purgeGroupBox.Location" type="System.Drawing.Point, System.Drawing">
<value>7, 355</value>
</data>
<data name="breakBtn.TabIndex" type="System.Int32, mscorlib">
<value>10</value>
<data name="emptyGroupBox.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 12pt</value>
</data>
<data name="&gt;&gt;emptyTank3Btn.Name" xml:space="preserve">
<value>emptyTank3Btn</value>
@@ -285,9 +288,6 @@
<data name="&gt;&gt;startQ3Btn.Name" xml:space="preserve">
<value>startQ3Btn</value>
</data>
<data name="breakBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="&gt;&gt;emptyGroupBox.Name" xml:space="preserve">
<value>emptyGroupBox</value>
</data>
@@ -339,9 +339,15 @@
<data name="&gt;&gt;purgeEndBtn.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="startTestBtn.Size" type="System.Drawing.Size, System.Drawing">
<value>190, 38</value>
</data>
<data name="groupBox1.TabIndex" type="System.Int32, mscorlib">
<value>22</value>
</data>
<data name="&gt;&gt;purgeGroupBox.Name" xml:space="preserve">
<value>purgeGroupBox</value>
</data>
<data name="nextButton.TabIndex" type="System.Int32, mscorlib">
<value>21</value>
</data>
@@ -402,15 +408,15 @@
<data name="startCycleBtn.Location" type="System.Drawing.Point, System.Drawing">
<value>8, 142</value>
</data>
<data name="testGroupBox.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 12pt</value>
</data>
<data name="&gt;&gt;stopBtn.ZOrder" xml:space="preserve">
<value>8</value>
</data>
<data name="sensitivityTestBtn.TabIndex" type="System.Int32, mscorlib">
<value>14</value>
</data>
<data name="&gt;&gt;startQ2Btn.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="purgeEndBtn.Size" type="System.Drawing.Size, System.Drawing">
<value>92, 35</value>
</data>
@@ -444,8 +450,8 @@
<data name="emptyGroupBox.Text" xml:space="preserve">
<value>Drain water tank</value>
</data>
<data name="&gt;&gt;breakBtn.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
<data name="purgeBeginBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="emptyTank2Btn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
@@ -474,6 +480,9 @@
<data name="&gt;&gt;purgeEndBtn.Parent" xml:space="preserve">
<value>purgeGroupBox</value>
</data>
<data name="&gt;&gt;customButton.Name" xml:space="preserve">
<value>customButton</value>
</data>
<data name="groupBox1.Location" type="System.Drawing.Point, System.Drawing">
<value>7, 588</value>
</data>
@@ -489,8 +498,8 @@
<data name="resetResultsBtn.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 15.75pt</value>
</data>
<data name="acceptResultsBtn.Size" type="System.Drawing.Size, System.Drawing">
<value>190, 38</value>
<data name="&gt;&gt;emptyTank3Btn.Parent" xml:space="preserve">
<value>emptyGroupBox</value>
</data>
<data name="testGroupBox.Text" xml:space="preserve">
<value>Session</value>
@@ -543,9 +552,6 @@
<data name="startTestBtn.TabIndex" type="System.Int32, mscorlib">
<value>4</value>
</data>
<data name="purgeEndBtn.TabIndex" type="System.Int32, mscorlib">
<value>9</value>
</data>
<data name="$this.Size" type="System.Drawing.Size, System.Drawing">
<value>224, 736</value>
</data>
@@ -555,8 +561,8 @@
<data name="&gt;&gt;emptyTank2Btn.Name" xml:space="preserve">
<value>emptyTank2Btn</value>
</data>
<data name="emptyGroupBox.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 12pt</value>
<data name="emptyGroupBox.Size" type="System.Drawing.Size, System.Drawing">
<value>207, 68</value>
</data>
<data name="&gt;&gt;acceptResultsBtn.Name" xml:space="preserve">
<value>acceptResultsBtn</value>
@@ -567,9 +573,6 @@
<data name="&gt;&gt;nextButton.ZOrder" xml:space="preserve">
<value>4</value>
</data>
<data name="&gt;&gt;emptyTank3Btn.Parent" xml:space="preserve">
<value>emptyGroupBox</value>
</data>
<data name="&gt;&gt;emptyTank1Btn.Parent" xml:space="preserve">
<value>emptyGroupBox</value>
</data>
@@ -579,12 +582,6 @@
<data name="&gt;&gt;cameraTestBtn.Name" xml:space="preserve">
<value>cameraTestBtn</value>
</data>
<data name="nextButton.Enabled" type="System.Boolean, mscorlib">
<value>False</value>
</data>
<data name="testComboBox.Location" type="System.Drawing.Point, System.Drawing">
<value>8, 68</value>
</data>
<data name="&gt;&gt;startQ2Btn.Parent" xml:space="preserve">
<value>testGroupBox</value>
</data>
@@ -648,8 +645,8 @@
<data name="testComboBox.Size" type="System.Drawing.Size, System.Drawing">
<value>190, 33</value>
</data>
<data name="cameraTestBtn.Location" type="System.Drawing.Point, System.Drawing">
<value>112, 537</value>
<data name="breakBtn.TabIndex" type="System.Int32, mscorlib">
<value>10</value>
</data>
<data name="$this.AutoScaleDimensions" type="System.Drawing.SizeF, System.Drawing">
<value>9, 18</value>
@@ -678,11 +675,11 @@
<data name="&gt;&gt;startCycleBtn.ZOrder" xml:space="preserve">
<value>7</value>
</data>
<data name="startTestBtn.Size" type="System.Drawing.Size, System.Drawing">
<value>190, 38</value>
<data name="&gt;&gt;breakBtn.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="emptyGroupBox.Size" type="System.Drawing.Size, System.Drawing">
<value>207, 68</value>
<data name="&gt;&gt;startQ3Btn.Parent" xml:space="preserve">
<value>testGroupBox</value>
</data>
<data name="&gt;&gt;testGroupBox.Parent" xml:space="preserve">
<value>$this</value>
@@ -747,11 +744,11 @@
<data name="&gt;&gt;resetResultsBtn.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="testGroupBox.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 12pt</value>
<data name="&gt;&gt;sensitivityTestBtn.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;purgeGroupBox.Name" xml:space="preserve">
<value>purgeGroupBox</value>
<data name="&gt;&gt;startQ2Btn.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;emptyGroupBox.Type" xml:space="preserve">
<value>System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
@@ -780,8 +777,8 @@
<data name="startQ1Btn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="&gt;&gt;customButton.Name" xml:space="preserve">
<value>customButton</value>
<data name="nextButton.Enabled" type="System.Boolean, mscorlib">
<value>False</value>
</data>
<data name="startQ3Btn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
@@ -789,8 +786,11 @@
<data name="startQ3Btn.Font" type="System.Drawing.Font, System.Drawing">
<value>Verdana, 15.75pt</value>
</data>
<data name="&gt;&gt;startQ3Btn.Parent" xml:space="preserve">
<value>testGroupBox</value>
<data name="breakBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="cameraTestBtn.Location" type="System.Drawing.Point, System.Drawing">
<value>112, 537</value>
</data>
<data name="nextButton.Text" xml:space="preserve">
<value>Next</value>
@@ -798,8 +798,8 @@
<data name="&gt;&gt;emptyTank1Btn.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="groupBox1.Text" xml:space="preserve">
<value>Results</value>
<data name="purgeEndBtn.TabIndex" type="System.Int32, mscorlib">
<value>9</value>
</data>
<data name="stopBtn.Size" type="System.Drawing.Size, System.Drawing">
<value>92, 72</value>
@@ -831,4 +831,7 @@
<metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="$this.Language" type="System.Globalization.CultureInfo, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>fr</value>
</metadata>
</root>
-6
View File
@@ -136,12 +136,6 @@
<None Include="app.config" />
<None Include="packages.config" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\RecordProcessing\RecordProcessing.csproj">
<Project>{67BD7A8F-0FED-4FDE-B875-78D5A2BC9B2C}</Project>
<Name>RecordProcessing</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
+240
View File
@@ -0,0 +1,240 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="AddBtnText" xml:space="preserve">
<value>Ajouter</value>
</data>
<data name="CancelBtnText" xml:space="preserve">
<value>Annuler exte Btn</value>
</data>
<data name="DescriptionColHdr" xml:space="preserve">
<value>Description</value>
</data>
<data name="EditBtnText" xml:space="preserve">
<value>Éditer</value>
</data>
<data name="Edit_User" xml:space="preserve">
<value>Modifier utilisateur</value>
</data>
<data name="Error" xml:space="preserve">
<value>Erreur</value>
</data>
<data name="Full_name" xml:space="preserve">
<value>Nom complet</value>
</data>
<data name="Groups" xml:space="preserve">
<value>Groupes</value>
</data>
<data name="ID" xml:space="preserve">
<value>ID</value>
</data>
<data name="Invalid_username_or_password" xml:space="preserve">
<value>Nom ou mot passe utilisateur non valide </value>
</data>
<data name="max_0_alphanum_chars" xml:space="preserve">
<value>max {0} caractères alphanum</value>
</data>
<data name="Name" xml:space="preserve">
<value>Prénom</value>
</data>
<data name="OkBtnText" xml:space="preserve">
<value>Ok</value>
</data>
<data name="Password" xml:space="preserve">
<value>Mot de passe</value>
</data>
<data name="RemoveBtnText" xml:space="preserve">
<value>Supprimer</value>
</data>
<data name="Repeat_password" xml:space="preserve">
<value>Répéter mot passe</value>
</data>
<data name="Username_taken" xml:space="preserve">
<value>Ce nom d'utilisateur a déjà été pris. Veuillez en choisir un autre.</value>
</data>
<data name="User_code" xml:space="preserve">
<value>Code utilisateur</value>
</data>
<data name="User_Login" xml:space="preserve">
<value>Utilisateur en ligne</value>
</data>
<data name="User_Management" xml:space="preserve">
<value>Gestion utilisateurs</value>
</data>
<data name="User_name" xml:space="preserve">
<value>Nom d'utilisateur</value>
</data>
<data name="CloseBtnText" xml:space="preserve">
<value>Fermer</value>
</data>
<data name="No_remote_database_of_users" xml:space="preserve">
<value>Pas télécommande sur base utilisateurs</value>
</data>
<data name="Are_you_sure" xml:space="preserve">
<value>Êtes-vous sûr ?</value>
</data>
<data name="Warning" xml:space="preserve">
<value>Attention</value>
</data>
<data name="Confirmation" xml:space="preserve">
<value>Confirmation</value>
</data>
<data name="N_users_copied" xml:space="preserve">
<value>{0} utilisateurs copiés</value>
</data>
<data name="Copying_remote_users_failed" xml:space="preserve">
<value>Copie utilisateurs a échoué</value>
</data>
<data name="Save_or_update_user_failed" xml:space="preserve">
<value>Enregistrement ou mise à jour utilisateur a échoué</value>
</data>
<data name="administrator" xml:space="preserve">
<value>administrateur</value>
</data>
<data name="calibration_specialist" xml:space="preserve">
<value>spécialiste étalonnages</value>
</data>
<data name="head_of_lab" xml:space="preserve">
<value>chef laboratoire</value>
</data>
<data name="maintenance" xml:space="preserve">
<value>entretien</value>
</data>
<data name="metrologist" xml:space="preserve">
<value>métrologue</value>
</data>
<data name="specialist" xml:space="preserve">
<value>spécialiste</value>
</data>
<data name="tester" xml:space="preserve">
<value>testeur</value>
</data>
<data name="invalid" xml:space="preserve">
<value>invalide</value>
</data>
<data name="Tag" xml:space="preserve">
<value>NFC tag</value>
</data>
<data name="Tag_taken" xml:space="preserve">
<value>Ce tag NFC a déjà été pris. S'il vous plaît utiliser un autre.</value>
</data>
<data name="production_tracing_administrator" xml:space="preserve">
<value>administrateur suivi production</value>
</data>
</root>
+1
View File
@@ -122,6 +122,7 @@
</EmbeddedResource>
<EmbeddedResource Include="Resources\Strings.cs.resx" />
<EmbeddedResource Include="Resources\Strings.de.resx" />
<EmbeddedResource Include="Resources\Strings.fr.resx" />
<EmbeddedResource Include="Resources\Strings.pl.resx" />
<EmbeddedResource Include="Resources\Strings.resx">
<Generator>ResXFileCodeGenerator</Generator>
File diff suppressed because it is too large Load Diff
Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More