1#include "../../Inc/Utils/Updateable.h"
2#include "../../Inc/Utils/Common.h"
17 printf(
"Warning: Calling default Sensor Update Function.\n");
35 FILE* file = fopen(filename,
"w");
37 perror(
"Failed to open file");
41 printf(
"Writing data to file %s\n", filename);
int defaultEnable(struct Updateable *self)
Default enable function for Updateable objects.
int defaultDisable(struct Updateable *self)
Default disable function for Updateable objects.
int writeDataToFileImplementation(const char *filename, void *self)
Write data to a file.
void defaultUpdate(void *self)
Default update function for Updateable objects.
int defaultStatus(struct Updateable *self)
Default status function for Updateable objects.
void initUpdateable(Updateable *updateable, const char *name, int hz)
void(* update)(void *self)
int(* disable)(struct Updateable *self)
int(* status)(struct Updateable *self)
char name[MAX_NAME_LENGTH]
int(* enable)(struct Updateable *self)