From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
03-05-2015 01:54 AM
Hello,
With the help of this forum, I've been learning about FlexRIOs, low-level FPGA programming, the higher-level FlexRIO Instrument Development Library, and general techniques for high-speed synchronization and acquisition.
I believe I'm now on the right track, and would like to ask for feedback/advice from someone who's experienced with FlexRIO (or general PXI FPGA) programming on what I've done. I modified Acq Engine on 5734 PXIe-7962R.lvproj:FPGA Top Generic PXIe.vi to let all 15 cards trigger a synchronized acquisition. I replaced the trigger detection mechanism, but left everything else untouched:
Brief background
Equipment list
Requirements
Explanation for code modifications
Idea
Implementation
Questions
Thanks in advance!
03-05-2015 04:17 PM
Seems fine. I've always just used a single trigger connected to the master, but what you've done to allow any of the slaves to notify the master that it needs to distribute a synchronized trigger to all the slaves should work fine. Not sure what delay you are referring to though. It probably doesn't matter as long as all of the modules see the synchronized trigger at the same time since you can always just increase the number of pre-trigger samples you collect.
Regarding decimation, I suppose you could just dump 11 of every 12 samples to decimate the data down to 10MS/s, but like Rob mentioned, you may get some nasty aliasing. I would look into using the decimation filter he mentioned.
03-06-2015 01:39 AM
@David-A wrote:
Seems fine. I've always just used a single trigger connected to the master, but what you've done to allow any of the slaves to notify the master that it needs to distribute a synchronized trigger to all the slaves should work fine. Not sure what delay you are referring to though. It probably doesn't matter as long as all of the modules see the synchronized trigger at the same time since you can always just increase the number of pre-trigger samples you collect.
Thanks for confirming, David.
About the delay: With the default example, if I specify 50 pre-trigger samples, then on the host graph I see the y-threshold crossed at t=50. With my modifications, I see the y-threshold crossed at t=48.
But you're right. Since the shift is constant across all cards, all I need to do is read 2 extra pre-trigger samples to compensate -- not a problem.
@David-A wrote:
Regarding decimation, I suppose you could just dump 11 of every 12 samples to decimate the data down to 10MS/s, but like Rob mentioned, you may get some nasty aliasing. I would look into using the decimation filter he mentioned.
I understand the importance of a decimation filter.
To clarify my question: After filtering my signals, how do I get the FIDL multi-record system to pass downsampled data to the host?
I tried modifying Acquisition Engine - Facade.lvlib: Packer.vi to Enable every 12th sample:
Explanation
However, the data received by the host is corrupted. Below is from a 100 kHz sine wave input, sampled at 10 MHz. I asked for 100 pre-trigger and 200 post-trigger samples, which should give me 3 cycles. It looks like the wrong sections from the buffer are being read from:
What did I do wrong?
03-06-2015 12:43 PM - edited 03-06-2015 12:45 PM
The record state machine that is immediately upstream of the packer VI is responisble for counting the number of samples that you've acquired since the trigger was detected and notifying the VI's downstream of itself when the requested number of post trigger samples have been acquired. The record state machine assumes that a valid sample is acquired every tick.
To use the method you've chosen to decimate the data, you would need to crack open acqEngineRecordStateMachine.vi and get it to count up in unison with the packer vi.