From d15acaf23dcc779bd65b393ace28178bd8ac152d Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 31 Jan 2018 11:03:28 +0000 Subject: Need to debug --- lab4/RTDSP/intio.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lab4/RTDSP/intio.c') diff --git a/lab4/RTDSP/intio.c b/lab4/RTDSP/intio.c index 9992d4a..d7dceeb 100644 --- a/lab4/RTDSP/intio.c +++ b/lab4/RTDSP/intio.c @@ -44,7 +44,7 @@ // PI defined here for use in your code #define PI 3.141592653589793 #define N 249 -double buffer[N]; +double buffer[N]= {0}; unsigned int ptr = N-1; /******************************* Global declarations ********************************/ @@ -133,9 +133,9 @@ void ISR_AIC() sample_out = non_circ_fir(); mono_write_16Bit(sample_out); - ptr--; if (ptr == 0) - ptr = N-1; + ptr = N; + ptr--; } // Perform linear convolution -- cgit