High-Speed Digitizers

cancel
Showing results for 
Search instead for 
Did you mean: 

Continuous Streaming workarounds on 5122

Hello,

I've been trying to implement niScope streaming in my system based on this post (http://forums.ni.com/t5/Example-Program-Drafts/Scope-Streaming-Examples/ta-p/3522487) specifically this example(http://forums.ni.com/t5/Example-Program-Drafts/niScope-Multiple-Channel-Stream-to-Memory-Continuous-...).

Right now, the onboard memory gets filled up too fast and eventually throws the "data overwritten error". I can't drop the sampling rate on my digitizer for other reasons, so I need a work around.

Is there a way to ignore the data overwritten error? Because it would be fine if the data was continuously streaming and overwriting the buffer. If you can ignore it, then, how do you fetch a particular section of data from the onboard memory?

And lastly, how could you temporarily pause the streaming, so that the fetching could continue and flush out the onboard memory, and then continue streaming normally?

Thanks in advance for any help or resources you can directly me to.

Jazz

0 Kudos
Message 1 of 4
(3,856 Views)

Depending on what you are trying to do, ignoring an overwrite error may cause other issues for you - like not fetching the signal that you expect to be in the buffer. There isn't much detail on your application or need here, so I'll just assume that this won't be a problem for you:

 

How Do I Ignore a Specific Error in LabVIEW?

 

Depending on what you want to do, here is some background on relative fetching functions laid out in the NI High-Speed Digitizers help;

 

Acquiring Data Continuously

 

I think you will have to elaborate on your final question, I'm not entirely sure what you mean there. Also, any further insight to your application would do a lot to help the community offer up valuable suggestions on how to go about it. 

 

Best,

Sam R.
0 Kudos
Message 2 of 4
(3,780 Views)

A few years ago I wanted something similar, and the answer was "you can't make difitizer to ignore the error". This means you can't do it in an elegant way. You can monitor fetch backlog and stop acquisition before memory got full. This allows you to save all the data from onboard memory, which was already acquired but not yet fetched. Then you can start it again.

Here I assume you can't fetch fast enough, perhaps due to bus or disk limitations. Make sure your processing doe not affect. I mean try to do nothing with data fetched, not even wire them.

If the issue is in processing speed then you can use producer-consumer and queue and flush it from time to time.

 

P.S. I did not dig too deep then, and gave it up )

0 Kudos
Message 3 of 4
(3,768 Views)

A couple options:

  • configure for continuous records and configure a software trigger.  You'll have to issue the software trigger in a loop to keep the records acquiring, but that will essentially 'pause' the acquisition so that you fetch the data off the board.  Another option instead of configuring for software trigger is configure 'trigger holdoff' to a time that allows you to keep up without overwrites.
  • fetch relative to 'now' with a negative fetch offset.  This will ensure that you are fetching relative to the most recent point acquired by the digitizer.  You can use the timestamp returned with the fetch to see how many samples have passed since your last fetch (assuming you save the timestamp from the last fetch). 
Message 4 of 4
(3,766 Views)