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

15921 commits

Author SHA1 Message Date
Michael Keller
65fb16eb37
Merge pull request #9735 from mikeller/fix_ms5611_spi_baro 2020-04-28 23:06:37 +12:00
mikeller
278ebf3aea Fixed the MS5611 baro in SPI mode. 2020-04-27 00:52:11 +12:00
Michael Keller
212dab7ecd
Merge pull request #9686 from Daemon42/patch-1
Fix rssi_scale formula.
2020-04-25 17:04:55 +12:00
Michael Keller
35e95b2eb7
Merge pull request #9718 from mikeller/added_unified_target_testing_instructions 2020-04-25 17:02:55 +12:00
Michael Keller
8d2e97e529
Merge pull request #9730 from etracer65/fix_arming_disable_rpmfilter_bitbang 2020-04-25 16:59:54 +12:00
Michael Keller
393a432927
Merge pull request #9728 from etracer65/dynamic_idle_rpmfilter_check 2020-04-25 12:56:23 +12:00
Bruce Luckcuck
62adae7374 Fix ARMING_DISABLED_RPMFILTER when DSHOT bitbang is enabled
The function that checks for each motor having valid telemetry broke with the implementation of bitbang. Effectively the motor count was zero and this caused the logic to fall through with a false-positive. The check relied on a local motor count that was set when the PWM dshot was initialized. When bitbang is active this initialization no longer runs and the motor count was defaulting to zero. This was missed in the bitbang implementation.

Fixed to get the motor count from a common source initialized by both timer and bitbang dshot.

