Go to Post please remember that the children we are trying to positively influence do read these forums. - Amanda Morrison [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 01-03-2015, 01:22
Slade Slade is offline
Registered User
FRC #4471 (Spartrons)
Team Role: Programmer
 
Join Date: Jan 2015
Rookie Year: 2013
Location: Florida
Posts: 24
Slade is an unknown quantity at this point
Re: Custom Driver Station on the Field

Quote:
Originally Posted by Alan Anderson View Post
A team at the Indianapolis district competition had the same problem. The SD variables on the Basic tab don't seem to be getting to the robot when they're connected on the field. The team says they were working fine earlier in the day, but now don't -- and they made no code changes at the time.

They came up with a workaround: they tether the robot in the queue and set the value then, leaving the robot on until the match is over.
So instead of building the code and pressing Run as Startup, we should just press the button that is a "soft" deploy(The button to the left: http://puu.sh/ghsYK/d1b8777f29.png) and then pick it through the dashboard, then disconnect the thether, and when we get to the field, just do our thing and connect the computer to their ethernet?
Reply With Quote
  #2   Spotlight this post!  
Unread 01-03-2015, 05:53
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,112
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: Custom Driver Station on the Field

Quote:
Originally Posted by Slade View Post
So instead of building the code and pressing Run as Startup, we should just press the button that is a "soft" deploy(The button to the left: http://puu.sh/ghsYK/d1b8777f29.png) and then pick it through the dashboard, then disconnect the thether, and when we get to the field, just do our thing and connect the computer to their ethernet?
No. Why would you think you should do that? As soon as you unplug and lose the network connection, the interactive execution will stop. All the team did was to power up the robot with the Driver Station computer connected by wire, set the control on the Dashboard appropriately, and unplug the tether. The SD value was retained by the roboRIO as long as it didn't get powered down before the match began.
Reply With Quote
  #3   Spotlight this post!  
Unread 01-03-2015, 11:06
MrRoboSteve MrRoboSteve is offline
Mentor
AKA: Steve Peterson
FRC #3081 (Kennedy RoboEagles)
Team Role: Mentor
 
Join Date: Mar 2012
Rookie Year: 2011
Location: Bloomington, MN
Posts: 577
MrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond repute
Re: Custom Driver Station on the Field

Another thing to try is to close and reopen the driver station and dashboard prior to connecting to the field.
__________________
2016-17 events: 10000 Lakes Regional, Northern Lights Regional, FTC Burnsville Qualifying Tournament

2011 - present · FRC 3081 Kennedy RoboEagles mentor
2013 - present · event volunteer at 10000 Lakes Regional, Northern Lights Regional, North Star Regional, Lake Superior Regional, Minnesota State Tournament, PNW District 4 Glacier Peak, MN FTC, CMP
http://twitter.com/MrRoboSteve · www.linkedin.com/in/speterson
Reply With Quote
  #4   Spotlight this post!  
Unread 03-03-2015, 10:51
MikeF1617 MikeF1617 is offline
Registered User
AKA: Michael Fischler
FRC #1124 (UberBots)
Team Role: Programmer
 
Join Date: Sep 2013
Rookie Year: 2013
Location: United States
Posts: 15
MikeF1617 is an unknown quantity at this point
Re: Custom Driver Station on the Field

Quote:
Originally Posted by MrRoboSteve View Post
Another thing to try is to close and reopen the driver station and dashboard prior to connecting to the field.
This may fix it, except after connecting to the field and being sure the robot code is started (boot your robot before going onto the field and peeking at other driver stations to see if FMS is established or seeing if team numbers are on correct on the player stations). I found that the TCP connection (contains all the network variables) does not open for some reason with the dashboard code if the robot has not been started up first and the FMS hasn't established a connection yet, it matters the boot order of the robot code and the FMS connection. I found that if you wait on opening the dashboard (logging into driver on the classmate PC if you have it as start-up), everything works fine. I created indicators that indicate when the dashboard establishes connection with the robot by checking to see if a code revision was written to a network variable by the robot, this or checking your variables tab will tell you if you have connected.

We set our autonomous mode before the match starts, and it is stored in a global variable (not necessary but we have dashboard code and robot code separated in different loops in different areas, its a custom structure) on the robot, and that does the trick, as long as there is a connection to the dashboard established. This seems to be a bug with the dashboard code, and if other people are having this issue, then I would assume its a problem with the code provided in the WPIlib or the TCP just doesn't work well in certain scenarios for some reason, and I haven't found a fix yet. Its a pretty weird problem.

Last edited by MikeF1617 : 03-03-2015 at 10:53. Reason: clarification
Reply With Quote
  #5   Spotlight this post!  
Unread 03-03-2015, 11:12
TylerStaudigel's Avatar
TylerStaudigel TylerStaudigel is offline
Registered User
FRC #0144 (R.O.C.K)
Team Role: Programmer
 
Join Date: Dec 2013
Rookie Year: 2014
Location: United States
Posts: 39
TylerStaudigel is an unknown quantity at this point
Re: Custom Driver Station on the Field

Check your data types in automatous mode. The data coming from your numeric read does not match the date type that you loop is looking for causing the loop to default to zero every time you run the program.
http://puu.sh/ggnQW/e4c23b7496.png

Last edited by TylerStaudigel : 03-03-2015 at 11:13. Reason: added link
Reply With Quote
  #6   Spotlight this post!  
Unread 03-03-2015, 11:21
Mark McLeod's Avatar
Mark McLeod Mark McLeod is offline
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,795
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Custom Driver Station on the Field

Yea, your data type in Autonomous is a floating point number not the integer type of the Case. The floating point number doesn't equal any of the integer cases, so it is taking the default.

The problem exists on both the Dashboard side and the robot side.
You need to write/read an integer on both sides and you need to make sure the enum order matches the numbers you expect.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle

Last edited by Mark McLeod : 03-03-2015 at 11:24.
Reply With Quote
  #7   Spotlight this post!  
Unread 04-03-2015, 00:16
MikeF1617 MikeF1617 is offline
Registered User
AKA: Michael Fischler
FRC #1124 (UberBots)
Team Role: Programmer
 
Join Date: Sep 2013
Rookie Year: 2013
Location: United States
Posts: 15
MikeF1617 is an unknown quantity at this point
Re: Custom Driver Station on the Field

Quote:
Originally Posted by Mark McLeod View Post
Yea, your data type in Autonomous is a floating point number not the integer type of the Case. The floating point number doesn't equal any of the integer cases, so it is taking the default.

The problem exists on both the Dashboard side and the robot side.
You need to write/read an integer on both sides and you need to make sure the enum order matches the numbers you expect.
This is how I managed the different datatypes in our code. (The image contains two screenshots, one from the dashboard and one from the robot code.) On the robot code side, the mode is being casted into an enum typedef using the Type Cast function in the Numeric Palette under Data Manipulation.

However, LabVIEW should be (and I assume is) automatically casting the double into an integer, as shown by the red dot in this screenshot that you are referencing:
http://puu.sh/ggnQW/e4c23b7496.png

So technically, that part should be working fine, but it is better to cast it yourself, just as good practice. There is probably some communication issue occurring here, however, so try to recreate the problem in practice with a similar setup to how you run your robot at competition, specifically the boot order and time of connection.
Attached Thumbnails
Click image for larger version

Name:	dashboard auto config.png
Views:	21
Size:	11.0 KB
ID:	18547  
Reply With Quote
  #8   Spotlight this post!  
Unread 03-03-2015, 11:28
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,563
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: Custom Driver Station on the Field

Quote:
Originally Posted by MikeF1617 View Post
This may fix it, except after connecting to the field and being sure the robot code is started (boot your robot before going onto the field and peeking at other driver stations to see if FMS is established or seeing if team numbers are on correct on the player stations). I found that the TCP connection (contains all the network variables) does not open for some reason with the dashboard code if the robot has not been started up first and the FMS hasn't established a connection yet, it matters the boot order of the robot code and the FMS connection. I found that if you wait on opening the dashboard (logging into driver on the classmate PC if you have it as start-up), everything works fine. I created indicators that indicate when the dashboard establishes connection with the robot by checking to see if a code revision was written to a network variable by the robot, this or checking your variables tab will tell you if you have connected.
FIRST is looking into this: http://forums.usfirst.org/showthread...3862#post93862
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 10:25.

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