mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-10 18:08:30 -04:00
ArduCopter: bug fix for ROI not working if user did not have a camera mount
Changed verify_nav_roi command to attempt to point at the target if our camera mount type is not pan_tilt nor pan_tilt_roll
This commit is contained in:
parent
a32002e14b
commit
5d3ddf1fc9
@ -710,7 +710,7 @@ static bool verify_nav_roi()
|
||||
{
|
||||
#if MOUNT == ENABLED
|
||||
// check if mount type requires us to rotate the quad
|
||||
if( camera_mount.get_mount_type() == AP_Mount::k_tilt_roll ) {
|
||||
if( camera_mount.get_mount_type() != AP_Mount::k_pan_tilt && camera_mount.get_mount_type() != AP_Mount::k_pan_tilt_roll ) {
|
||||
// ensure yaw has gotten to within 2 degrees of the target
|
||||
if( labs(wrap_180(ahrs.yaw_sensor-auto_yaw)) <= 200 ) {
|
||||
nav_yaw = auto_yaw; // ensure target yaw for YAW_HOLD is our desired yaw
|
||||
|
Loading…
Reference in New Issue
Block a user