Commit bb315d84 authored by Don Gagne's avatar Don Gagne Committed by GitHub

Merge pull request #8292 from DonLakeFlyer/FollowMe

ArduPilot Follow Me: Support both relative and absolute FOLL_ALT_TYPE
parents 956f4a86 d54a9b0a
......@@ -49,13 +49,15 @@ SetupPage {
property int _followComboMaintainIndex: 0
property int _followComboSpecifyIndex: 1
property bool _followMaintain: followPositionCombo.currentIndex === _followComboMaintainIndex
property bool _isFollowMeSetup: _followEnabled.rawValue == 1 && _followParamsAvailable && _followOffsetType.rawValue == 1 && (_roverFirmware || (!_roverFirmware && _followAltitudeType.rawValue == 1)) && _followSysId.rawValue == 0
property bool _isFollowMeSetup: _followEnabled.rawValue == 1 && _followParamsAvailable && _followOffsetType.rawValue == _followOffsetTypeHeadingRelative && _followSysId.rawValue == 0
property bool _roverFirmware: controller.roverFirmware
readonly property int _followYawBehaviorNone: 0
readonly property int _followYawBehaviorFace: 1
readonly property int _followYawBehaviorSame: 2
readonly property int _followYawBehaviorFlight: 3
readonly property int _followYawBehaviorNone: 0
readonly property int _followYawBehaviorFace: 1
readonly property int _followYawBehaviorSame: 2
readonly property int _followYawBehaviorFlight: 3
readonly property int _followOffsetTypeHeadingRelative: 1
readonly property int _followAltitudeTypeRelative: 1
Component.onCompleted: _setUIFromParams()
......@@ -89,7 +91,7 @@ SetupPage {
_followOffsetType.rawValue = 1 // Relative to vehicle
_followSysId.rawValue = 0 // Follow first message sent
if (!_roverFirmware) {
_followAltitudeType.rawValue = 1 // Altitude is relative
_followAltitudeType.rawValue = _followAltitudeTypeRelative
}
controller.distance.value = controller.distance.defaultValue
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment