1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-15 12:25:20 +03:00
Commit graph

27 commits

Author SHA1 Message Date
ctzsnooze
4c917efa50 Smooth anti gravity 2018-07-21 23:49:41 +12:00
Robert Lacroix
aa18ab4afa Allow linking of modes
This allows modes to be linked, for example to link vtx pit mode to paralyze. Whenever paralyze is activated, vtx pit mode is activated as well. Also the logic to prevent mode changes when enabling paralyze can be removed in favor of making paralyze sticky.

Modes can be linked in CLI by providing the mode id as the last parameter of the aux command. For example in order to link vtx pit mode to paralyze, replace the last 0 of the pit mode aux (39) with the mode id of paralyze (45):

```
aux 2 39 2 1700 2100 0 0
```

becomes

```
aux 2 39 2 1700 2100 0 45
```

_Legal disclaimer: I am making my contributions/submissions to this project solely in my personal capacity and am not conveying any rights to any intellectual property of any third parties._
2018-07-13 13:05:15 +02:00
mikeller
93ab648183 Added disabling of GPS_RESCUE when 3D is enabled. 2018-07-01 21:33:32 +12:00
Bruce Luckcuck
9b43839052 Acro trainer
Adds a new angle limiting mode for pilots who are learning to fly in acro mode. Primarily targeted at new LOS acro pilots, but can be used with FPV as well.

The feature is activated with a new mode named "ACRO TRAINER". When the feature is active, the craft will fly in normal acro mode but will limit roll/pitch axes so that they don't exceed the configured angle limit. New pilots can start with a small angle limit and progressively increase as their skills improve.

The accelerometer must be enabled for the feature to be configured and function.

Also the feature will only be active while in acro flight and will disable if ANGLE or HORIZON modes are selected.

For most users all they need to do is simply configure the new mode to be active as desired on the "Modes" tab in the configurator and configure the desired angle limit in the cli.

Configuration parameters:

acro_trainer_angle_limit: (range 10-80) Angle limit in degrees.

acro_trainer_lookahead_ms: (range 10-200) Time in milliseconds that the logic will "look ahead" to help minimize overshoot and bounce-back if the limit is approached at high gyro rates. The default value of 50 should be good for most users. For low powered or unresponsive craft (micros or brushed) it may be helpful to increase this setting if you're seeing substantial overshoot.

acro_trainer_debug_axis: (ROLL, PITCH) The axis that will log information if debugging is active.

To enable debugging:
set debug_mode = ACRO_TRAINER

debug(0) - Current angle
debug(1) - The internal logic state
debug(2) - Modified setpoint
debug(3) - Projected angle based gyro rate and lookahead period
2018-05-29 21:08:16 -04:00
mikeller
557d704b9e Fixed RC modes PG version after GPS rescue. 2018-05-21 15:07:36 +12:00
s0up
ac6b8088c9 add gps rescue mode 2018-05-20 16:28:17 -07:00
Robert Lacroix
092baf5805 Add Paralyze mode support
During team relay races it's unsafe to retrieve crashed quads because the course is continuously hot. In order to safely fly a backup quad with the primary quad crashed in the field (but powered up) it's necessary to:

* Disable arming, so that the crashed quad doesn't unintentionally arm as well. This is specifically a problem when a transmitter can send signals to all powered up receivers (like FrSky and others).
* Change VTX to an unused channel with low power output
* Turn off telemetry

This change introduces a new mode called paralyze which disables arming and prevents mode changes (except beeper). It can only be invoked while the quad isn't armed. Once it's invoked, the FC has to be power cycled. In order to invoke it, the mode needs to be in a disengaged state at least once, so that forgetting to flip the switch back after crashing doesn't immediately invoke graveyard on the backup quad.

_Legal disclaimer: I am making my contributions/submissions to this project solely in my personal capacity and am not conveying any rights to any intellectual property of any third parties._
2018-05-10 07:40:31 -07:00
blckmn
a9f74cd6df Removed excess trailing spaces before new lines on licenses. 2018-04-25 20:58:00 +10:00
blckmn
46fe22b4bd Direct license replacement 2018-04-22 09:22:46 +10:00
Michael Keller
92d19e7be6
Merge pull request #3036 from cleanflight/spracingf7dual-pidaudio (#5586)
PID-Audio feature
2018-04-01 11:08:41 +12:00
Michael Keller
b4667332d7
Merge pull request #5208 from jflyper/bfdev-piniobox-cleanup
PINIOBOX Separation of boxId and permanentId.
2018-02-20 01:53:07 +13:00
jflyper
18d5a373c0 Separation of boxId and permanentId. 2018-02-18 21:30:05 +09:00
mikeller
232fc4e8de Unified BOX3DDISABLE and BOX3DONASWITCH switches. 2018-02-13 20:02:02 +13:00
jflyper
6557b161aa Add box to pinio monitor/mapper 2018-02-12 13:54:40 +09:00
Petr Ledvina
5a75737df9 Implement getBoxIdState
packFlightModeFlags is simplified by using it. Base for #5111
2018-02-05 13:10:52 +01:00
jflyper
11c47c631b Port iNav's rangefinder 2017-12-20 12:54:19 +09:00
mikeller
b489d0ba9d Renamed 'parameter_group' to 'pg'. 2017-12-19 23:36:31 +13:00
Dave Huber
b9272ae325 Added Logic AND to Modes
Added Mode Inversion configuration, CLI commands, and update.
Changed Mode Inversion to Mode Logic.
configure by AND/OR instead of output inversion.
Fixed Mode Logic code after debugging.
Added PG_REGISTER to cli unittest.
Revert version to previous.
Revamped Mode Logic using existing Conditions config.
Requires coordination with BF-configurator, but works with CLI (added argument in 'aux' command).
Coding standard changes.
Cleaned up code. Added modeLogic enum.
removed executable permissions.
Code cleanup, cliAux backward compatible.
changed bitArrayInv to bitArrayXor.
allow for old 'aux' command (without last argument) to be made. asserts MODELOGIC_OR instead of resetting the memory.
2017-12-12 10:35:15 -06:00
Curtis Bangert
b13e73c9bb Pit mode on a switch 2017-11-26 23:17:21 -05:00
Bryce Johnson
d1a197f99e 3d on a mode switch 2017-10-11 13:08:12 -05:00
mikeller
98d85969ce Added distinct mode for 'beep GPS number of satellites found', and separated this functionality from 'RX_SET' beeping. 2017-10-04 08:43:03 +13:00
Bryce Johnson
fd37566bc5 New turtle mode that only spins needed props 2017-09-07 07:59:59 -05:00
Bryce Johnson
f8bd089e47 Add in prearm option for safer arming.
When prearm is used, it must be enabled before arming.  Before you can arm again, the prearm switch needs to get toggled. (+3 squashed commit)
2017-07-30 17:08:46 -05:00
Martin Budden
6943fb8e56 Split MSP box code into separate module 2017-07-20 13:33:34 +01:00
mikeller
282668edde Added BOXDSHOTREVERSE as a separate mode to BOX3DDISABLE. 2017-07-08 12:32:23 +12:00
Dominic Clifton
32fa109a64 Merge pull request #2852 from azolyoung/add-runcam-split-support
Add runcam split support
2017-06-23 08:48:07 +12:00
Dominic Clifton
db006b1585 Merge pull request #2856 from ledvinap/improvement-64bit-boxid
array based box masks
2017-06-19 13:31:08 +12:00