Browse Source

1.Kepler2200 TM/PM控大压力10Pa,添加工艺结束,等待压力稳定(TM/PM压差满足要求)TM再Pick功能
2.TM 搭载kepler2200时控压由Fast Pump改为Soft pump,解决控大压力10Pa控不住问题
3.优化Datalog数据分析界面,精确到毫秒

lixiang 1 year ago
parent
commit
6d6f659b77
34 changed files with 483 additions and 270 deletions
  1. 2 0
      Venus/Framework/Common/Device/Bases/RfPowerBase.cs
  2. 8 0
      Venus/Venus_Core/ProcessUnitDefine.cs
  3. 7 52
      Venus/Venus_Core/Recipe.cs
  4. 3 0
      Venus/Venus_Core/VenusDevice.cs
  5. 1 1
      Venus/Venus_MainPages/ViewModels/FaViewModel.cs
  6. 7 2
      Venus/Venus_MainPages/ViewModels/OverKepler2200BViewModel.cs
  7. 24 5
      Venus/Venus_MainPages/ViewModels/ProcessHistoryViewModel.cs
  8. 26 17
      Venus/Venus_MainPages/ViewModels/TMOperationViewModel.cs
  9. 22 2
      Venus/Venus_MainPages/ViewModels/TMViewModel.cs
  10. 34 0
      Venus/Venus_MainPages/Views/OverKepler2200BView.xaml
  11. 6 1
      Venus/Venus_MainPages/Views/ProcessHistoryView.xaml
  12. 10 5
      Venus/Venus_MainPages/Views/TMView.xaml
  13. BIN
      Venus/Venus_RT/Config/PM/Kepler2200A/Kepler2200ADeviceModel.xml
  14. BIN
      Venus/Venus_RT/Config/PM/Kepler2200B/Kepler2200BDeviceModel.xml
  15. 2 2
      Venus/Venus_RT/Config/PM/Kepler2200B/Kepler2200BIoDefine.xml
  16. 28 0
      Venus/Venus_RT/Config/System_Kepler2200.sccfg
  17. 0 1
      Venus/Venus_RT/Config/TM/TMInterlock.xml
  18. 1 1
      Venus/Venus_RT/Devices/AdTecRF.cs
  19. 46 19
      Venus/Venus_RT/Devices/DeviceManager.cs
  20. 6 1
      Venus/Venus_RT/Devices/IODevices/IoGasStick.cs
  21. 15 14
      Venus/Venus_RT/Devices/JetKepler2200BPM.cs
  22. 15 1
      Venus/Venus_RT/Devices/JetVenusPM.cs
  23. 1 1
      Venus/Venus_RT/Devices/LzMatch_Ethercat.cs
  24. 31 10
      Venus/Venus_RT/Devices/RevtechMatch.cs
  25. 10 1
      Venus/Venus_RT/Devices/TruPlasmaRF_Ethercat.cs
  26. 1 1
      Venus/Venus_RT/Instances/ToolLoader.cs
  27. 6 1
      Venus/Venus_RT/Modules/PMs/GasBoxLeakCheckRoutine.cs
  28. 11 13
      Venus/Venus_RT/Modules/PMs/PMProcessRoutine.cs
  29. 26 2
      Venus/Venus_RT/Modules/PMs/ProcessDefine.cs
  30. 16 16
      Venus/Venus_RT/Modules/PMs/PumpDownRoutine.cs
  31. 99 99
      Venus/Venus_RT/Modules/TM/MFControlPressureRoutine.cs
  32. 17 0
      Venus/Venus_RT/Modules/TM/MFPMPickRoutine.cs
  33. 1 1
      Venus/Venus_Themes/UserControls/DrawGraphicsControl.xaml.cs
  34. 1 1
      Venus/Venus_Themes/UserControls/FlowPipe.xaml

+ 2 - 0
Venus/Framework/Common/Device/Bases/RfPowerBase.cs

@@ -81,6 +81,8 @@ namespace MECF.Framework.Common.Device.Bases
             DATA.Subscribe($"{Module}.{Name}.ForwardPower", () => ForwardPower);
             DATA.Subscribe($"{Module}.{Name}.ReflectPower", () => ReflectPower);
             DATA.Subscribe($"{Module}.{Name}.PowerSetPoint", () => PowerSetPoint);
+            DATA.Subscribe($"{Module}.{Name}.IsPowerOn", () => IsPowerOn);
+
 
             DATA.Subscribe($"{Module}.{Name}.Frequency", () => Frequency);
             DATA.Subscribe($"{Module}.{Name}.PulsingFrequency", () => PulsingFrequency);

+ 8 - 0
Venus/Venus_Core/ProcessUnitDefine.cs

@@ -64,6 +64,7 @@ namespace Venus_Core
         PressureByPressureModeUnit,
         Kepler2200GasControlUnit,
         HeaterUnit,
+        RFBoxUnit,
         TCPUnit
     }
 
@@ -190,6 +191,13 @@ namespace Venus_Core
         public int TargetBiasRFPower { get; set; }            
     }
 
+    public class RFBoxUnit : ProcessUnitBase
+    {
+        public string UnitName { get; set; } = "RFBoxUnit";
+        public int C1 { get; set; }
+    }
+
+
     public class GasControlUnit : ProcessUnitBase
     {
         public string UnitName { get; set; } = "GasControlUnit";

+ 7 - 52
Venus/Venus_Core/Recipe.cs

@@ -157,11 +157,11 @@ namespace Venus_Core
             get { return m_BasePressure; }
             set { m_BasePressure = value; InvokePropertyChanged("BasePressure"); }
         }
-        private string m_ChillerTemp;
-        public string ChillerTemp
+        private string m_BaseTemperature;
+        public string BaseTemperature
         {
-            get { return m_ChillerTemp; }
-            set { m_ChillerTemp = value; InvokePropertyChanged("ChillerTemp"); }
+            get { return m_BaseTemperature; }
+            set { m_BaseTemperature = value; InvokePropertyChanged("BaseTemperature"); }
         }
         private int m_RFHoldTime = 1000;
         public int RFHoldTime
@@ -549,6 +549,9 @@ namespace Venus_Core
                         case "HeaterUnit":
                             unit.Add(JsonConvert.DeserializeObject<HeaterUnit>(step.LstUnit[i].ToString()));
                             break;
+                        case "RFBoxUnit":
+                            unit.Add(JsonConvert.DeserializeObject<RFBoxUnit>(step.LstUnit[i].ToString()));
+                            break;
                         case "GasUnit":
                             unit.Add(JsonConvert.DeserializeObject<Kepler2200GasControlUnit>(step.LstUnit[i].ToString()));
                             break;
@@ -638,55 +641,7 @@ namespace Venus_Core
 
             return recipeString;
         }
-        public static ObservableCollection<Object> GetAllUnits(JetChamber jetChamber)
-        {
-            ObservableCollection<Object> LstUnit = new ObservableCollection<object>();
-            switch (jetChamber)
-            {
-                case JetChamber.Venus:
-                    foreach (var item in Enum.GetValues(typeof(VenusUnits)))
-                    {
-                        Type t = Type.GetType($"Venus_Core.{item.ToString()}");
-                        var obj = System.Activator.CreateInstance(t);
-                        LstUnit.Add(obj);
-                    }
-                    break;
 
-                case JetChamber.Kepler2300:
-                    foreach (var item in Enum.GetValues(typeof(Kepler2300Uints)))
-                    {
-                        Type t = Type.GetType($"Venus_Core.{item.ToString()}");
-                        var obj = System.Activator.CreateInstance(t);
-                        LstUnit.Add(obj);
-                    }
-                    break;
-                case JetChamber.Kepler2200A:
-                    foreach (var item in Enum.GetValues(typeof(Kepler2200AUnits)))
-                    {
-                        Type t = Type.GetType($"Venus_Core.{item.ToString()}");
-                        var obj = System.Activator.CreateInstance(t);
-                        LstUnit.Add(obj);
-                    }
-                    break;
-                case JetChamber.Kepler2200B:
-                    foreach (var item in Enum.GetValues(typeof(Kepler2200BUnits)))
-                    {
-                        Type t = Type.GetType($"Venus_Core.{item.ToString()}");
-                        var obj = System.Activator.CreateInstance(t);
-                        LstUnit.Add(obj);
-                    }
-                    break;
-                case JetChamber.VenusSE:
-                    foreach (var item in Enum.GetValues(typeof(VenusSEUnits)))
-                    {
-                        Type t = Type.GetType($"Venus_Core.{item.ToString()}");
-                        var obj = System.Activator.CreateInstance(t);
-                        LstUnit.Add(obj);
-                    }
-                    break;
-            }
-            return LstUnit;
-        }
         public static ObservableCollection<Object> GetAllUnits(JetChamber jetChamber, RecipeType recipeType)
         {
             ObservableCollection<Object> LstUnit = new ObservableCollection<object>();

+ 3 - 0
Venus/Venus_Core/VenusDevice.cs

@@ -94,6 +94,9 @@
         Match,
         BiasMatch,
 
+        RFBox,
+
+
         PressureControl,
         ThrottleValve,
         HeaterChamber,

+ 1 - 1
Venus/Venus_MainPages/ViewModels/FaViewModel.cs

@@ -440,7 +440,7 @@ namespace Venus_MainPages.ViewModels
                                 RaisePropertyChanged(pi.Name);
                             }
                         }
-                        catch (Exception ex)
+                        catch
                         {
                         }
                     }

+ 7 - 2
Venus/Venus_MainPages/ViewModels/OverKepler2200BViewModel.cs

@@ -18,8 +18,6 @@ using MECF.Framework.Common.CommonData.DeviceData;
 using Path = System.IO.Path;
 using System.Windows.Controls;
 using Aitex.Core.RT.Log;
