00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef MYCONSTANTS_H
00026 #define MYCONSTANTS_H
00027
00028 #include <errno.h>
00029 #include <sys/types.h>
00030
00031 #define DI194
00032
00034 extern int my_errno;
00036 const u_int8_t asciihex[] = "0123456789ABCDEF";
00038 const u_int8_t inthex[128] =
00039 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
00040 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
00041 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
00042 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
00043 0, 0, 0, 0, 0, 0, 0, 0, 0, 1,
00044 2, 3, 4, 5, 6, 7, 8, 9, 0, 0,
00045 0, 0, 0, 0, 0,10,11,12,13,14,
00046 15,0, 0, 0, 0, 0, 0, 0, 0, 0,
00047 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
00048 0, 0, 0, 0, 0, 0, 0,10,11,12,
00049 13,14,15,0, 0, 0, 0, 0, 0, 0,
00050 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
00051 0, 0, 0, 0, 0, 0, 0, 0};
00052
00054 const int BIG_STR = 1024;
00056 const int SMALL_STR = 32;
00058 const int DEV_PATH = 64;
00063 const int DI_SERIAL_BUFFER_SIZE = 4096;
00064
00069 #ifdef DI194
00070 const int DI194_SN_LENGTH = 10;
00071 #endif
00072
00073
00074 #ifdef DI194
00075 const int DI194_KEY_SIZE = 10;
00076 #endif
00077
00082 #ifdef DI194
00083 const int DI194_CHANNELS = 5;
00084 #endif
00085
00091 #ifdef DI194
00092 const int DI194_CHAN_SIZE = 2;
00093 #endif
00094
00100 #ifdef DI194
00101 const double DI194_MAXBURSTRATE = 240.00*4;
00102 const double DI194_MINBURSTRATE = DI194_MAXBURSTRATE / 32767;
00103 #endif
00104
00110 const u_int8_t IOS_SMALLEST = 0;
00111 const u_int8_t IOS_AVERAGE = 0;
00112 const u_int8_t IOS_MAX = 1;
00113 const u_int8_t IOS_MIN = 2;
00114 const u_int8_t IOS_RMS = 3;
00115 const u_int8_t IOS_FREQ = 4;
00116 const u_int8_t IOS_LAST_POINT = 5;
00117 const u_int8_t IOS_GREATEST = 5;
00124 const int EBOUNDS = 200;
00125 const int EBADRSVP = 201;
00126
00128 #endif
00129