-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathPS4_Input.h
More file actions
48 lines (42 loc) · 781 Bytes
/
PS4_Input.h
File metadata and controls
48 lines (42 loc) · 781 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
37
38
39
40
41
42
43
44
45
46
47
48
#ifndef PS4_INPUT
#define PS4_INPUT
#include "Arduino.h"
#define ANALOGUE_DEADZONE 25 // value used as the zone of the analogue inputs that doesn't get processed as input.
class PS4_Input {
private:
String message;
public:
//Constructor
PS4_Input();
//Buttons
//Analog
int rightV;
int rightH;
int leftV;
int leftH;
//Digital
bool ps;
bool share;
bool options;
bool triangle;
bool square;
bool circle;
bool x;
bool up;
bool down;
bool left;
bool right;
bool l1;
bool l2;
bool l3;
bool r1;
bool r2;
bool r3;
//Functions
void Start_Serial();
int Get_Input();
void Reset_Bools();
void Reset_Analogues();
String Print_Out();
};
#endif