Jump to content
Jongmin.Kang

continuous measurement using Actor Framework

Recommended Posts

Hi all. I just started studying the actor framework. I'm trying to do basic coding in this and the ni community while learning the basics.

I would like to make a continuous measurement and logging system using the actor framework, but I'm in trouble.

The way I originally code it is to put the 'read' function inside the state machine and pass the output of the function to the 'save loop' using the queue.

Here are the questions 1.
Is it correct to code in actor core to use some continuous action or a while loop? To be precise, is it necessary to create an actor core to write one 'read' function?

Questions 2.
If I do not use the actor core and put 'read' in the method vi and measure it for the amount of time I want it, I think I need a 'message' to continue passing automatically, is there a function that does such a function?

Share this post


Link to post
Share on other sites
1 hour ago, Jongmin.Kang said:

Here are the questions 1.
Is it correct to code in actor core to use some continuous action or a while loop? To be precise, is it necessary to create an actor core to write one 'read' function?

I don't know what the recommended way of doing what you want is but you can definitely put a second while loop in one of the children's actor core. You have to make sure you have a way to stop that while loop though. Maybe just put an event structure with a specific timeout and send a user event to stop the loop (and possibly another message to change the timeout)?

1 hour ago, Jongmin.Kang said:

Questions 2.
If I do not use the actor core and put 'read' in the method vi and measure it for the amount of time I want it, I think I need a 'message' to continue passing automatically, is there a function that does such a function?

http://zone.ni.com/reference/en-XX/help/371361P-01/lvcomm/af_td_send/

Share this post


Link to post
Share on other sites

jacobson,

I heard your advice, I tried to code it by continuing 'read' through the Time-Delayed Send Message and ending the message by releasing the notifier.

I am very grateful to you.

Share this post


Link to post
Share on other sites

smithd,

It looks like a really good reference, but I did not run it because I did not have some vi even after downloading it.

Thanks for the help!

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.