You need to find out how the Jaguars are connected to the cRIO. There are two ways. You are either connecting the Jaguars to the PWM channels or you are connecting them to a CAN bus by the RJ-12 cables. The way they are connected to the cRIO affects how they are programmed. If you are using CAN bus, you need to declare CANJaguar objects. If you are using PWM, then you declare Jaguar objects. What slot in the cRIO is your digital module plugged into? If your robot is 2-motor drive and you have an 8-slot cRIO with the digital module on slot 4 and connect them through PWM, then you need to declare the Jaguars like this:
Code:
class MyRobot: public SimpleRobot
{
RobotDrive drive;
MyRobot():
drive(PWM_CHANNEL_LEFTJAG, PWM_CHANNEL_RIGHTJAG)
{
// You may want to flip the booleans if the motors running the wrong way.
drive.SetInvertedMotor(kRearLeftMotor, true);
drive.SetInvertedMotor(kRearRightMotor, false);
...
...
}
}