|
@@ -22,10 +22,13 @@ namespace Venus_MainPages.ViewModels
|
|
|
public class TMOperationViewModel : BindableBase
|
|
|
{
|
|
|
#region 私有字段
|
|
|
- private TMOperationView m_TMOperationView;
|
|
|
- private bool m_IsOFFline = true;
|
|
|
+ //private TMOperationView m_TMOperationView;
|
|
|
+ //private bool m_IsOFFline = true;
|
|
|
|
|
|
private bool m_TMIsOFFline = true;
|
|
|
+ private bool m_LLAIsOFFline = true;
|
|
|
+ private bool m_LLBIsOFFline = true;
|
|
|
+
|
|
|
|
|
|
|
|
|
private bool m_PMAIsInstalled;
|
|
@@ -184,20 +187,38 @@ namespace Venus_MainPages.ViewModels
|
|
|
get { return m_TMChamberFlowSetPoint; }
|
|
|
set { SetProperty(ref m_TMChamberFlowSetPoint, value); }
|
|
|
}
|
|
|
- public bool IsOFFline
|
|
|
+ //public bool IsOFFline
|
|
|
+ //{
|
|
|
+ // get { return m_IsOFFline; }
|
|
|
+ // set
|
|
|
+ // {
|
|
|
+ // SetProperty(ref m_IsOFFline, value);
|
|
|
+ // }
|
|
|
+ //}
|
|
|
+ public bool TMIsOFFline
|
|
|
{
|
|
|
- get { return m_IsOFFline; }
|
|
|
+ get { return m_TMIsOFFline; }
|
|
|
set
|
|
|
{
|
|
|
- SetProperty(ref m_IsOFFline, value);
|
|
|
+ SetProperty(ref m_TMIsOFFline, value);
|
|
|
}
|
|
|
}
|
|
|
- public bool TMIsOFFline
|
|
|
+
|
|
|
+ public bool LLAIsOFFline
|
|
|
{
|
|
|
- get { return m_TMIsOFFline; }
|
|
|
+ get { return m_LLAIsOFFline; }
|
|
|
set
|
|
|
{
|
|
|
- SetProperty(ref m_TMIsOFFline, value);
|
|
|
+ SetProperty(ref m_LLAIsOFFline, value);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ public bool LLBIsOFFline
|
|
|
+ {
|
|
|
+ get { return m_LLBIsOFFline; }
|
|
|
+ set
|
|
|
+ {
|
|
|
+ SetProperty(ref m_LLBIsOFFline, value);
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -332,36 +353,36 @@ namespace Venus_MainPages.ViewModels
|
|
|
public DelegateCommand<object> LoadCommand =>
|
|
|
_LoadCommand ?? (_LoadCommand = new DelegateCommand<object>(OnLoad));
|
|
|
|
|
|
- private DelegateCommand _HomeCommand;
|
|
|
- public DelegateCommand HomeCommand =>
|
|
|
- _HomeCommand ?? (_HomeCommand = new DelegateCommand(OnHome));
|
|
|
+ private DelegateCommand<object> _HomeCommand;
|
|
|
+ public DelegateCommand<object> HomeCommand =>
|
|
|
+ _HomeCommand ?? (_HomeCommand = new DelegateCommand<object>(OnHome));
|
|
|
|
|
|
private DelegateCommand _RobotHomeCommand;
|
|
|
public DelegateCommand RobotHomeCommand =>
|
|
|
- _RobotHomeCommand ?? (_RobotHomeCommand = new DelegateCommand(OnHome));
|
|
|
+ _RobotHomeCommand ?? (_RobotHomeCommand = new DelegateCommand(OnRobotHome));
|
|
|
|
|
|
- private DelegateCommand _VentCommand;
|
|
|
- public DelegateCommand VentCommand =>
|
|
|
- _VentCommand ?? (_VentCommand = new DelegateCommand(OnVent));
|
|
|
+ private DelegateCommand<object> _VentCommand;
|
|
|
+ public DelegateCommand<object> VentCommand =>
|
|
|
+ _VentCommand ?? (_VentCommand = new DelegateCommand<object>(OnVent));
|
|
|
|
|
|
- private DelegateCommand _PumpCommand;
|
|
|
- public DelegateCommand PumpCommand =>
|
|
|
- _PumpCommand ?? (_PumpCommand = new DelegateCommand(OnPump));
|
|
|
+ private DelegateCommand<object> _PumpCommand;
|
|
|
+ public DelegateCommand<object> PumpCommand =>
|
|
|
+ _PumpCommand ?? (_PumpCommand = new DelegateCommand<object>(OnPump));
|
|
|
|
|
|
- private DelegateCommand _PurgeCommand;
|
|
|
- public DelegateCommand PurgeCommand =>
|
|
|
- _PurgeCommand ?? (_PurgeCommand = new DelegateCommand(OnPurge));
|
|
|
+ private DelegateCommand<object> _PurgeCommand;
|
|
|
+ public DelegateCommand<object> PurgeCommand =>
|
|
|
+ _PurgeCommand ?? (_PurgeCommand = new DelegateCommand<object>(OnPurge));
|
|
|
|
|
|
private DelegateCommand _LeakCheckCommand;
|
|
|
public DelegateCommand LeakCheckCommand =>
|
|
|
_LeakCheckCommand ?? (_LeakCheckCommand = new DelegateCommand(OnLeakCheck));
|
|
|
|
|
|
- private DelegateCommand _AbortCommand;
|
|
|
- public DelegateCommand AbortCommand =>
|
|
|
- _AbortCommand ?? (_AbortCommand = new DelegateCommand(OnAbort));
|
|
|
- private DelegateCommand<object> _ModuleCheckedCommand;
|
|
|
- public DelegateCommand<object> ModuleCheckedCommand =>
|
|
|
- _ModuleCheckedCommand ?? (_ModuleCheckedCommand = new DelegateCommand<object>(OnModuleChecked));
|
|
|
+ private DelegateCommand<object> _AbortCommand;
|
|
|
+ public DelegateCommand<object> AbortCommand =>
|
|
|
+ _AbortCommand ?? (_AbortCommand = new DelegateCommand<object>(OnAbort));
|
|
|
+ //private DelegateCommand<object> _ModuleCheckedCommand;
|
|
|
+ //public DelegateCommand<object> ModuleCheckedCommand =>
|
|
|
+ // _ModuleCheckedCommand ?? (_ModuleCheckedCommand = new DelegateCommand<object>(OnModuleChecked));
|
|
|
|
|
|
private DelegateCommand<object> _ControlValveCommand;
|
|
|
public DelegateCommand<object> ControlValveCommand =>
|
|
@@ -394,17 +415,17 @@ namespace Venus_MainPages.ViewModels
|
|
|
_ChamberDoorCloseCommand ?? (_ChamberDoorCloseCommand = new DelegateCommand<object>(OnChamberDoorClose));
|
|
|
|
|
|
|
|
|
- private DelegateCommand _SetTMChamberPressureCommand;
|
|
|
- public DelegateCommand SetTMChamberPressureCommand =>
|
|
|
- _SetTMChamberPressureCommand ?? (_SetTMChamberPressureCommand = new DelegateCommand(OnSetTMChamberPressure));
|
|
|
+ private DelegateCommand<object> _SetTMChamberPressureCommand;
|
|
|
+ public DelegateCommand<object> SetTMChamberPressureCommand =>
|
|
|
+ _SetTMChamberPressureCommand ?? (_SetTMChamberPressureCommand = new DelegateCommand<object>(OnSetTMChamberPressure));
|
|
|
|
|
|
- private DelegateCommand _OnlineCommand;
|
|
|
- public DelegateCommand OnlineCommand =>
|
|
|
- _OnlineCommand ?? (_OnlineCommand = new DelegateCommand(OnOnline));
|
|
|
+ private DelegateCommand<object> _OnlineCommand;
|
|
|
+ public DelegateCommand<object> OnlineCommand =>
|
|
|
+ _OnlineCommand ?? (_OnlineCommand = new DelegateCommand<object>(OnOnline));
|
|
|
|
|
|
- private DelegateCommand _OfflineCommand;
|
|
|
- public DelegateCommand OfflineCommand =>
|
|
|
- _OfflineCommand ?? (_OfflineCommand = new DelegateCommand(OnOffline));
|
|
|
+ private DelegateCommand<object> _OfflineCommand;
|
|
|
+ public DelegateCommand<object> OfflineCommand =>
|
|
|
+ _OfflineCommand ?? (_OfflineCommand = new DelegateCommand<object>(OnOffline));
|
|
|
|
|
|
#endregion
|
|
|
|
|
@@ -443,7 +464,7 @@ namespace Venus_MainPages.ViewModels
|
|
|
{
|
|
|
if (m_firstLoad)
|
|
|
{
|
|
|
- m_TMOperationView = (TMOperationView)tmOperationView;
|
|
|
+ //m_TMOperationView = (TMOperationView)tmOperationView;
|
|
|
var AllLeakCheckDa = QueryDataClient.Instance.Service.GetPMLeakCheckResult("TM");
|
|
|
if (AllLeakCheckDa != null)
|
|
|
{
|
|
@@ -453,38 +474,38 @@ namespace Venus_MainPages.ViewModels
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- private void OnHome()
|
|
|
+ private void OnHome(object obj)
|
|
|
{
|
|
|
- InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.Home");
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{obj.ToString()}.Home");
|
|
|
}
|
|
|
- //private void OnRobotHome()
|
|
|
- //{
|
|
|
- // InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.RobotHome");
|
|
|
- //}
|
|
|
- private void OnVent()
|
|
|
+ private void OnRobotHome()
|
|
|
{
|
|
|
- InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.{RtOperation.Vent}");
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.RobotHome");
|
|
|
}
|
|
|
- private void OnPump()
|
|
|
+ private void OnVent(object obj)
|
|
|
{
|
|
|
- InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.{RtOperation.Pump}");
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{obj}.{RtOperation.Vent}");
|
|
|
}
|
|
|
- private void OnPurge()
|
|
|
+ private void OnPump(object obj)
|
|
|
{
|
|
|
- InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.{RtOperation.Purge}");
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{obj}.{RtOperation.Pump}");
|
|
|
}
|
|
|
- private void OnLeakCheck()
|
|
|
+ private void OnPurge(object obj)
|
|
|
{
|
|
|
- InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.{RtOperation.LeakCheck}");
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{obj}.{RtOperation.Purge}");
|
|
|
}
|
|
|
- private void OnAbort()
|
|
|
+ private void OnLeakCheck()
|
|
|
{
|
|
|
- InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.{RtOperation.Abort}");
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.{RtOperation.LeakCheck}");
|
|
|
}
|
|
|
- private void OnModuleChecked(object obj)
|
|
|
+ private void OnAbort(object obj)
|
|
|
{
|
|
|
- m_ModuleCheckedName = obj.ToString();
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{obj}.{RtOperation.Abort}");
|
|
|
}
|
|
|
+ //private void OnModuleChecked(object obj)
|
|
|
+ //{
|
|
|
+ // m_ModuleCheckedName = obj.ToString();
|
|
|
+ //}
|
|
|
|
|
|
private void OnControlValve(object obj)
|
|
|
{
|
|
@@ -525,26 +546,26 @@ namespace Venus_MainPages.ViewModels
|
|
|
{
|
|
|
InvokeClient.Instance.Service.DoOperation($"{obj?.ToString()}.SlitDoor.Close");
|
|
|
}
|
|
|
- private void OnSetTMChamberPressure()
|
|
|
+ private void OnSetTMChamberPressure(object obj)
|
|
|
{
|
|
|
- if (CommonFunction.GetValue<bool>(RtDataValues, $"{m_ModuleCheckedName}.IsEnableControlPressure"))
|
|
|
+ if (CommonFunction.GetValue<bool>(RtDataValues, $"{obj}.IsEnableControlPressure"))
|
|
|
{
|
|
|
- InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.{RtOperation.AbortControlPressure}");
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{obj}.{RtOperation.AbortControlPressure}");
|
|
|
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
- InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.{RtOperation.ControlPressure}");
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{obj}.{RtOperation.ControlPressure}");
|
|
|
}
|
|
|
|
|
|
}
|
|
|
- private void OnOnline()
|
|
|
+ private void OnOnline(object obj)
|
|
|
{
|
|
|
- InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.{RtOperation.Online}");
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{obj.ToString()}.{RtOperation.Online}");
|
|
|
}
|
|
|
- private void OnOffline()
|
|
|
+ private void OnOffline(object obj)
|
|
|
{
|
|
|
- InvokeClient.Instance.Service.DoOperation($"{m_ModuleCheckedName}.{RtOperation.Offline}");
|
|
|
+ InvokeClient.Instance.Service.DoOperation($"{obj.ToString()}.{RtOperation.Offline}");
|
|
|
}
|
|
|
|
|
|
#endregion
|
|
@@ -581,8 +602,11 @@ namespace Venus_MainPages.ViewModels
|
|
|
TMVentExhaustValveIsOpen = CommonFunction.GetValue<bool>(RtDataValues, "TM.TMVentExhaustValve.IsOpen");
|
|
|
|
|
|
|
|
|
- IsOFFline = !CommonFunction.GetValue<bool>(RtDataValues, $"{m_ModuleCheckedName}.IsOnline");
|
|
|
+ //IsOFFline = !CommonFunction.GetValue<bool>(RtDataValues, $"{m_ModuleCheckedName}.IsOnline");
|
|
|
TMIsOFFline = !CommonFunction.GetValue<bool>(RtDataValues, $"TM.IsOnline");
|
|
|
+ LLAIsOFFline = !CommonFunction.GetValue<bool>(RtDataValues, $"LLA.IsOnline");
|
|
|
+ LLBIsOFFline = !CommonFunction.GetValue<bool>(RtDataValues, $"LLB.IsOnline");
|
|
|
+
|
|
|
TMCurrentState = (TMState)(Enum.Parse(typeof(TMState), RtDataValues[$"TM.FsmState"].ToString()));
|
|
|
LLACurrentState = (LLState)(Enum.Parse(typeof(LLState), RtDataValues[$"LLA.FsmState"].ToString()));
|
|
|
LLBCurrentState = (LLState)(Enum.Parse(typeof(LLState), RtDataValues[$"LLB.FsmState"].ToString()));
|