-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathfirmware.ino
64 lines (48 loc) · 2.22 KB
/
firmware.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
/*
.__ .___ _____.__ .__ ___.
____ ____ | |__ _____ ____ ____ ____ __| _/ _/ ____\ | _____ _____| |__\_ |__ _____ ____ ____
_/ __ \ / \| | \\__ \ / \_/ ___\/ __ \ / __ | ______ \ __\| | \__ \ / ___/ | \| __ \\__ \ / \ / ___\
\ ___/| | \ Y \/ __ \| | \ \__\ ___// /_/ | /_____/ | | | |__/ __ \_\___ \| Y \ \_\ \/ __ \| | \/ /_/ >
\___ >___| /___| (____ /___| /\___ >___ >____ | |__| |____(____ /____ >___| /___ (____ /___| /\___ /
\/ \/ \/ \/ \/ \/ \/ \/ \/ \/ \/ \/ \/ \//_____/
Written by:
Jarvis
Malcolm
&
Paxton
*/
// Arduino code to switch relay
#define relay_pin 5
#define check 7
int command = 0;
void setup() {
pinMode(relay_pin, OUTPUT);
Serial.begin(9600);
}
void loop() {
while (Serial.available() > 0){
command = Serial.read();
}
if (check == command){
digitalWrite(7, HIGH);
delay(3000);
digitalWrite(7, LOW);
}
command = 0;
}
/*
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢠⣴⣶⣤⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣠⣸⣿⣿⡟⣀⣀⣀⣀⣀⣀⣀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣿⣿⣿⣿⣿⣿⣿⡿⣿⡿⠛⠛⠋⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣸⣿⣿⣿⣿⣿⣿⣿⣷⣿⠃⠀⠀⠀⠀⠀⠀⠀
⢠⣶⣶⣶⣶⣶⣶⡄⠀⢸⣿⣿⣿⣿⣿⣿⣧⠙⠛⠉⢠⣶⣶⣶⣶⣶⣶⡄
⢸⣿⣿⠛⠛⠛⠛⠃⠀⠐⣿⣿⣿⣿⣿⣿⡟⠀⠀⠀⢸⣿⡿⠛⠛⠛⠛⠃
⢸⣿⣿⠀⠀⠀⠀⠀⠀⢠⣿⣿⣿⣿⣿⣧⡀⠀⠀⠀⢸⣿⣿⣶⣶⣶⣶⡆
⢸⣿⣿⠀⠀⠀⠀⠀⠀⢸⣿⣿⡿⢿⣿⣿⣿⡀⠀⠀⠈⠛⠛⠛⠛⣿⣿⡇
⢸⣿⣿⣿⣿⣿⣿⡇⠀⢸⣿⣿⠁⠀⠘⢿⣿⣷⠀⠀⢸⣿⣿⣿⣿⣿⣿⡇
⠈⠉⠉⠉⠉⠉⠉⠁⢠⣿⡟⠁⠀⠀⠀⢠⣿⣿⠀⠀⠈⠉⠉⠉⠉⠉⠉⠁
⠀⠀⠀⠀⠀⠀⠀⢠⣿⣿⠃⠀⠀⠀⠀⠀⣿⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⢸⣿⠉⠀⠀⠀⠀⠀⠀⣹⣿⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠸⠿⠀⠀⠀⠀⠀⠀⠀⠛⠛⠛⠃⠀⠀
Copyright (C)2022
*/