View Single Post
  #4   Spotlight this post!  
Unread 03-22-2016, 07:54 AM
PhilBot's Avatar
PhilBot PhilBot is offline
Get a life? This IS my life!
AKA: Phil Malone
FRC #1629 (GaCo: The Garrett Coalition)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2006
Location: Maryland
Posts: 744
PhilBot has a reputation beyond reputePhilBot has a reputation beyond reputePhilBot has a reputation beyond reputePhilBot has a reputation beyond reputePhilBot has a reputation beyond reputePhilBot has a reputation beyond reputePhilBot has a reputation beyond reputePhilBot has a reputation beyond reputePhilBot has a reputation beyond reputePhilBot has a reputation beyond reputePhilBot has a reputation beyond repute
Re: Is Smart Dashboard really this limited?

Quote:
Originally Posted by lopsided98 View Post
You can use an autonomous selector (SendableChooser) even if you are not using the Command system.

You can place any type of data in the SendableChooser, not just Commands, because SendableChooser.addObject() takes any type of Object as its second parameter. You could use numbers or strings instead and then use these to decide which autonomous to run.
Hi.

Thanks for the information about the send-able chooser. I had wondered what the limitations were for the attached data. So, how does the program get access to this attached data? The normal chooser operation seems to dictate what gets run in Auto, but I just want to get access to the "chosen" parameter. The Screen Steps docs just jump over how the chooser actually works, and just shows how to use it for automatic command selection.

So, lets say I just want to chose between 6 different enum values. Assuming I can figure out how to load up the chooser, how, where and when do I access the chosen value?

I'm an experienced C++ programmer, but I'm new to Java. It's fun, but I'm just not loving having to guess how to use these classes in the FRC code.

I'll definitely try out your slider code.

Phil
__________________
Phil Malone
Garrett Engineering And Robotics Society (GEARS) founder.
http://www.GEARSinc.org

FRC1629 Mentor, FTC2818 Coach, FTC4240 Mentor, FLL NeXTGEN Mentor
Reply With Quote