-using System.Reflection;
-using static Xceed.Wpf.Toolkit.Calculator;
 
 namespace Venus_MainPages.ViewModels
 {
@@ -1813,6 +1811,13 @@ namespace Venus_MainPages.ViewModels
             m_RtDataKeys.Add($"{ModuleName}.{VenusDevice.Match}.C2");
             m_RtDataKeys.Add($"{ModuleName}.{VenusDevice.Match}.WorkMode");
 
+            m_RtDataKeys.Add($"{ModuleName}.{VenusDevice.RFBox}.C1");
+            m_RtDataKeys.Add($"{ModuleName}.{VenusDevice.RFBox}.C2");
+            m_RtDataKeys.Add($"{ModuleName}.{VenusDevice.RFBox}.WorkMode");
+            m_RtDataKeys.Add($"{ModuleName}.{VenusDevice.RFBox}.Vpp");
+            m_RtDataKeys.Add($"{ModuleName}.{VenusDevice.RFBox}.DCBias");
+
+
             m_RtDataKeys.Add($"{ModuleName}.{VenusDevice.PendulumValve}.DeviceData");
             //m_RtDataKeys.Add($"{ModuleName}.{VenusDevice.ESCHV}.DeviceData");
 

+ 24 - 5
Venus/Venus_MainPages/ViewModels/ProcessHistoryViewModel.cs

@@ -49,6 +49,8 @@ namespace Venus_MainPages.ViewModels
         public List<SolidColorBrush> solidColorBrushes = new List<SolidColorBrush>();
         //DateTime currentTime;
         private RecipeItem selectedRecipeItem;
+        private bool m_IsShowStep;
+
 
         #endregion
 
@@ -83,6 +85,11 @@ namespace Venus_MainPages.ViewModels
             get { return _PdKeyDataObservation; }
             set { SetProperty(ref _PdKeyDataObservation, value); }
         }
+        public bool IsShowStep
+        {
+            get { return m_IsShowStep; }
+            set { SetProperty(ref m_IsShowStep, value); }
+        }
         #endregion
 
         #region 命令
@@ -478,6 +485,7 @@ namespace Venus_MainPages.ViewModels
             }
             Compare(OldPdKeyDataCollection, PdKeyDataCollection);
             PdKeyDataCollection = DeepCopyJson(OldPdKeyDataCollection);
+           
         }
 
         public void Compare(ObservableCollection<PdKeyData> olddata, ObservableCollection<PdKeyData> newdata)
@@ -582,13 +590,24 @@ namespace Venus_MainPages.ViewModels
 
             this.view.MyDrawGraphicsControl.FitControl();
             this.view.MyDrawGraphicsControl.YPoints.Clear();
-            var item = QueryDataClient.Instance.Service.GetHistorySteps(Convert.ToDateTime(selectedRecipeItem?.StartTime), Convert.ToDateTime(selectedRecipeItem?.EndTime));
-            if (item!=null)
+            //var item = QueryDataClient.Instance.Service.GetHistorySteps(Convert.ToDateTime(selectedRecipeItem?.StartTime), Convert.ToDateTime(selectedRecipeItem?.EndTime));
+            //if (item!=null)
+            //{
+            //    item.ForEach(x =>
+            //    {
+            //        this.view.MyDrawGraphicsControl.YPoints.Add(new Venus_Core.StepItem() { StartValue = x.StartTime.ToOADate(), Information = $"{x.RecipeId}:{x.StepNo}" });
+            //    });
+            //}
+            if (IsShowStep)
             {
-                item.ForEach(x =>
+                var item2 = QueryDataClient.Instance.Service.GetHistorySteps(Convert.ToDateTime(selectedRecipeItem?.StartTime), Convert.ToDateTime(selectedRecipeItem?.EndTime));
+                if (item2 != null)
                 {
-                    this.view.MyDrawGraphicsControl.YPoints.Add(new Venus_Core.StepItem() { StartValue = x.StartTime.ToOADate(), Information = $"{x.RecipeId}:{x.StepNo}" });
-                });
+                    item2.ForEach(x =>
+                    {
+                        this.view.MyDrawGraphicsControl.YPoints.Add(new Venus_Core.StepItem() { StartValue = x.StartTime.ToOADate(), Information = $"{x.RecipeId}\n{x.StepNo}" });
+                    });
+                }
             }
         }
         private void CloseAll(ObservableCollection<ParameterNode> parameterNodes)

+ 26 - 17
Venus/Venus_MainPages/ViewModels/TMOperationViewModel.cs

