Przeglądaj źródła

1.高温Heater position1-position5加上动画
2.Operation界面 remove/set wafer Button 改为create job后无法使用
3.kepler2200/Kepler2300 所有界面改为 切换到当前界面再刷UI界面(提升wpf 性能)

lixiang 1 rok temu
rodzic
commit
e00ff4f30d
34 zmienionych plików z 843 dodań i 231 usunięć
  1. 3 0
      Venus/Framework/ClientBase/OpenSEMI.ClientBase.csproj
  2. 3 0
      Venus/Framework/OpenControl/OpenSEMI.Ctrlib.csproj
  3. 2 2
      Venus/Framework/OpenControl/generic.xaml
  4. 3 0
      Venus/Framework/OpenSEMICore/OpenSEMI.Core.csproj
  5. 7 3
      Venus/Venus_MainPages/Venus_MainPages.csproj
  6. 15 3
      Venus/Venus_MainPages/ViewModels/EfemViewModel.cs
  7. 12 0
      Venus/Venus_MainPages/ViewModels/GasLeakCheckViewModel.cs
  8. 16 3
      Venus/Venus_MainPages/ViewModels/IOViewModel.cs
  9. 107 12
      Venus/Venus_MainPages/ViewModels/OperationOverViewModel.cs
  10. 32 22
      Venus/Venus_MainPages/ViewModels/OverKepler2200AViewModel.cs
  11. 30 21
      Venus/Venus_MainPages/ViewModels/OverKepler2200BViewModel.cs
  12. 27 14
      Venus/Venus_MainPages/ViewModels/OverKepler2300ViewModel.cs
  13. 2 2
      Venus/Venus_MainPages/ViewModels/OverVenusDEViewModel.cs
  14. 2 2
      Venus/Venus_MainPages/ViewModels/OverVenusSEViewModel.cs
  15. 16 2
      Venus/Venus_MainPages/ViewModels/TMOperationViewModel.cs
  16. 14 3
      Venus/Venus_MainPages/ViewModels/TMViewModel.cs
  17. 1 14
      Venus/Venus_MainPages/Views/MFCVerificationView.xaml.cs
  18. 6 8
      Venus/Venus_MainPages/Views/OperationOverView.xaml
  19. 1 29
      Venus/Venus_MainPages/Views/OperationOverView.xaml.cs
  20. 11 4
      Venus/Venus_MainPages/Views/OverKepler2200AView.xaml
  21. 4 5
      Venus/Venus_MainPages/Views/OverKepler2200BView.xaml
  22. 1 1
      Venus/Venus_RT/App.config
  23. 1 1
      Venus/Venus_RT/Devices/EFEM/JetEfem.cs
  24. 1 1
      Venus/Venus_RT/Devices/TM/SIASUNRobot.cs
  25. 6 10
      Venus/Venus_Themes/UserControls/Chamber.xaml
  26. 3 17
      Venus/Venus_Themes/UserControls/Chamber.xaml.cs
  27. 354 0
      Venus/Venus_Themes/UserControls/ChamberWithHeater.xaml
  28. 129 0
      Venus/Venus_Themes/UserControls/ChamberWithHeater.xaml.cs
  29. 2 2
      Venus/Venus_Themes/UserControls/EFEMFrontView.xaml
  30. 2 14
      Venus/Venus_Themes/UserControls/FOUPFrontView.xaml
  31. 7 0
      Venus/Venus_Themes/Venus_Themes.csproj
  32. 4 3
      Venus/Venus_UI/Venus_UI.csproj
  33. 4 5
      Venus/Venus_UI/Views/ShellView.xaml
  34. 15 28
      Venus/Venus_UI/Views/ShellView.xaml.cs

+ 3 - 0
Venus/Framework/ClientBase/OpenSEMI.ClientBase.csproj

@@ -27,6 +27,9 @@
     <DebugType>pdbonly</DebugType>
     <Optimize>true</Optimize>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|AnyCPU'">
+    <NoWarn>CS0168</NoWarn>
+  </PropertyGroup>
   <ItemGroup>
     <Reference Include="Caliburn.Micro">
       <HintPath>..\Output\MECF.Framework\Caliburn.Micro.dll</HintPath>

+ 3 - 0
Venus/Framework/OpenControl/OpenSEMI.Ctrlib.csproj

@@ -27,6 +27,9 @@
     <DebugType>pdbonly</DebugType>
     <Optimize>true</Optimize>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|AnyCPU'">
+    <NoWarn>CS0168</NoWarn>
+  </PropertyGroup>
   <ItemGroup>
     <Reference Include="PresentationFramework">
       <HintPath>C:\windows\Microsoft.Net\assembly\GAC_MSIL\PresentationFramework\v4.0_4.0.0.0__31bf3856ad364e35\PresentationFramework.dll</HintPath>

Plik diff jest za duży
+ 2 - 2
Venus/Framework/OpenControl/generic.xaml


+ 3 - 0
Venus/Framework/OpenSEMICore/OpenSEMI.Core.csproj

@@ -27,6 +27,9 @@
     <DebugType>pdbonly</DebugType>
     <Optimize>true</Optimize>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|AnyCPU'">
+    <NoWarn>CS0168</NoWarn>
+  </PropertyGroup>
   <ItemGroup>
     <Reference Include="log4net">
       <HintPath>..\..\ThirdParty\log4net.dll</HintPath>

+ 7 - 3
Venus/Venus_MainPages/Venus_MainPages.csproj

@@ -55,11 +55,11 @@
     <Reference Include="log4net">
       <HintPath>..\ThirdParty\log4net.dll</HintPath>
     </Reference>
+    <Reference Include="MECF.Framework.RT.Core">
+      <HintPath>..\Framework\Output\MECF.Framework\MECF.Framework.RT.Core.dll</HintPath>
+    </Reference>
     <Reference Include="Microsoft.VisualBasic" />
     <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL" />
-    <Reference Include="OpenSEMI.Core">
-      <HintPath>..\ThirdParty\OpenSEMI.Core.dll</HintPath>
-    </Reference>
     <Reference Include="PresentationCore" />
     <Reference Include="PresentationFramework" />
     <Reference Include="Prism">
@@ -351,6 +351,10 @@
       <Project>{b55e8d4b-c4c8-4a6d-9fc4-609c52a56cac}</Project>
       <Name>OpenSEMI.Ctrlib</Name>
     </ProjectReference>
+    <ProjectReference Include="..\Framework\OpenSEMICore\OpenSEMI.Core.csproj">
+      <Project>{c4cd3d7b-cb40-47d5-ab04-df05007e5b6a}</Project>
+      <Name>OpenSEMI.Core</Name>
+    </ProjectReference>
     <ProjectReference Include="..\Framework\SequenceControl\SequenceControl.csproj">
       <Project>{a40b734c-f2ec-453c-a5fb-70cd46452bf1}</Project>
       <Name>SequenceControl</Name>

+ 15 - 3
Venus/Venus_MainPages/ViewModels/EfemViewModel.cs

@@ -85,7 +85,7 @@ namespace Venus_MainPages.ViewModels
         //int arm1oldWaferStatus = 100;
         //int arm2oldWaferStatus = 100;
         private RobotPosition m_CurrentRobotPosition;
-
+        DispatcherTimer timer;
         #endregion
 
         #region 属性
@@ -424,10 +424,10 @@ namespace Venus_MainPages.ViewModels
             
             LLAIsInstalled = allModules.Contains("LLA");
             LLBIsInstalled = allModules.Contains("LLB");
-            DispatcherTimer timer = new DispatcherTimer();
+            timer = new DispatcherTimer();
             timer.Interval = TimeSpan.FromSeconds(0.1);
             timer.Tick += Timer_Tick;
-            timer.Start();
+            //timer.Start();
             EFEMModules.Add(EFEMModule.LLA);
             EFEMModules.Add(EFEMModule.LLB);
             EFEMModules.Add(EFEMModule.LP1);
@@ -783,6 +783,18 @@ namespace Venus_MainPages.ViewModels
 
         }
 
+        public void EnterExitView(bool isEnter)
+        {
+            if (isEnter)
+            {
+                Timer_Tick(null, null);
+                timer.Start();
+            }
+            else
+            {
+                timer.Stop();
+            }
+        }
         //private void UIEvents_PMDoorRaiseChangedEvent(DoorPara obj)
         //{
         //    InvokeClient.Instance.Service.DoOperation($"{obj?.ModuleName}.SlitDoor.{obj?.IsOpen}");

+ 12 - 0
Venus/Venus_MainPages/ViewModels/GasLeakCheckViewModel.cs

@@ -1156,6 +1156,18 @@ namespace Venus_MainPages.ViewModels
 
 
         }
+        public void EnterExitView(bool isEnter)
+        {
+            if (isEnter)
+            {
+                timer_Tick(null, null);
+                timer.Start();
+            }
+            else
+            {
+                timer.Stop();
+            }
+        }
         #endregion
     }
 }

+ 16 - 3
Venus/Venus_MainPages/ViewModels/IOViewModel.cs

@@ -28,8 +28,8 @@ namespace Venus_MainPages.ViewModels
         private ObservableCollection<AOItem32> m_AOs = new ObservableCollection<AOItem32>();
         private ObservableCollection<IOItem<bool>> m_DIs = new ObservableCollection<IOItem<bool>>();
         private ObservableCollection<IOItem<bool>> m_DOs = new ObservableCollection<IOItem<bool>>();
+        DispatcherTimer timer;
 
-        
 
         #endregion
 
@@ -79,10 +79,10 @@ namespace Venus_MainPages.ViewModels
         {
 
 
-            DispatcherTimer timer = new DispatcherTimer();
+            timer = new DispatcherTimer();
             timer.Interval = TimeSpan.FromSeconds(2);
             timer.Tick += timer_Tick;
-            timer.Start();
+            //timer.Start();
 
             BuildIoSchema();
 
@@ -217,6 +217,18 @@ namespace Venus_MainPages.ViewModels
                     _aoMap[item.Key].Value = (float)aoValues[item.Key];
             }
         }
+        public void EnterExitView(bool isEnter)
+        {
+            if (isEnter)
+            {
+                timer_Tick(null, null);
+                timer.Start();
+            }
+            else
+            {
+                timer.Stop();
+            }
+        }
         #endregion
     }
     public class AOItem32 : IOItem<float>
@@ -247,5 +259,6 @@ namespace Venus_MainPages.ViewModels
                 this.SetValue(TextSavedProperty, (object)value);
             }
         }
+
     }
 }

+ 107 - 12
Venus/Venus_MainPages/ViewModels/OperationOverViewModel.cs

@@ -61,6 +61,11 @@ namespace Venus_MainPages.ViewModels
         private bool m_LLBIsInstalled;
         private bool m_TMIsInstalled;
         private bool m_EFEMIsInstalled;
+        private bool m_ButtonIsEnableLP1;
+        private bool m_ButtonIsEnableLP2;
+        private bool m_ButtonIsEnableLP3;
+
+
         private WaferInfo m_EFEMBladeAWafer;
         private WaferInfo m_EFEMBladeBWafer;
         private WaferInfo m_Aligner1Wafer;
