Go to Post Do you have to think about FIRST when you get up in the morning? - KenWittlief [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
  #2   Spotlight this post!  
Unread 03-02-2015, 06:52
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,752
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: Switch Camera in Labview Dashboard with Joystick

If the camera selector already does what you want, the task isn't hard, but will involve a little code in each language.

In Java, on the robot, read the joystick and update a Smart Dashboard variable that represents the desired camera state.

On the DB, in LV, in the top loop, you will want to read the Smart Dashboard variable by name and update the LabVIEW control using a local variable update. The top loop already has several reads of the joystick and motors. You can drop another by right clicking on the diagram and going to the bottom of the palettes. Drop the SD Read Value, choose the correct type from the selector, and wire up the name of the SD Variable.

In the second loop, where the vision is performed, you can right click on the blue Vision terminal and choose to Create >> Local Variable. Drop it into the top loop downstream of the SD Read. Wire the output of the read to the local variable. Add any mapping math to either the Java or Dashboard.

Greg McKaskle
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 21:30.

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