Commit Graph

21512 Commits

Author SHA1 Message Date
Randy Mackay
dee4e867e4 AP_Logger: add vibration failsafe error subsystem 2019-10-18 11:15:25 +09:00
Leonard Hall
e5f724bc3a AC_PosControl: add high vibration compensation 2019-10-18 11:15:25 +09:00
Randy Mackay
0052dcc8f8 AC_PID: update pid_info when integrator set 2019-10-18 11:15:25 +09:00
Randy Mackay
adf4d8fd47 AP_InertialNav: use ekf::get_vert_pos_rate during high vibration 2019-10-18 11:15:25 +09:00
Randy Mackay
5baed38266 AP_NavEKF3: reduce EK3_HRT_FILT max to 30 2019-10-18 11:15:25 +09:00
Paul Riseborough
5b1d9ed868 AP_NavEKF3: Add missing vertical position derivative calculation 2019-10-18 11:15:25 +09:00
Randy Mackay
e2d3afaaa7 AP_NavEKF2: reduce EK2_HRT_FILT max to 30 2019-10-18 11:15:25 +09:00
Paul Riseborough
c26c6fd078 AP_NavEKF2: Add missing vertical position derivative calculation
Use a third order order complementary filter to estimate the rate of change of vertical position output.
2019-10-18 11:15:25 +09:00
Randy Mackay
4a1247b9f7 AP_AHRS: add get_innovations 2019-10-18 11:15:25 +09:00
Leonard Hall
05f1161e63 RC_Channel: Support for Standby functions 2019-10-17 14:57:18 +09:00
Leonard Hall
e8e969af62 AP_Logger: Support for Standby functions 2019-10-17 14:57:18 +09:00
Leonard Hall
5acfc77a3c AC_AttitudeControl: Support for Standby functions 2019-10-17 14:57:18 +09:00
Michael du Breuil
3274398bc2 AP_Scripting: Fix up uint32_t manipulation, fix AP_Notify
This also adds a touched up version of the foxhunt demo that was done at
the 2019 developer unconf
2019-10-16 21:57:41 -07:00
Andrew Tridgell
c03796d7de GCS_MAVLink: fixed uninitialised bytes in send_named_float()
this fixes an issue with mavproxy with python3
2019-10-17 13:50:35 +11:00
Peter Barker
49687d4e5d AP_HAL_SITL: ToneAlarm doesn't play tones if disabled via param 2019-10-16 16:00:35 +11:00
Peter Barker
47fbf70e85 SITL: create SITL tonealarm files to hold enable parameter 2019-10-16 16:00:35 +11:00
Peter Barker
d6f10a12eb AP_Notify: add a simulated buzzer for SITL 2019-10-16 16:00:35 +11:00
Peter Barker
111c17d0b4 AP_HAL_SITL: add a simulated buzzer 2019-10-16 16:00:35 +11:00
Peter Barker
32ec6d7e9a SITL: add a simulated buzzer 2019-10-16 16:00:35 +11:00
Andrew Tridgell
df90cee8a0 AP_ADSB: added handle_adsb_vehicle() API
this allows for UAVCAN ADSB adapters
2019-10-16 13:13:24 +11:00
Andrew Tridgell
8650229ad4 AP_ADSB: added singleton interface 2019-10-16 13:13:24 +11:00
Andrew Tridgell
16bc7f800e AP_UAVCAN: support ADSB over UAVCAN 2019-10-16 13:13:24 +11:00
Andrew Tridgell
b9885034b1 HAL_ChibiOS: added a f103-ADSB firmware
for presenting a ping ADSB device as UAVCAN
2019-10-16 13:13:24 +11:00
Andrew Tridgell
85271a8747 HAL_ChibiOS: split out f103-GPS from base f103-periph
this makes it easier to create more peripheral variants
2019-10-16 13:13:24 +11:00
Michael du Breuil
e54acb8bde AP_Scripting: Add an example message interval script 2019-10-16 09:48:55 +09:00
Michael du Breuil
076cf0bdc8 AP_Scripting: Add a one arg variant of uint32_t, and expose table unpack 2019-10-16 09:48:55 +09:00
Bill Geyer
63d9b47530 AP_Motors: make init_targets_on_arming global 2019-10-16 08:17:09 +09:00
bnsgeyer
d1a0635ec2 AC_AttitudeControl: incorporate SysID into tradheli 2019-10-16 08:17:09 +09:00
Leonard Hall
0834726b48 AC_AttitudeControl: Support System ID tests 2019-10-16 08:17:09 +09:00
Andrew Tridgell
b7ae12a9d3 HAL_ChibiOS: reduce max compasses to 1 on AP_Periph 2019-10-16 08:58:52 +11:00
Andrew Tridgell
7ad91fa1c9 AP_Compass: don't show too many params when max compasses 1 2019-10-16 08:58:52 +11:00
Michael du Breuil
a80ff80061 AP_Motors: Fix safe disarm 2019-10-16 08:46:49 +11:00
Leonard Hall
6e8413f122 AP_Motors: Use safety timer to enable pwm before spool up 2019-10-16 08:46:49 +11:00
Michael du Breuil
df8c9e5825 AP_Scripting: Raise default heap size 2019-10-15 15:35:12 -06:00
Michael du Breuil
cf94a02207 AP_Scripting: Stop running scripts if the enable flag ever goes false 2019-10-15 15:35:12 -06:00
Peter Barker
9fee2a9c06 AP_Vehicle: add singleton 2019-10-15 13:24:20 +11:00
Leonard Hall
d4b922336b Copter: add voltage compensation to _throttle_thrust_max 2019-10-15 10:45:36 +09:00
Andrew Tridgell
00260db65a AP_GPS: fixed UAVCAN GPS status when disconnected
this fixes the status reported for a UAVCAN GPS when the cable is
unplugged. It should be "NO GPS", but was instead reporting "NO
FIX". The user had no way to distinguish between not finding a CAN GPS
at all and it not getting satellites

thanks to CUAV for reporting
2019-10-14 19:08:37 -06:00
murata
000aa4f515 AP_RangeFinder: Add TF03-180 2019-10-15 10:07:53 +09:00
Randy Mackay
6588c93e44 SRV_Channel: renamed EPM to Gripper in FUNCTION param docs 2019-10-15 09:11:06 +09:00
Andrew Tridgell
c2067d5bc2 AP_NavEKF3: set a min yaw accuracy from GPS of 5 degrees
GPS modules tend to be rather optimistic about their yaw accuracy. By
setting a min or 5 degrees we prevent the user constantly getting
warnings about yaw innovations
2019-10-15 11:06:11 +11:00
Andrew Tridgell
37fb028532 AP_GPS: improved checking for valid yaw for moving baseline
and fixed check for carrSolnFixed
2019-10-15 11:06:11 +11:00
Michael du Breuil
2587b13ae7 AP_GPS: UBLOX: Parse RELPOSNED messages
This does not yet:
  - validate the receiver configuration
  - manage timing out stale GPS heading info
  - relPosNormalized usage isn't clear, which may defeat the STRICT_LENGTH_CHECK
