|
@@ -18,58 +18,98 @@ namespace OTSModelSharp.ServiceCenter
|
|
|
private COTSControlFunExport eds;
|
|
|
static IEDSController edsctrl = null;
|
|
|
private List<String> keyElenamelist = new List<string>();
|
|
|
- private bool delayQuant=false;
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
- public static IEDSController GetEDSController(string deviceType,int imgwidth,int imgheight,int expectCount,bool ifautoid,string knownelements)
|
|
|
+ public bool delayQuant=false;
|
|
|
+ /// <summary>
|
|
|
+ ///
|
|
|
+ /// </summary>
|
|
|
+ /// <param name="SemType">sem type</param>
|
|
|
+ /// <param name="deviceType"> eds type</param>
|
|
|
+ /// <param name="imgwidth"></param>
|
|
|
+ /// <param name="imgheight"></param>
|
|
|
+ /// <param name="expectCount"></param>
|
|
|
+ /// <param name="ifautoid"></param>
|
|
|
+ /// <param name="knownelements"></param>
|
|
|
+ /// <returns></returns>
|
|
|
+ public static IEDSController GetEDSController(string SemType,string deviceType,int imgwidth,int imgheight,int expectCount,bool ifautoid,string knownelements)
|
|
|
{
|
|
|
- // string deviceType = FileHelper.GetXMLInformations("EDSName");
|
|
|
-
|
|
|
+ // string deviceType = FileHelper.GetXMLInformations("EDSName");
|
|
|
+
|
|
|
if (edsctrl == null)
|
|
|
{
|
|
|
- if (deviceType == "FEI")
|
|
|
- {
|
|
|
- edsctrl = new FEIEDSController(expectCount,ifautoid,knownelements);
|
|
|
-
|
|
|
- }
|
|
|
- else if (deviceType == "Oxford")
|
|
|
- {
|
|
|
- edsctrl = new OxfordEDSController(expectCount,ifautoid,knownelements);
|
|
|
-
|
|
|
- }
|
|
|
- else if (deviceType == "Bruker")
|
|
|
+ switch (SemType)
|
|
|
{
|
|
|
- var ctrl = new EDSController("Bruker",expectCount,ifautoid,knownelements);
|
|
|
- //var delayQuant = Convert.ToBoolean(FileHelper.GetIfDelayQuantify());
|
|
|
- var delayQuant = false;//Now it has proved that this method won't increase the speed of xray analysis.So deactivate it here.
|
|
|
- ctrl.delayQuant = delayQuant;
|
|
|
- edsctrl = ctrl;
|
|
|
-
|
|
|
- }
|
|
|
- else if (deviceType == "OffLine")
|
|
|
- {
|
|
|
- edsctrl = new EDSController("OffLine",expectCount,ifautoid,knownelements);
|
|
|
-
|
|
|
-
|
|
|
- }
|
|
|
- else if (deviceType == "PicoSmart")
|
|
|
- {
|
|
|
- //edsctrl = new PicoSmartEDSController(deviceType, expectCount, ifautoid, knownelements);
|
|
|
- edsctrl = new PicoSmartEDSController(deviceType, imgwidth, imgheight, expectCount, ifautoid, knownelements);
|
|
|
- }
|
|
|
- else if (deviceType == "Coxm")
|
|
|
- {
|
|
|
- edsctrl = new CoxmEDSController(deviceType, imgwidth, imgheight, expectCount, ifautoid, knownelements);
|
|
|
+ case "FEI":
|
|
|
+ if (deviceType == "FEI")
|
|
|
+ {
|
|
|
+ edsctrl = new FEIEDSController(expectCount, ifautoid, knownelements);
|
|
|
+
|
|
|
+ }
|
|
|
+ else if (deviceType == "Oxford")
|
|
|
+ {
|
|
|
+ edsctrl = new OxfordEDSController(expectCount, ifautoid, knownelements);
|
|
|
+
|
|
|
+ }
|
|
|
+ else if (deviceType == "Bruker")
|
|
|
+ {
|
|
|
+ var ctrl = new EDSController("Bruker", expectCount, ifautoid, knownelements);
|
|
|
+ //var delayQuant = Convert.ToBoolean(FileHelper.GetIfDelayQuantify());
|
|
|
+ var delayQuant = false;//Now it has proved that this method won't increase the speed of xray analysis.So deactivate it here.
|
|
|
+ ctrl.delayQuant = delayQuant;
|
|
|
+ edsctrl = ctrl;
|
|
|
+
|
|
|
+ }
|
|
|
+ break;
|
|
|
+ case "ZEISS":
|
|
|
+ if (deviceType == "Oxford")
|
|
|
+ {
|
|
|
+ edsctrl = new OxfordEDSController(expectCount, ifautoid, knownelements);
|
|
|
+
|
|
|
+ }
|
|
|
+ else if (deviceType == "Bruker")
|
|
|
+ {
|
|
|
+ var ctrl = new EDSController("Bruker", expectCount, ifautoid, knownelements);
|
|
|
+ //var delayQuant = Convert.ToBoolean(FileHelper.GetIfDelayQuantify());
|
|
|
+ var delayQuant = false;//Now it has proved that this method won't increase the speed of xray analysis.So deactivate it here.
|
|
|
+ ctrl.delayQuant = delayQuant;
|
|
|
+ edsctrl = ctrl;
|
|
|
+
|
|
|
+ }
|
|
|
+ break;
|
|
|
+ case "Coxm":
|
|
|
+ edsctrl = new CoxmEDSController(SemType, deviceType, imgwidth, imgheight, expectCount, ifautoid, knownelements);
|
|
|
+ break;
|
|
|
+ case "PicoSmart":
|
|
|
+ edsctrl = new PicoSmartEDSController(SemType, deviceType, imgwidth, imgheight, expectCount, ifautoid, knownelements);
|
|
|
+ break;
|
|
|
+ case "ComposeEds"://coxm picosmart ComposeEds;coxm picosmart 电镜组合eds
|
|
|
+ if (deviceType == "Oxford")
|
|
|
+ {
|
|
|
+ edsctrl = new OxfordEDSController(expectCount, ifautoid, knownelements);
|
|
|
+
|
|
|
+ }
|
|
|
+ else if (deviceType == "Bruker")
|
|
|
+ {
|
|
|
+ var ctrl = new EDSController("Bruker", expectCount, ifautoid, knownelements);
|
|
|
+ //var delayQuant = Convert.ToBoolean(FileHelper.GetIfDelayQuantify());
|
|
|
+ var delayQuant = false;//Now it has proved that this method won't increase the speed of xray analysis.So deactivate it here.
|
|
|
+ ctrl.delayQuant = delayQuant;
|
|
|
+ edsctrl = ctrl;
|
|
|
+
|
|
|
+ }
|
|
|
+ break;
|
|
|
+ case "OffLine":
|
|
|
+ edsctrl = new EDSController("OffLine", expectCount, ifautoid, knownelements);
|
|
|
+ break;
|
|
|
+ default:
|
|
|
+ edsctrl = new EDSController("OffLine", expectCount, ifautoid, knownelements);
|
|
|
+ break;
|
|
|
}
|
|
|
edsctrl.SetResolution(imgwidth, imgheight);
|
|
|
-
|
|
|
-
|
|
|
}
|
|
|
return edsctrl;
|
|
|
}
|
|
|
|
|
|
- protected EDSController(string deviceType,int expectcount,bool ifautoid,string knownelements)
|
|
|
+ public EDSController(string deviceType,int expectcount,bool ifautoid,string knownelements)
|
|
|
{
|
|
|
|
|
|
eds = COTSControlFunExport.GetControllerInstance(deviceType);
|