Facebook
From Capacious Water Vole, 6 Months ago, written in Plain Text.
Embed
Download Paste or View Raw
Hits: 76
  1. #include "nuty.h"
  2. int tony[46] = {c2, d2, g1, c2, g1, e2, e2, f2, d2, e2, c2, d2, h1, c2, g1, e2, e2,f2, d2,e2,c2,e2,c2,e2,f2,d2,h1,g1,c2,e2,c2,e2,f2,d2,h1,g1,c2,c2,d2,d2,e2,c2,c2,d2,d2,c2};
  3. int czasy[46] = {1000, 500, 500, 1000, 1000, 500, 500, 500, 500, 2000, 1000, 500, 500, 1000, 1000, 500, 500, 500, 500, 2000, 500, 500, 500, 500, 750, 250, 500, 500, 500, 500, 500, 500, 750, 250, 500, 500, 500, 500, 500, 500, 2000, 500, 500, 500, 500, 2000};
  4. void setup(){
  5.   pinMode(3, OUTPUT);
  6.   for (int i = 0; i < 46; i++) {
  7.     tone(3, tony[i]);
  8.     delay(czasy[i]);
  9.   }
  10.   noTone(3);
  11. }
  12. void loop() {
  13.  
  14. }
  15.