@@ -20,7 +20,7 @@ namespace Venus_MainPages.ViewModels
     {
         #region 私有字段
         private TMOperationView m_TMOperationView;
-        private bool m_IsOFFline=true;
+        private bool m_IsOFFline = true;
 
         private bool m_TMIsOFFline = true;
 
@@ -50,7 +50,7 @@ namespace Venus_MainPages.ViewModels
         private bool m_LLBFastPumpValveIsOpen;
         private bool m_LLBPurgeValveIsOpen;
         private bool m_LLBVentValveIsOpen;
-        private List<string> m_RtDataKeys=new List<string> ();
+        private List<string> m_RtDataKeys = new List<string>();
 
         private int m_TMOutChamberPressure;
         private int m_TMOutChamberFlow;
@@ -66,7 +66,7 @@ namespace Venus_MainPages.ViewModels
         private LLState m_LLBCurrentState;
         private ObservableCollection<PMLeakCheckResult> m_LeakCheckResultList = new ObservableCollection<PMLeakCheckResult>();
 
-
+        private bool m_firstLoad = true;
         #endregion
 
         #region 属性
@@ -166,12 +166,12 @@ namespace Venus_MainPages.ViewModels
         public bool TMIsOFFline
         {
             get { return m_TMIsOFFline; }
-            set 
-            {               
+            set
+            {
                 SetProperty(ref m_TMIsOFFline, value);
             }
         }
-      
+
         public Dictionary<string, object> RtDataValues
         {
             get { return m_RtDataValues; }
@@ -223,7 +223,7 @@ namespace Venus_MainPages.ViewModels
         public int TMOutChamberPressure
         {
             get { return m_TMOutChamberPressure; }
-            set 
+            set
             {
                 SetProperty(ref m_TMOutChamberPressure, value);
             }
@@ -231,7 +231,7 @@ namespace Venus_MainPages.ViewModels
         public ObservableCollection<string> HomeAllSteps
         {
             get { return m_HomeAllSteps; }
-            set{SetProperty(ref m_HomeAllSteps, value);}
+            set { SetProperty(ref m_HomeAllSteps, value); }
         }
         public int StepProcess
         {
@@ -248,7 +248,7 @@ namespace Venus_MainPages.ViewModels
             get { return m_TMCurrentState; }
             set
             {
-                if (( m_TMCurrentState == TMState.Leakchecking) && value == TMState.Idle)
+                if ((m_TMCurrentState == TMState.Leakchecking) && value == TMState.Idle)
                 {
                     var AllLeakCheckDa = QueryDataClient.Instance.Service.GetPMLeakCheckResult(m_ModuleCheckedName);
                     if (AllLeakCheckDa != null)
@@ -412,7 +412,16 @@ namespace Venus_MainPages.ViewModels
         #region 命令方法
         private void OnLoad(object tmOperationView)
         {
-           m_TMOperationView = (TMOperationView)tmOperationView;
+            if (m_firstLoad)
+            {
+                m_TMOperationView = (TMOperationView)tmOperationView;
+                var AllLeakCheckDa = QueryDataClient.Instance.Service.GetPMLeakCheckResult("TM");
+                if (AllLeakCheckDa != null)
+                {
+                    LeakCheckResultList = new ObservableCollection<PMLeakCheckResult>(AllLeakCheckDa);
+                }
+                m_firstLoad=false;
+            }
         }
 
         private void OnHome()
@@ -458,7 +467,7 @@ namespace Venus_MainPages.ViewModels
         }
         private void OnOpenTMPump()
         {
-            InvokeClient.Instance.Service.DoOperation("TM.ControlPump",true);
+            InvokeClient.Instance.Service.DoOperation("TM.ControlPump", true);
         }
         private void OnCloseTMPump()
         {
@@ -467,7 +476,7 @@ namespace Venus_MainPages.ViewModels
         }
         private void OnOpenLLPump()
         {
-            InvokeClient.Instance.Service.DoOperation("LL.ControlPump",true);
+            InvokeClient.Instance.Service.DoOperation("LL.ControlPump", true);
         }
         private void OnCloseLLPump()
         {
@@ -529,15 +538,15 @@ namespace Venus_MainPages.ViewModels
             LLBFastPumpValveIsOpen = CommonFunction.GetValue<bool>(RtDataValues, "TM.LLBFastPumpValve.IsOpen");
             LLBPurgeValveIsOpen = CommonFunction.GetValue<bool>(RtDataValues, "TM.LLBPurgeValve.IsOpen");
             LLBVentValveIsOpen = CommonFunction.GetValue<bool>(RtDataValues, "TM.LLBVentValve.IsOpen");
-            IsOFFline= !CommonFunction.GetValue<bool>(RtDataValues, $"{m_ModuleCheckedName}.IsOnline");
-            TMIsOFFline= !CommonFunction.GetValue<bool>(RtDataValues, $"TM.IsOnline");
+            IsOFFline = !CommonFunction.GetValue<bool>(RtDataValues, $"{m_ModuleCheckedName}.IsOnline");
+            TMIsOFFline = !CommonFunction.GetValue<bool>(RtDataValues, $"TM.IsOnline");
             TMCurrentState = (TMState)(Enum.Parse(typeof(TMState), RtDataValues[$"TM.FsmState"].ToString()));
-            LLACurrentState = (LLState)(Enum.Parse(typeof(LLState), RtDataValues[$"LLA.FsmState"].ToString())); 
+            LLACurrentState = (LLState)(Enum.Parse(typeof(LLState), RtDataValues[$"LLA.FsmState"].ToString()));
             LLBCurrentState = (LLState)(Enum.Parse(typeof(LLState), RtDataValues[$"LLB.FsmState"].ToString()));
             TMIsHoming = TMCurrentState == TMState.Initializing || (TMState)(Enum.Parse(typeof(TMState), RtDataValues[$"TM.FsmState"].ToString())) == TMState.InitializingRB;
             if (m_TMOperationView != null)
             {
-                m_TMOperationView.stepBar.Progress= CommonFunction.GetValue<int>(RtDataValues, "TM.Home.StepNo");
+                m_TMOperationView.stepBar.Progress = CommonFunction.GetValue<int>(RtDataValues, "TM.Home.StepNo");
 
             }
         }
@@ -594,7 +603,7 @@ namespace Venus_MainPages.ViewModels
 
             m_RtDataKeys.Add("TM.Home.StepNo");
 
-            
+
         }
         #endregion
     }

+ 22 - 2
Venus/Venus_MainPages/ViewModels/TMViewModel.cs

@@ -112,13 +112,18 @@ namespace Venus_MainPages.ViewModels
         private bool m_PMDIsCycle;
 
         private int m_CycleCount;
-
+        private PressureType m_PressureType;
+        private bool m_firstFlag = true;
 
 
         #endregion
 
         #region 属性
-
+        public PressureType PressureType
+        {
+            get { return m_PressureType; }
+            set { SetProperty(ref m_PressureType, value); }
+        }
         public List<string> OriginalCycle
         {
             get { return m_OriginalCycle; }
@@ -869,6 +874,10 @@ namespace Venus_MainPages.ViewModels
         private DelegateCommand<object> _ChamberDoorCloseCommand;
         public DelegateCommand<object> ChamberDoorCloseCommand =>
             _ChamberDoorCloseCommand ?? (_ChamberDoorCloseCommand = new DelegateCommand<object>(OnChamberDoorClose));
+
+        private DelegateCommand _LoadCommand;
+        public DelegateCommand LoadCommand =>
+            _LoadCommand ?? (_LoadCommand = new DelegateCommand(OnLoad));
         #endregion
 
         #region 构造函数
@@ -1257,6 +1266,17 @@ namespace Venus_MainPages.ViewModels
         {
             InvokeClient.Instance.Service.DoOperation($"{obj?.ToString()}.SlitDoor.Close");
         }
+        private void OnLoad()
+        {
+            if (m_firstFlag)
+            {
+                object obj = QueryDataClient.Instance.Service.GetData("System.PressureUnitType");
+                PressureType = (PressureType)Convert.ToInt32(obj);
+                m_firstFlag = false;
+            }
+
+        }
+
         #endregion
 
         #region 私有方法

+ 34 - 0
Venus/Venus_MainPages/Views/OverKepler2200BView.xaml

@@ -1160,8 +1160,42 @@
 
 
 
+        </Grid>
+
+        <Grid Width="300" Height="130"  Canvas.Left="500" Canvas.Top="580" Background="#E8E8E8" unity:GridOptions.LineBrush="#afb4db" unity:GridOptions.ShowBorder="True">
+            <Grid.RowDefinitions>
+                <RowDefinition/>
+                <RowDefinition/>
+                <RowDefinition/>
+                <RowDefinition/>
+                <RowDefinition/>
+            </Grid.RowDefinitions>
+            <Grid.ColumnDefinitions>
+                <ColumnDefinition Width="2*"/>
+                <ColumnDefinition Width="*"/>
+                <ColumnDefinition Width="*"/>
+                <ColumnDefinition Width="*"/>
+            </Grid.ColumnDefinitions>
+            <TextBlock  Text="RF Box"  Grid.ColumnSpan="4" FontSize="15" VerticalAlignment="Center"  HorizontalAlignment="Center"/>
+
+
+            <TextBlock Grid.Row="1" Text="Set C1(%)"     FontSize="15" VerticalAlignment="Center" HorizontalAlignment="Left" Padding="10,0,0,0"/>
+            <TextBlock Grid.Row="1" Grid.Column="2" Width="Auto" Height="Auto" Text="{Binding SRFData.ForwardPower,StringFormat='F1'}"  Background="#E8E8E8" TextBlock.TextAlignment="Center" VerticalAlignment="Center" Block.TextAlignment="Center"/>
+            <TextBox   Grid.Row="1" Grid.Column="1" Width="Auto" Height="Auto" Text="{Binding SRFFwdPowerSetpoint,UpdateSourceTrigger=PropertyChanged}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"    BorderThickness="0" />
+            <Button    Grid.Row="1" Grid.Column="3" Margin="5,0,5,0" Height="20"   Style="{x:Null}" Content="Set"             Command="{Binding SetChillerTempCommand}"    IsEnabled="{Binding IsAutoMode,Converter={StaticResource BoolToBool}}" Cursor="Hand"/>
+
+
+            <TextBlock Grid.Row="2" Text="Work Mode"     FontSize="15" VerticalAlignment="Center" HorizontalAlignment="Left" Padding="10,0,0,0"/>
+            <TextBlock Grid.Row="2" Grid.Column="1" Width="Auto" Height="Auto" Text="{Binding SRFData.ReflectPower,StringFormat='F1'}"  Background="#E8E8E8" TextBlock.TextAlignment="Center" VerticalAlignment="Center" Block.TextAlignment="Center" Grid.ColumnSpan="3"/>
+           
+            <TextBlock Grid.Row="3" Text="VPP" FontSize="15" VerticalAlignment="Center" HorizontalAlignment="Left" Padding="10,0,0,0"/>
+            <TextBlock Grid.Row="3" Grid.Column="1" Width="Auto" Height="Auto" Text="{Binding MatchC1,StringFormat='F1'}" Background="#E8E8E8" TextBlock.TextAlignment="Center" VerticalAlignment="Center" Block.TextAlignment="Center" Grid.ColumnSpan="3"/>
+
+            <TextBlock Grid.Row="4" Text="DC Bias" FontSize="15" VerticalAlignment="Center" HorizontalAlignment="Left" Padding="10,0,0,0"/>
+            <TextBlock Grid.Row="4" Grid.Column="1" Width="Auto" Height="Auto" Text="{Binding MatchC1,StringFormat='F1'}" Background="#E8E8E8" TextBlock.TextAlignment="Center" VerticalAlignment="Center" Block.TextAlignment="Center" Grid.ColumnSpan="3"/>
 
         </Grid>
+        
         <Ellipse Width="20" Height="20" Fill="{Binding SRFData.IsRfOn,Converter={StaticResource boolToColor}}"  Canvas.Left="500" Canvas.Top="375" Stroke="Silver" StrokeThickness="2"/>
         <Button Height="20" Width="100" Content="RF ON/OFF" Canvas.Left="530" Canvas.Top="375" Command="{Binding SetSRfCommand}"  Style="{StaticResource SysBtnStyle}"  IsEnabled="{Binding IsAutoMode,Converter={StaticResource BoolToBool}}"/>
 

+ 6 - 1
Venus/Venus_MainPages/Views/ProcessHistoryView.xaml

@@ -171,7 +171,12 @@
                 <RowDefinition Height="20"></RowDefinition>
                 <RowDefinition Height="*"></RowDefinition>
             </Grid.RowDefinitions>
-            <Button Grid.Row="0" Content="导出数据" FontSize="10" Height="18" Margin="0,5,12,0"  x:Name="ButtonExportData" IsEnabled="True"  VerticalAlignment="Top" HorizontalAlignment="Right" Width="106"  Click="buttonLotDetailsExport_Click"  />
+            <Canvas >
+                <CheckBox    HorizontalAlignment="Center" FontSize="20" Padding="4,-4,0,0" Canvas.Top="8" Canvas.Left="400" Content="AutoX Zoom"     x:Name="AutoXCheckBox"/>
+                <CheckBox    HorizontalAlignment="Center" FontSize="20" Padding="4,-4,0,0" Canvas.Top="8" Canvas.Left="600" Content="AutoY Zoom"     x:Name="AutoYCheckBox"/>
+                <CheckBox    HorizontalAlignment="Center" FontSize="20" Padding="4,-4,0,0" Canvas.Top="8" Canvas.Left="800" Content="Show Step"      IsChecked="{Binding IsShowStep}"/>
+                <Button Grid.Row="0" Content="导出数据" FontSize="10" Height="18" Canvas.Top="5" Canvas.Right="12"  x:Name="ButtonExportData" IsEnabled="True"  VerticalAlignment="Top" HorizontalAlignment="Right" Width="106"  Click="buttonLotDetailsExport_Click"  />
+            </Canvas>
             <Grid Grid.Row="1" Margin="10,5,10,5">
                 <Grid.ColumnDefinitions>
                     <ColumnDefinition Width="350*"/>

File diff suppressed because it is too large
+ 10 - 5
Venus/Venus_MainPages/Views/TMView.xaml


BIN
Venus/Venus_RT/Config/PM/Kepler2200A/Kepler2200ADeviceModel.xml


BIN
Venus/Venus_RT/Config/PM/Kepler2200B/Kepler2200BDeviceModel.xml


+ 2 - 2
Venus/Venus_RT/Config/PM/Kepler2200B/Kepler2200BIoDefine.xml

@@ -9,8 +9,8 @@
 		<DI_ITEM Index="2" Name="DI_VAC_Switch" Device="" Addr="w20.02" />
 		<DI_ITEM Index="3" Name="" />
 		<DI_ITEM Index="4" Name="DI_Water_Leak_Sensor" Device="" Addr="w20.04" />
-		<DI_ITEM Index="5" Name="" Device="" Addr="w20.05" />
-		<DI_ITEM Index="6" Name="" Device="" Addr="w20.06" />
+		<DI_ITEM Index="5" Name="" Device="" Addr="w20.05"/>
+		<DI_ITEM Index="6" Name="DI_RF_Box_Interlock" Device="" Addr="w20.06" />
 		<DI_ITEM Index="7" Name="DI_Source_RF_Generator_Interlock" Device="" Addr="w20.07" />
 		<DI_ITEM Index="8" Name="DI_Source_RF_Match_Interlock" Device="" Addr="w20.08" />
 		<DI_ITEM Index="9" Name="DI_Turbo_Pump_Interlock" Device="" Addr="w20.09" />

+ 28 - 0
Venus/Venus_RT/Config/System_Kepler2200.sccfg

@@ -451,6 +451,13 @@
 			<!--<config default="10" name="MatchPositionC1" nameView="CycleCount" description="" max="100" min="0" paramter="" tag="" unit="" type="Double" />
       <config default="10" name="MatchPositionC2" nameView="CycleCount" description="" max="100" min="0" paramter="" tag="" unit="" type="Double" />-->
 		</configs>
+		<configs name="RFBox" nameView="RF Box" >
+			<config default="false" name="EnableMatch" nameView="Enable Source Match" description="enable match or not" max="1" min="0" tag="" unit="" type="Bool" />
+			<config default="1" name="MFG" nameView="MFG" description="厂商, 1:AdTec; 2:Comet; 3:Revtech" max="10" min="0" paramter="" tag="" unit="" type="Integer" />
+			<config default="1" name="CommunicationType" nameView="Communication Type" description="0:Analogue; 1:RS232; 2:Ethernet" max="10" min="0" paramter="" tag="" unit="" type="Integer" />
+			<config default="COM40" name="Port" nameView="Port" description="serial port name of match" max="" min="" paramter="" tag="" unit="" type="String" />
+			<config default="192.168.10.21:502" name="IPAddress" nameView="IP Address" description="Match IP,default 127.0.0.1:502" max="" min="" paramter="" tag="" unit="" type="String" />
+		</configs>
 		<configs name="MfcGas1" nameView="MFC Gas1" >
 			<config default="true" name="Enable" nameView="Enable" description="Enable gas 1 or not" tag="" unit="" type="Bool" />
 			<config default="O2" name="GasName" nameView="Gas Name" description="Name of NO.1 gas stick" tag="" unit="" type="String" />
@@ -813,6 +820,13 @@
 			<!--<config default="10" name="MatchPositionC1" nameView="CycleCount" description="" max="100" min="0" paramter="" tag="" unit="" type="Double" />
       <config default="10" name="MatchPositionC2" nameView="CycleCount" description="" max="100" min="0" paramter="" tag="" unit="" type="Double" />-->
 		</configs>
+		<configs name="RFBox" nameView="RF Box" >
+			<config default="false" name="EnableMatch" nameView="Enable Source Match" description="enable match or not" max="1" min="0" tag="" unit="" type="Bool" />
+			<config default="1" name="MFG" nameView="MFG" description="厂商, 1:AdTec; 2:Comet; 3:Revtech" max="10" min="0" paramter="" tag="" unit="" type="Integer" />
+			<config default="1" name="CommunicationType" nameView="Communication Type" description="0:Analogue; 1:RS232; 2:Ethernet" max="10" min="0" paramter="" tag="" unit="" type="Integer" />
+			<config default="COM40" name="Port" nameView="Port" description="serial port name of match" max="" min="" paramter="" tag="" unit="" type="String" />
+			<config default="192.168.10.21:502" name="IPAddress" nameView="IP Address" description="Match IP,default 127.0.0.1:502" max="" min="" paramter="" tag="" unit="" type="String" />
+		</configs>
 		<configs name="MfcGas1" nameView="MFC Gas1" >
 			<config default="true" name="Enable" nameView="Enable" description="Enable gas 1 or not" tag="" unit="" type="Bool" />
 			<config default="O2" name="GasName" nameView="Gas Name" description="Name of NO.1 gas stick" tag="" unit="" type="String" />
@@ -1176,6 +1190,13 @@
 			<!--<config default="10" name="MatchPositionC1" nameView="CycleCount" description="" max="100" min="0" paramter="" tag="" unit="" type="Double" />
       <config default="10" name="MatchPositionC2" nameView="CycleCount" description="" max="100" min="0" paramter="" tag="" unit="" type="Double" />-->
 		</configs>
+		<configs name="RFBox" nameView="RF Box" >
+			<config default="false" name="EnableMatch" nameView="Enable Source Match" description="enable match or not" max="1" min="0" tag="" unit="" type="Bool" />
+			<config default="1" name="MFG" nameView="MFG" description="厂商, 1:AdTec; 2:Comet; 3:Revtech" max="10" min="0" paramter="" tag="" unit="" type="Integer" />
+			<config default="1" name="CommunicationType" nameView="Communication Type" description="0:Analogue; 1:RS232; 2:Ethernet" max="10" min="0" paramter="" tag="" unit="" type="Integer" />
+			<config default="COM40" name="Port" nameView="Port" description="serial port name of match" max="" min="" paramter="" tag="" unit="" type="String" />
+			<config default="192.168.10.21:502" name="IPAddress" nameView="IP Address" description="Match IP,default 127.0.0.1:502" max="" min="" paramter="" tag="" unit="" type="String" />
+		</configs>
 		<configs name="MfcGas1" nameView="MFC Gas1" >
 			<config default="true" name="Enable" nameView="Enable" description="Enable gas 1 or not" tag="" unit="" type="Bool" />
 			<config default="O2" name="GasName" nameView="Gas Name" description="Name of NO.1 gas stick" tag="" unit="" type="String" />
@@ -1539,6 +1560,13 @@
 			<!--<config default="10" name="MatchPositionC1" nameView="CycleCount" description="" max="100" min="0" paramter="" tag="" unit="" type="Double" />
       <config default="10" name="MatchPositionC2" nameView="CycleCount" description="" max="100" min="0" paramter="" tag="" unit="" type="Double" />-->
 		</configs>
+		<configs name="RFBox" nameView="RF Box" >
+			<config default="false" name="EnableMatch" nameView="Enable Source Match" description="enable match or not" max="1" min="0" tag="" unit="" type="Bool" />
+			<config default="1" name="MFG" nameView="MFG" description="厂商, 1:AdTec; 2:Comet; 3:Revtech" max="10" min="0" paramter="" tag="" unit="" type="Integer" />
+			<config default="1" name="CommunicationType" nameView="Communication Type" description="0:Analogue; 1:RS232; 2:Ethernet" max="10" min="0" paramter="" tag="" unit="" type="Integer" />
+			<config default="COM40" name="Port" nameView="Port" description="serial port name of match" max="" min="" paramter="" tag="" unit="" type="String" />
+			<config default="192.168.10.21:502" name="IPAddress" nameView="IP Address" description="Match IP,default 127.0.0.1:502" max="" min="" paramter="" tag="" unit="" type="String" />
+		</configs>
 		<configs name="MfcGas1" nameView="MFC Gas1" >
 			<config default="true" name="Enable" nameView="Enable" description="Enable gas 1 or not" tag="" unit="" type="Bool" />
 			<config default="O2" name="GasName" nameView="Gas Name" description="Name of NO.1 gas stick" tag="" unit="" type="String" />

+ 0 - 1
Venus/Venus_RT/Config/TM/TMInterlock.xml

@@ -123,7 +123,6 @@
 
 	<Action do="DO_LLB_Slit_Door_E_Open"					value="true" tip="LLB Slit Door/I Open"		tip.zh-CN="" tip.en-US="DO-21" >
 		<Limit di="DI_TM_RB_Not_Extend_LLB"			value="true" tip="TM RB Not Extend LLB"		tip.zh-CN="" tip.en-US="DI-09" />
-		<Limit di="DI_EFEM_RB_Not_Extend_LLB"				value="true" tip="EFEM RB Not Extend LLB"			tip.zh-CN="" tip.en-US="DI-12" />
 		<Limit di="DI_EFEM_Side_Door_Closed"				value="true" tip="EFEM Side Panel Closed"			tip.zh-CN="" tip.en-US="DI-13" />
 		<Limit di="DI_CDA_Pressure_Switch"			value="true" tip="CDA Pressure Switch"		tip.zh-CN="" tip.en-US="DI-19" />
 		<Limit di="DI_LLB_T_Slit_Door_close_Position"			value="true" tip="LLB Out Slit Door close Position"		tip.zh-CN="" tip.en-US="DI-30" />

+ 1 - 1
Venus/Venus_RT/Devices/AdTecRF.cs

@@ -725,7 +725,7 @@ namespace Venus_RT.Devices
         //
         public AdTecMatch(ModuleName mod, VenusDevice device) : base(mod.ToString(), device.ToString())
         {
-            var portNum = SC.GetStringValue(device == VenusDevice.Match ? $"{mod}.Match.Port" : $"{mod}.BiasMatch.Port");
+            var portNum = SC.GetStringValue( $"{mod}.{device}.Port");
 
             _serial = new AsyncSerialPort(portNum, 9600, 8);
 

+ 46 - 19
Venus/Venus_RT/Devices/DeviceManager.cs

@@ -28,7 +28,7 @@ namespace Venus_RT.Instances
 
     public class DeviceManager : DeviceManagerBase
     {
-        private  string device_model_file;
+        private string device_model_file;
         private readonly string device_model_file_MF;
         private readonly string device_model_file_SEMF;
 
@@ -38,9 +38,9 @@ namespace Venus_RT.Instances
 
         private bool startEthercatOK;
         public DeviceManager()
-        {           
+        {
 
-            device_model_file_MF = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Config\\","TM", RtInstance.DeviceModelFileName_MF);
+            device_model_file_MF = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Config\\", "TM", RtInstance.DeviceModelFileName_MF);
             device_model_file_SEMF = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Config\\", "TM", RtInstance.DeviceModelFileName_SE);
         }
         public bool InitEthercat()
@@ -126,7 +126,7 @@ namespace Venus_RT.Instances
                     }
                 }
             }
-            
+
 
             if (ModuleHelper.IsInstalled(ModuleName.PMA))
             {
@@ -152,21 +152,21 @@ namespace Venus_RT.Instances
             if (ModuleHelper.IsInstalled(ModuleName.TM))
                 InitTM(ModuleName.TM);
 
-            if(ModuleHelper.IsInstalled(ModuleName.SETM))
+            if (ModuleHelper.IsInstalled(ModuleName.SETM))
             {
                 InitSETM(ModuleName.SETM);
             }
 
             AddCustomModuleDevice(new VenusSignalTower("System", "SignalTower"));
 
-            
+
             OP.Subscribe("DeviceOperation", this.Invoke);
 
             return true;
         }
 
-        private void InitPM(ModuleName mod,JetChamber jetChamber)
-        {         
+        private void InitPM(ModuleName mod, JetChamber jetChamber)
+        {
             device_model_file = PathManager.GetCfgDir() + "PM" + "\\" + jetChamber.ToString() + "\\" + $"{jetChamber.ToString()}DeviceModel.xml";
             Initialize(device_model_file, jetChamber.ToString(), mod, mod.ToString());
 
@@ -176,7 +176,7 @@ namespace Venus_RT.Instances
                 AddCustomModuleDevice(new AdTecGenerator(mod, Venus_Core.VenusDevice.Rf));
             }
 
-                             
+
 
             if (jetChamber == JetChamber.Kepler2300)
             {
@@ -217,10 +217,37 @@ namespace Venus_RT.Instances
                     }
                 }
             }
-            
+
+
+            if (jetChamber == JetChamber.Kepler2200B)
+            {
+                if (SC.GetValue<bool>($"{mod}.RFBox.EnableMatch") &&
+                                   SC.GetValue<int>($"{mod}.RFBox.CommunicationType") == (int)CommunicationType.RS232 &&
+                                   SC.GetValue<int>($"{mod}.RFBox.MFG") == (int)MatchMFG.AdTec)
+                {
+                    AddCustomModuleDevice(new AdTecMatch(mod, Venus_Core.VenusDevice.RFBox));
+                }
+                else if (SC.GetValue<bool>($"{mod}.RFBox.EnableMatch") &&
+                    SC.GetValue<int>($"{mod}.RFBox.CommunicationType") == (int)CommunicationType.RS232 &&
+                    SC.GetValue<int>($"{mod}.RFBox.MFG") == (int)MatchMFG.Revtech)
+                {
+                    AddCustomModuleDevice(new RevtechMatch(mod, Venus_Core.VenusDevice.RFBox, MatchCommunicationType.RS232));
+                }
+                else if (SC.GetValue<bool>($"{mod}.RFBox.EnableMatch") &&
+                    SC.GetValue<int>($"{mod}.RFBox.CommunicationType") == (int)CommunicationType.Ethernet &&
+                    SC.GetValue<int>($"{mod}.RFBox.MFG") == (int)MatchMFG.Revtech)
+                {
+                    AddCustomModuleDevice(new RevtechMatch(mod, Venus_Core.VenusDevice.RFBox, MatchCommunicationType.Ethernet));
+                }
+                else if (SC.GetValue<bool>($"{mod}.RFBox.EnableMatch") &&
+                    SC.GetValue<int>($"{mod}.RFBox.MFG") == (int)MatchMFG.Lz_Ethercat && startEthercatOK)
+                {
+                    AddCustomModuleDevice(new LzMatch_Ethercat(mod, Venus_Core.VenusDevice.RFBox, v_board_id));
+                }
+            }
             if (SC.GetValue<bool>($"{mod}.Match.EnableMatch") &&
-                SC.GetValue<int>($"{mod}.Match.CommunicationType") == (int)CommunicationType.RS232 &&
-                SC.GetValue<int>($"{mod}.Match.MFG") == (int)MatchMFG.AdTec)
+            SC.GetValue<int>($"{mod}.Match.CommunicationType") == (int)CommunicationType.RS232 &&
+            SC.GetValue<int>($"{mod}.Match.MFG") == (int)MatchMFG.AdTec)
             {
                 AddCustomModuleDevice(new AdTecMatch(mod, Venus_Core.VenusDevice.Match));
             }
@@ -231,7 +258,7 @@ namespace Venus_RT.Instances
                 AddCustomModuleDevice(new RevtechMatch(mod, Venus_Core.VenusDevice.Match, MatchCommunicationType.RS232));
             }
             else if (SC.GetValue<bool>($"{mod}.Match.EnableMatch") &&
-                SC.GetValue<int>($"{mod}.Match.CommunicationType") == (int)CommunicationType.Ethernet&&
+                SC.GetValue<int>($"{mod}.Match.CommunicationType") == (int)CommunicationType.Ethernet &&
                 SC.GetValue<int>($"{mod}.Match.MFG") == (int)MatchMFG.Revtech)
             {
                 AddCustomModuleDevice(new RevtechMatch(mod, Venus_Core.VenusDevice.Match, MatchCommunicationType.Ethernet));
@@ -322,13 +349,13 @@ namespace Venus_RT.Instances
                 }
             }
 
-            
+
             AddCustomModuleDevice(new AdixenTurboPump(mod));
             AddCustomModuleDevice(new PendulumValve(mod));
 
-           
-           
-            
+
+
+
 
             switch (jetChamber)
             {
@@ -343,7 +370,7 @@ namespace Venus_RT.Instances
                     break;
                 case JetChamber.Kepler2200B:
                     AddCustomDevice(new JetKepler2200BPM(mod));
-                    break;               
+                    break;
                 case JetChamber.VenusSE:
                     AddCustomDevice(new JetVenusSEPM(mod));
                     break;
@@ -380,7 +407,7 @@ namespace Venus_RT.Instances
                     AddCustomModuleDevice(new EdwardsPump(mod));
                 }
             }
