View Single Post
  #5   Spotlight this post!  
Unread 24-01-2012, 20:18
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,751
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: Code in Periodic Tasks working with teleop

Doh. Joe gets the prize. Make sure your code doesn't run just once by putting it in a loop.

Keep the code in periodic tasks, but make sure that the joystick code is checked more than once. Put it in a loop and put a delay of 100ms or so to make sure the code doesn't run faster than needed.

You place a breakpoint in the code by opening the diagram, right clicking and choosing to probe or breakpoint. As you mention, when if the robot stops responding, it will shutdown the I/O, but you can still debug the code. Generally, whenever debugging, start with the robot on blocks, and don't remove it until you know how it will respond.

Greg McKaskle
Reply With Quote