Go to Post So, in the good old FIRST spirit, let's all start brainstorming and sharing ideas, ok? :D - LauraN [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 13-06-2010, 17:05
Tanner's Avatar
Tanner Tanner is offline
Registered User
FRC #1261 (Roblions)
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: Suwanee, GA
Posts: 311
Tanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to behold
Robot Crash

Hi all,

Working on alternate ideas while doing the whole reprogramming the robot in C++.

The robot works fine until I press the kick/fire button, upon which the cRIO "crashes". Nothing happens, DS says "Watchdog Not Fed". Using NetConsole, I could see that the cRIO clearly crashed, but now it's not saying anything for some reason.

I reimaged the cRIO to see if that would fix it, but nope. Though it now says the evil errors:
Code:
data access
Exception current instruction address: 0x0215bf40
Machine Status Register:  0x0000b02
Data Access Register: 0x05000060
Condition Register: 0x42000242
Data storage interrupt Register: 0x40000000
Task: 0xe63170 "FRC_RobotTask"
0xe63170 (FRC_RobotTask): task 0xe96170 has had a failure and has been stopped.
0xe63170 (FRC_RobotTask): fatal kernel task-level exception!
If I comment out line #71 in Kicker.cpp and then push the fire/arm button, the robot stops doing what it does, the DS indicates "Watchdog Not Fed" and nothing else is printed from NetConsole (not even disabled printf's).

I want to say it has something to do with the rollerEncoder because I'm not getting any data from it. Dad hasn't hooked up the scope yet to tell for sure though.

If you want to look at all the code, look here:
http://github.com/Tanner/Team-1261--.../rollerEncoder

Thoughts?

-Tanner
Reply With Quote
  #2   Spotlight this post!  
Unread 13-06-2010, 18:08
Radical Pi Radical Pi is offline
Putting the Jumper in the Bumper
AKA: Ian Thompson
FRC #0639 (Code Red Robotics)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2010
Location: New York
Posts: 655
Radical Pi has a spectacular aura aboutRadical Pi has a spectacular aura aboutRadical Pi has a spectacular aura about
Re: Robot Crash

Can you put printfs every few lines to narrow down the location of the crash?

Oh and we have dead encoders on our bot and nothing went wrong when we tried to use them. Unless you're encoders are somehow causing NULLs, you should be fine

Also, when looking at your code, I noticed that you call Kicker::Act in autonomous, which looks at joystick buttons. The DS will send whatever data was on the DS at the beginning of Autonomous, so if one of the control buttons are pressed when auton enables your kicker code will follow it
__________________

"To have no errors would be life without meaning. No strugle, no joy"
"A network is only as strong as it's weakest linksys"
Reply With Quote
  #3   Spotlight this post!  
Unread 13-06-2010, 18:49
Tanner's Avatar
Tanner Tanner is offline
Registered User
FRC #1261 (Roblions)
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: Suwanee, GA
Posts: 311
Tanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to behold
Re: Robot Crash

Quote:
Originally Posted by Radical Pi View Post
Can you put printfs every few lines to narrow down the location of the crash?
I can do that tomorrow afternoon and get results back to you then.

Quote:
Originally Posted by Radical Pi View Post
Oh and we have dead encoders on our bot and nothing went wrong when we tried to use them. Unless you're encoders are somehow causing NULLs, you should be fine
Ah, that's good to know.

Quote:
Originally Posted by Radical Pi View Post
Also, when looking at your code, I noticed that you call Kicker::Act in autonomous, which looks at joystick buttons. The DS will send whatever data was on the DS at the beginning of Autonomous, so if one of the control buttons are pressed when auton enables your kicker code will follow it
All though that should (hopefully) never happen, I should fix that. Thanks for noticing.

-Tanner
Reply With Quote
  #4   Spotlight this post!  
