RocketLogger  1.0
file_handling.h
Go to the documentation of this file.
1 
5 #include <stdio.h>
6 #include <stdlib.h>
7 #include <string.h>
8 #include <time.h>
9 
10 #include "types.h"
11 #include "rl_file.h"
12 #include "log.h"
13 #include "util.h"
14 #include "sem.h"
15 #include "web.h"
16 
17 
18 // DEFINES
19 
20 
22 #define VALID_MASK 0x1
23 #define BINARY_MASK 0xE
25 
27 #define H_L_SCALE 100
28 
30 #define CSV_LINE_LENGTH 200
31 #define CSV_VALUE_LENGTH 50
33 
34 // FUNCTIONS
35 void setup_lead_in(struct rl_file_lead_in* lead_in, struct rl_conf* conf);
36 void setup_header(struct rl_file_header* file_header, struct rl_conf* conf);
37 void store_header_bin(FILE* data, struct rl_file_header* file_header);
38 void store_header_csv(FILE* data, struct rl_file_header* file_header);
39 void update_header_bin(FILE* data, struct rl_file_header* file_header);
40 void update_header_csv(FILE* data, struct rl_file_header* file_header);
41 void handle_data_buffer(FILE* data, void* buffer_addr, uint32_t sample_size, uint32_t samples_buffer, struct rl_conf* conf, int sem_id, struct web_shm* web_data_ptr);
void update_header_csv(FILE *data, struct rl_file_header *file_header)
int sem_id
ID of semaphore set.
Definition: rl_server.c:24
Definition: types.h:202
void handle_data_buffer(FILE *data, void *buffer_addr, uint32_t sample_size, uint32_t samples_buffer, struct rl_conf *conf, int sem_id, struct web_shm *web_data_ptr)
void update_header_bin(FILE *data, struct rl_file_header *file_header)
void setup_header(struct rl_file_header *file_header, struct rl_conf *conf)
Definition: web.h:64
void setup_lead_in(struct rl_file_lead_in *lead_in, struct rl_conf *conf)
Definition: file_handling.c:67
void store_header_csv(FILE *data, struct rl_file_header *file_header)
void store_header_bin(FILE *data, struct rl_file_header *file_header)