On compiling the program given in 'arduino_audio_loopback' i am getting an error as " TCCR2A not declared" . plz hlp...
// set adc prescaler to 64 for 19kHz sampling frequency cbi(ADCSRA, ADPS2); sbi(ADCSRA, ADPS1); sbi(ADCSRA, ADPS0);
here is the correct prescaler for the adc again// set adc prescaler to 32 for 38 kHz sampling frequencysbi(ADCSRA, ADPS2);cbi(ADCSRA, ADPS1);sbi(ADCSRA, ADPS0);
the sampling rate is determined by the timer2 interrupt and set to 31,25KHz. Since we measure two inputs, the audio signal and the pot position alternately, the effective sampling rate is 15,625 KHz. With a prescaler of 64 and a 16000KHz Clock and 13 Cycles for one sample we get a sample rate of 16000 / 64 / 13 = 19,2 KHz So the ADC is just ready before the sample is processed.
Please enter a valid email to subscribe
We need to confirm your email address.
To complete the subscription, please click the link in the
email we just sent you.
Thank you for subscribing!
via Egeo 16