Masses are stored in double variables everywhere.

This commit is contained in:
Milan Hanajik
2016-10-07 14:06:54 +02:00
parent 9f2e8407a0
commit 4160420844
26 changed files with 104 additions and 111 deletions
@@ -255,7 +255,7 @@ namespace TBF.BenchControl.Elde
ControlComponent_Torino2015.UserControl1 ctrlBrdComponent,
#endif
ulong valvesToInvert,
float[] tankCapacities)
double[] tankCapacities)
{
this.valvesToInvert = valvesToInvert;
this.benchModelRoute = valvesToInvert;
@@ -67,7 +67,7 @@ namespace TBF.BenchControl.Elde
public uint AnalogInputRaw(int adcNr0, int bank) { return 0; } /// bank0=RV, bank1=Temp
public float TotalRefVolume { get { return 0; } }
public float VyslExt(int wmNr0, int what) { return 0; }
public void SetWeight(int pos, float mass) { return; } /// not available in sim. mode
public void SetWeight(int pos, double mass) { return; } /// not available in sim. mode
///
/// Private initialization data updated by contructors of children components
@@ -65,9 +65,9 @@ namespace TBF.BenchControl.Elde
public float MassRefVolume { get { return ctrlBrdComponent.ReferenceVolume; } }
#endif
public float VyslExt(int wmNr0, int what) { return ctrlBrdComponent.VyslExt[wmNr0, what]; }
public void SetWeight(int pos, float mass)
public void SetWeight(int pos, double mass)
{
ctrlBrdComponent.Weight[pos] = mass;
ctrlBrdComponent.Weight[pos] = (float)mass;
log.DebugFormat("SetWeight(pos={0}, mass={1}", pos, mass);
}
@@ -30,7 +30,7 @@ namespace TBF.BenchControl.Elde
uint AnalogInputRaw(int adcNr0, int bank);
float TotalRefVolume { get; }
float VyslExt(int wmNr0, int what);
void SetWeight(int pos, float mass);
void SetWeight(int pos, double mass);
/// <summary>
/// Sends calibration and configuration data to the control board.