Vehicle Control Unit 0.01
This is the c library for controlling the car.
Loading...
Searching...
No Matches
Sensor.c
Go to the documentation of this file.
1#include "../../Inc/Sensors/Sensor.h"
2#include "../../Inc/Utils/Updateable.h"
3
4void initSensor(Sensor* sensor, const char* name, int hz, SensorType type) {
5 initUpdateable(&sensor->updateable, name, hz);
6 sensor->type = type;
7}
void initSensor(Sensor *sensor, const char *name, int hz, SensorType type)
Initializes a sensor with the given parameters.
Definition: Sensor.c:4
SensorType
Definition: Sensor.h:9
type
Definition: Updateable.h:17
void initUpdateable(Updateable *updateable, const char *name, int hz)
Definition: Updateable.c:6
Definition: Sensor.h:14
SensorType type
Definition: Sensor.h:16
Updateable updateable
Definition: Sensor.h:15