1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-16 12:55:19 +03:00
Commit graph

1624 commits

Author SHA1 Message Date
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
Nicholas Sherlock
bcadd0803a Merge pull request #624 from ledvinap/improvement-blackbox
Simplify Blackbox code by improving printf() and using that instead of longer more specialised code
2015-03-17 22:30:21 +13:00
Petr Ledvina
35ef95cec7 blackbox - support arrays greater that 10 elements / use printf to print numbers 2015-03-17 09:34:52 +01:00
Petr Ledvina
8d2dc82f4b blackboxPrintf - return number of characters written
change fmt to `const char*`
2015-03-17 09:33:16 +01:00
Petr Ledvina
c90231f35c printf - implement '%n' 2015-03-17 09:27:54 +01:00
Petr Ledvina
ae67870db1 Modify prinf-like functions to return number of characters written 2015-03-17 09:27:19 +01:00
Dominic Clifton
8e6570754c Add the first unit test for the mixer.
See #16
2015-03-16 22:56:14 +01:00
Dominic Clifton
1e7fb08b9d Ensure failsafe is not reset when using stale serial rx channel data. 2015-03-15 22:05:54 +01:00
Dominic Clifton
e08c83fdc9 Use the same pattern for cleaning the frame complete flag in spektrum
and xbus driver as used in sbus/sumd/sumh drivers.

Very minor performance optimization too since the flag is only checked
once per main loop instead of once per channel read.
2015-03-15 00:02:45 +01:00
Dominic Clifton
7d6e4aa390 Updating the SerialRX drivers so they can report back a failsafe
condition.  Improve SumD driver, when a failsafe is detected the values
from the frame will be used (same behaviour as SBus when SBus RX reports
failsafe).
2015-03-14 23:28:38 +01:00
Dominic Clifton
6059089bb6 Fix disabling of acc and mag sensors.
Closes #623
2015-03-14 21:01:19 +01:00
Dominic Clifton
4cf6fe6571 Rename 'frsky_hiprec_vfas' to 'frsky_vfas_precision' and introduce enum
for FRSKY_VFAS_PRECISION_LOW and FRSKY_VFAS_PRECISION_HIGH.

Improves naming for humans.  'hiprec' was meaningless and
untranslatable. See
https://cleancoders.com/episode/clean-code-episode-2/show
2015-03-13 23:49:24 +01:00
Dominic Clifton
d82fc6b9be Merge pull request #477 from projectkk2glider/projectkk2glider/issue_316_frsky_voltages
Fixes #316: better arithmetics for FrSky CELL voltages, VFAS battery vol...
2015-03-13 23:40:24 +01:00
Dominic Clifton
626bd29dae Merge pull request #592 from sherlockflight/blackbox-serial-baud
Support new 230400 baud rate which allows >750Hz Blackbox logging
2015-03-13 23:24:57 +01:00
Dominic Clifton
ccb1698ba5 Add human readable versions of the serial functions bitmask values to
help non-developers understand.
2015-03-13 22:28:10 +01:00
Dominic Clifton
3b77626dd8 Only enable VBat ADC when VBat feature is enabled.
Fixes #612
2015-03-13 22:28:10 +01:00
Dominic Clifton
8fcffa1454 Merge pull request #616 from ledvinap/fix-small-angle
Fix small_angle type to match CLI
2015-03-13 13:52:06 +01:00
Petr Ledvina
59df4e502b Fix small_angle type to match CLI
int8_t small_angle prevents using angles>128deg (and thus disabling it with small_angle=180)
2015-03-12 15:25:30 +01:00
Dominic Clifton
fce1d5a680 Bump MSP API version for recent MSP_RC_TUNING changes. 2015-03-11 22:40:10 +01:00
Dominic Clifton
f62b5c883d Merge pull request #601 from tricopterY/tricopterY-patch-1
Update serial_msp.c
2015-03-11 20:15:24 +01:00
Dominic Clifton
2c79d777bc Merge pull request #605 from ledvinap/fix-batterytest-merge
Fix incorrect merge in battery_unittest
2015-03-11 08:35:06 +01:00
Nicholas Sherlock
cee021706b Merge remote-tracking branch 'upstream/master' into blackbox-serial-baud 2015-03-11 13:31:30 +13:00
Dominic Clifton
4746b336b9 Tweak to GPS page to show when Space Vehicle updates are received via a
ticker next to the bargraphs which updates each time SV info is
received.

