Browse Source

Added and uploaded VenusDETMViewModel.cs, VenusDETMView.xaml, VCEleft1.png, VCEright1.png, detm.png, DEVceA.xaml, DEVceB.xaml, and VenusDETM.xaml.

intern02 1 year ago
parent
commit
7d6765cd44

+ 938 - 0
Venus/Venus_MainPages/ViewModels/VenusDETMView.cs

@@ -0,0 +1,938 @@
+using Aitex.Sorter.Common;
+using MECF.Framework.Common.CommonData;
+using MECF.Framework.Common.DataCenter;
+using MECF.Framework.Common.Equipment;
+using MECF.Framework.Common.OperationCenter;
+using MECF.Framework.Common.Schedulers;
+using OpenSEMI.ClientBase;
+using OpenSEMI.Ctrlib.Controls;
+using Prism.Commands;
+using Prism.Mvvm;
+using System;
+using System.Collections.Generic;
+using System.Collections.ObjectModel;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows.Threading;
+using Venus_Core;
+using Venus_MainPages.Unity;
+using Venus_Themes.CustomControls;
+using static Venus_Themes.CustomControls.SERobot;
+
+namespace Venus_MainPages.ViewModels
+{
+    public class VenusDETMViewModel : BindableBase
+    {
+        #region 私有字段
+        public double m_VPAangle;
+
+        private ModuleInfo m_VCEModuleInfo;
+        private ModuleInfo m_VPAModuleInfo;
+        private ModuleInfo m_TMModuleInfo;
+
+        //Wafer
+        private WaferInfo m_PMAWafer;
+        private WaferInfo m_PMBWafer;
+        private WaferInfo m_PMCWafer;
+        public WaferInfo m_RobotUpperWafer;
+        public WaferInfo m_RobotLowerWafer;
+        public WaferInfo m_PAWafer;
+
+        //Door
+        private bool m_PMADoorIsOpen;
+        private bool m_PMBDoorIsOpen;
+        private bool m_PMCDoorIsOpen;
+        private bool m_VCEDoorIsOpen;
+        private bool m_VCEOutDoorIsOpen;
+
+        //Pick、Place、Extend、Retract行下拉框内容
+        private SeTMModule m_PickSelectedModule;
+        private SeTMModule m_PlaceSelectedModule;
+        private SeTMModule m_ExtendSelectedModule;
+        private SeTMModule m_RetractSelectedModule;
+        private SeTMModule m_GotoSelectedModule;
+        private SeTMBlade m_PickSelectedBlade;
+        private SeTMBlade m_PlaceSelectedBlade;
+        private SeTMBlade m_ExtendSelectedBlade;
+        private SeTMBlade m_RetractSelectedBlade;
+        private SeTMBlade m_GoToSelectedBlade;
+
+
+        //Pick、Place、Extend、Retract行下拉框关联
+        private ObservableCollection<int> m_PickSoltItemsSource = new ObservableCollection<int>();
+        private ObservableCollection<int> m_PlaceSoltItemsSource = new ObservableCollection<int>();
+        private ObservableCollection<int> m_ExtendSoltItemsSource = new ObservableCollection<int>();
+        private ObservableCollection<int> m_RetractSoltItemsSource = new ObservableCollection<int>();
+        private int m_PickSoltSelectedIndex;
+        private int m_PlaceSoltSelectedIndex;
+        private int m_ExtendSoltSelectedIndex;
+        private int m_RetractSoltSelectedIndex;
+
+
+        //下拉框内容
+        private List<SeTMModule> m_TMModules = new List<SeTMModule>();
+
+        private bool m_PMAIsInstalled;
+        private bool m_PMBIsInstalled;
+        private bool m_PMCIsInstalled;
+        private bool m_VCEIsInstalled;
+        private bool m_VPAIsInstalled;
+        private Dictionary<string, object> m_RtDataValues = new Dictionary<string, object>();
+        private List<string> m_RtDataKeys = new List<string>();
+
+        //Robot动画
+        private SERobotTAction m_SERobotTAction;
+        private SERobotTAction m_Robot1TAction;
+        private SERobotXAction m_Robot1XAction;
+        private SERobotTAction m_Robot2TAction;
+        private SERobotXAction m_Robot2XAction;
+        public RobotMoveInfo m_robotMoveInfo;
+        //Cycle
+        private List<string> m_OriginalCycle = new List<string>();
+        private List<string> m_ToCycle = new List<string>();
+        private bool m_CycleEnable;
+
+        private bool m_PMAIsCycle;
+        private bool m_PMBIsCycle;
+        private bool m_PMCIsCycle;
+
+        private int m_CycleCount;
+
+        #endregion
+
+        #region 属性
+        public double VPAangle
+        {
+            get { return m_VPAangle; }
+            set { SetProperty(ref m_VPAangle, value); }
+        }
+        public WaferInfo PMAWafer
+        {
+            get { return m_PMAWafer; }
+            set { SetProperty(ref m_PMAWafer, value); }
+        }
+        public WaferInfo PMBWafer
+        {
+            get { return m_PMBWafer; }
+            set { SetProperty(ref m_PMBWafer, value); }
+        }
+        public WaferInfo PMCWafer
+        {
+            get { return m_PMCWafer; }
+            set { SetProperty(ref m_PMCWafer, value); }
+        }
+        public WaferInfo RobotUpperWafer
+        {
+            get { return m_RobotUpperWafer; }
+            set { SetProperty(ref m_RobotUpperWafer, value); }
+        }
+
+        public WaferInfo RobotLowerWafer
+        {
+            get { return m_RobotLowerWafer; }
+            set { SetProperty(ref m_RobotLowerWafer, value); }
+        }
+        public WaferInfo PAWafer
+        {
+            get { return m_PAWafer; }
+            set { SetProperty(ref m_PAWafer, value); }
+        }
+        public bool VCEDoorIsOpen { get => m_VCEDoorIsOpen; set => SetProperty(ref m_VCEDoorIsOpen, value); }
+        public bool VCEOutDoorIsOpen { get => m_VCEOutDoorIsOpen; set => SetProperty(ref m_VCEOutDoorIsOpen, value); }
+
+
+        public bool PMCDoorIsOpen
+        {
+            get => m_PMCDoorIsOpen;
+            set
+            {
+                SetProperty(ref m_PMCDoorIsOpen, value);
+            }
+        }
+
+        public bool PMADoorIsOpen
+        {
+            get { return m_PMADoorIsOpen; }
+            set { SetProperty(ref m_PMADoorIsOpen, value); }
+        }
+        public bool PMBDoorIsOpen
+        {
+            get { return m_PMBDoorIsOpen; }
+            set { SetProperty(ref m_PMBDoorIsOpen, value); }
+        }
+        public ModuleInfo VCEModuleInfo
+        {
+            get { return m_VCEModuleInfo; }
+            set
+            {
+                SetProperty(ref m_VCEModuleInfo, value);
+            }
+        }
+        public ModuleInfo VPAModuleInfo
+        {
+            get { return m_VPAModuleInfo; }
+            set
+            {
+                SetProperty(ref m_VPAModuleInfo, value);
+            }
+        }
+        public Dictionary<string, object> RtDataValues
+        {
+            get { return m_RtDataValues; }
+            set { SetProperty(ref m_RtDataValues, value); }
+        }
+
+        public bool PMAIsInstalled
+        {
+            get { return m_PMAIsInstalled; }
+            set { SetProperty(ref m_PMAIsInstalled, value); }
+        }
+        public bool PMBIsInstalled
+        {
+            get { return m_PMBIsInstalled; }
+            set { SetProperty(ref m_PMBIsInstalled, value); }
+        }
+        public bool PMCIsInstalled
+        {
+            get { return m_PMCIsInstalled; }
+            set { SetProperty(ref m_PMCIsInstalled, value); }
+        }
+        public bool VCEIsInstalled
+        {
+            get { return m_VCEIsInstalled; }
+            set { SetProperty(ref m_VCEIsInstalled, value); }
+        }
+        public bool VPAIsInstalled
+        {
+            get { return m_VPAIsInstalled; }
+            set { SetProperty(ref m_VPAIsInstalled, value); }
+        }
+
+        public List<SeTMModule> TMModules
+        {
+            get { return m_TMModules; }
+            set { SetProperty(ref m_TMModules, value); }
+        }
+
+        //Module属性
+        public SeTMModule PickSelectedModule
+        {
+            get { return m_PickSelectedModule; }
+            set { SetProperty(ref m_PickSelectedModule, value); }
+        }
+        public SeTMModule PlaceSelectedModule
+        {
+            get { return m_PlaceSelectedModule; }
+            set { SetProperty(ref m_PlaceSelectedModule, value); }
+        }
+        public SeTMModule ExtendSelectedModule
+        {
+            get { return m_ExtendSelectedModule; }
+            set { SetProperty(ref m_ExtendSelectedModule, value); }
+        }
+        public SeTMModule RetractSelectedModule
+        {
+            get { return m_RetractSelectedModule; }
+            set { SetProperty(ref m_RetractSelectedModule, value); }
+        }
+        public SeTMModule GotoSelectedModule
+        {
+            get { return m_GotoSelectedModule; }
+            set { SetProperty(ref m_GotoSelectedModule, value); }
+        }
+        public ModuleInfo TMModuleInfo
+        {
+            get { return m_TMModuleInfo; }
+            set
+            {
+                SetProperty(ref m_TMModuleInfo, value);
+            }
+        }
+        //Blade属性
+        public SeTMBlade PickSelectedBlade
+        {
+            get { return m_PickSelectedBlade; }
+            set { SetProperty(ref m_PickSelectedBlade, value); }
+        }
+        public SeTMBlade PlaceSelectedBlade
+        {
+            get { return m_PlaceSelectedBlade; }
+            set { SetProperty(ref m_PlaceSelectedBlade, value); }
+        }
+        public SeTMBlade ExtendSelectedBlade
+        {
+            get { return m_ExtendSelectedBlade; }
+            set { SetProperty(ref m_ExtendSelectedBlade, value); }
+        }
+        public SeTMBlade RetractSelectedBlade
+        {
+            get { return m_RetractSelectedBlade; }
+            set { SetProperty(ref m_RetractSelectedBlade, value); }
+        }
+        public SeTMBlade GoToSelectedBlade
+        {
+            get { return m_GoToSelectedBlade; }
+            set { SetProperty(ref m_GoToSelectedBlade, value); }
+        }
+
+        public ObservableCollection<int> PickSoltItemsSource
+        {
+            get { return m_PickSoltItemsSource; }
+            set { SetProperty(ref m_PickSoltItemsSource, value); }
+        }
+        public ObservableCollection<int> PlaceSoltItemsSource
+        {
+            get { return m_PlaceSoltItemsSource; }
+            set { SetProperty(ref m_PlaceSoltItemsSource, value); }
+        }
+        public ObservableCollection<int> ExtendSoltItemsSource
+        {
+            get { return m_ExtendSoltItemsSource; }
+            set { SetProperty(ref m_ExtendSoltItemsSource, value); }
+        }
+        public ObservableCollection<int> RetractSoltItemsSource
+        {
+            get { return m_RetractSoltItemsSource; }
+            set { SetProperty(ref m_RetractSoltItemsSource, value); }
+        }
+        public int PickSoltSelectedIndex
+        {
+            get { return m_PickSoltSelectedIndex; }
+            set { SetProperty(ref m_PickSoltSelectedIndex, value); }
+        }
+        public int PlaceSoltSelectedIndex
+        {
+            get { return m_PlaceSoltSelectedIndex; }
+            set { SetProperty(ref m_PlaceSoltSelectedIndex, value); }
+        }
+        public int ExtendSoltSelectedIndex
+        {
+            get { return m_ExtendSoltSelectedIndex; }
+            set { SetProperty(ref m_ExtendSoltSelectedIndex, value); }
+        }
+        public int RetractSoltSelectedIndex
+        {
+            get { return m_RetractSoltSelectedIndex; }
+            set { SetProperty(ref m_RetractSoltSelectedIndex, value); }
+        }
+        //Robot动作
+        public SERobotTAction SERobotTAction
+        {
+            get { return m_SERobotTAction; }
+            set { SetProperty(ref m_SERobotTAction, value); }
+        }
+        public SERobotTAction Robot1TAction
+        {
+            get { return m_Robot1TAction; }
+            set { SetProperty(ref m_Robot1TAction, value); }
+        }
+        public SERobotXAction Robot1XAction
+        {
+            get { return m_Robot1XAction; }
+            set { SetProperty(ref m_Robot1XAction, value); }
+        }
+        public SERobotTAction Robot2TAction
+        {
+            get { return m_Robot2TAction; }
+            set { SetProperty(ref m_Robot2TAction, value); }
+        }
+        public SERobotXAction Robot2XAction
+        {
+            get { return m_Robot2XAction; }
+            set { SetProperty(ref m_Robot2XAction, value); }
+        }
+        public RobotMoveInfo RobotMoveInfo
+        {
+            get { return m_robotMoveInfo; }
+            set
+            {
+                RobotMoveInfoChanged(m_robotMoveInfo, value);
+                m_robotMoveInfo = value;
+            }
+        }
+        //Cycle
+        public List<string> OriginalCycle
+        {
+            get { return m_OriginalCycle; }
+            set { SetProperty(ref m_OriginalCycle, value); }
+        }
+        public List<string> ToCycle
+        {
+            get { return m_ToCycle; }
+            set { SetProperty(ref m_ToCycle, value); }
+        }
+        public bool CycleEnable
+        {
+            get { return m_CycleEnable; }
+            set { SetProperty(ref m_CycleEnable, value); }
+        }
+        public bool PMAIsCycle
+        {
+            get { return m_PMAIsCycle; }
+            set { SetProperty(ref m_PMAIsCycle, value); }
+        }
+        public bool PMBIsCycle
+        {
+            get { return m_PMBIsCycle; }
+            set { SetProperty(ref m_PMBIsCycle, value); }
+        }
+        public bool PMCIsCycle
+        {
+            get { return m_PMCIsCycle; }
+            set { SetProperty(ref m_PMCIsCycle, value); }
+        }
+        public int CycleCount
+        {
+            get { return m_CycleCount; }
+            set { SetProperty(ref m_CycleCount, value); }
+        }
+
+
+        #endregion
+
+        #region 命令
+        //模块下拉框选择命令
+        private DelegateCommand<object> _ModuleChangeCommand;
+        public DelegateCommand<object> ModuleChangeCommand =>
+            _ModuleChangeCommand ?? (_ModuleChangeCommand = new DelegateCommand<object>(OnModuleChange));
+        //Pick按钮命令
+        private DelegateCommand _PickCommand;
+        public DelegateCommand PickCommand =>
+            _PickCommand ?? (_PickCommand = new DelegateCommand(OnPick));
+        //Place按钮命令
+        private DelegateCommand _PlaceCommand;
+        public DelegateCommand PlaceCommand =>
+            _PlaceCommand ?? (_PlaceCommand = new DelegateCommand(OnPlace));
+        //Extend按钮命令
+        private DelegateCommand _ExtendCommand;
+        public DelegateCommand ExtendCommand =>
+            _ExtendCommand ?? (_ExtendCommand = new DelegateCommand(OnExtend));
+        //Retract按钮命令
+        private DelegateCommand _RetractCommand;
+        public DelegateCommand RetractCommand =>
+            _RetractCommand ?? (_RetractCommand = new DelegateCommand(OnRetract));
+        //RobotHome按钮命令
+        public DelegateCommand _RobotHomeCommand;
+        public DelegateCommand RobotHomeCommand =>
+            _RobotHomeCommand ?? (_RobotHomeCommand = new DelegateCommand(OnRobotHome));
+        private DelegateCommand _HomeCommand;
+        public DelegateCommand HomeCommand =>
+            _HomeCommand ?? (_HomeCommand = new DelegateCommand(OnHome));
+        private DelegateCommand _GotoCommand;
+        public DelegateCommand GotoCommand =>
+            _GotoCommand ?? (_GotoCommand = new DelegateCommand(OnGoto));
+        #endregion
+        //Cycle
+        private DelegateCommand _StartCycleCommand;
+        public DelegateCommand StartCycleCommand =>
+            _StartCycleCommand ?? (_StartCycleCommand = new DelegateCommand(OnStartCycle));
+
+        private DelegateCommand _StopCycleCommand;
+
+        public DelegateCommand StopCycleCommand =>
+            _StopCycleCommand ?? (_StopCycleCommand = new DelegateCommand(OnStopCycle));
+
+
+        #region 构造函数
+        public VenusDETMViewModel()
+        {
+            string allModules = QueryDataClient.Instance.Service.GetConfig($"System.InstalledModules").ToString();
+            PMAIsInstalled = allModules.Contains("PMA");
+            PMBIsInstalled = allModules.Contains("PMB");
+            //PMCIsInstalled = allModules.Contains("PMC");
+            PMCIsInstalled = true;
+            //VCEIsInstalled = allModules.Contains("VCE1");
+            VCEIsInstalled = true;
+            VPAIsInstalled = allModules.Contains("VPA");
+            if (PMAIsInstalled == true)
+            {
+                TMModules.Add(SeTMModule.PMA);
+            }
+            if (PMBIsInstalled == true)
+            {
+                TMModules.Add(SeTMModule.PMB);
+            }
+            if (PMCIsInstalled == true)
+            {
+                TMModules.Add(SeTMModule.PMC);
+                m_VPAangle = 270;
+            }
+            else
+            {
+                m_VPAangle = 180;
+            }
+
+            if (VCEIsInstalled == true)
+            {
+                TMModules.Add(SeTMModule.VCE1);
+            }
+            if (VPAIsInstalled == true)
+            {
+                TMModules.Add(SeTMModule.VPA);
+            }
+
+            PickSoltItemsSource.Add(1);
+            PlaceSoltItemsSource.Add(1);
+            ExtendSoltItemsSource.Add(1);
+            RetractSoltItemsSource.Add(1);
+
+
+            addDataKeys();
+            RtDataValues = QueryDataClient.Instance.Service.PollData(m_RtDataKeys);
+
+            VCEDoorIsOpen = !CommonFunction.GetValue<bool>(RtDataValues, "SETM.VCESlitDoorClosed");
+            PMADoorIsOpen = !CommonFunction.GetValue<bool>(RtDataValues, "SETM.PMASlitDoorClosed");
+            PMBDoorIsOpen = !CommonFunction.GetValue<bool>(RtDataValues, "SETM.PMBSlitDoorClosed");
+            PMCDoorIsOpen = !CommonFunction.GetValue<bool>(RtDataValues, "SETM.PMCSlitDoorClosed");
+            VCEOutDoorIsOpen = !CommonFunction.GetValue<bool>(RtDataValues, "VCE1.VCEOutDoorClosed");
+            DispatcherTimer timer = new DispatcherTimer();
+            timer.Interval = TimeSpan.FromSeconds(0.5);
+            timer.Tick += Timer_Tick;
+            timer.Start();
+
+        }
+        #endregion
+
+        #region 命令方法
+        private void addDataKeys()
+        {
+            m_RtDataKeys.Add($"SETM.VCESlitDoorClosed");
+            m_RtDataKeys.Add($"SETM.PMASlitDoorClosed");
+            m_RtDataKeys.Add($"SETM.PMBSlitDoorClosed");
+            m_RtDataKeys.Add($"SETM.PMCSlitDoorClosed");
+            m_RtDataKeys.Add($"VCE1.VCEOutDoorClosed");
+            m_RtDataKeys.Add($"PMA.ChamberPressure");
+            m_RtDataKeys.Add($"PMB.ChamberPressure");
+            m_RtDataKeys.Add($"PMC.ChamberPressure");
+            m_RtDataKeys.Add($"SETM.VCEPressure.Value");
+            m_RtDataKeys.Add($"VCE1.CassetteArrive");
+            m_RtDataKeys.Add($"TMCycle.CycleIndex");
+        }
+        //模块选择根据obj选择下拉框内容
+        private void OnModuleChange(object obj)
+        {
+            var value = obj.ToString();
+            switch (value)
+            {
+                case "Pick":
+                    PickSoltItemsSource.Clear();
+                    if ((int)PickSelectedModule == 3)
+                    {
+                        for (int i = 1; i <= 25; i++)
+                        {
+                            PickSoltItemsSource.Add(i);
+                        }
+                    }
+                    else
+                    {
+                        PickSoltItemsSource.Add(1);
+
+                    }
+                    PickSoltSelectedIndex = 0;
+                    break;
+                case "Place":
+                    PlaceSoltItemsSource.Clear();
+                    if ((int)PlaceSelectedModule == 3)
+                    {
+                        for (int i = 1; i <= 25; i++)
+                        {
+                            PlaceSoltItemsSource.Add(i);
+                        }
+                    }
+                    else
+                    {
+                        PlaceSoltItemsSource.Add(1);
+
+                    }
+                    PlaceSoltSelectedIndex = 0;
+                    break;
+                case "Extend":
+                    ExtendSoltItemsSource.Clear();
+                    if ((int)ExtendSelectedModule == 3)
+                    {
+                        for (int i = 1; i <= 25; i++)
+                        {
+                            ExtendSoltItemsSource.Add(i);
+                        }
+                    }
+                    else
+                    {
+                        ExtendSoltItemsSource.Add(1);
+
+                    }
+                    ExtendSoltSelectedIndex = 0;
+                    break;
+                case "Retract":
+                    RetractSoltItemsSource.Clear();
+                    if ((int)RetractSelectedModule == 3)
+                    {
+                        for (int i = 1; i <= 25; i++)
+                        {
+                            RetractSoltItemsSource.Add(i);
+                        }
+                    }
+                    else
+                    {
+                        RetractSoltItemsSource.Add(1);
+
+                    }
+                    RetractSoltSelectedIndex = 0;
+                    break;
+
+            }
+
+        }
+        private void OnPick()
+        {
+            Queue<MoveItem> moveItems = new Queue<MoveItem>();
+            var moduleName = (ModuleName)Enum.Parse(typeof(ModuleName), PickSelectedModule.ToString(), true);
+            var selectedHand = (Hand)Enum.Parse(typeof(Hand), PickSelectedBlade.ToString(), true);
+            MoveItem moveItem = new MoveItem(moduleName, PickSoltItemsSource[PickSoltSelectedIndex] - 1, ModuleName.TMRobot, 0, selectedHand);
+            moveItems.Enqueue(moveItem);
+            if ((int)PickSelectedModule < TMModules.Count - 2)
+            {
+                InvokeClient.Instance.Service.DoOperation($"SETM.PMPick", moveItems);
+            }
+            else
+            {
+                InvokeClient.Instance.Service.DoOperation($"SETM.Pick", moveItems);
+            }
+
+        }
+        private void OnPlace()
+        {
+            Queue<MoveItem> moveItems = new Queue<MoveItem>();
+            var moduleName = (ModuleName)Enum.Parse(typeof(ModuleName), PlaceSelectedModule.ToString(), true);
+            var selectedHand = (Hand)Enum.Parse(typeof(Hand), PlaceSelectedBlade.ToString(), true);
+            MoveItem moveItem = new MoveItem(ModuleName.TMRobot, 0, moduleName, PlaceSoltItemsSource[PlaceSoltSelectedIndex] - 1, selectedHand);
+            moveItems.Enqueue(moveItem);
+            if ((int)PlaceSelectedModule < TMModules.Count - 2)
+            {
+                InvokeClient.Instance.Service.DoOperation($"SETM.PMPlace", moveItems);
+            }
+            //VCE、VPA
+            else
+            {
+                InvokeClient.Instance.Service.DoOperation($"SETM.Place", moveItems);
+            }
+        }
+        private void OnExtend()
+        {
+            var moduleName = (ModuleName)Enum.Parse(typeof(ModuleName), ExtendSelectedModule.ToString(), true);
+            var selectedHand = (Hand)Enum.Parse(typeof(Hand), ExtendSelectedBlade.ToString(), true);
+            InvokeClient.Instance.Service.DoOperation($"SETM.Extend", moduleName, ExtendSoltItemsSource[ExtendSoltSelectedIndex] - 1, selectedHand);
+        }
+        private void OnRetract()
+        {
+            //Queue<MoveItem> moveItems = new Queue<MoveItem>();
+            var moduleName = (ModuleName)Enum.Parse(typeof(ModuleName), RetractSelectedModule.ToString(), true);
+            var selectedHand = (Hand)Enum.Parse(typeof(Hand), RetractSelectedBlade.ToString(), true);
+            //MoveItem moveItem = new MoveItem(moduleName, RetractSoltItemsSource[PickSoltSelectedIndex] - 1, 0, 0, selectedHand);
+            //moveItems.Enqueue(moveItem);
+            InvokeClient.Instance.Service.DoOperation($"SETM.Retract", moduleName, RetractSoltItemsSource[PlaceSoltSelectedIndex] - 1, selectedHand);
+        }
+        //令选择的模块下发Home指令
+        private void OnRobotHome()
+        {
+            InvokeClient.Instance.Service.DoOperation($"SETM.Home", "TMRobot");
+            InvokeClient.Instance.Service.DoOperation($"SETM.Retract");
+
+        }
+        private void OnHome()
+        {
+            InvokeClient.Instance.Service.DoOperation($"SETM.Home");
+        }
+        private void OnGoto()
+        {
+            var moduleName = (ModuleName)Enum.Parse(typeof(ModuleName), GotoSelectedModule.ToString(), true);
+            var selectedHand = (Hand)Enum.Parse(typeof(Hand), GoToSelectedBlade.ToString(), true);
+            InvokeClient.Instance.Service.DoOperation($"SETM.Goto", moduleName, 0, selectedHand);
+        }
+        //Cycle
+        private void OnStartCycle()
+        {
+            if (CycleEnable == false)
+            {
+                return;
+            }
+            List<string> stations = new List<string>();
+            stations.Add("VCE1");
+            stations.Add("VPA");
+            if (PMAIsCycle == true)
+            {
+                stations.Add("PMA");
+            }
+            if (PMBIsCycle == true)
+            {
+                stations.Add("PMB");
+            }
+            if (PMCIsCycle == true)
+            {
+                stations.Add("PMC");
+            }
+            stations.Add("VCE1");
+            InvokeClient.Instance.Service.DoOperation("System.SETMCycle", stations.ToArray(), CycleCount);
+
+        }
+
+        private void OnStopCycle()
+        {
+
+            InvokeClient.Instance.Service.DoOperation("System.SEAbort");
+
+        }
+        #endregion
+
+        #region 私有方法
+        private void Timer_Tick(object sender, EventArgs e)
+        {
+            TMModuleInfo = ModuleManager.ModuleInfos["TMRobot"];
+            if (VCEIsInstalled)
+            {
+
+            }
+
+            if (PMAIsInstalled == true)
+            {
+                ModuleInfo PMAModuleInfo = ModuleManager.ModuleInfos["PMA"];
+                PMAWafer = PMAModuleInfo.WaferManager.Wafers[0];
+            }
+            if (PMBIsInstalled == true)
+            {
+                ModuleInfo PMBModuleInfo = ModuleManager.ModuleInfos["PMB"];
+                PMBWafer = PMBModuleInfo.WaferManager.Wafers[0];
+            }
+            if (PMCIsInstalled == true)
+            {
+                ModuleInfo PMCModuleInfo = ModuleManager.ModuleInfos["PMC"];
+                PMCWafer = PMCModuleInfo.WaferManager.Wafers[0];
+            }
+
+            RtDataValues = QueryDataClient.Instance.Service.PollData(m_RtDataKeys);
+            VCEDoorIsOpen = !CommonFunction.GetValue<bool>(RtDataValues, "SETM.VCESlitDoorClosed");
+            PMADoorIsOpen = !CommonFunction.GetValue<bool>(RtDataValues, "SETM.PMASlitDoorClosed");
+            PMBDoorIsOpen = !CommonFunction.GetValue<bool>(RtDataValues, "SETM.PMBSlitDoorClosed");
+            PMCDoorIsOpen = !CommonFunction.GetValue<bool>(RtDataValues, "SETM.PMCSlitDoorClosed");
+            VCEOutDoorIsOpen = !CommonFunction.GetValue<bool>(RtDataValues, "VCE1.VCEOutDoorClosed");
+            RobotMoveInfo = (RobotMoveInfo)QueryDataClient.Instance.Service.GetData("SETM.RobotMoveAction");
+            RobotUpperWafer = TMModuleInfo.WaferManager.Wafers[0];
+            RobotLowerWafer = TMModuleInfo.WaferManager.Wafers[1];
+            PAWafer = ModuleManager.ModuleInfos["VPA"].WaferManager.Wafers[0];
+
+        }
+        private async void RobotMoveInfoChanged(RobotMoveInfo oldValue, RobotMoveInfo newValue)
+        {
+            string RobotTarget;
+            if (oldValue == null || newValue == null)
+            {
+                return;
+            }
+
+            #region Rotating
+            if ((oldValue.Action == RobotAction.None || oldValue.ArmTarget != newValue.ArmTarget) && (newValue.Action == RobotAction.Rotating))
+            {
+                var TMRobotMoveActionBladeTarget = newValue.BladeTarget;
+                if (TMRobotMoveActionBladeTarget != null)
+                {
+                    RobotTarget = TMRobotMoveActionBladeTarget.ToString();
+                }
+                else
+                {
+                    return;
+                }
+                var values = RobotTarget.Split('.');
+                var arm = values[0];
+                var module = values[1];
+                if (arm == "ArmA")
+                {
+                    var SERobotTAction = (SERobotTAction)Enum.Parse(typeof(SERobotTAction), module, true);
+                    if (SERobotTAction != Robot1TAction)
+                    {
+                        Robot1TAction = SERobotTAction;
+                    }
+                }
+                else if (arm == "ArmB")
+                {
+                    var SERobotTAction = (SERobotTAction)Enum.Parse(typeof(SERobotTAction), module, true);
+                    if (SERobotTAction != Robot2TAction)
+                    {
+                        Robot2TAction = SERobotTAction;
+                    }
+                }
+            }
+            #endregion
+
+            #region VPA、VCE1 Pick、Place
+            else if ((oldValue.Action == RobotAction.None || oldValue.ArmTarget != newValue.ArmTarget) && (newValue.Action == RobotAction.Placing || newValue.Action == RobotAction.Picking))
+            {
+                var TMRobotMoveActionBladeTarget = newValue.BladeTarget;
+                if (TMRobotMoveActionBladeTarget != null)
+                {
+                    RobotTarget = TMRobotMoveActionBladeTarget.ToString();
+                }
+                else
+                {
+                    return;
+                }
+                var values = RobotTarget.Split('.');
+                var arm = values[0];
+                var module = values[1];
+                //if (module == "VPA")
+                //{
+                //    module = PMCIsInstalled ? "VPA" : "VPARight";
+                //}
+                if (arm == "ArmA")
+                {
+                    var SERobotTAction = (SERobotTAction)Enum.Parse(typeof(SERobotTAction), module, true);
+                    if (SERobotTAction != Robot1TAction)
+                    {
+                        Robot1TAction = SERobotTAction;
+                    }
+                    await Task.Delay(600);
+
+                    if (module == "VCE1")
+                    {
+                        Robot1XAction = SERobotXAction.ToVCE;
+                    }
+                    else
+                    {
+                        Robot1XAction = SERobotXAction.Extend;
+                    }
+                    while ((newValue.Action == RobotAction.Placing && ModuleManager.ModuleInfos["TMRobot"].WaferManager.Wafers[0].WaferStatus != 0) || (newValue.Action == RobotAction.Picking && ModuleManager.ModuleInfos["TMRobot"].WaferManager.Wafers[0].WaferStatus == 0))
+                    {
+                        await Task.Delay(100);
+                    }
+                    Robot1XAction = SERobotXAction.Retract;
+                }
+                else if (arm == "ArmB")
+                {
+                    var SERobotTAction = (SERobotTAction)Enum.Parse(typeof(SERobotTAction), module, true);
+                    if (SERobotTAction != Robot2TAction)
+                    {
+                        Robot2TAction = SERobotTAction;
+                    }
+                    else
+                    {
+                        //await Task.Delay(100);
+                    }
+                    await Task.Delay(600);
+                    if (module == "VCE1")
+                    {
+                        Robot2XAction = SERobotXAction.ToVCE2;
+                    }
+                    else
+                    {
+                        Robot2XAction = SERobotXAction.Extend2;
+                    }
+                    while ((newValue.Action == RobotAction.Placing && ModuleManager.ModuleInfos["TMRobot"].WaferManager.Wafers[1].WaferStatus != 0) || (newValue.Action == RobotAction.Picking && ModuleManager.ModuleInfos["TMRobot"].WaferManager.Wafers[1].WaferStatus == 0))
+                    {
+                        await Task.Delay(100);
+                    }
+                    Robot2XAction = SERobotXAction.Retract2;
+                }
+
+            }
+            #endregion
+
+            #region PM pick、PM place
+            else if ((oldValue.Action == RobotAction.None || oldValue.ArmTarget != newValue.ArmTarget) && newValue.Action == RobotAction.Extending)
+            {
+                var TMRobotMoveActionBladeTarget = newValue.BladeTarget;
+                if (TMRobotMoveActionBladeTarget != null)
+                {
+                    RobotTarget = TMRobotMoveActionBladeTarget.ToString();
+                }
+                else
+                {
+                    return;
+                }
+                var values = RobotTarget.Split('.');
+                var arm = values[0];
+                var module = values[1];
+                if (arm == "ArmA")
+                {
+                    var SERobotTAction = (SERobotTAction)Enum.Parse(typeof(SERobotTAction), module, true);
+                    if (SERobotTAction != Robot1TAction)
+                    {
+                        Robot1TAction = SERobotTAction;
+                    }
+                    else
+                    {
+                        // await Task.Delay(100);
+                    }
+                    await Task.Delay(600);
+
+                    Robot1XAction = SERobotXAction.Extend;
+                }
+                else if (arm == "ArmB")
+                {
+                    var SERobotTAction = (SERobotTAction)Enum.Parse(typeof(SERobotTAction), module, true);
+                    if (SERobotTAction != Robot2TAction)
+                    {
+                        Robot2TAction = SERobotTAction;
+                    }
+                    else
+                    {
+                        // await Task.Delay(100);
+                    }
+                    await Task.Delay(600);
+
+                    Robot2XAction = SERobotXAction.Extend2;
+                }
+            }
+
+            else if ((oldValue.Action == RobotAction.None || oldValue.ArmTarget != newValue.ArmTarget) && newValue.Action == RobotAction.Retracting)
+            {
+                var TMRobotMoveActionBladeTarget = newValue.BladeTarget;
+                if (TMRobotMoveActionBladeTarget != null)
+                {
+                    RobotTarget = TMRobotMoveActionBladeTarget.ToString();
+                }
+                else
+                {
+                    return;
+                }
+                var values = RobotTarget.Split('.');
+                var arm = values[0];
+                if (arm == "ArmA")
+                {
+                    Robot1XAction = SERobotXAction.Retract;
+                }
+                else if (arm == "ArmB")
+                {
+                    Robot2XAction = SERobotXAction.Retract2;
+                }
+            }
+            #endregion
+            #region Home
+            else if (oldValue.Action == RobotAction.None && newValue.Action == RobotAction.Homing)
+            {
+                if (Robot1XAction == SERobotXAction.Extend)
+                {
+                    Robot1XAction = SERobotXAction.Retract;
+                }
+                if (Robot2XAction == SERobotXAction.Extend2)
+                {
+                    Robot2XAction = SERobotXAction.Retract2;
+                }
+                await Task.Delay(2000);
+                if (Robot1TAction != SERobotTAction.T_Origin)
+                {
+                    Robot1TAction = SERobotTAction.T_Origin;
+                }
+                if (Robot2TAction != SERobotTAction.T_Origin)
+                {
+                    Robot2TAction = SERobotTAction.T_Origin;
+                }
+            }
+
+            #endregion
+
+        }
+
+
+        #endregion
+    }
+
+}

