mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-11-03 04:31:36 +08:00
MAVSDK test: increase offboard position threshold
This is a workaround to hotfix CI but the root cause is #22792 (MAVSDK test failing after EKF change, accelerometer simulation issues not learned anymore?)
This commit is contained in:
@@ -34,6 +34,7 @@
|
|||||||
#include "autopilot_tester.h"
|
#include "autopilot_tester.h"
|
||||||
#include <chrono>
|
#include <chrono>
|
||||||
|
|
||||||
|
static constexpr float acceptance_radius = 0.3f;
|
||||||
|
|
||||||
TEST_CASE("Offboard takeoff and land", "[multicopter][offboard]")
|
TEST_CASE("Offboard takeoff and land", "[multicopter][offboard]")
|
||||||
{
|
{
|
||||||
@@ -45,7 +46,7 @@ TEST_CASE("Offboard takeoff and land", "[multicopter][offboard]")
|
|||||||
tester.set_rc_loss_exception(AutopilotTester::RcLossException::Offboard);
|
tester.set_rc_loss_exception(AutopilotTester::RcLossException::Offboard);
|
||||||
tester.arm();
|
tester.arm();
|
||||||
std::chrono::seconds goto_timeout = std::chrono::seconds(90);
|
std::chrono::seconds goto_timeout = std::chrono::seconds(90);
|
||||||
tester.offboard_goto(takeoff_position, 0.1f, goto_timeout);
|
tester.offboard_goto(takeoff_position, acceptance_radius, goto_timeout);
|
||||||
tester.offboard_land();
|
tester.offboard_land();
|
||||||
tester.wait_until_disarmed(std::chrono::seconds(120));
|
tester.wait_until_disarmed(std::chrono::seconds(120));
|
||||||
tester.check_home_within(1.0f);
|
tester.check_home_within(1.0f);
|
||||||
@@ -63,12 +64,12 @@ TEST_CASE("Offboard position control", "[multicopter][offboard]")
|
|||||||
tester.store_home();
|
tester.store_home();
|
||||||
tester.set_rc_loss_exception(AutopilotTester::RcLossException::Offboard);
|
tester.set_rc_loss_exception(AutopilotTester::RcLossException::Offboard);
|
||||||
tester.arm();
|
tester.arm();
|
||||||
std::chrono::seconds goto_timeout = std::chrono::seconds(120);
|
std::chrono::seconds goto_timeout = std::chrono::seconds(10);
|
||||||
tester.offboard_goto(takeoff_position, 0.1f, goto_timeout);
|
tester.offboard_goto(takeoff_position, acceptance_radius, goto_timeout);
|
||||||
tester.offboard_goto(setpoint_1, 0.1f, goto_timeout);
|
tester.offboard_goto(setpoint_1, acceptance_radius, goto_timeout);
|
||||||
tester.offboard_goto(setpoint_2, 0.1f, goto_timeout);
|
tester.offboard_goto(setpoint_2, acceptance_radius, goto_timeout);
|
||||||
tester.offboard_goto(setpoint_3, 0.1f, goto_timeout);
|
tester.offboard_goto(setpoint_3, acceptance_radius, goto_timeout);
|
||||||
tester.offboard_goto(takeoff_position, 0.1f, goto_timeout);
|
tester.offboard_goto(takeoff_position, acceptance_radius, goto_timeout);
|
||||||
tester.offboard_land();
|
tester.offboard_land();
|
||||||
tester.wait_until_disarmed(std::chrono::seconds(120));
|
tester.wait_until_disarmed(std::chrono::seconds(120));
|
||||||
tester.check_home_within(1.0f);
|
tester.check_home_within(1.0f);
|
||||||
|
|||||||
Reference in New Issue
Block a user