123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Linq;
- using System.Reflection;
- using System.Runtime.Serialization;
- using System.Text;
- using System.Windows.Input;
- using Aitex.Core.UI.MVVM;
- using MECF.Framework.Common.CommonData;
- namespace Aitex.Core.Common.DeviceData
- {
- [DataContract]
- [Serializable]
- public class AITMfcData : NotifiableItem, IDeviceData
- {
- [DataMember]
- public string Module { get; set; }
- [DataMember]
- public string UniqueName { get; set; }
- /// <summary>
- /// 设备的唯一名称,UI与RT交互的ID
- /// </summary>
- [DataMember]
- public string DeviceName
- {
- get;
- set;
- }
- /// <summary>
- /// 显示在界面上的名称
- /// </summary>
- [DataMember]
- public string DisplayName
- {
- get;
- set;
- }
- /// <summary>
- /// IO 表中定义的物理编号,物理追溯使用 比如: M122
- /// </summary>
- [DataMember]
- public string DeviceSchematicId
- {
- get;
- set;
- }
- [DataMember]
- public string Unit
- {
- get;
- set;
- }
- [DataMember]
- public string Description
- {
- get;
- set;
- }
- /// <summary>
- /// 量程
- /// </summary>
- [DataMember]
- public double Scale
- {
- get;
- set;
- }
- /// <summary>
- /// 量程范围
- /// </summary>
- [DataMember]
- public string Range
- {
- get;
- set;
- }
- /// <summary>
- /// 设定值
- /// </summary>
- [DataMember]
- public double SetPoint
- {
- get;
- set;
- }
- [DataMember]
- public double FeedBack
- {
- get;
- set;
- }
- /// <summary>
- /// 默认值
- /// </summary>
- [DataMember]
- public double DefaultValue
- {
- get;
- set;
- }
- /// <summary>
- /// 是否有报警
- /// </summary>
- [DataMember]
- public bool IsWarning
- {
- get;
- set;
- }
- [DataMember]
- public bool IsError
- {
- get;
- set;
- }
- [DataMember]
- public bool IsOffline
- {
- get;
- set;
- }
- [DataMember]
- public int Status
- {
- get;
- set;
- }
- /// <summary>
- /// alarm或是erro时显示的信息
- /// </summary>
- [DataMember]
- public string ErroMessage
- {
- get;
- set;
- }
- /// <summary>
- /// MFC,PC
- /// </summary>
- [DataMember]
- public string Type
- {
- get;
- set;
- }
- [DataMember]
- public double Factor
- {
- get;
- set;
- }
- private string _title;
- [DataMember]
- public string DisplayTitle
- {
- get
- {
- return string.Format("{0}({1})", DeviceSchematicId, DisplayName);
- }
- set
- {
- _title = value;
- }
- }
- public AITMfcData()
- {
- DisplayName = "Undefined";
- Factor = 1.0;
- Unit = "sccm";
- Type = "MFC";
- DeviceSchematicId = "Undefined";
- UniqueName = "";
- }
- public void Update(IDeviceData data)
- {
- throw new NotImplementedException();
- }
- }
- public class AITMfcOperation
- {
- public const string Ramp = "Ramp";
- }
- public class AITMfcDataPropertyName
- {
- public const string IsOffline = "IsOffline";
- public const string MfcAlarm = "MfcAlarm";
- public const string IsEnable = "IsEnable";
- public const string PressureAlarm = "PressureAlarm";
- public const string FeedBack = "FeedBack";
- public const string SetPoint = "SetPoint";
- public const string DefaultSetPoint = "DefaultSetPoint";
- public const string Scale = "Scale";
- public const string Range = "Range";
- public const string IsEnabled = "IsEnabled";
- public const string IsOutOfTolerance = "IsOutOfTolerance";
- public const string IsEnableAlarm = "IsEnableAlarm";
- public const string AlarmRange = "AlarmRange";
- public const string AlarmTime = "AlarmTime";
- public const string Status = "Status";
- }
- }
|