ArduPlane: rename OpticalFlow class to AP_OpticalFlow

Brings us in-line with other classes in ArduPilot.

Removes ambiguity with AP_HAL::OpticalFlow which can cause compilation errors as we start to make code more portable across targets
This commit is contained in:
Peter Barker 2022-08-15 11:31:14 +10:00 committed by Peter Barker
parent 78c742978e
commit 0d19d7646f
4 changed files with 4 additions and 4 deletions

View File

@ -83,7 +83,7 @@ const AP_Scheduler::Task Plane::scheduler_tasks[] = {
SCHED_TASK_CLASS(AP_ICEngine, &plane.g2.ice_control, update, 10, 100, 81),
#endif
#if AP_OPTICALFLOW_ENABLED
SCHED_TASK_CLASS(OpticalFlow, &plane.optflow, update, 50, 50, 87),
SCHED_TASK_CLASS(AP_OpticalFlow, &plane.optflow, update, 50, 50, 87),
#endif
SCHED_TASK(one_second_loop, 1, 400, 90),
SCHED_TASK(three_hz_loop, 3, 75, 93),

View File

@ -99,7 +99,7 @@ void GCS_Plane::update_vehicle_sensor_status_flags(void)
}
#if AP_OPTICALFLOW_ENABLED
const OpticalFlow *optflow = AP::opticalflow();
const AP_OpticalFlow *optflow = AP::opticalflow();
if (optflow && optflow->enabled()) {
control_sensors_present |= MAV_SYS_STATUS_SENSOR_OPTICAL_FLOW;
control_sensors_enabled |= MAV_SYS_STATUS_SENSOR_OPTICAL_FLOW;

View File

@ -939,7 +939,7 @@ const AP_Param::Info Plane::var_info[] = {
#if AP_OPTICALFLOW_ENABLED
// @Group: FLOW
// @Path: ../libraries/AP_OpticalFlow/AP_OpticalFlow.cpp
GOBJECT(optflow, "FLOW", OpticalFlow),
GOBJECT(optflow, "FLOW", AP_OpticalFlow),
#endif
// @Group: MIS_

View File

@ -240,7 +240,7 @@ private:
#if AP_OPTICALFLOW_ENABLED
// Optical flow sensor
OpticalFlow optflow;
AP_OpticalFlow optflow;
#endif
// Rally Ponints