Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed wing soaring mode #7250

Merged
merged 6 commits into from
Nov 8, 2021

Conversation

breadoven
Copy link
Collaborator

Provides a "Soaring" mode for fixed wing. Intended to be used with power off so aimed at sailplanes/motor gliders.

Mode is active when Position Hold or Heading Hold modes are enabled. Disables altitude control and allows Angle mode to "free float" in pitch within a deadband set using option nav_fw_soaring_pitch_deadband, The deadband operates above and below the level datum. The motor can be switched off using option nav_fw_soaring_motor_stop when mode is active.

PR also fixes redundant logic in fc_msp_box.c related to feature(FEATURE_GPS).

Works as intended when tested in flight on a conventional T tail. Not yet flight tested on a flying wing.

@DzikuVx
Copy link
Member

DzikuVx commented Jul 12, 2021

Wo ho ho... now this is AWESOME!

@CertainBot
Copy link

Interesting idea. Shouldn't it be separate mode from Pos hold and Course hold? Can be that I am not undestanding it properly, the way I see it is as an Angle mode with a dead band around center pitch where the pitch axis is not corrected by the Angle mode. In this way it can be a separate mode that can be overimposed to Pos and Course holds like it was done with Alt hold.

@breadoven
Copy link
Collaborator Author

It's an accessory mode that provides automated direction control in a straight line (Course hold or Cruise) or circling (Poshold) whilst overriding the altitude control and Angle limitations which normally prevent these modes from allowing a plane to soar freely. Ideally with Poshold it should drift with the lift so it can follow thermals but that's a whole different thing in itself.

There is a function in Inav already that cancels Nav mode altitude control when the motor is stopped by setting the throttle low but that won't work if nav_overrides_motor_stop is set to ALL_NAV, the setting you'd most likely prefer when not soaring.

@breadoven breadoven added this to the 4.0 milestone Oct 28, 2021
@DzikuVx DzikuVx added the Release Notes Add this when a PR needs to be mentioned in the release notes label Nov 8, 2021
@DzikuVx DzikuVx merged commit 6df55cb into iNavFlight:master Nov 8, 2021
breadoven added a commit to breadoven/inav that referenced this pull request Nov 8, 2021
commit ddbf3dd
Merge: 6df55cb 3c4df22
Author: Paweł Spychalski <pspychalski@gmail.com>
Date:   Mon Nov 8 10:30:44 2021 +0100

    Merge pull request iNavFlight#7578 from breadoven/abo_mission_planner_fix

    Mission planner fix

commit 6df55cb
Merge: 00716f7 896f2da
Author: Paweł Spychalski <pspychalski@gmail.com>
Date:   Mon Nov 8 09:06:29 2021 +0100

    Merge pull request iNavFlight#7250 from breadoven/abo_fixed_wing_soaring_mode

    Fixed wing soaring mode

commit 00716f7
Merge: b0aa8ee 6091443
Author: Paweł Spychalski <pspychalski@gmail.com>
Date:   Mon Nov 8 09:03:43 2021 +0100

    Merge pull request iNavFlight#7323 from MrD-RC/nav_rth_climb_first_stage

    Two Stage Climb First RTH

commit b0aa8ee
Merge: 3b77031 f7b4e75
Author: Paweł Spychalski <pspychalski@gmail.com>
Date:   Mon Nov 8 08:58:30 2021 +0100

    Merge pull request iNavFlight#7573 from iNavFlight/dzikuvx-fix-f7-h7-msc-on-windows

    Fix MSC on windows with F7 and H7

commit 3b77031
Merge: c4ecdd7 ed4d232
Author: Paweł Spychalski <pspychalski@gmail.com>
Date:   Mon Nov 8 08:58:08 2021 +0100

    Merge pull request iNavFlight#7574 from sdellava/Add-pinio-to-FLYVOOF457

    Added PINIO and USER1 mode to FLYWOOF745 and FLYWOOF745

commit c4ecdd7
Merge: 7a71263 65514af
Author: Paweł Spychalski <pspychalski@gmail.com>
Date:   Mon Nov 8 08:57:49 2021 +0100

    Merge pull request iNavFlight#7572 from bkleiner/bkleiner-h7-usb-msc

    h7: usb msc support for sdio

