SELKIELogger
1.0.0
|
Classes | |
struct | global_opts |
General program options. More... | |
struct | device_callbacks |
Device specific function information. More... | |
struct | log_thread_args_t |
Logging thread information. More... | |
struct | channel_stats |
Channel statistics. More... | |
Macros | |
#define | DEFAULT_MON_PREFIX "@DEFAULT_MON_PREFIX@" |
If no output file prefix is specified, this will be used as a default. | |
#define | DEFAULT_STATE_NAME "@DEFAULT_STATE_NAME@" |
If no state file name is specified, this will be used as a default. | |
#define | DEFAULT_MARK_FREQUENCY @DEFAULT_MARK_FREQUENCY@ |
Default sample/marker frequency. | |
#define | DEFAULT_MARK_FREQ_STRING "@DEFAULT_MARK_FREQUENCY@" |
Default sample/marker frequency, as a string. | |
#define | SERIAL_SLEEP 1E3 |
Default serial wait time. More... | |
Typedefs | |
typedef void *(* | device_fn) (void *) |
Device specific callback functions. | |
typedef bool(* | dc_parser) (log_thread_args_t *, config_section *) |
Data source specific configuration parsers;. | |
Functions | |
bool | timespec_subtract (struct timespec *result, struct timespec *x, struct timespec *y) |
Difference between timespecs (used for rate keeping) More... | |
bool | log_softwareVersion (msgqueue *q) |
Push current software version into message queue. More... | |
void | destroy_global_opts (struct global_opts *go) |
Cleanup function for global_opts struct. More... | |
bool | write_state_file (char *sFName, channel_stats stats[128][128], uint32_t lTS, char *vFName) |
Write out the state file. More... | |
#define SERIAL_SLEEP 1E3 |
Default serial wait time.
If no data, the various reader threads usleep() for a period to give sensors/devices time to send more data.
The main logging thread also sleeps when no messages are available, which is also based on this value.
Definition at line 51 of file Logger.h.in.
void destroy_global_opts | ( | struct global_opts * | go | ) |
Cleanup function for global_opts struct.
The global_opts structure should be left in a safe state after calling this function, and calling this function repeatedly should not cause an error.
[in] | go | Pointer to structure |
bool log_softwareVersion | ( | msgqueue * | q | ) |
bool timespec_subtract | ( | struct timespec * | result, |
struct timespec * | x, | ||
struct timespec * | y | ||
) |
bool write_state_file | ( | char * | sFName, |
channel_stats | stats[128][128], | ||
uint32_t | lTS, | ||
char * | vFName | ||
) |
Write out the state file.
Truncates and recreates the state file, including last received message statistics, timestamps and path to the channel mapping file currently in use. Any change to this output format also needs to be reflected in SLFiles.py
[in] | sFName | Name and path to state file |
[in] | stats | Channel statistics array |
[in] | lTS | Last received timestamp |
[in] | vFName | Name and path to current channel mapping file |