- COmponent properties 'Position' --> 'Idx0' or 'Idx1'

- process data logging, RegulVal position logging
- changes for I11+I12, NOK yet
This commit is contained in:
Milan Hanajik
2014-09-10 12:05:49 +02:00
parent c3050863a6
commit fcfdfeca41
26 changed files with 165 additions and 101 deletions
@@ -7,8 +7,8 @@ namespace TBF.BenchControl.Elde.PressureMeter
{
public class PressureMeterCfg : ComponentCfgBase, Generic.IChildComponentCfg
{
public int Position; /// 0..7
public byte RS485Address; /// 0..255
public int Idx0; /// 0..3
public byte RS485Address; /// 0..255
/// Parameterless constructor
public PressureMeterCfg()
@@ -18,14 +18,14 @@ namespace TBF.BenchControl.Elde.PressureMeter
/// Regulation valve configuration parameters
/// </summary>
/// <param name="name">Regulation valve name</param>
/// <param name="index">Position on the control board 1..5</param>
/// <param name="idx0">Position on the control board 0..3</param>
/// <param name="dacValueClosed">0..1023</param>
/// <param name="dacValueOpen">0..1023</param>
public PressureMeterCfg(IComponentFactory factory, string name, string parentName, int index, byte rs485Address)
public PressureMeterCfg(IComponentFactory factory, string name, string parentName, int idx0, byte rs485Address)
: base(factory, name, parentName)
{
if (index < 0 || index > 7) throw new ArgumentOutOfRangeException("Position");
this.Position = index;
if (idx0 < 0 || idx0 > 3) throw new ArgumentOutOfRangeException("Index (0-based)");
this.Idx0 = idx0;
if (rs485Address < 0 || rs485Address > 255) throw new ArgumentOutOfRangeException("RS485Address");
this.RS485Address = rs485Address;
@@ -33,12 +33,12 @@ namespace TBF.BenchControl.Elde.PressureMeter
public IComponentCfg Clone()
{
return new PressureMeterCfg(Factory, Name, ParentName, Position, RS485Address);
return new PressureMeterCfg(Factory, Name, ParentName, Idx0, RS485Address);
}
public string ToString(int i)
{
return string.Format("index={0}, RS485 address={1}", Position, RS485Address);
return string.Format("idx0={0}, RS485 address={1}", Idx0, RS485Address);
}
public TBF.Entities.Component CreateDbEntity()