-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathturntable.h
More file actions
36 lines (33 loc) · 714 Bytes
/
Copy pathturntable.h
File metadata and controls
36 lines (33 loc) · 714 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#ifndef TURNTABLE_H_INC
#define TURNTABLE_H_INC
#include <SpeedController.h>
#include <DigitalInput.h>
class turntable {
public:
enum cur_side {
UNSURE,
LEFT,
RIGHT,
CENTER
};
turntable(SpeedController&, DigitalInput&, DigitalInput&, DigitalInput&);
~turntable();
void new_offset(int, int);
void center();
void enable();
void disable();
void manual_control(float);
float get_power() const;
private:
SpeedController * jag;
DigitalInput * left;
DigitalInput * mid;
DigitalInput * right;
float power;
bool centering;
bool enabled;
cur_side pos;
void update();
static void update_help(void*);
};
#endif