David King

MC56F8006 DTMF

Discussion created by David King on Feb 24, 2010
Latest reply on Mar 12, 2010 by Processor Expert

I'm trying to implement a DTMF decoder using my MC56F8006Demo board.  I feel like I'm pretty close.  When I run it in debugging mode in Code Warrior it looks like it jumps to void Cpu_Interrupt(void), which apparently is for unhanded interrupts.


Whenever I comment out this line, I don't have the problem. 


dtmfresult = DTMFDetection(pDTMFDet, (Frac16 *) &AdcBuffer[AdcReadIndex], 16);


Also, if I put a breakpoint on that line then it never seems to jump to the Cpu_interrupt.  I'm guessing there's either a timing problem or I'm not continuing enough times to hit whatever condition is causing the problem.  I was hoping I could look at the variables before it called the DTMFDetection function and find something wrong that caused it to hit the interrupt, but no luck.  After it hits the interrupt I'm having a hard time finding what's causing the problem.


I've attached the code, it's basically a modified version of the FFT example.  It still has a lot of the FFT stuff in it, I'm using that to verify sampling my sound source is working, I plan on cleaning that all out once I get it working.  It looks like the problem happens independent of my sound source connected to the board, so you shouldn't need to connect anything to the board to see the error.