File diff suppressed because it is too large
+ 272 - 0
Venus/Venus_MainPages/Views/VenusDETMView.xaml


+ 28 - 0
Venus/Venus_MainPages/Views/VenusDETMView.xaml.cs

@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Navigation;
+using System.Windows.Shapes;
+
+namespace Venus_MainPages.Views
+{
+    /// <summary>
+    /// VenusDETMView.xaml 的交互逻辑
+    /// </summary>
+    public partial class VenusDETMView : UserControl
+    {
+        public VenusDETMView()
+        {
+            InitializeComponent();
+        }
+    }
+}

BIN
Venus/Venus_Themes/Themes/Images/parts/venusde/VCEleft1.png


BIN
Venus/Venus_Themes/Themes/Images/parts/venusde/VCEright1.png


BIN
Venus/Venus_Themes/Themes/Images/parts/venusde/detm.png


+ 136 - 0
Venus/Venus_Themes/UserControls/DEVceA.xaml

@@ -0,0 +1,136 @@
+<UserControl x:Class="Venus_Themes.UserControls.DEVceA"
+             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
+             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
+             xmlns:local="clr-namespace:Venus_Themes.UserControls"
+             xmlns:converters="clr-namespace:Venus_Themes.Converters"
+             mc:Ignorable="d" 
+             d:DesignHeight="450" d:DesignWidth="800" Name="devceChamber">
+    <UserControl.Resources>
+        <Style TargetType="Rectangle" x:Key="doorAnimation">
+            <Setter Property="Width" Value="200"/>
+            <Style.Triggers>
+                <DataTrigger Binding="{Binding ElementName=tmChamber,Path=DoorIsOpen}" Value="True">
+                    <DataTrigger.EnterActions>
+                        <BeginStoryboard>
+                            <Storyboard>
+                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="40" Duration="0:0:1"/>
+                            </Storyboard>
+                        </BeginStoryboard>
+                    </DataTrigger.EnterActions>
+                    <DataTrigger.ExitActions>
+                        <BeginStoryboard>
+                            <Storyboard>
+                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="102" Duration="0:0:1"/>
+                            </Storyboard>
+                        </BeginStoryboard>
+                    </DataTrigger.ExitActions>
+                </DataTrigger>
+            </Style.Triggers>
+        </Style>
+        <converters:BoolToBool x:Key="BoolToBool"/>
+        <Storyboard x:Key="WaterStoryboard">
+            <PointAnimation Storyboard.TargetName="bs_Water" Storyboard.TargetProperty="Point1" From="15,-10" To="15,10" Duration="00:00:1" AutoReverse="True" RepeatBehavior="Forever"></PointAnimation>
+            <PointAnimation Storyboard.TargetName="bs_Water" Storyboard.TargetProperty="Point2" From="35,10" To="35,-10" Duration="00:00:2.5" AutoReverse="True" RepeatBehavior="Forever"></PointAnimation>
+        </Storyboard>
+        <Storyboard x:Key="WaterWidth">
+            <DoubleAnimation Storyboard.TargetName="rec_Water" Storyboard.TargetProperty="Height" Duration="0:0:0.3">
+
+            </DoubleAnimation>
+        </Storyboard>
+    </UserControl.Resources>
+    <UserControl.Triggers>
+        <EventTrigger RoutedEvent="Loaded">
+            <BeginStoryboard Storyboard="{StaticResource WaterStoryboard}"></BeginStoryboard>
+            <BeginStoryboard Storyboard="{StaticResource WaterWidth}"></BeginStoryboard>
+        </EventTrigger>
+    </UserControl.Triggers>
+    <Viewbox>
+        <Canvas Height="120" Width="200">
+            <Image Width="200" Canvas.Left="0" Canvas.Top="-93" Source="pack://application:,,,/Venus_Themes;component/Themes/Images/parts/venusde/VCEleft1.png"></Image>
+            <!--<Rectangle Cursor="Hand" DataContext="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=UserControl,AncestorLevel=1}}" Style="{StaticResource doorAnimation}"  Fill="DimGray"   VerticalAlignment="Top"    Height="15"    Canvas.Top="-20" Canvas.Left="-4" Name="door2">
+                <Rectangle.RenderTransform >
+                    <RotateTransform CenterX="102" CenterY="10" Angle="180"/>
+                </Rectangle.RenderTransform>
+                <Rectangle.ContextMenu >
+                    <ContextMenu>
+                        <MenuItem Header="Open Door"  Click="OpenDoor_Click"    IsChecked="{Binding DoorIsOpen}" IsEnabled="{Binding DoorIsOpen,Converter={StaticResource BoolToBool}}"/>
+                        <MenuItem Header="Close Door" Click="CloseDoor_Click"    IsChecked="{Binding DoorIsOpen,Converter={StaticResource BoolToBool}}" IsEnabled="{Binding DoorIsOpen}"/>
+                    </ContextMenu>
+                </Rectangle.ContextMenu>
+            </Rectangle>-->
+            <Canvas Canvas.Top="20">
+                <Border Canvas.Bottom="-120" Canvas.Left="10" HorizontalAlignment="Center" Width="180">
+                    <Rectangle Fill="#fac090"  Width="180" Height="10">
+                        <Rectangle.Style>
+                            <Style TargetType="Rectangle">
+                                <Style.Triggers>
+                                    <DataTrigger Binding="{Binding ElementName=devceChamber,Path=VCEOutDoorIsOpen}" Value="True">
+                                        <DataTrigger.EnterActions>
+                                            <BeginStoryboard>
+                                                <Storyboard>
+                                                    <DoubleAnimation  Storyboard.TargetProperty="Width" To="0" Duration="0:0:1"/>
+                                                </Storyboard>
+                                            </BeginStoryboard>
+                                        </DataTrigger.EnterActions>
+                                        <DataTrigger.ExitActions>
+                                            <BeginStoryboard>
+                                                <Storyboard>
+                                                    <DoubleAnimation  Storyboard.TargetProperty="Width" To="180" Duration="0:0:1"/>
+                                                </Storyboard>
+                                            </BeginStoryboard>
+                                        </DataTrigger.ExitActions>
+                                    </DataTrigger>
+                                </Style.Triggers>
+                            </Style>
+                        </Rectangle.Style>
+                    </Rectangle>
+                </Border>
+
+                <Border Canvas.Top="129" Canvas.Left="-5" Height="44" Width="270" Background="Transparent" BorderBrush="Gainsboro" BorderThickness="0,0,3,3" CornerRadius="3" Visibility="{Binding ElementName=devceChamber,Path=IsVenting,Converter={StaticResource bool2VisibilityConverter}}">
+                    <Border.RenderTransform>
+                        <ScaleTransform ScaleX="0.77" ScaleY="0.58"></ScaleTransform>
+                    </Border.RenderTransform>
+                    <Border Background="Transparent" CornerRadius="1" BorderBrush="Black" BorderThickness="3,3,0,0">
+                        <StackPanel Margin="-160,0,0,0" Height="44">
+
+                            <StackPanel   Width="49" Margin="-40 0 45 10">
+                                <StackPanel.RenderTransform>
+                                    <RotateTransform Angle="-90" CenterX="19.5" CenterY="10"></RotateTransform>
+                                </StackPanel.RenderTransform>
+                                <!--矩形-->
+                                <Rectangle x:Name="rec_Water"  Fill="#42a5f5" Height="{Binding ElementName=devceChamber,Path=PercentValue,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" Width="50" Margin="-20,6,0,0"/>
+                                <!--水波-->
+                                <Path Fill="#42a5f5" Margin="0,-16,0,0" Height="10" Stretch="Fill">
+                                    <Path.RenderTransform>
+                                        <RotateTransform Angle="180" CenterX="19.5" CenterY="10"></RotateTransform>
+                                    </Path.RenderTransform>
+                                    <Path.Data>
+                                        <PathGeometry>
+                                            <PathFigure StartPoint="0,0">
+                                                <BezierSegment x:Name="bs_Water" Point1="15,-5" Point2="35,5"  Point3="50,0"></BezierSegment>
+                                                <PolyLineSegment Points="50,10 0,10"></PolyLineSegment>
+                                            </PathFigure>
+                                        </PathGeometry>
+                                    </Path.Data>
+                                </Path>
+                            </StackPanel>
+                        </StackPanel>
+                    </Border>
+                </Border>
+                <StackPanel Width="200" Canvas.Top="130" HorizontalAlignment="Center" VerticalAlignment="Center">
+                    <TextBlock Canvas.Top="130" Canvas.Left="90" TextAlignment="Center" FontSize="20" FontWeight="Normal">
+                        <TextBlock.Text>
+                            <MultiBinding  StringFormat=" {0}({1}mtorr)">
+                                <Binding  ElementName="devceChamber" Path="VCEName"></Binding>
+                                <Binding  ElementName="devceChamber" Path="PressureValue"></Binding>
+                            </MultiBinding>
+                        </TextBlock.Text>
+                    </TextBlock>
+                    <!--<TextBlock Canvas.Top="130" Canvas.Left="90" TextAlignment="Center" FontSize="20" FontWeight="Normal" Text="{Binding ElementName=devceChamber,Path=PressureValue,StringFormat=F0}" />-->
+                </StackPanel>
+            </Canvas>
+        </Canvas>
+    </Viewbox>
+</UserControl>

