How can I set trigger callback function for session based interface?

1 view (last 30 days)
Hi,
I want to callback some functions when trigger is executed in DAQ session based interface.
How can I set it? I tried to execute >> set(AI,'TriggerFcn',@show_data); but matlab says "TriggerFcn is not an accessable property for 'daq.ni.Session'". The instrument is NI USB-6251 and Matlab version is R2013b.
Sincerely yours
  1 Comment
Yishai
Yishai on 12 May 2015
Has anyone looked into this int he past 9 months? This is essentially capabilities that existed in the past and were removed.

Sign in to comment.

Answers (2)

Walter Roberson
Walter Roberson on 13 May 2015
Add a listener for DataAvailable? See here and an example of someone using it over there
  2 Comments
Ryoya Ikuta
Ryoya Ikuta on 13 May 2015
Thank you. I successfully add a listener for DataAvailable. I finally found that session based functions are very convenient.

Sign in to comment.


Yishai
Yishai on 4 Aug 2014
I would like to second this question. This is functionality that existed in the legacy based interface and was removed in the session-based interface. I don't know how to convert my old code to this now.
  1 Comment
Ryoya Ikuta
Ryoya Ikuta on 4 Aug 2014
Dear Mr.Yishai
Thank you. I see callback was removed in the session-based interface. Can anyone answer our question?

Sign in to comment.

Categories

Find more on Introduction to Installation and Licensing in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!