API
ocam2_sdk.h
Go to the documentation of this file.
1 /** -- FIRSTLIGHT --
2  \file ocam2_sdk.h
3 
4  \brief The purpose of the libocam2sdk library is to provide an easy way to achieve ocam2 specific opĂ©ration.
5  The main feature is ocam2 raw image descrambling.
6 
7  \author FIRSTLIGHT
8 
9  \note You will find in this header ocam2 camera characteristic constants and functions protoypes.
10 */
11 
12 
13 #ifndef OCAM2_SDK_H
14 #define OCAM2_SDK_H
15 
16 /** Amplifier width */
17 #define OCAM2_AMPLI_WIDTH 60
18 /** Amplifier width raw */
19 #define OCAM2_AMPLI_WIDTH_RAW 66
20 /** Amplifier prescan pixels number */
21 #define OCAM2_AMPLI_PRESCAN (OCAM2_AMPLI_WIDTH_RAW-OCAM2_AMPLI_WIDTH)
22 
23 /** Amplifier height */
24 #define OCAM2_AMPLI_HEIGHT 120
25 
26 /** 2^14 */
27 #define OCAM2_PIXEL_MAX_VAL /*16383*/32767
28 /** -2^14 */
29 #define OCAM2_PIXEL_MIN_VAL /*(-16384)*/(-32768)
30 
31 /** 16bit witdth */
32 #define OCAM2_IMAGE_WIDTH_NORMAL 240
33 /** 16bit witdth */
34 #define OCAM2_IMAGE_HEIGHT_NORMAL 240
35 /** 57600 pixels(16bit witdth) per image area (240x240) */
36 #define OCAM2_PIXELS_IMAGE_NORMAL (OCAM2_IMAGE_WIDTH_NORMAL*OCAM2_IMAGE_HEIGHT_NORMAL)
37 /** 8bit witdth */
38 #define OCAM2_IMAGE_WIDTH_RAW_NORMAL 1056
39 /** 8bit witdth */
40 #define OCAM2_IMAGE_HEIGHT_RAW_NORMAL 121
41 /** 63888 pixels(16bit witdth) in raw image (including non-image pixels : 66x121x8) */
42 #define OCAM2_PIXELS_RAW_NORMAL ((OCAM2_IMAGE_WIDTH_RAW_NORMAL*OCAM2_IMAGE_HEIGHT_RAW_NORMAL)/2)
43 
44 /** 16bit witdth*/
45 #define OCAM2_IMAGE_WIDTH_CROPPING240x120 120
46 /** 16bit witdth*/
47 #define OCAM2_IMAGE_HEIGHT_CROPPING240x120 120
48 /** 14400 pixels(16bit witdth) per image area (120x120) */
49 #define OCAM2_PIXELS_IMAGE_CROPPING240x120 (OCAM2_IMAGE_WIDTH_CROPPING240x120*OCAM2_IMAGE_HEIGHT_CROPPING240x120)
50 /** 8bit witdth*/
51 #define OCAM2_IMAGE_WIDTH_RAW_CROPPING240x120 1056
52 /** 8bit witdth*/
53 #define OCAM2_IMAGE_HEIGHT_RAW_CROPPING240x120 61
54 /** 32208 pixels(16bit witdth) in raw image (including non-image pixels : 66x61x8)*/
55 #define OCAM2_PIXELS_RAW_CROPPING240x120 ((OCAM2_IMAGE_WIDTH_RAW_CROPPING240x120*OCAM2_IMAGE_HEIGHT_RAW_CROPPING240x120)/2)
56 
57 /** 16bit witdth*/
58 #define OCAM2_IMAGE_WIDTH_CROPPING240x128 128
59 /** 16bit witdth*/
60 #define OCAM2_IMAGE_HEIGHT_CROPPING240x128 128
61 /** 16384 pixels(16bit witdth) per image area (128x128) */
62 #define OCAM2_PIXELS_IMAGE_CROPPING240x128 (OCAM2_IMAGE_WIDTH_CROPPING240x128*OCAM2_IMAGE_HEIGHT_CROPPING240x128)
63 /** 8bit witdth*/
64 #define OCAM2_IMAGE_WIDTH_RAW_CROPPING240x128 1056
65 /** 8bit witdth*/
66 #define OCAM2_IMAGE_HEIGHT_RAW_CROPPING240x128 65
67 /** 34320 pixels(16bit witdth) in raw image (including non-image pixels : 66x65x8)*/
68 #define OCAM2_PIXELS_RAW_CROPPING240x128 ((OCAM2_IMAGE_WIDTH_RAW_CROPPING240x128*OCAM2_IMAGE_HEIGHT_RAW_CROPPING240x128)/2)
69 
70 /** 16bit witdth*/
71 #define OCAM2_IMAGE_WIDTH_BINNING2x2 120
72 /** 16bit witdth*/
73 #define OCAM2_IMAGE_HEIGHT_BINNING2x2 120
74 /** 14400 pixels(16bit witdth) per image area (120x120) */
75 #define OCAM2_PIXELS_IMAGE_BINNING2x2 (OCAM2_IMAGE_WIDTH_BINNING2x2*OCAM2_IMAGE_HEIGHT_BINNING2x2)
76 /** 8bit witdth*/
77 #define OCAM2_IMAGE_WIDTH_RAW_BINNING2x2 1056
78 /** 8bit witdth*/
79 #define OCAM2_IMAGE_HEIGHT_RAW_BINNING2x2 62
80 /** 32736 pixels(16bit witdth) in raw image (including non-image pixels : 66x62x8) */
81 #define OCAM2_PIXELS_RAW_BINNING2x2 ((OCAM2_IMAGE_WIDTH_RAW_BINNING2x2*OCAM2_IMAGE_HEIGHT_RAW_BINNING2x2)/2)
82 /** Number of identical pixel in raw image */
83 #define OCAM2_NB_IDENTICAL_PIXELS_BINNING2x2 2
84 /** Offset for second chunk */
85 #define OCAM2_BINNING2x2_OFFSET (OCAM2_PIXELS_IMAGE_NORMAL - (OCAM2_PIXELS_IMAGE_BINNING2x2/2*OCAM2_NB_IDENTICAL_PIXELS_BINNING2x2))
86 
87 /** 16bit witdth*/
88 #define OCAM2_IMAGE_WIDTH_BINNING3x3 80
89 /** 16bit witdth*/
90 #define OCAM2_IMAGE_HEIGHT_BINNING3x3 80
91 /** 6400 pixels(16bit witdth) per image area (80x80) */
92 #define OCAM2_PIXELS_IMAGE_BINNING3x3 (OCAM2_IMAGE_WIDTH_BINNING3x3*OCAM2_IMAGE_HEIGHT_BINNING3x3)
93 /** 8bit witdth*/
94 #define OCAM2_IMAGE_WIDTH_RAW_BINNING3x3 1056
95 /** 8bit witdth*/
96 #define OCAM2_IMAGE_HEIGHT_RAW_BINNING3x3 41
97 /** 22176 pixels(16bit witdth) in raw image (including non-image pixels : 66x42x8)*/
98 #define OCAM2_PIXELS_RAW_BINNING3x3 ((OCAM2_IMAGE_WIDTH_RAW_BINNING3x3*OCAM2_IMAGE_HEIGHT_RAW_BINNING3x3)/2)
99 /** Number of identical pixel in raw image */
100 #define OCAM2_NB_IDENTICAL_PIXELS_BINNING3x3 3
101 /** Offset for second chunk */
102 #define OCAM2_BINNING3x3_OFFSET (OCAM2_PIXELS_IMAGE_NORMAL - (OCAM2_PIXELS_IMAGE_BINNING3x3/2*OCAM2_NB_IDENTICAL_PIXELS_BINNING3x3))
103 
104 /** 16bit witdth*/
105 #define OCAM2_IMAGE_WIDTH_BINNING4x4 60
106 /** 16bit witdth*/
107 #define OCAM2_IMAGE_HEIGHT_BINNING4x4 60
108 /** 3600 pixels(16bit witdth) per image area (60x60) */
109 #define OCAM2_PIXELS_IMAGE_BINNING4x4 (OCAM2_IMAGE_WIDTH_BINNING4x4*OCAM2_IMAGE_HEIGHT_BINNING4x4)
110 /** 8bit witdth*/
111 #define OCAM2_IMAGE_WIDTH_RAW_BINNING4x4 1056
112 /** 8bit witdth*/
113 #define OCAM2_IMAGE_HEIGHT_RAW_BINNING4x4 31
114 /** 16896 pixels(16bit witdth) in raw image (including non-image pixels : 66x32x8) */
115 #define OCAM2_PIXELS_RAW_BINNING4x4 ((OCAM2_IMAGE_WIDTH_RAW_BINNING4x4*OCAM2_IMAGE_HEIGHT_RAW_BINNING4x4)/2)
116 /** Number of identical pixel in raw image */
117 #define OCAM2_NB_IDENTICAL_PIXELS_BINNING4x4 4
118 /** Offset for second chunk */
119 #define OCAM2_BINNING4x4_OFFSET (OCAM2_PIXELS_IMAGE_NORMAL - (OCAM2_PIXELS_IMAGE_BINNING4x4/2*OCAM2_NB_IDENTICAL_PIXELS_BINNING4x4))
120 
121 /** 16bit witdth*/
122 #define OCAM2_IMAGE_WIDTH_2_TRACK 240
123 /** 16bit witdth*/
124 #define OCAM2_IMAGE_HEIGHT_2_TRACK 2
125 /** 480 pixels(16bit witdth) per image area (240x2) */
126 #define OCAM2_PIXELS_IMAGE_2_TRACK (OCAM2_IMAGE_WIDTH_2_TRACK*OCAM2_IMAGE_HEIGHT_2_TRACK)
127 /** 8bit witdth*/
128 #define OCAM2_IMAGE_WIDTH_RAW_2_TRACK 1056
129 /** 8bit witdth*/
130 #define OCAM2_IMAGE_HEIGHT_RAW_2_TRACK 2
131 /** 16896 pixels(16bit witdth) in raw image (including non-image pixels : 66x32x8) */
132 #define OCAM2_PIXELS_RAW_2_TRACK ((OCAM2_IMAGE_WIDTH_RAW_2_TRACK*OCAM2_IMAGE_HEIGHT_RAW_2_TRACK)/2)
133 /** Number of identical pixel in raw image */
134 #define OCAM2_NB_IDENTICAL_PIXELS_2_TRACK 1
135 /** Offset for second chunk */
136 #define OCAM2_2_TRACK_OFFSET (OCAM2_PIXELS_IMAGE_NORMAL - (OCAM2_PIXELS_IMAGE_2_TRACK/2*OCAM2_NB_IDENTICAL_PIXELS_2_TRACK))
137 
138 /** 16bit witdth*/
139 #define OCAM2_IMAGE_WIDTH_4_TRACK 240
140 /** 16bit witdth*/
141 #define OCAM2_IMAGE_HEIGHT_4_TRACK 4
142 /** 480 pixels(16bit witdth) per image area (240x2) */
143 #define OCAM2_PIXELS_IMAGE_4_TRACK (OCAM2_IMAGE_WIDTH_4_TRACK*OCAM2_IMAGE_HEIGHT_4_TRACK)
144 /** 8bit witdth*/
145 #define OCAM2_IMAGE_WIDTH_RAW_4_TRACK 1056
146 /** 8bit witdth*/
147 #define OCAM2_IMAGE_HEIGHT_RAW_4_TRACK 3
148 /** 16896 pixels(16bit witdth) in raw image (including non-image pixels : 66x32x8) */
149 #define OCAM2_PIXELS_RAW_4_TRACK ((OCAM2_IMAGE_WIDTH_RAW_4_TRACK*OCAM2_IMAGE_HEIGHT_RAW_4_TRACK)/2)
150 /** Number of identical pixel in raw image */
151 #define OCAM2_NB_IDENTICAL_PIXELS_4_TRACK 1
152 /** Offset for second chunk */
153 #define OCAM2_4_TRACK_OFFSET (OCAM2_PIXELS_IMAGE_NORMAL - (OCAM2_PIXELS_IMAGE_4_TRACK/2*OCAM2_NB_IDENTICAL_PIXELS_4_TRACK))
154 
155 
156 /** 16bit witdth*/
157 #define OCAM2_IMAGE_WIDTH_BINNING1x3 240
158 /** 16bit witdth*/
159 #define OCAM2_IMAGE_HEIGHT_BINNING1x3 80
160 /** 19200 pixels(16bit witdth) per image area (240x80) */
161 #define OCAM2_PIXELS_IMAGE_BINNING1x3 (OCAM2_IMAGE_WIDTH_BINNING1x3*OCAM2_IMAGE_HEIGHT_BINNING1x3)
162 /** 8bit witdth*/
163 #define OCAM2_IMAGE_WIDTH_RAW_BINNING1x3 1056
164 /** 8bit witdth*/
165 #define OCAM2_IMAGE_HEIGHT_RAW_BINNING1x3 41
166 /** 22176 pixels(16bit witdth) in raw image (including non-image pixels : 66x42x8)*/
167 #define OCAM2_PIXELS_RAW_BINNING1x3 ((OCAM2_IMAGE_WIDTH_RAW_BINNING1x3*OCAM2_IMAGE_HEIGHT_RAW_BINNING1x3)/2)
168 /** Number of identical pixel in raw image */
169 #define OCAM2_NB_IDENTICAL_PIXELS_BINNING1x3 1
170 /** Offset for second chunk */
171 #define OCAM2_BINNING1x3_OFFSET (OCAM2_PIXELS_IMAGE_NORMAL - (OCAM2_PIXELS_IMAGE_BINNING1x3/2*OCAM2_NB_IDENTICAL_PIXELS_BINNING1x3))
172 
173 /** 16bit witdth*/
174 #define OCAM2_IMAGE_WIDTH_BINNING1x4 240
175 /** 16bit witdth*/
176 #define OCAM2_IMAGE_HEIGHT_BINNING1x4 60
177 /** 3600 pixels(16bit witdth) per image area (60x60) */
178 #define OCAM2_PIXELS_IMAGE_BINNING1x4 (OCAM2_IMAGE_WIDTH_BINNING1x4*OCAM2_IMAGE_HEIGHT_BINNING1x4)
179 /** 8bit witdth*/
180 #define OCAM2_IMAGE_WIDTH_RAW_BINNING1x4 1056
181 /** 8bit witdth*/
182 #define OCAM2_IMAGE_HEIGHT_RAW_BINNING1x4 31
183 /** 16896 pixels(16bit witdth) in raw image (including non-image pixels : 66x32x8) */
184 #define OCAM2_PIXELS_RAW_BINNING1x4 ((OCAM2_IMAGE_WIDTH_RAW_BINNING1x4*OCAM2_IMAGE_HEIGHT_RAW_BINNING1x4)/2)
185 /** Number of identical pixel in raw image */
186 #define OCAM2_NB_IDENTICAL_PIXELS_BINNING1x4 1
187 /** Offset for second chunk */
188 #define OCAM2_BINNING1x4_OFFSET (OCAM2_PIXELS_IMAGE_NORMAL - (OCAM2_PIXELS_IMAGE_BINNING1x4/2*OCAM2_NB_IDENTICAL_PIXELS_BINNING1x4))
189 
190 
191 /** Keep for compatibility */
192 #define OCAM2_IMAGE_WIDTH_BINNING OCAM2_IMAGE_WIDTH_BINNING2x2
193 /** Keep for compatibility */
194 #define OCAM2_IMAGE_HEIGHT_BINNING OCAM2_IMAGE_HEIGHT_BINNING2x2
195 /** Keep for compatibility */
196 #define OCAM2_PIXELS_IMAGE_BINNING OCAM2_PIXELS_IMAGE_BINNING2x2
197 /** Keep for compatibility */
198 #define OCAM2_IMAGE_WIDTH_RAW_BINNING OCAM2_IMAGE_WIDTH_RAW_BINNING2x2
199 /** Keep for compatibility */
200 #define OCAM2_IMAGE_HEIGHT_RAW_BINNING OCAM2_IMAGE_HEIGHT_RAW_BINNING2x2
201 /** Keep for compatibility */
202 #define OCAM2_PIXELS_RAW_BINNING OCAM2_PIXELS_RAW_BINNING2x2
203 /** Keep for compatibility */
204 #define OCAM2_BINNING_OFFSET OCAM2_BINNING2x2_OFFSET
205 
206 #ifndef OCAM2_IMAGE_NB_OFFSET
207 /** Offset of image number in raw image(bytes)*/
208 #define OCAM2_IMAGE_NB_OFFSET 8
209 #endif
210 /** Image number field width(bytes)*/
211 #define OCAM2_IMAGE_NB_SZ 4
212 
213 /**
214  \typedef ocam2_mode
215  \brief typedef of ocam2 camera mode
216 */
217 /**
218  \enum workMode
219  \brief Enum of ocam2 camera work mode
220 */
221 typedef enum workMode
222 {
223  /** Invalid */
225  /** Default mode */
227  /** Cropping 120 */
229  /** Binning 2x2 */
231  /** Binning 3x3 */
233  /** Binning 4x4 */
235  /** For compatibility(= Binning 2x2) */
237  /** Cropping 128 */
239  /** Binning 2 lignes */
241  /** Binning 4 lignes */
243  /** Binning 1x3 */
245  /** Binning 1x4 */
247  /** Number of mode */
248  OCAM2_NB_WORK_MODE = 10 /** Number of mode */
249 
251 
252 
253 /**
254  \typedef ocam2_rc
255  \brief Enum of ocam2 library return code
256 */
257 typedef enum
258 {
260  OCAM2_OK=0
261 
263 
264 /**
265  \typedef ocam2_id
266  \brief Library camera identifier
267 */
268 typedef int ocam2_id;
269 
270 /**
271  \typedef ocam2_camFirmVer
272  \brief Camera firmware release
273  For firmware build date before 18/03/2015, use
274  OCAM2_FIRM_V1 else OCAM2_FIRM_V2
275  You can know the camera firmware build using the command:
276  "firmware read"
277 */
278 typedef enum
279 {
281  OCAM2_FIRM_V2=2
282 
284 
285 /** Max number of camera managed by the sdk */
286 #define OCAM2_SDK_MAX_CAMERA 10
287 
288 #ifdef __cplusplus
289 extern "C" {
290 #endif
291 
292 /**
293  \fn const char * ocam2_sdkVersion()
294  \brief Return sdk version
295  \return sdk version as a string
296 */
297 const char * ocam2_sdkVersion();
298 
299 /**
300  \fn const char * ocam2_sdkBuild()
301  \brief Return sdk build
302  \return sdk build as a string
303 */
304 const char * ocam2_sdkBuild();
305 
306 /**
307  \fn ocam2_rc ocam2_init(ocam2_mode mode, const char *descrbFile, ocam2_id *id)
308  \brief Create a camera instance with the provided mode
309  \param[in] mode camera mode
310  \param[in] descrbFile descrambling file to use
311  \param[out] id camera identifier
312 
313  \return Return OK or Error
314 */
315 ocam2_rc ocam2_init(ocam2_mode mode, const char *descrbFile, ocam2_id *id);
316 
317 /**
318  \fn void ocam2_descramble(int id, unsigned int *number, short *image, const short *imageRaw)
319  \brief Create a camera instance with the provided mode
320  \param[in] id camera identifier
321  \param[out] number Image number
322  \param[out] image Descrambled image
323  \param[in] imageRaw Raw image
324 
325  \return none
326 */
327 void ocam2_descramble(ocam2_id id, unsigned int *number, short *image, const short *imageRaw);
328 
329 /**
330  \fn ocam2_rc ocam2_exit(ocam2_id id)
331  \brief Clear a camera instance
332  \param[in] id camera identifier
333 
334  \return Return OK or Error
335 */
337 
338 /**
339  \fn ocam2_mode ocam2_getMode(ocam2_id id)
340  \brief Return the camera mode
341  \param[in] id camera identifier
342 
343  \return camera mode as ocam2_mode
344 */
346 
347 /**
348  \fn const char *ocam2_modeStr(ocam2_mode mode)
349  \brief Return a description text for camera mode
350  \param[in] mode camera mode
351 
352  \return camera mode description as a string
353 */
354 const char *ocam2_modeStr(ocam2_mode mode);
355 
356 /* --- New flat bias --- */
357 
358 /**
359  \typedef ocam2_serialOut_func_t
360  \brief Callback used to send characters to the serial port
361  \param p private data
362  \param buffer characters to send to serial port
363  \param number number of character to send to serial port
364 */
365 typedef void (*ocam2_serialOut_func_t)(void *p, const char *buffer, int number);
366 
367 
368 /**
369  \fn ocam2_rc ocam2_sendBias(ocam2_id id, const char *biasFile, int offset, ocam2_serialOut_func_t cb, void *p, ocam2_camFirmVer camVer)
370  \brief Send bias image to the camera link serial port
371  \param[in] id camera identifier
372  \param[in] biasFile bias file
373  \param[in] offset offset to reach pixel in bias file(can be used to skip a header)
374  \param[in] cb callback, it must send the received characters to the camera link serial port
375  \param[in] p private data
376  \param[in] camVer camera firmware release
377 
378  \return Return OK or Error
379 */
380 ocam2_rc ocam2_sendBias(ocam2_id id, const char *biasFile, int offset, ocam2_serialOut_func_t cb, void *p, ocam2_camFirmVer camVer);
381 
382 /**
383  \fn ocam2_rc ocam2_sendFlat(ocam2_id id, const char *flatFile, int offset, ocam2_serialOut_func_t cb, void *p, ocam2_camFirmVer camVer)
384  \brief Send flat image to the camera link serial port
385  \param[in] id camera identifier
386  \param[in] flatFile flat file
387  \param[in] offset offset to reach pixel in bias file(can be used to skip a header)
388  \param[in] cb callback, it must send the received characters to the camera link serial port
389  \param[in] p private data
390  \param[in] camVer camera firmware release
391 
392  \return Return OK or Error
393 */
394 ocam2_rc ocam2_sendFlat(ocam2_id id, const char *flatFile, int offset, ocam2_serialOut_func_t cb, void *p, ocam2_camFirmVer camVer);
395 
396 
397 #ifdef __cplusplus
398 }
399 #endif
400 
401 #endif // OCAM2_SDK_H
402 
403 
404 
const char * ocam2_sdkBuild()
Return sdk build.
Definition: ocam2_sdk.c:117
int ocam2_id
Library camera identifier.
Definition: ocam2_sdk.h:268
ocam2_rc ocam2_init(ocam2_mode mode, const char *descrbFile, ocam2_id *id)
Create a camera instance with the provided mode.
Definition: ocam2_sdk.c:431
void ocam2_descramble(ocam2_id id, unsigned int *number, short *image, const short *imageRaw)
Create a camera instance with the provided mode.
Definition: ocam2_sdk.c:418
ocam2_camFirmVer
Camera firmware release For firmware build date before 18/03/2015, use OCAM2_FIRM_V1 else OCAM2_FIRM_...
Definition: ocam2_sdk.h:279
@ OCAM2_FIRM_V1
Definition: ocam2_sdk.h:280
@ OCAM2_FIRM_V2
Definition: ocam2_sdk.h:281
ocam2_rc
Enum of ocam2 library return code.
Definition: ocam2_sdk.h:258
@ OCAM2_OK
Definition: ocam2_sdk.h:260
@ OCAM2_ERROR
Definition: ocam2_sdk.h:259
workMode
Enum of ocam2 camera work mode.
Definition: ocam2_sdk.h:222
@ OCAM2_2_TRACK
Definition: ocam2_sdk.h:240
@ OCAM2_BINNING3x3
Definition: ocam2_sdk.h:232
@ OCAM2_BINNING4x4
Definition: ocam2_sdk.h:234
@ OCAM2_CROPPING240x120
Definition: ocam2_sdk.h:228
@ OCAM2_NB_WORK_MODE
Definition: ocam2_sdk.h:248
@ OCAM2_BINNING
Definition: ocam2_sdk.h:236
@ OCAM2_BINNING1x3
Definition: ocam2_sdk.h:244
@ OCAM2_BINNING1x4
Definition: ocam2_sdk.h:246
@ OCAM2_BINNING2x2
Definition: ocam2_sdk.h:230
@ OCAM2_4_TRACK
Definition: ocam2_sdk.h:242
@ OCAM2_UNKNOWN
Definition: ocam2_sdk.h:224
@ OCAM2_NORMAL
Definition: ocam2_sdk.h:226
@ OCAM2_CROPPING240x128
Definition: ocam2_sdk.h:238
enum workMode ocam2_mode
typedef of ocam2 camera mode
const char * ocam2_sdkVersion()
Return sdk version.
Definition: ocam2_sdk.c:111
ocam2_rc ocam2_exit(ocam2_id id)
Clear a camera instance.
Definition: ocam2_sdk.c:490
const char * ocam2_modeStr(ocam2_mode mode)
Return a description text for camera mode.
Definition: ocam2_sdk.c:77
ocam2_rc ocam2_sendFlat(ocam2_id id, const char *flatFile, int offset, ocam2_serialOut_func_t cb, void *p, ocam2_camFirmVer camVer)
Send flat image to the camera link serial port.
void(* ocam2_serialOut_func_t)(void *p, const char *buffer, int number)
Callback used to send characters to the serial port.
Definition: ocam2_sdk.h:365
ocam2_mode ocam2_getMode(ocam2_id id)
Return the camera mode.
Definition: ocam2_sdk.c:69
ocam2_rc ocam2_sendBias(ocam2_id id, const char *biasFile, int offset, ocam2_serialOut_func_t cb, void *p, ocam2_camFirmVer camVer)
Send bias image to the camera link serial port.