@@ -91,7 +96,7 @@ namespace Venus_MainPages.ViewModels
 
         private string m_RouteState;
         private PressureType m_PressureType;
-
+        DispatcherTimer timer;
         #endregion
 
         #region  属性
@@ -281,6 +286,21 @@ namespace Venus_MainPages.ViewModels
             get { return m_EFEMIsInstalled; }
             set { SetProperty(ref m_EFEMIsInstalled, value); }
         }
+        public bool ButtonIsEnableLP1
+        {
+            get { return m_ButtonIsEnableLP1; }
+            set { SetProperty(ref m_ButtonIsEnableLP1, value); }
+        }
+        public bool ButtonIsEnableLP2
+        {
+            get { return m_ButtonIsEnableLP2; }
+            set { SetProperty(ref m_ButtonIsEnableLP2, value); }
+        }
+        public bool ButtonIsEnableLP3
+        {
+            get { return m_ButtonIsEnableLP3; }
+            set { SetProperty(ref m_ButtonIsEnableLP3, value); }
+        }
         public WaferInfo EFEMBladeAWafer
         {
             get { return m_EFEMBladeAWafer; }
@@ -402,9 +422,9 @@ namespace Venus_MainPages.ViewModels
         #endregion
 
         #region 命令
-        private DelegateCommand _LoadCommand;
-        public DelegateCommand LoadCommand =>
-            _LoadCommand ?? (_LoadCommand = new DelegateCommand(OnLoad));
+        private DelegateCommand<object> _LoadCommand;
+        public DelegateCommand<object> LoadCommand =>
+            _LoadCommand ?? (_LoadCommand = new DelegateCommand<object>(OnLoad));
 
         private DelegateCommand<object> _LoadWaferCommand;
         public DelegateCommand<object> LoadWaferCommand =>
@@ -472,6 +492,14 @@ namespace Venus_MainPages.ViewModels
         public DelegateCommand EnableManualCommand =>
             _EnableManualCommand ?? (_EnableManualCommand = new DelegateCommand(OnEnableManual));
 
+        private DelegateCommand _LostFocusCommand;
+        public DelegateCommand LostFocusCommand =>
+            _LostFocusCommand ?? (_LostFocusCommand = new DelegateCommand(OnLostFocus));
+
+        private DelegateCommand _GotFocusCommand;
+        public DelegateCommand GotFocusCommand =>
+            _GotFocusCommand ?? (_GotFocusCommand = new DelegateCommand(OnGotFocus));
+
 
         public bool SwitchFlag;
 
@@ -480,12 +508,11 @@ namespace Venus_MainPages.ViewModels
         #region 构造函数
         public OperationOverViewModel()
         {
-            DispatcherTimer timer = new DispatcherTimer();
-            timer.Interval = TimeSpan.FromSeconds(0.1);
+            timer = new DispatcherTimer();
+            timer.Interval = TimeSpan.FromSeconds(0.5);
             addDataKeys();
             RtDataValues = QueryDataClient.Instance.Service.PollData(m_RtDataKeys);
             timer.Tick += Timer_Tick;
-            timer.Start();
 
             string allModules = QueryDataClient.Instance.Service.GetConfig($"System.InstalledModules").ToString();
             PMAIsInstalled = allModules.Contains("PMA");
@@ -496,7 +523,7 @@ namespace Venus_MainPages.ViewModels
             LLBIsInstalled = allModules.Contains("LLB");
             EFEMIsInstalled = allModules.Contains("EFEM");
             TMIsInstalled = allModules.Contains("TM");
-            
+
 
 
 
@@ -511,10 +538,11 @@ namespace Venus_MainPages.ViewModels
         #endregion
 
         #region 命令方法
-        private void OnLoad()
+        private void OnLoad(object obj)
         {
             if (!SwitchFlag)
             {
+                var t = (obj as OperationOverView);
                 LP1WaferAssociation = new WaferAssociationInfo();
                 LP3WaferAssociation = new WaferAssociationInfo();
                 LP2WaferAssociation = new WaferAssociationInfo();
@@ -522,12 +550,25 @@ namespace Venus_MainPages.ViewModels
                 LP2WaferAssociation.ModuleData = ModuleManager.ModuleInfos["LP2"];
                 LP3WaferAssociation.ModuleData = ModuleManager.ModuleInfos["LP3"];
                 SwitchFlag = true;
-                object obj = QueryDataClient.Instance.Service.GetData("System.PressureUnitType");
-                PressureType = (PressureType)Convert.ToInt32(obj);
+
+                PressureType = (PressureType)Convert.ToInt32(QueryDataClient.Instance.Service.GetData("System.PressureUnitType"));
             }
 
         }
 
+        private void T_IsVisibleChanged(object sender, DependencyPropertyChangedEventArgs e)
+        {
+            if (timer.IsEnabled)
+            {
+                timer.Stop();
+
+            }
+            else
+            {
+                timer.Start();
+            }
+        }
+
         private void OnLoadWafer(object obj)
         {
             InvokeClient.Instance.Service.DoOperation($"{obj.ToString()}.Load", ModuleManager.ModuleInfos[obj.ToString()].ModuleID);
@@ -703,11 +744,25 @@ namespace Venus_MainPages.ViewModels
         {
             InvokeClient.Instance.Service.DoOperation("System.SetManualMode");
         }
+        private void OnLostFocus()
+        {
+            timer.Stop();
+        }
+        private void OnGotFocus()
+        {
+            timer.Start();
+        }
+
         #endregion
 
         #region 私有方法
         private void Timer_Tick(object sender, EventArgs e)
         {
+            RtDataValues = QueryDataClient.Instance.Service.PollData(m_RtDataKeys);
+            if (RtDataValues == null || RtDataValues.Count==0)
+            {
+                return;
+            }
             LP1ModuleInfo = ModuleManager.ModuleInfos["LP1"];
             LP2ModuleInfo = ModuleManager.ModuleInfos["LP2"];
             LP3ModuleInfo = ModuleManager.ModuleInfos["LP3"];
@@ -716,7 +771,7 @@ namespace Venus_MainPages.ViewModels
             BladeAWafer = ModuleManager.ModuleInfos["EfemRobot"].WaferManager.Wafers[0];
             BladeBWafer = ModuleManager.ModuleInfos["EfemRobot"].WaferManager.Wafers[1];
 
-            RtDataValues = QueryDataClient.Instance.Service.PollData(m_RtDataKeys);
+            
 
             if (LLAIsInstalled == true)
             {
@@ -765,10 +820,34 @@ namespace Venus_MainPages.ViewModels
                 EFEMBladeBWafer = ModuleManager.ModuleInfos["EfemRobot"].WaferManager.Wafers[1];
                 Aligner1Wafer = ModuleManager.ModuleInfos["Aligner1"].WaferManager.Wafers[0];
                 ControlJobInfo lp1Cj = CommonFunction.GetValue<ControlJobInfo>(RtDataValues, "LP1.CurrentControlJob");
+                if (lp1Cj == null)
+                {
+                    ButtonIsEnableLP1 = true;
+                }
+                else
+                {
+                    ButtonIsEnableLP1= false;
+                }
                 UPdateWaferAssociation(LP1WaferAssociation, lp1Cj);
                 ControlJobInfo lp2Cj = CommonFunction.GetValue<ControlJobInfo>(RtDataValues, "LP2.CurrentControlJob");
+                if (lp2Cj == null)
+                {
+                    ButtonIsEnableLP2 = true;
+                }
+                else
+                {
+                    ButtonIsEnableLP2 = false;
+                }
                 UPdateWaferAssociation(LP2WaferAssociation, lp2Cj);
                 ControlJobInfo lp3Cj = CommonFunction.GetValue<ControlJobInfo>(RtDataValues, "LP3.CurrentControlJob");
+                if (lp3Cj == null)
+                {
+                    ButtonIsEnableLP3 = true;
+                }
+                else
+                {
+                    ButtonIsEnableLP3 = false;
+                }
                 UPdateWaferAssociation(LP3WaferAssociation, lp3Cj);
             }
 
@@ -793,6 +872,10 @@ namespace Venus_MainPages.ViewModels
         /// <param name="cjInfo"></param>
         private void UPdateWaferAssociation(WaferAssociationInfo info, ControlJobInfo cjInfo)
         {
+            if(info==null)
+            {
+                return; 
+            }
             if (cjInfo != null)
             {
                 info.LotId = cjInfo.Name;
@@ -1315,6 +1398,18 @@ namespace Venus_MainPages.ViewModels
                 await Task.Delay(delay);
             }
         }
+        public void EnterExitView(bool isEnter)
+        {
+            if (isEnter)
+            {
+                 Timer_Tick(null, null);
+                timer.Start();
+            }
+            else
+            {
+                timer.Stop();
+            }
+        }
         #endregion
     }
 }

+ 32 - 22
Venus/Venus_MainPages/ViewModels/OverKepler2200AViewModel.cs

@@ -155,8 +155,8 @@ namespace Venus_MainPages.ViewModels
         private int m_TurboPumpRotationalSpeed;
 
         //private bool m_LiftPinIsUp;
-        private bool m_IsSlitDoorClosed;
-        private bool m_IsLidClosed;
+        private bool m_IsSlitDoorClosed=true;
+        private bool m_IsLidClosed=true;
 
         //private float m_MatchC1;
         //private float m_MatchC2;
@@ -192,7 +192,7 @@ namespace Venus_MainPages.ViewModels
         private float m_HighTemperatureHeaterRatioSetpoint;
         private PressureType m_PressureType;
         private bool m_IsInclude;
-
+        DispatcherTimer timer;
         #endregion
 
         #region  属性
@@ -1092,7 +1092,6 @@ namespace Venus_MainPages.ViewModels
         public DelegateCommand IncludeCommand =>
             _IncludeCommand ?? (_IncludeCommand = new DelegateCommand(OnInclude));
 
-
         #endregion
 
         #region 构造函数
@@ -1106,10 +1105,10 @@ namespace Venus_MainPages.ViewModels
 
             //CurrentModuleRecipes = GetFilesNames(Path.Combine(QueryDataClient.Instance.Service.GetData("GetRTPath").ToString(), "Recipes", ModuleName)).ToList();
 
-            DispatcherTimer timer = new DispatcherTimer();
-            timer.Interval = TimeSpan.FromSeconds(0.1);
+            timer = new DispatcherTimer();
+            timer.Interval = TimeSpan.FromMilliseconds(500);
             timer.Tick += timer_Tick;
-            timer.Start();
+            //timer.Start();
 
             //PressureType = (PressureType)Convert.ToInt32(QueryDataClient.Instance.Service.GetConfig("System.PressureUnitType"));
             //m_ChamberType=(JetChamber)Enum.Parse(typeof(JetChamber), QueryDataClient.Instance.Service.GetConfig($"{ModuleName}.ChamberType").ToString());
@@ -1500,7 +1499,7 @@ namespace Venus_MainPages.ViewModels
         {
             RtDataValues = QueryDataClient.Instance.Service.PollData(m_RtDataKeys);
 
-            if (RtDataValues == null)
+            if (RtDataValues == null || RtDataValues.Count == 0)
             {
                 return;
             }
@@ -1621,22 +1620,21 @@ namespace Venus_MainPages.ViewModels
             WaferID = IsHasWafer ? ModuleManager.ModuleInfos[ModuleName].WaferManager.Wafers[0].SourceName : "";
 
             MatchData = CommonFunction.GetValue<AITMatchData>(RtDataValues, $"{ModuleName}.{VenusDevice.Match}.DeviceData");
-            if (IsProcessing)
-            {
-                CurrentRecipeResult = CommonFunction.GetValue<RecipeResult>(RtDataValues, $"{ModuleName}.CurrentRecipeResult");
-                if (CurrentRecipeResult!=null && CurrentRecipeResult.RecipeStepNumber != null && CurrentRecipeResult.RecipeStepNumber != currentRecipeNumber)
-                {
-                    var recipePath = Path.Combine(QueryDataClient.Instance.Service.GetData("GetRTPath").ToString(), "Recipes", ModuleName, CurrentRecipeResult.RecipeType, CurrentRecipeResult.RecipeName + ".rcp");
-                    CurrentRecipe = Recipe.Load(File.ReadAllText(recipePath));
-                    CurrentRecipeStep = CurrentRecipe.Steps[Convert.ToInt32(CurrentRecipeResult.RecipeStepNumber) - 1];
-                    currentRecipeNumber = CurrentRecipeResult?.RecipeStepNumber;
-                }
-            }
-            //else
+
+            CurrentRecipeResult = CommonFunction.GetValue<RecipeResult>(RtDataValues, $"{ModuleName}.CurrentRecipeResult");
+
+
+            //if (IsProcessing)
             //{
-            //    CurrentRecipeResult = null;
-            //    CurrentRecipeStep = null;
+            //    if (CurrentRecipeResult!=null && CurrentRecipeResult.RecipeStepNumber != null && CurrentRecipeResult.RecipeStepNumber != currentRecipeNumber)
+            //    {
+            //        var recipePath = Path.Combine(QueryDataClient.Instance.Service.GetData("GetRTPath").ToString(), "Recipes", ModuleName, CurrentRecipeResult.RecipeType, CurrentRecipeResult.RecipeName + ".rcp");
+            //        CurrentRecipe = Recipe.Load(File.ReadAllText(recipePath));
+            //        CurrentRecipeStep = CurrentRecipe.Steps[Convert.ToInt32(CurrentRecipeResult.RecipeStepNumber) - 1];
+            //        currentRecipeNumber = CurrentRecipeResult?.RecipeStepNumber;
+            //    }
             //}
+           
 
             if (Math.Abs(100 - ProcessPressure) > 1 && ProcessPressure < 2000)
             {
@@ -1767,6 +1765,18 @@ namespace Venus_MainPages.ViewModels
 
 
         }
+        public void EnterExitView(bool isEnter)
+        {
+            if (isEnter)
+            {
+                timer_Tick(null, null);
+                timer.Start();
+            }
+            else
+            {
+                timer.Stop();
+            }
+        }
         #endregion
     }
 }

+ 30 - 21
Venus/Venus_MainPages/ViewModels/OverKepler2200BViewModel.cs

@@ -161,8 +161,8 @@ namespace Venus_MainPages.ViewModels
         private int m_TurboPumpRotationalSpeed;
 
         //private bool m_LiftPinIsUp;
-        private bool m_IsSlitDoorClosed;
-        private bool m_IsLidClosed;
+        private bool m_IsSlitDoorClosed=true;
+        private bool m_IsLidClosed=true;
 
         //private float m_ChillerTemperature;
         //private float m_HVTemperature;
@@ -216,7 +216,7 @@ namespace Venus_MainPages.ViewModels
         private bool m_IsInclude;
         private int m_SelectedRecipeIndex=-1;
         private ComboBoxItem m_SelectedRecipeType;
-
+        DispatcherTimer timer;
         #endregion
 
         #region  属性
@@ -1071,10 +1071,10 @@ namespace Venus_MainPages.ViewModels
 
             //CurrentModuleRecipes = GetFilesNames(Path.Combine(QueryDataClient.Instance.Service.GetData("GetRTPath").ToString(), "Recipes", ModuleName)).ToList();
 
-            DispatcherTimer timer = new DispatcherTimer();
-            timer.Interval = TimeSpan.FromSeconds(0.1);
+            timer = new DispatcherTimer();
+            timer.Interval = TimeSpan.FromSeconds(0.5);
             timer.Tick += timer_Tick;
-            timer.Start();
+            //timer.Start();
             PressureType = PressureType.Pa;
         }
         #endregion
