Go to Post Honesty and integrity should always be taken seriously. It's the lubrication that makes the world go round. - rsisk [more]
Home
Go Back   Chief Delphi > Technical > Technical Discussion
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 16-02-2013, 20:26
dieDoktor dieDoktor is offline
Registered User
AKA: Kipling Cohen
FRC #4118 (Roaring Riptides)
Team Role: Mechanical
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Gainesville
Posts: 32
dieDoktor is an unknown quantity at this point
Watchdog not being fed

After resetting our D-link, our Driver Station is telling us that the Watchdog isn't being fed. We have checked through our code, but everything checks out. Prior to reset, we had no Watchdog issues. If anyone can help please do.
  #2   Spotlight this post!  
Unread 16-02-2013, 21:28
joelg236 joelg236 is offline
4334 Retired Mentor & Alumni
AKA: Joel Gallant
no team
Team Role: Mentor
 
Join Date: Dec 2011
Rookie Year: 2012
Location: Calgary
Posts: 733
joelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond repute
Re: Watchdog not being fed

The bridge couldn't possibly be a problem with the watchdog, unless there is a considerable amount of lag. I would guess it's something in your code that enters a loop without updating your driving values.
__________________
All opinions are my own.
  #3   Spotlight this post!  
Unread 16-02-2013, 22:08
dieDoktor dieDoktor is offline
Registered User
AKA: Kipling Cohen
FRC #4118 (Roaring Riptides)
Team Role: Mechanical
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Gainesville
Posts: 32
dieDoktor is an unknown quantity at this point
Re: Watchdog not being fed

It might be the code. However, we made no changes to anything BUT resetting the bridge...
  #4   Spotlight this post!  
Unread 16-02-2013, 22:11
joelg236 joelg236 is offline
4334 Retired Mentor & Alumni
AKA: Joel Gallant
no team
Team Role: Mentor
 
Join Date: Dec 2011
Rookie Year: 2012
Location: Calgary
Posts: 733
joelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond repute
Re: Watchdog not being fed

Code on a robot won't run the same way every time. It's certainly possible that some part of your code has never been run until now and it is just now starting to give you errors. My advice is to redeploy and try logging suspicious parts of your code which could end up in a loop.
__________________
All opinions are my own.
  #5   Spotlight this post!  
Unread 16-02-2013, 22:22
OWilliamson's Avatar
OWilliamson OWilliamson is offline
Registered User
FRC #2594 (NASKCO)
Team Role: Mentor
 
Join Date: Feb 2012
Rookie Year: 2012
Location: Idaho
Posts: 115
OWilliamson is a glorious beacon of lightOWilliamson is a glorious beacon of lightOWilliamson is a glorious beacon of lightOWilliamson is a glorious beacon of lightOWilliamson is a glorious beacon of light
Re: Watchdog not being fed

Are you programming in Labview? If so make sure that you have the Feed Watchdog VI included in your code.
  #6   Spotlight this post!  
Unread 16-02-2013, 22:32
dieDoktor dieDoktor is offline
Registered User
AKA: Kipling Cohen
FRC #4118 (Roaring Riptides)
Team Role: Mechanical
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Gainesville
Posts: 32
dieDoktor is an unknown quantity at this point
Re: Watchdog not being fed

I will certainly try to redeploy, and find possible errors. And no, we are not using LabView, we are using C++.
  #7   Spotlight this post!  
Unread 16-02-2013, 23:08
Kevin Sevcik's Avatar
Kevin Sevcik Kevin Sevcik is offline
(Insert witty comment here)
FRC #0057 (The Leopards)
Team Role: Mentor
 
Join Date: Jun 2001
Rookie Year: 1998
Location: Houston, Texas
Posts: 3,658
Kevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond repute
Send a message via AIM to Kevin Sevcik Send a message via Yahoo to Kevin Sevcik
Re: Watchdog not being fed

Is this a Watchdog error, or is this the "MotorSafetyHelper: Motor has not been updated often enough" error?

MotorSafetyHelper errors can be pretty common. They occur if you don't constant send new control values to your motors. If you're convinced your code is alright, you can use the SetSafetyEnabled(false) method to disable the MotorSafetyHelper for a particular motor or motors.
__________________
The difficult we do today; the impossible we do tomorrow. Miracles by appointment only.

Lone Star Regional Troubleshooter
  #8   Spotlight this post!  
Unread 17-02-2013, 11:34
dieDoktor dieDoktor is offline
Registered User
AKA: Kipling Cohen
FRC #4118 (Roaring Riptides)
Team Role: Mechanical
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Gainesville
Posts: 32
dieDoktor is an unknown quantity at this point
Re: Watchdog not being fed

