Commit Graph

17566 Commits

Author SHA1 Message Date
Andrew Tridgell
4b33865ee2 AP_Math: fixed inefficient sq() function 2019-02-25 10:52:25 +11:00
Andrew Tridgell
51acb72152 AP_RangeFinder: fixed lightware serial with LW20 lidar
it needs a longer serial write to force it to serial mode from i2c
2019-02-25 10:52:25 +11:00
Andrew Tridgell
3dd4cf4d87 AP_Rangefinder: probe all I2C buses for rangefinders 2019-02-25 10:52:25 +11:00
Andrew Tridgell
a2f0ff7386 Filter: fixed crash on zero cutoff frequency
this fixes #10435
2019-02-25 10:52:25 +11:00
Andrew Tridgell
ba53230f70 HAL_ChibiOS: fixed CAN on Pixhawk4 and PH4-mini
the silent pins floating disabled CAN
2019-01-23 13:26:55 +11:00
Andrew Tridgell
98fa9454ed HAL_ChibiOS: disable USART6_TX on fmuv5
this prevents it acting as a pullup on SBUS input for Pixhawk4. Thanks
to David Sidrane for the suggestion.

This also enables the extra 3 PWMs for PH4-mini
2019-01-18 09:45:46 +11:00
Andrew Tridgell
7040b6c2d7 AP_RCProtocol: on DSM sync error don't reset channel count
this fixes the issue noticed by Andreyl in 3.6.5rc1
2019-01-15 10:41:50 +11:00
Andrew Tridgell
e33d42e659 SITL: added simulated battery for quadplane
needed for motor interference for mag
2019-01-15 10:41:50 +11:00
Michael du Breuil
0a7fc2fd12 AP_HAL_ChibiOS: Fix FMUv2 LED lighting up 2019-01-11 17:46:20 +11:00
Andrew Tridgell
81b5c3a7da HAL_ChibiOS: fixed sdcard build 2019-01-11 13:25:32 +11:00
Andrew Tridgell
12be040da2 AP_BoardConfig: fixed build 2019-01-11 13:15:36 +11:00
Andrew Tridgell
4732266017 HAL_ChibiOS: fixes for DrotekP3Pro 2019-01-11 13:15:33 +11:00
Kevin Lopez Alvarez
2069cff1bf AP_BoardConfig: add ChibiOS FMUv4pro defines 2019-01-11 13:15:31 +11:00
Kevin Lopez Alvarez
6c2cf4ecc0 AP_HAL: add ChibiOS FMUv4pro 2019-01-11 13:15:29 +11:00
Kevin Lopez Alvarez
f350b3ce57 HAL_ChibiOS: add MCU tables for STM32F469 2019-01-11 13:15:23 +11:00
Kevin Lopez Alvarez
3ae1b0d3c3 HAL_ChibiOS: add DrotekP3Pro hardware definitions 2019-01-11 13:15:20 +11:00
Siddharth Purohit
8a64876eb2 HAL_ChibiOS: add CubePurple/PH2Slim board config 2019-01-10 21:35:04 +11:00
Andrew Tridgell
9467e0fa04 AP_RCProtocol: bring up to date with master
this adds new RC protocol decoders for SRXL, SUMD and ST24 as well as
updating to latest soft-serial decoder
2019-01-09 13:52:42 +11:00
Andrew Tridgell
1240b79cc8 DataFlash: allow startup with no microSD
this allows logging to work with insert after boot
2018-12-31 08:15:14 +11:00
Andrew Tridgell
99d0f7a77d HAL_ChibiOS: try to mount microSD after boot 2018-12-31 08:15:12 +11:00
Andrew Tridgell
cf85f25adc HAL_ChibiOS: log stdout to USB on mindpx-v2 2018-12-31 08:15:08 +11:00
Andrew Tridgell
b03024dd34 HAL_ChibiOS: allow mount of microSD after boot
when disarmed, try to mount sd card every 3s
2018-12-31 08:15:05 +11:00
Andrew Tridgell
4d89a2757c HAL_ChibiOS: fixed card inserted test for SDC 2018-12-31 08:15:02 +11:00
Andrew Tridgell
274dc0b9bd AP_BoardConfig: added BRD_SD_SLOWDOWN parameter
allows for reduction in microSD clock speed
2018-12-31 08:14:57 +11:00
Andrew Tridgell
85c3ef229d HAL_ChibiOS: support microSD slowdown
allow use of BRD_SD_SLOWDOWN to slow down clock on microSD
2018-12-31 08:14:53 +11:00
Andrew Tridgell
5a76aa9023 AP_HAL: added set_slowdown() to SPIDevice
used to slow down a SPI device below normal high speed operation
2018-12-31 08:14:50 +11:00
Andrew Tridgell
20f3a92e50 AP_HAL: added fs_init() to Util API 2018-12-31 08:14:47 +11:00
Andrew Tridgell
680caeb349 HAL_ChibiOS: switched fmuv5 firmware to ChibiOS IO fw
so users installing fmuv5 on a Pixhawk4 get the SBUS fixes
2018-12-31 08:14:15 +11:00
Andrew Tridgell
5cac150a91 HAL_ChibiOS: fixed safety switch and LEDs on PH4-mini
fixes #10127
2018-12-31 08:14:10 +11:00
Andrew Tridgell
fe0030947e HAL_ChibiOS: detect stuck I2C bus and clear with SCL
This detects the I2C bus becoming stuck with SDA low after a timeout
and clears the bus by toggling SCL. Many thanks to @jhw84 for the
suggestion
2018-12-14 16:26:53 +11:00
Andrew Tridgell
067de3849c HAL_ChibiOS: added palReadLineMode() function
used to change and restore line modes
2018-12-14 16:26:50 +11:00
Andrew Tridgell
645629baa2 AP_InertialSensor: fixed orientation of 2nd OmnibusF7V2 IMU 2018-12-12 16:28:42 +11:00
Andrew Tridgell
80b9cf09de HAL_ChibiOS: setup PH4 for right voltage scaling 2018-12-09 07:42:59 +11:00
pierre-louis.k
a23c174e24 AP_RangeFinder: Remove range enforcement on out of range 2018-12-09 07:32:49 +11:00
pierre-louis.k
5e328e6276 AP_RangeFinder: Rework function structure in TeraRanger driver 2018-12-09 07:32:46 +11:00
pierre-louis.k
8198235af4 AP_RangeFinder: Rename function in TeraRanger driver 2018-12-09 07:32:44 +11:00
pierre-louis.k
4769055c4a AP_RangeFinder: Give back semaphore on whoami error 2018-12-09 07:32:42 +11:00
pierre-louis.k
92791821c1 AP_RangeFinder: Clean TeraRanger driver 2018-12-09 07:32:39 +11:00
pierre-louis.k
cfd13d4e83 AP_RangeFinder: Add error codes rejection for TeraRanger sensors 2018-12-09 07:32:36 +11:00
Nghia Nguyen
21782835c4 AP_Rangefinder: Add support for Garmin LidarLite-V3HP 2018-12-09 07:31:44 +11:00
Randy Mackay
f408adf696 AP_RangeFinder: check I2C dev during detect 2018-12-09 07:31:32 +11:00
Randy Mackay
6699a44b1b AP_RangeFinder: benewake tfmini always provide cm distances
a misunderstanding of the datasheet led to the mistaken idea that while in short-range-mode the distances were returned in millimeters
2018-12-09 07:30:46 +11:00
Randy Mackay
dfe32e7496 RangeFinder: benewake buffer uses uint8_t 2018-12-09 07:30:44 +11:00
Andrew Tridgell
bbfe147d50 HAL_ChibiOS: use ChibiOS IO firmware for Pixhawk4 2018-11-28 14:49:11 +11:00
Andrew Tridgell
50ad91f00f HAL_ChibiOS: allow ROMFS to override a file
this allows a hwdef.dat with an include to change an embedded file
specified in the include
2018-11-28 09:28:54 +11:00
Randy Mackay
8969926765 AP_RangeFinder: fix benewake checksum check 2018-11-15 17:20:40 +11:00
Randy Mackay
bd96fe6f33 DataFlash: log rangefinder status in RFND msg 2018-11-15 17:20:37 +11:00
Randy Mackay
07bbf75a8b AP_RangeFinder: benewake returns at least 12m or 22m when out-of-range
value logged and shown to the user will be at least 12m for TFmini or 22m for TF02 which ensure the user won't see the range drop even if they have configured a very short useable distance
2018-11-15 17:20:30 +11:00
Randy Mackay
16c4776475 AP_RangeFinder: benewake logic reordering
this should be a non-functional change
2018-11-15 17:20:27 +11:00
Randy Mackay
89f485f32e AP_RangeFinder: benewake lidar returns max range + 1m when out-of-range
also returns out-of-range when signal is weak
2018-11-15 17:20:23 +11:00
Andrew Tridgell
ce1b0fe533 AP_RPM: set pin to input before attaching interrupt
this fixes input on AUX6 on CubeBlack
2018-11-15 17:19:50 +11:00
Andrew Tridgell
0669619cea AP_RCProtocol: fixed DSM parser for 8 channels
this ensures we remember channels from the previous frame, avoiding a
bug with more than 7 channels
2018-11-15 17:19:43 +11:00
Randy Mackay
9485ab8eb8 AP_RangeFinder: Benewake driver discards distances over 327m 2018-11-10 14:04:07 +11:00
Peter Barker
c16a810e89 DataFlash: add sanity checks around EraseAll 2018-11-10 14:04:01 +11:00
Andrew Tridgell
1b4d680749 AP_BoardConfig: updated BRD_PWM_COUNT docs
This reflects the use of this parameter under ChibiOS
2018-11-06 09:07:53 +11:00
Andrew Tridgell
633ba4ef20 HAL_ChibiOS: updated to latest hw definitions from master 2018-11-06 08:44:07 +11:00
Andrew Tridgell
9f8ec3849c AP_IOMCU: fixed a race in event trigger on startup
this fixes the issue with initial safety option state, and with
initial safety mask
2018-11-03 17:30:22 +11:00
Andrew Tridgell
2a743df9f1 HAL_ChibiOS: ensure RC in channels are bounded 2018-11-02 22:51:08 +11:00
Andrew Tridgell
0bb1821e8d AP_Notify: fixed PixracerLED on NuttX
led_dim must be a positive number, and is not related to the led off
value
2018-10-10 12:55:45 +11:00
Andrew Tridgell
5e3c0964eb AP_HAL: fixed PX4 LED polarity 2018-10-10 12:55:41 +11:00
Andrew Tridgell
39e1b3b89f AP_Notify: init gpio state for LEDs 2018-10-10 12:55:39 +11:00
Andrew Tridgell
0f949ba8b2 AP_Notify: fixed px4-v4 to use pixracer LED driver 2018-10-10 12:55:35 +11:00
Andrew Tridgell
ea52df3da4 HAL_ChibiOS: fixed LED mapping for fmuv4 2018-10-10 12:55:29 +11:00
Randy Mackay
e8f0fe770f AP_HAL_ChibiOS: fix safety switch option handling 2018-10-04 16:14:08 +10:00
Andrew Tridgell
bbce83b8b2 HAL_ChibiOS: fixed a race in DShot code
this fixes a problem found by Daniel Met with the copter 3.6 beta
release
2018-10-02 18:49:34 +10:00
Andrew Tridgell
32c5e6bced AP_Compass: fixed handling of duplication rotations
we have some rotations that are duplicated, such as ROLL_180_YAW_90
and PITCH_180_YAW_270. This copes with those in the auto-orientation
code
2018-09-19 13:53:37 +10:00
Andrew Tridgell
e2467a19a5 HAL_ChibiOS: fixed RSSI voltage from IOMCU 2018-09-15 15:45:46 +10:00
Leonard Hall
de45a3d3e5 AC_Loiter: reduce twitch on init 2018-09-15 10:26:23 +10:00
Leonard Hall
8830b2a764 AC_PosControl: reduce glitch on init 2018-09-15 10:25:59 +10:00
Leonard Hall
616ab50938 AC_PID_2D: add reset for filter and D term 2018-09-15 10:24:53 +10:00
Andrew Tridgell
bf21a0153c AC_AttitudeControl: Add missing variable initalisations
# Conflicts:
#	libraries/AC_AttitudeControl/AC_AttitudeControl.cpp
2018-09-15 10:09:05 +10:00
Leonard Hall
88ded7ee67 AC_PID: Fix D term initialisation 2018-09-15 10:08:41 +10:00
Andrew Tridgell
6c17dcd71a AP_Compass: default COMPASS_AUTO_ROT to 2 for all boards
we're confident of this code now
2018-09-14 15:16:13 +10:00
Andrew Tridgell
042265b4c4 AP_AHRS: fixed synthetic airspeed to be along +ve X axis
this prevents us from thinking we have +ve airspeed when flying
backwards with no pitot tube
2018-09-14 10:51:18 +10:00
Andrew Tridgell
820b2386c0 APM_Control: halve the default pitch D term for planes
this is based on feedback from the 3.9.1 release
2018-09-14 07:32:46 +10:00
Andrew Tridgell
cdfef0bbeb HAL_ChibiOS: implement set_failsafe_pwm() 2018-09-13 08:16:10 +10:00
Andrew Tridgell
9db5d45d07 SRV_Channel: handle reversed channels in limit PWMs 2018-09-13 08:16:07 +10:00
Andrew Tridgell
098cf8dcb0 AP_IOMCU: implement failsafe PWM 2018-09-13 08:16:04 +10:00
Andrew Tridgell
239c18792a AP_AHRS: fixed dead-reckoning groundspeed vector
this is essential for RTL in planes on GPS loss
2018-09-12 16:26:36 +10:00
Leonard Hall
69138fea36 AC_PosControl: Fix divide by zero check in limit_vector_length 2018-09-12 14:15:13 +10:00
Leonard Hall
3fd270ff2a AC_AttitudeControl: Add minimum angle limit for get_althold_lean_angle_max 2018-09-12 14:15:09 +10:00
Andrew Tridgell
54c5b6e404 HAL_ChibiOS: fixed ADC bug
this caused bad analog readings when the number of channels being read
was more than the number of hw channels