@@ -1471,7 +1471,7 @@ namespace Venus_MainPages.ViewModels
         {
             RtDataValues = QueryDataClient.Instance.Service.PollData(m_RtDataKeys);
 
-            if (RtDataValues == null)
+            if (RtDataValues == null || RtDataValues.Count == 0)
             {
                 return;
             }
@@ -1594,22 +1594,19 @@ namespace Venus_MainPages.ViewModels
             IsHasWafer = CommonFunction.GetValue<bool>(RtDataValues, $"{ModuleName}.HasWafer");
             WaferID = IsHasWafer ? ModuleManager.ModuleInfos[ModuleName].WaferManager.Wafers[0].SourceName : "";
 
-            if (IsProcessing)
-            {
-                CurrentRecipeResult = CommonFunction.GetValue<RecipeResult>(RtDataValues, $"{ModuleName}.CurrentRecipeResult");
-                if (CurrentRecipeResult.RecipeStepNumber != null && CurrentRecipeResult.RecipeStepNumber != currentRecipeNumber)
-                {
-                    var recipePath = Path.Combine(QueryDataClient.Instance.Service.GetData("GetRTPath").ToString(), "Recipes", ModuleName, CurrentRecipeResult.RecipeType, CurrentRecipeResult.RecipeName + ".rcp");
-                    CurrentRecipe = Recipe.Load(File.ReadAllText(recipePath));
-                    CurrentRecipeStep = CurrentRecipe.Steps[Convert.ToInt32(CurrentRecipeResult.RecipeStepNumber) - 1];
-                }
-                currentRecipeNumber = CurrentRecipeResult.RecipeStepNumber;
-            }
-            //else
+            CurrentRecipeResult = CommonFunction.GetValue<RecipeResult>(RtDataValues, $"{ModuleName}.CurrentRecipeResult");
+
+            //if (IsProcessing)
             //{
-            //    CurrentRecipeResult = null;
-            //    CurrentRecipeStep = null;
+            //    if (CurrentRecipeResult.RecipeStepNumber != null && CurrentRecipeResult.RecipeStepNumber != currentRecipeNumber)
+            //    {
+            //        var recipePath = Path.Combine(QueryDataClient.Instance.Service.GetData("GetRTPath").ToString(), "Recipes", ModuleName, CurrentRecipeResult.RecipeType, CurrentRecipeResult.RecipeName + ".rcp");
+            //        CurrentRecipe = Recipe.Load(File.ReadAllText(recipePath));
+            //        CurrentRecipeStep = CurrentRecipe.Steps[Convert.ToInt32(CurrentRecipeResult.RecipeStepNumber) - 1];
+            //    }
+            //    currentRecipeNumber = CurrentRecipeResult.RecipeStepNumber;
             //}
+         
 
             if (Math.Abs(100 - ProcessPressure) > 1 && ProcessPressure < 2000)
             {
@@ -1744,6 +1741,18 @@ namespace Venus_MainPages.ViewModels
             m_RtDataKeys.Add($"{ModuleName}.IsInclude");
 
         }
+        public void EnterExitView(bool isEnter)
+        {
+            if (isEnter)
+            {
+                timer_Tick(null, null);
+                timer.Start();
+            }
+            else
+            {
+                timer.Stop();
+            }
+        }
         #endregion
     }
 }

+ 27 - 14
Venus/Venus_MainPages/ViewModels/OverKepler2300ViewModel.cs

@@ -168,8 +168,8 @@ namespace Venus_MainPages.ViewModels
         private int m_TurboPumpRotationalSpeed;
 
         private bool m_LiftPinIsUp;
-        private bool m_IsSlitDoorClosed;
-        private bool m_IsLidClosed;
+        private bool m_IsSlitDoorClosed=true;
+        private bool m_IsLidClosed=true;
 
         private float m_ChillerTemperature;
 
@@ -208,6 +208,7 @@ namespace Venus_MainPages.ViewModels
         private bool m_IsInclude;
         private int m_SelectedRecipeIndex=-1;
         private ComboBoxItem m_SelectedRecipeType;
+        DispatcherTimer timer;
         #endregion
 
         #region  属性
@@ -1138,7 +1139,7 @@ namespace Venus_MainPages.ViewModels
 
             //CurrentModuleRecipes = GetFilesNames(Path.Combine(QueryDataClient.Instance.Service.GetData("GetRTPath").ToString(), "Recipes", ModuleName)).ToList();
 
-            DispatcherTimer timer = new DispatcherTimer();
+            timer = new DispatcherTimer();
             timer.Interval = TimeSpan.FromSeconds(0.5);
             timer.Tick += timer_Tick;
             timer.Start();
@@ -1715,19 +1716,19 @@ namespace Venus_MainPages.ViewModels
             IsTurboPumpAtSpeed = CommonFunction.GetValue<bool>(RtDataValues, $"{ModuleName}.IsTurboPumpAtSpeed");
             IsHasWafer = CommonFunction.GetValue<bool>(RtDataValues, $"{ModuleName}.HasWafer");
 
+            CurrentRecipeResult = CommonFunction.GetValue<RecipeResult>(RtDataValues, $"{ModuleName}.CurrentRecipeResult");
 
-            if (PMCurrentState == PMState.Processing || PMCurrentState == PMState.Clean)
-            {
-                CurrentRecipeResult = CommonFunction.GetValue<RecipeResult>(RtDataValues, $"{ModuleName}.CurrentRecipeResult");
-                if (CurrentRecipeResult.RecipeStepNumber != null && CurrentRecipeResult.RecipeStepNumber != currentRecipeNumber)
-                {
-                    var recipePath = Path.Combine(QueryDataClient.Instance.Service.GetData("GetRTPath").ToString(), "Recipes", ModuleName,CurrentRecipeResult.RecipeType, CurrentRecipeResult.RecipeName + ".rcp");
-                    CurrentRecipe = Recipe.Load(File.ReadAllText(recipePath));
-                    CurrentRecipeStep = CurrentRecipe.Steps[Convert.ToInt32(CurrentRecipeResult.RecipeStepNumber) - 1];
-                }
-                currentRecipeNumber = CurrentRecipeResult.RecipeStepNumber;
+            //if (PMCurrentState == PMState.Processing || PMCurrentState == PMState.Clean)
+            //{
+            //    //if (CurrentRecipeResult.RecipeStepNumber != null && CurrentRecipeResult.RecipeStepNumber != currentRecipeNumber)
+            //    //{
+            //    //    var recipePath = Path.Combine(QueryDataClient.Instance.Service.GetData("GetRTPath").ToString(), "Recipes", ModuleName,CurrentRecipeResult.RecipeType, CurrentRecipeResult.RecipeName + ".rcp");
+            //    //    CurrentRecipe = Recipe.Load(File.ReadAllText(recipePath));
+            //    //    CurrentRecipeStep = CurrentRecipe.Steps[Convert.ToInt32(CurrentRecipeResult.RecipeStepNumber) - 1];
+            //    //}
+            //    //currentRecipeNumber = CurrentRecipeResult.RecipeStepNumber;
 
-            }
+            //}
             //else
             //{
             //    CurrentRecipeResult = null;