Some code-size improvements optimizations could be done.
2015-03-10 23:01:06 +00:00
Petr Ledvina
f1a0972002 Fix incorrect merge in battery_unittest
batteryConfig initialization was merged twice, removing one version
2015-03-10 08:32:36 +01:00
tricopterY
ced280acb9 Update serial_msp.c
Enhanced MSP_RC_TUNING and MSP_SET_RC_TUNING. Configurator's PID Tuning tab can be enabled to update TPA Breakpoint.  
PID Tuning tab must be enhanced for this feature. Agnostic if older versions of Configurator are used.
2015-03-10 10:40:56 +11:00
Dominic Clifton
bc8e53a9d8 Rename some PID controller methods.
See #461.
2015-03-09 23:26:52 +00:00
Dominic Clifton
d8cd9f239c Merge pull request #437 from tracernz/nmea-satdata
Add NMEA Signal Quality
2015-03-10 00:18:47 +01:00
Dominic Clifton
c0c2f8e285 Remove a suprious newline. 2015-03-09 23:04:54 +00:00
Dominic Clifton
4a12d00d1e Moving mixer config out of the profile. It doesn't really make sense. 2015-03-09 23:00:44 +00:00
Dominic Clifton
ed434fe47b Use a positive named setting and variable instead of a negative one to
simplify the logic and aid understanding.
2015-03-09 22:50:27 +00:00
Dominic Clifton
acabbf41db 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
2015-03-09 23:44:53 +01:00
Dominic Clifton
1b1163da10 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

added cli command disable_pid_at_min_throttle

(same as previous)
2015-03-09 23:42:42 +01: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
e40a3663d2 Remove failsafe vtable usage. 2015-03-09 23:19:21 +01:00
Dominic Clifton
60a95f1d22 Removing noise from unit tests. 2015-03-09 23:19:21 +01:00
Dominic Clifton
bce6c6722c Merge branch 'port-changes' of https://github.com/ledvinap/cleanflight into ledvinap-port-changes
Conflicts:
	src/main/blackbox/blackbox.c
	src/main/io/serial.c
2015-03-09 22:23:04 +01:00
Damjan Adamic
517d38c94f Re #316: Battery voltage calculation converted to integer arithmetic, unit tests updated to account for proper rounding of voltage
Added frsky_hiprec_vfas configuration option that selects how VFAS is sent
Better arithmetics for FrSky CELL voltages, VFAS battery voltage send with other ID that allows 0.1V resolution
2015-03-09 20:43:04 +01:00
Dominic Clifton
9d0e464aaf Updating unit tests to match roll/pid/yaw rate decoupling. 2015-03-08 00:51:29 +00:00
Dominic Clifton
2e5fe06a6a Update AlienWii32 defaults for pitch/roll/yaw rates 2015-03-08 00:48:47 +00: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
26bb86898e Updating comment in mixer.c 2015-03-07 14:15:38 +00:00
Nicholas Sherlock
3b5d2b6a16 Change recommended Blackbox baudrate to 250000
This is because the AVR's 230400 baudrate is very inaccurate, while the
250000 baudrate is spot-on.
2015-03-07 13:07:03 +13:00
Dominic Clifton
4d1060f87b Merge pull request #591 from nebbian/bugfix-tricopter-3d
Bugfix for 3D inverted flight using a tricopter.
2015-03-06 16:49:52 +00:00
Dominic Clifton
e9742c124c Merge pull request #594 from sherlockflight/mag-limit
Fix upper limit on mag_hardware and acc_hardware CLI variables
2015-03-06 16:42:54 +00:00
Nicholas Sherlock
5e917090b6 Merge remote-tracking branch 'upstream/master' into blackbox-serial-baud 2015-03-07 02:01:03 +13:00
Nicholas Sherlock
0c8adf25c2 Use defines for MAG_MAX and ACC_MAX 2015-03-07 01:57:45 +13:00
Nicholas Sherlock
8a541a9fa2 Fix upper limit on mag_hardware and acc_hardware CLI variables 2015-03-07 01:18:05 +13:00
Nicholas Sherlock
99fe3465b2 Support configurable Blackbox baud rates, allows >750Hz logging 2015-03-06 20:08:05 +13:00
Nicholas Sherlock
cbaa67f1d0 Add 230400 & 250000 baud rates, 2 stop-bits port mode 2015-03-06 20:07:07 +13:00