+ 94 - 0
Venus/Venus_Themes/UserControls/DEVceA.xaml.cs

@@ -0,0 +1,94 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Animation;
+using System.Windows.Media.Imaging;
+using System.Windows.Navigation;
+using System.Windows.Shapes;
+
+namespace Venus_Themes.UserControls
+{
+    /// <summary>
+    /// DEVceA.xaml 的交互逻辑
+    /// </summary>
+    public partial class DEVceA : UserControl
+    {
+        public DEVceA()
+        {
+            InitializeComponent();
+        }
+
+
+        public static readonly DependencyProperty VCEOutDoorIsOpenProperty = DependencyProperty.Register(
+            "VCEOutDoorIsOpen", typeof(bool), typeof(DEVceA));
+        public bool VCEOutDoorIsOpen
+        {
+            get => (bool)GetValue(VCEOutDoorIsOpenProperty);
+            set => SetValue(VCEOutDoorIsOpenProperty, value);
+        }
+
+        public static readonly DependencyProperty IsVentingProperty = DependencyProperty.Register(
+    "IsVenting", typeof(bool), typeof(DEVceA));
+        public bool IsVenting
+        {
+
+            get => (bool)GetValue(IsVentingProperty);
+            set => SetValue(IsVentingProperty, value);
+        }
+
+
+        public static readonly DependencyProperty VCENameProperty = DependencyProperty.Register("VCEName", typeof(string), typeof(DEVceA));
+        public string VCEName
+        {
+            get => (string)GetValue(VCENameProperty);
+            set => SetValue(VCENameProperty, value);
+        }
+
+        public static readonly DependencyProperty PressureValueProperty = DependencyProperty.Register(
+       "PressureValue", typeof(double), typeof(DEVceA));
+
+        public double PressureValue
+        {
+            get { return (double)this.GetValue(PressureValueProperty); }
+            set { this.SetValue(PressureValueProperty, value); }
+        }
+
+        public static readonly DependencyProperty PercentValueProperty = DependencyProperty.Register(
+       "PercentValue", typeof(double), typeof(DEVceA), new PropertyMetadata(0.0, OnDataChanged));
+        private static void OnDataChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
+        {
+            if (d is DEVceA chamber)
+            {
+
+                DoubleAnimation doubleAnimation = new DoubleAnimation((double)e.OldValue, (double)e.NewValue, new Duration(TimeSpan.FromSeconds(1)));
+                chamber.rec_Water.BeginAnimation(HeightProperty, doubleAnimation);
+            }
+        }
+        public double PercentValue
+        {
+            get { return (double)GetValue(PercentValueProperty); }
+            set
+            {
+
+                SetValue(PercentValueProperty, value);
+            }
+        }
+
+        public static readonly DependencyProperty CassetteArriveProperty = DependencyProperty.Register(
+        "CassetteArrive", typeof(bool), typeof(DEVceA));
+        public bool CassetteArrive
+        {
+            get { return (bool)this.GetValue(CassetteArriveProperty); }
+            set { this.SetValue(CassetteArriveProperty, value); }
+        }
+
+    }
+}

