Path: news.mathworks.com!not-for-mail
From: "Dave Hathaway" <david.hathaway@aecom.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: DAQ SamplesAvailable never >0 after getdata
Date: Thu, 11 Feb 2010 14:40:21 +0000 (UTC)
Organization: AECOM
Lines: 16
Message-ID: <hl14sl$8rp$1@fred.mathworks.com>
References: <hks0ii$p3$1@fred.mathworks.com> <hkuaq8$mhm$1@fred.mathworks.com> <hkufls$802$1@fred.mathworks.com> <hl10di$eh7$1@fred.mathworks.com>
Reply-To: "Dave Hathaway" <david.hathaway@aecom.com>
NNTP-Posting-Host: webapp-05-blr.mathworks.com
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1265899221 9081 172.30.248.35 (11 Feb 2010 14:40:21 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 11 Feb 2010 14:40:21 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1931390
Xref: news.mathworks.com comp.soft-sys.matlab:606462


Sherryl,

Thank you very much for your suggestions.  As a real-time acquisition program, I am concerned about the throughput of all this stuff.  But, ultimately, we'll be grabbing "only" 200 samples per second.  The processing of those samples occurs at minute intervals, and more hourly.

The use of TimerFcn and SamplesAcquiredFcn is a result of neither one working for me.  Now that I am getting sustained data sampled, I'll get rid of the SamplesAcquiredFcn.

One concern that I have is that the program should get what data is acquired at the minute boundary, rather than waiting for 60*200 samples to be obtained.  But doesn't

set(ai, 'SampleRate', 200);
set(ai, 'SamplesPerTrigger', 12000);

mean that I won't get a SamplesAvailable > 0 until I have 12000 samples, even if it takes 61 or 62 seconds?

I guess this issue is outside the topic of this thread, but please know that I have appreciated your help and advice.

Dave Hathaway