54 #define SEND_MODE_OFF 0 55 #define SEND_MODE_ONCE 1 56 #define SEND_MODE_ON 2 66 DLT_STRING(
"dlt-system-logfile, sending file."));
73 pFile = fopen((*fileopt).Filename[n],
"r");
77 while (!feof(pFile)) {
78 bytes = fread(buffer,1,
sizeof(buffer)-1,pFile);
97 DLT_STRING(
"dlt-system-logfile, failed to open file."),
105 DLT_STRING(
"dlt-system-logfile, registering file contexts."));
107 for(i = 0;i < (*fileopts).Count;i++)
110 (*fileopts).Filename[i]);
117 DLT_STRING(
"dlt-system-logfile, in thread."));
135 if(logfile_delays[i] <= 0)
137 send_file(&(conf->
LogFile), i);
155 static pthread_attr_t t_attr;
int Mode[DLT_SYSTEM_LOG_FILE_MAX]
void start_logfile(DltSystemConfiguration *conf)
void logfile_thread(void *v_conf)
void register_contexts(LogFileOptions const *fileopts)
unsigned char buffer[BUFFER_SIZE]
Buffer for dlt file transfer. The size is defined by BUFFER_SIZE.
#define DLT_REGISTER_CONTEXT(CONTEXT, CONTEXTID, DESCRIPTION)
#define DLT_LOG(CONTEXT, LOGLEVEL, ARGS...)
int TimeDelay[DLT_SYSTEM_LOG_FILE_MAX]
DLT_IMPORT_CONTEXT(dltsystem)
pthread_t threads[MAX_THREADS]
#define DLT_SYSTEM_LOG_FILE_MAX