Vehicle Control Unit 0.01
This is the c library for controlling the car.
Loading...
Searching...
No Matches
App.h
Go to the documentation of this file.
1#ifndef RENSSELAERMOTORSPORT_APP_H
2#define RENSSELAERMOTORSPORT_APP_H
3
4#include "../AnalogSensor.h"
5#include "../../Utils/Telemetry.h"
6
7typedef struct {
9 float position;
12} App;
13
22void initApp(App* app, int hz, int channel, char* name);
23
30float getAppPosition(App* app);
31
37void updateApp(App* app);
38
45float transferFunctionApp(float rawVal);
46
54void setAppPos(App* app, float pos);
55
56#endif // RENSSELAERMOTORSPORT_APP_H
float getAppPosition(App *app)
Gets the current position of the APP.
Definition: App.c:17
void updateApp(App *app)
Updates the APP data.
Definition: App.c:21
void setAppPos(App *app, float pos)
Sets pedal position in app sensor.
float transferFunctionApp(float rawVal)
Converts raw APP data to a meaningful position value.
Definition: App.c:41
void initApp(App *app, int hz, int channel, char *name)
Initializes the APP with the given frequency and channel.
Definition: App.c:6
Definition: App.h:7
TelemetrySignal * telem_raw
Definition: App.h:10
AnalogSensor base
Definition: App.h:8
float position
Definition: App.h:9
TelemetrySignal * telem_position
Definition: App.h:11