Reply by August 18, 20122012-08-18
Yes thank you for replying to my other post.

There aren't that many files in the project. I think initSPORT.c is the most important one since it contains the code that sets up the precision clock generator (PCG) and the sample rate converters (SRC).

The .c files have a lot of comments in them.

blockProcess.c: Audio processing goes here
init1835viaSPI: Initialize and setup HW Audio Codec (AD1939)
initPLL_DDR2DRAM.asm: set up PLL and DDR2 DRAM.
initSPORT.c : Setup SPORT, PCG and SRC
initSRU.c: Signal routing
IRQprocess: Interrupt service routines (not important)
main.c: Do I need to comment this?
SPORTisr.c : Audio Interrupt Service Routine. 
Reply by Mac Decman August 18, 20122012-08-18
On Fri, 17 Aug 2012 15:18:45 -0700 (PDT), Mauritz Jameson
<mjames2393@gmail.com> wrote:

>Hi, > >I'm having a bit of trouble modifying one of the TalkThru projects >that comes with SHARC 21469 EZKit from AD. > >I am trying to implement this signal chain: > >ADC (48kHz) -> SRC (48kHz -> 16kHz) -> Audio Processing -> SRC (16kHz - >> 48kHz) -> DAC (48kHz) > >where audio is sampled at 48kHz. The signal is routed through the SRC >and resampled to 16kHz. The resampled signal is then processed and >sent off to the SRC where it is resampled back up to 48kHz and sent to >the DAC. > >I have tried to inject a 1000Hz sine via the RCA port. When I do an >FFT of the data which supposedly has been resampled down to 16kHz, I >see a spike at 500Hz instead of 1000Hz. > >So....are there any SHARC experts in this group who wouldn't mind >spending a couple of minutes going through my project and telling me >what I am doing wrong? > >Thanks. > >Here is the project: > >https://www.dropbox.com/s/xve021tn05odjul/Talkthrough_withSRC.zip
Did you check my other post about your previous question? I would make sure your sign extention code optimizes to the correct asm. A little bit of roadmap to the code would be helpful before I have to start opening 15 different files looking for what your talking about. Mark DeArman
Reply by Mauritz Jameson August 17, 20122012-08-17
Hi,

I'm having a bit of trouble modifying one of the TalkThru projects
that comes with SHARC 21469 EZKit from AD.

I am trying to implement this signal chain:

ADC (48kHz) -> SRC (48kHz -> 16kHz) -> Audio Processing -> SRC (16kHz -
> 48kHz) -> DAC (48kHz)
where audio is sampled at 48kHz. The signal is routed through the SRC and resampled to 16kHz. The resampled signal is then processed and sent off to the SRC where it is resampled back up to 48kHz and sent to the DAC. I have tried to inject a 1000Hz sine via the RCA port. When I do an FFT of the data which supposedly has been resampled down to 16kHz, I see a spike at 500Hz instead of 1000Hz. So....are there any SHARC experts in this group who wouldn't mind spending a couple of minutes going through my project and telling me what I am doing wrong? Thanks. Here is the project: https://www.dropbox.com/s/xve021tn05odjul/Talkthrough_withSRC.zip