2019-10-15 11:06:11 +11:00
Michael du Breuil
cb5bba8379 AP_Logger: Log GPS yaw accuracy 2019-10-15 11:06:11 +11:00
Michael du Breuil
f0e742caa3 AP_Scripting: Fix generation of uint32_t arguments
This also fixes the message interval description not generating
correctly, it must have been manually edited before
2019-10-14 17:51:54 -06:00
Andrew Tridgell
97dc76732c HAL_ChibiOS: drop mRoControlZeroF7 DPS310 clock to 5MHz 2019-10-15 10:22:15 +11:00
Andrew Tridgell
94418ca70e AP_Baro: added register checking and reset to DPS280 driver
this is to fix an issue found on a mRoControlZeroF7
2019-10-15 10:22:15 +11:00
Randy Mackay
7ce2fb8783 GCS_Mavlink: handle_preflight_reboot made virtual 2019-10-15 07:41:44 +09:00
Henry Wurzburg
c515f4b317 AP_HAL_ChibiOS/hwdef: update KakuteF4 readme 2019-10-14 10:04:30 +11:00
Andy Piper
28b866cc8f AP_HAL_ChibiOS: hardware definitions for Kakute F7 Mini 2019-10-12 21:53:55 +11:00
liang
8de44ec319 AP_Airspeed: protect sample timestamp while get data 2019-10-12 18:15:06 +11:00
Michael du Breuil
05d104675e AP_Logger: Fix logging of current on non primary instances 2019-10-11 08:39:28 +11:00
Andy Piper
ef7f8531fb Filter: set the harmonic notch filter ref default to zero (disabled)
Modify parameter descriptions for tradheli
2019-10-10 20:26:02 +09:00
Leonard Hall
4a1a5e81ea AP_Motors: Add variable to record the final thrust value
Add Throttle_Out for other frames
2019-10-10 20:26:02 +09:00
Andrew Tridgell
d6e17b0c2b AP_InertialSensor: publish an IMU temperature
makes testing of mavlink extension easier
2019-10-10 13:23:03 +11:00
Andrew Tridgell
29e65a7294 GCS_MAVLink: supply IMU temperature in mavlink extensions 2019-10-10 13:23:03 +11:00
Do Carmo Lucas
dc4ad26e96 GCS_MAVLink: updates to support the latest stable mavlink changes (IMU temperature extension) 2019-10-10 13:23:03 +11:00
Andrew Tridgell
77bf67e15f HAL_ChibiOS: fixed padding of neopixel bits
lack of padding at start caused occasional glitches in colors
displayed
2019-10-10 10:41:19 +11:00
Peter Barker
25fd04d402 AP_Proximity: declare RangeFinder as a class to avoid circular include issue 2019-10-08 11:26:04 +11:00
Peter Barker
9aaa6c49fa AP_BoardConfig: correct include of AP_Vehicle_Type 2019-10-08 11:26:04 +11:00
Peter Barker
083d4ac3ea DataFlash: adjust for new vehicle base class 2019-10-08 11:26:04 +11:00
Peter Barker
405bf0ce7f AP_Mission: adjust for new vehicle base class 2019-10-08 11:26:04 +11:00
Peter Barker
8e412d0885 AP_Compass: adjust for new vehicle base class 2019-10-08 11:26:04 +11:00
Peter Barker
cf201afdf6 AP_AccelCal: adjust for new vehicle base class 2019-10-08 11:26:04 +11:00
Peter Barker
8bb51f4b7d AC_AttitudeControl: adjust for new vehicle base class 2019-10-08 11:26:04 +11:00
Peter Barker
1ea365d52a AP_Vehicle: move many members up to base class 2019-10-08 11:26:04 +11:00
Peter Barker
a6b6bb99f3 AP_NMEA_Output: skip sending sentences if no space on UART
AP_NMEA_Output: clean scope by removing unneeded temps

AP_NMEA_Output: redo last_sent to last_run

AP_NMA_Output: early-exit if no data
2019-10-08 11:07:19 +11:00
Peter Barker
5428d13502 AP_Arming: remove bogus ARMING_CHECK_NONE 'bitmask value'
This looks like a bitmask value, but if you treat it like one (and
people have in the past!) by using logical operations then you get the
incorrect result.

Places which were checking for equivalence to ARMING_CHECK_NONE now
simply check the bitmask to see if it is all-empty.
2019-10-08 10:31:07 +11:00
murata
371f11b7f4 AP_Motors: Change to description(NFC) 2019-10-08 08:26:17 +09:00
Andrew Tridgell
4866fd68b5 AP_BoardConfig: fixed CAN init without SLCAN 2019-10-08 10:02:14 +11:00
Andrew Tridgell
15d98220e0 AP_HAL: enabled SLCAN on fmuv2 and Pixhawk1-1M
this fits for now, and is needed for CAN GPS for now
2019-10-08 10:02:14 +11:00
Andrew Tridgell
08b3bc4506 AP_UAVCAN: cleanup ifdefs for SLCAN enable 2019-10-08 10:02:14 +11:00
Andrew Tridgell
53fab5767f AP_HAL: cleanup ifdefs for SLCAN enable 2019-10-08 10:02:14 +11:00
Andrew Tridgell
15e4641e51 AP_HAL_ChibiOS: cleanup ifdefs for SLCAN enable 2019-10-08 10:02:14 +11:00
Andrew Tridgell
6b3c10f0e7 AP_BoardConfig: cleanup ifdefs for SLCAN enable 2019-10-08 10:02:14 +11:00
Henry Wurzburg
4a42a3a23a Rover: implement steering trim save in armed/manual mode only 2019-10-08 07:41:57 +09:00
vierfuffzig
cb054e714b AP_RTC: add local time support 2019-10-07 19:55:42 +11:00
vierfuffzig
1f9b2f712e AP_OSD: add clock panel 2019-10-07 19:55:42 +11:00
Randy Mackay
e4336551cd AP_Follow: add clear_offsets_if_required method
this restores the offsets to zero if they were initialised from zero when the lead vehicle was first spotted
2019-10-07 08:30:45 +09:00
Ebin
f6c7ac88d0 SITL: Yaw rate calculation uses wheel offset 2019-10-07 07:31:53 +11:00
Peter Barker
e32d8ecda1 AP_WheelEncoder: add SITL backend
AP_WheelEncoder: added update function for SITL quadrature encoder
2019-10-07 07:31:51 +11:00
Peter Barker
4d17a7cf89 AP_Logger: tidy MessageWriter stages using enum class 2019-10-05 16:37:43 +10:00
Henry Wurzburg
880285dad4 AP_BLHeli: Change descriptions in SERVO_BLH_PORT param to actual AP port 2019-10-05 16:35:59 +10:00
Michel Pastor
dec5b97275 AP_Logger: fix logging on 256Mbit flash chips 2019-10-05 16:25:22 +10:00
Andrew Tridgell
39182e70e4 AP_Motors: enable docs for hover thr learning in plane 2019-10-04 14:01:08 +10:00
Michel Pastor
49bf0a3057 AP_Logger: fix AP_Logger_Block::get_num_logs() 2019-10-04 12:49:16 +10:00
Randy Mackay
db7836ad48 AP_SmartRTL: fixup compile error
fix typo introduced by me attempting a minor fixup before merging
2019-10-04 10:01:49 +09:00
Peter Barker
fd0a8b72b4 AP_Logger: correct uninitialised value when logging all rally points 2019-10-04 10:39:01 +10:00
Henry Wurzburg
13e66e9f7c AP_SmartRTL: give warning buffer is about to fill-up 2019-10-04 08:57:30 +09:00
Andrew Tridgell
555f56a8af HAL_ChibiOS: removed wait on CAN peripheral in H7
these wait busy loops can take a very long time, and end up causing
interrupts to be lost elsewhere in the system, causing lost bytes on
UARTs

We should not have while loops waiting on peripharals like this. If we
do need to wait for a flag to clear then it needs to be done in a low
priority thread, or we need to check for completion in a timer

CAN still seems to work with this change, but needs flight testing
2019-10-03 15:26:47 +10:00
Henry Wurzburg
9717548cb5 AP_Follow: hide params not used by Rover 2019-10-03 07:18:47 +09:00
Andrew Tridgell
3ebc69320c AP_Logger: fixed LOG_FILE_DSRMROT with delayed log stop
now that we persist logging for 15s after disarm we need to also delay
the log rotation if LOG_FILE_DSRMROT=1. Otherwise we will put the log
data into the next log, which defeats the purpose of the 15s
persistance
2019-10-03 07:17:16 +10:00
vierfuffzig
b89c60d5b0 AP_BLHeli: fix watchdog resets with telemetry active from non-multirotor motors 2019-10-02 21:06:22 +10:00
Randy Mackay
8686197c59 GCS_MAVLink: add comment above set-message-interval 2019-10-02 16:17:09 +09:00
Randy Mackay
3a113a31bb GCS_MAVLink: minor fix to set_message_interval 2019-10-02 16:09:44 +09:00
Tatsuya Yamaguchi
5039bdc8ea AP_Scripting: add set_message_interval binding 2019-10-02 16:09:44 +09:00
Tatsuya Yamaguchi
9a99d9bff5 GCS_MAVLink: add set_message_interval functions 2019-10-02 16:09:44 +09:00
Andrew Tridgell
ddde512b74 AP_Scheduler: use fill_nanf() on each scheduler function 2019-10-01 17:35:26 +10:00
Andrew Tridgell
cbe34320b5 AP_NavEKF2: fixed build
broken by recent common variable change
2019-10-01 17:35:26 +10:00
Andrew Tridgell
b9291d95f0 HAL_SITL: pre-fill stack on each loop with NaN
this allows us to catch use of uninitialised stack variables in SITL
without having valgrind running
2019-10-01 17:35:26 +10:00
Andrew Tridgell
66b4e92444 AP_Math: make fill_nanf() use a signalling NaN
we want use of these values to trigger a FPE
2019-10-01 17:35:26 +10:00
Andrew Tridgell
f79907bd1e AP_NavEKF: fixed build with vector index checking 2019-10-01 15:39:03 +10:00
Andrew Tridgell
3995db49a4 AP_NavEKF3: use parent class for intermediate static variables
this makes the code faster as well as using less memory when both EK2
and EK3 are enabled
2019-10-01 15:39:03 +10:00
Andrew Tridgell
f7e138bddd AP_NavEKF2: use parent class for intermediate static variables
this makes the code faster as well as using less memory when both EK2
and EK3 are enabled
2019-10-01 15:39:03 +10:00
Andrew Tridgell
688b01c6c6 AP_NavEKF: added a common parent class for EKF2 and EKF3 core classes
this provides a common location for static intermediate variables in
EK2 and EK3. This has a few benefits:

 - the compiler can determine the address of the frequently accessed
   variables at compile time, making them faster

 - by sharing between EK2 and EK3 we save a lot of memory if both EK2
   and EK3 are enabled

 - we can fill all these with NaN in SITL on every loop, which allows
   us to catch cases where the variables are ever re-used between
   loops, which guarantees we aren't mixing data between EKF lanes or
   between EK2 and EK3
