1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-23 00:05:33 +03:00
Commit graph

79 commits

Author SHA1 Message Date
Martin Budden
541f4d4018 Directory rearrangement to reflect cleanflight changes 2016-08-07 13:44:00 +01:00
Martin Budden
0de27cf7c2 Used forward declarations to remove #includes from header files 2016-08-07 01:28:17 +02:00
borisbstyle
b581f4c39a Revert "Used forward references to remove #includes from header files" 2016-08-04 01:41:58 +02:00
Martin Budden
f6194f0eb7 Used forward references to remove #includes from header files 2016-08-03 21:19:40 +01:00
borisbstyle
c11c50287e Finalisation of Betaflight PID controller // RC smoothing added back 2016-07-28 00:54:40 +02:00
Martin Budden
b5c62df3f8 Added some further build flags for ROM saving 2016-07-27 16:13:14 +01:00
borisbstyle
5e32ced94d Add FPV ANGLE MIX as a mode
ident
2016-07-17 02:05:12 +02:00
borisbstyle
d214f8602d Smoothed Derivative from Error // Fix Iterm accumulation issues // Defaultss
Saturation rework
2016-06-18 00:37:01 +02:00
borisbstyle
a74acccb84 Add rc_rate_yaw // SuperExpo feature renamed to SUPEREXPO_RATES 2016-06-02 19:41:04 +02:00
borisbstyle
bb880e68d3 Cleanup Modes 2016-06-01 22:44:56 +02:00
sblakemore
2df7e3cefa Add RTC6705 SPI VTX support 2016-05-31 07:15:37 +10:00
borisbstyle
3470181a0f Add feature for SuperExpo and Airmode // Super Expo by default activated 2016-05-30 20:42:43 +02:00
borisbstyle
ff5c320b4a Iterm reset rework // Airmode Iterm Protection Configurable // Dynamic Ki
New defaults
2016-05-23 23:57:32 +02:00
borisbstyle
595d5d0867 Acro Plus replaced by Super Expo feature 2016-03-30 12:38:29 +02:00
borisbstyle
4ec5166c0f Add option for gyro calibration on first arm // Remove Retarded Arm 2016-03-21 01:22:40 +01:00
borisbstyle
fa63ab52e1 Disabling of 3D Feature on switch 2016-03-10 00:27:44 +01:00
borisbstyle
2dc424d83b restore original modes order 2016-02-21 13:09:21 +01:00
KiteAnton
a16ac7fbe7 Remove GTUNE 2016-02-20 14:20:31 +01:00
KiteAnton
0d054af27f Additional inflight adjustments possible 2016-02-03 21:03:27 +01:00
borisbstyle
9859bbfcae Less Anti Winduo in Air mode 2016-02-03 01:32:57 +01:00
borisbstyle
a1ebe6fd4f Remove old mixer // Separate Acro Plus from Airmode // Fix MOTOLAB merge issues 2016-02-03 00:58:38 +01:00
borisbstyle
6a4682908f Rework Iterm Shrink for AIR Mode
Rework Iterm Shrink for AIR Mode part 2
2015-12-09 00:56:19 +01:00
borisbstyle
b84e9f4676 AIR MODE Safety Enhancements 2015-12-08 12:25:37 +01:00
borisbstyle
72e9a4dc17 Fix motor_stop instability 2015-12-07 11:29:22 +01:00
borisbstyle
763ff23ede Further AIR MODE enhancements // Motor stop overules AIR MODE low throttle
reset iterm for motor stop

fix luxfloat
2015-12-07 10:16:32 +01:00
borisbstyle
400fe14e30 AIR MODE Optimalisations // Disable retarded arm
enable level modes
2015-12-06 23:58:18 +01:00
borisbstyle
83d186057f AIR MODE implementation 2015-12-06 02:19:35 +01:00
borisbstyle
eafa631a32 IDLE UP switch // Remove pid_at_min_throttle 2015-12-04 16:17:44 +01:00
Dominic Clifton
57e5794ae1 Use the right mode (aka BOX) - replaces autotune mode. This will help
with migrations.
2015-10-06 21:25:40 +01:00
Dominic Clifton
123a4ccfc5 Merge branch 'GTune' of https://github.com/MJ666/cleanflight into
MJ666-Harakiri_PID_update

