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

309 commits

Author SHA1 Message Date
Kevin Plaizier
078ffafec1
Add 3+ IMU support (Gyro Fusion) (#14383)
* Allow for 3 gyros to be fused at once.

* Handle the case where no GYRO_COUNT is defined

* Fix accel init bug

* Fix bugs found by AI

* Fix compile time assert message

* Move to picking which IMU you want to enable, allow IMU that have the same scale and looprate to run together even if they aren't identical IMU.

* Fully support 8 IMU

* Fix suggestions, except for MSP all suggestions

* Fix bugs found by AI

* Update gyro_init

* Fix unit tests (feels wrong though)

* Allow MSP to update all gyro alignment

* resolve comments

* Only auto set up to 4 gyros in a config.

* Update MSP implementation

* Fix divide by 0 error

* Update src/main/target/common_post.h

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>

* Handle case where gyro 1 does not exist

* Fix 426XX driver

* fix = logic in if statement

* Update src/main/msp/msp.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/drivers/accgyro/accgyro_spi_icm426xx.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Apply ledvinap suggestions

* Fix detectedSensors initialization

* fix getGyroDetectedFlags

* Automatically handle GYRO_COUNT for up to 4 IMU

* better handle unit tests

* Backwards compatible with older config.h files

* Update src/main/sensors/gyro_init.c

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>

* Update src/main/target/common_pre.h

Co-authored-by: nerdCopter <56646290+nerdCopter@users.noreply.github.com>

* Update src/main/sensors/gyro_init.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/sensors/gyro.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* This needs to be the case or unit tests fail, without this we cannot choose default gyro either.

* ledvinap suggestions

* whitespace

---------

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>
Co-authored-by: Petr Ledvina <ledvinap@gmail.com>
Co-authored-by: nerdCopter <56646290+nerdCopter@users.noreply.github.com>
2025-06-23 21:35:11 +02:00
Jay Blackman
4769c2fcdf
PICO: Adding RP2350A MCU (#14437)
- allow for provision of libc
- correction for unused function in msp
2025-06-11 17:10:44 +10:00
mjs1441
8853356e71
Allow for builds with certain features disabled. (#14420)
* Allow for builds with certain features disabled.

Fix build for when the following are disabled:
 USE_DMA
 USE_DSHOT_TELEMETRY
 USE_SERIAL_PASSTHROUGH

* Tweak #ifdef / UNUSED as per code review.
2025-06-04 16:39:45 +02:00
Eric Katzfey
b03b57bd90
Added missing GCC diagnostic push pragma (#14397)
Replaced faulty #pragma GCC diagnostic ignored "-Wunused-function" with the more elegant MAYBE_UNUSED macro
2025-05-21 15:53:43 +02:00
Marc Frank
4ae22e9f8e
hover point throttle curve adjustment (#14229)
* hover point throttle curve adjustment

* Update src/main/fc/rc.c

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>

* Update src/main/fc/rc.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/fc/rc.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* refactor lookup calculation and move hover to end of controlRateConfig_s struct

* moved sbufReadU8 to the bottom

* added sbufBytesRemaining check

* update controlRateProfile version from 6 to 7

* moved thrHover8 declaration position

* revert variable declaration position change

* fixed tests

---------

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>
Co-authored-by: Petr Ledvina <ledvinap@gmail.com>
2025-04-10 14:39:36 +02:00
ctzsnooze
86767ba112
Consistent autopilot variable names, use alt_hold_climb_rate (#14136)
* consistent autopilot parameter names

- add colons after each blackbox header line
- change alt_hold_throttle_response to alt_hold_climb_rate
- don't use cfg abbreviation for apConfig() because it is harder to search

* enforce semicolon with do... while (0)

* don't abbreviate autopilotConfig to apConfig

* remove semicolon after break to enforce semicolon at input line ending

* explanatory message

* fix copy and paste errors

* restore local cfg alias in place of autopilotConfig()

* struct name formatting as requested by blckmn

Co-Authored-By: Jay Blackman <blckmn@users.noreply.github.com>

* underscore the CLI names, fix prev commit

Co-Authored-By: Jay Blackman <blckmn@users.noreply.github.com>

* Update src/main/fc/parameter_names.h

* Update src/main/fc/parameter_names.h

---------

Co-authored-by: Jay Blackman <blckmn@users.noreply.github.com>
Co-authored-by: Mark Haslinghuis <mark@numloq.nl>
2025-02-09 23:34:12 +01:00
Mark Haslinghuis
c2381fb98f
Make number of rate profiles conditional using define (#14239)
* Revert reducing number of rate profiles

* Add CONTROL_RATE_PROFILE_COUNT to STATUS_EX (msp)

* Update src/main/target/common_pre.h

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/test/unit/platform.h

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

---------

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>
2025-02-06 22:11:05 +01:00
Mark Haslinghuis
54cee62699
Fix opticalflow detection (msp) (#14241)
* Fix opticalflow detection (msp)

* Add opticalflow to detected sensors in MSP_STATUS_EX
2025-02-05 21:12:15 +01:00
Mark Haslinghuis
bde342c8cb
Fix PG ID and corruption in MSP_SET_SENSOR_CONFIG (#14230)
* Fix PG ID

* Fix corruption in MSP_SET_SENSOR_CONFIG

* No need to specify ammount of bytes remaining

* Update after review from @ledvinap

* Remove unused PG_BETAFLIGHT_END
2025-02-03 12:07:44 +01:00
Jeff Haynes
79ecc1ac74
Fix MSP memory issue (#14221)
* fixes #14219

* Update src/main/msp/msp.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

---------

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>
2025-02-01 21:59:24 +01:00
Petr Ledvina
b277364b2c
Refactor missing prototypes 2 (#14170) 2025-01-29 06:20:12 +11:00
Jay Blackman
c2768d0409
Refactoring motor to simplify implementation on other platforms (#14156) 2025-01-24 18:37:20 +11:00
Jay Blackman
cec5d00bbf
Remove MCU name table from CLI (rely on build info), add MCU info MSP2 command (#14148) 2025-01-18 04:17:57 +11:00
Mark Haslinghuis
51c09efe69
Add gyro and magnetic custom alignment to MSP (#14019)
* Add magnetic dip and alignment to MSP

* Update PG

* Revert inclination addition

* Revert heading units

* space

* Use MSP_SENSOR_ALIGNMENT

* Missed bracket

* Adjust mag_declination range

* Add gyro custom alignment

* Remove precision from declination

* Revert remove precision from declination
2025-01-09 22:41:41 +01:00
Ivan Efimov
ef81595f1d
Separate autopilot multirotor from autopilot wing - dummy files for wing (#14108)
* separate autopilot multirotor from autopilot wing - dummy files for wing

* fix for lisence header for new files

* filling empty PG structures with uint8_t dummy
2024-12-30 22:36:33 +01:00
Jay Blackman
31bd403446
Adding support for UART0 (#14094) 2024-12-28 16:55:15 +11:00
Petr Ledvina
ac82d8b998
Refactoring of PR 13050 - support for custom OSD messages from external device (#14097) 2024-12-22 15:44:08 +11:00
ahmedsalah52
d244239f39
opticalflow mt sensor added (#14038)
* opticalflow mt sensor added

* set the processedFlow to raw when no rotation

* use sin and cos approximations

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/sensors/opticalflow.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* refactoring

* not needed anymore

* update

* Update src/main/sensors/opticalflow.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/sensors/opticalflow.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/drivers/rangefinder/rangefinder_lidarmt.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* update

* rm prototype

* clean up

* Update src/main/drivers/opticalflow/opticalflow.h

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/drivers/opticalflow/opticalflow.h

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>

* update flip_y

* Update src/main/drivers/opticalflow/opticalflow.h

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/drivers/rangefinder/rangefinder_lidarmt.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/drivers/rangefinder/rangefinder_lidarmt.h

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/sensors/opticalflow.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/sensors/opticalflow.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/sensors/opticalflow.c

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>

* rm casting

* update op rotation

---------

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>
Co-authored-by: Mark Haslinghuis <mark@numloq.nl>
2024-12-21 05:47:36 +11:00
Mark Haslinghuis
2426f43502
Update external defines for ALT / POS HOLD (#14069)
* Update external defines for ALT / POS HOLD

* Update unit test define
2024-12-08 16:23:38 +01:00
Mark Haslinghuis
4b78aeec51
Fix arming disable flag and OSD warning buffer size (#14057)
* Fix missing arming disable flag

* Add test for array length

* Fix array init && add getter

* armingDisableFlagNames is no longer external

* Update array

* Thanks ledvinap

* Revert designated initializers

* Increase OSD Warnings buffer size

* Remove standard libraries

* Refactor

* Update pos

* Restore comment

* Micro optimize

* Extract condition

* Another optimization

* Use cmpTimeUs (not cmp32)

* Revert STATIC ASSERT string change

* Adjust esc sensor warning

* I like this

* Optimize intended minimum width

* revert Optimize intended minimum width

* Is dshot telemetry and esc telemetry exclusive

* Fix conflict

* OSD - WARNINGS_PREFERRED_SIZE

* OSD - Return NONE for no flag
2024-12-06 15:33:25 +01:00
ctzsnooze
3138141cd1
Position hold for 4.6 and Altitude Hold updates (#13975)
* autopilot naming, function sharing
* initial position hold setup
* get current gps location
* first position hold draft
* basic control scheme
* add debug values for testing
* first working example with smoothed acceleration
* add deadbands
* Re-organise included files and functions thanks Karate
* revise PID gains
* PIDJ distance controller, not velocity based. Remove airmode check
* sanity check notes
* fix pid bug and improve iTerm handling
* calculate PIDs independently for each axis, increas DJ gains
* adjust pids and smoothing; smoothing cutoff to settings
* force iTerm to zero when close to target
* allow earth referencing in alt and pos hold
* stop activation until throttle raised, but not require airmode
use wasThrottleRaised in place of isAirmodeActivated where airmode isn't really needed
* remove unnecessary debug
* block arming if poshold or althold switches are on
* basic sanity check and OSD warning
* allow user to fly without mag only if they reverse the default
* separate alt and pos hold deadbands
if poshold deadband is zero, sticks are ignored
if user tries to enable posHold and it can't work, they get stick with a deadband
* try to prevent position hold if no mag without valid IMU
fixes a bug in the last commit, also
* retaisn iTerm just attenuate the output
* struct for values
* reset position at start when slowed down, retain rotated iTerm back
* resolve bounceback and remove iTerm attenuation
* adjust PID gains to 30
* force unit tests sto work
* tidy up after merge
* Use mpif
* conditionally only do compass check if Mag is defined
* fixe defines and remove const
* comments to explain strange rc multiplier
* fix small omission when refactoring after throttle raised PR
* licence updates, refactoring from review comments
* fix issues when pos hold deadband is set to zero
* A for acceleration element, not J
* compact the posHoldUpdate() function - thanks K
* rename showPosHoldWarning to posHoldFailure
* Use a function in gps.c to initate the posHold activity on new GPS data
* Use autopilotAngle in place of posHoldAngle
* separate function for gpsHeading truth
* use FLIGHT_MODE(POS_HOLD_MODE) in place of isPosHoldRequested
* removed non-required definitions
* fix failure to initiate position hold from error in ifdef
* refactoring from reviews, rename posHoldReset
* move deadbands for pos and alt hold to their config files.
* comment
* fix for blackbox breakup of GPS values
reverts use a function in gps.c to initate the posHold activity on new GPS data
* fix for msp change for posHoldConfig
* try to constrain aggressiveness at start, smaller deadband
* allow greater overshoot at the start for high incoming speed
rename justStarted to isDeceleratingAtStart
* dynamically update smoothing at the start
* retain iTerm when moving sticks, to keep attitude in the wind
* fix unit tests
* finally retain iTerm correctly while moving sticks, but reset at start
* Fix iTerm reset and parameter rotation
* absolute rotation vs incremental rotation, fix spike after resetting target location
* don't rotate D or A, it reverses their sign inappropriately
* Block yaw, allow in CLI, option to apply yaw correction code
* restore debug
* calc D from groundspeed and drift angle
* add back some target based D
* Earth Frame iTerm vector
appears to work :-)
* fix unit test
* lower PID gains, slowly leak iTerm while sticks move
* earth ref Dterm, not from GPS Speed
smoother than using GPS Speed and heading
* stronger PIDs
* adjust debug
* shoehorn the unit tests
* Proper earth referencing, at last
* clean up a bit
* no need to duplicate wrapping done in sin_approx
* add note about PT1 gain on PT2 filters
* avoid unnecessary float conversions
* Remove unnecessary CLI testing params
* update PID gains, stronger tilt angle correction
* improved distance to target. thanks to demvlad
* Terminate start individually on each axis
added comments
* refactoring to avoid code duplication
* implement reviews, reduce PID gains
* upsampling filter at 5Hz
* warn if posHold mode requested but throttle not above airmode activation point
* disable angle feedforward in position hold
* rebase, pass unit test
* sequential PT1's, refactoring from reviews
* PID and filter revision
* bane of my life
* lenient sanity check, message for noMag, possible DA vector limit code
* replace angleTarget in pid.c only when autopilot is active
* rearrange status checks
* fix debug, tidy up EF axis names, add comments about sign and direction
* stop more cleanly, easier sanity check, phases, debugs complete
* extend sanity check distance while sticks move; refactor; comments
* fix instability on hard stop, allow activation after arming but before takeoff
* make altHoldState_t  local, getter to pass unit tests.
* hopefully the last cleanup of this test file
* implement review from PL - thank you!
* restore angle limiting in pid.c , max of 80 degrees allowed in CLI
* fixes after review changes weren't right
* fix braces
* limit max angle to 50 by vector length
* Fix curly brackets, comments and debug mistake
* in autopilot modes, allow up to 85 deg for pos hold
* limit pilot angle in position hold to half the configured position hold angle
* use smaller of angle_limit or half the autopilot limit
* increase alt_hold sensitivity 5x and narrow deadband to 20
* make altitude control 5x stronger with narrower deadband and new name
* add suggestions from recent reviews
* start autopilot gpsStamp at 0
* renaming variables
* reset the upsampling filters when resetting position control
* improved gpsStamp thanks PL
Also cleanup names and notes
* simplify altitude control
* rename to GPS_distances  to GPS_latLongVectors
* alt_hold respect zero deadband, hold when throttle is zero
* remove unused debug
* fix unit test
* re-name variables in alt_hold and update comments
* more flexible limit on target vs current altitude
* updates from reviews, thanks karate
* review changes from PL
* more updates from PL review
* rationalise GPS_latLongVectors
* remove static newGpsData and rescueThrottle
* Thanks, PL, for your review
* Modifications, but has a big twitch when sticks stop
* Re-naming, fix the twitch, minor changes
* remove unnecessary unit test reference
* sanity dist to 10m at full stop, send task interval for upsampling filter
* vector and parameter re-name
Co-Authored-By: Jan Post <19867640+KarateBrot@users.noreply.github.com>
* small changes from review
Co-Authored-By: Mark Haslinghuis <8344830+haslinghuis@users.noreply.github.com>
Co-Authored-By: Petr Ledvina <2318015+ledvinap@users.noreply.github.com>
* comment PL
Co-Authored-By: Petr Ledvina <2318015+ledvinap@users.noreply.github.com>
* fix ltm alt_hold flightMode
* NOINLINE some pid.c functions
* Revert "NOINLINE some pid.c functions"
This reverts commit 56a3f7cec2.
* fast_code_pref the wing functions in pid.c
* use fast_code_pref where won't break the build
* apply fast_code_pref correctly
* NOINLINE some pid.c functions
FAST_CODE_PREF for updatePIDAudio
add comment to FAST_CODE_PREF
FIx platform.h unit test issue
Wing functions all FAST_CODE_PREF
* revert FAST_CODE_PREF changes
* Reduce ITCM RAM footprint considerably
* multiple name changes and some refactoring
Thanks, PL
* small editorial change
* refactoring, thanks PL
Co-Authored-By: Petr Ledvina <2318015+ledvinap@users.noreply.github.com>
* 64 bytes to check crossing 180 deg longitude
Co-Authored-By: Petr Ledvina <2318015+ledvinap@users.noreply.github.com>
* try to fix build error
Co-Authored-By: Petr Ledvina <2318015+ledvinap@users.noreply.github.com>
* Revert "try to fix build error"
This reverts commit f926d26021.
* just guessing here
* Revert "just guessing here"
This reverts commit ebc240a325.
* use a null location at initialisation
* Revert "use a null location at initialisation"
This reverts commit b51ae1395d.
* revert more compact initialisation code due to SITL error otherwise
* fix wrapping when 180 lon meridian is crossed
* null location option from PL
* Revert "null location option from PL"
This reverts commit ad40e979bd.
* refactor PosHold start/stop code
* move Alt_Hold and Pos_Hold warnings ahead of Angle, update some comments
* use setTargetLocationByAxis, fix comments
* change from karatebrot review
Co-Authored-By: Jan Post <19867640+KarateBrot@users.noreply.github.com>
* things still to do
Co-Authored-By: Jan Post <19867640+KarateBrot@users.noreply.github.com>
* keep warning strings 12 or less characters
Co-Authored-By: Jan Post <19867640+KarateBrot@users.noreply.github.com>
* a few more
Co-Authored-By: Jan Post <19867640+KarateBrot@users.noreply.github.com>

---------

Co-authored-by: Jan Post <19867640+KarateBrot@users.noreply.github.com>
Co-authored-by: Mark Haslinghuis <8344830+haslinghuis@users.noreply.github.com>
Co-authored-by: Petr Ledvina <2318015+ledvinap@users.noreply.github.com>
Co-authored-by: Jay Blackman <blckmn@users.noreply.github.com>
2024-12-06 13:04:00 +11:00
nerdCopter
ed6a4a4769
duplicate emptyline removal (#14027)
* trailing space removal

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* deduplicate empty lines

---------

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>
Co-authored-by: Mark Haslinghuis <mark@numloq.nl>
2024-11-15 23:07:25 +01:00
ahmedsalah52
b70e98ed5a
MSP Range finder added (#13980)
* MSP Range Finder added (configured and tested on the MTF-01P Lidar)

* MSP Range Finder added (configured and tested on the MTF-01P Lidar)

* fix the license of the added files from INAV

* Update src/main/drivers/rangefinder/rangefinder_virtual.c

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>

* Update src/main/msp/msp.c

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>

* Update src/main/io/rangefinder.h

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>

* Update src/main/msp/msp.c

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>

* refactored the code of INAV for the MSP rangefinder, to be extendable to other MSP rangefinder and more specific about the parameters of the supported ones

* Update src/main/drivers/rangefinder/rangefinder_lidarmt.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/main/drivers/rangefinder/rangefinder_lidarmt.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* refactored the code for readability

* mt lidar msp address

* us the delay MS from the dev directly

* todo

* MT device type datatype

* refactored the code for readability

* spacing

* refactoring

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* refactoring

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* refactoring

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* refactoring

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* refactoring

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* refactoring

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* refactoring

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* refactoring

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* after the edits fix

* rm idx

* typo fixed

* i think this shouldn't be here

* spacing

* Update src/main/drivers/rangefinder/rangefinder_lidarmt.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* fix mt models ranges

* remove mt01p model, it doesn't map

* rm "MT01P", it doesn't support map

* rm mt01p, it doesn't support msp

* Update rangefinder_lidarmt.h

* update mt lidar deadzone

* Update rangefinder_lidarmt.c

* Update rangefinder_lidarmt.c

* rm unused variable mtfConnected

---------

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>
Co-authored-by: Petr Ledvina <ledvinap@gmail.com>
2024-11-12 08:42:20 +11:00
Petr Ledvina
866191dfad
Refactor gps (#13853) 2024-10-24 06:45:17 +11:00
ctzsnooze
58fc8bbbb8
Shared altitude control function in position_control.c (#13954)
* Altitude control code shared

fewer debugs
subtract D

* remove #include comments, simplify coding, restructuring

thanks JP and MH

* fix cms limits for throttle control

* Use altitude_control debug, fix throttle calculation

minor refactoring

* use AUTO_CONTROL_ALTITUDE debug in place of GPS Rescue throttle pid

* use autopilot for position control names

* fixes from reviews - thanks

* Re-organise included files and functions thanks Karate

* missed init and other typos

* remove old unused unit test file, tidy up thanks Mark

* fix indentation on one line
2024-10-16 23:17:44 +02:00
ctzsnooze
5ffeea6ab1
refactor motor idle, rename dshot_idle_value to motor_idle (#13936)
* use idleOffset, simplify idle : check PWM idle

* remove get for dshot idle and calculate it once only

* fixes from reviews, thanks

* use motor_idle for CLI name

* use motorConfig->motorIdle not idleOffset

* rename dshotmotorIdle variable to motorIdlePercent

* small comment improvement
2024-10-08 18:31:08 +02:00
ctzsnooze
16c157e840
Shared altitude control parameters (#13884) 2024-10-05 16:32:50 +10:00
MikeNomatter
908f9cc32d
Remove d min confusion (#13908)
* rename dMin, remove D_MIN_GAIN_MAX

* rename vars

* fix logic

* fix logic

* Revert "fix tests"

This reverts commit c518c9c444.

* Revert "add yaw and other adjustment cases"

This reverts commit 2cacd4b360.

* Revert "fix unit test"

This reverts commit 3d88f4158a.

* Revert "fix D adjustments change dmax instead of D"

This reverts commit 7ee4e7f8af.

* Revert "Fix telemetry for Spektrum/SRXL (#13814)"

This reverts commit 04fe4b4461.

* review adjustments and test fixes

* Reapply "Fix telemetry for Spektrum/SRXL (#13814)"

This reverts commit eb7f8ee0fd.

* fix logic

* Apply suggestions from code review

Co-authored-by: Jan Post <Rm2k-Freak@web.de>
Co-authored-by: Mark Haslinghuis <mark@numloq.nl>

* fix d_max slider

---------

Co-authored-by: Jan Post <Rm2k-Freak@web.de>
Co-authored-by: Mark Haslinghuis <mark@numloq.nl>
2024-09-24 11:28:25 +02:00
Jan Post
f71170db1b
Vector library expansion (#12968) 2024-09-16 07:03:32 +10:00
Petr Ledvina
dab60e3093
MSP - fix buffers in MSP_MULTIPLE_MSP (#13881)
Fix case when MSP command fills all available space
2024-09-07 18:49:09 +02:00
ctzsnooze
254da8f460
Altitude hold for 4.6 (#13816) 2024-09-04 20:29:03 +10:00
Mark Haslinghuis
0819a56d55
Add SPI ELRS Model Match ID (#13774) 2024-07-26 08:05:29 +02:00
J Blackman
5762688f6d
CLEANUP: Move flash drivers to their own directory (#13691)
* CLEANUP: Move flash drivers to their own directory

* Missed flash_w25q128fv.h.

* Directories in #include, and specifying all source files explicitly.

* Revert RX driver src file implicit declaration
2024-06-25 16:24:40 +02:00
Míguel Ángel Mulero Martínez
dc40b8f655
Add RSSI dBm alarm to MSP (#13682)
* Upgrade MSP version to 1.47

* Add RSSI dBm alarm to MSP

* Fix unit test after changing MSP version
2024-06-13 15:05:07 +02:00
Mark Haslinghuis
e60224395e
Add MSP support for gyro_cal_on_first_arm (#13626)
* Add MSP support for gyro_cal_on_first_arm

* Update comment

* Add parameter to MSP

* Fix unit test

* Adjust condition

* Fix unittest instead
2024-05-22 16:38:54 +02:00
Steve Evans
565de1b68b
Use the cached value of useDshotTelemetry to ensure consistent runtime use if dshot_bidir is changed (#13589) 2024-04-28 09:31:50 +10:00
ctzsnooze
5457032838
Use PDOP consistently, since it replaces HDOP (#13477) 2024-04-04 09:08:40 +11:00
Károly Kiripolszky
9f36b400c9
Fix MSP version comment (#13471) 2024-03-26 23:18:49 +01:00
Károly Kiripolszky
9dfa09a07e
Extend build info with defined flags (#13333)
* Extend build info with defined flags

* Fix CI

* Formatting

* Update license header

* Build options (WIP)

* Review fixes

* Add MSP build info generator

* Review fixes

* Add input hash

* Fix for PascalCase

* Add comment about MSP version
2024-03-21 18:29:22 +01:00
Mark Haslinghuis
d84ec8da63
Do not return MSP_RESULT_ERROR when succesful (#13328) 2024-02-04 11:52:52 +01:00
Steve Evans
17e43e3363
Fix OSD defaults based on SD/HD (#13320)
Fix OSD defaults based on SD/HD and validate changing video_system to/from HD
2024-01-23 00:56:25 +01:00
Steve Evans
70e70c5d7b
Scale heading appropriately (#13269) 2024-01-06 12:12:03 +01:00
Mark Haslinghuis
9b078c0b1f
Fix arming when GPS included in build but no active GNSS device attached + revert msp request for SatInfo (#13244)
* Fix arming when GPS included in build but not active

* Fixes per review from Chris

* Move PG change to new PR

* Restore changing GPS PG version
2023-12-28 00:14:02 +01:00
Mark Haslinghuis
22ce586550
Add MSP request for UBLOX SatInfo and disable SatInfo on ARMING. (#13240) 2023-12-25 10:50:34 +11:00
Mark Haslinghuis
58933f9972
Revive MSP message for mag declination (#13232)
Add MSP message for mag declination
2023-12-19 13:26:15 +01:00
Mark Haslinghuis
65aaf732f9
Remove custom defaults and enable features on boot (#13216)
* Remove custom defaults

* Fixes per review

* Fixes per review (thanks ledvinap)

* Fix copy pasta
2023-12-17 07:58:15 +01:00
Flavio Pinzarrone
4c86e31d1e
Fixed incorrect accelerometer scaling in MSP (#13026) 2023-12-04 16:50:08 +01:00
Mark Haslinghuis
b199e65000
Remove unused servos header file (#13182) 2023-12-04 13:21:17 +11:00
Jan Post
5769b3021e
Dshot RPM Telemetry Refactoring (#13012) 2023-12-03 15:16:35 +11:00
Míguel Ángel Mulero Martínez
65357e51bd
Add OSD Link Quality alarm value to the MSP (#13121) 2023-12-02 10:15:37 +01:00