Jump to content

Graph plotting and shift register


Nikunj

Recommended Posts

  • 4 weeks later...

Hey Nikunj,

Sounds like you have a fun project to work with. As you have multiple tasks (or processes/threads, whatever suits your fancy), you might want to try out structuring your code as such. In an OS they're typically referred to as threads, and in LV there is potential for the same structure, and it is really efficient.

One option in LV that may work well for you is a Queued-State Machine(QSM), where each 'task', or collection of common tasks is it's own thread (or QSM). There is a ton of info on the forum about this concept, but it essentially mimics the behavior of an OS.

Here is an example, but by no means the best example (check the forum):

-http://forums.lavag.org/PM341-t13547.html (the stepper_II.zip file)

For your application, one effective method for the graph plotting would be to make it a seperate thread. It would then be up to the 'serial' thread to pass incoming data to it.

If you are interested and your project warrants the time for it, play around a bit with this option. You may find it can be very flexible for your needs.

Best of Luck,

-Justin

*I've also attached a simple vi showing that queues can pass anything you want them to.

Link to comment

Join the conversation

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

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
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.