2019-10-01 15:39:03 +10:00
IamPete1
3b9a35da27 AP_Motors: add reversed tricopter option 2019-10-01 09:39:08 +10:00
vierfuffzig
2af0be3947 AP_AHRS: fix custom orientation ToRad conversion 2019-10-01 09:35:09 +10:00
Andrew Tridgell
0deef76875 GCS_MAVLink: use HAL_MEM_CLASS for status sizes 2019-10-01 09:29:55 +10:00
Andrew Tridgell
889b18022b AP_Logger: use HAL_MEM_CLASS for logging buffer size 2019-10-01 09:29:55 +10:00
Andrew Tridgell
3bf3ebb703 AP_Logger: try harder to use close to user buffer size
this stops us drastically reducing buffer size when low on memory
2019-10-01 09:29:55 +10:00
Andrew Tridgell
2d00298070 AP_HAL: added HAL_MEM_CLASS for amount of memory 2019-10-01 09:29:55 +10:00
Andrew Tridgell
47f2f1764d HAL_ChibiOS: generate HAL_MEMORY_TOTAL_KB for each board 2019-10-01 09:29:55 +10:00
Peter Barker
13352a4ca7 AP_ADSB: move is_valid_octal to is_valid_callsign and add tests for it 2019-10-01 09:18:15 +10:00
Peter Barker
6fe09b6120 AP_Math: move is_valid_octal into adsb
This doesn't ensure the value is octal digits - there's more magic in
it.
2019-10-01 09:18:15 +10:00
Andrew Tridgell
1a34fccc71 AP_Proximity: fixed incorrect use of fabs() 2019-10-01 08:12:07 +09:00
Andrew Tridgell
e3a965272c HAL_ChibiOS: added Pixhawk1-1M
this is for 1M versions of the Pixhawk1. It is smaller than fmuv2 as
it only links the specific sensors needed for Pixhawk1
2019-10-01 09:08:25 +10:00
Andrew Tridgell
b5217412f9 AP_GPS: fixed a bug in handling corrupt u-blox packets
when we have corrupt input due to loss of bytes on a UART we can end
up with a u-blox packet with zero payload bytes. When that happens we
need to bypass payload reading as otherwise we will end up keeping
reading bytes until the driver resets at 4 seconds, causing a GPS
outage.

This was causing GPS outages every few hours in copters running 3.6.7,
and was also reproduced in SITL using SIM_GPS_BYTELOSS.
2019-09-30 15:20:30 -06:00
Mark Whitehorn
0a6ae60c89 AP_IOMCU: fix IO fast channel mask 2019-10-01 07:13:33 +10:00
Mark Whitehorn
d8a07b6c44 HAL_ChibiOS: fix FMU fast_channel_mask
fix IO fast channel mask
use IOMCU chmask to only set right channels
remove unused variable
2019-10-01 07:13:33 +10:00
Andrew Tridgell
748cf39116 HAL_ChibiOS: disable DMA for RCIN on Pixracer
this frees up DMA for USART1_RX, which gives DMA for input over the
SERIAL5 WiFi port, which is important for applications where a
pixracer is being fed vision data over WiFi
2019-09-30 07:58:40 +10:00
mhefny
92d55fa126 SITL: removed unnecessary files of webots 2019-09-30 04:46:38 +10:00
Peter Barker
04ee459e8c AP_Baro: exclude Sub pressure transducers from non-sub builds 2019-09-28 16:41:06 +10:00
Andrew Tridgell
c29867ecad AP_Common: removed fcntl overrides
not needed with AP_Filesystem, and fixes lots of warnings with newer
compilers
2019-09-28 14:19:46 +10:00
Andrew Tridgell
81711eb28e AP_HAL: fixed build on g++ 7.3 for stm32
the system maths headers don't like our maths defines, but are happy
if we include math.h first
2019-09-28 14:19:46 +10:00
Henry Wurzburg
cf3bd2487b AP_OSD: add current averaging filter to reduce jitter (~5 sample timeconstant) 2019-09-28 14:17:59 +10:00
Randy Mackay
0d032ecd86 AC_Avoidance: add enabled and margin accessors 2019-09-28 11:13:14 +09:00
Randy Mackay
6be4adbe02 RC_Channels: define surface tracking auxiliary function 2019-09-28 11:13:14 +09:00
Randy Mackay
9aeac012d2 AC_Avoid: add support for complex fence types
AP_OABendyRuler: support exclusion polygons

AP_OADijkstra: support exclusion polygons

AC_Avoid: adjust_velocity supports exclusion polygons

AC_Avoidance: handle fence::get_boundary_points returning nullptr instead of setting num_points to zero

AC_Avoidance: Dijkstra's works with only exclusion polygons

AC_Avoidance: Dijkstra: check for fence counts instead of polyfence validity

We really only care whether fences can be returned - and they won't be
returned unless they are valid

AC_Avoidance: BendyRuler: just try to get inclusion fence rather than checking validity

AC_Avoidance: BendyRuler supports exclusion circles

AC_Avoid: Dijkstra support for exclusion circles

AC_Avoid: BendyRuler support for inclusion circles

AC_Avoid: stop an inclusion/exclusion circular fences

AC_Avoid: stop at inclusion/exclusion circular fences

AC_Avoid: fixes to Dijkstra's use of inclusion/exclusion circles and polygons

AP_Avoidance: take semaphores when interacting with AHRS and polyfence

AC_Avoid: Dijkstra's fix for some_fences_enabled inclusion circles
2019-09-28 07:58:48 +09:00
Randy Mackay
3431938bce AP_Logger: add error code to Write_OADijkstra 2019-09-28 07:58:48 +09:00
Peter Barker
a0c6ff95e4 AP_Proximity: polyfence valid() has been renamed 2019-09-28 07:58:48 +09:00
Peter Barker
714a3e2462 AC_Fence: support for multiple polygon fences
AC_Fence: add interface for retrieving exclusion polygons

AC_Fence: add interface to get exlusion polygons to polyfence loader

AC_Fence: add suport for inclusion circles

AC_Fence: add option for compiling-out FENCE_POINT protocol support

AC_Fence: get_exclusion_polygon and get_boundary_points set num_points to zero on failure

AC_Fence: use Debug(...) to hide debug messages

AC_PolyFence_loader: add methods to retrieve all inclusion zones

AC_PolyFence_loader: valid simply returns true if a polygon boundary can be returned

AC_Fence: add get_exclusion_circle

AC_Fence: add get_exclusion_circle_update_ms accessor

AC_Fence: PolyFence_loader gets inclusion circle accessors

AC_PolyFence_loader: add and use semaphore to protect loaded fence

AC_Fence: move fence breach check below fence type checks

This allows us to provide more information to the user about why they
are breached.

For example, if the radius is negative you are considered in breach of
it - but we'd tell you you were breached, not that your radius was
invalid

AC_Fence: clear the fence if we discover the user has set the fence count to zero
2019-09-28 07:58:48 +09:00
Peter Barker
6d0c5da84a GCS_MAVLink: allow upload of fence using mission item protocol
GCS_MAVLink: add support for fence inclusion circles

