Main Page | Files | Data Structures | Functions | Global Variables |

gpiv-trig.h File Reference

module for triggering lightsource(s) and camera(s) using RTAI More...

Go to the source code of this file.

Data Structures

struct  __GpivTrigTime
 Trigger parameters. More...
struct  __GpivTrigPar
 Whether elements of __GpivTrigTime have been set. More...

Defines

#define GPIV_TRIGPAR_DEFAULT__CAP   250
#define GPIV_TRIGPAR_DEFAULT__LPW   0.02
#define GPIV_TRIGPAR_DEFAULT__T2L   0.19
#define GPIV_TRIGPAR_DEFAULT__DT   10
#define GPIV_TRIGPAR_DEFAULT__MODE   2
#define GPIV_TRIGPAR_DEFAULT__CYCLES   1
#define GPIV_TRIGPAR_DEFAULT__INCR_DT   1
#define GPIV_TRIGPAR_KEY   "TRIG"
#define GPIV_TRIGPAR_KEY__CAP   "Ttime_cap"
#define GPIV_TRIGPAR_KEY__LPW   "Ttime_lpw"
#define GPIV_TRIGPAR_KEY__T2L   "Ttime_t2l"
#define GPIV_TRIGPAR_KEY__DT   "Ttime_dt"
#define GPIV_TRIGPAR_KEY__MODE   "Ttime_mode"
#define GPIV_TRIGPAR_KEY__CYCLES   "Ttime_cycles"
#define GPIV_TRIGPAR_KEY__INCR_DT   "Ttime_incr_dt"
#define GPIV_TRIGPAR_CAP_MIN   100
#define GPIV_TRIGPAR_LPW_MIN   0.02
#define GPIV_TRIGPAR_T2L_MIN   0.19
#define GPIV_TRIGPAR_DT_MIN   0.10
#define GPIV_TRIGPAR_MODE_MIN   1
#define GPIV_TRIGPAR_CYCLES_MIN   1
#define GPIV_TRIGPAR_INCR_DT_MIN   0.01
#define GPIV_TRIGPAR_CAP_MAX   1000
#define GPIV_TRIGPAR_LPW_MAX   0.02
#define GPIV_TRIGPAR_T2L_MAX   0.19
#define GPIV_TRIGPAR_DT_MAX   100
#define GPIV_TRIGPAR_MODE_MAX   6
#define GPIV_TRIGPAR_CYCLES_MAX   1
#define GPIV_TRIGPAR_INCR_DT_MAX   20
#define GPIV_NANO2MILI   0.001 * 0.001
#define GPIV_MILI2NANO   1000 * 1000

Typedefs

typedef __GpivTrigTime GpivTrigTime
typedef __GpivTrigPar GpivTrigPar

Enumerations

enum  GpivFifo { GPIV_FIFO_TIMING_PARAMETER = 1, GPIV_FIFO_START_COMMAND, GPIV_FIFO_STOP_COMMAND, GPIV_FIFO_ERROR, GPIV_FIFO_JITTER }
enum  GpivTimingMode { GPIV_TIMER_MODE__PERIODIC = 1, GPIV_TIMER_MODE__DURATION, GPIV_TIMER_MODE__ONE_SHOT_IRQ, GPIV_TIMER_MODE__TRIGGER_IRQ, GPIV_TIMER_MODE__INCREMENT, GPIV_TIMER_MODE__DOUBLE }

Functions

gint gpiv_trig_openrtfs (gint *init, gint *trig, gint *stop, gint *error)
void gpiv_trig_default_parameters (GpivTrigPar *trig_par_default, const gboolean force)
void gpiv_trig_read_parameters (FILE *fp_par, GpivTrigPar *trig_par, const gboolean verbose)
gchar * gpiv_trig_check_parameters_read (GpivTrigPar *trig_par, const GpivTrigPar *trig_par_default)
void gpiv_trig_parameters_set (GpivTrigPar *trig_par, const gboolean flag)
gchar * gpiv_trig_test_parameter (const GpivTrigPar *trig_par)
void gpiv_trig_print_parameters (FILE *fp_par_out, const GpivTrigPar *trig_par)


Detailed Description

module for triggering lightsource(s) and camera(s) using RTAI

SOURCES: lib/trig.c, lib/trig_par.c

LAST MODIFICATION DATE:

Id
trig.h,v 1.3 2007-06-06 16:59:02 gerber Exp

Definition in file gpiv-trig.h.


