Mercurial > hg > beaglert
diff projects/basic_button/render.cpp @ 242:db76215feb69
Added libpd.so
author | Giulio Moro <giuliomoro@yahoo.it> |
---|---|
date | Mon, 18 Apr 2016 03:05:45 +0100 |
parents | ec9425f728bc |
children | da5ce9876fcc |
line wrap: on
line diff
--- a/projects/basic_button/render.cpp Mon Apr 18 03:04:34 2016 +0100 +++ b/projects/basic_button/render.cpp Mon Apr 18 03:05:45 2016 +0100 @@ -42,10 +42,13 @@ void render(BeagleRTContext *context, void *userData) { + float sum=0; for(unsigned int n=0; n<context->digitalFrames; n++){ int status=digitalReadFrame(context, 0, P8_08); //read the value of the button + sum += status; digitalWriteFrame(context, n, P8_07, status); //write the status to the LED } + rt_printf("status: %f\n", sum); } // cleanup() is called once at the end, after the audio has stopped.