2023-04-11 11:13:23 -04:00
|
|
|
#ifndef MACRO_H
|
|
|
|
#define MACRO_H
|
|
|
|
|
2023-05-03 17:53:35 -04:00
|
|
|
#define MaxNPorts 1
|
|
|
|
#define MaxNBoards 2
|
2023-04-24 17:37:03 -04:00
|
|
|
|
|
|
|
#define MaxNDigitizer MaxNPorts * MaxNBoards
|
|
|
|
|
2023-04-11 11:13:23 -04:00
|
|
|
#define MaxNChannels 16
|
|
|
|
#define MaxRecordLength 0x3fff * 8
|
|
|
|
#define MaxSaveFileSize 1024 * 1024 * 1024 * 2
|
|
|
|
|
2023-04-18 13:12:05 -04:00
|
|
|
#define MaxDisplayTraceDataLength 2000 //data point,
|
|
|
|
#define MaxNumberOfTrace 4 // in an event
|
|
|
|
|
2023-04-11 11:13:23 -04:00
|
|
|
#define SETTINGSIZE 2048
|
|
|
|
|
|
|
|
#include <sys/time.h> /** struct timeval, select() */
|
|
|
|
|
|
|
|
inline unsigned int get_time(){
|
|
|
|
unsigned int time_us;
|
|
|
|
struct timeval t1;
|
|
|
|
struct timezone tz;
|
|
|
|
gettimeofday(&t1, &tz);
|
|
|
|
time_us = (t1.tv_sec) * 1000 * 1000 + t1.tv_usec;
|
|
|
|
return time_us;
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|