+ 117 - 0
Venus/Venus_Themes/UserControls/DEVceB.xaml

@@ -0,0 +1,117 @@
+<UserControl x:Class="Venus_Themes.UserControls.DEVceB"
+             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
+             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
+             xmlns:local="clr-namespace:Venus_Themes.UserControls"
+             xmlns:converters="clr-namespace:Venus_Themes.Converters"
+             mc:Ignorable="d" 
+             d:DesignHeight="450" d:DesignWidth="800" Name="devceBChamber">
+    <UserControl.Resources>
+        <converters:BoolToBool x:Key="BoolToBool"/>
+        <Storyboard x:Key="WaterStoryboard">
+            <PointAnimation Storyboard.TargetName="bs_Water" Storyboard.TargetProperty="Point1" From="15,-10" To="15,10" Duration="00:00:1" AutoReverse="True" RepeatBehavior="Forever"></PointAnimation>
+            <PointAnimation Storyboard.TargetName="bs_Water" Storyboard.TargetProperty="Point2" From="35,10" To="35,-10" Duration="00:00:2.5" AutoReverse="True" RepeatBehavior="Forever"></PointAnimation>
+        </Storyboard>
+        <Storyboard x:Key="WaterWidth">
+            <DoubleAnimation Storyboard.TargetName="rec_Water" Storyboard.TargetProperty="Height" Duration="0:0:0.3">
+
+            </DoubleAnimation>
+        </Storyboard>
+    </UserControl.Resources>
+    <UserControl.Triggers>
+        <EventTrigger RoutedEvent="Loaded">
+            <BeginStoryboard Storyboard="{StaticResource WaterStoryboard}"></BeginStoryboard>
+            <BeginStoryboard Storyboard="{StaticResource WaterWidth}"></BeginStoryboard>
+        </EventTrigger>
+    </UserControl.Triggers>
+    <Viewbox>
+        <Canvas Height="120" Width="200">
+            <Image Width="200" Canvas.Left="0" Canvas.Top="-93" Source="pack://application:,,,/Venus_Themes;component/Themes/Images/parts/venusde/VCEright1.png"></Image>
+            <!--<Rectangle Cursor="Hand" DataContext="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=UserControl,AncestorLevel=1}}" Style="{StaticResource doorAnimation}"  Fill="DimGray"   VerticalAlignment="Top"    Height="15"    Canvas.Top="-20" Canvas.Left="-4" Name="door2">
+                <Rectangle.RenderTransform >
+                    <RotateTransform CenterX="102" CenterY="10" Angle="180"/>
+                </Rectangle.RenderTransform>
+                <Rectangle.ContextMenu >
+                    <ContextMenu>
+                        <MenuItem Header="Open Door"  Click="OpenDoor_Click"    IsChecked="{Binding DoorIsOpen}" IsEnabled="{Binding DoorIsOpen,Converter={StaticResource BoolToBool}}"/>
+                        <MenuItem Header="Close Door" Click="CloseDoor_Click"    IsChecked="{Binding DoorIsOpen,Converter={StaticResource BoolToBool}}" IsEnabled="{Binding DoorIsOpen}"/>
+                    </ContextMenu>
+                </Rectangle.ContextMenu>
+            </Rectangle>-->
+          
+
+            <Canvas Canvas.Top="20">
+                <Border Canvas.Bottom="-120" Canvas.Left="10" HorizontalAlignment="Center" Width="180">
+                    <Rectangle Fill="#fac090"  Width="180" Height="10">
+                        <Rectangle.Style>
+                            <Style TargetType="Rectangle">
+                                <Style.Triggers>
+                                    <DataTrigger Binding="{Binding ElementName=devceBChamber,Path=VCEOutDoorIsOpen}" Value="True">
+                                        <DataTrigger.EnterActions>
+                                            <BeginStoryboard>
+                                                <Storyboard>
+                                                    <DoubleAnimation  Storyboard.TargetProperty="Width" To="0" Duration="0:0:1"/>
+                                                </Storyboard>
+                                            </BeginStoryboard>
+                                        </DataTrigger.EnterActions>
+                                        <DataTrigger.ExitActions>
+                                            <BeginStoryboard>
+                                                <Storyboard>
+                                                    <DoubleAnimation  Storyboard.TargetProperty="Width" To="180" Duration="0:0:1"/>
+                                                </Storyboard>
+                                            </BeginStoryboard>
+                                        </DataTrigger.ExitActions>
+                                    </DataTrigger>
+                                </Style.Triggers>
+                            </Style>
+                        </Rectangle.Style>
+                    </Rectangle>
+                </Border>
+
+                <Border Canvas.Top="129" Canvas.Left="-5" Height="44" Width="270" Background="Transparent" BorderBrush="Gainsboro" BorderThickness="0,0,3,3" CornerRadius="3" Visibility="{Binding ElementName=devceBChamber,Path=IsVenting,Converter={StaticResource bool2VisibilityConverter}}">
+                    <Border.RenderTransform>
+                        <ScaleTransform ScaleX="0.77" ScaleY="0.58"></ScaleTransform>
+                    </Border.RenderTransform>
+                    <Border Background="Transparent" CornerRadius="1" BorderBrush="Black" BorderThickness="3,3,0,0">
+                        <StackPanel Margin="-160,0,0,0" Height="44">
+
+                            <StackPanel   Width="49" Margin="-40 0 45 10">
+                                <StackPanel.RenderTransform>
+                                    <RotateTransform Angle="-90" CenterX="19.5" CenterY="10"></RotateTransform>
+                                </StackPanel.RenderTransform>
+                                <!--矩形-->
+                                <Rectangle x:Name="rec_Water"  Fill="#42a5f5" Height="{Binding ElementName=devceBChamber,Path=PercentValue,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" Width="50" Margin="-20,6,0,0"/>
+                                <!--水波-->
+                                <Path Fill="#42a5f5" Margin="0,-16,0,0" Height="10" Stretch="Fill">
+                                    <Path.RenderTransform>
+                                        <RotateTransform Angle="180" CenterX="19.5" CenterY="10"></RotateTransform>
+                                    </Path.RenderTransform>
+                                    <Path.Data>
+                                        <PathGeometry>
+                                            <PathFigure StartPoint="0,0">
+                                                <BezierSegment x:Name="bs_Water" Point1="15,-5" Point2="35,5"  Point3="50,0"></BezierSegment>
+                                                <PolyLineSegment Points="50,10 0,10"></PolyLineSegment>
+                                            </PathFigure>
+                                        </PathGeometry>
+                                    </Path.Data>
+                                </Path>
+                            </StackPanel>
+                        </StackPanel>
+                    </Border>
+                </Border>
+                <StackPanel Width="200" Canvas.Top="130" HorizontalAlignment="Center" VerticalAlignment="Center">
+                    <TextBlock Canvas.Top="130" Canvas.Left="90" TextAlignment="Center" FontSize="20" FontWeight="Normal">
+                        <TextBlock.Text>
+                            <MultiBinding  StringFormat=" {0}({1}mtorr)">
+                                <Binding  ElementName="devceBChamber" Path="VCEName"></Binding>
+                                <Binding  ElementName="devceBChamber" Path="PressureValue"></Binding>
+                            </MultiBinding>
+                        </TextBlock.Text>
+                    </TextBlock>
+                    <!--<TextBlock Canvas.Top="130" Canvas.Left="90" TextAlignment="Center" FontSize="20" FontWeight="Normal" Text="{Binding ElementName=devceBChamber,Path=PressureValue,StringFormat=F0}" />-->
+                </StackPanel>
+            </Canvas>
+        </Canvas>
+    </Viewbox>
+</UserControl>

