Go to Post Hasn't that always been the mission of FIRST? Don't settle for what works; strive for what amazes. - Sam Lipscomb [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

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 12-02-2013, 21:43
bspymaster's Avatar
bspymaster bspymaster is offline
Registered User
FRC #1732
Team Role: Programmer
 
Join Date: Jan 2011
Rookie Year: 2011
Location: here
Posts: 15
bspymaster is an unknown quantity at this point
Post reading and writing dashboard data

Hello.
I am currently working on the dashboard project for our team for the tournament. I am trying to send a string variable from the dashboard program to the CrIO to tell the robot which autonomous mode to run. I tried using the Smart Dashbord "SD Read String" vi in the robot code and using "SD Write String" in the dashboard, but it only sends the information to the code once, if the dashboard was turned on before the robot code was deployed. It never updates afterwards, no matter what I do, unless I redeploy the code. Both parts of the code are written inside of while loops. Any suggestions? Thanks.
Reply With Quote
  #2   Spotlight this post!  
Unread 12-02-2013, 22:03
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: reading and writing dashboard data

How are you changing the value of the string in the Dashboard?
Reply With Quote
  #3   Spotlight this post!  
Unread 12-02-2013, 23:07
bspymaster's Avatar
bspymaster bspymaster is offline
Registered User
FRC #1732
Team Role: Programmer
 
Join Date: Jan 2011
Rookie Year: 2011
Location: here
Posts: 15
bspymaster is an unknown quantity at this point
Re: reading and writing dashboard data

It is a dropdown string box (I forget what Labview calls it). the output from the control is a string. I'm plugging that string into a case structure in autonomous independent.vi.
Reply With Quote
  #4   Spotlight this post!  
Unread 12-02-2013, 23:20
Joe Ross's Avatar Unsung FIRST Hero
Joe Ross Joe Ross is offline
Registered User
FRC #0330 (Beachbots)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1997
Location: Los Angeles, CA
Posts: 8,579
Joe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond repute
Re: reading and writing dashboard data

Does it show up correctly in the variables tab of the dashboard? Is the control also in a while loop, or just the write string vi?
Reply With Quote
  #5   Spotlight this post!  
Unread 12-02-2013, 23:35
bspymaster's Avatar
bspymaster bspymaster is offline
Registered User
FRC #1732
Team Role: Programmer
 
Join Date: Jan 2011
Rookie Year: 2011
Location: here
Posts: 15
bspymaster is an unknown quantity at this point
Re: reading and writing dashboard data

I never thought to check the variables tab. Good idea! The entire thing (including the control) is in the while loop. in the CrIO code, the entire thing is in a loop as well.
Reply With Quote
  #6   Spotlight this post!  
Unread 13-02-2013, 00:08
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: reading and writing dashboard data

You probably don't need to do an explicit SD Write String with the control's value. Just putting a disconnected control on the Operation tab of the Dashboard is enough to share it as a SmartDashboard variable.
Reply With Quote
Reply


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 22:58.

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