Unread 13-06-2010, 20:09
Pat Fairbank's Avatar
Pat Fairbank Pat Fairbank is offline
Circuit Breaker
FRC #0254 (The Cheesy Poofs)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2001
Location: San Jose, CA
Posts: 2,132
Pat Fairbank has a reputation beyond reputePat Fairbank has a reputation beyond reputePat Fairbank has a reputation beyond reputePat Fairbank has a reputation beyond reputePat Fairbank has a reputation beyond reputePat Fairbank has a reputation beyond reputePat Fairbank has a reputation beyond reputePat Fairbank has a reputation beyond reputePat Fairbank has a reputation beyond reputePat Fairbank has a reputation beyond reputePat Fairbank has a reputation beyond repute
Send a message via MSN to Pat Fairbank
Re: Robot Crash

In my experience, the most common source of those symptoms (crash, "Watchdog Not Fed" message) is when your code tries to dereference a null pointer. I'd suggest doing a quick check to make sure you're creating all the objects you are using.
__________________
Patrick Fairbank
Team 254 | Mentor (2012-)
Team 1503 | Mentor (2007-2011)
Team 296 | Alumnus (2001-2004) | Mentor (2005-2006)

patfairbank.com
Reply With Quote
  #5   Spotlight this post!  
Unread 13-06-2010, 21:11
biojae's Avatar
biojae biojae is offline
Likes Omni drives :)
AKA: Justin Stocking
FTC #5011 (BOT SQUAD) && FTC#72(Garage bots)&& FRC#0399 (Eagle Robotics)
Team Role: College Student
 
Join Date: Oct 2008
Rookie Year: 2008
Location: Lancaster
Posts: 276
biojae is a jewel in the roughbiojae is a jewel in the roughbiojae is a jewel in the rough
Re: Robot Crash

Just quickly looking through your code I notice that you never initialize variable kickerSwitch

That would be a null pointer at at line 94 / 95 (The number spacing is off a lot, I can't tell)
__________________
FTC Team 72 - No site
FRC Team 399 - http://www.team399.org
2010 Rockwell Collins Innovation in Control Award - (Use of the CAN bus, among other reasons) Phoenix, Arizona!

Last edited by biojae : 13-06-2010 at 21:36.
Reply With Quote
  #6   Spotlight this post!  
Unread 14-06-2010, 11:42
Tanner's Avatar
Tanner Tanner is offline
Registered User
FRC #1261 (Roblions)
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: Suwanee, GA
Posts: 311
Tanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to behold
Re: Robot Crash

Quote:
Originally Posted by biojae View Post
Just quickly looking through your code I notice that you never initialize variable kickerSwitch

That would be a null pointer at at line 94 / 95 (The number spacing is off a lot, I can't tell)
Hmf. I don't do I. I removed it in the last commit for some reason (grr @ last commit).

I commited it back. Will see how it all works when I get off work.

-Tanner
Reply With Quote
  #7   Spotlight this post!  
Unread 16-06-2010, 15:53
Tanner's Avatar
Tanner Tanner is offline
Registered User
FRC #1261 (Roblions)
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: Suwanee, GA
Posts: 311
Tanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to behold
Re: Robot Crash

Quote:
Originally Posted by biojae View Post
Just quickly looking through your code I notice that you never initialize variable kickerSwitch

That would be a null pointer at at line 94 / 95 (The number spacing is off a lot, I can't tell)

The variable kickerSwitch was it. Not sure why I removed it, but that was it. At least it wasn't something terribly wrong.

Thanks all!

-Tanner
Reply With Quote
Reply


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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Laptop crash mjcoss C/C++ 2 14-04-2009 12:10
HELP: Robot Crash in Autonomous Shadow503 C/C++ 6 23-03-2009 00:33
PlasmaCam Crash Course Andrew Blair Technical Discussion 0 30-12-2005 21:48
Prom Night Crash Nate Edwards General Forum 5 28-05-2005 15:15
3dsmax5 Crash? yangotang Inventor 5 09-03-2003 21:17


All times are GMT -5. The time now is 03:26.

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