commit 7a71263
Merge: d5b7a2c 0a14236
Author: Paweł Spychalski <pspychalski@gmail.com>
Date:   Mon Nov 8 08:55:29 2021 +0100

    Merge pull request iNavFlight#7577 from iNavFlight/dzikuvx-fix-ci

    Temporary fix for CI

commit 0a14236
Author: Pawel Spychalski (DzikuVx) <pspychalski@gmail.com>
Date:   Mon Nov 8 08:35:54 2021 +0100

    Temporary fix for CI

commit 3c4df22
Author: breadoven <56191411+breadoven@users.noreply.github.com>
Date:   Mon Nov 8 00:08:18 2021 +0000

    Update navigation.c

commit 896f2da
Merge: aa1f6c2 d5b7a2c
Author: breadoven <56191411+breadoven@users.noreply.github.com>
Date:   Sun Nov 7 16:40:19 2021 +0000

    Merge remote-tracking branch 'upstream/master' into abo_fixed_wing_soaring_mode

commit aa1f6c2
Merge: 9ce4e27 264955b
Author: breadoven <56191411+breadoven@users.noreply.github.com>
Date:   Sun Nov 7 15:51:49 2021 +0000

    Merge remote-tracking branch 'upstream/master' into abo_fixed_wing_soaring_mode

commit ed4d232
Author: Stefano Della Valle <stefano.dellavalle@thingslab.email>
Date:   Sun Nov 7 15:23:13 2021 +0100

    Added pinio

commit f7b4e75
Author: Pawel Spychalski (DzikuVx) <pspychalski@gmail.com>
Date:   Sun Nov 7 14:20:18 2021 +0100

    Fix MSC on windows with F7 and H7

commit 65514af
Author: bkleiner <b.kleiner@str8labs.com>
Date:   Sat Nov 6 19:49:36 2021 +0100

    h7: hide all the unused parameters in usbd_msc_scsi

commit 4463d3f
Author: bkleiner <b.kleiner@str8labs.com>
Date:   Sat Nov 6 19:37:25 2021 +0100

    h7: use idma for msc sdio

commit 6855c33
Author: bkleiner <b.kleiner@str8labs.com>
Date:   Sat Nov 6 19:37:01 2021 +0100

    h7: enable usb msc and fix middleware compliation

commit b4ba470
Author: bkleiner <b.kleiner@str8labs.com>
Date:   Sat Nov 6 18:36:57 2021 +0100

    h7: drop SDCARD_SDIO_DMA as IDMA is used

commit 6091443
Author: Darren Lines <darren@darrenlines.uk>
Date:   Sat Nov 6 16:45:42 2021 +0000

    Updated Navigation.md - Made doc clearer

    Made doc clearer.

commit 98731cc
Merge: 155eaf7 3dad1d2
Author: Darren Lines <darren@darrenlines.uk>
Date:   Sat Nov 6 16:17:02 2021 +0000

    Merge branch 'master' into nav_rth_climb_first_stage

commit 9965eb8
Author: bkleiner <b.kleiner@str8labs.com>
Date:   Sat Nov 6 15:27:40 2021 +0100

    h7: move afatfs_cache to for alignment

commit 364b5be
Author: bkleiner <b.kleiner@str8labs.com>
Date:   Sat Nov 6 14:37:00 2021 +0100

    h7: init sdio pins in fc_init

commit 24f2fb7
Author: bkleiner <b.kleiner@str8labs.com>
Date:   Sat Nov 6 14:36:47 2021 +0100

    h7: skip SDIO_CFG_TO_DEV conversion as we hardcode enum entries

commit e440b64
Author: bkleiner <b.kleiner@str8labs.com>
Date:   Sat Nov 6 13:30:32 2021 +0100

    h7: fix sdio src file extension

commit fee2394
Author: Pawel Spychalski (DzikuVx) <pspychalski@gmail.com>
Date:   Mon Jul 26 11:59:53 2021 +0200

    Initial cut on H7 SD card. No idea if works. Compiles

commit 155eaf7
Merge: cce14d6 f8c9c3e
Author: Darren Lines <darren@darrenlines.uk>
Date:   Wed Nov 3 19:18:20 2021 +0000

    Merge branch 'iNavFlight:master' into nav_rth_climb_first_stage

