View Single Post
  #2   Spotlight this post!  
Unread 12-03-2014, 14:08
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,572
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: Grabbing subsystem data to use in another subsystem in Command Based

Quote:
Originally Posted by kylelanman View Post
All commands inherit CommandBase and CommandBase contains static instances of each subsystem.
Quote:
Originally Posted by DjScribbles View Post
The Robot class has static instances of all subsystems, so you can access them from anywhere that includes Robot.h (just as is done in commands).
In case anyone is confused, both Kyle and Joe are correct, depending on how you started your project. Currently, if you build your build your project with the Windriver plugins, you get a CommandBase that contains all subsystems. If you use RobotBuilder, the Robot class contains all subsystems.
Reply With Quote