11-13-2008 01:11 PM
Folks -
Just got USB-5132 s in, trying to use NI-Scope in LV 8.5.1. What I want to do is simple : read 2.5M records at 20Mhz internally clocked, into both channels using PF1 as trigger source, positive edge. Below is my little VI and the error generated at the "read" . Simple, right ? but what am I doing wrong ?
TIA
Alex
Solved! Go to Solution.
11-13-2008 03:16 PM
Hi Alex,
Thanks for the post!
Coud you please re-attach your vi?
How have you set your read, Nsamples etc? Common issues with Reads are underflow/overflow issues.
Kind Regards,
James.
11-13-2008 03:52 PM
11-14-2008 03:59 AM
Hi Alex.
Thanks for the reply.
I think the problem is the numSamples is the maximum number of samples to fetch for each waveform; if the acquisition finishes with fewer points than requested, some devices return partial data if the acquisition finished, was aborted, or a timeout of 0 was used. Use –1 for this parameter if you want to fetch all available samples. The VI reads the actual record length and attempts to acquire all available samples. If it fails to complete within the timeout period, the VI returns an error.
So do you get an error if you set this to -1?
I think you maybe over-writing the data in the buffer.
If you take a look at the niScope EX Multi Record Fetch More Than Available Memory.vi in the example finder. It features a property node which allows more records than can be fitted in the buffer. Im sure you coud alter this example to use the PFI trigger etc.
Please let me know what you think,
Kind Regards,
James.
11-14-2008 08:42 AM
Hi -
Same error . Noticing that I don't have a way yet to poll and see if the device is indeed triggered, and wait until it is , I set the trigger config to "immediate software" , and single-stepped through to make sure that there was enough time to do the acquisition. Didn't help either. It does though bring up another question : What is the best way to arm and wait for an externally triggered acquisition ? In this case, a separate loop is asking an external server if a big data system is ready for the next shot (which might take minutes or hours) , then arms the 5132 and waits for 3-30 min, then , once triggered , reads the data back and processes it. I see a few paths to that in the NI-SCOPE examples, but It would save wading through errors to know if there is a standard path of vis.I'm wondering if, going back to my numSamples problem, whether the device is in fact not in some armed state, even when I give it immediate trigger, and that it has zero samples because the read does not wait for an "I'm done" signal.
Alex
11-17-2008 01:27 PM
Hello Alex,
One of the problems you are running into is that your device does not support multiple record acquisition. The example you are trying to run uses this feature.
An example VI that you could run with this device would be the niScope EX Configured Acquisition, found under Hardware Input and Output»Modular Instruments»NI-SCOPE(High-Speed Digitizers)»General. This example is set to acquire a single record and then run the acquisition again. By modifying this example you should be able to get what you need.
Regards,
Dan King
11-17-2008 02:25 PM