View Full Version : PWM to CAN switch
3044smike
24-01-2013, 21:25
does anyone know how to do this via programming (perferably in java), my team has been having some problems.:confused:
CosmicCricket
26-01-2013, 17:19
Programming-side, working with CAN should not be too different. Make sure you are declaring your jaguars as CANJaguars, and make sure your ID numbers match up with those in your code.
That depends on what mode you want the Jaguar be in. If you are doing default mode, then it is pretty simple. If, however, you are doing any of the close-loop modes, you need to call different functions to initialize the Jaguar correctly. For example:
m_Motor1(CANID_MOTOR1_JAG, CANJaguar::kSpeed);
...
m_Motor1.SetSpeedReference(CANJaguar::kSpeedRef_Qu adEncoder);
m_Motor1.ConfigNeutralMode(CANJaguar::kNeutralMode _Coast);
m_Motor1.ConfigEncoderCodesPerRev(SHOOTER_ENCODER_ PPR);
...
vBulletin® v3.6.4, Copyright ©2000-2017, Jelsoft Enterprises Ltd.