+ 94 - 0
Venus/Venus_Themes/UserControls/DEVceB.xaml.cs

@@ -0,0 +1,94 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Animation;
+using System.Windows.Media.Imaging;
+using System.Windows.Navigation;
+using System.Windows.Shapes;
+
+namespace Venus_Themes.UserControls
+{
+    /// <summary>
+    /// DEVceB.xaml 的交互逻辑
+    /// </summary>
+    public partial class DEVceB : UserControl
+    {
+        public DEVceB()
+        {
+            InitializeComponent();
+        }
+
+
+        public static readonly DependencyProperty VCEOutDoorIsOpenProperty = DependencyProperty.Register(
+            "VCEOutDoorIsOpen", typeof(bool), typeof(DEVceB));
+        public bool VCEOutDoorIsOpen
+        {
+            get => (bool)GetValue(VCEOutDoorIsOpenProperty);
+            set => SetValue(VCEOutDoorIsOpenProperty, value);
+        }
+
+        public static readonly DependencyProperty IsVentingProperty = DependencyProperty.Register(
+    "IsVenting", typeof(bool), typeof(DEVceB));
+        public bool IsVenting
+        {
+
+            get => (bool)GetValue(IsVentingProperty);
+            set => SetValue(IsVentingProperty, value);
+        }
+
+
+        public static readonly DependencyProperty VCENameProperty = DependencyProperty.Register("VCEName", typeof(string), typeof(DEVceB));
+        public string VCEName
+        {
+            get => (string)GetValue(VCENameProperty);
+            set => SetValue(VCENameProperty, value);
+        }
+
+        public static readonly DependencyProperty PressureValueProperty = DependencyProperty.Register(
+       "PressureValue", typeof(double), typeof(DEVceB));
+
+        public double PressureValue
+        {
+            get { return (double)this.GetValue(PressureValueProperty); }
+            set { this.SetValue(PressureValueProperty, value); }
+        }
+
+        public static readonly DependencyProperty PercentValueProperty = DependencyProperty.Register(
+       "PercentValue", typeof(double), typeof(DEVceB), new PropertyMetadata(0.0, OnDataChanged));
+        private static void OnDataChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
+        {
+            if (d is DEVceB chamber)
+            {
+
+                DoubleAnimation doubleAnimation = new DoubleAnimation((double)e.OldValue, (double)e.NewValue, new Duration(TimeSpan.FromSeconds(1)));
+                chamber.rec_Water.BeginAnimation(HeightProperty, doubleAnimation);
+            }
+        }
+        public double PercentValue
+        {
+            get { return (double)GetValue(PercentValueProperty); }
+            set
+            {
+
+                SetValue(PercentValueProperty, value);
+            }
+        }
+
+        public static readonly DependencyProperty CassetteArriveProperty = DependencyProperty.Register(
+        "CassetteArrive", typeof(bool), typeof(DEVceB));
+        public bool CassetteArrive
+        {
+            get { return (bool)this.GetValue(CassetteArriveProperty); }
+            set { this.SetValue(CassetteArriveProperty, value); }
+        }
+
+    }
+}

