|
This was supposed to be used in the final robot, but it took up
too much memory on the handyboard.
void main(){
stairway_to_heaven();
}
void stairway_to_heaven(){
float top_a= 440.00;
float middle_c= 523.25;
float top_e=659.26;
float topper_a= 880.00;
float topper_b= 987.77;
float topper_c= 1046.50;
float top_f_sharp= 739.99;
float top_g= 783.99;
float top_d= 587.33;
float top_b=493.88;
float aye= 220.00;
float ey= 329.63;
float ef= 349.23;
float bee= 246.94;
float cee= 261.63;
float gee= 392.00;
float dee= 293.66;
float sixteenth= .2;
float eighth= .4;
float dotted_eighth= .6;
float quarter= .8;
float dotted_quarter= 1.2;
float half= 1.6;
float dotted_half= 2.4;
float whole= 3.2;
while (!stop_button()){
tone(top_a, eighth);
tone(middle_c, eighth);
tone(top_e, eighth);
tone(topper_a, eighth);
tone(topper_b, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(topper_b, eighth);
tone(topper_c, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(topper_c, eighth);
tone(top_f_sharp, eighth);
tone(top_d, eighth);
tone(top_a, eighth);
tone(top_f_sharp, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(middle_c, quarter);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(top_b, eighth);
tone(middle_c, sixteenth);
sleep(sixteenth);
tone(middle_c, dotted_quarter);
tone(aye, eighth);
tone(ef, eighth);
tone(ey, eighth);
tone(aye, eighth);
tone(middle_c, eighth);
tone(top_e, eighth);
tone(topper_a, eighth);
tone(topper_b, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(topper_b, eighth);
tone(topper_c, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(topper_c, eighth);
tone(top_f_sharp, eighth);
tone(top_d, eighth);
tone(top_a, eighth);
tone(top_f_sharp, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(middle_c, quarter);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(top_b, eighth);
tone(middle_c, sixteenth);
sleep(sixteenth);
tone(middle_c, half);
tone(aye, eighth);
tone(bee, eighth);
tone(cee, eighth);
tone(ey, eighth);
tone(gee, eighth);
tone(top_e, eighth);
tone(top_f_sharp, eighth);
tone(top_d, eighth);
tone(top_a, eighth);
tone(top_f_sharp, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(top_e, eighth);
tone(top_b, sixteenth);
tone(middle_c, sixteenth);
tone(top_a, eighth);
tone(aye, eighth);
tone(bee, eighth);
tone(middle_c, eighth);
tone(gee, eighth);
tone(ey, eighth);
tone(middle_c, eighth);
tone(top_g, eighth);
tone(top_b, eighth);
tone(gee, eighth);
tone(top_g, eighth);
tone(top_g, sixteenth);
tone(top_f_sharp, sixteenth);
tone(top_f_sharp, eighth);
tone(top_f_sharp, half);
tone(aye, eighth);
tone(bee, eighth);
tone(cee, eighth);
tone(ey, eighth);
tone(gee, eighth);
tone(top_e, eighth);
tone(top_f_sharp, eighth);
tone(top_d, eighth);
tone(top_a, eighth);
tone(top_f_sharp, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(top_e, eighth);
tone(top_b, sixteenth);
tone(middle_c, sixteenth);
tone(top_a, eighth);
tone(aye, eighth);
tone(bee, eighth);
tone(cee, eighth);
tone(ey, eighth);
tone(gee, eighth);
tone(middle_c, eighth);
tone(dee, eighth);
tone(top_a, eighth);
tone(top_d, eighth);
tone(top_f_sharp, eighth);
tone(top_e, eighth);
tone(top_e, eighth);
tone(top_e, half);
sleep(quarter);
tone(top_a, eighth);
tone(middle_c, eighth);
tone(top_e, eighth);
tone(topper_a, eighth);
tone(topper_b, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(topper_b, eighth);
tone(topper_c, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(topper_c, eighth);
tone(top_f_sharp, eighth);
tone(top_d, eighth);
tone(top_a, eighth);
tone(top_f_sharp, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(middle_c, quarter);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(top_b, eighth);
tone(middle_c, sixteenth);
sleep(sixteenth);
tone(middle_c, half);
sleep(quarter);
tone(top_a, eighth);
tone(middle_c, eighth);
tone(top_e, eighth);
tone(topper_a, eighth);
tone(topper_b, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(topper_b, eighth);
tone(topper_c, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(topper_c, eighth);
tone(top_f_sharp, eighth);
tone(top_d, eighth);
tone(top_a, eighth);
tone(top_f_sharp, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(middle_c, quarter);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(top_b, eighth);
tone(middle_c, sixteenth);
sleep(sixteenth);
tone(middle_c, half);
tone(aye, eighth);
tone(bee, eighth);
tone(cee, eighth);
tone(ey, eighth);
tone(gee, eighth);
tone(top_e, eighth);
tone(top_f_sharp, eighth);
tone(top_d, eighth);
tone(top_a, eighth);
tone(top_f_sharp, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(top_e, eighth);
tone(top_b, sixteenth);
tone(middle_c, sixteenth);
tone(top_a, eighth);
tone(aye, eighth);
tone(bee, eighth);
tone(middle_c, eighth);
tone(gee, eighth);
tone(ey, eighth);
tone(middle_c, eighth);
tone(top_g, eighth);
tone(top_b, eighth);
tone(gee, eighth);
tone(top_g, eighth);
tone(top_g, sixteenth);
tone(top_f_sharp, sixteenth);
tone(top_f_sharp, eighth);
tone(top_f_sharp, half);
tone(aye, eighth);
tone(bee, eighth);
tone(cee, eighth);
tone(ey, eighth);
tone(gee, eighth);
tone(top_e, eighth);
tone(top_f_sharp, eighth);
tone(top_d, eighth);
tone(top_a, eighth);
tone(top_f_sharp, eighth);
tone(top_e, eighth);
tone(middle_c, eighth);
tone(top_a, eighth);
tone(top_e, eighth);
tone(top_b, sixteenth);
tone(middle_c, sixteenth);
tone(top_a, eighth);
tone(aye, eighth);
tone(bee, eighth);
tone(cee, eighth);
tone(ey, eighth);
tone(gee, eighth);
tone(middle_c, eighth);
tone(dee, eighth);
tone(top_a, eighth);
tone(top_d, eighth);
tone(top_f_sharp, eighth);
tone(top_e, eighth);
tone(top_e, eighth);
tone(top_e, half);
sleep(quarter);
}
}
|