Before explaining the steps I've taken to date, I'd like to first describe the technical scope of my challenge. In short, I would like to acquire data (ADC) at a rate of 250,000 kSps that is synchronized with a trigger that occurs every 10-40 Hz. Additionally, it is necessary to perform signal averaging on the data as the actual signal is quite noisy (typically a couple of hundred averages is needed) so I would like to average the readings from the respective data bins as defined by the trigger.

[TL : DR]

How to sample multiple ADCs continuously while simultaneously stream data through the USB?

From my experimentation using the links and discussions below, I gather that a single buffer collecting all of the data at 12-bit resolution is simply not possible and that a buffering approach may be best through a combination of PDB and DMA. However, this raises the question as to how to synchronize the buffer to the trigger especially if you need a circular/ring buffer to capture the data? Is there a way to tag/timestamp the values with respect to the trigger and still stream the information?

My initial thought was to simply acquire data on two channels with ADC0 sampling the input trigger and ADC1 sample the actual signal, send the data back to the PC, and fold the data appropriately using some other script based upon the rising edges recorded on the ADC0 channel. Is this a rational approach or is there a better option?

Digging through the forums the range of examples from tni have been extremely helpful: In this example I can get the sampling rates needed but it is unclear to me how to trigger the byte stream back to the PC. My guess is that I need to detect when the buffer is full and transfer the last half before it is overwritten. This seems to be where I'm running into a lack of knowledge regarding how to trigger an interrupt and use a circular/ring buffer appropriately.

Other potential/partial solutions investigated: