04-13-2017 02:58 PM
That may or may not be solved. I described how to put the original AI data in phase with its harmonics on a GUI graph, or how to put a delayed *copy* of the original AI data in phase with its harmonics out onto 2 channels of AO. What hasn't been solved yet would be a way to make the delayed harmonics on AO to be delayed by exactly an integer # of cycles from the raw AI such that they *appear* to be in phase.
I think the best hope to make that work is if the AI waveform will have a very consistent period. Then there'll probably need to be some trial and error to find the right combo of # samples to read, size of AO buffer, and # samples of 0 V to pre-write before you start writing harmonics. You'll also want to sync the AI and AO tasks with a shared sample clock.
-Kevin P