Skip to content
Snippets Groups Projects
Commit 1946f043 authored by Beat Küng's avatar Beat Küng
Browse files

mc_pos_control: print active flight task for 'mc_pos_control status' cmd

parent e7e06dfe
No related branches found
No related tags found
No related merge requests found
......@@ -95,6 +95,9 @@ public:
/** @see ModuleBase::run() */
void run() override;
/** @see ModuleBase::print_status() */
int print_status() override;
private:
bool _in_smooth_takeoff = false; /**<true if takeoff ramp is applied */
......@@ -556,6 +559,17 @@ MulticopterPositionControl::set_vehicle_states(const float &vel_sp_z)
}
int
MulticopterPositionControl::print_status()
{
if (_flight_tasks.isAnyTaskActive()) {
PX4_INFO("Running, active flight task: %i", _flight_tasks.getActiveTask());
} else {
PX4_INFO("Running, no flight task active");
}
return 0;
}
void
MulticopterPositionControl::run()
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment