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

8559 commits

Author SHA1 Message Date
Michael Keller
6e44173f86
Fixed missed naming changes. (#5738) 2018-04-21 18:35:59 +12:00
Andrey Mironov
ff4c2bc145 Post-cleanup of F7 optimizations (#5729)
* Moved ART Prefetch enabling from library to main code

* Fixed tabs to spaces

* Added F7 LL EX header to simplify work with DMA and TIM

* Refactored F7 DSHOT using LL EX

* Got rid of overlooked duplicate lines
2018-04-21 18:14:35 +12:00
pulquero
a51bea1ebc Fixes to ranges of esc warning thresholds. (#5726)
Signed-off-by: Mark Hale <mark.hale@physics.org>
2018-04-21 18:12:11 +12:00
Miroslav Drbal [ApoC]
4968352446 Fixing the #5705 (D-Term spikes) (#5728)
* * Fixing the #5705 (D-Term spikes)
  - For D-Term calculation I reverted back to use dT instead of jittery deltaT
  - Moved calculation of deltaT to handleItermRotation because it is the only place now where it is used

* * Changed the constant expression per DieHertz request

* * Changed the type of argument to match the type from caller

* * Redone also the handleItermRotation to dT per @ledvinap request
2018-04-21 12:09:13 +12:00
jflyper
0306accf6e FLASH Add W25M homogeneous stack driver and W25M512 support (#5722)
* Winbond W25M homogeneous mode driver

* W25M512 support on OMNIBUSF4 variants
2018-04-20 16:37:48 +12:00
jflyper
e97496713a
Merge pull request #5721 from jflyper/bfdev-omnibusf4sd-onboard-flash
OMNIBUSF4SD Add onboard flash support
2018-04-20 07:52:17 +09:00
Andrey Mironov
bee2bacb66
Fixed ownership of MPU_CS resource in case of multiple gyros (#5715) 2018-04-20 00:13:28 +03:00
Andrey Mironov
bf984f39b1 F7 optimizations (#5674)
* Revert "Revert "Rewritten F7 dshot to LL (draft)" (#5430)"

This reverts commit aa42a69d2f.

* Reworked F7 linker scripts to maximize performance of both F74x and F72x

* Some comments and changes from original F7 HAL DSHOT

* Prohibit inlining of some functions to place them in ITCM-RAM

* Fixed usartTargetConfigure implicit declaration

* Moved back to SRAM1 as main RAM

* Added SRAM2 attribute

* Fixed LL DSHOT FOR SPRF7DUAL and probably other adv TIM users

* Fixed SPRF7DUAL rev. A motor order

* Enabled CCM for data on F40x

* Fixed F7 startup assembly symbols

* Fixed KISSFCV2F7 linker script

* Added a quick way of building F7 targets only

* Got rid of the useless F7 target script

* Added NOINLINE and got rid of useless __APPLE__ define

* Added some important functions to ITCM

* Added NOINLINE macro for tests

* Copy to ITCM before passing execution into it

* Minimized cache footprint of motor output code

* Evicted low-impact functions from ITCM

* Switched MATEKF722 and SPRACINGF7DUAL to burst DSHOT

* Switched CLRACINGF7 to burst DSHOT

* Moved UART RX&TX buffers to DTCM-RAM to avoid cache incoherency

* Marked taskMainPidLoop for ITCM-RAM, disallowed inlining per-function

* Revert "Added a quick way of building F7 targets only"

This reverts commit 2294518998.
2018-04-20 08:37:32 +12:00
Charles K Stevenson
39fec69fb0 Target update: AlienWhoop V2.1 blackbox via dataflash (#5723) 2018-04-20 08:02:43 +12:00
Michael Keller
fb3b41ca0e
Fixed condition in BEEBRAIN target.mk. (#5717) 2018-04-20 07:57:43 +12:00
jflyper
f9f05ecad5 FLASH Full (re)configurability (#5720) 2018-04-20 07:55:17 +12:00
Michael Keller
6b632bf65e
Added timer for PA3 (PPM in) for OMNIBUSF7. (#5716) 2018-04-20 07:52:36 +12:00
jflyper
08997fa62e OMNIBUSF4SD Add onboard flash support 2018-04-19 22:35:29 +09:00
Andrey Mironov
0f6d4a2def Fixed a typo in HMC5883L driver for F7 (#5714) 2018-04-19 22:16:12 +12:00
Alberto García Hierro
e192f82fcc Don't make the report_cell_voltage setting depend on IBUS (#5711)
report_cell_voltage was only compiled in when IBUS was enabled, but
it's used for several telemetry protocols. Now it only depends on
USE_TELEMETRY.
2018-04-19 21:06:39 +12:00
Michael Keller
0fd6d5d74e
Fixed priority of RSSI validation: ADC / RX channel / frame errors. (#5703) 2018-04-19 21:06:21 +12:00
jflyper
864dba98c1 Prepare flash code for multiple device type support (#5683)
* Prepare flash drivers for multiple device type support

* Add static assertions on device page and flashfs alloc sizes.
2018-04-19 21:05:42 +12:00
chibaron
4a5e79a534 add target BeeStorm (#5662)
* add target BeeStorm

* Revert "add target BeeStorm"

This reverts commit 834a186da7.

* derived model of BEEBRAIN_V2F
2018-04-19 01:39:25 +12:00
Michael Keller
b2c247d34a
Added USB VCP detect and debugging. (#5689) 2018-04-18 01:22:46 +12:00
pulquero
a86aaeebd1 Improve ESC warning message and include current threshold check. (#5685)
Signed-off-by: Mark Hale <mark.hale@physics.org>
2018-04-18 00:25:36 +12:00
SteveCEvans
6f088d0fd2 Add PID adjustment from AUX transmitter channel (#5584)
* Scale PIDs using aux channels

* Add control via variables and documentation

* Use USE_TXPID

* Removed OWNER_TXPID

* Use PWM_RANGE_MIDDLE

* Fix typos

* Move Tx PID arrays into pidProfile_t

* Move macro to pidUpdateRate function

* Enable TXPID on REVONANO

* Add support for direct setting of adjustments from aux channel

* Change variable name from adjustmentScale to adjustmentScale to avoid confusion

* Update documentation

* Change variable name from adjustmentScale to adjustmentScale to avoid confusion

* Only adjust settings if adjustment channel has changed value

* Fix formatting

* Use pidAudioModes_e type in ADJUSTMENT_PID_AUDIO setting. Only allow absolute override of settings of ADJUSTMENT_MODE_STEP.

* Add example 6

* Fix checking of adjustment mode

* Fix USE_PID_AUDIO code. Broke SPRACINGF7DUAL.
2018-04-18 00:23:44 +12:00
Michael Keller
a1d10b49f4
Reduced firmware size for OMNIBUS and RCEXPLORERF3. (#5699) 2018-04-17 07:26:15 +12:00
Andrey Mironov
f24941feb7
Constrained D-term transition upper-bound (#5701) 2018-04-16 16:45:25 +03:00
Michael Keller
c3a534f800
Fix for blackbox I interval to be 32 ms even if PID denom isn't 1. (#5688) 2018-04-16 22:40:38 +12:00
jflyper
0cb6205f05 Don't call flashfsGetOffset if device is not found or unsupported. (#5684) 2018-04-16 22:32:58 +12:00
Míguel Ángel Mulero Martínez
4e024f5467 Fix MSP Flash FS supported (#5670) 2018-04-15 12:29:49 +12:00
jflyper
0ae84bebb4 Per mikeller's comment. 2018-04-13 02:59:17 +09:00
jflyper
4adc5e0ed2 Drop VBUS_SENSING_ENABLED handling in usb_bsp.c 2018-04-13 02:37:32 +09:00
jflyper
17f0554cad Oops 2018-04-13 02:31:18 +09:00
jflyper
3983902efb Convert target.h 2018-04-13 02:17:09 +09:00
jflyper
78bc3f52ad Disable VBUSSENSING features on PA9 completely 2018-04-13 02:07:58 +09:00
Michael Keller
fbd8f07440
Fixed help text for 'diff defaults'. (#5668) 2018-04-11 23:32:32 +12:00
Michael Keller
e0dcea4d48
Added checks for ESC_SENSOR feature being enabled when reading ESC sensor data. (#5663) 2018-04-11 23:31:14 +12:00
Michael Keller
6cfec6fc53
Added config checks for the RSSI config. (#5644) 2018-04-11 19:31:57 +12:00
jflyper
d749879cf6 FAT emulation of onboard flash for MSC (#5650) 2018-04-11 11:29:56 +12:00
Andrey Mironov
c305833c8b Correct pinout for REVOLTOSD and moved M3&4 to TIM2 (#5665) 2018-04-11 08:54:56 +12:00
Miroslav Drbal [ApoC]
045557561d Optimized the PID loop a little bit (#5661)
* * Put PID variables into the structure
* Precalculate DTerm gyro filter outside the axis loop
* Removed unused variables PIDweight[3], airmodeWasActivated
* If zero throttle or gyro overflow, we can just set values and exit, this saves checks and jumps in axis loop
* Compute PIDSUM after the axis loop, this saves branching inside the loop because of Yaw has no D term

* * Incorporated review changes from DieHertz and fujin

* * Incorporated another review requests from DieHertz
  - PidSum renamed to Sum
  - pidData[3] redone to pidData[XYZ_AXIS_COUNT]
2018-04-11 08:22:51 +12:00
SteveCEvans
696478d04c Fix CDC class buffer length validation (#5659)
* Fix CDC class buffer length validation

* Use sizeof (<variable>) rather than sizeof (<type>)

* Use sizeof (<variable>) rather than sizeof (<type>)
2018-04-10 08:58:54 +12:00
Míguel Ángel Mulero Martínez
802edf236b Fix Blackbox P interval (#5645) 2018-04-10 00:35:54 +12:00
jflyper
2811171ea3 Prepare MSC for simultaneous multiple storages 2018-04-09 11:18:59 +09:00
jflyper
4a314613d8
Merge pull request #5649 from jflyper/bdev-msc-white-space-tidy-2
MSC support code: White space tidy
2018-04-09 11:14:33 +09:00
pulquero
247766c30e Expose ESC telemetry over smart port. (#5651)
Signed-off-by: Mark Hale <mark.hale@physics.org>
2018-04-08 14:34:32 +12:00
jflyper
9a25d84ed3 White space tidy 2018-04-08 08:43:30 +09:00
Michael Keller
7a6e2db387
Reduced BETAFLIGHTF3 flash size. (#5648) 2018-04-08 10:02:40 +12:00
pulquero
e3db75176d Expose ESC telemetry over smart port. (#5581)
Signed-off-by: Mark Hale <mark.hale@physics.org>
2018-04-08 08:57:49 +12:00
Bruce Luckcuck
9a7533f57d Expose vbat ADC divider and multiplier parameters in CLI (#5641)
Previously only vbat_scale was exposed. Adds vbat_divider and vbat_multiplier parameters.

Note that all of these parameters only apply to the first voltage sensor (VOLTAGE_SENSOR_ADC_VBAT).  There is the capability to have multiple sensors and those will not have their parameters exposed.  Currently there are no target definitions that use multiple sensors.
2018-04-07 12:26:16 +12:00
Bryce Johnson
588addd6dd added crashflip_motor_percent. This will use the other motors while doing a turtle. (#5600) 2018-04-06 20:24:48 +12:00
borisbstyle
3663230803 Cleanup PID controller function (#5631) 2018-04-06 20:23:57 +12:00
Bruce Luckcuck
630e5d09a2 Enable USE_BRUSHED_ESC_AUTODETECT for all targets (#5637)
Without this a target that didn't specifically specify brushed motors would initialize to Oneshot125 on a firmware reset and this signal is sufficient to act a as a PWM source for brushed motors making them spin on power up.

With the proliferation of some targets (REVO, OMNIBUS, etc.) there are now many brushed variants that are at risk.
2018-04-06 19:51:32 +12:00
borisbstyle
d576354e7d
Merge pull request #5633 from betaflight/mixer_cleanup
Cleanup mixTable
2018-04-06 09:18:58 +02:00