ACM-HIL: fixed optflow declaration

This commit is contained in:
Andrew Tridgell 2012-10-11 11:51:15 +11:00
parent c56f3a9f8c
commit 2af5ff896d
1 changed files with 7 additions and 3 deletions

View File

@ -304,7 +304,11 @@ AP_Compass_HIL compass; // never used
AP_Baro_BMP085_HIL barometer;
AP_InertialSensor_Stub ins;
#ifdef OPTFLOW_ENABLED
AP_OpticalFlow_ADNS3080 optflow(OPTFLOW_CS_PIN);
#if CONFIG_APM_HARDWARE == APM_HARDWARE_APM2
AP_OpticalFlow_ADNS3080 optflow(&spi3_semaphore,OPTFLOW_CS_PIN);
#else
AP_OpticalFlow_ADNS3080 optflow(NULL,OPTFLOW_CS_PIN);
#endif
#endif
#ifdef DESKTOP_BUILD
#include <SITL.h>