@@ -1872,6 +1873,18 @@ namespace Venus_MainPages.ViewModels
 
 
         }
+        public void EnterExitView(bool isEnter)
+        {
+            if (isEnter)
+            {
+                timer_Tick(null, null);
+                timer.Start();
+            }
+            else
+            {
+                timer.Stop();
+            }
+        }
         #endregion
     }
 }

+ 2 - 2
Venus/Venus_MainPages/ViewModels/OverVenusDEViewModel.cs

@@ -196,9 +196,9 @@ namespace Venus_MainPages.ViewModels
         private int m_TurboPumpRotationalSpeed;
 
         private bool m_LiftPinIsUp;
-        private bool m_IsSlitDoorClosed;
+        private bool m_IsSlitDoorClosed=true;
         private bool m_IsLinerDoorClosed;
-        private bool m_IsLidClosed;
+        private bool m_IsLidClosed=true;
 
         private float m_ChillerTemperature;
         private float m_HVTemperature;

+ 2 - 2
Venus/Venus_MainPages/ViewModels/OverVenusSEViewModel.cs

@@ -201,8 +201,8 @@ namespace Venus_MainPages.ViewModels
         private int m_TurboPumpRotationalSpeed;
 
         private bool m_LiftPinIsUp;
-        private bool m_IsSlitDoorClosed;
-        private bool m_IsLidClosed;
+        private bool m_IsSlitDoorClosed=true;
+        private bool m_IsLidClosed=true;
 
         private float m_ChillerTemperature;
         private float m_HVTemperature;

+ 16 - 2
Venus/Venus_MainPages/ViewModels/TMOperationViewModel.cs

@@ -68,6 +68,7 @@ namespace Venus_MainPages.ViewModels
         private ObservableCollection<PMLeakCheckResult> m_LeakCheckResultList = new ObservableCollection<PMLeakCheckResult>();
 
         private bool m_firstLoad = true;
+        DispatcherTimer timer;
         #endregion
 
         #region 属性
@@ -393,10 +394,10 @@ namespace Venus_MainPages.ViewModels
             LLAIsInstalled = allModules.Contains("LLA");
             LLBIsInstalled = allModules.Contains("LLB");
 
-            DispatcherTimer timer = new DispatcherTimer();
+            timer = new DispatcherTimer();
             timer.Interval = TimeSpan.FromSeconds(0.5);
             timer.Tick += timer_Tick;
-            timer.Start();
+            //timer.Start();
 
             HomeAllSteps.Add("Lid");
             HomeAllSteps.Add("Robot");
@@ -620,6 +621,19 @@ namespace Venus_MainPages.ViewModels
 
 
         }
+
+        public void EnterExitView(bool isEnter)
+        {
+            if (isEnter)
+            {
+                timer_Tick(null, null);
+                timer.Start();
+            }
+            else
+            {
+                timer.Stop();
+            }
+        }
         #endregion
     }
 }

+ 14 - 3
Venus/Venus_MainPages/ViewModels/TMViewModel.cs

@@ -114,7 +114,7 @@ namespace Venus_MainPages.ViewModels
         private int m_CycleCount;
         private PressureType m_PressureType;
         private bool m_firstFlag = true;
-
+        DispatcherTimer timer;
 
         #endregion
 
@@ -924,7 +924,7 @@ namespace Venus_MainPages.ViewModels
             }
             addDataKeys();
             RtDataValues = QueryDataClient.Instance.Service.PollData(m_RtDataKeys);
-            DispatcherTimer timer = new DispatcherTimer();
+            timer = new DispatcherTimer();
             timer.Interval = TimeSpan.FromSeconds(0.1);
             timer.Tick += Timer_Tick;
             timer.Start();
@@ -1305,7 +1305,18 @@ namespace Venus_MainPages.ViewModels
             m_RtDataKeys.Add("TM.PMDSlitDoor.IsClosed");
 
         }
-
+        public void EnterExitView(bool isEnter)
+        {
+            if (isEnter)
+            {
+                Timer_Tick(null, null);
+                timer.Start();
+            }
+            else
+            {
+                timer.Stop();
+            }
+        }
 
         #endregion
     }

+ 1 - 14
Venus/Venus_MainPages/Views/MFCVerificationView.xaml.cs

@@ -28,20 +28,7 @@ namespace Venus_MainPages.Views
         public void Init(string systemName)
         {
             (this.DataContext as MFCVerificationViewModel).ModuleName = systemName;
-            (this.DataContext as MFCVerificationViewModel).Init();
-            
+            (this.DataContext as MFCVerificationViewModel).Init();          
         }
-
-        //private void MFCVerificationView1_Loaded(object sender, RoutedEventArgs e)
-        //{
-        //    if ((this.DataContext as MFCVerificationViewModel).MFC7IsEnable == false)
-        //    {
-        //        DataGridTemplateColumn7.Visibility = Visibility.Collapsed;
-        //    }
-        //    if ((this.DataContext as MFCVerificationViewModel).MFC8IsEnable == false)
-        //    {
-        //        DataGridTemplateColumn8.Visibility = Visibility.Collapsed;
-        //    }
-        //}
     }
 }

+ 6 - 8
Venus/Venus_MainPages/Views/OperationOverView.xaml

@@ -13,14 +13,12 @@
              xmlns:userControls="clr-namespace:Venus_Themes.UserControls;assembly=Venus_Themes"
              xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
              xmlns:prism="http://prismlibrary.com/"
-             prism:ViewModelLocator.AutoWireViewModel="True"
-             xmlns:deviceControl="clr-namespace:Aitex.Core.UI.DeviceControl;assembly=MECF.Framework.UI.Core"
-            
+             prism:ViewModelLocator.AutoWireViewModel="True"       
              xmlns:unity="clr-namespace:Venus_MainPages.Unity"
-             d:DesignHeight="450" d:DesignWidth="800">
+             d:DesignHeight="1000" d:DesignWidth="1920" x:Name="operationOverView">
     <i:Interaction.Triggers>
         <i:EventTrigger EventName="Loaded">
-            <i:InvokeCommandAction Command="{Binding LoadCommand}"/>
+            <i:InvokeCommandAction Command="{Binding LoadCommand}" CommandParameter="{Binding ElementName=operationOverView}"/>
         </i:EventTrigger>
     </i:Interaction.Triggers>
 
@@ -407,13 +405,13 @@
                     </StackPanel>
                 </TabPanel>
                 <TabPanel Canvas.Left="900"  Canvas.Top="140" Visibility="{Binding ElementName=JobRadioButton1,Path=IsChecked,Converter={StaticResource boolToVisibility2}}" >
-                    <local:WaferAssociationUnit                  WAInfo="{Binding LP1WaferAssociation}" ButtonIsEnable="{Binding RtDataValues[System.IsAutoMode],Converter={StaticResource BoolToBool}}"/>
+                    <local:WaferAssociationUnit                  WAInfo="{Binding LP1WaferAssociation}" ButtonIsEnable="{Binding ButtonIsEnableLP1}"/>
                 </TabPanel>
                 <TabPanel Canvas.Left="900"  Canvas.Top="140" Visibility="{Binding ElementName=JobRadioButton2,Path=IsChecked,Converter={StaticResource boolToVisibility2}}" >
-                    <local:WaferAssociationUnit   WAInfo="{Binding LP2WaferAssociation}" ButtonIsEnable="{Binding RtDataValues[System.IsAutoMode],Converter={StaticResource BoolToBool}}"/>
+                    <local:WaferAssociationUnit   WAInfo="{Binding LP2WaferAssociation}" ButtonIsEnable="{Binding ButtonIsEnableLP2}"/>
                 </TabPanel>
                 <TabPanel Canvas.Left="900"  Canvas.Top="140" Visibility="{Binding ElementName=JobRadioButton3,Path=IsChecked,Converter={StaticResource boolToVisibility2}}" >
-                    <local:WaferAssociationUnit                    WAInfo="{Binding LP3WaferAssociation}" ButtonIsEnable="{Binding RtDataValues[System.IsAutoMode],Converter={StaticResource BoolToBool}}"/>
+                    <local:WaferAssociationUnit                    WAInfo="{Binding LP3WaferAssociation}" ButtonIsEnable="{Binding ButtonIsEnableLP3}"/>
                 </TabPanel>
 
 

+ 1 - 29
Venus/Venus_MainPages/Views/OperationOverView.xaml.cs

@@ -1,18 +1,4 @@
-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_MainPages.Unity;
+using System.Windows.Controls;
 
 namespace Venus_MainPages.Views
 {
@@ -25,19 +11,5 @@ namespace Venus_MainPages.Views
         {
             InitializeComponent();
         }
-
-
-
-        //public WaferAssociationInfo WAInfo
-        //{
-        //    get { return (WaferAssociationInfo)GetValue(WAInfoProperty); }
-        //    set { SetValue(WAInfoProperty, value); }
-        //}
-        //public static readonly DependencyProperty WAInfoProperty = DependencyProperty.Register("WAInfo", typeof(WaferAssociationInfo), typeof(OperationOverView), new UIPropertyMetadata(null));
-
-        //private void test1_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
-        //{
-        //    var test = test1;
-        //}
     }
 }

+ 11 - 4
Venus/Venus_MainPages/Views/OverKepler2200AView.xaml

@@ -17,6 +17,14 @@
              xmlns:converters2="clr-namespace:Venus_MainPages.Converters"
              d:DesignHeight="1080" Width="1920"
              >
+    <i:Interaction.Triggers>
+        <i:EventTrigger EventName="LostFocus">
+            <i:InvokeCommandAction Command="{Binding LostFocusCommand}" />
+        </i:EventTrigger>
+        <i:EventTrigger EventName="GotFocus">
+            <i:InvokeCommandAction Command="{Binding GotFocusCommand}" />
+        </i:EventTrigger>
+    </i:Interaction.Triggers>
     <UserControl.Resources>
 
         <LinearGradientBrush x:Key="buttonBrush" StartPoint="0.5,0" EndPoint="0.5,1">
@@ -803,16 +811,15 @@
                 </StackPanel>
 
                 <!--Chamber-->
-                <ctrls:Chamber Canvas.Left="1000" Canvas.Top="224" 
-                       IsLiftPinUp="{Binding LiftPinIsUp}" 
+                <ctrls:ChamberWithHeater Canvas.Left="1000" Canvas.Top="224" 
+                       
                        IsOpenSlitDoor="{Binding IsSlitDoorClosed,Converter={StaticResource BoolToBool}}" 
                        IsLidOpen="{Binding IsLidClosed,Converter={StaticResource BoolToBool}}"  
-                       IsBRFOn="{Binding BRFData.IsRfOn}"
                        IsSRFOn="{Binding SRFData.IsRfOn}"
                        IsHasWafer="{Binding IsHasWafer}"
                        WaferID="{Binding WaferID}"
                        ModuleName="{Binding ModuleName}"
