X-Git-Url: http://git.harvie.cz/?a=blobdiff_plain;f=c%2Fghetto-sound-system%2Fbeatdetect.c;h=bb4a191da6723fbea8f7b65ce92add9729a7f5b1;hb=75e2456441dd2360b17b5e08022e91f8bb9331df;hp=b520ae881b9b5055c4df5f95073263d5b36d57d5;hpb=9552f73fbd0559a314fc6f8f442e3e90a7d5d4d4;p=mirrors%2FPrograms.git diff --git a/c/ghetto-sound-system/beatdetect.c b/c/ghetto-sound-system/beatdetect.c index b520ae8..bb4a191 100644 --- a/c/ghetto-sound-system/beatdetect.c +++ b/c/ghetto-sound-system/beatdetect.c @@ -1,4 +1,6 @@ //CFLAGS=-lasound make beatdetect; echo -----; ./beatdetect hw:default +//http://www.equalarea.com/paul/alsa-audio.html + #include #include #include @@ -78,7 +80,10 @@ } else { int j; for(j=0;j<128;j++) if((int)buf[j] > 1000) { - printf("BOOM! %d\n", (int)buf[j]); + //printf("BOOM! %d\n", (int)buf[j]); + //puts(""); + putchar('!'); + fflush(stdout); break; } }