GCS_MAVLink: factor out a transfer_is_complete; start commenting properly
2019-09-28 07:58:48 +09:00
Peter Barker
f3b0148719 AP_OADijkstra: cope with polyfence holding boundary points 2019-09-28 07:58:48 +09:00
Peter Barker
dfca32a2af AP_OABendyRuler: cope with polyfence holding boundary points 2019-09-28 07:58:48 +09:00
Peter Barker
3a7f1b882e AC_Avoidance: cope with polyfence holding boundary points 2019-09-28 07:58:48 +09:00
Peter Barker
74aed5aef8 GCS_MAVLink: cope with polyfence holding boundary points 2019-09-28 07:58:48 +09:00
Peter Barker
5fe16d5250 AP_Proximity: cope with polyfence holding boundary points 2019-09-28 07:58:48 +09:00
Peter Barker
ff37590776 AC_Fence: move polygon points into AC_Fence_Polygon 2019-09-28 07:58:48 +09:00
Peter Barker
189ef5f1e7 AP_Math: define != for Vector2<int> 2019-09-28 07:58:48 +09:00
Peter Barker
f1e5c72ee9 StorageManager: add write_uint8 alias for write_byte 2019-09-28 07:58:48 +09:00
Peter Barker
f090f35afa AP_InternalError: add a general should-not-be-here bit 2019-09-28 07:58:48 +09:00
Peter Barker
bc8e56966f GCS_MAVLink: squelched rally-points-received message 2019-09-28 07:58:48 +09:00
Andrew Tridgell
8dd2119b14 AP_NavEKF2: make it easy to do EK2 timing tests
for future benchmarking
2019-09-28 08:57:26 +10:00
Andrew Tridgell
e820219202 HAL_ChibiOS: changed optimisation of higher end boards to -O2
-O3 does not seem to be a win, and takes up a lot more flash
2019-09-28 08:57:26 +10:00
Andrew Tridgell
0e3a27f74f AP_NavEKF3: change optimisation from -O3 to -O2 2019-09-28 08:57:26 +10:00
Andrew Tridgell
163efd0df5 AP_NavEKF2: change optimisation from -O3 to -O2 2019-09-28 08:57:26 +10:00
Andrew Tridgell
5f90afa71e AP_Mount: change optimisation from -O3 to -O2 2019-09-28 08:57:26 +10:00
Andrew Tridgell
13a2367278 AP_Math: change optimisation from -O3 to -O2 2019-09-28 08:57:26 +10:00
Andrew Tridgell
7c3df18ea3 AP_IOMCU: change optimisation from -O3 to -O2 2019-09-28 08:57:26 +10:00
Willian Galvani
0c5753112a AP_TemperatureSensor: Update TSYS01 for Pixhawk2 2019-09-27 13:08:26 -07:00
Peter Barker
06df44c184 AP_Relay: change parameter name from relay to instance 2019-09-27 12:02:38 +10:00
Peter Barker
1c3b2f9699 AP_Relay: tidy, reduce flash usage 2019-09-27 12:02:38 +10:00
Peter Hall
b6efcbcf3b AR_WPNav: make get_stopping_location public 2019-09-27 09:09:47 +09:00
Henry Wurzburg
11c633be32 AP_OSD: distance total fix for slow vehicles 2019-09-27 07:19:55 +10:00
Willian Galvani
dd97eedde3 APMotors_6DOF: Implement motor_is_enabled(), get_motor_angular_factors() and set_reversed(); 2019-09-26 09:39:50 -07:00
Peter Hall
4c62fe6c72 AP_Windvane: caculate vehicles current tack 2019-09-26 18:23:03 +09:00
Willian Galvani
d56c490b18 AP_Motors_6DOF: Add missing 'break' 2019-09-25 20:17:41 -07:00
Henry Wurzburg
59ce3f1007 AP_OSD: scale xtrack, add precision for distances <10 units 2019-09-26 12:56:12 +10:00
Patrick José Pereira
29fadc2417 AP_HAL_Linux: PCA9685: Check for device before accessing it
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2019-09-26 12:42:12 +10:00
mhefny
8310058c8c SITL: adding Tricopter model in Webots 2019-09-25 13:34:47 +01:00
Randy Mackay
5e3c6b4d3a GCS_MAVLink: allow proximity to send only upward facing distances
this removes the requirement that a horizontal proximity sensor be enabled
2019-09-25 15:22:13 +09:00
Henry Wurzburg
f592806184 AP_OSD: formatting fixes 2019-09-25 15:01:59 +09:00
bnsgeyer
d4fec221c3 AP_Motor: tradheli align swash params btwn frames and fix metadata 2019-09-25 14:59:02 +09:00
Peter Barker
975804fa35 AP_Math: remove unit_mod concept from wrap functions
devcall decided it would be clearer to have non-shared implementation
for the _cd variants
2019-09-25 13:19:44 +10:00
Peter Barker
952d4d2cbc AP_NavEKF2: initialise Kfusion stack variable to fix compilation
This fixes the compilation, as previous patches have done.
2019-09-25 12:54:55 +10:00
Peter Barker
9fb715692e AP_HAL_ChibiOS: correct include of mavlink header for analog debug 2019-09-25 12:22:27 +10:00
liang
d890203f73 AP_Baro: LPS22H: correct formatting 2019-09-24 09:50:56 -07:00
Andrew Tridgell
d40d812ea4 AP_NavEKF2: fixed build with g++ 9.1
this is a false positive, but the cost of clearing this array is low,
and it saves a much more complex fix
2019-09-24 14:59:17 +10:00
murata
6d7c2301f2 AP_Radio: Change direct value to define name 2019-09-24 13:23:24 +10:00
murata
ec0c49315f AP_Compass: Change direct value to define name 2019-09-24 13:23:24 +10:00
Andrew Tridgell
9226899c6f AP_NavEKF2: added comment (review request) 2019-09-24 12:51:54 +10:00
Andrew Tridgell
255981c60c AP_NavEKF2: moved some of the intermediate vars to the stack
this keeps stack frames below 1k, while giving faster access to the
variables and saving more memory
2019-09-24 12:51:54 +10:00
Andrew Tridgell
96c6544997 AP_NavEKF3: moved intermediate variables to common memory
this moves intermediate variables from being per-core to being common
between cores. This saves memory on systems with more than one core by
avoiding allocating this memory on every core.

This is an alternative to #11717 which moves memory onto the stack. It
doesn't save as much memory as #11717, but avoids creating large stack
frames
2019-09-24 12:51:54 +10:00
Andrew Tridgell
0041874826 AP_NavEKF2: moved intermediate variables to common memory
this moves intermediate variables from being per-core to being common
between cores. This saves memory on systems with more than one core by
avoiding allocating this memory on every core.