-                       IsHasHeater="True"
+                       HeaterPosition="{Binding HighTemperatureHeaterData.HighTemperatureHeaterPositionFeedBack}"
                        IsEnabled="{Binding IsAutoMode,Converter={StaticResource BoolToBool}}"
                         />
 

+ 4 - 5
Venus/Venus_MainPages/Views/OverKepler2200BView.xaml

@@ -794,16 +794,15 @@
                 </StackPanel>
 
                 <!--Chamber-->
-                <ctrls:Chamber Canvas.Left="1000" Canvas.Top="224" 
-                       IsLiftPinUp="{Binding LiftPinIsUp}" 
+                <ctrls:ChamberWithHeater Canvas.Left="1000" Canvas.Top="224" 
+                        
                        IsOpenSlitDoor="{Binding IsSlitDoorClosed,Converter={StaticResource BoolToBool}}" 
                        IsLidOpen="{Binding IsLidClosed,Converter={StaticResource BoolToBool}}"  
-                       IsBRFOn="{Binding BRFData.IsRfOn}"
                        IsSRFOn="{Binding SRFData.IsRfOn}"
                        IsHasWafer="{Binding IsHasWafer}"
                        WaferID="{Binding WaferID}"
-                       ModuleName="{Binding ModuleName}"
-                       IsHasHeater="True"
+                       ModuleName="{Binding ModuleName}"  
+                       HeaterPosition="{Binding HighTemperatureHeaterData.HighTemperatureHeaterPositionFeedBack}"
                        IsEnabled="{Binding IsAutoMode,Converter={StaticResource BoolToBool}}"
                         />
 

+ 1 - 1
Venus/Venus_RT/App.config

@@ -32,7 +32,7 @@
 	<connectionStrings>
 		<add name="PostgreSQL"   connectionString="Server=localhost;Port=5432;User Id=postgres;Password=123456;Database=postgres;Enlist=true;Preload Reader=true;" />
 		<!--0是other,1是kepler2300,2是Kepler2200,3是VenusSE,4是VenusDE-->
-		<add name="ConfigType"   connectionString="3"/>
+		<add name="ConfigType"   connectionString="2"/>
 	</connectionStrings>
 	<system.serviceModel>
 		<!--<diagnostics>

+ 1 - 1
Venus/Venus_RT/Devices/EFEM/JetEfem.cs

@@ -105,7 +105,7 @@ namespace Venus_RT.Devices.EFEM
                     _robotMoveInfo.Action = data.Action;
                     _robotMoveInfo.ArmTarget = data.Hand == Hand.Blade1 ? RobotArm.ArmA : (data.Hand == Hand.Both ? RobotArm.Both : RobotArm.ArmB);
                     _robotMoveInfo.BladeTarget = $"{_robotMoveInfo.ArmTarget}.{data.Target}";
-                    System.Threading.Thread.Sleep(300);
+                    System.Threading.Thread.Sleep(600);
                 }
             });
 

+ 1 - 1
Venus/Venus_RT/Devices/TM/SIASUNRobot.cs

@@ -97,7 +97,7 @@ namespace Venus_RT.Devices
                     _robotMoveInfo.Action = data.Action;
                     _robotMoveInfo.ArmTarget = data.Hand == Hand.Blade1 ? RobotArm.ArmA : (data.Hand == Hand.Both ? RobotArm.Both : RobotArm.ArmB);
                     _robotMoveInfo.BladeTarget = $"{_robotMoveInfo.ArmTarget}.{data.Target}";
-                    Thread.Sleep(300);
+                    Thread.Sleep(600);
                 }
             });
         }

+ 6 - 10
Venus/Venus_Themes/UserControls/Chamber.xaml

@@ -8,17 +8,13 @@
              d:DesignHeight="300" d:DesignWidth="300" x:Name="chamber">
     <UserControl.Resources>
         <Storyboard x:Key="SlitValve_Open">
-            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Height)" >
-                <EasingDoubleKeyFrame KeyTime="0" Value="75"/>
-                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="42"/>
-            </DoubleAnimationUsingKeyFrames>
+            <DoubleAnimation Storyboard.TargetProperty="(FrameworkElement.Height)" Duration="0:0:1" To="42"/>
         </Storyboard>
+        
         <Storyboard x:Key="SlitValve_Close">
-            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Height)" >
-                <EasingDoubleKeyFrame KeyTime="0" Value="42"/>
-                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="75"/>
-            </DoubleAnimationUsingKeyFrames>
+            <DoubleAnimation Storyboard.TargetProperty="(FrameworkElement.Height)" Duration="0:0:1" To="75"/>
         </Storyboard>
+        
         <Style TargetType="{x:Type Rectangle}" x:Key="SlitValve_Animation" >
             <Style.Triggers>
                 <DataTrigger Binding="{Binding ElementName=chamber,Path=IsOpenSlitDoor}" Value="true">
@@ -349,7 +345,7 @@
                 <Canvas Visibility="{Binding ElementName=chamber,Path=IsHasHeater,Converter={StaticResource bool2VisibilityConverter}}" Margin="29.5,100,0,0">
                     <Rectangle HorizontalAlignment="Left" Fill="{StaticResource heatercolor}" Stroke="Black" Width="100" Height="10"/>
                     <Rectangle HorizontalAlignment="Left" Fill="{StaticResource heatercolor}" Stroke="Black" Width="100" Height="10"  Canvas.Top="10"/>
-                    <Rectangle HorizontalAlignment="Left" Fill="{StaticResource heatercolor}" Stroke="Black" Width="30"  Height="30"  Canvas.Top="20" Canvas.Left="36"/>
+                    <Rectangle HorizontalAlignment="Left" Fill="{StaticResource heatercolor}" Stroke="Black" Width="30"  Height="60"  Canvas.Top="20" Canvas.Left="36"/>
                 </Canvas>
 
                 <!--左边slit door-->
@@ -366,7 +362,7 @@
                             <MenuItem Header="Close Door"  Click="CloseDoor_Click"  IsChecked="{Binding IsSlitDoorClosed}"  IsEnabled="{Binding IsSlitDoorClosed,Converter={StaticResource BoolToBool}}"/>
                         </ContextMenu>
                     </Grid.ContextMenu>
-                    <Rectangle  Fill="{StaticResource doorColor}" Style="{StaticResource SlitValve_Animation}" Width="8" VerticalAlignment="Top" Height="75" />
+                    <Rectangle  Fill="{StaticResource doorColor}" Style="{StaticResource SlitValve_Animation}" Width="8" VerticalAlignment="Top"    Height="75" />
                     <Rectangle  Fill="{StaticResource doorColor}" Style="{StaticResource SlitValve_Animation}" Width="8" VerticalAlignment="Bottom" Height="75" />
                 </Grid>
             </Grid>

+ 3 - 17
Venus/Venus_Themes/UserControls/Chamber.xaml.cs

@@ -1,17 +1,5 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
+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_Themes.Unity;
 
 namespace Venus_Themes.UserControls
@@ -26,8 +14,7 @@ namespace Venus_Themes.UserControls
             InitializeComponent();
         }
         public static readonly DependencyProperty IsOpenSlitDoorProperty = DependencyProperty.Register(
-           "IsOpenSlitDoor", typeof(bool), typeof(Chamber),
-           new FrameworkPropertyMetadata(false, FrameworkPropertyMetadataOptions.AffectsRender));
+           "IsOpenSlitDoor", typeof(bool), typeof(Chamber));
 
 
         public bool IsOpenSlitDoor
