Go to Post I think this thread needs a reminder that there's no h in mecanum. ;) - Lil' Lavery [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #3   Spotlight this post!  
Unread 25-10-2015, 10:34
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,748
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: Autonomous Independent Cluster Input

Parallel operations cannot share data through synchronized data flow wires. If they did, they'd no longer be parallel and independent.

So there are a number of additional language constructs in LabVIEW to support the sharing of data when in a parallel, non-sequential situation. The easiest to use, and the one the framework suggests in the attached comment, is the variable. In this case, the global variable. Write to it in the Vision loop and read from it in the auto loop and it probably does what you need. The only additional consideration you may want is to initialize it so that things don't misbehave if vision is removed or failing to function how it is supposed to.

Just to look at alternatives.

When you do not want to miss a value, you may want to use a queue. Vision would enqueue information, and autonomous would dequeue and process it. Because the information in the queue can get stale pretty quickly, I don't think a queue is a good idea.

When you want a more event-driven form of execution, you may want to use a notifier. This is a special form of single-element-queue with overwrite. The vision loop would post a notification to auto when it sees something, and the auto would automatically sleep until something is posted.

Other data sharing mechanisms exist as well, and the functional global lets you build your own that are custom suited to your task.

But in the case of vision and auto, a simple global variable is really pretty good approach.

Greg McKaskle
Attached Thumbnails
Click image for larger version

Name:	From Clipboard 2.png
Views:	15
Size:	39.1 KB
ID:	19372  
Reply With Quote
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 20:45.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi