mirror of https://github.com/ArduPilot/ardupilot
Tracker: let AP_Vehicle handle loop()
This commit is contained in:
parent
ba883e2b89
commit
449ca74951
|
@ -64,20 +64,6 @@ void Tracker::get_scheduler_tasks(const AP_Scheduler::Task *&tasks,
|
|||
log_bit = (uint32_t)-1;
|
||||
}
|
||||
|
||||
/**
|
||||
loop() is called continuously
|
||||
*/
|
||||
void Tracker::loop()
|
||||
{
|
||||
// wait for an INS sample
|
||||
ins.wait_for_sample();
|
||||
|
||||
// tell the scheduler one tick has passed
|
||||
scheduler.tick();
|
||||
|
||||
scheduler.run(19900UL);
|
||||
}
|
||||
|
||||
void Tracker::one_second_loop()
|
||||
{
|
||||
// make it possible to change orientation at runtime
|
||||
|
|
|
@ -73,15 +73,9 @@ public:
|
|||
|
||||
Tracker(void);
|
||||
|
||||
// HAL::Callbacks implementation.
|
||||
void loop() override;
|
||||
|
||||
private:
|
||||
Parameters g;
|
||||
|
||||
// main loop scheduler
|
||||
AP_Scheduler scheduler;
|
||||
|
||||
uint32_t start_time_ms = 0;
|
||||
|
||||
AP_Logger logger;
|
||||
|
|
Loading…
Reference in New Issue