Conflicts:
	Makefile
	src/main/blackbox/blackbox_fielddefs.h
	src/main/flight/pid.c
	src/main/io/serial_msp.c
	src/main/mw.c
	src/main/target/ALIENWIIF3/target.h
	src/main/target/CC3D/target.h
	src/main/target/NAZE/target.h
	src/main/target/NAZE32PRO/target.h
	src/main/target/SPARKY/target.h
2015-10-06 20:16:37 +01:00
Dominic Clifton
d36da111b2 Delete autotune. 2015-10-06 19:38:02 +01:00
Michael Jakob
43f5792a61 G-Tune port from Harakiri
Enabled for NAZE, ALIENWWIIF1 and ALIENWIIF3 targets
Implement G-Tune for all PID controllers
The G-Tune tuning results will be save if G-Tune mode will be disabled
during copter is disarmed.
Update PID controller and G-Tune documentation
2015-10-04 18:37:18 +02:00
ProDrone
f0681de53d Updates and feature additions to failsafe system.
- Added failsafe flightmode and rc control box.

To make failsafe procedure a separate flight mode and make it possible
to trigger failsafe with an AUX switch.

- Failsafe mode is activated when failsafe is active.

RC link lost is simulated with the failsafe AUX switch.
When NOT armed: failsafe switch to failsafe mode is shown in GUI (mode
tab).

- Activate failsafe mode with AUX switch.

- Prevent arming when failsafe via AUX switch is active (safety issue).

- Make failsafe disarm if motors armed and throttle was LOW (2D & 3D)
for `failsafe_throttle_low_delay` time (__JustDisarmEvent__).

Applied code changes to effectively add pull request: Make failsafe
disarm if motors armed and throttle low #717.

- Use failsafeIsMonitoring() to actually start monitoring.

- Added `failsafe_kill_switch` to code.

When set to 1 (0 is default), the failsafe switch will instantly disarm
(__KillswitchEvent__) instead of executing the landings procedure.
Arming is NOT locked after
this, so the craft could be re-armed if needed.
This is intended for racing quads where damage and danger must be
minimized in case of a pilot error.

- Added `failsafe_throttle_low_delay`, adapted documentation.

Used to adjust the time throttle level must have been LOW
to _only disarm_ instead of _full failsafe procedure_
(__JustDisarmEvent__).

- Updated the failsafe documentation.

- Re-enable arming at end of failsafe procedure.

At the end of a handled failsafe event, that means: auto-landing,
__JustDisarmEvent__ or __KillswitchEvent__, the RX link is monitored for
valid data.
Monitoring is a part of the failsafe handling, which means the craft is
still in failsafe mode while this is done.
Arming is re-enabled (allowed) when there is a valid RX link for more
then XX seconds, where XX depends on the handled event like this:
1. XX = 30 seconds after auto landing.
2. XX = 3 seconds after __JustDisarmEvent__.
3. XX = 0 seconds after __KillswitchEvent__.

NOTE: When armed via an AUX switch, you will have to switch to the
disarmed position at the very end to be able to re-arm.
The failsafe mode will not end until you do.

- __KillswitchEvent__ has now priority over __JustDisarmEvent__

- Apply rxfail values instantly when failsafe switch is ON

- Added missing cases to display.c

Show M when failsafe is monitoring for RX recovery (AND disarming when
armed with a switch).

===

Reworked the code from counter-based to time-based.

- AUX failsafe switch now has identical behavior to RX loss.

- Added RX failure and RX recovery timing.

- __KillswitchEvent__ skips RX failure detection delay (direct disarm).

===

[UNIT TESTS]

Adapted failsafe related unittests from counter-based to time-based

