wind_estimator add param to enable and start

This commit is contained in:
Daniel Agar
2018-08-01 14:59:02 -04:00
committed by Lorenz Meier
parent 6f204c4913
commit ad41744670
3 changed files with 22 additions and 1 deletions

View File

@@ -489,6 +489,11 @@ else
#
navigator start
#
# Start the standalone wind estimator.
#
wind_estimator start
#
# Start a thermal calibration if required.
#

View File

@@ -330,5 +330,12 @@ extern "C" __EXPORT int wind_estimator_main(int argc, char *argv[]);
int
wind_estimator_main(int argc, char *argv[])
{
return WindEstimatorModule::main(argc, argv);
int32_t wind_estimator_enabled = 0;
param_get(param_find("WEST_EN"), &wind_estimator_enabled);
if (wind_estimator_enabled == 1) {
return WindEstimatorModule::main(argc, argv);
}
return PX4_OK;
}

View File

@@ -1,3 +1,12 @@
/**
* Enable Wind estimator
*
* @boolean
* @reboot_required true
* @group Wind Estimator
*/
PARAM_DEFINE_INT32(WEST_EN, 0);
/**
* Wind estimator wind process noise.
*