-           
+
             //AddCustomModuleDevice(new SkyPump(mod));
             //AddCustomModuleDevice(new SkyPump(ModuleName.LLA));
 

+ 6 - 1
Venus/Venus_RT/Devices/IODevices/IoGasStick.cs

@@ -10,6 +10,8 @@ namespace Venus_RT.Devices
     class IoGasStick : BaseDevice, IDevice
     {
         private readonly IoValve _DownValve;
+        private readonly IoValve _UpValve;
+
         public readonly MfcBase1 _mfc;
 
         // Properties
@@ -32,6 +34,7 @@ namespace Venus_RT.Devices
             base.DeviceID = node.GetAttribute("schematicId");
 
             _DownValve    = ParseDeviceNode<IoValve>(Module, "downvalve", node);
+            _UpValve = ParseDeviceNode<IoValve>(Module, "upvalve", node);
             _mfc          = ParseDeviceNode<MfcBase1>(Module, "mfc", node);
         }
 
@@ -52,11 +55,13 @@ namespace Venus_RT.Devices
             if (setpoint >= 0.01)
             {
                 _DownValve.TurnValve(true, out _);
-                //this.FlowSP = setpoint;
+                _UpValve?.TurnValve(true, out _);
             }
             else
             {
                 _DownValve.TurnValve(false, out _);
+                _UpValve?.TurnValve(false, out _);
+
             }
             _mfc.Ramp(setpoint, 1000);
         }