Define Documentation

#define GPIV_MILI2NANO   1000 * 1000

Constant to convert from milli to nanseconds

Definition at line 95 of file gpiv-trig.h.

#define GPIV_NANO2MILI   0.001 * 0.001

Constant to convert from nano ro milliseconds

Definition at line 94 of file gpiv-trig.h.

#define GPIV_TRIGPAR_CAP_MAX   1000

Maximum value for cam_acq_period of __GpivTrigTime

Definition at line 86 of file gpiv-trig.h.

#define GPIV_TRIGPAR_CAP_MIN   100

Minimum value for cam_acq_period of __GpivTrigTime

Definition at line 78 of file gpiv-trig.h.

#define GPIV_TRIGPAR_CYCLES_MAX   1

Maximum value for cycles of __GpivTrigTime

Definition at line 91 of file gpiv-trig.h.

#define GPIV_TRIGPAR_CYCLES_MIN   1

Minimum value for cycles of __GpivTrigTime

Definition at line 83 of file gpiv-trig.h.

#define GPIV_TRIGPAR_DEFAULT__CAP   250

Default parameter for cam_acq_period of __GpivTrigTime

Definition at line 61 of file gpiv-trig.h.

#define GPIV_TRIGPAR_DEFAULT__CYCLES   1

Default parameter for cycles of __GpivTrigTime

Definition at line 66 of file gpiv-trig.h.

#define GPIV_TRIGPAR_DEFAULT__DT   10

Default parameter for dt of __GpivTrigTime

Definition at line 64 of file gpiv-trig.h.

#define GPIV_TRIGPAR_DEFAULT__INCR_DT   1

Default parameter for increment of __GpivTrigTime

Definition at line 67 of file gpiv-trig.h.

#define GPIV_TRIGPAR_DEFAULT__LPW   0.02

Default parameter for laser_trig_pw of __GpivTrigTime

Definition at line 62 of file gpiv-trig.h.

#define GPIV_TRIGPAR_DEFAULT__MODE   2

Default parameter for mode of __GpivTrigTime

Definition at line 65 of file gpiv-trig.h.

#define GPIV_TRIGPAR_DEFAULT__T2L   0.19

Default parameter for time2laser of __GpivTrigTime

Definition at line 63 of file gpiv-trig.h.

#define GPIV_TRIGPAR_DT_MAX   100

Maximum value for dt of __GpivTrigTime

Definition at line 89 of file gpiv-trig.h.

#define GPIV_TRIGPAR_DT_MIN   0.10

Minimum value for dt of __GpivTrigTime

Definition at line 81 of file gpiv-trig.h.

#define GPIV_TRIGPAR_INCR_DT_MAX   20

Maximum value for increment of __GpivTrigTime

Definition at line 92 of file gpiv-trig.h.

#define GPIV_TRIGPAR_INCR_DT_MIN   0.01

Minimum value for increment of __GpivTrigTime

Definition at line 84 of file gpiv-trig.h.

#define GPIV_TRIGPAR_KEY   "TRIG"

Key of trigger parameters

Definition at line 69 of file gpiv-trig.h.

#define GPIV_TRIGPAR_KEY__CAP   "Ttime_cap"

Key for cam_acq_period of __GpivTrigTime

Definition at line 70 of file gpiv-trig.h.

#define GPIV_TRIGPAR_KEY__CYCLES   "Ttime_cycles"

Key for cycles of __GpivTrigTime

Definition at line 75 of file gpiv-trig.h.

#define GPIV_TRIGPAR_KEY__DT   "Ttime_dt"

Key for dt of __GpivTrigTime

Definition at line 73 of file gpiv-trig.h.

#define GPIV_TRIGPAR_KEY__INCR_DT   "Ttime_incr_dt"

Key for increment of __GpivTrigTime

Definition at line 76 of file gpiv-trig.h.

#define GPIV_TRIGPAR_KEY__LPW   "Ttime_lpw"

Key for laser_trig_pw of __GpivTrigTime

Definition at line 71 of file gpiv-trig.h.

#define GPIV_TRIGPAR_KEY__MODE   "Ttime_mode"

Key for mode of __GpivTrigTime

Definition at line 74 of file gpiv-trig.h.

#define GPIV_TRIGPAR_KEY__T2L   "Ttime_t2l"

Key for time2laser of __GpivTrigTime

Definition at line 72 of file gpiv-trig.h.

#define GPIV_TRIGPAR_LPW_MAX   0.02

