add WIP

parent 8e724281
......@@ -13,7 +13,7 @@ extern "C" {
#include <stdint.h>
/*
/**
* general questions/open ends --- look fast for 'tbd' or FIXME in the
* code to quickly identify loose ends
*
......@@ -32,11 +32,13 @@ extern "C" {
* type, this can be size-optimized - tbd
*/
/* two types of channel inputs: distance meas. or Bragg */
/** types of channel inputs: distance meas. or Bragg */
enum fsi_channel_type {
FSI_CH_NONE = 0,
FSI_CH_DISTANCE = 1, /**< configure as distance meas. channel */
FSI_CH_BRAGG, /**< configure as Bragg channel */
FSI_CH_GAS_CELL, /**< gas cell channel */
FSI_CH_INTERF, /**< reference interferometer channel */
};
/* types of functional forms to fit the peaks found */
......@@ -74,6 +76,8 @@ enum fsi_expert_mode {
/* library error codes */
#define __FSI_ERR_START 1024
struct FSI;
/* peak finding/fitting configuration for a channel
*
* A channel will be configured so that
......@@ -133,16 +137,26 @@ struct fsi_full_measurement {
/* methods */
int fsi_lib_init(void);
/** initialize library */
struct FSI* fsi_lib_init(void);
/** configure a channel type, gain and expected peak params */
int fsi_channel_configure(struct fsi_channel_config *cfg);
/** bulk configure a channel array type, gain and expected peak params */
int fsi_channel_array_configure(struct fsi_channel_config cfg[], int nchannels);
/** receive the whole set of distance/bragg measurements from all channels */
int fsi_receive_measurements(struct fsi_channel_measurement meas[], int *nchannels);
/** receive the whole set of distance/bragg measurements from all channels with a timeout */
int fsi_receive_measurements_timemout(struct fsi_channel_measurement meas[], int *nchannels,
unsigned int timeout);
int fsi_get_full_measurement(int channel_id, enum fsi_expert_mode mode, struct fsi_full_measurement *meas);
/** receive raw measurements of channel_id */
int fsi_get_full_samples(int channel_id, enum fsi_expert_mode mode, struct fsi_full_measurement *meas);
/** close library */
int fsi_lib_exit(void);
#ifdef __cplusplus
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment