Rover: Initialize variables

This commit is contained in:
muramura 2024-05-11 17:38:39 +09:00 committed by Randy Mackay
parent fbb785859a
commit 3f88a5e749
1 changed files with 2 additions and 4 deletions

View File

@ -10,10 +10,8 @@ void Rover::set_servos(void)
motor_test_output();
} else {
// get ground speed
float speed;
if (!g2.attitude_control.get_forward_speed(speed)) {
speed = 0.0f;
}
float speed = 0.0f;
g2.attitude_control.get_forward_speed(speed);
g2.motors.output(arming.is_armed(), speed, G_Dt);
}