diff --git a/ArduPlane/quadplane.cpp b/ArduPlane/quadplane.cpp index da6ccab4f9..3a23caac8a 100644 --- a/ArduPlane/quadplane.cpp +++ b/ArduPlane/quadplane.cpp @@ -1678,7 +1678,7 @@ int8_t QuadPlane::forward_throttle_pct(void) return 0; } - float deltat = (AP_HAL::millis() - vel_forward.lastt_ms) * 0.001f; + float deltat = (AP_HAL::millis() - vel_forward.last_ms) * 0.001f; if (deltat > 1 || deltat < 0) { vel_forward.integrator = 0; deltat = 0.1; @@ -1687,7 +1687,7 @@ int8_t QuadPlane::forward_throttle_pct(void) // run at 10Hz return vel_forward.last_pct; } - vel_forward.lastt_ms = AP_HAL::millis(); + vel_forward.last_ms = AP_HAL::millis(); // work out the desired speed in forward direction const Vector3f &desired_velocity_cms = pos_control->get_desired_velocity(); diff --git a/ArduPlane/quadplane.h b/ArduPlane/quadplane.h index 379bbf6b18..1af4425f39 100644 --- a/ArduPlane/quadplane.h +++ b/ArduPlane/quadplane.h @@ -227,7 +227,7 @@ private: struct { AP_Float gain; float integrator; - uint32_t lastt_ms; + uint32_t last_ms; int8_t last_pct; } vel_forward;