This is an alternative to #11717 which moves memory onto the stack. It
doesn't save as much memory as #11717, but avoids creating large stack
frames
2019-09-24 12:51:54 +10:00
Andrew Tridgell
9b746b89db AP_Math: added fill_nanf()
used in SITL to invalidate memory
2019-09-24 12:51:54 +10:00
Peter Barker
08623c1712 AP_ADSB: use ObjectBuffer in place of AP_Buffer 2019-09-24 09:36:33 +10:00
Peter Barker
c043f315de AP_Buffer: remove as it is replaced with ObjectBuffer 2019-09-24 09:36:33 +10:00
Willian Galvani
5a9e5e937a APMotors6DOF: add roll factor for motors 4 and 5 for SIMPLEROV_4 and SIMPLEROV_5 2019-09-23 10:41:57 -07:00
Willian Galvani
948a5bf9c3 APMotors6DOF: add case for SIMPLEROV_3 2019-09-23 10:41:57 -07:00
Peter Barker
045960fe57 AP_HAL_SITL: catch SIGTERM and exit with zero exit status 2019-09-23 19:36:38 +10:00
Andrew Tridgell
85332d49a2 HAL_SITL: added MotorBoat 2019-09-23 17:22:01 +10:00
Andrew Tridgell
d2e75717b8 SITL: added a MotorBoat class
a sailboat with zero sail area
2019-09-23 17:22:01 +10:00
Lucas De Marchi
7520cdef2f AP_RangeFinder: update minimum fw version of TFMiniPlus
Version 2.0.3 has important fixes to avoid having the sensor to lock up.
Let's make sure we check for it and warn on console.
2019-09-23 12:56:13 +09:00
Peter Hall
c71cbe2729 APM_Control: AR_AttitudeControl: add description for new PID params 2019-09-23 09:45:46 +09:00
Andrew Tridgell
05d62c62bb AP_NavEKF3: fixed use of uninitialised variable in EKF3 mag fusion
not all elements of H_MAG are initialised, but they are used, as found
by valgrind
2019-09-22 21:06:36 +10:00
Andrew Tridgell
386e7dc3e8 HAL_ChibiOS: fixed delay for OneShot125 channels
we were delaying output for OneShot125 by 8x as much as we need to,
which reduced our max loop rate
2019-09-22 19:43:35 +10:00
Andrew Tridgell
850892c3d9 HAL_ChibiOS: fixes from LGTM errors 2019-09-22 18:35:15 +10:00
Andrew Tridgell
c6f43e9700 AP_NavEKF3: fixed use of old irqsave() API 2019-09-21 15:36:47 +10:00
Andrew Tridgell
1d47f9186e AP_NavEKF2: fixed use of old irqsave() API 2019-09-21 15:36:47 +10:00
Andrew Tridgell
d7ee622edc AP_Logger: fixed use of old irqsave() API 2019-09-21 15:36:47 +10:00
Lucas De Marchi
5f65033511 AP_RangeFinder: add missing overrides 2019-09-21 08:01:08 +10:00
Lucas De Marchi
ce877ba40a AP_RangeFinder: fix build 2019-09-21 08:01:08 +10:00
Andrew Tridgell
108d7fa024 AP_Logger: added logging of extra loop time from the scheduler 2019-09-19 18:25:20 +10:00
Andrew Tridgell
79acaeaef1 AP_Scheduler: cope with high CPU load by stretching loop times
this adds an extra budget of time per loop when we are not achieving
scheduled tasks at a rate of at least 1/8 of the desired rate. This
fixes an issue where a vehicle can become uncontrollable if the user
asks for a SCHED_LOOP_RATE which is not achievable. As these events
happen we add extra loop budget until we are able to run all tasks. We
drop the extra time when the CPU pressure eases.
2019-09-19 18:25:20 +10:00
Andrew Tridgell
3d9f393f4b SITL: added SIM_LOOP_DELAY parameter
this allows us to test high CPU load conditions by adding a delay to
each loop
2019-09-19 18:25:20 +10:00
Michael du Breuil
95bca05322 AP_HAL_ChibiOS: Only include MAVLink when using the MAVLink debugging 2019-09-19 10:48:25 +09:00
Michael du Breuil
5000891a76 GCS_MAVLink: remove some unused includes 2019-09-19 10:48:25 +09:00
Peter Barker
1c187d8feb AP_NavEKF3: correct return of empty prearm string 2019-09-19 08:47:47 +09:00
Peter Barker
3619856fc9 AP_NavEKF2: correct return of empty prearm string 2019-09-19 08:47:47 +09:00
Randy Mackay
398f427830 AP_Proximity: fix rangefinder backends cm to m conversion 2019-09-19 08:43:11 +09:00
Peter Barker
9cd30083a4 AC_AutoTune: correct abs to fabsf for roll_cd and pitch_cd 2019-09-18 12:57:02 +10:00
Peter Barker
8ee411e998 AP_L1_Control: wrap_180_cd no longer solely returns floats 2019-09-18 12:57:02 +10:00
Peter Barker
7fbaea7971 APM_Control: wrap_180_cd no longer solely returns floats 2019-09-18 12:57:02 +10:00
Peter Barker
5692f3d79e AP_Math: stop returning float for integer wrap_180/wrap_360 etc 2019-09-18 12:57:02 +10:00
Peter Barker
84d999142f AP_Math: add more tests for wrap functions 2019-09-18 12:57:02 +10:00
Peter Barker
56de1f2eed AC_WPNav: do not calculate NEU vector from invalid location 2019-09-17 09:05:23 +09:00
Michael du Breuil
819d1b5246 AP_Common: Include altitude in the init check for a location 2019-09-17 09:30:56 +10:00
Andrew Tridgell
9eb6c1be64 AP_GPS: use jitter correction on GPS_INPUT data
this allows for more accurate timing when using GPS_INPUT for indoor
positioning systems
2019-09-17 09:17:04 +10:00
Peter Barker
2f60b230cd GCS_MAVLink: use singleton to get AP_AdvancedFailsafe pointer 2019-09-17 09:13:43 +10:00
Peter Barker
9f8553d422 AP_AdvancedFailSafe: add singleton getter 2019-09-17 09:13:43 +10:00
Henry Wurzburg
57dc253be8 AP_OSD: Add autoranging to current and speed displays 2019-09-17 07:34:46 +10:00
Andrew Tridgell
3c058851b2 HAL_ChibiOS: fixed undef for define lines
this fixes IMU heater enable for CubeBlack+
2019-09-16 12:53:44 +10:00
Andrew Tridgell
255e769171 HAL_ChibiOS: fixed IMU order and board ID for CubeBlack+ 2019-09-16 12:53:44 +10:00
bugobliterator
e82da992c9 HAL_ChibiOS: hwdef: add hwdef for CubeBlack+ 2019-09-16 12:53:44 +10:00
bugobliterator
ee6f912217 AP_BoardConfig: add support for CubeBlackPlus 2019-09-16 12:53:44 +10:00
Andrew Tridgell
f86a7d347d Revert "AP_HAL_SITL: set initial PWM values to a flag value"
This reverts commit 1735563bb7.

This commit broke RC input on high channels with sim_vehicle.py, plane
getc RC failsafe immediately
2019-09-15 18:26:50 +10:00
Peter Barker
6193d6cf69 AP_Compass: fix example by instantiating Baro
Baro is required to get location, and Compass tries to get the declination based on current location
2019-09-13 08:54:21 +09:00
bnsgeyer
e91402aeb6 AP_Motors: tradheli-make all RSC params part of library
AP_Motors: Tradheli-fix RSC mode change while armed

AP_Motors: tradheli - improve RSC param metadata

AP_Motors: tradheli-put all throttle param settings in percent
2019-09-13 08:53:54 +09:00
Peter Barker
1735563bb7 AP_HAL_SITL: set initial PWM values to a flag value
These should never be used.  Setting them to a flag value may give a
hint to someone trying to debug a problem in the future.
2019-09-13 08:58:43 +10:00
Peter Barker
8da978b913 GCS_MAVLink: use sending_mavlink1 method in send_rc_channels_raw 2019-09-12 16:10:23 +10:00
Peter Barker
5dad0e5410 AP_HAL: a few more simple tests for snprintf 2019-09-12 16:08:59 +10:00
Andrew Tridgell
28cca004f2 HAL_ChibiOS: added default params for skyviper-journey 2019-09-12 14:02:36 +10:00
Andrew Tridgell
1dca0a16f5 HAL_ChibiOS: rename skyviper-f412 to skyviper-journey 2019-09-12 14:02:36 +10:00
Andrew Tridgell
dcbbc86f34 AP_Radio: added support for Skyviper 2018 model radios
fixes #12273
2019-09-12 14:02:36 +10:00
mhefny
375510ecc2 SITL: adding wind simulation in Webots 2019-09-12 13:22:26 +10:00
mhefny
bfb7e3af3b SITL: sending wind data to Webots controller 2019-09-12 13:22:26 +10:00
Andrew Tridgell
8bb6a67b36 GCS_MAVLink: refuse set of read-only parameters 2019-09-12 10:50:30 +10:00
Andrew Tridgell
6573857a90 AP_Param: support @READONLY marker in param files
allows for read-only parameters embedded in firmware
2019-09-12 10:50:30 +10:00
Andrew Tridgell
4a6fdc00c9 AP_AdvancedFailsafe: added AFS_MAX_RANGE option
this allows a maximum range since first arm to be set in
AFS_MAX_RANGE. This value (in km) will trigger the configured
termination type if the GPS location shows that it has been breached.

This feature, in combination with the @READONLY apj parameter feature,
is intended to be used to meet regulatory restrictions on a vehicles
maximum range
2019-09-12 09:59:17 +10:00
Andrew Tridgell
6af9d55e70 AP_OSD: fixed vsnprintf return assumption 2019-09-12 08:43:31 +10:00
Andrew Tridgell
98c2606c0a GCS_MAVLink: fixed assumption on return of snprintf 2019-09-12 08:43:31 +10:00
Peter Barker
412bf24b9a AP_HAL: add gtests for snprintf 2019-09-12 07:42:40 +10:00
Andrew Tridgell
54b9524c0b AP_RangeFinder: make LightWare I2C native work with more hw versions
this allows the native i2c lightware driver to work with a wide range
of lidars from LightWare, removing the specific version check, and the
version specific config commands
2019-09-12 07:40:32 +10:00
Andy Piper
8e385d7453 AP_InertialSensor: correct formatting 2019-09-11 18:41:05 +10:00
Leonard Hall
6f3be90147 Filter: Alter Notch filter formula to remove /0 and allow perfect notch.
This formulation of the notch equations lets the user specify the depth of the Notch. The presence of a diveide by A prevents the gain going to zero and therefore achieving a perfect notch. It also provides the risk that a user may attempt to do this and cause a divide by zero error. This change adds the ability to achive a perfect notch and removes the possibility of a divide by zero.

Add Notch Filter parameter checking
2019-09-11 18:41:05 +10:00
Andy Piper
9b9fb0d593 Filter: sanity check the harmonic notch sample rate on initialization. do not allow harmonics to go above the nyquist frequency 2019-09-11 18:41:05 +10:00
Andy Piper
5b7f9f6bea AP_InertialSensor: while sensors are converging update the filters sample rates. if gyro filtering produces invalid output, keep the previous value 2019-09-11 18:41:05 +10:00
Andy Piper
bc5916ebc9 Filter: comment on reserved config. cope with notch allocation failure. 2019-09-11 18:41:05 +10:00
Andy Piper
a9a7fe3ea5 AP_InertialSensor: ensure harmonic notch gets appropriate defaults 2019-09-11 18:41:05 +10:00
Andy Piper
3261677e01 AP_InertialSensor: remove _ prefix from methods. use changed filter methods. 2019-09-11 18:41:05 +10:00
Andy Piper
334ebadd5a Filter: add comments and address review comments for harmonic notch 2019-09-11 18:41:05 +10:00
Andy Piper
50f7e50634 AP_InertialSensor: add harmonic notch filter to gyro filter chain
Allow dynamic updates to the calculated frequency. Convert bandwidth and frequency to floats.
backend variables do not need to be indexed per-backed
2019-09-11 18:41:05 +10:00
Andy Piper
366bc06089 Filter: New HarmonicNotchFilter
This delegates updates to a bank of NotchFilters located at an rpm frequency and harmonics. Center frequency can be updated dynamically. Notch parameters are configurable, including the number of harmonics to filter on. Updates to the filter parameters are optimized across the notch bank. Convert notch bandwidth and frequency to floats.

