Commit Graph

12180 Commits

Author SHA1 Message Date
Michael Keller 46a8aea76b
Merge pull request #6436 from DieHertz/bfdev-fix-kakute-f7-timer-collision
Fix KakuteF7 motors 3 and 4
2018-07-24 23:52:22 +12:00
Michael Keller 01ddbf2927
Merge pull request #6439 from DieHertz/bfdev-max7456-segfault-fix
Fixed init order of MAX7456 DisplayPort
2018-07-24 23:51:34 +12:00
Andrey Mironov 134616ed32 Enabled MPU for ITCM-RAM and MemManage_Handler 2018-07-24 14:27:42 +03:00
mikeller 8a427da8e9 Removed more features from F3 to make the firmware fit into flash. 2018-07-24 23:09:20 +12:00
Andrey Mironov 65bff6b7d7 Added a condition for enabling OSD task 2018-07-24 13:40:01 +03:00
Andrey Mironov 5542578d98 Added KISSFCV2F7 back to supported targets 2018-07-23 23:41:41 +03:00
Andrey Mironov 0115ff15b2 Fixed init order of MAX7456 DisplayPort 2018-07-23 23:31:42 +03:00
Andrey Mironov 3c4c3a09fe Unified KISSFC V2 F7 linker script 2018-07-23 20:34:54 +03:00
Andrey Mironov 5e398be295 Undefined camera control pin to resolved timer collision 2018-07-23 20:01:44 +03:00
Andrey Mironov 19f5d3cd98 Removed a redundant memset 2018-07-23 17:00:43 +03:00
Andrey Mironov 02eccab75b Made gyroAnalyse reentrant 2018-07-23 17:00:43 +03:00
Michael Keller 805b2f4b1e
Merge pull request #6429 from DieHertz/bfdev-dynamic-notch-quality-fix
Fixed dynamic notch Q CLI scaling
2018-07-24 00:35:40 +12:00
Andrey Mironov 79dfaadb85 Fixed dynamic notch Q scaling 2018-07-23 14:41:21 +03:00
Michael Keller 0c5ed8f9bf
Merge pull request #6408 from mikeller/add_release_freeze_announcement
Added release freeze announcement for 3.5 to pull request template, removed F1 end of life message.
2018-07-23 22:58:34 +12:00
Michael Keller 544ecb1d69
Merge pull request #6424 from etracer65/cli_use_memcmp
Use memcmp for CLI defaults comparisons where appropriate
2018-07-23 20:07:19 +12:00
Michael Keller 179d01fb3f
Merge pull request #6421 from mikeller/add_dynamic_filter_parameters
Added parameters for dynamic notch filter.
2018-07-23 07:31:20 +12:00
s0up 3ade65a438 correct casing per mikeller review 2018-07-22 12:23:33 -07:00
s0up 0f2dc6328e Merge branch 'master' of github.com:betaflight/betaflight into rescue_config_change 2018-07-22 12:21:36 -07:00
Bruce Luckcuck 68906f990b Changes from feedback - use source instead of type in sizeof() 2018-07-22 13:40:20 -04:00
Bruce Luckcuck 9745547175 Use memcmp for CLI defaults comparisons where appropriate
Saves 196 bytes on F3
2018-07-22 13:01:06 -04:00
mikeller 2746173ab6 Updated defaults. 2018-07-23 00:43:30 +12:00
mikeller 46d3f0dd83 Added parameters for dynamic notch filter. 2018-07-23 00:43:30 +12:00
Michael Keller bc22934185
Merge pull request #6422 from mikeller/add_antigravity_mode_to_msp
Added antigravity mode parameter to MSP.
2018-07-23 00:37:05 +12:00
Michael Keller 8592430a5f
Merge pull request #6411 from ctzsnooze/Dynamic_Notch_Update
Dynamic Notch Filter Update
2018-07-23 00:34:56 +12:00
jflyper b909fa2a3f Fix mixer for A-Tail 2018-07-22 20:15:53 +09:00
mikeller 651174e794 Added antigravity mode parameter to MSP. 2018-07-22 22:23:17 +12:00
Michael Keller b4dd86dbde
Merge pull request #6420 from mikeller/remove_sirinfpv_features
Removed features from SIRINFPV target to make room for dynamic notch.
2018-07-22 22:11:56 +12:00
mikeller 1adb4ffa55 Removed features from SIRINFPV target to make room for dynamic notch. 2018-07-22 21:40:23 +12:00
Michael Keller 81ba753f06
Merge pull request #6417 from mikeller/remove_features
Removed features from F3 targets to make dynamic filter fit.
2018-07-22 20:57:59 +12:00
Michael Keller 7b212f7d69
Merge pull request #6419 from mikeller/fix_displayport_without_msp
Fixed compilation error when displayport over MSP is not defined.
2018-07-22 20:16:09 +12:00
Michael Keller 2cbe8b0e9d
Merge pull request #6415 from mikeller/added_per_mcu_builds
Added per-MCU-type build targets.
2018-07-22 14:02:05 +12:00
mikeller 6da89d5f04 Fixed compilation error when displayport over MSP is not defined. 2018-07-22 13:48:43 +12:00
Michael Keller 4382203abf
Merge pull request #6416 from mikeller/remove_kissfcv2f7_from_build
Removed KISSFCV2F7 from build because of ITCM_RAM overflow.
2018-07-22 13:14:48 +12:00
Michael Keller de7a18f1c2
Merge pull request #6409 from mikeller/remove_unused_pid_settings
Removed unused PID settings.
2018-07-22 12:43:19 +12:00
mikeller 08294d21d8 Removed features from F3 targets to make dynamic filter fit. 2018-07-22 12:24:49 +12:00
Michael Keller 2293462324
Added more verbosity. 2018-07-22 12:08:31 +12:00
mikeller 3663fcb285 Removed KISSFCV2F7 from build because of ITCM_RAM overflow. 2018-07-22 11:49:43 +12:00
mikeller ec06575203 Removed unused PID settings. 2018-07-22 11:41:22 +12:00
Michael Keller 5e2fefe036
Merge pull request #6355 from etracer65/pid_feedforward
PID controller feedforward
2018-07-22 11:34:28 +12:00
mikeller 5c16c50826 Added per-MCU-type build targets. 2018-07-22 11:24:07 +12:00
Michael Keller 4d53c3a5d7
Merge pull request #6414 from mikeller/remove_f3_features
Removed features from F3 to make new features fit.
2018-07-22 10:54:52 +12:00
mikeller 19b0f9712f Also removed some from FURYF3. 2018-07-22 10:07:48 +12:00
mikeller 5c2195d5ed Removed features from F3 to make new features fit. 2018-07-22 09:23:42 +12:00
ctzsnooze f1a67f9c19 Put pre-filter debugs into correct location 2018-07-22 01:09:13 +10:00
ctzsnooze 0296ffd13e move raw gyro debug for DEBUG_FFT and DEBUG_FFT_FREQ to correct place 2018-07-22 00:43:55 +10:00
Bruce Luckcuck a1d3a0dba8 Add in-flight adjustments support for feedforward terms
Renamed/repurposed the "D Setpoint" adjustment to be "Pitch & Roll F Adjustment" and have it simultaneously adjust pitch and roll.

