2016-08-01 05:44:12 -03:00
|
|
|
#include "Copter.h"
|
|
|
|
|
2019-02-25 10:32:52 -04:00
|
|
|
#if MODE_GUIDED_NOGPS_ENABLED == ENABLED
|
|
|
|
|
2016-08-01 05:44:12 -03:00
|
|
|
/*
|
|
|
|
* Init and run calls for guided_nogps flight mode
|
|
|
|
*/
|
|
|
|
|
|
|
|
// initialise guided_nogps controller
|
2019-05-09 23:18:49 -03:00
|
|
|
bool ModeGuidedNoGPS::init(bool ignore_checks)
|
2016-08-01 05:44:12 -03:00
|
|
|
{
|
|
|
|
// start in angle control mode
|
2019-05-09 23:18:49 -03:00
|
|
|
ModeGuided::angle_control_start();
|
2016-08-01 05:44:12 -03:00
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
// guided_run - runs the guided controller
|
|
|
|
// should be called at 100hz or more
|
2019-05-09 23:18:49 -03:00
|
|
|
void ModeGuidedNoGPS::run()
|
2016-08-01 05:44:12 -03:00
|
|
|
{
|
|
|
|
// run angle controller
|
2019-05-09 23:18:49 -03:00
|
|
|
ModeGuided::angle_control_run();
|
2016-08-01 05:44:12 -03:00
|
|
|
}
|
2019-02-25 10:32:52 -04:00
|
|
|
|
|
|
|
#endif
|