allow all filter harmonics to be controlled.

add destructor to harmonic notch.

don't allocate sub-filters for harmonic notch if no harmonics set.
2019-09-11 18:41:05 +10:00
Andrew Tridgell
fae2e44eac AP_NavEKF3: reset inhibitMagStates on in-flight yaw reset
this is needed to prevent the next ConstrainVariances() from zeroing
the variances, which leads to very slow learning of mag states
2019-09-11 14:22:18 +10:00
Andrew Tridgell
71ad90819e AP_Compass: don't reset SITL compass offsets if set by user
makes for easier EKF compass bias learning testing
2019-09-11 14:22:18 +10:00
Peter Barker
10675ab5c4 AP_HAL: correct include ordering in srxl.h
The header needs stdint.h which it was only getting because it was
included after stdint.h in the cpp file.

Stop including standard headers before other ArduPilot headers
2019-09-11 14:19:14 +10:00
Andrew Tridgell
4197fdeb2a AP_HAL: fixed bug in vsnprintf()
we need to return the number of bytes that would have been printed if
the buffer was big enough to support use cases such as vasprintf()
which needs to know how many bytes to allocate
2019-09-11 13:41:03 +10:00
Peter Hall
102a231c3f AP_WindVane: rename abs to true wind 2019-09-11 11:22:12 +09:00
Rajat Singhal
5147b607c0 SITL: Correct Airsim params 2019-09-11 08:28:28 +10:00
Randy Mackay
246bfcf4a1 AP_Common: expanding array checks memory before allocating 2019-09-11 06:56:35 +10:00
Peter Barker
15308af230 AP_HAL_SITL: avoid lockstep scheduling issue with semaphores
If there is another thread holding a lock that the main thread wants to
take while pretending to be the IO thread, we will wait forever as we do
not move SITL time forward while pretending to be the IO thread.