- Added failsafeOnValidDataFailed() to some tests

- Removed duplicate test setup from rc_controls_unittest.cc

- Removed magic numbers from rx_ranges_unittest.cc and rx_rx_unittest.cc

- Reworked all test-cases for flight_failsafe_unittest.cc
2015-09-04 16:55:40 +02:00
Alexander Fedorov
01632998a3 Blackbox: Enable logging when mode switch is active 2015-07-22 13:36:22 +12:00
Dominic Clifton
ea6a6ccb3d First cut of custom servo mixers.
Main rule logic and MSP commands ported from baseflight.

Gimbal mixer updated to use rules.  This allows us to remove more
conditional logic.  Operation of gimbal servos is now different.
2015-06-28 23:06:56 +01:00
Dominic Clifton
6f3c16fe6c Reducing the maximum number of mode ranges from 40 to 20 to free up some
configuration storage space.
2015-05-30 00:03:56 +01:00
Dominic Clifton
c174a52ebe Allow independent pitch and roll in-flight PID adjustment. Fixes #149. 2015-05-17 23:43:55 +01:00
borisbstyle
da8bb6f6fc Yaw Expo Feature 2015-05-06 22:23:40 +01:00
Nicholas Sherlock
5edfdde942 Restore previous rate limit for yaw of 2.55
Since some people are indeed using yaw > 1.0.
2015-03-26 02:02:32 +13:00
Nicholas Sherlock
828ec550cd Apply the same maximum control rates (1.0) in CLI and MSP
Previously it was possible to set roll/pitch rate > 1.0 using MSP, but
not using the CLI. Roll/pitch rate > 1.0 is meaningless.

TPA is also limited to 1.0.
2015-03-22 20:38:15 +13:00
Dominic Clifton
5e3734946e # This is a combination of 2 commits.
# The first commit's message is:

Previously, at minimum throttle, the quad would do absolutely no self-leveling
and simply run the motors at constant minthrottle.  This allowed the chance
for the quad to lose control during flight if the throttle was set to minimum,
say, to drop from a high altitude to a lower one.

With this edit, the quad will still self-level at minimum throttle when armed,
allowing for safe decents from altitude.  To prevent motors spinning when
arming/disarming, the yaw input is ignored if the throttle is at minimum and
we're using the sticks to arm/disarm.

Conflicts:
	src/main/flight/mixer.c

# This is the 2nd commit message:

added cli command disable_pid_at_min_throttle
2015-03-09 23:36:54 +01:00
Dominic Clifton
e4a6886266 Allow independent in-flight adjustment of roll and pitch. 2015-03-07 15:14:52 +00:00
Dominic Clifton
b595b49ca8 Decouple roll and pitch rates. MSP clients take note of updated
MSP_RC_TUNING/MSP_SET_RC_TUNING commands.
2015-03-07 15:11:20 +00:00
Dominic Clifton
55d9994ff8 Reset adjustment states when switching profiles.
Fixes #544.
2015-02-26 13:58:03 +00:00
Dominic Clifton
f77a762b48 Allow inflight adjustments for floating-point based PID controllers. 2015-01-30 20:54:34 +01:00
Krzysztof Rosinski
34cd8f466e MSP command for sonar altitude 2015-01-29 15:17:15 +01:00
Dominic Clifton
b64c71264c Renaming getRcStickPosition to getRcStickDeflection and moving to
rc_controls.c.
2015-01-16 01:00:40 +00:00
Dominic Clifton
347b156727 Avoid calling mwDisarm() when due to having auto_disarm_delay when using
switch to arm().
2014-12-26 20:22:13 +00:00
Dominic Clifton
503e7a0817 Decouple altitudehold.c from config.c. Update flight_imu_unittest and
altitude_hold_unittest.
2014-11-03 20:03:21 +01:00
Dominic Clifton
28f9fa629c Add rate profiles and inflight switching between them. See Profiles and
Inflight Adjustment documentation for details.
2014-10-29 23:36:34 +00:00