I would like to sample an arbitrary waveform from a function generator synchronously to the sync output while timing the period of the sync. To do this I have the input capture set to do a hardware trigger for the ADC which then does a series of measurements which are copied to RAM with the DMA. In order to time the sync I have the prescale set to 1 which makes the FTM overflow often, so I also used the Global Time Base to synchronize 2 FTM's so that I could separate the ISR for the overflow from the input capture event ISR.
The problem I am having is that I am getting a hardware trigger from the FTM for the ADC when the timer overflow occurs. Is there a way to stop this from happening? Or will I need to do something different, such as have the input capture trigger the PDB which triggers the ADC, but even then I would assume I would see the same issue I am having. In the end I would like to have a very repeatable delay from the Input capture event to the start of the ADC's measurement cycle.
I am using the TWR-K40X256 with Codewarrior 10.2.