MeasureParam.cs 34 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051
  1. //时间:20200618
  2. //作者:郝爽
  3. //功能:测量参数
  4. using System;
  5. using System.Collections.Generic;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Threading.Tasks;
  9. using FileManager;
  10. using System.Xml;
  11. using System.IO;
  12. namespace MeasureData
  13. {
  14. public class MeasureParam : ISlo
  15. {
  16. #region 内容
  17. //工作条件,一次测量的全部切孔都是一类的
  18. // 样品类型
  19. private string m_SampleName;
  20. public string SampleName
  21. {
  22. get { return this.m_SampleName; }
  23. set { this.m_SampleName = value; }
  24. }
  25. //是否仅拍照
  26. private Boolean is_Photograph;
  27. public Boolean Is_Photograph
  28. {
  29. get { return this.is_Photograph; }
  30. set { this.is_Photograph = value; }
  31. }
  32. //是否有pt工序
  33. private Boolean m_pt;
  34. public Boolean PT
  35. {
  36. get { return this.m_pt; }
  37. set { this.m_pt = value; }
  38. }
  39. //倾斜样品台
  40. private Boolean m_Tilt;
  41. public Boolean Tilt
  42. {
  43. get { return this.m_Tilt; }
  44. set { this.m_Tilt = value; }
  45. }
  46. //是否有EDS
  47. private Boolean m_EDS;
  48. public Boolean EDS
  49. {
  50. get { return this.m_EDS; }
  51. set { this.m_EDS = value; }
  52. }
  53. //能谱Z轴移动的位置
  54. private float edsZ;
  55. public float EDSZ
  56. {
  57. get { return this.edsZ; }
  58. set { this.edsZ = value; }
  59. }
  60. //能谱电压设定值
  61. private float edsV;
  62. public float EDSV
  63. {
  64. get { return this.edsV; }
  65. set { this.edsV = value; }
  66. }
  67. //能谱电压设定值
  68. private float edsA;
  69. public float EDSA
  70. {
  71. get { return this.edsA; }
  72. set { this.edsA = value; }
  73. }
  74. //Z轴移动的范围
  75. private float m_dZ;
  76. public float ZDistance
  77. {
  78. get { return this.m_dZ; }
  79. set { this.m_dZ = value; }
  80. }
  81. //FIB使用的ELY文件
  82. private string m_fibTemp;
  83. public string FIBTemp
  84. {
  85. get { return this.m_fibTemp; }
  86. set { this.m_fibTemp = value; }
  87. }
  88. //PT使用的ELY文件
  89. private string m_ptTemp;
  90. public string PTTemp
  91. {
  92. get { return this.m_ptTemp; }
  93. set { this.m_ptTemp = value; }
  94. }
  95. //对焦方式,自动对焦还是手动对焦,手动对焦是1,自有自动对焦2,客户自动对焦3
  96. private int m_fMode;
  97. public int FocusMode
  98. {
  99. get { return m_fMode; }
  100. set { m_fMode = value; }
  101. }
  102. //拉直操作需要的放大位数
  103. private float stretch_Magnification;
  104. public float Stretch_Magnification
  105. {
  106. get { return this.stretch_Magnification; }
  107. set { this.stretch_Magnification = value; }
  108. }
  109. //定位切割位置的放大倍数
  110. private float location_Magnification;
  111. public float Location_Magnification
  112. {
  113. get { return this.location_Magnification; }
  114. set { this.location_Magnification = value; }
  115. }
  116. //定位切割位置的工作电压
  117. private float location_Voltage;
  118. public float Location_Voltage
  119. {
  120. get { return this.location_Voltage; }
  121. set { this.location_Voltage = value; }
  122. }
  123. //拍照的放大倍数
  124. private float photograph_Magnification;
  125. public float Photograph_Magnification
  126. {
  127. get { return this.photograph_Magnification; }
  128. set { this.photograph_Magnification = value; }
  129. }
  130. //拍照的工作电压
  131. private float photograph_Voltage;
  132. public float Photograph_Voltage
  133. {
  134. get { return this.photograph_Voltage; }
  135. set { this.photograph_Voltage = value; }
  136. }
  137. //FIB拍照时的放大倍数
  138. private float fib_Magnification;
  139. public float FIB_Magnification
  140. {
  141. get { return this.fib_Magnification; }
  142. set { this.fib_Magnification = value; }
  143. }
  144. //校正角度选择
  145. private float correction_Angle;
  146. public float Correction_Angle
  147. {
  148. get { return this.correction_Angle; }
  149. set { this.correction_Angle = value; }
  150. }
  151. //厂商
  152. private String firm;
  153. public String Firm
  154. {
  155. get { return this.firm; }
  156. set { this.firm = value; }
  157. }
  158. //对焦参数, SEM
  159. private FocusParam focusP;
  160. public FocusParam AutoFocus
  161. {
  162. get { return this.focusP; }
  163. set { this.focusP = value; }
  164. }
  165. //对焦参数, FIB
  166. private FocusParam focusF;
  167. public FocusParam FIBFocus
  168. {
  169. get { return this.focusF; }
  170. set { this.focusF = value; }
  171. }
  172. //消像散x参数
  173. private FocusParam StigX;
  174. public FocusParam AutoStigX
  175. {
  176. get { return this.StigX; }
  177. set { this.StigX = value; }
  178. }
  179. //消像散Y参数
  180. private FocusParam StigY;
  181. public FocusParam AutoStigY
  182. {
  183. get { return this.StigY; }
  184. set { this.StigY = value; }
  185. }
  186. //EDS参数
  187. private EDSParam EdsParam;
  188. public EDSParam EDSParam
  189. {
  190. get { return this.EdsParam; }
  191. set { this.EdsParam = value; }
  192. }
  193. #region 放大倍数档位切换功能
  194. //档位阈值4个,4个偏差补偿值
  195. private bool bMagComp;
  196. public bool MagComp
  197. {
  198. get { return this.bMagComp; }
  199. set { this.bMagComp = value; }
  200. }
  201. private float fMagRange1;
  202. public float MagRange1
  203. {
  204. get { return this.fMagRange1; }
  205. set
  206. {
  207. if (value < this.fMagRange2)
  208. this.fMagRange1 = value;
  209. }
  210. }
  211. private float fMagCompX1;
  212. public float MagCompX1
  213. {
  214. get { return this.fMagCompX1; }
  215. set { this.fMagCompX1 = value; }
  216. }
  217. private float fMagCompY1;
  218. public float MagCompY1
  219. {
  220. get { return this.fMagCompY1; }
  221. set { this.fMagCompY1 = value; }
  222. }
  223. private float fMagRange2;
  224. public float MagRange2
  225. {
  226. get { return this.fMagRange2; }
  227. set
  228. {
  229. if ((value > this.fMagRange1) && (value < this.fMagRange3))
  230. this.fMagRange2 = value;
  231. }
  232. }
  233. private float fMagCompX2;
  234. public float MagCompX2
  235. {
  236. get { return this.fMagCompX2; }
  237. set { this.fMagCompX2 = value; }
  238. }
  239. private float fMagCompY2;
  240. public float MagCompY2
  241. {
  242. get { return this.fMagCompY2; }
  243. set { this.fMagCompY2 = value; }
  244. }
  245. private float fMagRange3;
  246. public float MagRange3
  247. {
  248. get { return this.fMagRange3; }
  249. set
  250. {
  251. if ((value > this.fMagRange2) && (value < this.fMagRange4))
  252. this.fMagRange3 = value;
  253. }
  254. }
  255. private float fMagCompX3;
  256. public float MagCompX3
  257. {
  258. get { return this.fMagCompX3; }
  259. set { this.fMagCompX3 = value; }
  260. }
  261. private float fMagCompY3;
  262. public float MagCompY3
  263. {
  264. get { return this.fMagCompY3; }
  265. set { this.fMagCompY3 = value; }
  266. }
  267. private float fMagRange4;
  268. public float MagRange4
  269. {
  270. get { return this.fMagRange4; }
  271. set
  272. {
  273. if (value > this.fMagRange3)
  274. this.fMagRange4 = value;
  275. }
  276. }
  277. private float fMagCompX4;
  278. public float MagCompX4
  279. {
  280. get { return this.fMagCompX4; }
  281. set { this.fMagCompX4 = value; }
  282. }
  283. private float fMagCompY4;
  284. public float MagCompY4
  285. {
  286. get { return this.fMagCompY4; }
  287. set { this.fMagCompY4 = value; }
  288. }
  289. #endregion
  290. #region FIB自动亮度对比度调整
  291. //是否调节FIB
  292. private bool IsFIBDo;
  293. public bool FIBDo
  294. {
  295. get { return this.IsFIBDo; }
  296. set { this.IsFIBDo = value; }
  297. }
  298. //是否开启亮度对比度自动调节
  299. private bool IsFIBAutoBC;
  300. public bool FIBAutoBC
  301. {
  302. get { return this.IsFIBAutoBC; }
  303. set { this.IsFIBAutoBC = value; }
  304. }
  305. //关闭亮度对比度时,亮度和对比度的设置值
  306. private float FIBBright;
  307. public float FIBB
  308. {
  309. get { return this.FIBBright; }
  310. set { this.FIBBright = value; }
  311. }
  312. private float FIBContrast;
  313. public float FIBC
  314. {
  315. get { return this.FIBContrast; }
  316. set { this.FIBContrast = value; }
  317. }
  318. //是否开启在其他位置调节亮度对比度功能,再挪回原来位置
  319. #endregion
  320. //ScanRotation修正角度
  321. private float scanRotCor;
  322. public float ScanRotCor
  323. {
  324. get { return this.scanRotCor; }
  325. set { this.scanRotCor = value; }
  326. }
  327. //ScanRotation修正角度
  328. private float pixelSizeCor;
  329. public float PixelSizeCor
  330. {
  331. get { return this.pixelSizeCor; }
  332. set { this.pixelSizeCor = value; }
  333. }
  334. //能谱参数
  335. #region add by sun 2020-12-15 增加不同样品扫描速度参数
  336. //正常情况下默认扫描速度
  337. private String m_ScanSpeedNormal;
  338. public String ScanSpeedNormal
  339. {
  340. get { return this.m_ScanSpeedNormal; }
  341. set { this.m_ScanSpeedNormal = value; }
  342. }
  343. //对焦拍照扫描速度
  344. private String m_ScanSpeedFocus;
  345. public String ScanSpeedFocus
  346. {
  347. get { return this.m_ScanSpeedFocus; }
  348. set { this.m_ScanSpeedFocus = value; }
  349. }
  350. //高倍拍照扫描速度
  351. private String m_ScanSpeedHigh;
  352. public String ScanSpeedHigh
  353. {
  354. get { return this.m_ScanSpeedHigh; }
  355. set { this.m_ScanSpeedHigh = value; }
  356. }
  357. #endregion add by sun 2020-12-15 增加不同样品扫描速度参数end
  358. //add by sun 2020-12-17 增加调试时是否切割开关
  359. private bool m_IsCutingForDebug;
  360. public bool IsCutingForDebug
  361. {
  362. get { return this.m_IsCutingForDebug; }
  363. set { this.m_IsCutingForDebug = value; }
  364. }
  365. //add by sun 2020-12-17 增加调试时是否切割开关 end
  366. //add by zjx 2020-12-18 为了测试只做能谱部分
  367. private bool m_IsonlyEDSForDebug;
  368. public bool IsonlyEDSForDebug
  369. {
  370. get { return this.m_IsonlyEDSForDebug; }
  371. set { this.m_IsonlyEDSForDebug = value; }
  372. }
  373. //add by zjx 2020-12-18 为了测试只做能谱部分 end
  374. #endregion
  375. #region 初始化样品的默认参数
  376. // add by zjx 2020-12-20 厂商名字
  377. #region 厂商
  378. private String m_VendorType0;
  379. public String VendorType0
  380. {
  381. get { return this.m_VendorType0; }
  382. set { this.m_VendorType0 = value; }
  383. }
  384. private String m_VendorType1;
  385. public String VendorType1
  386. {
  387. get { return this.m_VendorType1; }
  388. set { this.m_VendorType1 = value; }
  389. }
  390. private String m_VendorType2;
  391. public String VendorType2
  392. {
  393. get { return this.m_VendorType2; }
  394. set { this.m_VendorType2 = value; }
  395. }
  396. private String m_VendorType3;
  397. public String VendorType3
  398. {
  399. get { return this.m_VendorType3; }
  400. set { this.m_VendorType3 = value; }
  401. }
  402. #endregion
  403. // add by zjx 2020-12-20 厂商名字 end
  404. // add by zjx 2020-12-20 校正角度
  405. #region 校正角度
  406. private String m_CorrectionType0;
  407. public String CorrectionType0
  408. {
  409. get { return this.m_CorrectionType0; }
  410. set { this.m_CorrectionType0 = value; }
  411. }
  412. private String m_CorrectionType1;
  413. public String CorrectionType1
  414. {
  415. get { return this.m_CorrectionType1; }
  416. set { this.m_CorrectionType1 = value; }
  417. }
  418. private String m_CorrectionType2;
  419. public String CorrectionType2
  420. {
  421. get { return this.m_CorrectionType2; }
  422. set { this.m_CorrectionType2 = value; }
  423. }
  424. private String m_CorrectionType3;
  425. public String CorrectionType3
  426. {
  427. get { return this.m_CorrectionType3; }
  428. set { this.m_CorrectionType3 = value; }
  429. }
  430. #endregion
  431. //add by zjx 2020-12-20 校正角度 end
  432. //add by zjx 2020-12-20 拉直操作放大倍数
  433. #region 拉直操作放大倍数
  434. private String m_StraightenTimesType0;
  435. public String StraightenTimesType0
  436. {
  437. get { return this.m_StraightenTimesType0; }
  438. set { this.m_StraightenTimesType0 = value; }
  439. }
  440. private String m_StraightenTimesType1;
  441. public String StraightenTimesType1
  442. {
  443. get { return this.m_StraightenTimesType1; }
  444. set { this.m_StraightenTimesType1 = value; }
  445. }
  446. private String m_StraightenTimesType2;
  447. public String StraightenTimesType2
  448. {
  449. get { return this.m_StraightenTimesType2; }
  450. set { this.m_StraightenTimesType2 = value; }
  451. }
  452. private String m_StraightenTimesType3;
  453. public String StraightenTimesType3
  454. {
  455. get { return this.m_StraightenTimesType3; }
  456. set { this.m_StraightenTimesType3 = value; }
  457. }
  458. #endregion
  459. //add by zjx 2020-12-20 拉直操作放大倍数 end
  460. //add by zjx 2020-12-20 样品类型的定位电压
  461. #region 样品类型的定位电压
  462. private String m_PositioningVoltageeType0;
  463. public String PositioningVoltageeType0
  464. {
  465. get { return this.m_PositioningVoltageeType0; }
  466. set { this.m_PositioningVoltageeType0 = value; }
  467. }
  468. private String m_PositioningVoltageeType1;
  469. public String PositioningVoltageeType1
  470. {
  471. get { return this.m_PositioningVoltageeType1; }
  472. set { this.m_PositioningVoltageeType1 = value; }
  473. }
  474. private String m_PositioningVoltageeType2;
  475. public String PositioningVoltageeType2
  476. {
  477. get { return this.m_PositioningVoltageeType2; }
  478. set { this.m_PositioningVoltageeType2 = value; }
  479. }
  480. private String m_PositioningVoltageeType3;
  481. public String PositioningVoltageeType3
  482. {
  483. get { return this.m_PositioningVoltageeType3; }
  484. set { this.m_PositioningVoltageeType3 = value; }
  485. }
  486. #endregion
  487. //add by zjx 2020-12-20 样品类型的定位电压 end
  488. //add by zjx 2020-12-20 样品类型的定位放大倍数
  489. #region 定位放大倍数
  490. private String m_PositioningTimesType0;
  491. public String PositioningTimesType0
  492. {
  493. get { return this.m_PositioningTimesType0; }
  494. set { this.m_PositioningTimesType0 = value; }
  495. }
  496. private String m_PositioningTimesType1;
  497. public String PositioningTimesType1
  498. {
  499. get { return this.m_PositioningTimesType1; }
  500. set { this.m_PositioningTimesType1 = value; }
  501. }
  502. private String m_PositioningTimesType2;
  503. public String PositioningTimesType2
  504. {
  505. get { return this.m_PositioningTimesType2; }
  506. set { this.m_PositioningTimesType2 = value; }
  507. }
  508. private String m_PositioningTimesType3;
  509. public String PositioningTimesType3
  510. {
  511. get { return this.m_PositioningTimesType3; }
  512. set { this.m_PositioningTimesType3 = value; }
  513. }
  514. #endregion
  515. //add by zjx 2020-12-20 样品类型的定位放大倍数 end
  516. //add by zjx 2020-12-20 样品类型的拍照电压
  517. #region 拍照电压
  518. private String m_PhotoVoltageeType0;
  519. public String PhotoVoltageeType0
  520. {
  521. get { return this.m_PhotoVoltageeType0; }
  522. set { this.m_PhotoVoltageeType0 = value; }
  523. }
  524. private String m_PhotoVoltageeType1;
  525. public String PhotoVoltageeType1
  526. {
  527. get { return this.m_PhotoVoltageeType1; }
  528. set { this.m_PhotoVoltageeType1 = value; }
  529. }
  530. private String m_PhotoVoltageeType2;
  531. public String PhotoVoltageeType2
  532. {
  533. get { return this.m_PhotoVoltageeType2; }
  534. set { this.m_PhotoVoltageeType2 = value; }
  535. }
  536. private String m_PhotoVoltageeType3;
  537. public String PhotoVoltageeType3
  538. {
  539. get { return this.m_PhotoVoltageeType3; }
  540. set { this.m_PhotoVoltageeType3 = value; }
  541. }
  542. #endregion
  543. //add by zjx 2020-12-20 样品类型的拍照电压 end
  544. //add by zjx 2020-12-20 样品类型的拍照放大倍数
  545. #region 拍照放大倍数
  546. private String m_PhotoTimesType0;
  547. public String PhotoTimesType0
  548. {
  549. get { return this.m_PhotoTimesType0; }
  550. set { this.m_PhotoTimesType0 = value; }
  551. }
  552. private String m_PhotoTimesType1;
  553. public String PhotoTimesType1
  554. {
  555. get { return this.m_PhotoTimesType1; }
  556. set { this.m_PhotoTimesType1 = value; }
  557. }
  558. private String m_PhotoTimesType2;
  559. public String PhotoTimesType2
  560. {
  561. get { return this.m_PhotoTimesType2; }
  562. set { this.m_PhotoTimesType2 = value; }
  563. }
  564. private String m_PhotoTimesType3;
  565. public String PhotoTimesType3
  566. {
  567. get { return this.m_PhotoTimesType3; }
  568. set { this.m_PhotoTimesType3 = value; }
  569. }
  570. #endregion
  571. //add by zjx 2020-12-20 样品类型的拍照放大倍数 end
  572. //add by zjx 2020-12-20 样品类型的ScanRotate修正参数
  573. #region ScanRotate修正参数
  574. private String m_ScanRotateType0;
  575. public String ScanRotateType0
  576. {
  577. get { return this.m_ScanRotateType0; }
  578. set { this.m_ScanRotateType0 = value; }
  579. }
  580. private String m_ScanRotateType1;
  581. public String ScanRotateType1
  582. {
  583. get { return this.m_ScanRotateType1; }
  584. set { this.m_ScanRotateType1 = value; }
  585. }
  586. private String m_ScanRotateType2;
  587. public String ScanRotateType2
  588. {
  589. get { return this.m_ScanRotateType2; }
  590. set { this.m_ScanRotateType2 = value; }
  591. }
  592. private String m_ScanRotateType3;
  593. public String ScanRotateType3
  594. {
  595. get { return this.m_ScanRotateType3; }
  596. set { this.m_ScanRotateType3 = value; }
  597. }
  598. #endregion
  599. //add by zjx 2020-12-20 样品类型的ScanRotate修正参数 end
  600. //add by zjx 2020-12-20 样品类型的Y轴方向PixelSize修正值
  601. #region Y轴方向PixelSize修正值
  602. private String m_PixelSizeType0;
  603. public String PixelSizeType0
  604. {
  605. get { return this.m_PixelSizeType0; }
  606. set { this.m_PixelSizeType0 = value; }
  607. }
  608. private String m_PixelSizeType1;
  609. public String PixelSizeType1
  610. {
  611. get { return this.m_PixelSizeType1; }
  612. set { this.m_PixelSizeType1 = value; }
  613. }
  614. private String m_PixelSizeType2;
  615. public String PixelSizeType2
  616. {
  617. get { return this.m_PixelSizeType2; }
  618. set { this.m_PixelSizeType2 = value; }
  619. }
  620. private String m_PixelSizeType3;
  621. public String PixelSizeType3
  622. {
  623. get { return this.m_PixelSizeType3; }
  624. set { this.m_PixelSizeType3 = value; }
  625. }
  626. #endregion
  627. //add by zjx 2020-12-20 样品类型的Y轴方向PixelSize修正值 end
  628. //add by zjx 2020-12-20 样品类型的能谱Z轴移动位置
  629. #region 能谱Z轴移动位置
  630. private String m_SEMAxis_ZType0;
  631. public String SEMAxis_ZType0
  632. {
  633. get { return this.m_SEMAxis_ZType0; }
  634. set { this.m_SEMAxis_ZType0 = value; }
  635. }
  636. private String m_SEMAxis_ZType1;
  637. public String SEMAxis_ZType1
  638. {
  639. get { return this.m_SEMAxis_ZType1; }
  640. set { this.m_SEMAxis_ZType1 = value; }
  641. }
  642. private String m_SEMAxis_ZType2;
  643. public String SEMAxis_ZType2
  644. {
  645. get { return this.m_SEMAxis_ZType2; }
  646. set { this.m_SEMAxis_ZType2 = value; }
  647. }
  648. private String m_SEMAxis_ZType3;
  649. public String SEMAxis_ZType3
  650. {
  651. get { return this.m_SEMAxis_ZType3; }
  652. set { this.m_SEMAxis_ZType3 = value; }
  653. }
  654. #endregion
  655. //add by zjx 2020-12-20 样品类型的能谱Z轴移动位置 end
  656. //add by zjx 2020-12-20 样品类型的能谱电压值
  657. #region 能谱电压值
  658. private String m_SEMVoltageeType0;
  659. public String SEMVoltageeType0
  660. {
  661. get { return this.m_SEMVoltageeType0; }
  662. set { this.m_SEMVoltageeType0 = value; }
  663. }
  664. private String m_SEMVoltageeType1;
  665. public String SEMVoltageeType1
  666. {
  667. get { return this.m_SEMVoltageeType1; }
  668. set { this.m_SEMVoltageeType1 = value; }
  669. }
  670. private String m_SEMVoltageeType2;
  671. public String SEMVoltageeType2
  672. {
  673. get { return this.m_SEMVoltageeType2; }
  674. set { this.m_SEMVoltageeType2 = value; }
  675. }
  676. private String m_SEMVoltageeType3;
  677. public String SEMVoltageeType3
  678. {
  679. get { return this.m_SEMVoltageeType3; }
  680. set { this.m_SEMVoltageeType3 = value; }
  681. }
  682. #endregion
  683. //add by zjx 2020-12-20 样品类型的能谱电压值 end
  684. //add by zjx 2020-12-20 样品类型的能谱电流值
  685. #region 能谱电流值
  686. private String m_SEMCurrentType0;
  687. public String SEMCurrentType0
  688. {
  689. get { return this.m_SEMCurrentType0; }
  690. set { this.m_SEMCurrentType0 = value; }
  691. }
  692. private String m_SEMCurrentType1;
  693. public String SEMCurrentType1
  694. {
  695. get { return this.m_SEMCurrentType1; }
  696. set { this.m_SEMCurrentType1 = value; }
  697. }
  698. private String m_SEMCurrentType2;
  699. public String SEMCurrentType2
  700. {
  701. get { return this.m_SEMCurrentType2; }
  702. set { this.m_SEMCurrentType2 = value; }
  703. }
  704. private String m_SEMCurrentType3;
  705. public String SEMCurrentType3
  706. {
  707. get { return this.m_SEMCurrentType3; }
  708. set { this.m_SEMCurrentType3 = value; }
  709. }
  710. #endregion
  711. //add by zjx 2020-12-20 样品类型的能谱电流值 end
  712. #endregion
  713. //构造函数
  714. public MeasureParam()
  715. {
  716. Init();
  717. }
  718. public void Init()
  719. {
  720. this.SampleName = @"";
  721. this.PT = false;
  722. this.FIBTemp = @"";
  723. this.PTTemp = @"";
  724. this.FocusMode = 2;
  725. this.AutoFocus = new FocusParam();
  726. this.AutoFocus.TYPE = 1;
  727. this.AutoStigX = new FocusParam();
  728. this.AutoStigX.TYPE = 2;
  729. this.AutoStigY = new FocusParam();
  730. this.AutoStigY.TYPE = 3;
  731. this.FIBFocus = new FocusParam();
  732. this.FIBFocus.TYPE = 4;
  733. this.Tilt = false;
  734. this.ZDistance = 0;
  735. this.EDS = false;
  736. this.EDSZ = 0.005f;
  737. this.EDSV = 10000;
  738. this.EDSA = 0.0000000005f;
  739. this.EDSParam = new EDSParam();
  740. //FIB自动亮度对比度
  741. this.FIBDo = false;
  742. this.FIBAutoBC = false;
  743. this.FIBB = 51;
  744. this.FIBC = 33;
  745. //档位阈值4个,4个偏差补偿值
  746. this.MagComp = false;
  747. this.MagRange1 = 300;
  748. this.MagCompX1 = 0;
  749. this.MagCompY1 = 0;
  750. this.MagRange2 = 700;
  751. this.MagCompX2 = 0;
  752. this.MagCompY2 = 0;
  753. this.MagRange3 = 2000;
  754. this.MagCompX3 = 0;
  755. this.MagCompY3 = 0;
  756. this.MagRange4 = 6000;
  757. this.fMagCompX4 = 0;
  758. this.fMagCompY4 = 0;
  759. this.ScanRotCor = 1;
  760. this.PixelSizeCor = 1;
  761. //add by sun 2020-12-15 增加不同样品扫描速度参数
  762. this.ScanSpeedNormal = "CMD_SCANRATE4";
  763. this.ScanSpeedFocus = "CMD_SCANRATE5";
  764. this.ScanSpeedHigh = "CMD_SCANRATE7";
  765. //add by sun 2020-12-15 增加不同样品扫描速度参数 end
  766. }
  767. //XML文件保存测量参数
  768. public override void Serialize(bool isStoring, XmlDocument xml, XmlNode rootNode)
  769. {
  770. Slo sFile = new Slo();
  771. //是否拍照和PT
  772. xBool isPhotograph = new xBool();
  773. xBool ptDepostion = new xBool();
  774. xBool isTilt = new xBool();
  775. xBool isEDS = new xBool();
  776. isTilt.AssignValue(this.Tilt);
  777. isEDS.AssignValue(this.EDS);
  778. isPhotograph.AssignValue(this.is_Photograph);
  779. ptDepostion.AssignValue(this.m_pt);
  780. sFile.Register("Is_Title", isTilt);
  781. sFile.Register("Is_Photograph", isPhotograph);
  782. sFile.Register("PT_Depostion", ptDepostion);
  783. sFile.Register("Is_EDS", isEDS);
  784. //ELY文件
  785. xString ptELYFile = new xString();
  786. xString fibELYFile = new xString();
  787. ptELYFile.AssignValue(this.m_ptTemp);
  788. fibELYFile.AssignValue(this.m_fibTemp);
  789. sFile.Register("PT_ELYFile", ptELYFile);
  790. sFile.Register("FIB_ELYFile", fibELYFile);
  791. //对焦方式
  792. xInt focusmode = new xInt();
  793. focusmode.AssignValue(this.m_fMode);
  794. sFile.Register("FocusMode", focusmode);
  795. //放大倍数和电压参数
  796. xDouble stretchMagnification = new xDouble();
  797. xDouble locationMagnification = new xDouble();
  798. xDouble locationVoltage = new xDouble();
  799. xDouble photographMagnification = new xDouble();
  800. xDouble photographVoltage = new xDouble();
  801. xDouble fibMagnification = new xDouble();
  802. xDouble ZDistance = new xDouble();
  803. xDouble xEDSZ = new xDouble();
  804. xDouble xEDSV = new xDouble();
  805. xDouble xEDSA = new xDouble();
  806. xEDSZ.AssignValue(this.edsZ);
  807. xEDSV.AssignValue(this.edsV);
  808. xEDSA.AssignValue(this.edsA);
  809. ZDistance.AssignValue(this.ZDistance);
  810. stretchMagnification.AssignValue(this.stretch_Magnification);
  811. locationMagnification.AssignValue(this.location_Magnification);
  812. locationVoltage.AssignValue(this.location_Voltage);
  813. photographMagnification.AssignValue(this.photograph_Magnification);
  814. photographVoltage.AssignValue(this.photograph_Voltage);
  815. fibMagnification.AssignValue(this.fib_Magnification);
  816. sFile.Register("Strectch_Magnification", stretchMagnification);
  817. sFile.Register("Locatio_Magnification", locationMagnification);
  818. sFile.Register("Location_Voltage", locationVoltage);
  819. sFile.Register("Photograph_Magnification", photographMagnification);
  820. sFile.Register("Photograph_Voltage", photographVoltage);
  821. sFile.Register("FIB_Magnification", fibMagnification);
  822. sFile.Register("ZDistance", ZDistance);
  823. sFile.Register("EDSZ", xEDSZ);
  824. sFile.Register("EDSV", xEDSV);
  825. sFile.Register("EDSA", xEDSA);
  826. //校正角度
  827. xDouble correctionAngle = new xDouble();
  828. correctionAngle.AssignValue(this.correction_Angle);
  829. sFile.Register("Correction_Angle", correctionAngle);
  830. //样品名称和厂商
  831. xString sampleType = new xString();
  832. xString _firm = new xString();
  833. sampleType.AssignValue(this.m_SampleName);
  834. _firm.AssignValue(this.firm);
  835. sFile.Register("Sample_Type", sampleType);
  836. sFile.Register("Firm", _firm);
  837. //对焦参数
  838. sFile.Register("Focus_Param", this.focusP);
  839. sFile.Register("FIBFocus_Param", this.FIBFocus);
  840. sFile.Register("StigX_Param", this.AutoStigX);
  841. sFile.Register("StigY_Param", this.AutoStigY);
  842. sFile.Register("EDS_Param", this.EDSParam);
  843. //FIB亮度对比
  844. xBool isFIBDo = new xBool();
  845. xBool isFIBAutoBC = new xBool();
  846. xDouble xFIBB = new xDouble();
  847. xDouble xFIBC = new xDouble();
  848. xBool isMagComp = new xBool();
  849. xDouble xMagRange1 = new xDouble();
  850. xDouble xMagCompX1 = new xDouble();
  851. xDouble xMagCompY1 = new xDouble();
  852. xDouble xMagRange2 = new xDouble();
  853. xDouble xMagCompX2 = new xDouble();
  854. xDouble xMagCompY2 = new xDouble();
  855. xDouble xMagRange3 = new xDouble();
  856. xDouble xMagCompX3 = new xDouble();
  857. xDouble xMagCompY3 = new xDouble();
  858. xDouble xMagRange4 = new xDouble();
  859. xDouble xMagCompX4 = new xDouble();
  860. xDouble xMagCompY4 = new xDouble();
  861. isFIBDo.AssignValue(this.FIBDo);
  862. isFIBAutoBC.AssignValue(this.FIBAutoBC);
  863. xFIBB.AssignValue(this.FIBB);
  864. xFIBC.AssignValue(this.FIBC);
  865. isMagComp.AssignValue(this.MagComp);
  866. xMagRange1.AssignValue(this.MagRange1);
  867. xMagCompX1.AssignValue(this.MagCompX1);
  868. xMagCompY1.AssignValue(this.MagCompY1);
  869. xMagRange2.AssignValue(this.MagRange2);
  870. xMagCompX2.AssignValue(this.MagCompX2);
  871. xMagCompY2.AssignValue(this.MagCompY2);
  872. xMagRange3.AssignValue(this.MagRange3);
  873. xMagCompX3.AssignValue(this.MagCompX3);
  874. xMagCompY3.AssignValue(this.MagCompY3);
  875. xMagRange4.AssignValue(this.MagRange4);
  876. xMagCompX4.AssignValue(this.MagCompX4);
  877. xMagCompY4.AssignValue(this.MagCompY4);
  878. sFile.Register("Is_FIBDo", isFIBDo);
  879. sFile.Register("Is_FIBAutoBC", isFIBAutoBC);
  880. sFile.Register("FIB_B", xFIBB);
  881. sFile.Register("FIB_C", xFIBC);
  882. sFile.Register("Mag_Comp", isMagComp);
  883. sFile.Register("Mag_Range1", xMagRange1);
  884. sFile.Register("Mag_CompX1", xMagCompX1);
  885. sFile.Register("Mag_CompY1", xMagCompY1);
  886. sFile.Register("Mag_Range2", xMagRange2);
  887. sFile.Register("Mag_CompX2", xMagCompX2);
  888. sFile.Register("Mag_CompY2", xMagCompY2);
  889. sFile.Register("Mag_Range3", xMagRange3);
  890. sFile.Register("Mag_CompX3", xMagCompX3);
  891. sFile.Register("Mag_CompY3", xMagCompY3);
  892. sFile.Register("Mag_Range4", xMagRange4);
  893. sFile.Register("Mag_CompX4", xMagCompX4);
  894. sFile.Register("Mag_CompY4", xMagCompY4);
  895. //ScanRotate修正
  896. xDouble scanRotate = new xDouble();
  897. scanRotate.AssignValue(this.scanRotCor);
  898. sFile.Register("ScanRotateCorrect", scanRotate);
  899. //PixelSize_Y轴补偿
  900. xDouble pscor = new xDouble();
  901. pscor.AssignValue(this.pixelSizeCor);
  902. sFile.Register("PixelSizeYCorrect", pscor);
  903. if (isStoring)
  904. {
  905. sFile.Serialize(true, xml, rootNode);
  906. }
  907. else
  908. {
  909. sFile.Serialize(false, xml, rootNode);
  910. this.is_Photograph = isPhotograph.value();
  911. this.m_pt = ptDepostion.value();
  912. this.Tilt = isTilt.value();
  913. this.EDS = isEDS.value();
  914. this.m_ptTemp = ptELYFile.value();
  915. this.m_fibTemp = fibELYFile.value();
  916. this.m_fMode = focusmode.value();
  917. this.stretch_Magnification = Convert.ToSingle(stretchMagnification.value());
  918. this.location_Magnification = Convert.ToSingle(locationMagnification.value());
  919. this.location_Voltage = Convert.ToSingle(locationVoltage.value());
  920. this.photograph_Magnification = Convert.ToSingle(photographMagnification.value());
  921. this.photograph_Voltage = Convert.ToSingle(photographVoltage.value());
  922. this.correction_Angle = Convert.ToSingle(correctionAngle.value());
  923. this.m_SampleName = sampleType.value();
  924. this.firm = _firm.value();
  925. this.ZDistance = Convert.ToSingle(ZDistance.value());
  926. this.EDSZ = Convert.ToSingle(xEDSZ.value());
  927. this.EDSV = Convert.ToSingle(xEDSV.value());
  928. this.EDSA = Convert.ToSingle(xEDSA.value());
  929. this.IsFIBDo = isFIBDo.value();
  930. this.IsFIBAutoBC = isFIBAutoBC.value();
  931. this.FIBB = Convert.ToSingle(xFIBB.value());
  932. this.FIBC = Convert.ToSingle(xFIBC.value());
  933. this.MagComp = isMagComp.value();
  934. this.MagRange1 = Convert.ToSingle(xMagRange1.value());
  935. this.MagCompX1 = Convert.ToSingle(xMagCompX1.value());
  936. this.MagCompY1 = Convert.ToSingle(xMagCompY1.value());
  937. this.MagRange2 = Convert.ToSingle(xMagRange2.value());
  938. this.MagCompX2 = Convert.ToSingle(xMagCompX2.value());
  939. this.MagCompY2 = Convert.ToSingle(xMagCompY2.value());
  940. this.MagRange3 = Convert.ToSingle(xMagRange3.value());
  941. this.MagCompX3 = Convert.ToSingle(xMagCompX3.value());
  942. this.MagCompY3 = Convert.ToSingle(xMagCompY3.value());
  943. this.MagRange4 = Convert.ToSingle(xMagRange4.value());
  944. this.fMagCompX4 = Convert.ToSingle(xMagCompX4.value());
  945. this.MagCompY4 = Convert.ToSingle(xMagCompY4.value());
  946. this.ScanRotCor = Convert.ToSingle(scanRotate.value());
  947. this.PixelSizeCor = Convert.ToSingle(pscor.value());
  948. }
  949. }
  950. }
  951. }