'Route' type changes from uint to Dirichlet.Numerics.UInt128
This commit is contained in:
parent
be52e2df96
commit
d5f91e9bab
@ -6,6 +6,7 @@ using System.Text;
|
||||
using System.IO.Ports;
|
||||
using System.Collections.Generic;
|
||||
using Config.Entities;
|
||||
using Dirichlet.Numerics;
|
||||
using TBF.BenchControl.Generic;
|
||||
using TBF.BenchControl.GenericDevices;
|
||||
using log4net;
|
||||
@ -49,7 +50,7 @@ namespace TBF.BenchControl.Elde
|
||||
public float Pressure(int prsNr0) { return controlCom.Pressure(prsNr0); }
|
||||
public float Temperature(int tmpNr0) { return controlCom.Temperature(tmpNr0); }
|
||||
public RegulValveState RegulValveState(int rvNr1) { return (RegulValveState)controlCom.RegulValveState(rvNr1); }
|
||||
public ulong RRoute { get { return controlCom.RRoute; } }
|
||||
public UInt128 RRoute { get { return controlCom.RRoute; } }
|
||||
public uint DivTime { get { return controlCom.DivTime; } }
|
||||
public float TTime { get { return controlCom.TTime; } }
|
||||
public uint FmState { get { return controlCom.FmState; } }
|
||||
|
||||
@ -4,6 +4,7 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using Dirichlet.Numerics;
|
||||
using log4net;
|
||||
|
||||
namespace TBF.BenchControl.Elde
|
||||
@ -47,7 +48,7 @@ namespace TBF.BenchControl.Elde
|
||||
public float Temperature(int tmpNr0) { return (float)(20 + tmpNr0); }
|
||||
public RegulValveState RegulValveState(int rvNr1) { return 0; }
|
||||
|
||||
public ulong RRoute { get { return simRoute; } }
|
||||
public UInt128 RRoute { get { return simRoute; } }
|
||||
|
||||
public uint DivTime { get { return 0; } }
|
||||
|
||||
@ -93,7 +94,7 @@ namespace TBF.BenchControl.Elde
|
||||
///
|
||||
Command cmd;
|
||||
int refFlowmtrNr;
|
||||
ulong simRoute;
|
||||
UInt128 simRoute;
|
||||
int totalRefPulses;
|
||||
int massRefPulses;
|
||||
TestMethods testMethods;
|
||||
@ -156,7 +157,7 @@ namespace TBF.BenchControl.Elde
|
||||
/// <param name="regConst">Coefficient used to control reg. valves (1..100)</param>
|
||||
/// <param name="shortImp">0 = default value, 1 = spec. processing of very short pulses</param>
|
||||
/// <param name="stopDevs">What to stop</param>
|
||||
public void SendCommand(Command cmd, int refFlowmtrNr, ulong route,
|
||||
public void SendCommand(Command cmd, int refFlowmtrNr, UInt128 route,
|
||||
int totalRefPulses, int massRefPulses, TestMethods testMethods,
|
||||
float filterConstant, float[] fmFreq, int regConst, int shortImp, StopDevs stopDevs)
|
||||
{
|
||||
@ -344,7 +345,7 @@ namespace TBF.BenchControl.Elde
|
||||
}
|
||||
|
||||
StatusP lastStatusP;
|
||||
ulong lastRoute;
|
||||
UInt128 lastRoute;
|
||||
|
||||
public void RunDeviceAfter()
|
||||
{
|
||||
@ -357,7 +358,7 @@ namespace TBF.BenchControl.Elde
|
||||
lastStatusP = bufferedStatusP;
|
||||
}
|
||||
|
||||
ulong bufferedRoute = simRoute;
|
||||
UInt128 bufferedRoute = simRoute;
|
||||
if (lastRoute != bufferedRoute)
|
||||
{
|
||||
string routeStr = bufferedRoute.ToString("x16");
|
||||
|
||||
@ -1,7 +1,8 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2015 Sensus Metering Systems
|
||||
/// Copyright (c) 2013-2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using Dirichlet.Numerics;
|
||||
using log4net;
|
||||
|
||||
namespace TBF.BenchControl.Elde
|
||||
@ -42,7 +43,11 @@ namespace TBF.BenchControl.Elde
|
||||
public float Pressure(int prsNr0) { return ctrlBrdComponent.pressure[prsNr0]; }
|
||||
public float Temperature(int tmpNr0) { return ctrlBrdComponent.temperature[tmpNr0]; }
|
||||
public RegulValveState RegulValveState(int rvNr1) { return (RegulValveState)ctrlBrdComponent.rValveStatus[rvNr1 - 1]; }
|
||||
public ulong RRoute { get { return ctrlBrdComponent.rRoute; } }
|
||||
#if GENESIS
|
||||
public UInt128 RRoute { get { return ctrlBrdComponent.rRoute; } }
|
||||
#else
|
||||
public UInt128 RRoute { get { return ctrlBrdComponent.rRoute; } }
|
||||
#endif
|
||||
public uint DivTime { get { return ctrlBrdComponent.divTime; } }
|
||||
public float TTime { get { return ctrlBrdComponent.Ttime; } }
|
||||
#if DN100 || MUNICH || FUZHOU150
|
||||
@ -63,7 +68,7 @@ namespace TBF.BenchControl.Elde
|
||||
public float AnalogInput(int adcNr0) { return ctrlBrdComponent.Analogy[adcNr0]; }
|
||||
public uint AnalogInputRaw(int adcNr0, int bank) { return ctrlBrdComponent.AnalogyRaw[adcNr0, bank]; } /// bank0=RV, bank1=Temp
|
||||
|
||||
#if DN100 || MUNICH || BADGER_MALA_TRAT || BADGER_VELKA_TRAT || FUZHOU40 || FUZHOU150 || FUZHOU300 || PT200IL || PUCHONG_PT200 || TORINO50 || TORUN_PT50_2015 || CEVAK_PT40_272 || MURES_PT40 || GENESIS
|
||||
#if DN100 || MUNICH || BADGER_MALA_TRAT || BADGER_VELKA_TRAT || FUZHOU40 || FUZHOU150 || FUZHOU300 || PT200IL || PUCHONG_PT200 || TORINO50 || TORUN_PT50_2015 || CEVAK_PT40_272 || MURES_PT40
|
||||
public float TotalRefVolume { get { return ctrlBrdComponent.ReferenceVolume; } }
|
||||
public float MassRefVolume { get { return ctrlBrdComponent.ReferenceVolume; } }
|
||||
#else
|
||||
@ -235,7 +240,7 @@ namespace TBF.BenchControl.Elde
|
||||
/// <param name="regConst">Coefficient used to control the regulation valve (1..100)</param>
|
||||
/// <param name="shortImp">0 = default value, 1 = spec. processing of very short pulses</param>
|
||||
/// <param name="stopDevs">What to stop</param>
|
||||
public void SendCommand(Command cmd, int refFlowMeterNr, ulong route,
|
||||
public void SendCommand(Command cmd, int refFlowMeterNr, UInt128 route,
|
||||
int totalRefPulses, int massRefPulses, TestMethods testMethods,
|
||||
float filterConstant, float[] fmFreq, int regConst, int shortImp, StopDevs stopDevs)
|
||||
{
|
||||
@ -254,11 +259,11 @@ namespace TBF.BenchControl.Elde
|
||||
}
|
||||
}
|
||||
///
|
||||
delegate void SendCommandDlgt(Command cmd, int refFlowmtrNr, ulong route,
|
||||
delegate void SendCommandDlgt(Command cmd, int refFlowmtrNr, UInt128 route,
|
||||
int totalRefPulses, int massRefPulses, TestMethods testMethods,
|
||||
float filterConstant, float[] fmFreq, int regConst, int shortImp, StopDevs stopDevs);
|
||||
///
|
||||
private void DoSendCommand(Command cmd, int refFlowMeterNr, ulong route,
|
||||
private void DoSendCommand(Command cmd, int refFlowMeterNr, UInt128 route,
|
||||
int totalRefPulses, int massRefPulses, TestMethods testMethods,
|
||||
float filterConstant, float[] fmFreq, int regConst, int shortImp, StopDevs stopDevs)
|
||||
{
|
||||
@ -305,16 +310,20 @@ namespace TBF.BenchControl.Elde
|
||||
#if DN100 || MUNICH
|
||||
ctrlBrdComponent.SendCommand((uint)cmd, (byte)refFlowMeterNr, (ulong)route, (uint)totalRefPulses, (uint)testMethods,
|
||||
filterConstant, fmFreq[0], (uint)regConst, (uint)shortImp, (uint)stopDevs);
|
||||
#elif BADGER_MALA_TRAT || BADGER_VELKA_TRAT || FUZHOU40 || FUZHOU150 || FUZHOU300 || PT200IL || PUCHONG_PT200 || TORINO50 || TORUN_PT50_2015 || CEVAK_PT40_272 || MURES_PT40 || GENESIS
|
||||
#elif BADGER_MALA_TRAT || BADGER_VELKA_TRAT || FUZHOU40 || FUZHOU150 || FUZHOU300 || PT200IL || PUCHONG_PT200 || TORINO50 || TORUN_PT50_2015 || CEVAK_PT40_272 || MURES_PT40
|
||||
ctrlBrdComponent.SendCommand((uint)cmd, (byte)refFlowMeterNr, (ulong)route, (uint)totalRefPulses, (uint)testMethods,
|
||||
filterConstant, fmFreq, (uint)regConst, (uint)shortImp, (uint)stopDevs);
|
||||
#elif GENESIS
|
||||
uint[] pulsesArr = new uint[] { (uint)totalRefPulses, (uint)massRefPulses };
|
||||
ctrlBrdComponent.SendCommand((uint)cmd, (byte)refFlowMeterNr, (ulong)route, 0, pulsesArr, (uint)testMethods,
|
||||
filterConstant, fmFreq, (uint)regConst, (uint)shortImp, (uint)stopDevs);
|
||||
#else /// if IPERLST || IPERLST_SPECIAL || MALTA_WSD25 || SLM_50 || SLM_END || WARSAW_END
|
||||
uint[] pulsesArr = new uint[] { (uint)totalRefPulses, (uint)massRefPulses };
|
||||
ctrlBrdComponent.SendCommand((uint)cmd, (byte)refFlowMeterNr, (ulong)route, pulsesArr, (uint)testMethods,
|
||||
filterConstant, fmFreq, (uint)regConst, (uint)shortImp, (uint)stopDevs);
|
||||
#endif
|
||||
|
||||
ulong bufferedRoute = route;
|
||||
UInt128 bufferedRoute = route;
|
||||
if (lastRoute != bufferedRoute)
|
||||
{
|
||||
string routeStr = bufferedRoute.ToString("x16");
|
||||
@ -333,7 +342,7 @@ namespace TBF.BenchControl.Elde
|
||||
|
||||
|
||||
private StatusP lastStatusP;
|
||||
private ulong lastRoute;
|
||||
private UInt128 lastRoute;
|
||||
|
||||
public void RunDeviceBefore()
|
||||
{
|
||||
|
||||
@ -2,6 +2,7 @@
|
||||
/// Copyright (c) 2013-2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using Dirichlet.Numerics;
|
||||
|
||||
namespace TBF.BenchControl.Elde
|
||||
{
|
||||
@ -17,7 +18,7 @@ namespace TBF.BenchControl.Elde
|
||||
float Pressure(int prsNr0);
|
||||
float Temperature(int tmpNr0);
|
||||
RegulValveState RegulValveState(int rvNr1);
|
||||
ulong RRoute { get; }
|
||||
UInt128 RRoute { get; }
|
||||
uint DivTime { get; }
|
||||
float TTime { get; }
|
||||
uint FmState { get; }
|
||||
@ -60,7 +61,7 @@ namespace TBF.BenchControl.Elde
|
||||
/// <param name="regConst">Coefficient used to control reg. valves (1..100)</param>
|
||||
/// <param name="shortImp">0 = default value, 1 = spec. processing of very short pulses</param>
|
||||
/// <param name="stopDevs">What to stop</param>
|
||||
void SendCommand(Command cmd, int refNr, ulong route, int totalRefPulses, int massRefPulses, TestMethods testMethods,
|
||||
void SendCommand(Command cmd, int refNr, UInt128 route, int totalRefPulses, int massRefPulses, TestMethods testMethods,
|
||||
float filterConstant, float[] fmFreq, int regConst, int shortImp, StopDevs stopDevs);
|
||||
|
||||
/// <summary>
|
||||
|
||||
@ -2,6 +2,7 @@
|
||||
/// Copyright (c) 2013-2015 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using Dirichlet.Numerics;
|
||||
using log4net;
|
||||
|
||||
namespace TBF.BenchControl
|
||||
@ -33,7 +34,7 @@ namespace TBF.BenchControl
|
||||
///
|
||||
/// Valves and diverters
|
||||
///
|
||||
public static ulong SimRoute;
|
||||
public static UInt128 SimRoute;
|
||||
public static bool Div1sim;
|
||||
public static bool Div2sim;
|
||||
public static bool Div3sim;
|
||||
|
||||
@ -130,6 +130,7 @@
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Deployment" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Numerics" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
@ -2173,6 +2174,10 @@
|
||||
<Project>{743DF7DB-C7B6-42EB-986D-0F485E5588E4}</Project>
|
||||
<Name>Config</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\Dirichlet.Numerics\Dirichlet.Numerics.csproj">
|
||||
<Project>{439D0878-C76E-452B-B17D-209A89E91D36}</Project>
|
||||
<Name>Dirichlet.Numerics</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\Results\Results.csproj">
|
||||
<Project>{9D0DCC88-DC81-47EB-9FDD-4C3907871BFB}</Project>
|
||||
<Name>Results</Name>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user