View Single Post
  #1   Spotlight this post!  
Unread 26-01-2010, 00:04
mikets's Avatar
mikets mikets is offline
Software Engineer
FRC #0492 (Titan Robotics)
Team Role: Mentor
 
Join Date: Jan 2010
Rookie Year: 2008
Location: Bellevue, WA
Posts: 667
mikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of light
Help interpreting load time error

I have started to customize the robot template for our team. I have sub-classed the SimpleRobot class to add some of our custom functions. Everything compiled and the code was downloaded into the cRIO fine. But when I rebooted the robot, at the end of the boot, it gave me the following output and I have no idea why TrcRobot is undefined. TrcRobot is my subclass of SimpleRobot. Simplified code construct is shown below. I am expecting to see compiler errors if I made mistakes. But the compiler didn't complain and instead I got load time error of undefined symbol. Can somebody tell me what it means? Thanks.
Code:
FRC_NetworkCommunication was compiled from SVN revision 2064
FPGA Hardware GUID: 0xAD9A5591CC64E4DF756D77D1B57A549E
FPGA Software GUID: 0xAD9A5591CC64E4DF756D77D1B57A549E
FPGA Hardware Version: 2010
FPGA Software Version: 2010
FPGA Hardware Revision: 1.3.0
FPGA Software Revision: 1.3.0
* Loading StartupDlls: FRC_UserProgram
Warning: module 0x134c5d0 (FRC_UserProgram.out) holds reference to undefined symbol _ZTV8TrcRobot.
Warning: module 0x134c5d0 (FRC_UserProgram.out) holds reference to undefined symbol _ZTI8TrcRobot.
(unloading partially loaded module FRC_UserProgram.out)
...FRC_UserProgram failed to load.
Code:
class TrcRobot: public SimpleRobot
{
public:
    virtual void SomeCustomizedMethods();
    void Autonomous()
    {
        //Autonomous main loop.
        SomeCustomizedMethods();
    }
    void OperatorControl()
    {
        //Operator control main loop.
        SomeCustomizedMethods();
    }
};

class MyRobot: public TrcRobot
{
    MyRobot()
    {
        //Instantiate other objects.
    }
    ~MyRobot()
    {
        //Destroy objects created in constructor.
    }
    void SomeCustomizedMethods()
    {
        //Autonomous or Operator Control tasks.
    }
}
START_ROBOT_CLASS(MyRobot);
Reply With Quote