16#include "global_enums.h"
26#define CURRENT_SCALE 100
27#define VOLTAGE_SCALE 100
28#define VELOCITY_SCALE 100
32#define ACCERLATION_FORCE 1
33#define CRUISE_THROTTLE_THRESHOLD 0
34#define TORQUE_CONTROL_VEL 20000
37#define WHEEL_DIAMETER 0.57147
38#define VEL_TO_RPM_RATIO (60 / (2 * MATH_PI) * WHEEL_DIAMETER)
39#define CONVERT_VELOCITY_TO_KPH 13234
43#define DRIVER_CONTROL_BASE 0x500
44#define MOTOR_CONTROLLER_BASE_L 0x400
45#define MOTOR_CONTROLLER_BASE_R 0x80
47typedef enum MotorControllerMessageIds {
64} MotorControllerMessageIds;
66void init_motor_controller_can();
67float prv_get_float(uint32_t u);
68float clamp_float(
float value);
69void prv_update_target_current_velocity();