Go to Post I have a pocket full of Gracious Professionalism! How about you? - Schnabel [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 12-02-2014, 20:50
peronis peronis is offline
Team Leader
FRC #3950 (RoboGym)
Team Role: Mentor
 
Join Date: Sep 2011
Rookie Year: 2012
Location: Glen Head NY
Posts: 43
peronis is on a distinguished road
C++ Code is not detected by the robot

So this problem may sound a little strange, and I'm really not sure what the issue could be at this point, so I'll try to explain in the best way I can and hope that someone here can help us fix the problem. Simply put, when the code is deployed to the cRIO and then rebooted, the driver station fails to recognize any code on the robot. I know you're all going to say to try reverting back to an older version of the to ensure it's not a hardware issue, so let me put you at ease by saying I have already tried. Older versions of the code work. Specifically, the robot detects code on some older versions, but after someone people cleaned the wiring, none of the motors seem to work. I suspect this is unrelated, as we had the same issue before we cleaned the wiring when we tried implementing PID code. I created a new workspace and began implementing subsystems piece by piece until the issue appeared again. Our drive system works, our subsystem to get the ball works, but once the PID code is used, the problem reappears. However, if I work backwards from the completed code, and simply remove the PID subsystem, the issue remains. The driver station indicates no robot code, and it therefore cannot be used. I intend to post some of the code in question here soon. Particularly the PID code, which I have a poor understanding of to begin with.

Note that the code is command based, and the prime issue is almost certainly in the code itself.

Any help here would be greatly appreciated.
--Tim the Enchanter, 3950 (aka TK3950)
Reply With Quote
  #2   Spotlight this post!  
Unread 12-02-2014, 21:00
Joe Ross's Avatar Unsung FIRST Hero
Joe Ross Joe Ross is offline
Registered User
FRC #0330 (Beachbots)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1997
Location: Los Angeles, CA
Posts: 8,557
Joe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond repute
Re: C++ Code is not detected by the robot

The code is probably crashing. Use netconsole to see the output when it crashes, or run in the debugger.
Reply With Quote
  #3   Spotlight this post!  
Unread 14-02-2014, 07:48
kylelanman's Avatar
kylelanman kylelanman is offline
Programming Mentor
AKA: Kyle
FRC #2481 (Roboteers)
Team Role: Mentor
 
Join Date: Feb 2008
Rookie Year: 2007
Location: Tremont Il
Posts: 186
kylelanman is a name known to allkylelanman is a name known to allkylelanman is a name known to allkylelanman is a name known to allkylelanman is a name known to allkylelanman is a name known to all
Re: C++ Code is not detected by the robot

Just wanted to share the most common things our team struggles with resulting in no code.
  • Not allocating an object instance before calling methods on it.
  • Using the same DIO, PWM, Analog In, etc more than once.
  • Not implementing a pure virtual method in a command/subsystem.

As Joe indicated you will need to watch NetConsole on boot up of the robot to determine the particular cause of your crash.
__________________
"May the coms be with you"

Is this a "programming error" or a "programmer error"?

Reply With Quote
  #4   Spotlight this post!  
Unread 22-02-2014, 09:51
taichichuan's Avatar
taichichuan taichichuan is offline
Software Mentor
AKA: Mike Anderson
FRC #0116 (Epsilon Delta)
Team Role: Mentor
 
Join Date: Feb 2010
Rookie Year: 2010
Location: Herndon, VA
Posts: 328
taichichuan has much to be proud oftaichichuan has much to be proud oftaichichuan has much to be proud oftaichichuan has much to be proud oftaichichuan has much to be proud oftaichichuan has much to be proud oftaichichuan has much to be proud oftaichichuan has much to be proud oftaichichuan has much to be proud oftaichichuan has much to be proud of
Send a message via AIM to taichichuan
Re: C++ Code is not detected by the robot

Watch the robot start up in the netconsole. You may be seeing the infamous 24-bit relocation problem. If you see something about 24-bit relocation in the netconsole, recompile your code with the -mlong-call compiler flag (in the build properties of the project) and try to redeploy.

Good luck,

Mike
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


All times are GMT -5. The time now is 02:44.

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