tbf/TestBenchFramework/BenchControl/GenericDevices/IRegulValve.cs

79 lines
3.2 KiB
C#

///
/// Copyright (c) 2013-2015 Sensus Metering Systems
///
using System;
using System.Collections.Generic;
using TBF.BenchControl.Generic;
using TBF.Boxes;
namespace TBF.BenchControl.GenericDevices
{
public interface IRegulValve : IComponent
{
/// <summary>
/// All, Feeding, Bench, Output or None
/// </summary>
ValveCategory Category { get; }
/// <summary>
/// true = The regulation valve is 4-20 mA current controlled coaxial valve
/// </summary>
bool IsCoax { get; }
/// <summary>
/// Regulation valve position 0.0 .. 100.0 %
/// </summary>
float Position { get; }
/// <summary>
/// Dictionary for position re-use
/// </summary>
IDictionary<float, float> Dict { get; }
/// <summary>
/// Operation to set the water flow within tolerances
/// Events: Event.None, Event.FlowReached, Event.FlowTimeOut
/// </summary>
/// <param name="requiredFlowLo">Lower limit of the required flow [m3/h]</param>
/// <param name="requiredFlowHi">Higher limit of the required flow [m3/h]</param>
/// <param name="pidCoef">PID coefficient (float)</param>
/// <param name="measuredFlow">Measured flow [m3/h]</param>
/// <param name="timeout">Timeout in [s]</param>
/// <returns>SetFlowOp instance</returns>
IOperation SetFlowOp(IFlowMeter flowMeter, float requiredFlowLo, float requiredFlowHi,
float pidCoef, DoubleBox measuredFlow, int timeout);
/// <summary>
/// Operation to set the water flow within tolerances. Leave the measurement running.
/// Events: Event.None, Event.FlowReached, Event.FlowTimeOut
/// </summary>
/// <param name="requiredFlowLo">Lower limit of the required flow [m3/h]</param>
/// <param name="requiredFlowHi">Higher limit of the required flow [m3/h]</param>
/// <param name="pidCoef">PID coefficient (float)</param>
/// <param name="measuredFlow">Measured flow [m3/h]</param>
/// <param name="timeout">Timeout in [s]</param>
/// <param name="filter">Passed to SendCommand() as argument filterContant</param>
/// <returns>SetFlowOp instance</returns>
IOperation SetFlowAndMeasureOp(IFlowMeter flowMeter, float requiredFlowLo, float requiredFlowHi,
float pidCoef, DoubleBox measuredFlow, int timeout, float filter);
/// <summary>
/// Operation to set the regulation valve to a required position
/// Events: Event.None
/// </summary>
/// <param name="posLoPct">Lower limit of the required valve position in %</param>
/// <param name="posHiPct">Higher limit of the required valve position in %</param>
/// <param name="timeout">Timeout in [s]</param>
/// <returns>SetPositionOp instance</returns>
IOperation SetRegulValvePositionOp(float posLoPct, float posHiPct, int timeout);
/// <summary>
/// Operation to set the regulation valve to a required position
/// Events: Event.None
/// </summary>
/// <param name="timePulseSec">Time pulse in sec</param>
/// <returns>SetPositionOp instance</returns>
IOperation ChangeRegulValvePositionOp(float timePulseSec);
}
}