-
Notifications
You must be signed in to change notification settings - Fork 0
/
BUTTONS.ino
42 lines (42 loc) · 1.52 KB
/
BUTTONS.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
void buttons() {
if (digitalRead(button1) == LOW) {
Serial.println("Button 1 pressed, playing 1.wav");
playFile("1.wav"); // filenames are always uppercase 8.3 format
playingWAVSeq();
}
if (digitalRead(button2) == LOW) {
Serial.println("Button 1 pressed, playing 2.wav");
playFile("2.wav"); // filenames are always uppercase 8.3 format
playingWAVSeq();
}
if (digitalRead(button3) == LOW) {
Serial.println("Button 1 pressed, playing 3.wav");
playFile("3.wav"); // filenames are always uppercase 8.3 format
playingWAVSeq();
}
if (digitalRead(button4) == LOW) {
Serial.println("Button 1 pressed, playing 4.wav");
playFile("4.wav"); // filenames are always uppercase 8.3 format
playingWAVSeq();
}
if (digitalRead(button5) == LOW) {
Serial.println("Button 1 pressed, playing 5.wav");
playFile("5.wav"); // filenames are always uppercase 8.3 format
playingWAVSeq();
}
if (digitalRead(button6) == LOW) {
Serial.println("Button 1 pressed, playing 6.wav");
playFile("6.wav"); // filenames are always uppercase 8.3 format
playingWAVSeq();
}
if (digitalRead(button7) == LOW) {
Serial.println("Button 1 pressed, playing 7.wav");
playFile("7.wav"); // filenames are always uppercase 8.3 format
playingWAVSeq();
}
if (digitalRead(button8) == LOW) {
Serial.println("Button 1 pressed, playing 8.wav");
playFile("8.wav"); // filenames are always uppercase 8.3 format
playingWAVSeq();
}
} //END void buttons()