Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   C/C++ (http://www.chiefdelphi.com/forums/forumdisplay.php?f=183)
-   -   Watchdog Not Fed! (http://www.chiefdelphi.com/forums/showthread.php?t=83543)

masoug 24-02-2010 13:43

Watchdog Not Fed!
 
Although this might seem like those classic "Watchdog" problems, this problem is special...

We use "Iterative Robot" system to program out robot, and we implemented things like solenoids, compressors, and camera, etc... When it got kinda complicated, the watchdog lost its appetite.

The robot boot fine, but whenever we enable it, the driver station immediately says "Watchdog Not Fed".

I don't think that the robot even initiated the Teleop Init function right... We fed the watchdog function plenty of times, but it still won't feed...:ahh:

mikets 24-02-2010 13:54

Re: Watchdog Not Fed!
 
The most typical mistake is if you have a Wait somewhere in your code that is longer than the watchdog expiration. Wait is blocking. So while you are waiting, the watchdog starves. We don't use Wait in our code at all. We wrote our own timer callback using the Notifier class. We also implemented a state machine so that we do non-blocking wait using the timer callback to advance the state machine to the next state.

masoug 24-02-2010 15:26

Re: Watchdog Not Fed!
 
We did not have any
Code:

Wait()
's either, but the thing is that the watchdog IMMEDIATELY does not get fed, so it is some problem with the initialization of our robot...

I think it might be the camera's
Code:

camera = AxisCamera::GetImage()
or something like that, OR it might be PID...

Has anyone ever have this problem before?

Radical Pi 24-02-2010 17:03

Re: Watchdog Not Fed!
 
Are you disabling the watchdog during autonomous and during the constructor? The watchdog could be expiring before the teleop function sets it up properly

mikets 24-02-2010 17:08

Re: Watchdog Not Fed!
 
I don't understand your code. Did you mean:
Code:

camera = AxisCamera::GetInstance();
or
HSLImage *image = camera.GetImage();

If it is really the first one, then it means the code failed to communicate with the camera. There are a number of reasons for that.
  • Make sure the ethernet cable is a cross over cable.
  • Make sure the camera is configured correctly with the correct IP address and acct/password
  • Although I haven't verified it myself other threads said the subnet mask of the camera should be 255.0.0.0.

mandrews281 24-02-2010 19:59

Re: Watchdog Not Fed!
 
We had a similar problem. Discovered that the accelerometer was plugged into to the duplicate I2C _OUT_ ports. The accelerator initialization in the robot constructor was simply hanging, so our robot class never made it out of its constructor. So, as soon as the robot was enabled, the watchdog went hungry because our code hadn't started feeding it yet.

I guess the lesson from that is: make sure your code is getting to where you think it is, and check everything.


All times are GMT -5. The time now is 13:46.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi