Fixed periodic voltage status message

Previously, the voltage was requested as a percentage and decoded as
a number of volts, which resulted in values being scaled wrong. The
correct message is requested now.

Change-Id: I5e81c7a4a2e2698f2e8a84ba747217e0e14f7676
This commit is contained in:
thomasclark
2014-07-02 12:14:49 -04:00
parent ff8016c088
commit b97d2eb0c3
2 changed files with 2 additions and 2 deletions

View File

@@ -504,7 +504,7 @@ void CANJaguar::setupPeriodicStatus() {
// temperature.
static const uint8_t kMessage0Data[] = {
LM_PSTAT_VOLTBUS_B0, LM_PSTAT_VOLTBUS_B1,
LM_PSTAT_VOLTOUT_B0, LM_PSTAT_VOLTOUT_B1,
LM_PSTAT_VOUT_B0, LM_PSTAT_VOUT_B1,
LM_PSTAT_CURRENT_B0, LM_PSTAT_CURRENT_B1,
LM_PSTAT_TEMP_B0, LM_PSTAT_TEMP_B1
};

View File

@@ -1749,7 +1749,7 @@ public class CANJaguar implements MotorSafety, PIDOutput, SpeedController, LiveW
// temperature.
final byte[] kMessage0Data = new byte[] {
CANJNI.LM_PSTAT_VOLTBUS_B0, CANJNI.LM_PSTAT_VOLTBUS_B1,
CANJNI.LM_PSTAT_VOLTOUT_B0, CANJNI.LM_PSTAT_VOLTOUT_B1,
CANJNI.LM_PSTAT_VOUT_B0, CANJNI.LM_PSTAT_VOUT_B1,
CANJNI.LM_PSTAT_CURRENT_B0, CANJNI.LM_PSTAT_CURRENT_B1,
CANJNI.LM_PSTAT_TEMP_B0, CANJNI.LM_PSTAT_TEMP_B1
};