View Single Post
  #11   Spotlight this post!  
Unread 04-02-2014, 20:21
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: Coding in a sequence.

Quote:
Originally Posted by matthewdenny View Post
Does the periodic in java need to execute in 20ms. If so is there a Periodic tasks in Java?
Yes, the telopPeriodic method in java in the IterativeRobot template must execute within 20ms.

There are a few things you can do to work around this.
1) Use the Simple Robot template
2) Use a state machine.
2a) Switch to the command framework (which uses a state machine). See http://wpilib.screenstepslive.com/s/...nomous-program
3) Run the code in a new Task. This would be equivalent to Periodic Tasks in LabVIEW.
Reply With Quote