+ 15 - 14
Venus/Venus_RT/Devices/JetKepler2200BPM.cs

@@ -86,7 +86,7 @@ namespace Venus_RT.Devices
         private readonly RfMatchBase _Match;
 
         //private readonly RfPowerBase _GeneratorBias;//brf=>CometRF
-        //private readonly RfMatchBase _BiasMatch;
+        private readonly RfMatchBase _BiasMatch;
 
         //private readonly IoSignalTower _SignalTower;
 
@@ -205,7 +205,7 @@ namespace Venus_RT.Devices
         //public override bool BackSideHeOutOfRange => _backsideHe.OutOfRange;
         public override float RFMatchC1 => _Match != null ? _Match.TunePosition1 : 0;
         public override float RFMatchC2 => _Match != null ? _Match.TunePosition2 : 0;
-        //public override float BiasRFMatchC1 => _BiasMatch != null ? _BiasMatch.TunePosition1 : 0;
+        public override float BiasRFMatchC1 => _BiasMatch != null ? _BiasMatch.TunePosition1 : 0;
         //public override float BiasRFMatchC2 => _BiasMatch != null ? _BiasMatch.TunePosition1 : 0;
         public override double MFC1FeedBack => DEVICE.GetDevice<IoMfc>($"{Module}.MfcGas1").FeedBack;
         public override double MFC2FeedBack => DEVICE.GetDevice<IoMfc>($"{Module}.MfcGas2").FeedBack;
@@ -435,17 +435,18 @@ namespace Venus_RT.Devices
             }
 
             _GasRFStopWatch.Stop();
-            //if (SC.GetValue<bool>($"{Module}.BiasMatch.EnableBiasMatch") &&
-            //    SC.GetValue<int>($"{Module}.BiasMatch.CommunicationType") == (int)CommunicationType.RS232 &&
-            //    SC.GetValue<int>($"{Module}.BiasMatch.MFG") == (int)MatchMFG.AdTec)
-            //{
-            //    _BiasMatch = DEVICE.GetDevice<AdTecMatch>($"{Module}.{VenusDevice.BiasMatch}");
-            //}
-            //else if (SC.GetValue<bool>($"{Module}.BiasMatch.EnableBiasMatch") &&
-            //    SC.GetValue<int>($"{Module}.BiasMatch.MFG") == (int)MatchMFG.Revtech)
-            //{
-            //    _BiasMatch = DEVICE.GetDevice<RevtechMatch>($"{Module}.{VenusDevice.BiasMatch}");
-            //}
+
+            if (SC.GetValue<bool>($"{Module}.RFBox.EnableMatch") &&
+                SC.GetValue<int>($"{Module}.RFBox.CommunicationType") == (int)CommunicationType.RS232 &&
+                SC.GetValue<int>($"{Module}.RFBox.MFG") == (int)MatchMFG.AdTec)
+            {
+                _BiasMatch = DEVICE.GetDevice<AdTecMatch>($"{Module}.{VenusDevice.RFBox}");
+            }
+            else if (SC.GetValue<bool>($"{Module}.RFBox.EnableMatch") &&
+                SC.GetValue<int>($"{Module}.RFBox.MFG") == (int)MatchMFG.Revtech)
+            {
+                _BiasMatch = DEVICE.GetDevice<RevtechMatch>($"{Module}.{VenusDevice.RFBox}");
+            }
 
             _foreline_interlock_pressure = SC.GetValue<double>($"{Module}.ForelineInterlockPressure");
             //_PressureType = (PressureType)SC.GetValue<int>("System.PressureUnitType");