Maximum value for laser_trig_pw of __GpivTrigTime

Definition at line 87 of file gpiv-trig.h.

#define GPIV_TRIGPAR_LPW_MIN   0.02

Minimum value for laser_trig_pw of __GpivTrigTime

Definition at line 79 of file gpiv-trig.h.

#define GPIV_TRIGPAR_MODE_MAX   6

Maximum value for mode of __GpivTrigTime

Definition at line 90 of file gpiv-trig.h.

#define GPIV_TRIGPAR_MODE_MIN   1

Minimum value for mode of __GpivTrigTime

Definition at line 82 of file gpiv-trig.h.

#define GPIV_TRIGPAR_T2L_MAX   0.19

Maximum value for time2laser of __GpivTrigTime

Definition at line 88 of file gpiv-trig.h.

#define GPIV_TRIGPAR_T2L_MIN   0.19

Minimum value for time2laser of __GpivTrigTime

Definition at line 80 of file gpiv-trig.h.


Typedef Documentation

typedef struct __GpivTrigPar GpivTrigPar

Definition at line 148 of file gpiv-trig.h.

typedef struct __GpivTrigTime GpivTrigTime

Definition at line 126 of file gpiv-trig.h.


Enumeration Type Documentation

enum GpivFifo

Fifo values

Enumerator:
GPIV_FIFO_TIMING_PARAMETER 
GPIV_FIFO_START_COMMAND 
GPIV_FIFO_STOP_COMMAND 
GPIV_FIFO_ERROR 
GPIV_FIFO_JITTER 

Definition at line 102 of file gpiv-trig.h.

enum GpivTimingMode

Operating mode

Enumerator:
GPIV_TIMER_MODE__PERIODIC  Indefinite until interrupted
GPIV_TIMER_MODE__DURATION  During specific amount of cycles
GPIV_TIMER_MODE__ONE_SHOT_IRQ  Check. Single shot after irq signal
GPIV_TIMER_MODE__TRIGGER_IRQ  Check. Trigger on irq signal
GPIV_TIMER_MODE__INCREMENT  Incremented __GpivTrigTime::dt
GPIV_TIMER_MODE__DOUBLE  Check. Double exposure

Definition at line 113 of file gpiv-trig.h.


Function Documentation

gchar* gpiv_trig_check_parameters_read ( GpivTrigPar trig_par,
const GpivTrigPar trig_par_default 
)

Check out if all GpivTrigPar parameters have been read.

Parameters:
[in] trig_par_default default trigger parameters
[out] trig_par trigger parameters
Returns:
NULL on success or *err_msg on failure

void gpiv_trig_default_parameters ( GpivTrigPar trig_par_default,
const gboolean  force 
)

Sets default GpivTrigPar parameter values.

Parameters:
[in] force flag to enforce parameters set to defaults
[out] trig_par_default structure of triggering parameters
Returns:
void

gint gpiv_trig_openrtfs ( gint *  init,
gint *  trig,
gint *  stop,
gint *  error 
)

Opens communication channels to camlasco-rtl kernel module.

Parameters:
[in] init initialization or uploading of trigger parameters
[in] trig trigger signel
[in] stop stop signal
[in] error error signal
Returns:
void

void gpiv_trig_parameters_set ( GpivTrigPar trig_par,
const gboolean  flag 
)

Sets flags for __set variables of GpivTrigPar.

Parameters:
[in] flag flag to be set
[out] trig_par triggering parameters
Returns:
void

void gpiv_trig_print_parameters ( FILE *  fp_par_out,
const GpivTrigPar trig_par 
)

Prints GpivTrigPar parameters to fp_par_out.

Parameters:
[in] fp_par_out output file
[in] trig_par triggering parameters
Returns:
void

void gpiv_trig_read_parameters ( FILE *  fp_par,
GpivTrigPar trig_par,
const gboolean  verbose 
)

Read all GpivTrigPar parameters.

Parameters:
[in] fp_par file pointer to parameter file
[out] trig_par triggering parameters
[in] verbose flag to print parametrs to stdout
Returns:
void

gchar* gpiv_trig_test_parameter ( const GpivTrigPar trig_par  ) 

Testing GpivTrigPar parameters on valid values.

Parameters:
[in] trig_par trigger parameters
[out] trig_par trigger parameters
Returns:
NULL on success or *err_msg on failure


Generated on Tue Nov 20 19:46:20 2007 for Libgpiv by doxygen 1.5.1