Copter: move sprayer update function into scheduler table

This commit is contained in:
Peter Barker 2018-06-08 19:24:00 +10:00 committed by Randy Mackay
parent ca7842afac
commit 7a065db2bb
1 changed files with 3 additions and 3 deletions

View File

@ -114,6 +114,9 @@ const AP_Scheduler::Task Copter::scheduler_tasks[] = {
SCHED_TASK(update_throttle_hover,100, 90),
#if MODE_SMARTRTL_ENABLED == ENABLED
SCHED_TASK_CLASS(Copter::ModeSmartRTL, &copter.mode_smartrtl, save_position, 3, 100),
#endif
#if SPRAYER_ENABLED == ENABLED
SCHED_TASK_CLASS(AC_Sprayer, &copter.sprayer, update, 3, 90),
#endif
SCHED_TASK(three_hz_loop, 3, 75),
SCHED_TASK_CLASS(AP_ServoRelayEvents, &copter.ServoRelayEvents, update_events, 50, 75),
@ -411,9 +414,6 @@ void Copter::three_hz_loop()
fence_check();
#endif // AC_FENCE_ENABLED
#if SPRAYER_ENABLED == ENABLED
sprayer.update();
#endif
// update ch6 in flight tuning
tuning();