This patch simply allows time to move forward if we've failed to take a
semaphore immediately and need to wait.
2019-09-10 21:01:37 +10:00
Andy Piper
dde6dec145 AP_InertialSensor: correct reboot documentation for batch logger and filters 2019-09-10 20:29:56 +10:00
Randy Mackay
0e1a2efb7c EKF3: RNG_USE_HGT param only used when ALT_SOURCE = rangefinder 2019-09-10 18:44:52 +10:00
Randy Mackay
94a52b3525 EKF2: RNG_USE_HGT param only used when ALT_SOURCE = rangefinder 2019-09-10 18:44:52 +10:00
Andrew Tridgell
b33afde884 HAL_ChibiOS: allow safety button on CUAV_GPS to be used for "stay in bootloader"
allows for recovery of bad CAN firmware
2019-09-10 16:22:33 +10:00
Andrew Tridgell
c6a9f067e2 HAL_ChibiOS: enable LEDs on CUAV_GPS 2019-09-10 16:22:33 +10:00
Andrew Tridgell
3dfe15443d HAL_ChibiOS: fixed orientation of CUAV_GPS compass 2019-09-10 16:22:33 +10:00
Andrew Tridgell
21cce1385a AP_UAVCAN: support safety buttons on UAVCAN
the button works in parallel with any button attached by IOMCU or by a
pin, and obeys all the same BRD_SAFETY* options
2019-09-10 16:22:33 +10:00
Andrew Tridgell
03c1a8bfd9 HAL_ChibiOS: use safety button logic from AP_BoardConfig 2019-09-10 16:22:33 +10:00
Andrew Tridgell
5a96e374ba AP_BoardConfig: moved logic for safety button press to AP_BoardConfig
this allows for common code between CAN and pin safety switches, as
well as making the code neater as most of the logic is related to
AP_BoardConfig options
2019-09-10 16:22:33 +10:00
Andrew Tridgell
82a98ef95d AP_Notify: added NTZ_BUZZ_VOLUME parameter
it is fairly non-linear, but does work
2019-09-10 16:22:33 +10:00
Andrew Tridgell
39f4f7c208 AP_UAVCAN: added safety LED and button messages 2019-09-10 16:22:33 +10:00
Andrew Tridgell
0ea67943b9 HAL_ChibiOS: enable safety button on CUAV_GPS 2019-09-10 16:22:33 +10:00
Andrew Tridgell
c6c1c4bc31 AP_UAVCAN: support safety LEDs on UAVCAN 2019-09-10 16:22:33 +10:00
Andrew Tridgell
186eedf838 HAL_ChibiOS: enable safety LED 2019-09-10 16:22:33 +10:00
Andrew Tridgell
75696997cc HAL_ChibiOS: added buzzer support to CUAV_GPS 2019-09-10 16:22:33 +10:00
Andrew Tridgell
7c57546eb1 AP_Notify: support UAVCAN buzzers 2019-09-10 16:22:33 +10:00
Andrew Tridgell
d55f76c88e AP_UAVCAN: added buzzer support 2019-09-10 16:22:33 +10:00
Peter Barker
8fc55b9678 GCS_MAVLink: remove comm_get_available
available returns an unsigned integer, so this was just weird
2019-09-10 15:45:27 +10:00
Andrew Tridgell
cbe0af2463 HAL_ChibiOS: setup for LEDs on KakuteF4
this makes Kopis1 display LEDs properly
2019-09-10 13:03:28 +10:00
Andrew Tridgell
a4924e1c0b AP_Notify: allow setting of LED count in hwdef.dat 2019-09-10 13:03:28 +10:00
Andrew Tridgell
28b5f2b021 AP_Notify: simplify NeoPixel driver
use new API to avoid complexities
2019-09-10 13:03:28 +10:00
Andrew Tridgell
f441223b55 HAL_ChibiOS: implement updated NeoPixel API
allow for N leds per chain, and setting separate colours per led in
each chain
2019-09-10 13:03:28 +10:00
Andrew Tridgell
1cb608a9f4 AP_HAL: allow neopixel LEDs to be set more flexibly
allow for N leds per chain, with RGB control of each
2019-09-10 13:03:28 +10:00
Tom Pittenger
aa602b5e1b AP_Notify: add NeoPixel driver 2019-09-10 13:03:28 +10:00
Tom Pittenger
e3416b66dc AP_HAL_ChibiOS: add Neopixel output type, similar to dshot 2019-09-10 13:03:28 +10:00
Tom Pittenger
52be3903c0 SRV_Channel: add neopixel as an output type 2019-09-10 13:03:28 +10:00
Randy Mackay
aba4a1fdc8 AC_Avoidance: remove OADatabase check that can never be true 2019-09-10 09:15:56 +10:00
Randy Mackay
0dd8525c99 AP_HAL_SITL: resolve compiler warning in sitl_airspeed by using fabsf 2019-09-10 09:15:56 +10:00
Randy Mackay
2d128e0079 AP_Proximity: remove unused var from AriSimSITL 2019-09-10 09:15:56 +10:00
Randy Mackay
d4b047fc1f SITL: Gripper_EPM compiler warning resolved by using float and fabsf 2019-09-10 09:15:56 +10:00
Randy Mackay
1fd7618238 SITL: remove unused time_diff member 2019-09-10 09:15:56 +10:00
Michael du Breuil
9a7d64e8fc AP_NavEKF3: Allow the GPS to be responsible for logging 2019-09-10 09:09:17 +10:00
Michael du Breuil
a4d10b2e86 AP_NavEKF2: Allow the GPS to be responsible for logging 2019-09-10 09:09:17 +10:00
Michael du Breuil
f857eb4640 AP_GPS: Take responsibility for logging the GPS if the EKF wants logging 2019-09-10 09:09:17 +10:00
Willian Galvani
b92473111c AP_LeakDetector: Mark Leak pins RebootRequired 2019-09-09 09:53:28 -07:00
Andy Piper
6f3334b460 AP_Filesystem: build fixes for SITL on macOS 2019-09-09 20:18:00 +10:00
Andrew Tridgell
91e8752c17 HAL_ChibiOS: wrap more libc functions
this saves a few k of flash as it avoids linking libc versions of some
functions
2019-09-09 13:31:30 +10:00
Andrew Tridgell
3166f84954 HAL_ChibiOS: added vsnprintf wrapper
this allows us to use a common snprintf implementation
2019-09-09 13:31:30 +10:00
Michael du Breuil
ba3cfbfb54 AP_RTC: Don't allow RTC times before 2019 2019-09-09 04:43:29 +10:00
Andrew Tridgell
aa20be4270 AP_RCProtocol: fixed SUMD with 16 channels
with 16 channels it is more than 3ms per frame
2019-09-07 10:02:26 +10:00
Andrew Tridgell
df387dc396 AP_Compass: allow rotation of BMM150 compass 2019-09-07 09:53:21 +10:00
Andrew Tridgell
1cb775e2c2 AP_Compass: probe more addresses for IST8310
IST8310 can be on 4 possible i2c addresses
2019-09-07 07:35:54 +10:00
Andrew Tridgell
5e5c30efe8 HAL_SITL: allow SITL to use SERIALn_PROTOCOL=23
this allows for testing of RC input protocol parsing in SITL
2019-09-06 08:51:45 +10:00
Andrew Tridgell
c8de2ec9c7 AP_RCProtocol: added update() method for use by SITL 2019-09-06 08:51:45 +10:00
Andrew Tridgell
4b48e80c26 AP_SerialManager: fixed AP_Periph build 2019-09-06 08:51:45 +10:00
Andrew Tridgell
83872c23e5 HAL_ChibiOS: fixed AP_Periph build 2019-09-06 08:51:45 +10:00
Andrew Tridgell
fd80220d3e HAL_ChibiOS: setup PH4-mini RCIN port by default 2019-09-06 08:51:45 +10:00
Andrew Tridgell
54649a0e4f HAL_ChibiOS: fixed KakuteF4 define for SERIAL2 2019-09-06 08:51:45 +10:00
Andrew Tridgell
06b272705e HAL_ChibiOS: run RCIN thread at 1kHz
this gives fast enough response for SBUS parsing on a UART
2019-09-06 08:51:45 +10:00
Andrew Tridgell
6983186210 AP_HAL: added get_options() method on UARTs 2019-09-06 08:51:45 +10:00
Andrew Tridgell
c841b39ea2 HAL_ChibiOS: switch to AP::RC() for AP_RCProtocol 2019-09-06 08:51:45 +10:00
Andrew Tridgell
bf2cf7834d HAL_ChibiOS: fixed a bug in parity/stop-bit setting on STM32F7 and H7
and add get_options() method
2019-09-06 08:51:45 +10:00
Andrew Tridgell
312018898f HAL_Linux: use AP::RC() 2019-09-06 08:51:45 +10:00
Andrew Tridgell
672d09c965 AP_IOMCU: use AP::RC() for AP_RCProtocol 2019-09-06 08:51:45 +10:00
Andrew Tridgell
cbdb23afb5 AP_SerialManager: support SERIALn_PROTOCOL=23 for RC input
sets up an extra RC input port
2019-09-06 08:51:45 +10:00
Andrew Tridgell
2b856abdd1 AP_RCProtocol: support an additional uart on RC input
this will allow for any UART to be configured as an additional RC
input source
2019-09-06 08:51:45 +10:00
Andrew Tridgell
ad2890dc5a HAL_ChibiOS: added connector pinouts for PH4-mini 2019-09-06 08:51:45 +10:00
Andrew Tridgell
b72dcf6478 AP_Filesystem: use a recursive semaphore
this is needed to cope with the mkdir("/APM") in sdcard_retry()
2019-09-06 08:51:04 +10:00
Andrew Tridgell
7afd51d03e AP_Frsky_Telem: move FrSky handling to it's own thread
we are getting timing issues sharing with the other users of the IO
thread. The FrSky protocols are quite timing sensitive, so this should
help
2019-09-05 10:50:17 +10:00
Randy Mackay
fb38db6640 AP_AHRS: resolve compile warning in AP_AHRS_DCM::use_compass 2019-09-05 08:39:10 +10:00
Andrew Tridgell
b344946300 HAL_ChibiOS: prevent duplicate sensors in hwdef.dat
throw an error on configure if there is a duplicate
2019-09-05 06:37:35 +10:00
Andrew Tridgell
2c5c8106a5 HAL_ChibiOS: removed duplicate barometer from fmuv5 2019-09-04 21:24:01 +10:00
Peter Barker
df5921a87c GCS_MAVLink: gate AP_DEVO_Telem behind !HAL_MINIMIZE_FEATURES 2019-09-04 17:47:33 +10:00
Andrew Tridgell
708ee47c03 HAL_ChibiOS: fixed f103 rm3100 2019-09-04 16:27:47 +10:00
Andrew Tridgell
c2c8702329 HAL_ChibiOS: convert remaining boards to use COMPASS specifier 2019-09-04 16:27:47 +10:00
Andrew Tridgell
3aa01448ff HAL_ChibiOS: use COMPASS specifier for f103-periph 2019-09-04 16:27:47 +10:00
Andrew Tridgell
f18a18c0ee AP_Baro: use GET_I2C_DEVICE() for i2c probes
for consistency with compass and INS
2019-09-04 16:27:47 +10:00
Andrew Tridgell
2bc7db4cca AP_HAL: removed old HAL_COMPASS_ defines (no longer used) 2019-09-04 16:27:47 +10:00
Andrew Tridgell
bd0760f9d4 AP_Compass: removed unusued compass probes
now only use probe lists
2019-09-04 16:27:47 +10:00
Andrew Tridgell
43e011c7a8 AP_HAL: convert Linux compass specification to new probe list
this avoids the special handling in AP_Compass library
2019-09-04 16:27:47 +10:00
Andrew Tridgell
3bc8522b54 AP_Compass: added ROTATION_NONE to probes
we no longer use defaults in the headers
2019-09-04 16:27:47 +10:00
Andrew Tridgell
f877def909 AP_Compass: removed default rotations for compass probe
this prevents bugs where the force_external and rotation are mixed up
in hwdef.dat causing incorrect rotations
2019-09-04 16:27:47 +10:00
Andrew Tridgell
2a48241ebb AP_Compass: fixed naming of QMC5883L driver
needed for probe using COMPASS macro in hwdef.dat
2019-09-04 16:27:47 +10:00
Andrew Tridgell
316e7cf7e6 HAL_ChibiOS: fixed mini-pix compass and baro probing
removed dup baro and fixed compass probe
2019-09-04 16:27:47 +10:00
Andrew Tridgell
2509b50852 AP_Baro: define GET_I2C_DEVICE() 2019-09-04 16:27:47 +10:00
Andrew Tridgell
15e15e0b9d AP_InertialSensor: define GET_I2C_DEVICE() 2019-09-04 16:27:47 +10:00
Andrew Tridgell
beca17c638 HAL_ChibiOS: use GET_I2C_DEVICE() for i2c probing
this allows for the driver probing to use a macro to prevent loading
of duplicate i2c devices (AP_Compass does this)
2019-09-04 16:27:47 +10:00
Michael du Breuil
e19f0ef238 AP_HAL_ChibiOS: Remove set_stop_pin from AnalogSource 2019-09-04 09:54:50 +10:00
Michael du Breuil
75b241622f AP_HAL_Empty: Remove set_stop_pin from AnalogSource 2019-09-04 09:54:50 +10:00
Michael du Breuil
979a431e4a AP_HAL_Linux: Remove set_stop_pin from AnalogSource 2019-09-04 09:54:50 +10:00
Michael du Breuil
69d3e97533 AP_HAL_SITL: Remove set_stop_pin from AnalogSource 2019-09-04 09:54:50 +10:00
Michael du Breuil
c12652b325 AP_Rangefinder: Remove stop pin usage 2019-09-04 09:54:50 +10:00
Michael du Breuil
927a0521e3 AP_HAL: Remove the empty force_safety_no_wait 2019-09-04 07:14:50 +10:00
Michael du Breuil
e5eeb6181d GCS_MAVLink: Remove the usage of force_safety_no_wait 2019-09-04 07:14:50 +10:00
Michael du Breuil
5711c2cbac AP_UAVCAN: Remove the usage of force_safety_no_wait 2019-09-04 07:14:50 +10:00
Michael du Breuil
53860b53ac AP_BoardConfig: Remove the usage of force_safety_no_wait 2019-09-04 07:14:50 +10:00
Michael du Breuil
a74f00d045 GCS_MAVLink: Remove single use method 2019-09-03 14:35:17 +10:00
Michael du Breuil
8adc6ba3ad AP_Notify: Add an alternate LED scheme 2019-09-03 11:50:52 +10:00
E Thomas
c09d6908ed Enabled active buzzer output on OmnibusNanoV6 2019-09-03 09:59:53 +10:00
Peter Barker
7ea449076f AP_NavEKF3: use timing logging from AP_NavEKF 2019-09-03 09:28:37 +10:00
Peter Barker
c8fac758ee AP_NavEKF2: use timing logging from AP_NavEKF 2019-09-03 09:28:37 +10:00
Peter Barker
6d71ef5cf8 AP_Logger: move EKF timing logging out to EKF 2019-09-03 09:28:37 +10:00
Peter Barker
9e0f525f69 AP_NavEKF: move logging in from AP_Logger 2019-09-03 09:28:37 +10:00
Peter Barker
9da0efaaef GCS_MAVLink: fill SYS_STATUS bits from AC_Fence 2019-09-03 09:12:24 +10:00
Andrew Tridgell
9c900c7176 AP_RangeFinder: added driver for Lanbao CM8JL65 2019-09-03 09:10:48 +10:00
Peter Hall
2f3c0447eb RC_Channel: add fence and value for rover 2019-09-02 11:03:27 +09:00
Andrew Tridgell
172c802ffa AP_RangeFinder: support native I2C protocol on LightWare Lidars
this supports both the native and the legacy I2C protocol for
LightWare Lidars. The native protocol is a string based protocol that
is enabled by default on new Lidars. By supporting both protocols we
avoid the need for users to re-configure their new lidar using a
serial cable before using it on I2C.