commit cce14d6
Merge: 2762f25 73a1325
Author: Darren Lines <darren@darrenlines.uk>
Date:   Wed Nov 3 19:17:12 2021 +0000

    Merge branch 'master' into nav_rth_climb_first_stage

commit 9ce4e27
Merge: 6f6371b 312d038
Author: breadoven <56191411+breadoven@users.noreply.github.com>
Date:   Thu Oct 28 20:31:47 2021 +0100

    Merge remote-tracking branch 'upstream/master' into abo_fixed_wing_soaring_mode

commit 2762f25
Merge: 7db8605 d3a95d8
Author: Darren Lines <darren@darrenlines.uk>
Date:   Sat Oct 9 14:24:22 2021 +0100

    Merge branch 'iNavFlight:master' into nav_rth_climb_first_stage

commit 7db8605
Author: Darren Lines <darren@darrenlines.uk>
Date:   Sun Aug 1 17:11:44 2021 +0100

    Update navigation.h

    Clarified descriptions

commit b6f8ff9
Author: Darren Lines <darren@darrenlines.uk>
Date:   Sun Aug 1 11:39:29 2021 +0100

    Corrected heading and based off home position

commit 4e5f86f
Author: Darren Lines <darren@darrenlines.uk>
Date:   Mon Jul 26 21:50:53 2021 +0100

    Added CMS settings to make testing at the field easier

commit f06288c
Author: Darren Lines <darren@darrenlines.uk>
Date:   Sun Jul 25 13:17:59 2021 +0100

    Changed method to set climb stage altitude

    Climb stage altitude is now set when RTH is initiated. this saves on calculations in each loop.

commit 9ed0b1d
Author: Darren Lines <darren@darrenlines.uk>
Date:   Sat Jul 24 19:55:24 2021 +0100

    Changes to fix EXTRA mode

    Initial testing went pretty well. Using the RTH climb stage worked perfectly with the AT_LEAST method. However the EXTRA method didn't work. After reviewing the code, I can see why, and have implemented a fix. This should now work as expected. I'll test ASAP.

commit a1c05be
Author: Darren Lines <darren@darrenlines.uk>
Date:   Tue Jul 13 20:23:29 2021 +0100

    Typo fixed. Compiled docs.

commit 7d92451
Author: Darren Lines <darren@darrenlines.uk>
Date:   Tue Jul 13 16:12:42 2021 +0100

    typo fix

commit 10931fe
Author: Darren Lines <darren@darrenlines.uk>
Date:   Sat Jun 19 17:36:02 2021 +0100

    Fixed compile errors

commit 4b2095f
Author: Darren Lines <darren@darrenlines.uk>
Date:   Sat Jun 19 10:41:44 2021 +0100

    Update Settings.md

commit 05199ad
Author: Darren Lines <darren@darrenlines.uk>
Date:   Sat Jun 19 10:23:34 2021 +0100

    Allow setting an altitude limit for climb first

    This feature adds two CLI commands:
    - nav_rth_climb_first_stage_mode
    - nav_rth_climb_first_stage_altitude

    nav_rth_climb_first_stage_altitude sets an altitude to transition from climb first to turn first. 0 is disabled.

    nav_rth_climb_first_stage_mode determines how nav_rth_climb_first_stage_altitude is used. Currently either as an at least altitude or adding to the current altitude.

    Initial coding.

commit 6f6371b
Author: breadoven <56191411+breadoven@users.noreply.github.com>
Date:   Mon Jul 12 10:18:14 2021 +0100

    Update fc_msp_box.c

commit 1d64e0a
Author: breadoven <56191411+breadoven@users.noreply.github.com>
Date:   Mon Jul 12 09:44:04 2021 +0100

    Update fc_msp_box.c

commit 64a3ef6
Author: breadoven <56191411+breadoven@users.noreply.github.com>
Date:   Sun Jul 11 21:49:54 2021 +0100

    Initial build
@breadoven breadoven deleted the abo_fixed_wing_soaring_mode branch November 8, 2021 15:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Release Notes Add this when a PR needs to be mentioned in the release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants