Go to Post There is nothing that says 'gracious professionalism' like making brunch for your opponents. - Monochron [more]
Home
Go Back   Chief Delphi > Technical > Programming > Python
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 16-02-2016, 08:27
onenerdyguy onenerdyguy is offline
Registered User
FRC #5929
 
Join Date: Jan 2016
Location: Lake Park, MN
Posts: 39
onenerdyguy is an unknown quantity at this point
Issue with Stateful Autonomous/Smart Dashboard

So, I've got the stateful autonomous setup and running (love how easy it was, by the way). When I sim the robot in pyfrc, the options all show up in the drop down.

However, when I throw the code on the bot, I have no idea where to look to find the chooser? We're on the vanilla drivers station, direct from the 2016 image.

Any suggestions for a rookie team who is *really* feeling the end of build season?
Reply With Quote
  #2   Spotlight this post!  
Unread 16-02-2016, 09:01
WubbaDuck WubbaDuck is offline
Registered User
FRC #0074 (Chaos)
Team Role: Mentor
 
Join Date: Jan 2016
Rookie Year: 2010
Location: Michigan
Posts: 6
WubbaDuck is an unknown quantity at this point
Re: Issue with Stateful Autonomous/Smart Dashboard

Which dashboard are you using? There are several options, but the Java Smartdashboard is the one we are using. It just shows up on the dashboard after you initialize it in the code. To install it you will need Eclipse and the wpilib addons that go with that. Here is a good resource for getting this all set up https://wpilib.screenstepslive.com/s/4485/m/26401
Reply With Quote
  #3   Spotlight this post!  
Unread 16-02-2016, 09:02
onenerdyguy onenerdyguy is offline
Registered User
FRC #5929
 
Join Date: Jan 2016
Location: Lake Park, MN
Posts: 39
onenerdyguy is an unknown quantity at this point
Re: Issue with Stateful Autonomous/Smart Dashboard

Quote:
Originally Posted by WubbaDuck View Post
Which dashboard are you using? There are several options, but the Java Smartdashboard is the one we are using. It just shows up on the dashboard after you initialize it in the code. To install it you will need Eclipse and the wpilib addons that go with that. Here is a good resource for getting this all set up https://wpilib.screenstepslive.com/s/4485/m/26401
I'm using the Dashboard that came pre-installed on the Classmate. The title bar states "FRC PC Dashboard".

Is that a different dashboard?
Reply With Quote
  #4   Spotlight this post!  
Unread 16-02-2016, 09:07
WubbaDuck WubbaDuck is offline
Registered User
FRC #0074 (Chaos)
Team Role: Mentor
 
Join Date: Jan 2016
Rookie Year: 2010
Location: Michigan
Posts: 6
WubbaDuck is an unknown quantity at this point
Re: Issue with Stateful Autonomous/Smart Dashboard

Yeah, it is different. The built in one is LabView based, I believe and the Java SmartDashboard allows for a ton of customization like adding an auton chooser.
Reply With Quote
  #5   Spotlight this post!  
Unread 16-02-2016, 09:08
onenerdyguy onenerdyguy is offline
Registered User
FRC #5929
 
Join Date: Jan 2016
Location: Lake Park, MN
Posts: 39
onenerdyguy is an unknown quantity at this point
Re: Issue with Stateful Autonomous/Smart Dashboard

Quote:
Originally Posted by WubbaDuck View Post
Yeah, it is different. The built in one is LabView based, I believe and the Java SmartDashboard allows for a ton of customization like adding an auton chooser.
Well, that'll be the first thing to check then. Thanks so much!
Reply With Quote
  #6   Spotlight this post!  
Unread 16-02-2016, 09:58
aeastet aeastet is offline
Programming Mentor
AKA: Tim Easterling
FRC #6043 (Allegan Tigers Robotics)
Team Role: Coach
 
Join Date: Jan 2015
Rookie Year: 2011
Location: Holland, MI
Posts: 116
aeastet is an unknown quantity at this point
Re: Issue with Stateful Autonomous/Smart Dashboard

The LabVIEW version allows for the same customization. You can do what ever you want to do.
Reply With Quote
  #7   Spotlight this post!  
Unread 16-02-2016, 11:07
virtuald's Avatar
virtuald virtuald is offline
RobotPy Guy
AKA: Dustin Spicuzza
FRC #1418 (), FRC #1973, FRC #4796, FRC #6367 ()
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2003
Location: Boston, MA
Posts: 1,040
virtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant future
Re: Issue with Stateful Autonomous/Smart Dashboard