Renamed the "D Setpoint Transition" adjustment to be "Feedforward Transition" - no functionality changes.

Added adjustments for the individual Pitch, Roll and Yaw axes.
2018-07-21 10:26:25 -04:00
Bruce Luckcuck 17e76e48f6 PID controller feedforward
Restructures the PID controller to decouple feedforward from D.

Cleaned up the structure of the PID controller; moved some feature-based enhancements out of the main structure.

Feedforward becomes a separate component of the PID controller and there is now:
f_pitch
f_roll
f_yaw

The default values of 60 for pitch and roll matches the default setpoint weight used in BF3.4.  Yaw previously had no setpoint weight capability so the default here needs to be discussed.  Currently it's also set to 60 and flight testing seems positive.  Feedforward on yaw adds a lot of value so I don't think we want to default to 0.  Instead we need decide on the default.

All occurences of setpoint weight have been replaced by feedforward. "setpoint_relax_ratio" has been renamed to "feedforward_transition".

The pidSum now consists of P + I + D + F.

D has been added back for yaw (disabled by default with d_yaw = 0). We've found little need for D for normal quads but it may have value for other configurations - particularly tricopters.

Updated CMS menus to support adjusting the feedforward for each axis.

Changed the default for "rc_interp_ch" to be "RPYT".  Need yaw to be smoothed to support feedforward.

Open issues:

Needs BFC support
- Need to add support for the axis "F" gains.
- Remove "setpoint weight" slider.
- Rename "D Setpoint transition" to "Feedforward transition"

Needs BBE support
- Header "setpoint_relaxation_ratio" has been renamed "feedforward_transition"
- Header "dterm_setpoint_weight" has been replaced with an array named "feed_forward_weight".
  example: H feed_forward_weight:65,60,60    (R,P,Y)
- PID component "AXISF" has been added for all axes. Should be handled like P, I and D values.
- PidSum calculation needs to include F.

Needs LUA script support
- Support the renamed "setpoint_relax_ratio".
- Support for feedforward weight on all 3 axes.

Open code issues:
- rc_adjustments.c - support for adjusting feedforward weight for all axes. Currently only supporting roll - needs coordination with BFC.
2018-07-21 10:26:23 -04:00
Michael Keller 625b23915e
Merge pull request #6220 from ctzsnooze/AG_New
Improved anti-gravity
2018-07-22 02:06:31 +12:00
ctzsnooze ad9197ca6a Dynamic Notch Filter Update
Improves performance of the dynamic notch filter, increasing peak accuracy over a wider band of frequencies, and generally using a narrower, higher notch.
Details:
- FFT now operates on gyro data *after* gyro notches and lowpasses
- FFT bandpass Q changed from 0.707 to 0.05, to 'open up' the FFT to a greater range of incoming frequencies
- FFT centre output now ranges from about 130 to 666Hz.
- ignore the lowest couple of FFT bins going into centre frequency calculation
- analyse FFT bins from low to high, keep ignoring bins until a bin is found that exceeds its previous bin by a factor of 2; then start examining bins from the bin before that (stops the FFT from being biased low, or going to the lowest value if there is no notch at all).
- if no bin exceeds previous by more than 2 times, ie no obvious peak, smoothly go to maximum allowed notch frequency to avoid delay (might be better to bypass filter altogether?)
- dominant bin emphasised by cubing bin height before calculating mean
- maximum cutoff frequency is half the highest allowable centre frequency
- default notch width is +/-25% of centre, narrower than before most of the time
- code tidied up
- thanks to rav, Flint, UAV Tech, icr4sh, diehertz and everyone else who helped with this.
2018-07-21 22:55:41 +10:00
ctzsnooze 36d71d07e7 Dynamic Notch Filter Update
Improves performance of the dynamic notch filter, increasing peak accuracy over a wider band of frequencies, and generally using a narrower, higher notch.
Details:
- FFT now operates on gyro data *after* gyro notches and lowpasses
- FFT bandpass Q changed from 0.707 to 0.05, to 'open up' the FFT to a greater range of incoming frequencies
- FFT centre output now ranges from about 130 to 666Hz.
- ignore the lowest couple of FFT bins going into centre frequency calculation
- analyse FFT bins from low to high, keep ignoring bins until a bin is found that exceeds its previous bin by a factor of 2; then start examining bins from the bin before that (stops the FFT from being biased low, or going to the lowest value if there is no notch at all).
- if no bin exceeds previous by more than 2 times, ie no obvious peak, smoothly go to maximum allowed notch frequency to avoid delay (might be better to bypass filter altogether?)
- dominant bin emphasised by cubing bin height before calculating mean
- maximum cutoff frequency is half the highest allowable centre frequency
- default notch width is +/-25% of centre, narrower than before most of the time
- code tidied up
- thanks to rav, Flint, UAV Tech, icr4sh, diehertz and everyone else who helped with this.
2018-07-21 22:53:07 +10:00