void setup() {
pinMode(2, INPUT_PULLUP);
pinMode(3, INPUT_PULLUP);
pinMode(4, INPUT_PULLUP);
}
void loop() {
if (!(digitalRead(2) == HIGH)) {
tone(11, 262, 100);
}
if (!(digitalRead(3) == HIGH)) {
tone(11, 294, 100);
}
if (!(digitalRead(4) == HIGH)) {
tone(11, 330, 100);
}
}
Copyright ⓒ TECH79 All right reserved