View Single Post
  #4   Spotlight this post!  
Unread 31-01-2010, 13:16
omalleyj omalleyj is offline
Registered User
AKA: Jim O'Malley
FRC #1279 (Cold Fusion)
Team Role: Mentor
 
Join Date: Jan 2008
Rookie Year: 2008
Location: New Jersey
Posts: 132
omalleyj is a splendid one to beholdomalleyj is a splendid one to beholdomalleyj is a splendid one to beholdomalleyj is a splendid one to beholdomalleyj is a splendid one to beholdomalleyj is a splendid one to beholdomalleyj is a splendid one to beholdomalleyj is a splendid one to behold
Re: Feeding the Watchdog

The example basicxman gave is correct. If it isn't working for you you should look carefully at your code for these things:
any init (such as the camera mentioned) that might take longer than the expiration
are you feeding it within all loops that might run longer than the expiration
do you ever pend on input that may not come fast enough
Timer.delay calls that may total too much time

Examine every loop or method call to make sure. Put printlns in that display the time in potential problem areas, some things, like processing large images take a lot longer than you might think. Lots of printlns are expensive. DriverStationLCD prints take a while. etc.

If you post your code we could look for potential problem areas

Good luck!
Reply With Quote