@@ -938,7 +939,7 @@ namespace Venus_RT.Devices
         {
             OpenValve(ValveType.N2, false);
             OpenValve(ValveType.PVN22, false);
-            await Task.Delay(1000);
+            await Task.Delay(500);
             OpenValve(ValveType.Purge, false);
             return true;
         }

+ 15 - 1
Venus/Venus_RT/Devices/JetVenusPM.cs

@@ -859,6 +859,13 @@ namespace Venus_RT.Devices
         {
             if (_Generator == null) return false;
 
+            if (on == _Generator.IsPowerOn)
+            {
+                string operation = on ? "Open" : "Close";
+                LOG.Write(eEvent.WARN_RF, Module, $" RF 已经 {operation},不可重复{operation}");
+                return true;
+            }
+
             if (on && !IsRFGInterlockOn)
             {
                 LOG.Write(eEvent.ERR_RF, Module, "射频电源 Interlock条件不满足");
@@ -881,9 +888,16 @@ namespace Venus_RT.Devices
         {
             if (_GeneratorBias == null) return false;
 
+            if (on == _GeneratorBias.IsPowerOn)
+            {
+                string operation=on ? "Open" : "Close";
+                LOG.Write(eEvent.WARN_RF, Module, $"Bias RF 已经 {operation},不可重复{operation}");
+                return true;
+            }
+
             if (on && !IsRFGInterlockOn)
             {
-                LOG.Write(eEvent.ERR_RF, Module, "Bias射频电源 Interlock条件不满足");
+                LOG.Write(eEvent.ERR_RF, Module, "Bias RF Interlock条件不满足");
                 return false;
             }
 

+ 1 - 1
Venus/Venus_RT/Devices/LzMatch_Ethercat.cs

@@ -17,7 +17,7 @@ namespace Venus_RT.Devices
     {
         //Int32 v_card_name = 0;
         Int32 v_board_id = -1;
-        Int32 v_StartAxisID = 0;
+        //Int32 v_StartAxisID = 0;
         Int32 BUS_No = 0;
         Int32 Mod_ID = 1;
         private readonly VenusDevice _device;

+ 31 - 10
Venus/Venus_RT/Devices/RevtechMatch.cs

@@ -33,6 +33,9 @@ namespace Venus_RT.Devices
         private MatchCommunicationType _matchCommunicationType;
         private string _address;
         public string WorkMode { get; set; } = "";
+
+        public string Vpp { get; set; }
+
         public RevtechMatch(ModuleName mod, VenusDevice venusDevice, MatchCommunicationType matchCommunicationType) : base(mod.ToString(), venusDevice.ToString())
         {
             _matchCommunicationType = matchCommunicationType;
@@ -97,6 +100,9 @@ namespace Venus_RT.Devices
             DATA.Subscribe($"{Module}.{Name}.C1", () => TunePosition1);
             DATA.Subscribe($"{Module}.{Name}.C2", () => TunePosition2);
             DATA.Subscribe($"{Module}.{Name}.WorkMode", () => WorkMode);
+            DATA.Subscribe($"{Module}.{Name}.Vpp", () => Vpp);
+            DATA.Subscribe($"{Module}.{Name}.DCBias", () => DCBias);
+
 
 
 
@@ -140,21 +146,36 @@ namespace Venus_RT.Devices
 
         private void OnDataChanged(byte[] obj)
         {
-            string data = System.Text.Encoding.ASCII.GetString(obj);
+            try 
+            {
+                string data = System.Text.Encoding.ASCII.GetString(obj);
 
 
-            if (data.Length < 10)
-            {
-                return;
-            }
-            string[] matchData = data.Split(',');        
+                if (data.Length < 10 && data.Length > 20)
+                {
+                    return;
+                }
+                string[] matchData = data.Split(',');
 
-            if (matchData.Length > 9)
+                if (matchData.Length > 9)
+                {
+                    if (matchData[0].Contains("MANUAL") || matchData[0].Contains("AUTO"))
+                    {
+                        WorkMode = matchData[0];
+
+                        TunePosition1 = Convert.ToSingle(matchData[8]);
+                        TunePosition2 = Convert.ToSingle(matchData[7]);
+                        Vpp = matchData[12];
+                        DCBias = Convert.ToSingle(matchData[13]);
+                    }
+                    
+                }
+            }
+            catch 
             {
-                WorkMode = matchData[0];
-                TunePosition1 = Convert.ToSingle(matchData[7]);
-                TunePosition2 = Convert.ToSingle(matchData[8]);
+            
             }
+            
         }
         private void RevtechMatch_sendDataChangedEvent(string obj)
         {

+ 10 - 1
Venus/Venus_RT/Devices/TruPlasmaRF_Ethercat.cs

@@ -1,5 +1,6 @@
 using Aitex.Core.Common.DeviceData;
 using Aitex.Core.RT.DataCenter;
+using Aitex.Core.RT.Device;
 using Aitex.Core.RT.Log;
 using Aitex.Core.RT.OperationCenter;
 using MECF.Framework.Common.Device.Bases;
@@ -15,12 +16,13 @@ namespace Venus_RT.Devices
     {
         //Int32 v_card_name = 0;
         Int32 v_board_id = -1;
-        Int32 v_StartAxisID = 0;
+        //Int32 v_StartAxisID = 0;
         Int32 BUS_No = 0;
         Int32 Mod_ID = 0;
 
         private readonly VenusDevice _device;
         private Stopwatch _stopWatch = new Stopwatch();
+        private JetPMBase _chamber;
 
 
 
@@ -41,6 +43,7 @@ namespace Venus_RT.Devices
             _device = device;
             v_board_id = board_id;
             _stopWatch.Start();
+            _chamber = DEVICE.GetDevice<JetPMBase>(Module);
         }
 
         public override bool Initialize()
@@ -71,6 +74,11 @@ namespace Venus_RT.Devices
                 ForwardPower = GetPower();
                 ReflectPower=GetReflectPower();
                 _stopWatch.Restart();
+
+                if (IsPowerOn == true && _chamber != null && _chamber.RFInterlock(_device) == false)
+                {
+                    SetPowerOnOff(false, out _);
+                }
             }
         }
 
@@ -144,6 +152,7 @@ namespace Venus_RT.Devices
             }
             else
             {
+                PowerSetPoint = val;
                 LOG.Write(eEvent.EV_DEVICE_INFO, Module, $"{_device} Set Power Setpoint {val} Success!");
             }
         }

+ 1 - 1
Venus/Venus_RT/Instances/ToolLoader.cs

@@ -96,7 +96,7 @@ namespace Venus_RT.Instances
             string s1 = System.Diagnostics.FileVersionInfo.GetVersionInfo(Path.Combine(PathManager.GetAppDir(), "Venus_RT.exe")).ProductVersion;
 
             DATA.Subscribe("GetRTPath", () => AppDomain.CurrentDomain.BaseDirectory);
-            DATA.Subscribe("System.PressureUnitType", () => (int)RtInstance.pressureType);
+            DATA.Subscribe("System.PressureUnitType", () => (int)RtInstance.pressureType,SubscriptionAttribute.FLAG.IgnoreSaveDB);
 
 
             Singleton<ResourceMonitor>.Instance.Initialize();

+ 6 - 1
Venus/Venus_RT/Modules/PMs/GasBoxLeakCheckRoutine.cs

@@ -73,11 +73,16 @@ namespace Venus_RT.Modules.PMs
                 //var lineNums = SC.GetStringValue($"{Module}.Pump.LeakCheckGasLineNums").Split(',');
                 var lineNums = objs[3].ToString().Split(',');
                 int nNum;
+                int allGas=8;
+                if (_chamber.ChamberType == JetChamber.Kepler2200A || _chamber.ChamberType == JetChamber.Kepler2200B)
+                {
+                    allGas = 6;
+                }
                 foreach(string num in lineNums)
                 {
                     if(int.TryParse(num, out nNum))
                     {
-                        if(nNum > 0 && nNum <= 8 && !_gasLineNums.Contains(nNum))
+                        if(nNum > 0 && nNum <= allGas && !_gasLineNums.Contains(nNum))
                         {
                             _gasLineNums.Add(nNum);
                         }

+ 11 - 13
Venus/Venus_RT/Modules/PMs/PMProcessRoutine.cs

@@ -10,7 +10,6 @@ using MECF.Framework.Common.SubstrateTrackings;
 using Venus_Core;
 using System.Diagnostics;
 using MECF.Framework.Common.DBCore;
-using Venus_Unity;
 using System.Threading.Tasks;
 using Aitex.Core.RT.Event;
 
@@ -21,7 +20,7 @@ namespace Venus_RT.Modules.PMs
         private enum ProcessStep
         {
             PreparePressure,
-            PrepareTemperature,                      
+            PrepareTemperature,
             RunChuckRecipe,
             RunProcessRecipe,
             RunDechuckRecipe,
@@ -73,15 +72,15 @@ namespace Venus_RT.Modules.PMs
         private bool needdechuck;
         private bool needchuck;
         private bool needclean;
-        private double ChillerTemp
+        private double BaseTemperature
         {
             get
             {
                 if (ProcessRecipeHead != null)
                 {
-                    if (!string.IsNullOrEmpty(ProcessRecipeHead.ChillerTemp))
+                    if (!string.IsNullOrEmpty(ProcessRecipeHead.BaseTemperature))
                     {
-                        double setpoint = Convert.ToDouble(ProcessRecipeHead.ChillerTemp);
+                        double setpoint = Convert.ToDouble(ProcessRecipeHead.BaseTemperature);
                         if (setpoint > 0 && setpoint < 600)
                             return setpoint;
                     }
@@ -282,7 +281,7 @@ namespace Venus_RT.Modules.PMs
             {
                 _tolerance = SC.GetValue<double>($"System.MaxTemperatureToleranceToTarget");
                 _OffsetTemp = SC.GetValue<double>($"{Module}.Chiller.ChillerTemperatureOffset");
-            }      
+            }
             _faCallback.RecipeStart(_chamber.Module.ToString(), recipeName);
             WaferManager.Instance.UpdateWaferProcessStatus(Module, 0, EnumWaferProcessStatus.InProcess);
             return Runner.Start(Module, Name);
@@ -291,7 +290,7 @@ namespace Venus_RT.Modules.PMs
         {
             Runner
                   .Run(ProcessStep.PreparePressure, PreparePressure, IsPressureReady)
-                  .Run(ProcessStep.PrepareTemperature, PrepareTemp, IsTempReady)                  
+                  .Run(ProcessStep.PrepareTemperature, PrepareTemp, IsTempReady)
                   .RunIf(ProcessStep.RunChuckRecipe, needchuck, StartChuckRecipe, CheckRecipeDone, 5 * 60 * 60 * 1000)
                   .RunIf(ProcessStep.RunProcessRecipe, needprocess, StartProcessRecipe, CheckRecipeDone, 5 * 60 * 60 * 1000)
                   .RunIf(ProcessStep.RunDechuckRecipe, needdechuck, StartDechuckRecipe, CheckRecipeDone, 5 * 60 * 60 * 1000)
@@ -338,7 +337,7 @@ namespace Venus_RT.Modules.PMs
         {
             if (_jetChamber == JetChamber.Venus)
             {
-                return SetCoolantTemp(ChillerTemp, _OffsetTemp);
+                return SetCoolantTemp(BaseTemperature, _OffsetTemp);
             }
             else
             {
@@ -350,7 +349,7 @@ namespace Venus_RT.Modules.PMs
         {
             if (_jetChamber == JetChamber.Venus)
             {
-                return CheckCoolantTemp(ChillerTemp, _tolerance);
+                return CheckCoolantTemp(BaseTemperature, _tolerance);
             }
             else
             {
@@ -416,7 +415,7 @@ namespace Venus_RT.Modules.PMs
         private bool StartChuckRecipe()
         {
             return startRecipe(ChuckRecipe);
-        }       
+        }
         private bool StartDechuckRecipe()
         {
             return startRecipe(DechuckRecipe);
@@ -574,13 +573,12 @@ namespace Venus_RT.Modules.PMs
 
         public async void Abort()
         {
-            if (_currentRecipe!=null) 
+            if (_currentRecipe != null)
             {
                 RecipeDone("Abort");
-            }            
+            }
             _chamber.GeneratorBiasPowerOn(false);
             _chamber.GeneratorPowerOn(false);
-            //_chamber.TurnPendulumValve(false);
             CloseAllValves();
             _chamber.OpenValve(ValveType.TurboPumpPumping, true);
             _chamber.OpenValve(ValveType.TurboPumpPurge, true);

+ 26 - 2
Venus/Venus_RT/Modules/PMs/ProcessDefine.cs

@@ -94,6 +94,10 @@ namespace Venus_RT.Modules.PMs
             startHelper[$"{Module}.HeaterUnit"] = (ProcessUnitBase unit, RecipeStep step) => HeaterUnit_Start(unit, step);
             checkerHelper[$"{Module}.HeaterUnit"] = (ProcessUnitBase unit, RecipeStep step) => HeaterUnit_Check(unit, step);
             endHelper[$"{Module}.HeaterUnit"] = (ProcessUnitBase unit, RecipeStep step) => HeaterUnit_End(unit, step);
+
+            startHelper[$"{Module}.RFBoxUnit"] = (ProcessUnitBase unit, RecipeStep step) => RFBoxUnit_Start(unit, step);
+            checkerHelper[$"{Module}.RFBoxUnit"] = (ProcessUnitBase unit, RecipeStep step) => RFBoxUnit_Check(unit, step);
+            endHelper[$"{Module}.RFBoxUnit"] = (ProcessUnitBase unit, RecipeStep step) => RFBoxUnit_End(unit, step);
         }
 
         private RState PressureByPressureModeUnit_Start(ProcessUnitBase unit, RecipeStep step)
@@ -350,6 +354,11 @@ namespace Venus_RT.Modules.PMs
                     Chamber.GeneratorBiasSetpower(ProcessUnit.BiasRFPower);
                 }
             }
+            else
+            {
+                Chamber.GeneratorBiasPowerOn(false);
+                Chamber.GeneratorBiasSetpower(0);
+            }
 
 
             if (ProcessUnit.BiasMatchWorkMode == MatchWorkMode.Auto)
@@ -433,8 +442,8 @@ namespace Venus_RT.Modules.PMs
         private void BiasUnit_End(ProcessUnitBase unit, RecipeStep step)
         {
             var ProcessUnit = unit as BiasUnit;
-            Chamber.GeneratorBiasSetpower(0);
-            Chamber.GeneratorBiasPowerOn(false);
+            //Chamber.GeneratorBiasSetpower(0);
+            //Chamber.GeneratorBiasPowerOn(false);
             if (biasRfMatchC1.Count >= 6)
             {
                 float allValue = 0;
@@ -795,6 +804,21 @@ namespace Venus_RT.Modules.PMs
 
 
 
+        private RState RFBoxUnit_Start(ProcessUnitBase unit, RecipeStep step)
+        {
+            return RState.Running;
+        }
+
+        private RState RFBoxUnit_Check(ProcessUnitBase unit, RecipeStep step)
+        {
+            return RState.Running;
+        }
+
+        private void RFBoxUnit_End(ProcessUnitBase unit, RecipeStep step)
+        {
+
+        }
+
         private RState HeaterUnit_Start(ProcessUnitBase unit, RecipeStep step)
         {
             var ProcessUnit = unit as HeaterUnit;

+ 16 - 16
Venus/Venus_RT/Modules/PMs/PumpDownRoutine.cs

@@ -68,25 +68,25 @@ namespace Venus_RT.Modules.PMs
         public RState Monitor()
         {
 
-            Runner.Delay(PumpStep.kDelay_2s,            _delay_2s)
-                .Run(PumpStep.kCloseISOValve,           HOFs.WrapAction(_chamber.OpenValve, ValveType.TurboPumpPumping, false),     _delay_2s)
-                .Run(PumpStep.kSoftPump,                HOFs.WrapAction(_chamber.OpenValve, ValveType.SoftPump, true),              () => { return _chamber.ChamberPressure < _roughPumpPressure; })
-                .Run(PumpStep.kFastPump,                OpenFastPump,       () => { return _chamber.ChamberPressure < _vHe2FlowPressure; })
-                .Run(PumpStep.kPVHe2,                   OpenHe2Valve,           _delay_2s)
-                .Run(PumpStep.kISOValve,                OpenISOValve,           _delay_2s)
-                .Run(PumpStep.kVATValve,                OpenVATValve,           _delay_5s)
-                .Run(PumpStep.kOpenTurboPumpPurgeGasFinal, () => 
-                {
-                    _chamber.OpenValve(ValveType.TurboPumpPurge, true);
-                    _chamber.OpenValve(ValveType.GasFinal, true);
-                    return true;
-                }, 3000)
-                .Run(PumpStep.kFinalStep,               FinalStep,                                                              () => { return _chamber.ChamberPressure < _basePressure; })
-                .End(PumpStep.kEnd,                     NullFun,                                                                _delay_1s);
+            Runner.Delay(PumpStep.kDelay_2s,                _delay_2s)
+                .Run(PumpStep.kCloseISOValve,               HOFs.WrapAction(_chamber.OpenValve, ValveType.TurboPumpPumping, false),     _delay_2s)
+                .Run(PumpStep.kSoftPump,                    HOFs.WrapAction(_chamber.OpenValve, ValveType.SoftPump, true),              () => { return _chamber.ChamberPressure < _roughPumpPressure; })
+                .Run(PumpStep.kFastPump,                    OpenFastPump,       () => { return _chamber.ChamberPressure < _vHe2FlowPressure; })
+                .Run(PumpStep.kPVHe2,                       OpenHe2Valve,           _delay_2s)
+                .Run(PumpStep.kISOValve,                    OpenISOValve,           _delay_2s)
+                .Run(PumpStep.kVATValve,                    OpenVATValve,           _delay_5s)
+                .Run(PumpStep.kOpenTurboPumpPurgeGasFinal,  OpenTurboPumpPurgeGasFinalValve, _delay_3s)
+                .Run(PumpStep.kFinalStep,                   FinalStep,                                                              () => { return _chamber.ChamberPressure < _basePressure; })
+                .End(PumpStep.kEnd,                         NullFun,                                                                _delay_1s);
 
             return Runner.Status;
         }
-
+        private bool OpenTurboPumpPurgeGasFinalValve()
+        {
+            _chamber.OpenValve(ValveType.TurboPumpPurge, true);
+            _chamber.OpenValve(ValveType.GasFinal, true);
+            return true;
+        }
         private bool OpenFastPump()
         {
             _chamber.OpenValve(ValveType.SoftPump, false);

+ 99 - 99
Venus/Venus_RT/Modules/TM/MFControlPressureRoutine.cs

@@ -1,114 +1,114 @@
-using Aitex.Core.RT.Routine;
-using Aitex.Core.RT.SCCore;
-using MECF.Framework.Common.Equipment;
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Venus_Core;
-using Venus_RT.Devices;
-using Venus_RT.Modules.PMs;
+//using Aitex.Core.RT.Routine;
+//using Aitex.Core.RT.SCCore;
+//using MECF.Framework.Common.Equipment;
+//using System;
+//using System.Collections.Generic;
+//using System.Linq;
+//using System.Text;
+//using System.Threading.Tasks;
+//using Venus_Core;
+//using Venus_RT.Devices;
+//using Venus_RT.Modules.PMs;
 
-namespace Venus_RT.Modules.TM
-{
+//namespace Venus_RT.Modules.TM
+//{
    
-    class MFControlPressureRoutine : ModuleRoutineBase, IRoutine
-    {
-        private enum ControlPressureStep
-        {
-            PumpDown,
-            Delay1s,
-            StartControlPressure,
-            End
-        }
+//    class MFControlPressureRoutine : ModuleRoutineBase, IRoutine
+//    {
+//        private enum ControlPressureStep
+//        {
+//            PumpDown,
+//            Delay1s,
+//            StartControlPressure,
+//            End
+//        }
 
-        private readonly JetTM _JetTM;
-        private readonly MFPumpRoutine _pumpDownRoutine;
-        private int _controlPressureCheckPoint = 100;
-        private int _controlPressureSetPoint = 90;
-        private int  _controlFlowSetPoint = 90;
+//        private readonly JetTM _JetTM;
+//        private readonly MFPumpRoutine _pumpDownRoutine;
+//        private int _controlPressureCheckPoint = 100;
+//        private int _controlPressureSetPoint = 90;
+//        private int  _controlFlowSetPoint = 90;
 
-        public MFControlPressureRoutine(JetTM jetTM, MFPumpRoutine pumpDownRoutine) : base(ModuleName.TM)
-        {
-            _JetTM = jetTM;
-            _pumpDownRoutine = pumpDownRoutine;
-        }
-        public RState Start(params object[] objs)
-        {
-            _controlPressureCheckPoint= SC.GetValue<int>($"TM.ControlPressureCheckPoint");
-            _controlPressureSetPoint= SC.GetValue<int>($"TM.ControlPressureSetPoint");
-            _controlFlowSetPoint= SC.GetValue<int>($"TM.TM_MFC1.DefaultSetPoint");
-            return Runner.Start(Module, Name);
-        }
+//        public MFControlPressureRoutine(JetTM jetTM, MFPumpRoutine pumpDownRoutine) : base(ModuleName.TM)
+//        {
+//            _JetTM = jetTM;
+//            _pumpDownRoutine = pumpDownRoutine;
+//        }
+//        public RState Start(params object[] objs)
+//        {
+//            _controlPressureCheckPoint= SC.GetValue<int>($"TM.ControlPressureCheckPoint");
+//            _controlPressureSetPoint= SC.GetValue<int>($"TM.ControlPressureSetPoint");
+//            _controlFlowSetPoint= SC.GetValue<int>($"TM.TM_MFC1.DefaultSetPoint");
+//            return Runner.Start(Module, Name);
+//        }
 
-        public RState Monitor()
-        {
+//        public RState Monitor()
+//        {
 
-            Runner.Run(ControlPressureStep.PumpDown,              PumpingDown,          StopPumpDone)
-                .Delay(ControlPressureStep.Delay1s,               _delay_1s)
-                .Run(ControlPressureStep.StartControlPressure,    StartControlPressure)
+//            Runner.Run(ControlPressureStep.PumpDown,              PumpingDown,          StopPumpDone)
+//                .Delay(ControlPressureStep.Delay1s,               _delay_1s)
+//                .Run(ControlPressureStep.StartControlPressure,    StartControlPressure)
 
-                .End(ControlPressureStep.End,                     End);
-            return Runner.Status;
-        }
+//                .End(ControlPressureStep.End,                     End);
+//            return Runner.Status;
+//        }
 
-        private bool PumpingDown()
-        {
-            return _pumpDownRoutine.Start() == RState.Running;
+//        private bool PumpingDown()
+//        {
+//            return _pumpDownRoutine.Start() == RState.Running;
 
-        }
+//        }
 
-        private bool StopPumpDone()
-        {
-            var status = _pumpDownRoutine.Monitor();
-            if (_JetTM.ChamberPressure <= _controlPressureCheckPoint && status == RState.End)
-            {
-                _JetTM.TurnSoftPumpValve(ModuleName.TM, false);
-                _JetTM.TurnFastPumpValve(ModuleName.TM, false);
-                _JetTM.TurnFastPumpValve(ModuleName.TM,true);
-                return true;
-            }
-            else
-            {
-                return false;
-            }
-        }
+//        private bool StopPumpDone()
+//        {
+//            var status = _pumpDownRoutine.Monitor();
+//            if (_JetTM.ChamberPressure <= _controlPressureCheckPoint && status == RState.End)
+//            {
+//                _JetTM.TurnSoftPumpValve(ModuleName.TM, false);
+//                _JetTM.TurnFastPumpValve(ModuleName.TM, false);
+//                _JetTM.TurnFastPumpValve(ModuleName.TM,true);
+//                return true;
+//            }
+//            else
+//            {
+//                return false;
+//            }
+//        }
 
-        private bool StartControlPressure()
-        {
-            _JetTM.TurnN2Valve(true);
-            _JetTM.TurnPurgeValve(ModuleName.TM, true);
-            if (_JetTM.AllPMSlitDoorClosed)
-            {
-                _JetTM.SwitchTMPressureMode(true);             
-                _JetTM.SetTMPressure(_controlPressureSetPoint);
-            }
-            else
-            {
-                _JetTM.SwitchTMPressureMode(false);
-                _JetTM.SetTMFlow(_controlFlowSetPoint);
-            }
-            return true;
-        }
+//        private bool StartControlPressure()
+//        {
+//            _JetTM.TurnN2Valve(true);
+//            _JetTM.TurnPurgeValve(ModuleName.TM, true);
+//            if (_JetTM.AllPMSlitDoorClosed)
+//            {
+//                _JetTM.SwitchTMPressureMode(true);             
+//                _JetTM.SetTMPressure(_controlPressureSetPoint);
+//            }
+//            else
+//            {
+//                _JetTM.SwitchTMPressureMode(false);
+//                _JetTM.SetTMFlow(_controlFlowSetPoint);
+//            }
+//            return true;
+//        }
 
 
 
-        private bool End()
-        {
+//        private bool End()
+//        {
 
-            return true;
-        }
-        public void Abort()
-        {
-            if(_JetTM != null)
-            {
-                _JetTM.TurnFastPumpValve(ModuleName.TM, false);
-                _JetTM.TurnN2Valve(false);
-                _JetTM.TurnPurgeValve(ModuleName.TM, false);
-                _JetTM.SetTMPressure(0);
-                _JetTM.SetTMFlow(0);
-            }
-        }
-    }
-}
+//            return true;
+//        }
+//        public void Abort()
+//        {
+//            if(_JetTM != null)
+//            {
+//                _JetTM.TurnFastPumpValve(ModuleName.TM, false);
+//                _JetTM.TurnN2Valve(false);
+//                _JetTM.TurnPurgeValve(ModuleName.TM, false);
+//                _JetTM.SetTMPressure(0);
+//                _JetTM.SetTMFlow(0);
+//            }
+//        }
+//    }
+//}

+ 17 - 0
Venus/Venus_RT/Modules/TM/MFPMPickRoutine.cs

@@ -34,6 +34,7 @@ namespace Venus_RT.Modules.TM
         private enum PickStepWithHeater
         {
             WaitPMReady,
+            WaitPressreDifference,
             PMPrepare,
             Picking,   
             QueryAWC,
@@ -53,6 +54,8 @@ namespace Venus_RT.Modules.TM
         private DateTime _starttime;
         private bool _queryAwc;
 
+        double maxPressureDifference ;
+
         public MFPMPickRoutine(JetTM tm, ITransferRobot robot) : base(ModuleName.TMRobot)
         {
             _JetTM = tm;
@@ -63,6 +66,8 @@ namespace Venus_RT.Modules.TM
                 _queryAwc = true;
             else
                 _queryAwc = false;
+
+            maxPressureDifference=SC.GetValue<double>("System.PMTMMaxPressureDifference");
         }
         public RState Start(params object[] objs)
         {
@@ -135,6 +140,7 @@ namespace Venus_RT.Modules.TM
                 case JetChamber.Kepler2200A:
                 case JetChamber.Kepler2200B:
          Runner.Wait(PickStepWithHeater.WaitPMReady,           () => _pmModule.IsIdle, _delay_60s)
+               .Wait(PickStepWithHeater.WaitPressreDifference,   TMPMPressureIsOK, _delay_60s)
                .Run(PickStepWithHeater.PMPrepare,              ModulePrepare,      IsModulePrepareReady)
                .Run(PickStepWithHeater.Picking,                Picking,            WaitPickDone)
                .Run(PickStepWithHeater.QueryAWC,               QueryAWC,           WaitRobotQueryDone)
@@ -147,6 +153,17 @@ namespace Venus_RT.Modules.TM
             return Runner.Status;
         }
 
+        private bool TMPMPressureIsOK()
+        {
+            if (Math.Abs((_pmModule.ChamberPressure - _JetTM.ChamberPressure)) < maxPressureDifference)
+            {
+                return true;
+            }
+            else
+            {
+                return false;
+            }
+        }
         private bool ModulePrepare()
         {
             _pmModule.PostMsg(PMEntity.MSG.PreparePick);

+ 1 - 1
Venus/Venus_Themes/UserControls/DrawGraphicsControl.xaml.cs

@@ -831,7 +831,7 @@ namespace Venus_Themes.UserControls
                                             graphics.DrawEllipse(m_PenBlue, rectangle);
                                             if (IsHorizontalDateTimeAxis)
                                             {
-                                                graphics.DrawString(string.Format("X={0};Y={1}", DateTime.FromOADate(point[index].X), point[index].Y.ToString("0.00")), new Font("Times New Roman", 15.0F), m_BrushXYText, new PointF((float)StartX + 10, (float)StartY + 10));
+                                                graphics.DrawString(string.Format("X={0};Y={1}", DateTime.FromOADate(point[index].X).ToString("yyyy/MM/dd HH:mm:ss:fff"), point[index].Y.ToString("0.00")), new Font("Times New Roman", 15.0F), m_BrushXYText, new PointF((float)StartX + 10, (float)StartY + 10));
                                             }
                                             else
                                             {

+ 1 - 1
Venus/Venus_Themes/UserControls/FlowPipe.xaml

@@ -36,7 +36,7 @@
                                     <DoubleAnimation  Storyboard.TargetProperty="Opacity" Duration="0:0:0.1"  To="0"/>
                                 </Storyboard>
                             </BeginStoryboard>-->
-                            <StopStoryboard BeginStoryboardName="FlowStoryboard" />
+                            <StopStoryboard BeginStoryboardName="FlowStoryboard"/>
                         </DataTrigger.ExitActions>
                     </DataTrigger>
                 </Style.Triggers>