 }
 
 void loop() {
-  // Check bumper thresholds to stop robot
-  bumper_left = analogRead(BUMPER_LEFT_PIN);
-  bumper_right = analogRead(BUMPER_RIGHT_PIN);
-  bumper_stop = bumper_left < 450 || bumper_right < 450;
-  if (bumper_stop) {
-    motor_left_speed = 0;
-    motor_right_speed = 0;
-  }
 
   ros::Time current_time = ros_nh.now();
 

const double WHEEL_RADIUS(0.127);  // in meters
const double MAX_SPEED(4.71);      // in meters/second

// Bumper sensors
bool bumper_stop = false; // Set to true if bumpers indicate robot should stop
unsigned int bumper_left;
unsigned int bumper_right;

// Motor encoders
Encoder encoder_left(ENCODER_LEFT_PIN_1, ENCODER_LEFT_PIN_2);
Encoder encoder_right(ENCODER_RIGHT_PIN_1, ENCODER_RIGHT_PIN_2);

 */
void cmdVelCallback(const geometry_msgs::Twist& cmd_vel_msg) {
  last_cmd_vel_time = ros_nh.now();
  
  // Calculate wheel linear velocity
  double vl = cmd_vel_msg.linear.x - (cmd_vel_msg.angular.z * TRACK_RADIUS);
