-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathERL_3.ino
84 lines (61 loc) · 1.01 KB
/
ERL_3.ino
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
#define ldr_activator A5
#define ldr_1 A0
#define ldr_2 A1
#define ldr_3 A2
#define ldr_4 A3
#define ldr_5 A4
#define button_1 13
#define button_2 A0
#define button_3 A1
#define button_4 A2
#define button_5 A3
#define button_6 10
#define button_7 A4
#define button_8 A5
// RELAYS
#define relay_1 4
#define relay_2 2
#define relay_3 12
#define relay_4 3
#define relay_5 9
#define relay_6 8
#define relay_7 7
#define relay_8 6
#define buzzer 11
#include <SoftwareSerial.h>
SoftwareSerial bluetooth(10, 5); // RX, TX
int light = 0;
int dataset=1;
/*
0r = red
o = orange
p = purple
b = black
w = white
g = green
y = yellow
c = cfl
n = null
d = delay
e = end
*/
char ka_1[1000] = "d1000 r80 p60";
char ka_2[1000] = "";
char ka_3[1000] = "";
char ka_4[1000] = "";
char ka_5[1000] = "";
char ka_6[1000] = "";
void setup()
{
Serial.begin(9600);
bluetooth.begin(9600);
initialize();
}
void loop()
{
// dance();
real_time();
// Serial.print(digitalRead(button_2));
//kraddy();
//music_writer();
}