Quote:
Originally Posted by aeastet View Post
The LabVIEW version allows for the same customization. You can do what ever you want to do.
You will not be able to communicate with python programs from the LabVIEW dashboard via NetworkTables, as the LabVIEW dashboard is not backwards compatible with NT2 clients, and we haven't upgraded pynetworktables to NT3 yet.
__________________
Maintainer of RobotPy - Python for FRC
Creator of pyfrc (Robot Simulator + utilities for Python) and pynetworktables/pynetworktables2js (NetworkTables for Python & Javascript)

2017 Season: Teams #1973, #4796, #6369
Team #1418 (remote mentor): Newton Quarterfinalists, 2016 Chesapeake District Champion, 2x Innovation in Control award, 2x district event winner
Team #1418: 2015 DC Regional Innovation In Control Award, #2 seed; 2014 VA Industrial Design Award; 2014 Finalists in DC & VA
Team #2423: 2012 & 2013 Boston Regional Innovation in Control Award


Resources: FIRSTWiki (relaunched!) | My Software Stuff
Reply With Quote
  #8   Spotlight this post!  
Unread 16-02-2016, 09:01
onenerdyguy onenerdyguy is offline
Registered User
FRC #5929
 
Join Date: Jan 2016
Location: Lake Park, MN
Posts: 39
onenerdyguy is an unknown quantity at this point
Re: Issue with Stateful Autonomous/Smart Dashboard

As I read a bit more, I notice some other code examples showing that you need some code on the drivers station...

Where would I put that? Our experience with the drivers station so far is turning it on when we want to drive, making sure we're enabled, teleop, etc, and using it to make sure our USB mappings are correct...
Reply With Quote
  #9   Spotlight this post!  
Unread 16-02-2016, 10:43
TimTheGreat's Avatar
TimTheGreat TimTheGreat is offline
ArchdukeTim
FRC #1418 (Vae Victis)
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Falls Church
Posts: 234
TimTheGreat has a spectacular aura aboutTimTheGreat has a spectacular aura aboutTimTheGreat has a spectacular aura about
Re: Issue with Stateful Autonomous/Smart Dashboard

Quote:
Originally Posted by onenerdyguy View Post
As I read a bit more, I notice some other code examples showing that you need some code on the drivers station...

Where would I put that? Our experience with the drivers station so far is turning it on when we want to drive, making sure we're enabled, teleop, etc, and using it to make sure our USB mappings are correct...
You shouldn't need to put any code on DS. If you use eclipse then get the wpilib plugin (instructions found here)

Run smartdashboard from the wpilib menu bar and connect to roborio-XXXX-frc.local (XXXX is team #). In the Autonomous Mode folder you need to add the key "selected" and make the value the MODE_NAME of the mode you want to run.
__________________
There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult.



2012 - Gracious Professionalism - Greater DC
2014 - Regional Finalist - Virginia | Industrial Design - Virginia | Regional Finalist - Greater DC
2015 - Innovation in Control - Greater DC
2016 - District Event Winner - VAHAY | Innovation in Control - VAHAY | District Event Winner - MDBET | Industrial Design - MDBET | District Champion - CHCMP | Innovation in Control - CHCMP
Reply With Quote
  #10   Spotlight this post!  
Unread 16-02-2016, 11:05
virtuald's Avatar
virtuald virtuald is offline
RobotPy Guy
AKA: Dustin Spicuzza
FRC #1418 (), FRC #1973, FRC #4796, FRC #6367 ()
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2003
Location: Boston, MA
Posts: 1,040
virtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant future
Re: Issue with Stateful Autonomous/Smart Dashboard

The short answer is that which was said above: get SmartDashboard running (which I think you can select in the DS if you set it to "Java Dashboard") and the autonomous chooser will just show up. However, customizing SmartDashboard and (in particular) making it pretty is fairly annoying.

With that in mind, I'll give you another option: pynetworktables2js

It makes building a dashboard and interacting with the robot as easy as making a webpage! The example program has an 'autonomous.html' page that shows a combo box which lets you choose autonomous modes.

https://github.com/robotpy/pynetwork...master/example
__________________
Maintainer of RobotPy - Python for FRC
Creator of pyfrc (Robot Simulator + utilities for Python) and pynetworktables/pynetworktables2js (NetworkTables for Python & Javascript)

2017 Season: Teams #1973, #4796, #6369
Team #1418 (remote mentor): Newton Quarterfinalists, 2016 Chesapeake District Champion, 2x Innovation in Control award, 2x district event winner
Team #1418: 2015 DC Regional Innovation In Control Award, #2 seed; 2014 VA Industrial Design Award; 2014 Finalists in DC & VA
Team #2423: 2012 & 2013 Boston Regional Innovation in Control Award


Resources: FIRSTWiki (relaunched!) | My Software Stuff
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 19:53.

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