using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace AuroraLaser.Coherent.Arm { public struct sNodeInfo { public int nExist; public string strNodeName; // Command Name public string strDisplayNodeName; // Display Name public string strKey; // Matching key, callback public int nNodeType; // 리턴 타입. public int IsCallBack; // Max CallBack 10set. public int priority; // 통신 우선 순위. 작을수록 우선. 0부터 시작 public int nDigit; // 배율. Pulse Power인 경우 1000 곱해야 한다. 이거 그냥 double로 해서 곱하는걸로? public int nKey; // Coherent용 Write 별로 and할 필요가 있다. 1,2,4,8,16~~~ public int nSettingValue; // Coherent용 Write 할 값(On/Off) // return data. public int nRet; public long lRet; public UInt16 n16Ret; public UInt32 n32Ret; public UInt64 n64Ret; public bool bRet; public double dRet; public string strRet; } public class csNodeType { public const int INT = 0; public const int DOUBLE = 1; public const int STRING = 2; public const int UINT16 = 3; public const int UINT32 = 4; public const int UINT64 = 5; public const int BYTE = 6; public const int BOOL = 7; } public class csReadCOH { public const int INIT_COMMUNICATION = 0; // Laser ready for communication. 0=not ready, 1=ready public const int EMS_STATUS = 1; // Emission status. 0=off, 1=on public const int MAINS_STATUS = 2; // Card Main supply status.start 먹었는지 확인용. start이후 이 값이 1로 변경되어야 사용할 수 있다. // public const int SPO = 3; // PSU Output state. 0=off, 1=on. start 이후 이 값이 on되면 레이저 발진 가능. ems로 대체 확인. spo는 0,1,2 public const int WARNING_STATUS = 3; // Warning Status. 0=no warning, 1=warning in the system. public const int ERROR_STATUS = 4; // Error Status. 0=no error, 1=error in the system. // public const int FIBER_ERROR_STATUS = 6; // Fiber Error status public const int PILOT_LASER_STATE = 5; // Pilot Laser state public const int CONTROL_MODE = 6; // Local (1), Remote(2) need Local mode to use pilot laser. //public const int WATER_FLOW_MAIN = 7; // Water flow state L/m //public const int WATER_TEMP_MAIN = 8; // Water temp 0.1 degree //public const int HUMIDITY_MAIN = 9; // Humidity 0.1% public const int ERROR_MESSAGE = 7; // Alarm Message. public const int LASER_POWER_CENTER = 8; // Laser Power CENTER Analog * ?? (Max 1500) public const int LASER_POWER_RING = 9; // Laser Power RING Analog * ?? (Max 2500) public const int SYSTEM_CONTROL_STATUS = 10; public const int DC_VOLTAGE = 11; public const int WARNING_MESSAGE = 12; //public const int LAST_ERROR_LOG = 15; //public const int FAN_CONTROLLER_FREQUENCY = 16; //public const int FAN_SPEED = 17; public const int LASER_START = 13; public const int MAX = 14; } public class csWriteCOH { // return Value OK/ERROR/OK resetting. public const int SYSTEM_START = 0; // Bool !start. public const int LASER_START = 1; // Bool !spo 1/0 public const int PILOT_LASER = 2; // Bool !abo 1/0 public const int LASER_RESET = 3; // Bool !reset public const int CONTROL_MODE = 4; // Bool !spm 1(local)/2(remote) public const int CLEAR_FAULT = 5; public const int POWER_LEVEL = 6; public const int POWER_CENTER = 7; public const int POWER_RING = 8; public const int MAX = 9; } }