+ 561 - 0
Venus/Venus_Themes/UserControls/VenusDETM.xaml

@@ -0,0 +1,561 @@
+<UserControl x:Class="Venus_Themes.UserControls.VenusDETM"
+             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
+             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
+             xmlns:local="clr-namespace:Venus_Themes.UserControls"
+             mc:Ignorable="d" 
+             xmlns:converters="clr-namespace:Venus_Themes.Converters"
+             d:DesignHeight="450" d:DesignWidth="800" Name="venusSetm">
+    <UserControl.Resources>
+        <converters:BoolToVisibility x:Key="boolToVisibility"/>
+        <converters:BoolToVisibility2 x:Key="boolToVisibility2"/>
+        <converters:BoolToBool x:Key="BoolToBool"/>
+        <Style x:Key="DoorAnimationStyle" TargetType="Rectangle">
+            <Setter Property="RenderTransform">
+                <Setter.Value>
+                    <RotateTransform Angle="0"/>
+                </Setter.Value>
+            </Setter>
+            <Style.Triggers>
+                <DataTrigger Binding="{Binding IsOpen}" Value="True">
+                    <DataTrigger.EnterActions>
+                        <BeginStoryboard>
+                            <Storyboard>
+                                <DoubleAnimation From="0" To="-90" Duration="0:0:1"
+                                                 Storyboard.TargetProperty="(Rectangle.RenderTransform).(RotateTransform.Angle)"/>
+                            </Storyboard>
+                        </BeginStoryboard>
+                    </DataTrigger.EnterActions>
+                </DataTrigger>
+            </Style.Triggers>
+        </Style>
+    </UserControl.Resources>
+    <Viewbox>
+        <Canvas Width="200" Height="200">
+            <Image Width="280" Canvas.Left="20" Source="pack://application:,,,/Venus_Themes;component/Themes/Images/parts/venusde/detm.png"></Image>
+
+            <!-- robot -->
+            <!--<Border BorderBrush="Gray" BorderThickness="2" Canvas.Top="20" Canvas.Left="20" CornerRadius="2">
+                <Rectangle Height="200" Width="200" >
+                    <Rectangle.Fill>
+                        <LinearGradientBrush StartPoint="-1,0" EndPoint="0,-1">
+                            <GradientStop Color="Gray" Offset="0"></GradientStop>
+                            <GradientStop Color="LightGray" Offset=".2"></GradientStop>
+                            <GradientStop Color="White" Offset=".5"></GradientStop>
+                            <GradientStop Color="LightGray" Offset=".8"></GradientStop>
+                            <GradientStop Color="Gray" Offset="1"></GradientStop>
+                        </LinearGradientBrush>
+                    </Rectangle.Fill>
+                </Rectangle>
+            </Border>-->
+            <!-- aligner1 两个位置 112,225 222,75-->
+            <Viewbox Stretch="Uniform" Width="80" Height="80" Canvas.Left="335" Canvas.Top="120" Name="VPAligner" Visibility="{Binding ElementName=venusSetm,Path=VPAIsShow,Converter={StaticResource boolToVisibility2}}" Canvas.ZIndex="2">
+
+                <Canvas UseLayoutRounding="False"  Width="100" Height="100" HorizontalAlignment="Center" VerticalAlignment="Top">
+                    <Canvas.Background>
+                        <LinearGradientBrush StartPoint="0,0" EndPoint="1,1">
+                            <GradientStop Color="Gray" Offset="0"></GradientStop>
+                            <GradientStop Color="White" Offset=".5"></GradientStop>
+                            <GradientStop Color="Gray" Offset="1"></GradientStop>
+                        </LinearGradientBrush>
+                    </Canvas.Background>
+                    <TextBlock Text="Aligner" FontSize="15" Canvas.Top="20" Canvas.Left="120" FontWeight="Normal">
+                        <TextBlock.RenderTransform>
+                            <RotateTransform Angle="90" />
+                        </TextBlock.RenderTransform>
+                    </TextBlock>
+                    <Canvas  Width="72.522" Height="72.521" Canvas.Left="14" Canvas.Top="14">
+                        <Path Data="F1M10.473,65.041C10.473,85.068,26.708,101.302,46.734,101.302L46.734,101.302C66.761,101.302,82.995,85.068,82.995,65.041L82.995,65.041C82.995,45.015,66.761,28.781,46.734,28.781L46.734,28.781C26.708,28.781,10.473,45.015,10.473,65.041" Stretch="Fill" Width="72.522" Height="72.521" Canvas.Left="0" Canvas.Top="0">
+                            <Path.Fill>
+                                <RadialGradientBrush Center="0.5,0.5" RadiusX="0.5" RadiusY="0.5" GradientOrigin="0.5,0.5">
+                                    <RadialGradientBrush.GradientStops>
+                                        <GradientStop Color="#FFE5E2DF" Offset="0" />
+                                        <GradientStop Color="#FFFFFFFF" Offset="0" />
+                                        <GradientStop Color="#FFADAEB0" Offset="0.52" />
+                                        <GradientStop Color="sc#1, 0.238698155, 0.250727534, 0.259264916" Offset="0.82" />
+                                        <GradientStop Color="#FF454F52" Offset="1" />
+                                    </RadialGradientBrush.GradientStops>
+                                </RadialGradientBrush>
+                            </Path.Fill>
+                        </Path>
+                        <Path Data="M46.8477,55.6938C52.0087,55.6938 56.1937,59.8788 56.1937,65.0398 56.1937,70.2008 52.0087,74.3858 46.8477,74.3858 41.6857,74.3858 37.5007,70.2008 37.5007,65.0398 37.5007,59.8788 41.6857,55.6938 46.8477,55.6938z" Stretch="Fill" Stroke="White" StrokeThickness="0.25" Width="18.943" Height="18.942" Canvas.Left="26.903" Canvas.Top="26.788" />
+                    </Canvas>
+                    <Canvas   Width="5.857" Height="5.855" Canvas.Left="48" Canvas.Top="48">
+                        <Path Data="M46.8477,62.1133C48.4637,62.1133 49.7757,63.4243 49.7757,65.0413 49.7757,66.6583 48.4637,67.9683 46.8477,67.9683 45.2307,67.9683 43.9187,66.6583 43.9187,65.0413 43.9187,63.4243 45.2307,62.1133 46.8477,62.1133z" Stretch="Fill" Fill="LightBlue" Stroke="#FF4C4C4C" StrokeThickness="0.25" Width="6.107" Height="6.105" Canvas.Left="-0.125" Canvas.Top="-0.125" />
+                    </Canvas>
+                    <Canvas   Width="56.555" Height="56.556" Canvas.Left="23" Canvas.Top="23">
+                        <Path Data="M46.8477,46.3472C57.1717,46.3472 65.5407,54.7172 65.5407,65.0412 65.5407,75.3652 57.1717,83.7342 46.8477,83.7342 36.5227,83.7342 28.1537,75.3652 28.1537,65.0412 28.1537,54.7172 36.5227,46.3472 46.8477,46.3472z" Stretch="Fill" Stroke="White" StrokeThickness="0.25" Width="37.637" Height="37.637" Canvas.Left="9.459" Canvas.Top="9.46" />
+                        <Path Data="M46.8477,36.8872C62.3957,36.8872 74.9997,49.4912 74.9997,65.0402 74.9997,80.5882 62.3957,93.1932 46.8477,93.1932 31.2987,93.1932 18.6947,80.5882 18.6947,65.0402 18.6947,49.4912 31.2987,36.8872 46.8477,36.8872z" Stretch="Fill" Stroke="White" StrokeThickness="0.25" Width="56.555" Height="56.556" />
+                    </Canvas>
+
+                    <local:WaferCtrl WaferData="{Binding ElementName=venusSetm, Path=PAWafer}" Canvas.Left="18" Canvas.Top="18"/>
+                </Canvas>
+            </Viewbox>
+
+            <Canvas Width="85" Height="20">
+                <Rectangle Width="85" Height="20" HorizontalAlignment="Center" Canvas.Left="45" VerticalAlignment="Top" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=PMBIsInstalled,Converter={StaticResource boolToVisibility2}}" RenderTransformOrigin="0.5,0.5" Canvas.Top="22">
+                    <Rectangle.RenderTransform>
+                        <TransformGroup>
+                            <ScaleTransform/>
+                            <SkewTransform/>
+                            <RotateTransform Angle="-30"/>
+                            <TranslateTransform/>
+                        </TransformGroup>
+                    </Rectangle.RenderTransform>
+                    <Rectangle.Style>
+                        <Style TargetType="Rectangle">
+                            <Style.Triggers>
+                                <DataTrigger Binding="{Binding ElementName=venusSetm,Path=PMBDoorIsOpen}" Value="True">
+                                    <DataTrigger.EnterActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.EnterActions>
+                                    <DataTrigger.ExitActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.ExitActions>
+                                </DataTrigger>
+                            </Style.Triggers>
+                        </Style>
+                    </Rectangle.Style>
+                    <Rectangle.DataContext>
+                        <local:Door></local:Door>
+                    </Rectangle.DataContext>
+                </Rectangle>
+
+                <Rectangle Fill="#bababa" Panel.ZIndex="-1"  Width="85" Height="20" HorizontalAlignment="Left" Canvas.Left="44"  Visibility="{Binding ElementName=venusSetm,Path=PMBIsInstalled,Converter={StaticResource boolToVisibility2}}" RenderTransformOrigin="0.5,0.5" VerticalAlignment="Center" Canvas.Top="23">
+                    <Rectangle.RenderTransform>
+                        <TransformGroup>
+                            <ScaleTransform/>
+                            <SkewTransform/>
+                            <RotateTransform Angle="-30"/>
+                            <TranslateTransform/>
+                        </TransformGroup>
+                    </Rectangle.RenderTransform>
+                </Rectangle>
+                <Rectangle Width="85" Height="20" HorizontalAlignment="Center" Canvas.Left="129" Canvas.Top="20" VerticalAlignment="Top" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=PMBIsInstalled,Converter={StaticResource boolToVisibility2}}">
+                    <Rectangle.Style>
+                        <Style TargetType="Rectangle">
+                            <Setter Property="RenderTransform">
+                                <Setter.Value>
+                                    <RotateTransform Angle="0"/>
+                                </Setter.Value>
+                            </Setter>
+                            <Style.Triggers>
+                                <DataTrigger Binding="{Binding ElementName=venusSetm,Path=PMBDoorIsOpen}" Value="True">
+                                    <DataTrigger.EnterActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.EnterActions>
+                                    <DataTrigger.ExitActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.ExitActions>
+                                </DataTrigger>
+                            </Style.Triggers>
+                        </Style>
+                    </Rectangle.Style>
+                    <Rectangle.RenderTransform>
+                        <TransformGroup>
+                            <ScaleTransform/>
+                            <SkewTransform/>
+                            <RotateTransform Angle="149.285"/>
+                            <TranslateTransform/>
+                        </TransformGroup>
+                    </Rectangle.RenderTransform>
+                </Rectangle>
+
+            </Canvas>
+
+            <Rectangle Fill="#bababa" Panel.ZIndex="-1"  Width="85" Height="20" HorizontalAlignment="Center" Canvas.Left="22" Canvas.Top="120" VerticalAlignment="Top"  Visibility="{Binding ElementName=venusSetm,Path=PMAIsInstalled,Converter={StaticResource boolToVisibility2}}" >
+                <Rectangle.RenderTransform>
+                    <TransformGroup>
+                        <RotateTransform Angle="90"/>
+                    </TransformGroup>
+                </Rectangle.RenderTransform>
+            </Rectangle>
+            <Rectangle Width="85" Height="20" HorizontalAlignment="Center" Canvas.Left="22" Canvas.Top="120" VerticalAlignment="Top" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=PMAIsInstalled,Converter={StaticResource boolToVisibility2}}" >
+                <Rectangle.Style>
+                    <Style TargetType="Rectangle">
+                        <Style.Triggers>
+                            <DataTrigger Binding="{Binding ElementName=venusSetm,Path=PMADoorIsOpen}" Value="True">
+                                <DataTrigger.EnterActions>
+                                    <BeginStoryboard>
+                                        <Storyboard>
+                                            <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                        </Storyboard>
+                                    </BeginStoryboard>
+                                </DataTrigger.EnterActions>
+                                <DataTrigger.ExitActions>
+                                    <BeginStoryboard>
+                                        <Storyboard>
+                                            <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                        </Storyboard>
+                                    </BeginStoryboard>
+                                </DataTrigger.ExitActions>
+                            </DataTrigger>
+                        </Style.Triggers>
+                    </Style>
+                </Rectangle.Style>
+                <Rectangle.RenderTransform>
+                    <TransformGroup>
+                        <RotateTransform Angle="90"/>
+                    </TransformGroup>
+                </Rectangle.RenderTransform>
+            </Rectangle>
+
+            <Rectangle Width="85" Height="20" HorizontalAlignment="Center" Canvas.Top="204" VerticalAlignment="Top" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=PMAIsInstalled,Converter={StaticResource boolToVisibility2}}" Canvas.Left="2" >
+                <Rectangle.Style>
+                    <Style TargetType="Rectangle">
+                        <Style.Triggers>
+                            <DataTrigger Binding="{Binding ElementName=venusSetm,Path=PMADoorIsOpen}" Value="True">
+                                <DataTrigger.EnterActions>
+                                    <BeginStoryboard>
+                                        <Storyboard>
+                                            <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                        </Storyboard>
+                                    </BeginStoryboard>
+                                </DataTrigger.EnterActions>
+                                <DataTrigger.ExitActions>
+                                    <BeginStoryboard>
+                                        <Storyboard>
+                                            <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                        </Storyboard>
+                                    </BeginStoryboard>
+                                </DataTrigger.ExitActions>
+                            </DataTrigger>
+                        </Style.Triggers>
+                    </Style>
+                </Rectangle.Style>
+                <Rectangle.RenderTransform>
+                    <TransformGroup>
+                        <RotateTransform Angle="-90"/>
+                    </TransformGroup>
+                </Rectangle.RenderTransform>
+            </Rectangle>
+
+            <Rectangle Fill="#bababa" Panel.ZIndex="-1"  Width="85" Height="20" HorizontalAlignment="Center" Canvas.Left="203" VerticalAlignment="Top" Visibility="{Binding ElementName=venusSetm,Path=PMCIsInstalled,Converter={StaticResource boolToVisibility2}}" Canvas.Top="2">
+                <Rectangle.RenderTransform>
+                    <TransformGroup>
+                        <RotateTransform Angle="30"/>
+                    </TransformGroup>
+                </Rectangle.RenderTransform>
+            </Rectangle>
+            <Rectangle Width="85" Height="20" HorizontalAlignment="Left" Canvas.Left="203" VerticalAlignment="Center" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=PMCIsInstalled,Converter={StaticResource boolToVisibility2}}" Cursor="" Canvas.Top="2" >
+                <Rectangle.Style>
+                    <Style TargetType="Rectangle">
+                        <Style.Triggers>
+                            <DataTrigger Binding="{Binding ElementName=venusSetm,Path=PMCDoorIsOpen}" Value="True">
+                                <DataTrigger.EnterActions>
+                                    <BeginStoryboard>
+                                        <Storyboard>
+                                            <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                        </Storyboard>
+                                    </BeginStoryboard>
+                                </DataTrigger.EnterActions>
+                                <DataTrigger.ExitActions>
+                                    <BeginStoryboard>
+                                        <Storyboard>
+                                            <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                        </Storyboard>
+                                    </BeginStoryboard>
+                                </DataTrigger.ExitActions>
+                            </DataTrigger>
+                        </Style.Triggers>
+                    </Style>
+                </Rectangle.Style>
+                <Rectangle.RenderTransform>
+                    <TransformGroup>
+                        <ScaleTransform/>
+                        <SkewTransform/>
+                        <RotateTransform Angle="30"/>
+                        <TranslateTransform/>
+                    </TransformGroup>
+                </Rectangle.RenderTransform>
+            </Rectangle>
+            <Rectangle Width="85" Height="20" HorizontalAlignment="Left" Canvas.Left="203" VerticalAlignment="Center" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=PMCIsInstalled,Converter={StaticResource boolToVisibility2}}" Cursor="" Canvas.Top="2" >
+                <Rectangle.Style>
+                    <Style TargetType="Rectangle">
+                        <Style.Triggers>
+                            <DataTrigger Binding="{Binding ElementName=venusSetm,Path=PMCDoorIsOpen}" Value="True">
+                                <DataTrigger.EnterActions>
+                                    <BeginStoryboard>
+                                        <Storyboard>
+                                            <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                        </Storyboard>
+                                    </BeginStoryboard>
+                                </DataTrigger.EnterActions>
+                                <DataTrigger.ExitActions>
+                                    <BeginStoryboard>
+                                        <Storyboard>
+                                            <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                        </Storyboard>
+                                    </BeginStoryboard>
+                                </DataTrigger.ExitActions>
+                            </DataTrigger>
+                        </Style.Triggers>
+                    </Style>
+                </Rectangle.Style>
+                <Rectangle.RenderTransform>
+                    <TransformGroup>
+                        <ScaleTransform/>
+                        <SkewTransform/>
+                        <RotateTransform Angle="30"/>
+                        <TranslateTransform/>
+                    </TransformGroup>
+                </Rectangle.RenderTransform>
+            </Rectangle>
+
+            <!--#region Aligner-->
+
+            <Canvas Width="100" Height="100" Canvas.Left="222" Canvas.Top="65" RenderTransformOrigin="0.5,0.5">
+                <Canvas.RenderTransform>
+                    <TransformGroup>
+                        <ScaleTransform/>
+                        <SkewTransform/>
+                        <RotateTransform Angle="-90"/>
+                        <TranslateTransform/>
+                    </TransformGroup>
+                </Canvas.RenderTransform>
+                <Rectangle Fill="#bababa" Panel.ZIndex="-1"  Width="85" Height="20" HorizontalAlignment="Left" Canvas.Left="-38" Canvas.Top="76" VerticalAlignment="Center" Visibility="{Binding ElementName=venusSetm,Path=VCEIsInstalled,Converter={StaticResource boolToVisibility2}}">
+                </Rectangle>
+                <Rectangle Width="85" Height="20" HorizontalAlignment="Center" Canvas.Left="46" Canvas.Top="96" VerticalAlignment="Top" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=VCEIsInstalled,Converter={StaticResource boolToVisibility2}}" >
+                    <Rectangle.Style>
+                        <Style TargetType="Rectangle">
+                            <Style.Triggers>
+                                <DataTrigger Binding="{Binding ElementName=venusSetm,Path=VCEDoorIsOpen}" Value="True">
+                                    <DataTrigger.EnterActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.EnterActions>
+                                    <DataTrigger.ExitActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.ExitActions>
+                                </DataTrigger>
+                            </Style.Triggers>
+                        </Style>
+                    </Rectangle.Style>
+
+                    <Rectangle.RenderTransform>
+                        <TransformGroup>
+                            <RotateTransform Angle="-180"/>
+                        </TransformGroup>
+                    </Rectangle.RenderTransform>
+                </Rectangle>
+                <Rectangle Width="85" Height="20" HorizontalAlignment="Left" Canvas.Left="-38" Canvas.Top="76" VerticalAlignment="Center" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=VCEIsInstalled,Converter={StaticResource boolToVisibility2}}" >
+                    <Rectangle.Style>
+                        <Style TargetType="Rectangle">
+                            <Style.Triggers>
+                                <DataTrigger Binding="{Binding ElementName=venusSetm,Path=VCEDoorIsOpen}" Value="True">
+                                    <DataTrigger.EnterActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.EnterActions>
+                                    <DataTrigger.ExitActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="150" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.ExitActions>
+                                </DataTrigger>
+                            </Style.Triggers>
+                        </Style>
+                    </Rectangle.Style>
+                </Rectangle>
+
+                <!--过道-->
+                <Border  Canvas.Top="94" Canvas.Left="-65" BorderBrush="Gray" BorderThickness="3" CornerRadius="0,0,5,5" Opacity=".5">
+                    <Canvas Width="130" Height="110" HorizontalAlignment="Left" VerticalAlignment="Top" Panel.ZIndex="2">
+                        <Canvas.Background>
+                            <LinearGradientBrush StartPoint="1,1" EndPoint="0,0">
+                                <GradientStop Color="Gray" Offset="0"></GradientStop>
+                                <GradientStop Color="LightGray" Offset=".2"></GradientStop>
+                                <GradientStop Color="White" Offset=".5"></GradientStop>
+                                <GradientStop Color="LightGray" Offset=".8"></GradientStop>
+                                <GradientStop Color="Gray" Offset="1"></GradientStop>
+                            </LinearGradientBrush>
+                        </Canvas.Background>
+                    </Canvas>
+                </Border>
+            </Canvas>
+
+            <!--#endregion-->
+
+            <!--#region vce-->
+            <Canvas Width="85" Height="20" Canvas.Top="229" Canvas.Left="-14">
+                <Rectangle Fill="#bababa" Panel.ZIndex="-1"  Width="70" Height="20" HorizontalAlignment="Left" Canvas.Left="211" VerticalAlignment="Center" Visibility="{Binding ElementName=venusSetm,Path=PMCIsInstalled,Converter={StaticResource boolToVisibility2}}" Canvas.Top="72">
+                    <Rectangle.RenderTransform>
+                        <TransformGroup>
+                            <RotateTransform Angle="-30"/>
+                        </TransformGroup>
+                    </Rectangle.RenderTransform>
+                </Rectangle>
+                <Rectangle Width="85" Height="20" HorizontalAlignment="Left" Canvas.Left="211" Canvas.Top="72" VerticalAlignment="Center" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=PMCIsInstalled,Converter={StaticResource boolToVisibility2}}" Cursor="" >
+                    <Rectangle.Style>
+                        <Style TargetType="Rectangle">
+                            <Style.Triggers>
+                                <DataTrigger Binding="{Binding ElementName=venusSetm,Path=PMCDoorIsOpen}" Value="True">
+                                    <DataTrigger.EnterActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.EnterActions>
+                                    <DataTrigger.ExitActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.ExitActions>
+                                </DataTrigger>
+                            </Style.Triggers>
+                        </Style>
+                    </Rectangle.Style>
+                    <Rectangle.RenderTransform>
+                        <TransformGroup>
+                            <ScaleTransform/>
+                            <SkewTransform/>
+                            <RotateTransform Angle="-30"/>
+                            <TranslateTransform/>
+                        </TransformGroup>
+                    </Rectangle.RenderTransform>
+                </Rectangle>
+                <Rectangle Width="85" Height="20" HorizontalAlignment="Left" Canvas.Left="211" VerticalAlignment="Center" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=PMCIsInstalled,Converter={StaticResource boolToVisibility2}}" Cursor="" Canvas.Top="72" >
+                    <Rectangle.Style>
+                        <Style TargetType="Rectangle">
+                            <Style.Triggers>
+                                <DataTrigger Binding="{Binding ElementName=venusSetm,Path=PMCDoorIsOpen}" Value="True">
+                                    <DataTrigger.EnterActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.EnterActions>
+                                    <DataTrigger.ExitActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.ExitActions>
+                                </DataTrigger>
+                            </Style.Triggers>
+                        </Style>
+                    </Rectangle.Style>
+                    <Rectangle.RenderTransform>
+                        <TransformGroup>
+                            <ScaleTransform/>
+                            <SkewTransform/>
+                            <RotateTransform Angle="-30"/>
+                            <TranslateTransform/>
+                        </TransformGroup>
+                    </Rectangle.RenderTransform>
+                </Rectangle>
+
+            </Canvas>
+            <Canvas Width="85" Height="20" Canvas.Top="186" Canvas.Left="-120">
+                <Rectangle Fill="#bababa" Panel.ZIndex="-1"  Width="85" Height="20" HorizontalAlignment="Center" Canvas.Left="173" VerticalAlignment="Top" Visibility="{Binding ElementName=venusSetm,Path=PMCIsInstalled,Converter={StaticResource boolToVisibility2}}" Canvas.Top="72">
+                    <Rectangle.RenderTransform>
+                        <TransformGroup>
+                            <RotateTransform Angle="30"/>
+                        </TransformGroup>
+                    </Rectangle.RenderTransform>
+                </Rectangle>
+                <Rectangle Width="85" Height="20" HorizontalAlignment="Center" Canvas.Left="173" Canvas.Top="73" VerticalAlignment="Top" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=PMCIsInstalled,Converter={StaticResource boolToVisibility2}}" Cursor="" >
+                    <Rectangle.Style>
+                        <Style TargetType="Rectangle">
+                            <Style.Triggers>
+                                <DataTrigger Binding="{Binding ElementName=venusSetm,Path=PMCDoorIsOpen}" Value="True">
+                                    <DataTrigger.EnterActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.EnterActions>
+                                    <DataTrigger.ExitActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.ExitActions>
+                                </DataTrigger>
+                            </Style.Triggers>
+                        </Style>
+                    </Rectangle.Style>
+                    <Rectangle.RenderTransform>
+                        <TransformGroup>
+                            <ScaleTransform/>
+                            <SkewTransform/>
+                            <RotateTransform Angle="30"/>
+                            <TranslateTransform/>
+                        </TransformGroup>
+                    </Rectangle.RenderTransform>
+                </Rectangle>
+                <Rectangle Width="85" Height="20" HorizontalAlignment="Center" Canvas.Left="173" VerticalAlignment="Top" Fill="Gray" Opacity=".8" Visibility="{Binding ElementName=venusSetm,Path=PMCIsInstalled,Converter={StaticResource boolToVisibility2}}" Cursor="" Canvas.Top="72" >
+                    <Rectangle.Style>
+                        <Style TargetType="Rectangle">
+                            <Style.Triggers>
+                                <DataTrigger Binding="{Binding ElementName=venusSetm,Path=PMCDoorIsOpen}" Value="True">
+                                    <DataTrigger.EnterActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="20" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.EnterActions>
+                                    <DataTrigger.ExitActions>
+                                        <BeginStoryboard>
+                                            <Storyboard>
+                                                <DoubleAnimation  Storyboard.TargetProperty="Width" To="85" Duration="0:0:1"/>
+                                            </Storyboard>
+                                        </BeginStoryboard>
+                                    </DataTrigger.ExitActions>
+                                </DataTrigger>
+                            </Style.Triggers>
+                        </Style>
+                    </Rectangle.Style>
+                    <Rectangle.RenderTransform>
+                        <TransformGroup>
+                            <ScaleTransform/>
+                            <SkewTransform/>
+                            <RotateTransform Angle="30"/>
+                            <TranslateTransform/>
+                        </TransformGroup>
+                    </Rectangle.RenderTransform>
+                </Rectangle>
+
+            </Canvas>
+            <!--#endregion-->
+        </Canvas>
+    </Viewbox>
+
+</UserControl>

