mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-01 21:48:28 -04:00
ArduCopter - small fixes to fix HIL compile errors
This commit is contained in:
parent
67855b207d
commit
fe336fb749
@ -335,7 +335,7 @@ static void init_ardupilot()
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
// initialise sonar
|
// initialise sonar
|
||||||
#if CONFIG_SONAR == ENABLED
|
#if HIL_MODE != HIL_MODE_ATTITUDE && CONFIG_SONAR == ENABLED
|
||||||
init_sonar();
|
init_sonar();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -31,7 +31,9 @@ static int8_t test_current(uint8_t argc, const Menu::arg *argv);
|
|||||||
static int8_t test_wp(uint8_t argc, const Menu::arg *argv);
|
static int8_t test_wp(uint8_t argc, const Menu::arg *argv);
|
||||||
static int8_t test_baro(uint8_t argc, const Menu::arg *argv);
|
static int8_t test_baro(uint8_t argc, const Menu::arg *argv);
|
||||||
static int8_t test_mag(uint8_t argc, const Menu::arg *argv);
|
static int8_t test_mag(uint8_t argc, const Menu::arg *argv);
|
||||||
|
#if HIL_MODE != HIL_MODE_ATTITUDE && CONFIG_SONAR == ENABLED
|
||||||
static int8_t test_sonar(uint8_t argc, const Menu::arg *argv);
|
static int8_t test_sonar(uint8_t argc, const Menu::arg *argv);
|
||||||
|
#endif
|
||||||
#ifdef OPTFLOW_ENABLED
|
#ifdef OPTFLOW_ENABLED
|
||||||
static int8_t test_optflow(uint8_t argc, const Menu::arg *argv);
|
static int8_t test_optflow(uint8_t argc, const Menu::arg *argv);
|
||||||
#endif
|
#endif
|
||||||
@ -84,7 +86,7 @@ const struct Menu::command test_menu_commands[] PROGMEM = {
|
|||||||
#if HIL_MODE != HIL_MODE_ATTITUDE
|
#if HIL_MODE != HIL_MODE_ATTITUDE
|
||||||
{"altitude", test_baro},
|
{"altitude", test_baro},
|
||||||
#endif
|
#endif
|
||||||
#if CONFIG_SONAR == ENABLED
|
#if HIL_MODE != HIL_MODE_ATTITUDE && CONFIG_SONAR == ENABLED
|
||||||
{"sonar", test_sonar},
|
{"sonar", test_sonar},
|
||||||
#endif
|
#endif
|
||||||
{"compass", test_mag},
|
{"compass", test_mag},
|
||||||
@ -965,7 +967,7 @@ test_mag(uint8_t argc, const Menu::arg *argv)
|
|||||||
/*
|
/*
|
||||||
test the sonar
|
test the sonar
|
||||||
*/
|
*/
|
||||||
#if CONFIG_SONAR == ENABLED
|
#if HIL_MODE != HIL_MODE_ATTITUDE && CONFIG_SONAR == ENABLED
|
||||||
static int8_t
|
static int8_t
|
||||||
test_sonar(uint8_t argc, const Menu::arg *argv)
|
test_sonar(uint8_t argc, const Menu::arg *argv)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user