DAS  3.1.6 - 18/09/2017
dco.h
Go to the documentation of this file.
1 #ifndef DCO_LIBRARY
2 #define DCO_LIBRARY
3 
4 #include "dcl.h"
5 
22 #if defined(_WIN32) || defined(__WIN32__)
23  #if defined(_MSC_VER)
24  #ifdef DCO_STATIC_LIBRARY
25  #define DTA_LIB
26  #else
27  #ifdef DCO_SOURCE_CODE
28  #define DTA_LIB __declspec(dllexport)
29  #else
30  #define DTA_LIB __declspec(dllimport)
31  #endif
32  #endif
33  #else
34  #if defined(__BORLANDC__)
35  #ifdef DCO_SOURCE_CODE
36  #define DTA_LIB _export
37  #else
38  #define DTA_LIB _import
39  #endif
40  #endif
41  #endif
42 #else
43  // UNIX
44  #define DTA_LIB
45 #endif
46 
53 {
54 public:
55 
57  enum REVISION {
61  WINDRIVER
62  };
63 
65  enum STATUS {
69  FILTERMOVING
70  };
71 
73  enum START_MODE {
75  COOLER_IS_ON
76  };
77 
80  FIXED_GAIN = 1,
81  DOUBLE_GAIN = 2,
82  GAIN_127 = 3,
83  AD_9826 = 4,
84  };
85 
88  DECIMATION_PRESENT
89  };
90 
92  SEL_GAIN = 1,
94  SEL_FILTERS
95  };
96 
97 
98  CameraObject(void);
99 
104  CameraObject(const char * CameraConfigFile, START_MODE StartMode = COOLER_IS_OFF);
105 
107  ~CameraObject();
108 
115  bool Open(const char * CameraConfigFile, START_MODE StartMode = COOLER_IS_OFF, int camAdd = -1, int subAdd = -1);
116 
117  bool Load(const char * CameraConfigFile);
118 
121  int Id();
122 
125  void Close();
126 
131  void ImageSize(int & XDim, int & YDim);
132 
136  U32 ImageSize();
137 
138  void CCDSize(int & XDim, int & YDim);
139 
144  void PixelSize(double & XDim, double & YDim);
145 
153  bool Image(bool Light, double Exposure, U16 * mat);
154 
163  bool Sequence(bool Light, double Exposure, int NumOfFrames, U16 * mat[]);
164 
165  int SequenceCount();
166 
170  int Status();
171 
174  void Stop();
175 
179  bool Fast();
180 
184  void Fast(bool Mode);
185 
189  bool Trigger();
190 
194  void Trigger(bool Mode);
195 
202  void ROI(int XStart, int YStart, int XWidth, int YHeight);
203 
210  void ROI(int * XStart, int * YStart, int * XWidth, int * YHeight);
211 
215  void ROI(bool roi);
216 
217  bool ROI();
218 
223  void Binning(int Hor = 1, int Ver = 1);
224 
229  void Binning(int * Hor, int * Ver);
230 
234  void TemperatureSet(double Celsius);
235 
238  double TemperatureSet();
239 
242  double Temperature();
243 
246  bool Cooler();
247  void Cooler(int enable);
248 
249  void SetFanSpeed(double speed);
250  double FanSpeed();
251 
252  int Plug(int parCnt, int * param);
253 
260  bool Power(double Pow);
261 
265  double Power();
266 
270  bool Gain(int CCDgain);
271 
275  int Gain();
276 
283  bool Gain(int UGain, int Offset, int Range);
284 
290  void Gain(int * UGain, int * Offset, int * Range);
291 
294  double GainValue(bool preset = false, int idx = 0, double * mVoffset = 0);
295 
296  int BitDecimation();
297  void BitDecimation(int val);
298 
305  bool Filter(int Speed, int Torque, int Offset);
306 
312  void Filter(int * Speed, int * Torque, int * Offset);
313 
318  bool Filter(int Flt);
319 
323  void Filter(bool Calib);
324 
327  int Filter();
328 
331  bool IsFilterWheel();
332 
336  void SubAdd(int Camera);
337 
341  int SubAdd();
342 
346  int Downloading();
347 
351  double Countdown();
352 
356  U32 Address();
357 
360  int Properties(int selector);
361 
367  int Ver(REVISION Who = LIBRARY, char * Version = 0);
368 
372  U32 Serial();
373 
378  const char * ErrorMessage(int Code);
379 
382  const char * CameraName();
383 
386  const char * CcdName();
387 
391  int ErrorCode();
392 
393  int UsedPort() { return Port; }
394  void Reentrant(bool ena) { Reent = ena; }
395 
396 protected:
397  int TaskSet(void);
398  void TaskSet(int Set);
399 
400 private:
401  int Port;
402  bool Reent;
403 };
404 
405 #endif
START_MODE
Definition: dco.h:73
bool Reent
Definition: dco.h:402
PROPERTIES_SELECTOR
Definition: dco.h:91
FDLPCI version (FPGA Version of the fast parallel interface on PCI bus)
Definition: dco.h:60
int Port
Definition: dco.h:401
PROPERTIES_GAIN
Definition: dco.h:79
int Mode
Definition: DAS_Spat.c:108
#define Image
Definition: Dildef.h:181
#define DTA_LIB
Definition: dco.h:44
short unsigned U16
2 byte without sign, range 0-65535
Definition: dcldef.h:375
REVISION
Definition: dco.h:57
unsigned long U32
4 byte without sign, range 0-4294967295
Definition: dcldef.h:376
void Status(char *tit)
Writes information's on the Status label .
Definition: Load.c:1556
When the camera start the cooler initialized and setted to off.
Definition: dco.h:74
Camera is ready.
Definition: dco.h:66
void Reentrant(bool ena)
Definition: dco.h:394
int UsedPort()
Definition: dco.h:393
Function prototypes.
unsigned char Port
DCO version, the revision of this library!
Definition: dco.h:58
Exposure in progress.
Definition: dco.h:67
DCL version, the revision of the base library.
Definition: dco.h:59
PROPERTIES_DECIMATION
Definition: dco.h:86
Downloading in progress.
Definition: dco.h:68
Create the camera object. The use of this library is very simple, as example view the following code ...
Definition: dco.h:52
Definition: Dildef.h:254
______________________________________________________________________________________
Generated on Mon Sep 18 2017 11:44:08 for DAS - Rel. 3.1.6 - 18/09/2017.