-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathCommunication.h
40 lines (33 loc) · 1.11 KB
/
Communication.h
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
#ifndef COMMUNICATION_H
#define COMMUNICATION_H
#include <Arduino.h>
#include "Plunger.h"
#include "HID-Project.h"
#include "Buttons.h"
#include "Accelerometer.h"
#include "Config.h"
#include "Outputs.h"
class Communication {
public:
Communication();
void communicate();
private:
bool DEBUG = false;
char* connectedString = "DEBUG,CSD Board Connected\r\n";
unsigned char firstNumber = 0; //0 normally
unsigned char bankOffset = 200; //200 normally
unsigned char adminNumber = 250; //250 normally
unsigned char connectionNumber = 251;//251 normally
unsigned char outputSingleNumber = 252;//252 normally
unsigned char outputButtonNumber = 253;//252 normally
unsigned char maxNumber = 255; //255 normally
unsigned char delayIncrementor = 0;
unsigned char incomingData[10];
int dataLocation = 0;
void updateOutputs();
int admin = 0;
void sendAdmin();
bool shouldDelay();
unsigned char previousDOFValues[63] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
};
#endif