123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace SmartSEMControl
- {
- //sealed, 避免继承出新类造成重构
- public sealed class FactoryHardware
- {
- //只读的静态成员
- private static readonly FactoryHardware instance = new FactoryHardware();
- // Explicit static constructor to tell C# compiler
- // not to mark type as beforefieldinit
- //C#的静态构造函数只有在当其类的实例被创建或者有静态成员被引用时执行,
- //在整个应用程序域中只会被执行一次。
- static FactoryHardware()
- {
- }
- private FactoryHardware()
- {
- }
- //使用这个实例
- public static FactoryHardware Instance
- {
- get
- {
- return instance;
- }
- }
- //其他使用的成员变量
- private ISEMControl m_iSEM = new SmartSEM(); //成员变量
- public ISEMControl ISEM
- {
- get { return m_iSEM; }
- } //属性,只能当前类创建
-
- }
- //SEM控制
- public interface ISEMControl
- {
- //缩放
- float GetMagnification();
- Boolean SetMagnification(float set);
- //焦距
- float GetWorkingDistance();
- Boolean SetWorkingDistance(float set);
- //亮度
- float GetBrightness();
- Boolean SetBrightness(float set);
- //对比度
- float GetContrast();
- Boolean SetContrast(float set);
- //自动亮度
- float GetAutoVideo();
- Boolean SetAutoVideoOff();
- Boolean SetAutoVideoBrightness();
- Boolean SetAutoVideoContrast();
- Boolean SetAutoVideoBrightnessAndContrast();
- //消像散
- float GetAstigmatismX();
- float GetAstigmatismY();
- Boolean SetAstigmatismX(float set);
- Boolean SetAstigmatismY(float set);
- //自动消像散
- Boolean CmdAutoStig();
- //角度补偿
- float GetTiltAngle();
- Boolean SetTiltAngle(float set);
- //抓图
- Boolean GrabImage(String filename, short xoff, short yoff, short width, short height, short type);
- //解冻
- Boolean ImageFrozen();
- //冻结
- Boolean ImageLive();
- //获取分辨率
- int[] GetImageStore();
- //设置分辨率
- Boolean SetImageStore(float set);
- //样品台
- float[] GetStagePosition();
- float GetStageAtX();
- float GetStageAtY();
- float GetStageAtZ();
- float GetStageAtT();
- float GetStageAtR();
- float GetStageAtM();
- Boolean SetStageGotoX(float set);
- Boolean SetStageGotoY(float set);
- Boolean SetStageGotoZ(float set);
- Boolean SetStageGotoT(float set);
- Boolean SetStageGotoR(float set);
- Boolean SetStageGotoM(float set);
- Boolean MoveStageXY(float x, float y);
- //Scan Rotate角度接口
- float GetScanRotation();
- Boolean SetScanRotation(float set);
- //像素读取PixelSize
- float GetPixelSize();
- //电子束校正设置
- float GetTiltCorrection();
- Boolean SetTiltCorrectionOff();
- Boolean SetTiltCorrectionOn();
- //开启电压
- Boolean CmdOpenVoltage();
- //关闭电压
- Boolean CmdCloseVoltage();
- //图像类型切换
- Boolean DetectorType(float set);
- //执行宏文件
- Boolean CMDMCFFilename(String filename);
- //清除控件
- Boolean Dispose();
- }
- interface FIBControl
- {
- //FIB的控制
- }
- interface PtControl
- {
- //Pt的控制
- //PT针插入
- void InsertPT();
- //PT针退出
- void OutputPT();
- }
- interface StageControl
- {
- //样品台控制
- }
- interface CommonMsg
- {
- //通用的信息
- }
- }
|