This driver was originally written by Mitch Koch and Jonathan
Challinger, and ported to master by me (it required only minor
changes)
2019-09-02 07:20:22 +10:00
Peter Hall
fdb6da0793 RC_Channel: define sailboat mainsail and motor input channels
The unusual use of 207 is in preparation for Peter Barker's RCMAP replacement PR which uses 200 to 206
2019-09-01 09:11:25 +09:00
Peter Hall
3dd0ebaf0d AP_WindVane: add wind_speed_enabled method 2019-09-01 09:11:25 +09:00
Peter Barker
ca5ee2bfbc AP_Param: correct fetching of flags for parameters
This was sending through the flags for the group the parameter was in,
rather than the parameter itself.
2019-08-30 06:57:30 +10:00
Andrew Tridgell
bcb139f02f AP_Compass: fixed uninitialised CAN device ID bits 2019-08-29 18:37:03 +10:00
Rajat Singhal
80bbadf9ca SITL: AirSim: Store last timestamp only
Also change the datatype of deltat
2019-08-29 08:32:19 +10:00
Rajat Singhal
86a70e5797 SITL: Remove redundant timestep in Airsim backend 2019-08-29 08:32:19 +10:00
Rajat Singhal
c056548f0d SITL: Enable Arming Checks in airsim-copter params 2019-08-29 08:32:19 +10:00
Michael du Breuil
fa6e43be77 AP_Logger: Forward declare AHRS
This reduces the number of places this is implicitly included, and helps
to reduce the scope of files that get rebuilt
2019-08-28 13:13:03 +10:00
Michael du Breuil
fe279b03b6 SITL: Directly include needed headers 2019-08-28 13:13:03 +10:00
Michael du Breuil
c85c9faa6d GCS_MAVLink: Directly include needed headers 2019-08-28 13:13:03 +10:00
Michael du Breuil
1a5627ae54 AP_VisualOdom: Directly include needed headers 2019-08-28 13:13:03 +10:00
Michael du Breuil
04863f858d AP_Terrain: Directly include needed headers 2019-08-28 13:13:03 +10:00
Michael du Breuil
17cec7cf2b AP_Landing: Directly include needed headers 2019-08-28 13:13:03 +10:00
Michael du Breuil
ca0dad9a7f AP_GPS: Directly include needed headers 2019-08-28 13:13:03 +10:00
Michael du Breuil
5d888abfec AP_Baro: Directly include needed headers 2019-08-28 13:13:03 +10:00
Michael du Breuil
d8bce8295e AP_Arming: Directly include needed headers 2019-08-28 13:13:03 +10:00
Peter Barker
78af091869 AP_Logger: log parameter space used as part of log open 2019-08-28 11:51:09 +10:00
Peter Barker
b493805fb4 AP_Param: methods to provide amount of parameter space used
AP_Param: provide method for storage size
2019-08-28 11:51:09 +10:00
Peter Barker
2d1357b44c AP_Mount: stop passing serial manager through to init() 2019-08-28 06:55:28 +10:00
Andrew Tridgell
6cecf15e6a AP_Baro: remove unused baro probe lines 2019-08-28 06:54:11 +10:00
Andrew Tridgell
7fa6eeaaed AP_HAL: remove unused HAL_BARO_ defines 2019-08-28 06:54:11 +10:00
Andrew Tridgell
9d94598235 AP_HAL: convert linux boards to use baro probe list 2019-08-28 06:54:11 +10:00
Andrew Tridgell
72494788f7 HAL_ChibiOS: convert more boards to use BARO specifier 2019-08-28 06:54:11 +10:00
Andrew Tridgell
60a6f1b04a AP_HAL: removed most HAL_INS_* defines
not used any more
2019-08-28 06:54:11 +10:00
Andrew Tridgell
1c92ecc89f AP_InertialSensor: removed old method of specifying most IMUs
and removed dangerous default values for rotations
2019-08-28 06:54:11 +10:00
Andrew Tridgell
0667747506 HAL_ChibiOS: convert some more boards to new IMU specifiers 2019-08-28 06:54:11 +10:00
Andrew Tridgell
96180018fb AP_HAL: convert HAL_Linux to use HAL_INS_PROBE_LIST
makes for much simpler addition of new boards, especially with more
than one IMU
2019-08-28 06:54:11 +10:00
Jaaaky
d7abd636ac AP_HAL_SITL: Fix build with --sitl-flash-storage option 2019-08-28 06:23:04 +10:00
Andrew Tridgell
dcd9003831 Revert "AP_Mission: Better AUTO watchdog restore"
This reverts commit d774bf3ea5.
2019-08-27 13:18:12 -06:00
Andrew Tridgell
5ce4ff916e HAL_ChibiOS: fixed Pixhawk1 gyro orientation
this was broken by the recent switch to hwdef.dat for orientations
2019-08-27 19:29:37 +10:00
Andrew Tridgell
c99923d500 AP_InertialSensor: require gyro orientations in LSM9DS probe
this prevents a bug where they are missing in hwdef.dat
2019-08-27 19:29:37 +10:00
Andrew Tridgell
d40835c666 AP_Logger: use AP::FS().set_mtime() 2019-08-27 15:40:43 +10:00
Andrew Tridgell
b489e8a655 AP_Filesystem: added set_mtime() call 2019-08-27 15:40:43 +10:00
Andrew Tridgell
0ffe2e75be HAL_ChibiOS: fixed warnings 2019-08-27 15:40:43 +10:00
Andrew Tridgell
df4cb00970 AP_Logger: added LOG_FILE_TIMEOUT parameter
this allows for cards to be removed and re-inserted while continuing
logging
2019-08-27 15:40:43 +10:00
Andrew Tridgell
b577787f68 AP_Scripting: use AP_Filesystem API 2019-08-27 15:40:43 +10:00
Andrew Tridgell
667b4e045a AP_Logger: convert to use AP_Filesystem 2019-08-27 15:40:43 +10:00
Andrew Tridgell
fb50ec2a1d AP_Notify: convert to use AP_Filesystem 2019-08-27 15:40:43 +10:00
Andrew Tridgell
d160f14856 AP_UAVCAN: convert to use AP_Filesystem 2019-08-27 15:40:43 +10:00
Andrew Tridgell
a4860afd32 AP_Terrain: convert to use AP_Filesystem 2019-08-27 15:40:43 +10:00
Andrew Tridgell
a4258639c8 AP_Proximity: use strtol instead of sscanf 2019-08-27 15:40:43 +10:00
Andrew Tridgell
9d760a2956 HAL_ChibiOS: disable re-entrancy in FATFS
not needed now we have a semaphore in AP_Filesystem
2019-08-27 15:40:43 +10:00
Andrew Tridgell
bf79b65e07 HAL_ChibiOS: simplify stubs code 2019-08-27 15:40:43 +10:00
Andrew Tridgell
d1565a96c5 HAL_ChibiOS: wrap cacheBuffer functions
needed to avoid problem with end() method in UARTDriver shadowing with
F7 implementation of cache macros
2019-08-27 15:40:43 +10:00
Andrew Tridgell
b867ef35c0 HAL_ChibiOS: use AP_Filesystem API 2019-08-27 15:40:43 +10:00
Andrew Tridgell
692abb11fa AP_Filesystem: define new filesystem API 2019-08-27 15:40:43 +10:00
Michael du Breuil
7fdc9fef12 AP_Scripting: Garbage collect after each run of a script
For some reason this resolves a memory leak in a tight loop of file
open, close. This also extends the memory debug printing to be a bit
more useful.
2019-08-27 13:54:54 +10:00
Michael du Breuil
1484a12f4b AP_HAL_Linux: Fix bad check order on heap_realloc 2019-08-27 13:54:54 +10:00
Michael du Breuil
2d40250f9b AP_HAL_SITL: Fix bad check order on heap_realloc 2019-08-27 13:54:54 +10:00
Andrew Tridgell
b30f3697d2 HAL_ChibiOS: fixed build without ISR limit 2019-08-27 10:29:56 +10:00
Andrew Tridgell
97c56c068e HAL_ChibiOS: update board IDs for AP_Periph firmwares 2019-08-27 10:29:56 +10:00
Andrew Tridgell
63f39c2bd6 HAL_ChibiOS: fixed build of iomcu firmware 2019-08-27 10:29:56 +10:00