@@ -57,8 +44,7 @@ namespace Venus_Themes.UserControls
 
 
         public static readonly DependencyProperty IsLidOpenProperty = DependencyProperty.Register(
-         "IsLidOpen", typeof(bool), typeof(Chamber),
-         new FrameworkPropertyMetadata(false, FrameworkPropertyMetadataOptions.AffectsRender));
+         "IsLidOpen", typeof(bool), typeof(Chamber));
         public bool IsLidOpen
         {
             get { return (bool)this.GetValue(IsLidOpenProperty); }

+ 354 - 0
Venus/Venus_Themes/UserControls/ChamberWithHeater.xaml

@@ -0,0 +1,354 @@
+<UserControl x:Class="Venus_Themes.UserControls.ChamberWithHeater"
+             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" 
+             mc:Ignorable="d" 
+             d:DesignHeight="300" d:DesignWidth="300" x:Name="chamber">
+    <VisualStateManager.VisualStateGroups>
+        <VisualStateGroup Name="HeaterActions">
+            <VisualStateGroup.Transitions>
+                <VisualTransition To="Position1">
+                    <Storyboard FillBehavior="HoldEnd">
+                        <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                            <LinearDoubleKeyFrame Value="10" KeyTime="0:0:0.5"/>
+                        </DoubleAnimationUsingKeyFrames>
+                    </Storyboard>
+                </VisualTransition>
+                <VisualTransition To="Origin">
+                    <Storyboard FillBehavior="HoldEnd">
+                        <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                            <LinearDoubleKeyFrame Value="0" KeyTime="0:0:0.5"/>
+                        </DoubleAnimationUsingKeyFrames>
+                    </Storyboard>
+                </VisualTransition>
+                <VisualTransition To="Position2">
+                    <Storyboard FillBehavior="HoldEnd">
+                        <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                            <LinearDoubleKeyFrame Value="-10" KeyTime="0:0:0.5"/>
+                        </DoubleAnimationUsingKeyFrames>
+                    </Storyboard>
+                </VisualTransition>
+                <VisualTransition To="Position3">
+                    <Storyboard FillBehavior="HoldEnd">
+                        <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                            <LinearDoubleKeyFrame Value="-20" KeyTime="0:0:0.5"/>
+                        </DoubleAnimationUsingKeyFrames>
+                    </Storyboard>
+                </VisualTransition>
+                <VisualTransition To="Position4">
+                    <Storyboard FillBehavior="HoldEnd">
+                        <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                            <LinearDoubleKeyFrame Value="-30" KeyTime="0:0:0.5"/>
+                        </DoubleAnimationUsingKeyFrames>
+                    </Storyboard>
+                </VisualTransition>
+                <VisualTransition To="Position5">
+                    <Storyboard FillBehavior="HoldEnd">
+                        <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                            <LinearDoubleKeyFrame Value="-40" KeyTime="0:0:0.5"/>
+                        </DoubleAnimationUsingKeyFrames>
+                    </Storyboard>
+                </VisualTransition>
+
+            </VisualStateGroup.Transitions>
+            <VisualState Name="Position1">
+                <Storyboard FillBehavior="HoldEnd">
+                    <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                        <LinearDoubleKeyFrame Value="10" KeyTime="0:0:0"/>
+                    </DoubleAnimationUsingKeyFrames>
+                </Storyboard>
+            </VisualState>
+            <VisualState Name="Origin">
+                <Storyboard FillBehavior="HoldEnd">
+                    <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                        <LinearDoubleKeyFrame Value="0" KeyTime="0:0:0"/>
+                    </DoubleAnimationUsingKeyFrames>
+                </Storyboard>
+            </VisualState>
+            <VisualState Name="Position2">
+                <Storyboard FillBehavior="HoldEnd">
+                    <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                        <LinearDoubleKeyFrame Value="-10" KeyTime="0:0:0"/>
+                    </DoubleAnimationUsingKeyFrames>
+                </Storyboard>
+            </VisualState>
+            <VisualState Name="Position3">
+                <Storyboard FillBehavior="HoldEnd">
+                    <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                        <LinearDoubleKeyFrame Value="-20" KeyTime="0:0:0"/>
+                    </DoubleAnimationUsingKeyFrames>
+                </Storyboard>
+            </VisualState>
+            <VisualState Name="Position4">
+                <Storyboard FillBehavior="HoldEnd">
+                    <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                        <LinearDoubleKeyFrame Value="-30" KeyTime="0:0:0"/>
+                    </DoubleAnimationUsingKeyFrames>
+                </Storyboard>
+            </VisualState>
+            <VisualState Name="Position5">
+                <Storyboard FillBehavior="HoldEnd">
+                    <DoubleAnimationUsingKeyFrames Storyboard.TargetName="heaterRotateAct" Storyboard.TargetProperty="Y">
+                        <LinearDoubleKeyFrame Value="-40" KeyTime="0:0:0"/>
+                    </DoubleAnimationUsingKeyFrames>
+                </Storyboard>
+            </VisualState>
+
+
+        </VisualStateGroup>
+
+
+    </VisualStateManager.VisualStateGroups>
+    
+    
+    <UserControl.Resources>
+        <Storyboard x:Key="SlitValve_Open">
+            <DoubleAnimation Storyboard.TargetProperty="(FrameworkElement.Height)" Duration="0:0:1" To="42"/>
+        </Storyboard>
+        
+        <Storyboard x:Key="SlitValve_Close">
+            <DoubleAnimation Storyboard.TargetProperty="(FrameworkElement.Height)" Duration="0:0:1" To="75"/>
+        </Storyboard>
+        
+        <Style TargetType="{x:Type Rectangle}" x:Key="SlitValve_Animation" >
+            <Style.Triggers>
+                <DataTrigger Binding="{Binding ElementName=chamber,Path=IsOpenSlitDoor}" Value="true">
+                    <DataTrigger.EnterActions>
+                        <BeginStoryboard Storyboard="{StaticResource SlitValve_Open}"/>
+                    </DataTrigger.EnterActions>
+                    <DataTrigger.ExitActions>
+                        <BeginStoryboard Storyboard="{StaticResource SlitValve_Close}"/>
+                    </DataTrigger.ExitActions>
+                </DataTrigger>
+            </Style.Triggers>
+        </Style>
+        <LinearGradientBrush StartPoint="0,0" EndPoint="1,1" x:Key="rfcolor">
+            <LinearGradientBrush.GradientStops>
+                <GradientStop Color="#FFCC00" Offset="0" />
+                <GradientStop Color="#FF6600" Offset="0.5" />
+                <GradientStop Color="#CC3300" Offset="0.75" />
+                <GradientStop Color="#FF0000" Offset="1" />
+            </LinearGradientBrush.GradientStops>
+        </LinearGradientBrush>
+
+        <LinearGradientBrush StartPoint="0,0" EndPoint="0,1" x:Key="chambercolor">
+            <LinearGradientBrush.GradientStops>
+                <GradientStop Color="#D3D3D3" Offset="0" />
+                <GradientStop Color="White" Offset="0.5" />
+                <GradientStop Color="#D3D3D3" Offset="1" />
+            </LinearGradientBrush.GradientStops>
+        </LinearGradientBrush>
+
+        <LinearGradientBrush StartPoint="0,0" EndPoint="0,1" x:Key="threadrcolor">
+            <LinearGradientBrush.GradientStops>
+                <GradientStop Color="#FFECB7" Offset="0" />
+                <GradientStop Color="#B98903" Offset="0.3" />
+                <GradientStop Color="#EBBF43" Offset=".6" />
+                <GradientStop Color="#BB8900" Offset="1" />
+
+            </LinearGradientBrush.GradientStops>
+        </LinearGradientBrush>
+
+
+        <LinearGradientBrush StartPoint="0,0" EndPoint="1,1" x:Key="heatercolor">
+            <LinearGradientBrush.GradientStops>
+                <GradientStop Color="#C88D02" Offset="0" />
+                <GradientStop Color="#EBBF43" Offset=".5" />
+                <GradientStop Color="#BB8900" Offset="1" />
+            </LinearGradientBrush.GradientStops>
+        </LinearGradientBrush>
+    </UserControl.Resources>
+    <Canvas >
+
+        <Grid Width="240" Height="190" Canvas.Top="80">
+            <Grid.RowDefinitions>
+                <RowDefinition Height="160"/>
+                <RowDefinition />
+            </Grid.RowDefinitions>
+            <Path Data="M0.5,0.5 L33.5,0.5 33.5,17.5 206.5,17.5 206.5,0.5 239.5,0.5 239.5,149.5 0.5,149.5 z" Stroke="#FF747474" Margin="0,10,0,0">
+                <Path.Fill>
+                    <LinearGradientBrush EndPoint="1,1" StartPoint="0,0">
+                        <GradientStop Color="#FF8F8F8F" Offset="0"/>
+                        <GradientStop Color="#FF9B9B9B" Offset="1"/>
+                        <GradientStop Color="#FEF1ECEC" Offset="0.15"/>
+                        <GradientStop Color="#FEC0C0C0" Offset="0.38"/>
+                        <GradientStop Color="#FEB4B4B4" Offset="0.5"/>
+                        <GradientStop Color="#FEE5E5E5" Offset="0.7"/>
+                        <GradientStop Color="#FFBABABA" Offset="0.85"/>
+                        <GradientStop Color="#FFE5E5E5" Offset="0.9"/>
+                    </LinearGradientBrush>
+                </Path.Fill>
+            </Path>
+            <Rectangle Stroke="#FF747474" Margin="8,18">
+                <Rectangle.Fill>
+                    <LinearGradientBrush EndPoint="0.243,1" StartPoint="0.757,0">
+                        <GradientStop Color="#FFE0DEDE" Offset="0"/>
+                        <GradientStop Color="#FFE2E2E2" Offset="1"/>
+                        <GradientStop Color="#FEFFFFFF" Offset="0.55"/>
+                        <GradientStop Color="#FFEFEFEF" Offset="0.75"/>
+                    </LinearGradientBrush>
+                </Rectangle.Fill>
+            </Rectangle>
+            <Rectangle x:Name="BG_Status" Margin="9,19" Visibility="{Binding BiasRfPowerOnChamberVisibility}" Cursor="Hand">
+                <Rectangle.ContextMenu >
+                    <ContextMenu>
+                        <MenuItem Header="Create Wafer"  Click="CreateWafer_Click"     IsChecked="{Binding IsHasWafer}" IsEnabled="{Binding IsHasWafer,Converter={StaticResource BoolToBool}}"/>
+                        <MenuItem Header="Delete Wafer"  Click="DeleteWafer_Click"     IsChecked="{Binding IsHasWafer,Converter={StaticResource BoolToBool}}" IsEnabled="{Binding IsHasWafer}"/>
+                    </ContextMenu>
+                </Rectangle.ContextMenu>
+                <Rectangle.Style>
+                    <Style>
+                        <Setter Property="Rectangle.Fill" Value="{StaticResource chambercolor}"/>
+                        <Style.Triggers>
+                            <DataTrigger Binding="{Binding ElementName=chamber,Path=IsBRFOn}"  Value="True">
+                                <Setter Property="Rectangle.Fill" Value="{StaticResource rfcolor}"></Setter>
+                            </DataTrigger>
+                        </Style.Triggers>
+                    </Style>
+                </Rectangle.Style>
+            </Rectangle>
+            <Rectangle Stroke="#FF747474" Height="11" VerticalAlignment="Bottom" Margin="12,0,12,8">
+                <Rectangle.Fill>
+                    <LinearGradientBrush EndPoint="0.243,1" StartPoint="0.757,0">
+                        <GradientStop Color="#FFE0DEDE" Offset="0"/>
+                        <GradientStop Color="#FFE2E2E2" Offset="1"/>
+                        <GradientStop Color="#FEFFFFFF" Offset="0.55"/>
+                        <GradientStop Color="#FFEFEFEF" Offset="0.75"/>
+                    </LinearGradientBrush>
+                </Rectangle.Fill>
+            </Rectangle>
+            <Grid x:Name="Cover" Width="180" Height="18" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="30,2,0,0" RenderTransformOrigin="1,0.4444">
+                <Grid.RenderTransform>
+                    <TransformGroup>
+                        <ScaleTransform/>
+                        <SkewTransform/>
+                        <RotateTransform/>
+                        <TranslateTransform/>
+                    </TransformGroup>
+                </Grid.RenderTransform>
+                <Grid.Resources>
+                    <Storyboard x:Key="CoverOpen">
+                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)">
+                            <EasingDoubleKeyFrame KeyTime="0" Value="0"/>
+                            <EasingDoubleKeyFrame KeyTime="0:0:0.5" Value="20"/>
+                        </DoubleAnimationUsingKeyFrames>
+                    </Storyboard>
+                    <Storyboard x:Key="CoverClose">
+                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)">
+                            <EasingDoubleKeyFrame KeyTime="0" Value="20"/>
+                            <EasingDoubleKeyFrame KeyTime="0:0:0.5" Value="0"/>
+                        </DoubleAnimationUsingKeyFrames>
+                    </Storyboard>
+                </Grid.Resources>
+                <Grid.Style>
+                    <Style>
+                        <Style.Triggers>
+                            <DataTrigger Binding="{Binding ElementName=chamber,Path=IsLidOpen}" Value="true">
+                                <DataTrigger.EnterActions>
+                                    <BeginStoryboard Storyboard="{StaticResource CoverOpen}"/>
+                                </DataTrigger.EnterActions>
+                                <DataTrigger.ExitActions>
+                                    <BeginStoryboard Storyboard="{StaticResource CoverClose}"/>
+                                </DataTrigger.ExitActions>
+                            </DataTrigger>
+                        </Style.Triggers>
+                    </Style>
+                </Grid.Style>
+                <Rectangle Grid.Row="0" HorizontalAlignment="Center" VerticalAlignment="Bottom" Fill="{DynamicResource Lid_BG}" Stroke="{DynamicResource Lid_BD}" Width="172" Height="12"/>
+                <Rectangle Grid.Row="0" HorizontalAlignment="Center" VerticalAlignment="Top" Fill="{DynamicResource Lid_BG}" Stroke="{DynamicResource Lid_BD}" Width="180" Height="8"/>
+                <Line X1="35" Y1="-80" X2="120" Y2="-90" Stroke="{StaticResource threadrcolor}" StrokeThickness="5"/>
+                <Line X1="35" Y1="-60" X2="145" Y2="-70" Stroke="{StaticResource threadrcolor}" StrokeThickness="5"/>
+                <Line X1="35" Y1="-40" X2="145" Y2="-50" Stroke="{StaticResource threadrcolor}" StrokeThickness="5"/>
+                <Line X1="35" Y1="-20" X2="145" Y2="-30" Stroke="{StaticResource threadrcolor}" StrokeThickness="5"/>
+                <Rectangle  Stroke="Gray" Fill="{StaticResource doorColor}"  Margin="130,-101,42,0" Width="8" VerticalAlignment="Top" Height="102" />
+                <Rectangle  Stroke="Gray" Fill="{StaticResource doorColor}" Margin="42,-101,130,0" Width="8" VerticalAlignment="Top" Height="102" />
+                <Rectangle  Stroke="Gray" Fill="{StaticResource doorColor2}" Margin="42,-106,42,0" VerticalAlignment="Top" Height="7" />
+                <Rectangle  Fill="White" Margin="50,-101,50,0" Width="80" Height="118" />
+                <Rectangle  x:Name="BG_Status1"  Margin="50,-101,50,0" Width="80" Height="118" Visibility="{Binding RfPowerOnChamberVisibility}" >
+                    <Rectangle.Style>
+                        <Style>
+                            <Setter Property="Rectangle.Fill" Value="{StaticResource chambercolor}"/>
+                            <Style.Triggers>
+                                <DataTrigger Binding="{Binding ElementName=chamber,Path=IsSRFOn}"  Value="True">
+                                    <Setter Property="Rectangle.Fill" Value="{StaticResource rfcolor}"/>
+                                </DataTrigger>
+                            </Style.Triggers>
+                        </Style>
+                    </Rectangle.Style>
+                </Rectangle>
+                <Rectangle  Stroke="#FF000000" Width="80" Height="10" Margin="0,8,0,0" StrokeThickness="1" StrokeDashArray="4 2" SnapsToDevicePixels="True"/>
+                <Rectangle  Stroke="#FF000000" Width="80" Height="9" Margin="0,-10,0,0" StrokeThickness="1" StrokeDashArray="4 2" SnapsToDevicePixels="True"/>
+                <Line X1="35" Y1="-40" X2="145" Y2="-30" Stroke="{StaticResource threadrcolor}" StrokeThickness="5"/>
+                <Line X1="35" Y1="-60" X2="145" Y2="-50" Stroke="{StaticResource threadrcolor}" StrokeThickness="5"/>
+                <Line X1="35" Y1="-80" X2="145" Y2="-70" Stroke="{StaticResource threadrcolor}" StrokeThickness="5"/>
+            </Grid>
+            <Grid Grid.RowSpan="2" Width="160" Height="167" VerticalAlignment="Bottom" Margin="0,0,0,2">
+
+
+
+
+                <!--lift pin-->
+                <Grid x:Name="Top_LiftPin" Height="51" VerticalAlignment="Bottom" Margin="0,0,0,28" >
+                    <Rectangle HorizontalAlignment="Left" Fill="{StaticResource heatercolor}" Stroke="{DynamicResource Lid_BD}" Width="8" Margin="48,10,0,4"/>
+                    <Rectangle HorizontalAlignment="Right" Fill="{StaticResource heatercolor}" Stroke="{DynamicResource Lid_BD}" Width="8" Margin="0,10,48,4"/>
+                    <Rectangle Stroke="{DynamicResource Lid_BD}" Fill="{StaticResource heatercolor}" StrokeThickness="1" VerticalAlignment="Bottom" Height="8" Margin="5,0" Width="64" />
+                    <Rectangle  HorizontalAlignment="Center" Margin="-100,0"  Width="{Binding WaferLength}" Height="10" VerticalAlignment="Top"/>
+                    
+
+                </Grid>
+               
+                <Canvas  Margin="29.5,100,0,0" x:Name="heater">
+                    <Canvas.RenderTransform>
+                        <TransformGroup>
+                            <TranslateTransform  x:Name="heaterRotateAct"/>
+                        </TransformGroup>
+                    </Canvas.RenderTransform>
+
+                    <TextBlock Text="{Binding  ElementName=chamber,Path=WaferID}" Margin="30,-32,0,0" TextAlignment="Center" ></TextBlock>
+
+                    <Border BorderThickness="1" BorderBrush="DarkGray" CornerRadius="4" VerticalAlignment="Top"  Height="10" Margin="-22,-12,0,0" Width="140" Visibility="{Binding ElementName=chamber,Path=IsHasWafer,Converter={StaticResource bool2VisibilityConverter}}">
+                        <Border.Background>
+                            <RadialGradientBrush >
+                                <GradientStop Color="AliceBlue" Offset="0" />
+                                <GradientStop Color="LightGreen" Offset="1" />
+                            </RadialGradientBrush>
+                        </Border.Background>
+                    </Border>
+                    
+                    <Rectangle HorizontalAlignment="Left" Fill="{StaticResource heatercolor}" Stroke="Black" Width="100" Height="10"/>
+                    <Rectangle HorizontalAlignment="Left" Fill="{StaticResource heatercolor}" Stroke="Black" Width="100" Height="10"  Canvas.Top="10"/>
+                    <Rectangle HorizontalAlignment="Left" Fill="{StaticResource heatercolor}" Stroke="Black" Width="30"  Height="50"  Canvas.Top="20" Canvas.Left="36"/>
+                </Canvas>
+                <!--<Canvas Margin="11,100,0,0">
+                    <Canvas.RenderTransform>
+                        <TransformGroup>
+                            <TranslateTransform  x:Name="waferRotateAct"/>
+                        </TransformGroup>
+                    </Canvas.RenderTransform>
+                   
+                </Canvas>-->
+                <!--左边slit door-->
+                <Grid x:Name="Slit_valve" Margin="-41,-10,191,29" >
+                    <Rectangle x:Name="SlitValve_Top"     Fill="{StaticResource doorColor}" Width="8" VerticalAlignment="Top" Height="75"   />
+                    <Rectangle x:Name="SlitValve_Bottom"  Fill="{StaticResource doorColor}" Width="8" VerticalAlignment="Bottom" Height="75" />
+                </Grid>
+
+                <!--slit door右边-->
+                <Grid Margin="190,-10,-40,29" Cursor="Hand">
+                    <Grid.ContextMenu>
+                        <ContextMenu >
+                            <MenuItem Header="Open Door"   Click="OpenDoor_Click"  IsChecked="{Binding IsSlitDoorClosed,Converter={StaticResource BoolToBool}}"                                        IsEnabled="{Binding IsSlitDoorClosed}"/>
+                            <MenuItem Header="Close Door"  Click="CloseDoor_Click"  IsChecked="{Binding IsSlitDoorClosed}"  IsEnabled="{Binding IsSlitDoorClosed,Converter={StaticResource BoolToBool}}"/>
+                        </ContextMenu>
+                    </Grid.ContextMenu>
+                    <Rectangle  Fill="{StaticResource doorColor}" Style="{StaticResource SlitValve_Animation}" Width="8" VerticalAlignment="Top"    Height="75" />
+                    <Rectangle  Fill="{StaticResource doorColor}" Style="{StaticResource SlitValve_Animation}" Width="8" VerticalAlignment="Bottom" Height="75" />
+                </Grid>
+            </Grid>
+        </Grid>
+
+    </Canvas>
+
+
+</UserControl>