Also changed the logic to prevent a false-positive fallthrough if the motor count is zero (shouldn't happen).
2020-04-23 19:50:35 -04:00
Bruce Luckcuck
5b3fd2d08f Disable dynmaic idle if RPM filter is not enabled
The addition of previous checks of bidirectional DSHOT being enabled were not sufficient. Additionally RPM filter must also be active (harmonics > 0) for dynamic idle to determine the minimum motor RPM and function correctly.
2020-04-22 20:36:54 -04:00
Michael Keller
bf9cc615c5
Merge pull request #9720 from codecae/crsf_displayport_init_fix
Relocated CRSF CMS display port init from telemetry to fc
2020-04-23 00:39:08 +12:00
Michael Keller
1d8a0e9fd6
Merge pull request #9723 from rvdveen/lagged-avg-init-fix
Zero the movingSum and buffer for laggedMovingAverage to fix ff_interpolate_sp switches
2020-04-22 01:47:16 +12:00
Roy van der Veen
0d2920423b Zero the movingSum and buffer for laggedMovingAverage to prevent persistent error from being introduced on re-initialization 2020-04-20 17:21:01 +02:00
Michael Keller
10bac1fd17
Merge pull request #9719 from etracer65/dyn_idle_change_profile_fix
Fix dynamic idle safety issues
2020-04-20 23:13:52 +12:00
Michael Keller
e060a0d507
Merge pull request #9712 from etracer65/fix_blocking_dshot_command
Fix blocking DSHOT commands
2020-04-20 23:07:40 +12:00
Michael Keller
4e3d93f44c
Merge pull request #9715 from mikeller/fix_pull_request_template
Fixed pull request template.
2020-04-20 23:05:35 +12:00
Curtis Bangert
d76465e23a Relocated CMS Displayport init from telemetry to init 2020-04-19 15:48:56 -04:00
Michael Keller
7a856bfe23
Merge pull request #9698 from etracer65/link_quality_alarm_range
Fix osd_link_quality_alarm range
2020-04-20 02:15:42 +12:00
Michael Keller
50fa2b4d71
Merge pull request #9695 from jflyper/bfdev-fix-i2c2-sda-on-F446RE
Fix I2C2 SDA pin def for F446
2020-04-20 02:05:09 +12:00
Michael Keller
0fcd8e9250
Merge pull request #9701 from tstibor/fix_sizeof_ticker_chr_count
Determine correct size of TICKER_CHARACTER_COUNT
2020-04-20 01:47:03 +12:00
Michael Keller
ee5df72916
Merge pull request #9702 from tstibor/fix_declaration
Make sure function declaration and definition are equal
2020-04-20 01:42:10 +12:00
Bruce Luckcuck
52d0764d17 Fix dynamic idle safety issues
Fixes a problem with dynamic idle not checking for bidirectional DSHOT being enabled. So the code would run but have no RPM data available leading to elevated motor idle.

Fixes a problem with dynamic idle not resetting accumulated static variables that continue to be used when dynamic idle is switched off via a PID profile change. Depending on the state of the variables this could cause excessive motor idle speed. In some cases enough to cause the quad to spontaneously take off on arming or be unable to descend in flight.

Fixes a problem with dynamic idle inappropriately modifying the static `motorOutputLow` that is set based on the chosen motor protocol. Downstream code that relies on this value to determine the acutal motor output range was adversely affected.
2020-04-19 09:12:45 -04:00
Michael Keller
9ae3845919
Merge pull request #9705 from ctzsnooze/Increase-default-yaw-P
Increase default Yaw P to 45
2020-04-20 01:10:37 +12:00
Michael Keller
2451a615ff
Merge pull request #9706 from ctzsnooze/Increase-TPA-start-point-to-1350-from-1250
Increase TPA start point to 35% throttle
2020-04-20 01:09:50 +12:00
Michael Keller
5bf1a1d849
Merge pull request #9707 from ctzsnooze/Enable-expo-on-D-by-default-at-5
Enable expo on the D lowpass filter at 5
2020-04-20 01:08:57 +12:00
Michael Keller
18cc54992d
Merge pull request #9716 from mikeller/add_translators_to_readme
Added instructions for new translators to README.md.
2020-04-20 01:03:01 +12:00
mikeller
bb24002a50 Added point about testing to Unified Target configuration creation instructions. 2020-04-19 02:42:11 +12:00
mikeller
17f9ba291a Added instructions for new translators to README.md. 2020-04-19 02:34:20 +12:00
Michael Keller
4f2a6103bb
Merge pull request #9703 from IllusionFpv/add-rates-type-to-blackbox-header
Add rates_type to blackbox header
2020-04-18 23:53:16 +12:00
Michael Keller
81dd5b28b0
Merge pull request #9696 from mikeller/fix_typo_in_readme
Fixed typo in README.md.
2020-04-18 23:36:46 +12:00
mikeller
276494c7e7 Fixed pull request template. 2020-04-18 19:01:55 +12:00
Michael Keller
7b0f4bde92
Merge pull request #9700 from jflyper/bfdev-h7-fix-timer-irq-handlers
[H7] Fix/add timer IRQ handlers
2020-04-18 18:30:32 +12:00
Bruce Luckcuck
c6c9ba7229 Fix blocking DSHOT commands
Motor and DSHOT refactoring broke blocking DSHOT commands as the check for commands being enabled was not taking into account that "blocking" type commands need to operate only when the motors are not enabled.

Fixes the CLI `dshotprog` command.
2020-04-17 08:29:24 -04:00
ctzsnooze
a3091751fe Enables expo on the D lowpass filter at 5
Most people who have tested IllusionFPV's expo on the dynamic D lowpass filter have found it to improve propwash without adverse effects.

It achieves this reducing D lowpass delay more quickly on throttling up.

This allows us to retain, at idle, the strong lowpass filtering we currently have, but quickly reduce lowpass delay and improve propwash by mid throttle.

A value of 5-7 is OK I'm proposing 5 as a conservative start.

I know this is a new feature but it is really good .  It would be great if it could be made active by default, if possible, in 4.2.
2020-04-15 10:28:29 +10:00
ctzsnooze
502f74b30a Increase TPA start point to 35% throttle
This should allow more D around the typical propwash points without adverse effects.  Probably 1250 was a bit too low.
2020-04-15 10:21:40 +10:00
ctzsnooze
9c99eed602 Default Yaw P to 45 2020-04-14 17:38:57 +10:00
Nicola De Pasquale
05dc3045ae add rates_type to blackbox header 2020-04-14 01:18:31 +02:00
Thomas Stibor
4e464058b2 Make sure function declaration and definition are equal 2020-04-13 19:33:14 +02:00
Thomas Stibor
bcc8a05978 Determine correct size of TICKER_CHARACTER_COUNT
Since tickerCharacters is a char pointer rather than a char array the
result is: sizeof(8) / sizeof(1).
However, desired
result is: sizeof(5) / sizeof(1).

See also following example:

const char *tickerCharacters = "|/-\\";
const char _tickerCharacters[] = "|/-\\";

int main(void)
{
	printf("%zu\n", (sizeof(tickerCharacters) / sizeof(char)));
	printf("%zu\n", (sizeof(_tickerCharacters) / sizeof(char)));

	return 0;
}

> gcc test.c -o test && ./test
8
5
2020-04-13 19:21:22 +02:00
jflyper
cbd9b0b599 Fix I2C2 SDA pin def for F446 2020-04-13 18:38:54 +09:00
jflyper
b291bc804c [H7] Fix/add timer IRQ handlers 2020-04-13 16:33:14 +09:00
Michael Keller
fde6c680b3
Merge pull request #9694 from etracer65/pid_process_denom_default_v2
Revise pid_process_denom default logic - 2nd try
2020-04-13 15:25:17 +12:00
Michael Keller
568c31a4f2
Merge pull request #9689 from mikeller/fix_missing_linefeed
Added missing linefeed after version in CLI.
2020-04-13 13:10:50 +12:00
Bruce Luckcuck
24849bce0e Fix link_quality_alarm range
This was missed during the transition to CRSF using a 0-100 range instead of 0-300.
2020-04-12 20:46:47 -04:00
mikeller
fa4275603e Fixed typo in README.md. 2020-04-13 01:27:31 +12:00
Michael Keller
a2aa3f19f4
Merge pull request #9684 from etracer65/fix_cms_task_rate
Fix CMS task rate; correct cmsDeviceCount logic; coding style cleanup
2020-04-12 17:33:04 +12:00
mikeller
547f161d27 Added missing linefeed after version in CLI. 2020-04-12 15:18:45 +12:00
Bruce Luckcuck
fb034c22e7 Revise pid_process_denom default logic - 2nd try
Now with the motor protocol defaulting to DISABLED we can reimplement this.

Remove dependence on gyro type and base on MCU type.

The previous logic was based on expecting an 8K sampling gyro and would set an inappropriate loop time for other gyro types.

Change the logic to be based on the capabilities of the MCU which is more appropriate. We set the pid_process_denom default to the maximum recommended value for a given MCU.

The `pid_process_denom` will be defaulted as follows (assuming a 8khz gyro) based on MCU type:

MCU	`pid_process_denom`
F1:	8 (1khz)
F3:	4 (2khz)
F411:	2 (4khz)
Others:	1 (8khz)

Of course the final PID loop rate will be based on the native sample rate of the gyro.
2020-04-11 20:23:43 -04:00
Ian
be791cb14f
Fix rssi_scale formula.
Change * to / in 
rssi_scale = 100 * 1000 / (rssi_fullsig - rssi_nosig)
to keep the scale near 100 instead of 100000..
2020-04-11 00:22:06 -06:00
Michael Keller
2101326a1d
Merge pull request #9619 from mikeller/add_motor_protocol_disabled
Added 'disabled' motor protocol and made it the default.
2020-04-11 12:41:18 +12:00
Michael Keller
5be62ca162
Merge pull request #9653 from mikeller/cli_print_custom_defaults_data
Parse and print custom defaults header data in CLI.
2020-04-11 12:29:13 +12:00
Michael Keller
337f176a11
Merge pull request #9675 from mikeller/fix_gyro_detection_time
Fixed unnecessarily long startup time due to gyro detection.
2020-04-11 12:28:53 +12:00