Thread: debugger help
View Single Post
  #2   Spotlight this post!  
Unread 24-03-2009, 22:38
virtuald's Avatar
virtuald virtuald is offline
RobotPy Guy
AKA: Dustin Spicuzza
FRC #1418 (), FRC #1973, FRC #4796, FRC #6367 ()
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2003
Location: Boston, MA
Posts: 1,050
virtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant future
Re: debugger help

I have found that generally when it does that, it means that there is a bad pointer somewhere.

Did you specify the slot of the accelerometer? If you specify the wrong one, or really if specify *something* wrong when creating it then you will get bad results, because the internal functions reference an object and if it never gets created... then invalid memory references happen. You might want to try launching a target console and see if there are error messages there, since the WPILib does not break into the debugger when asserts occur (which is incredibly annoying, actually).

You could also try running the code in my test harness (http://www.chiefdelphi.com/forums/sh...d.php?t=75811), though I don't think it supports accelerometers -- but many other problems (like NULL pointers and such) its pretty good at catching.
__________________
Maintainer of RobotPy - Python for FRC
Creator of pyfrc (Robot Simulator + utilities for Python) and pynetworktables/pynetworktables2js (NetworkTables for Python & Javascript)

2017 Season: Teams #1973, #4796, #6369
Team #1418 (remote mentor): Newton Quarterfinalists, 2016 Chesapeake District Champion, 2x Innovation in Control award, 2x district event winner
Team #1418: 2015 DC Regional Innovation In Control Award, #2 seed; 2014 VA Industrial Design Award; 2014 Finalists in DC & VA
Team #2423: 2012 & 2013 Boston Regional Innovation in Control Award


Resources: FIRSTWiki (relaunched!) | My Software Stuff
Reply With Quote