+ 130 - 0
Venus/Venus_Themes/UserControls/VenusDETM.xaml.cs

@@ -0,0 +1,130 @@
+using OpenSEMI.ClientBase;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Navigation;
+using System.Windows.Shapes;
+using Venus_Core;
+
+namespace Venus_Themes.UserControls
+{
+    /// <summary>
+    /// VenusDETM.xaml 的交互逻辑
+    /// </summary>
+    public partial class VenusDETM : UserControl
+    {
+
+        public VenusDETM()
+        {
+            InitializeComponent();
+        }
+
+        public static readonly DependencyProperty VCEIsInstalledProperty = DependencyProperty.Register(
+            "VCEIsInstalled", typeof(bool), typeof(VenusDETM));
+        public bool VCEIsInstalled
+        {
+            get => (bool)GetValue(VCEIsInstalledProperty);
+            set => SetValue(VCEIsInstalledProperty, value);
+        }
+        public static readonly DependencyProperty PMAIsInstalledProperty = DependencyProperty.Register(
+        "PMAIsInstalled", typeof(bool), typeof(VenusDETM));
+        public bool PMAIsInstalled
+        {
+            get => (bool)GetValue(PMAIsInstalledProperty);
+            set => SetValue(PMAIsInstalledProperty, value);
+        }
+        public static readonly DependencyProperty PMBIsInstalledProperty = DependencyProperty.Register(
+        "PMBIsInstalled", typeof(bool), typeof(VenusDETM));
+        public bool PMBIsInstalled
+        {
+            get => (bool)GetValue(PMBIsInstalledProperty);
+            set => SetValue(PMBIsInstalledProperty, value);
+        }
+        public static readonly DependencyProperty PMCIsInstalledProperty = DependencyProperty.Register(
+        "PMCIsInstalled", typeof(bool), typeof(VenusDETM), new PropertyMetadata(true, OnDataPropertyChanged));
+
+        public static readonly DependencyProperty PAWaferProperty = DependencyProperty.Register(
+        "PAWafer", typeof(WaferInfo), typeof(VenusDETM));
+        public WaferInfo PAWafer
+        {
+            get => (WaferInfo)GetValue(PAWaferProperty);
+            set => SetValue(PAWaferProperty, value);
+        }
+        private static void OnDataPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
+        {
+            if (d is VenusDETM setm)
+            {
+                if ((bool)e.NewValue)
+                {
+                    setm.VPAligner.SetValue(Canvas.LeftProperty, 84.0);
+                    setm.VPAligner.SetValue(Canvas.TopProperty, 240.0);
+                }
+                else
+                {
+                    setm.VPAligner.SetValue(Canvas.LeftProperty, 222.0);
+                    setm.VPAligner.SetValue(Canvas.TopProperty, 75.0);
+                }
+            }
+        }
+
+        public bool PMCIsInstalled
+        {
+            get => (bool)GetValue(PMCIsInstalledProperty);
+            set
+            {
+                SetValue(PMCIsInstalledProperty, value);
+            }
+        }
+
+        public static readonly DependencyProperty VPAIsShowProperty = DependencyProperty.Register(
+        "VPAIsShow", typeof(bool), typeof(VenusDETM));
+        public bool VPAIsShow
+        {
+            get => (bool)GetValue(VPAIsShowProperty);
+            set => SetValue(VPAIsShowProperty, value);
+        }
+
+        public static readonly DependencyProperty PMADoorIsOpenProperty = DependencyProperty.Register(
+        "PMADoorIsOpen", typeof(bool), typeof(VenusDETM));
+        public bool PMADoorIsOpen
+        {
+            get => (bool)GetValue(PMADoorIsOpenProperty);
+            set => SetValue(PMADoorIsOpenProperty, value);
+        }
+
+        public static readonly DependencyProperty PMBDoorIsOpenProperty = DependencyProperty.Register(
+        "PMBDoorIsOpen", typeof(bool), typeof(VenusDETM));
+        public bool PMBDoorIsOpen
+        {
+            get => (bool)GetValue(PMBDoorIsOpenProperty);
+            set => SetValue(PMBDoorIsOpenProperty, value);
+        }
+
+        public static readonly DependencyProperty PMCDoorIsOpenProperty = DependencyProperty.Register(
+        "PMCDoorIsOpen", typeof(bool), typeof(VenusDETM));
+        public bool PMCDoorIsOpen
+        {
+            get => (bool)GetValue(PMCDoorIsOpenProperty);
+            set => SetValue(PMCDoorIsOpenProperty, value);
+        }
+
+        public static readonly DependencyProperty VCEDoorIsOpenProperty = DependencyProperty.Register(
+        "VCEDoorIsOpen", typeof(bool), typeof(VenusDETM));
+        public bool VCEDoorIsOpen
+        {
+            get => (bool)GetValue(VCEDoorIsOpenProperty);
+            set => SetValue(VCEDoorIsOpenProperty, value);
+        }
+
+    }
+
+}