Here is the code we are using, its in C++. Please check it and tell us if there is anything wrong with it. We still haven't found anything in the code, hopefully one of you can.

Quote:
Is this a Watchdog error, or is this the "MotorSafetyHelper: Motor has not been updated often enough" error?

MotorSafetyHelper errors can be pretty common. They occur if you don't constant send new control values to your motors. If you're convinced your code is alright, you can use the SetSafetyEnabled(false) method to disable the MotorSafetyHelper for a particular motor or motors.
Kevin, it is a Watchdog error.
Attached Files
File Type: txt 130217.txt (10.5 KB, 18 views)
  #9   Spotlight this post!  
Unread 17-02-2013, 18:07
rainbowdash's Avatar
rainbowdash rainbowdash is offline
Director of Programming
AKA: Souvixada S.
FRC #1671 (Buchanan Bird Brains)
Team Role: Programmer
 
Join Date: Apr 2012
Rookie Year: 2005
Location: Clovis, CA
Posts: 28
rainbowdash is an unknown quantity at this point
Re: Watchdog not being fed

If it's not fed, you have to kill it and bury its body in the backyard.
- WPILibrary
__________________
"Why change the code? Just reverse the polarity."
  #10   Spotlight this post!  
Unread 17-02-2013, 18:13
RufflesRidge RufflesRidge is offline
Registered User
no team
 
Join Date: Jan 2012
Location: USA
Posts: 989
RufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant future
Re: Watchdog not being fed

Quote:
Originally Posted by dieDoktor View Post
Kevin, it is a Watchdog error.
The code you posted isn't using the Watchdog, can you post exactly the error you are seeing and where on the DS you are seeing it?

Also try installing the Driver Station Update 3 from here: http://joule.ni.com/nidu/cds/view/p/id/2263
Then you can look at your Trip Time and Lost Packets in green and blue respectively on the Charts tab of the DS.

Last edited by RufflesRidge : 17-02-2013 at 18:15.
  #11   Spotlight this post!  
Unread 17-02-2013, 19:53
Kevin Sevcik's Avatar
Kevin Sevcik Kevin Sevcik is offline
(Insert witty comment here)
FRC #0057 (The Leopards)
Team Role: Mentor
 
Join Date: Jun 2001
Rookie Year: 1998
Location: Houston, Texas
Posts: 3,658
Kevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond repute
Send a message via AIM to Kevin Sevcik Send a message via Yahoo to Kevin Sevcik
Re: Watchdog not being fed

I agree that you don't seem to be using the watchdog anywhere. While there's a Watchdog that's a member of the SimpleRobot class you derive from, the SimpleRobot constructor disables it by default. You have to actively enable it for it to do something. If you're really sure that's the problem, you can call GetWatchdog to get it, or simply access it directly at m_watchdog. If you put m_watchdog.SetEnabled(false) in your constructor, that'll guarantee it's disabled.

On the other hand, your buttons for driving the robot forward,backward, etc. for a fixed amount of time will definitely cause problems and MotorSafetyHelper errors. Putting a Wait() in your OperatorControl while loop is a really bad idea, because it stops everything else and waits. It's also not likely to do what you want.

If you have MotorSafety enabled, then your robot drive is expecting a new TankDrive or ArcadeDrive or somethingDrive command every 0.1 seconds. If you don't update it, MotorSafety will disable that motor until you command it again. So you give it that TankDrive(-.3,-.3) command, then wait 2 seconds with a command, which kills your motor, then you command it (0,0).

On the other hand, if you have MotorSafety disable, everything else keeps doing what it was doing just before you hit that button. If your armmotor was going down and you hit the backup button, that armmotor is going to keep going down for two seconds, limit switch or no.

So mostly, you shouldn't be using a Wait() in your OperatorControl loop.
__________________
The difficult we do today; the impossible we do tomorrow. Miracles by appointment only.

Lone Star Regional Troubleshooter
  #12   Spotlight this post!  
Unread 18-02-2013, 17:57
rich2202 rich2202 is offline
Registered User
FRC #2202 (BEAST Robotics)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2012
Location: Wisconsin
Posts: 1,188
rich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond repute
Re: Watchdog not being fed

What is the alternative to Wait? That is what we have been using to release CPU time to other threads. So far, we have not had a problem. Although, we use wait only at the bottom of the code, not inside the code. We use timers for that.

Last edited by rich2202 : 18-02-2013 at 17:59.
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 12:53.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


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