Tool/software: Code Composer Studio
I am using CCS 7.0. Essentially, that is the simplest form of what I am trying to do. We have a somewhat fast 38Khz signal in which I want to sample the data at. The interrupt time is taking longer than I want. I figured a DMA would work well to dump the results into a buffer, generate an interrupt once the buffer is full and then process the data. There isn’t any ADC data in the buffer however.
Also, the ADC is supposed to be triggered off a falling edge GPIO but it seems to go whenever it wants to. I don’t know that the issues are related since I could read the ADC values before implement the DMA.
I have a file of snippet code to look at if you want. It is just the latest in a long number of attempts. Most of it has come from scouring the TI forums and example code while also trying to understand what the datasheet is trying to explain.
Looked at the following post where a user finally got ADC DMA working, but this did not get the problem resolved:
I have all the items set up as listed there and still there is no data in the buffer. From what I read in the datasheet, the DMA should fire the ADC interrupt handler when the buffer is half full. (Page 585) I register the ADC interrupt handler but it never goes off. The only time it trips is when I have the ADCIntEnable( ADC1_BASE, 0 ); function call in but this isn’t the behavior I need as it ignores the DMA. Even pausing the code shows the buffer is empty so it isn’t just an interrupt problem.
Is it not possible to have the ADC trigger and load the value into the buffer via DMA? Then get an interrupt when the DMA buffer is half full to process that data?