2014-git-work/arduino/toneMelodyDisk1/toneMelodyDisk1.ino
2013-09-16 17:37:33 +09:00

17 lines
291 B
C++

#include "pitches.h"
void disk1(){
int melodyDisk1[] = {NOTE_B5,NOTE_D6,NOTE_G6};
for (int thisNote = 0; thisNote < 3; thisNote++) {
tone(3, melodyDisk1[thisNote]);
delay(100);
noTone(3);
}
}
void setup() {
disk1();
}
void loop() {
// no need to repeat the melody.
}