thanks to @vierfuffzig for reporting!
2018-09-11 20:29:48 +10:00
s0up
b53dfbc3d2 HAL_ChibiOS: Add speedybee hardware definition 2018-09-07 08:34:40 +10:00
Andrew Tridgell
536923585c AP_IOMCU: cope with IOMCU reset in flight
this copes with IOMCU reset when we have safety forced off
2018-09-04 15:24:33 +10:00
Andrew Tridgell
e1bab160f7 AP_Notify: fixed oled probe on first bus
Thanks to Erwin Quilloy for helping to track this down
2018-09-03 18:06:47 +10:00
Andrew Tridgell
7897fbc3c1 HAL_ChibiOS: use a larger TX buffer on USB
this is needed for fast log download on vehicles with 50Hz main loop
2018-08-28 08:49:37 +10:00
Andrew Tridgell
3ae4cfbf22 HAL_ChibiOS: enable terrain on Pixracer, minpx-v2 and mini-pix 2018-08-24 19:44:08 +10:00
Michael du Breuil
3292f049e7 SRV_Channel: Remove the trim_all interface, constrain failsafes to non motor outputs 2018-08-23 12:56:47 +10:00
Andrew Tridgell
860310ba7c AP_OSD: raise thread stack size to 1024
based on testing in SITL
2018-08-20 13:49:38 +10:00
Andrew Tridgell
1087da3d64 AP_TECS: set default pitch max to 15 2018-08-17 17:02:16 +10:00
Andrew Tridgell
cb37f112cd AP_L1_Control: lower default L1 period 2018-08-17 17:02:06 +10:00
Andrew Tridgell
6fe07e5702 APM_Control: raised default PID gains for roll/pitch 2018-08-17 17:01:56 +10:00
Hwurzburg
5ba6f5a3a2 AP_OSD: Adding efficiency and climb efficiency
and new font characters
2018-08-17 16:34:23 +10:00
Peter Barker
50a53ae28a DataFlash: force messagewriters to completion
Setting a dataflash-file buffer size of less than or equal to 2kiB would
cause the startup-messagewriter to never push any messages other than
FMT out to the logs.

This is a combination of the return values of
critical_message_reserved_space and
non_messagewriter_message_reserved_space

This patch forces the startup messages out to the logs by ignoring the
space constraints every 100ms
2018-08-16 17:41:47 +10:00
Andrew Tridgell
765e00faf1 HAL_ChibiOS: reduce memory used by serial buffers
this does not appear to affect log download speed. It saves about 27k
of memory
2018-08-16 17:01:01 +10:00
Andrew Tridgell
e26028f572 AP_Stats: make singleton and add flighttime accessor 2018-08-16 16:54:31 +10:00
Hwurzburg
ea3e523d28 AP_OSD: add flytime item 2018-08-16 16:54:21 +10:00
Hwurzburg
c4c8e18f0c AP_OSD: Adding flight distance and summary panels for OSD 2018-08-16 16:54:19 +10:00
Alexander Malishev
5502bba9b4 AP_OSD: add waypoint and xtrack_error items 2018-08-16 16:54:17 +10:00
vierfuffzig
f9ed94ed97 AP_OSD: add hdop display 2018-08-16 16:54:15 +10:00