FlightTasks: initialize task state based on subscriptions after the SubscriptionArray was initialized

This commit is contained in:
Matthias Grob
2018-04-05 07:30:12 +02:00
committed by Beat Küng
parent b0fdbf5136
commit 071b09c65d
6 changed files with 36 additions and 9 deletions
+7
View File
@@ -13,6 +13,13 @@ bool FlightTask::initializeSubscriptions(SubscriptionArray &subscription_array)
return true;
}
int FlightTask::activate()
{
_time_stamp_activate = hrt_absolute_time();
update(); /* to get subscriptions and evaluate them */
return 0;
}
int FlightTask::update()
{
_time_stamp_current = hrt_absolute_time();