+ 129 - 0
Venus/Venus_Themes/UserControls/ChamberWithHeater.xaml.cs

@@ -0,0 +1,129 @@
+using OpenSEMI.Ctrlib.Controls;
+using System.Windows;
+using System.Windows.Controls;
+using Venus_Themes.Unity;
+using static Venus_Themes.UserControls.EFEM;
+
+namespace Venus_Themes.UserControls
+{
+    /// <summary>
+    /// Chamber.xaml 的交互逻辑
+    /// </summary>
+    public partial class ChamberWithHeater : UserControl
+    {
+        public ChamberWithHeater()
+        {
+            InitializeComponent();
+        }
+        public static readonly DependencyProperty IsOpenSlitDoorProperty = DependencyProperty.Register(
+           "IsOpenSlitDoor", typeof(bool), typeof(ChamberWithHeater));
+
+
+        public bool IsOpenSlitDoor
+        {
+            get { return (bool)this.GetValue(IsOpenSlitDoorProperty); }
+            set { this.SetValue(IsOpenSlitDoorProperty, value); }
+        }
+    
+
+
+        public static readonly DependencyProperty IsHasWaferProperty = DependencyProperty.Register(
+          "IsHasWafer", typeof(bool), typeof(ChamberWithHeater),
+          new FrameworkPropertyMetadata(false, FrameworkPropertyMetadataOptions.AffectsRender));
+        public bool IsHasWafer
+        {
+            get { return (bool)this.GetValue(IsHasWaferProperty); }
+            set { this.SetValue(IsHasWaferProperty, value); }
+        }
+
+
+        public static readonly DependencyProperty IsLidOpenProperty = DependencyProperty.Register(
+         "IsLidOpen", typeof(bool), typeof(ChamberWithHeater));
+        public bool IsLidOpen
+        {
+            get { return (bool)this.GetValue(IsLidOpenProperty); }
+            set { this.SetValue(IsLidOpenProperty, value); }
+        }
+
+        public static readonly DependencyProperty IsSRFOnProperty = DependencyProperty.Register(
+        "IsSRFOn", typeof(bool), typeof(ChamberWithHeater),
+        new FrameworkPropertyMetadata(false, FrameworkPropertyMetadataOptions.AffectsRender));
+        public bool IsSRFOn
+        {
+            get { return (bool)this.GetValue(IsSRFOnProperty); }
+            set { this.SetValue(IsSRFOnProperty, value); }
+        }
+
+        public static readonly DependencyProperty IsBRFOnProperty = DependencyProperty.Register(
+       "IsBRFOn", typeof(bool), typeof(ChamberWithHeater),
+       new FrameworkPropertyMetadata(false, FrameworkPropertyMetadataOptions.AffectsRender));
+        public bool IsBRFOn
+        {
+            get { return (bool)this.GetValue(IsBRFOnProperty); }
+            set { this.SetValue(IsBRFOnProperty, value); }
+        }
+
+        public static readonly DependencyProperty WaferIDProperty = DependencyProperty.Register(
+          "WaferID", typeof(string), typeof(ChamberWithHeater));
+
+        public string WaferID
+        {
+            get { return (string)this.GetValue(WaferIDProperty); }
+            set { this.SetValue(WaferIDProperty, value); }
+        }
+        public static readonly DependencyProperty ModuleNameProperty = DependencyProperty.Register(
+      "ModuleName", typeof(string), typeof(ChamberWithHeater));
+
+        public string ModuleName
+        {
+            get { return (string)this.GetValue(ModuleNameProperty); }
+            set
+            {
+                this.SetValue(ModuleNameProperty, value);
+            }
+        }
+
+        public static readonly DependencyProperty HeaterPositionProperty = DependencyProperty.Register(
+          "HeaterPosition", typeof(string), typeof(ChamberWithHeater), new PropertyMetadata("Position1", PositionChangedCallback));
+
+        public string HeaterPosition
+        {
+            get { return (string)this.GetValue(HeaterPositionProperty); }
+            set { this.SetValue(HeaterPositionProperty, value); }
+        }
+
+        private void CreateWafer_Click(object sender, RoutedEventArgs e)
+        {
+            UIEvents.OnChamberCreateDeleteWafer(new WaferOperation() { ModuleName = ModuleName, IsCreate = true });
+        }
+
+        private void DeleteWafer_Click(object sender, RoutedEventArgs e)
+        {
+            UIEvents.OnChamberCreateDeleteWafer(new WaferOperation() { ModuleName = ModuleName, IsCreate = false });
+
+        }
+        private void OpenDoor_Click(object sender, RoutedEventArgs e)
+        {
+            //var t = ((((this.Parent as Canvas).Parent as Canvas).Parent as UserControl).DataContext).;
+            UIEvents.OnPMDoorRaiseChanged(new DoorPara() { ModuleName = ModuleName, IsOpen = "Open" });
+        }
+
+        private void CloseDoor_Click(object sender, RoutedEventArgs e)
+        {
+            UIEvents.OnPMDoorRaiseChanged(new DoorPara() { ModuleName = ModuleName, IsOpen = "Close" });
+        }
+        private static void PositionChangedCallback(DependencyObject d, DependencyPropertyChangedEventArgs e)
+        {
+
+            var newAct = e.NewValue.ToString();
+            var control = d as ChamberWithHeater;
+            GoToPosition(control, newAct);
+
+
+        }
+        private static void GoToPosition(Control control, string robotPosition)
+        {
+            VisualStateManager.GoToElementState(control, robotPosition, true);
+        }
+    }
+}

Plik diff jest za duży
+ 2 - 2
Venus/Venus_Themes/UserControls/EFEMFrontView.xaml


+ 2 - 14
Venus/Venus_Themes/UserControls/FOUPFrontView.xaml

@@ -57,20 +57,8 @@
                                                     <DropShadowEffect Direction="270" BlurRadius="0" ShadowDepth="1"/>
                                                 </Rectangle.Effect>
                                             </Rectangle>
-                                            <controls:Slot ViewType="Front"  WaferStatus="{Binding WaferStatus}" SlotID="{Binding SlotID}" ModuleID="{Binding ModuleID}" SourceName="{Binding SourceName}" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0,4,0,0" SlotMouseButtonDown="Slot_SlotMouseButtonDown" WaferTransferStarted="Slot_WaferTransferStarted">
-                                                <!--<i:Interaction.Triggers>
-                                                    <i:EventTrigger EventName="SlotMouseButtonDown">
-                                                        <cal:ActionMessage MethodName="OnMouseUp">
-                                                            <cal:Parameter Value="$source" />
-                                                            <cal:Parameter Value="$eventargs" />
-                                                        </cal:ActionMessage>
-                                                    </i:EventTrigger>
-                                                    <i:EventTrigger EventName="WaferTransferStarted">
-                                                        <cal:ActionMessage MethodName="OnWaferTransfer">
-                                                            <cal:Parameter Value="$eventargs" />
-                                                        </cal:ActionMessage>
-                                                    </i:EventTrigger>
-                                                </i:Interaction.Triggers>-->
+                                            <controls:Slot ViewType="Front"  WaferStatus="{Binding WaferStatus}" SlotID="{Binding SlotID}" ModuleID="{Binding ModuleID}" SourceName="{Binding SourceName}" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0,2,0,0" SlotMouseButtonDown="Slot_SlotMouseButtonDown" WaferTransferStarted="Slot_WaferTransferStarted" DuplicatedVisibility="{Binding DuplicatedVisibility}" Padding="50 0 0 0">
+
                                             </controls:Slot>
                                             <TextBlock x:Name="Foup_Text" HorizontalAlignment="Center" Grid.Column="1" TextWrapping="Wrap" Text="{Binding SlotIndex}" Background="#FF646464" Foreground="White" VerticalAlignment="Bottom" FontFamily="Arial" FontSize="10" Width="13" TextAlignment="Center" >
                                             </TextBlock>

+ 7 - 0
Venus/Venus_Themes/Venus_Themes.csproj

@@ -136,6 +136,9 @@
     <Compile Include="UserControls\ButterflyValveMessageBox.xaml.cs">
       <DependentUpon>ButterflyValveMessageBox.xaml</DependentUpon>
     </Compile>
+    <Compile Include="UserControls\ChamberWithHeater.xaml.cs">
+      <DependentUpon>ChamberWithHeater.xaml</DependentUpon>
+    </Compile>
     <Compile Include="UserControls\ChamberDE.xaml.cs">
       <DependentUpon>ChamberDE.xaml</DependentUpon>
     </Compile>
@@ -347,6 +350,10 @@
       <SubType>Designer</SubType>
       <Generator>MSBuild:Compile</Generator>
     </Page>
+    <Page Include="UserControls\ChamberWithHeater.xaml">
+      <Generator>MSBuild:Compile</Generator>
+      <SubType>Designer</SubType>
+    </Page>
     <Page Include="UserControls\ChamberDE.xaml">
       <Generator>MSBuild:Compile</Generator>
       <SubType>Designer</SubType>

+ 4 - 3
Venus/Venus_UI/Venus_UI.csproj

@@ -69,9 +69,6 @@
     <Reference Include="log4net">
       <HintPath>..\ThirdParty\log4net.dll</HintPath>
     </Reference>
-    <Reference Include="OpenSEMI.Core">
-      <HintPath>..\ThirdParty\OpenSEMI.Core.dll</HintPath>
-    </Reference>
     <Reference Include="Prism">
       <HintPath>..\ThirdParty\Prism.dll</HintPath>
     </Reference>
@@ -187,6 +184,10 @@
       <Project>{b55e8d4b-c4c8-4a6d-9fc4-609c52a56cac}</Project>
       <Name>OpenSEMI.Ctrlib</Name>
     </ProjectReference>
+    <ProjectReference Include="..\Framework\OpenSEMICore\OpenSEMI.Core.csproj">
+      <Project>{c4cd3d7b-cb40-47d5-ab04-df05007e5b6a}</Project>
+      <Name>OpenSEMI.Core</Name>
+    </ProjectReference>
     <ProjectReference Include="..\Framework\UICore\UICore.csproj">
       <Project>{2C9E1DF3-1ABA-4972-BE60-41DD9B3C47A7}</Project>
       <Name>UICore</Name>

+ 4 - 5
Venus/Venus_UI/Views/ShellView.xaml

@@ -2,8 +2,7 @@
         xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
         xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
         xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
-        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
-        xmlns:wnd="http://OpenSEMI.Ctrlib.com/presentation"        
+        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"       
         WindowStartupLocation="CenterScreen"
         xmlns:prism="http://prismlibrary.com/"
         mc:Ignorable="d"
@@ -150,10 +149,10 @@
             <RowDefinition Height="50"/>
         </Grid.RowDefinitions>
 
-        <ContentControl x:Name="Top_Frame"  Grid.Row="0"  prism:RegionManager.RegionName="TopRegion"/>
+        <ContentControl x:Name="Top_Frame"      Grid.Row="0"  prism:RegionManager.RegionName="TopRegion"/>
 
-        <ContentControl x:Name="Main_Frame" Grid.Row="1" prism:RegionManager.RegionName="MainRegion" MouseDoubleClick="Window_MouseDoubleClick"/>
+        <ContentControl x:Name="Main_Frame"     Grid.Row="1"  prism:RegionManager.RegionName="MainRegion" MouseDoubleClick="Window_MouseDoubleClick"/>
 
-        <StackPanel x:Name="Bottom_Frame"   Grid.Row="2" Background="White" Orientation="Horizontal"/>
+        <StackPanel     x:Name="Bottom_Frame"   Grid.Row="2" Background="White" Orientation="Horizontal"/>
     </Grid>
 </Window>

+ 15 - 28
Venus/Venus_UI/Views/ShellView.xaml.cs

@@ -100,10 +100,6 @@ namespace Venus_UI.Views
             this.MaxHeight = SystemParameters.WorkArea.Height;
             ResizeMode = ResizeMode.CanMinimize;
             this.WindowState = this.WindowState == WindowState.Maximized ? WindowState.Normal : WindowState.Maximized;
-
-            
-
-
         }
 
        
@@ -311,43 +307,34 @@ namespace Venus_UI.Views
                     aduRadioButtonIcon.Checked += AduRadioButtonIcon_Click;
                     aduRadioButtonIcon.SelectBackground = new SolidColorBrush((Color)ColorConverter.ConvertFromString("#0076C4"));
                     aduRadioButtonIcon.SelectColor = new SolidColorBrush((Colors.White));
-                    //aduRadioButtonIcon.DefaultBackground = new SolidColorBrush((Color)ColorConverter.ConvertFromString("#94BCD7"));
-                    //aduRadioButtonIcon.DefaultBackground = new SolidColorBrush(Colors.DarkGray);
-
-
                     aduRadioButtonIcon.Width = 180;
-                    //aduRadioButtonIcon.Height = 40;
-
-                    //aduRadioButtonIcon.Foreground=Brushes.White;
                     aduRadioButtonIcon.Tag = index;
                     buttonList.Add(aduRadioButtonIcon);
 
                     Bottom_Frame.Children.Add(aduRadioButtonIcon);
                 }
                 TabItem tabItem = new TabItem() { Header = menu[i].SecondMenu, Content = obj };
+                
                 if (menu[i].Permission == MenuPermission.ReadOnly)
                 {
                     (tabItem.Content as Control).IsEnabled = false;
                 }
                 centerTabViews[index].Items.Add(tabItem);
+                (tabItem.Content as Control).IsVisibleChanged += TabItem_IsVisibleChanged;
                 lastModule = menu[i].FirstMenu;
-                //tabControl.Items.Add(new TabItem() { Header = menu[i].SecondMenu, Content = obj });
-
-
-                //for (int j = 0; j < menu.Count; j++)
-                //{
-                //    if (menu[j].Permission == MenuPermission.None)
-                //    {
-                //        continue;
-                //    }
-
-                //}
-                //centerTabViews.Add(tabControl);
             }
             Main_Frame.Content = centerTabViews[0];
             ModuleManager.Initialize();
         }
 
+        private void TabItem_IsVisibleChanged(object sender, DependencyPropertyChangedEventArgs e)
+        {
+            var viewmodel = (sender as Control).DataContext;
+            Type t = viewmodel.GetType();
+            MethodInfo methodInfo = t.GetMethod("EnterExitView", new Type[] { typeof(bool) });
+            methodInfo?.Invoke(viewmodel, new object[] { e.NewValue });
+        }
+
         public void Anystationchange(string menuviewItem, WaferHistoryWafer queryFilter)
         {
             UserControl address = new ProcessHistoryView();
@@ -696,12 +683,12 @@ namespace Venus_UI.Views
         }
         #endregion
 
-        private  async void Window_MouseDoubleClick(object sender, System.Windows.Input.MouseButtonEventArgs e)
+        private   void Window_MouseDoubleClick(object sender, System.Windows.Input.MouseButtonEventArgs e)
         {
-            this.buttonList[1].IsChecked = true;
-            await System.Threading.Tasks.Task.Delay(10);
-            SaveWindowContent(this, "test.jpg");
-            this.buttonList[0].IsChecked = true;
+            //this.buttonList[1].IsChecked = true;
+            //await System.Threading.Tasks.Task.Delay(10);
+            //SaveWindowContent(this, "test.jpg");
+            //this.buttonList[0].IsChecked = true;
         }      
     }
 }