Recipe.cs 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739
  1. using System;
  2. using System.Collections.ObjectModel;
  3. using System.ComponentModel;
  4. using System.Diagnostics;
  5. using System.IO;
  6. using System.Linq;
  7. using Newtonsoft.Json;
  8. using Newtonsoft.Json.Converters;
  9. using Venus_Core.Attributes;
  10. namespace Venus_Core
  11. {
  12. public enum RecipeType
  13. {
  14. Chuck,
  15. DeChuck,
  16. Process,
  17. Clean,
  18. }
  19. public enum StepType
  20. {
  21. Time,
  22. Stable,
  23. EndPoint,
  24. OverEtch,
  25. }
  26. public enum ProcessModule
  27. {
  28. Pressure,
  29. TCP, // Transformer Coupled Plasma (转换耦合等离子)
  30. Bias,
  31. Gas,
  32. ESC,
  33. Process,
  34. Compound,
  35. }
  36. public enum GeneratorMode
  37. {
  38. Pulsing,
  39. CW,
  40. }
  41. public enum PressureUnitMode
  42. {
  43. Pressure,
  44. Valve
  45. }
  46. public enum Suspect
  47. {
  48. Origin,
  49. Position1,
  50. Position2,
  51. Position3
  52. }
  53. public enum TargetMode
  54. {
  55. Step,
  56. Cycle
  57. }
  58. public enum ToleranceMode
  59. {
  60. Value,
  61. Percent
  62. }
  63. public class VenusTolerance
  64. {
  65. }
  66. public class Kepler2300Tolerance
  67. {
  68. public bool EnableTolerance { get; set; }
  69. public ToleranceMode ToleranceMode { get; set; }
  70. public int Gas1ToleranceValue { get; set; }
  71. public int Gas1TolerancePercent { get; set; }
  72. public int Gas2ToleranceValue { get; set; }
  73. public int Gas2TolerancePercent { get; set; }
  74. public int Gas3ToleranceValue { get; set; }
  75. public int Gas3TolerancePercent { get; set; }
  76. public int Gas4ToleranceValue { get; set; }
  77. public int Gas4TolerancePercent { get; set; }
  78. public int Gas5ToleranceValue { get; set; }
  79. public int Gas5TolerancePercent { get; set; }
  80. public int Gas6ToleranceValue { get; set; }
  81. public int Gas6TolerancePercent { get; set; }
  82. public int Gas7ToleranceValue { get; set; }
  83. public int Gas7TolerancePercent { get; set; }
  84. public int Gas8ToleranceValue { get; set; }
  85. public int Gas8TolerancePercent { get; set; }
  86. }
  87. public class RecipeHead : INotifyPropertyChanged
  88. {
  89. private string m_name;
  90. [IsOnlyRead]
  91. public string Name
  92. {
  93. get { return m_name; }
  94. set { m_name = value; InvokePropertyChanged("Name"); }
  95. }
  96. private string _Version = "TestVersion";
  97. public string Version
  98. {
  99. get { return _Version; }
  100. set { _Version = value; InvokePropertyChanged("Version"); }
  101. }
  102. private JetChamber _ChamberType = JetChamber.Venus;
  103. public JetChamber ChamberType
  104. {
  105. get { return _ChamberType; }
  106. set { _ChamberType = value; InvokePropertyChanged("ChamberType"); }
  107. }
  108. private RecipeType m_Type;
  109. [JsonConverter(typeof(StringEnumConverter))]
  110. public RecipeType Type
  111. {
  112. get { return m_Type; }
  113. set { m_Type = value; InvokePropertyChanged("Type"); }
  114. }
  115. private string m_ChunckRecipe;
  116. public string ChuckRecipe
  117. {
  118. get { return m_ChunckRecipe; }
  119. set { m_ChunckRecipe = value; InvokePropertyChanged("ChuckRecipe"); }
  120. }
  121. private string m_DechuckRecipe;
  122. public string DechuckRecipe
  123. {
  124. get { return m_DechuckRecipe; }
  125. set { m_DechuckRecipe = value; InvokePropertyChanged("DechuckRecipe"); }
  126. }
  127. private string m_CreateTime;
  128. [IsOnlyRead]
  129. public string CreateTime
  130. {
  131. get { return m_CreateTime; }
  132. set { m_CreateTime = value; InvokePropertyChanged("CreateTime"); }
  133. }
  134. private string m_EditTime;
  135. [IsOnlyRead]
  136. public string EditTime
  137. {
  138. get { return m_EditTime; }
  139. set { m_EditTime = value; InvokePropertyChanged("EditTime"); }
  140. }
  141. private string m_LastModifiedBy;
  142. [IsOnlyRead]
  143. public string LastModifiedBy
  144. {
  145. get { return m_LastModifiedBy; }
  146. set { m_LastModifiedBy = value; InvokePropertyChanged("LastModifiedBy"); }
  147. }
  148. private string m_Barcode;
  149. public string Barcode
  150. {
  151. get { return m_Barcode; }
  152. set { m_Barcode = value; InvokePropertyChanged("Barcode"); }
  153. }
  154. private string m_BasePressure;
  155. public string BasePressure
  156. {
  157. get { return m_BasePressure; }
  158. set { m_BasePressure = value; InvokePropertyChanged("BasePressure"); }
  159. }
  160. private string m_ChillerTemp;
  161. public string ChillerTemp
  162. {
  163. get { return m_ChillerTemp; }
  164. set { m_ChillerTemp = value; InvokePropertyChanged("ChillerTemp"); }
  165. }
  166. private int m_RFHoldTime = 1000;
  167. public int RFHoldTime
  168. {
  169. get { return m_RFHoldTime; }
  170. set { m_RFHoldTime = value; InvokePropertyChanged("RFHoldTime"); }
  171. }
  172. private int m_BiasRFHoldTime = 1000;
  173. public int BiasRFHoldTime
  174. {
  175. get { return m_BiasRFHoldTime; }
  176. set { m_BiasRFHoldTime = value; InvokePropertyChanged("BiasRFHoldTime"); }
  177. }
  178. private string m_Comment;
  179. public string Comment
  180. {
  181. get { return m_Comment; }
  182. set { m_Comment = value; InvokePropertyChanged("Comment"); }
  183. }
  184. //private string m_ChillerTemp1;
  185. //public string ChillerTemp1
  186. //{
  187. // get { return m_ChillerTemp1; }
  188. // set { m_ChillerTemp1 = value; InvokePropertyChanged("ChillerTemp1"); }
  189. //}
  190. //private string m_ChillerTemp2;
  191. //public string ChillerTemp2
  192. //{
  193. // get { return m_ChillerTemp2; }
  194. // set { m_ChillerTemp2 = value; InvokePropertyChanged("ChillerTemp2"); }
  195. //}
  196. //private string m_ChillerTemp3;
  197. //public string ChillerTemp3
  198. //{
  199. // get { return m_ChillerTemp3; }
  200. // set { m_ChillerTemp3 = value; InvokePropertyChanged("ChillerTemp3"); }
  201. //}
  202. //private string m_ChillerTemp4;
  203. //public string ChillerTemp4
  204. //{
  205. // get { return m_ChillerTemp4; }
  206. // set { m_ChillerTemp4 = value; InvokePropertyChanged("ChillerTemp4"); }
  207. //}
  208. public event PropertyChangedEventHandler PropertyChanged;
  209. public void InvokePropertyChanged(string propertyName)
  210. {
  211. if (PropertyChanged != null)
  212. {
  213. PropertyChanged.Invoke(this, new PropertyChangedEventArgs(propertyName));
  214. }
  215. }
  216. }
  217. public class ProcessUnitBase
  218. {
  219. [JsonIgnore]
  220. public Func<ProcessUnitBase, RecipeStep, RState> checker;
  221. [JsonIgnore]
  222. public Func<ProcessUnitBase, RecipeStep, RState> starter;
  223. [JsonIgnore]
  224. public Action<ProcessUnitBase, RecipeStep> end;
  225. //[JsonIgnore]
  226. //public string Name { get; set; }
  227. //[JsonIgnore]
  228. //public ProcessModule Moudle { get; set; }
  229. public RState Start(RecipeStep step)
  230. {
  231. if (starter != null)
  232. return starter(this, step);
  233. return RState.Running;
  234. }
  235. public RState Run(RecipeStep step)
  236. {
  237. if (checker != null)
  238. return checker(this, step);
  239. return RState.Running;
  240. }
  241. public void End(RecipeStep step)
  242. {
  243. if (end != null)
  244. end(this, step);
  245. }
  246. }
  247. [Serializable]
  248. public class RecipeStep : INotifyPropertyChanged
  249. {
  250. [JsonIgnore]
  251. public Func<RecipeStep, RState> checker;
  252. [JsonIgnore]
  253. public Func<RecipeStep, RState> starter;
  254. [JsonIgnore]
  255. public Func<RecipeStep, RState> ender;
  256. private int m_StepNo = 1;
  257. [IsOnlyRead]
  258. public int StepNo
  259. {
  260. get { return m_StepNo; }
  261. set { m_StepNo = value; InvokePropertyChanged("StepNo"); }
  262. }
  263. private StepType m_StepType;
  264. [JsonConverter(typeof(StringEnumConverter))]
  265. public StepType Type
  266. {
  267. get { return m_StepType; }
  268. set { m_StepType = value; InvokePropertyChanged("Type"); }
  269. }
  270. private int m_Time;
  271. public int Time
  272. {
  273. get { return m_Time; }
  274. set { m_Time = value; InvokePropertyChanged("Time"); }
  275. }
  276. private string m_Description;
  277. public string Description
  278. {
  279. get { return m_Description; }
  280. set { m_Description = value; InvokePropertyChanged("Description"); }
  281. }
  282. private string m_EPDConfigName;
  283. public string EPDConfig
  284. {
  285. get { return m_EPDConfigName; }
  286. set { m_EPDConfigName = value; InvokePropertyChanged("EPDConfig"); }
  287. }
  288. private int m_MinEndPointTime;
  289. public int MinEndPointTime
  290. {
  291. get { return m_MinEndPointTime; }
  292. set { m_MinEndPointTime = value; InvokePropertyChanged("MinEndPointTime"); }
  293. }
  294. private int m_MaxEndPointTime;
  295. public int MaxEndPointTime
  296. {
  297. get { return m_MaxEndPointTime; }
  298. set { m_MaxEndPointTime = value; InvokePropertyChanged("MaxEndPointTime"); }
  299. }
  300. //private bool m_EnableRamp;
  301. //public bool EnableRamp
  302. //{
  303. // get { return m_EnableRamp; }
  304. // set { m_EnableRamp = value; InvokePropertyChanged("EnableRamp"); }
  305. //}
  306. private int m_OverEtchPercent;
  307. public int OverEtchPercent
  308. {
  309. get { return m_OverEtchPercent; }
  310. set { m_OverEtchPercent = value; InvokePropertyChanged("OverEtchPercent"); }
  311. }
  312. private bool m_CycleStart;
  313. public bool CycleStart
  314. {
  315. get { return m_CycleStart; }
  316. set { m_CycleStart = value; InvokePropertyChanged("CycleStart"); }
  317. }
  318. private bool m_CycleEnd;
  319. public bool CycleEnd
  320. {
  321. get { return m_CycleEnd; }
  322. set { m_CycleEnd = value; InvokePropertyChanged("CycleEnd"); }
  323. }
  324. private int m_CycleNumber;
  325. public int CycleNumber
  326. {
  327. get { return m_CycleNumber; }
  328. set { m_CycleNumber = value; InvokePropertyChanged("CycleNumber"); }
  329. }
  330. private ObservableCollection<Object> lstUnit = new ObservableCollection<Object>();
  331. public ObservableCollection<Object> LstUnit
  332. {
  333. get { return lstUnit; }
  334. set { lstUnit = value; InvokePropertyChanged("LstUnit"); }
  335. }
  336. private Stopwatch _stepTimer = new Stopwatch();
  337. public long ElapsedTime()
  338. {
  339. return _stepTimer.ElapsedMilliseconds;
  340. }
  341. public void StartStepTimer()
  342. {
  343. _stepTimer.Restart();
  344. }
  345. private long _lastEPDStepTimne = 0;
  346. public void RecordEPDStepTime()
  347. {
  348. _lastEPDStepTimne = _stepTimer.ElapsedMilliseconds;
  349. }
  350. public long GetLastEPDStepTime()
  351. {
  352. return _lastEPDStepTimne;
  353. }
  354. public RState Start()
  355. {
  356. starter(this);
  357. foreach (var unit in lstUnit)
  358. {
  359. var processUnit = unit as ProcessUnitBase;
  360. if (processUnit != null)
  361. {
  362. var state = processUnit.Start(this);
  363. if (state != RState.Running)
  364. return state;
  365. }
  366. else
  367. return RState.Failed;
  368. }
  369. return RState.Running;
  370. }
  371. public RState Start(int steps, int currentstep)
  372. {
  373. starter(this);
  374. foreach (var unit in lstUnit)
  375. {
  376. var processUnit = unit as ProcessUnitBase;
  377. if (processUnit != null)
  378. {
  379. var state = processUnit.Start(this);
  380. if (state != RState.Running)
  381. return state;
  382. }
  383. else
  384. return RState.Failed;
  385. }
  386. return RState.Running;
  387. }
  388. public RState Run()
  389. {
  390. if (checker(this) == RState.End)
  391. return RState.End;
  392. bool bStable = true;
  393. foreach (var unit in lstUnit)
  394. {
  395. var processUnit = unit as ProcessUnitBase;
  396. if (processUnit != null)
  397. {
  398. var state = processUnit.Run(this);
  399. if (Type == StepType.Stable)
  400. {
  401. if (state != RState.Running && state != RState.End)
  402. return state;
  403. if (state == RState.Running)
  404. bStable = false;
  405. }
  406. else
  407. {
  408. if (state != RState.Running)
  409. return state;
  410. }
  411. }
  412. else
  413. return RState.Failed;
  414. }
  415. return (Type == StepType.Stable && bStable) ? RState.End : RState.Running;
  416. }
  417. public void End()
  418. {
  419. foreach (var unit in lstUnit)
  420. {
  421. var processUnit = unit as ProcessUnitBase;
  422. if (processUnit != null)
  423. {
  424. processUnit.End(this);
  425. }
  426. }
  427. ender(this);
  428. }
  429. public double RampFactor()
  430. {
  431. return _stepTimer.ElapsedMilliseconds / (Time * 1000.0);
  432. }
  433. public void AppendUnit(ProcessUnitBase unit)
  434. {
  435. lstUnit.Append(unit);
  436. }
  437. public event PropertyChangedEventHandler PropertyChanged;
  438. public void InvokePropertyChanged(string propertyName)
  439. {
  440. if (PropertyChanged != null)
  441. {
  442. PropertyChanged.Invoke(this, new PropertyChangedEventArgs(propertyName));
  443. }
  444. }
  445. }
  446. public class Recipe : INotifyPropertyChanged
  447. {
  448. private RecipeHead m_Header = new RecipeHead();
  449. public RecipeHead Header
  450. {
  451. get { return m_Header; }
  452. set { m_Header = value; InvokePropertyChanged("Header"); }
  453. }
  454. private ObservableCollection<RecipeStep> m_Steps;
  455. public ObservableCollection<RecipeStep> Steps
  456. {
  457. get { return m_Steps; }
  458. set { m_Steps = value; InvokePropertyChanged("Steps"); }
  459. }
  460. public static Recipe Load(string recipeFile)
  461. {
  462. var recipe = JsonConvert.DeserializeObject<Recipe>(recipeFile);
  463. if (recipe == null)
  464. {
  465. return null;
  466. }
  467. foreach (var step in recipe.Steps)
  468. {
  469. ObservableCollection<ProcessUnitBase> unit = new ObservableCollection<ProcessUnitBase>();
  470. for (int i = 0; i < step.LstUnit.Count; i++)
  471. {
  472. string value = step.LstUnit[i].ToString();
  473. string[] striparr = value.Split(new string[] { "\r\n" }, StringSplitOptions.None);
  474. string item1 = striparr[1].Remove(0, 15);
  475. string item2 = item1.Remove(item1.Length - 2, 2);
  476. switch (item2)
  477. {
  478. case "PressureModeUnit":
  479. unit.Add(JsonConvert.DeserializeObject<PressureByPressureModeUnit>(step.LstUnit[i].ToString()));
  480. break;
  481. //case "PressureByValveModeUnit":
  482. // unit.Add(JsonConvert.DeserializeObject<PressureByValveModeUnit>(step.LstUnit[i].ToString()));
  483. // break;
  484. case "TCPUnit":
  485. unit.Add(JsonConvert.DeserializeObject<TCPUnit>(step.LstUnit[i].ToString()));
  486. break;
  487. case "BiasUnit":
  488. unit.Add(JsonConvert.DeserializeObject<BiasUnit>(step.LstUnit[i].ToString()));
  489. break;
  490. case "GasControlUnit":
  491. unit.Add(JsonConvert.DeserializeObject<GasControlUnit>(step.LstUnit[i].ToString()));
  492. break;
  493. case "ESCHVUnit":
  494. unit.Add(JsonConvert.DeserializeObject<ESCHVUnit>(step.LstUnit[i].ToString()));
  495. break;
  496. case "ProcessKitUnit":
  497. unit.Add(JsonConvert.DeserializeObject<ProcessKitUnit>(step.LstUnit[i].ToString()));
  498. break;
  499. case "HeaterUnit":
  500. unit.Add(JsonConvert.DeserializeObject<HeaterUnit>(step.LstUnit[i].ToString()));
  501. break;
  502. case "GasUnit":
  503. unit.Add(JsonConvert.DeserializeObject<Kepler2200GasControlUnit>(step.LstUnit[i].ToString()));
  504. break;
  505. }
  506. }
  507. step.LstUnit.Clear();
  508. unit.ToList().ForEach(x =>
  509. {
  510. step.LstUnit.Add(x);
  511. });
  512. }
  513. return recipe;
  514. }
  515. public bool Validate()
  516. {
  517. return true;
  518. }
  519. public bool Save(string recipeFile)
  520. {
  521. return true;
  522. }
  523. public event PropertyChangedEventHandler PropertyChanged;
  524. public void InvokePropertyChanged(string propertyName)
  525. {
  526. if (PropertyChanged != null)
  527. {
  528. PropertyChanged.Invoke(this, new PropertyChangedEventArgs(propertyName));
  529. }
  530. }
  531. }
  532. public class RecipeUnity
  533. {
  534. public static string ConvertJsonString(string str)
  535. {
  536. JsonSerializer serializer = new JsonSerializer();
  537. TextReader tr = new StringReader(str);
  538. JsonTextReader jtr = new JsonTextReader(tr);
  539. object obj = serializer.Deserialize(jtr);
  540. if (obj != null)
  541. {
  542. StringWriter textWriter = new StringWriter();
  543. JsonTextWriter jsonWriter = new JsonTextWriter(textWriter)
  544. {
  545. Formatting = Newtonsoft.Json.Formatting.Indented,
  546. Indentation = 4,
  547. IndentChar = ' '
  548. };
  549. serializer.Serialize(jsonWriter, obj);
  550. return textWriter.ToString();
  551. }
  552. else
  553. {
  554. return str;
  555. }
  556. }
  557. public static string RecipeToString(Recipe recipe)
  558. {
  559. return JsonConvert.SerializeObject(recipe);
  560. }
  561. public static String CreateRecipe(JetChamber currentChamber, RecipeType recipeType, string recipeName)
  562. {
  563. Recipe recipe = new Recipe();
  564. recipe.Header = new RecipeHead();
  565. recipe.Header.CreateTime = DateTime.Now.ToString();
  566. recipe.Header.EditTime = DateTime.Now.ToString();
  567. recipe.Header.Type = recipeType;
  568. recipe.Header.ChamberType = currentChamber;
  569. recipe.Header.Name = recipeName;
  570. recipe.Header.LastModifiedBy = "Admin";
  571. recipe.Steps = new ObservableCollection<RecipeStep>();
  572. RecipeStep recipeStep = new RecipeStep();
  573. recipeStep.LstUnit = GetAllUnits(currentChamber, recipeType);
  574. recipe.Steps.Add(recipeStep);
  575. var recipeString = JsonConvert.SerializeObject(recipe);
  576. return recipeString;
  577. }
  578. public static ObservableCollection<Object> GetAllUnits(JetChamber jetChamber)
  579. {
  580. ObservableCollection<Object> LstUnit = new ObservableCollection<object>();
  581. switch (jetChamber)
  582. {
  583. case JetChamber.Venus:
  584. foreach (var item in Enum.GetValues(typeof(VenusUnits)))
  585. {
  586. Type t = Type.GetType($"Venus_Core.{item.ToString()}");
  587. var obj = System.Activator.CreateInstance(t);
  588. LstUnit.Add(obj);
  589. }
  590. break;
  591. case JetChamber.Kepler2300:
  592. foreach (var item in Enum.GetValues(typeof(Kepler2300Uints)))
  593. {
  594. Type t = Type.GetType($"Venus_Core.{item.ToString()}");
  595. var obj = System.Activator.CreateInstance(t);
  596. LstUnit.Add(obj);
  597. }
  598. break;
  599. case JetChamber.Kepler2200A:
  600. foreach (var item in Enum.GetValues(typeof(Kepler2200AUnits)))
  601. {
  602. Type t = Type.GetType($"Venus_Core.{item.ToString()}");
  603. var obj = System.Activator.CreateInstance(t);
  604. LstUnit.Add(obj);
  605. }
  606. break;
  607. }
  608. return LstUnit;
  609. }
  610. public static ObservableCollection<Object> GetAllUnits(JetChamber jetChamber, RecipeType recipeType)
  611. {
  612. ObservableCollection<Object> LstUnit = new ObservableCollection<object>();
  613. switch (jetChamber)
  614. {
  615. case JetChamber.Venus:
  616. if (recipeType == RecipeType.Clean)
  617. {
  618. foreach (var item in Enum.GetValues(typeof(VenusCleanRecipeUnits)))
  619. {
  620. Type t = Type.GetType($"Venus_Core.{item.ToString()}");
  621. var obj = System.Activator.CreateInstance(t);
  622. LstUnit.Add(obj);
  623. }
  624. }
  625. else
  626. {
  627. foreach (var item in Enum.GetValues(typeof(VenusUnits)))
  628. {
  629. Type t = Type.GetType($"Venus_Core.{item.ToString()}");
  630. var obj = System.Activator.CreateInstance(t);
  631. LstUnit.Add(obj);
  632. }
  633. }
  634. break;
  635. case JetChamber.Kepler2300:
  636. if (recipeType == RecipeType.Clean)
  637. {
  638. foreach (var item in Enum.GetValues(typeof(Kepler2300CleanRecipeUints)))
  639. {
  640. Type t = Type.GetType($"Venus_Core.{item.ToString()}");
  641. var obj = System.Activator.CreateInstance(t);
  642. LstUnit.Add(obj);
  643. }
  644. }
  645. else
  646. {
  647. foreach (var item in Enum.GetValues(typeof(Kepler2300Uints)))
  648. {
  649. Type t = Type.GetType($"Venus_Core.{item.ToString()}");
  650. var obj = System.Activator.CreateInstance(t);
  651. LstUnit.Add(obj);
  652. }
  653. }
  654. break;
  655. case JetChamber.Kepler2200A:
  656. foreach (var item in Enum.GetValues(typeof(Kepler2200AUnits)))
  657. {
  658. Type t = Type.GetType($"Venus_Core.{item.ToString()}");
  659. var obj = System.Activator.CreateInstance(t);
  660. LstUnit.Add(obj);
  661. }
  662. break;
  663. }
  664. return LstUnit;
  665. }
  666. }
  667. }