tbf/TestBenchFramework/BenchControl/Cameras/IdcCamera/IdcEnums.cs
2014-07-28 09:56:40 +02:00

66 lines
1.7 KiB
C#

using System;
namespace TBF.BenchControl.Cameras.IdcCamera
{
/// <summary>IDC camera states</summary>
public enum IdcState
{
Unchanged = -1, /// not a state - used in state transition tables
NotConnected = 0, /// 'gray'
Idle, /// 'green'
Busy, /// 'yellow' or 'orange'
OpCompleted, /// 'green'
OpFailed, /// 'red'
Halted, /// 'red'
}
public enum RetVal
{
OK = 0,
HOST_START = 1000, /// Start of error codes from HOST part of the software
Busy, /// OK - camera operation in progress
OpInterrupted, /// OK - camera operation interrupted
OpFailed, /// RetVal - Camera operation failed
CameraNotConnected, /// RetVal - Camera is not connected
SequenceError, /// RetVal - Invalid sequence of calls
InvalidComPortNr, /// RetVal - Invalid COM-port number
CannotOpenComPort, /// RetVal - Cannot open COM-port
CannotCommWithCamera, /// RetVal - Cannot communicate with the camera
CommTimeout, /// RetVal - Communication timeout
CommError, /// RetVal - Unknown error during communication
ShutdownInProgress, /// RetVal - System is shutting down
FatalError, /// RetVal - Fatal error
}
public struct IdcTransition
{
public RetVal RetVal;
public IdcState NewState;
public IdcTransition(RetVal retVal, IdcState newState)
{
this.RetVal = retVal;
this.NewState = newState;
}
}
public enum FileFormat
{
Bmp,
Jpeg,
}
public enum StreamType
{
Full,
SubSampled,
Focus,
}
enum WorkerCommand
{
StopOp, /// Stop the current operation
Timeout, /// The expected WorkerCommand(s) have not arrived in time
}
}