Commit Graph

20790 Commits

Author SHA1 Message Date
Peter Barker 11760c33f6 AP_NavEKF: avoid use of undefined #defines
Ensure EKF_DISABLE_INTERRUPTS is defined

Do not define MATH_CHECK_INDEXES, assume it is defined
2016-02-19 12:34:24 -02:00
Peter Barker 80bc7a50d7 AP_Math: define MATH_CHECK_INDEXES
Wrapped in ifndefs so the top-level Makefile can override

Assume MATH_CHECK_INDEXES is always defined
2016-02-19 12:34:23 -02:00
Peter Barker ca4017d093 Plane: defines.h should not use defines from config.h
config.h includes defines.h early, so defines in config.h are unavailable
2016-02-19 12:34:23 -02:00
Peter Barker 44c63b8873 Copter: move use of defines after config.h and defines.h 2016-02-19 12:34:23 -02:00
Lucas De Marchi 3ace8b52de AP_HAL_Linux: use AnalogIn_IIO for minlure 2016-02-19 11:55:31 -02:00
Lucas De Marchi f865e085b1 AP_BattMonitor: add defaults for minlure 2016-02-19 11:55:31 -02:00
Lucas De Marchi 4e034cd2e1 AP_HAL_Linux: AnalogIn_IIO: add scale for minlure 2016-02-19 11:55:31 -02:00
Lucas De Marchi f56a80cd80 AP_HAL_Linux: AnalogIn_IIO: return fixed board voltage
Return board voltage as 5V so we don't fail prearm checks.
2016-02-19 11:55:31 -02:00
Lucas De Marchi d387deb2f5 PID: fix example using wrong type
pid.imax() has type int16_t

../../libraries/PID/examples/pid/pid.cpp:36:53: warning: format ‘%f’ expects argument of type ‘double’, but argument 6 has type ‘int’ [-Wformat=]
             pid.kP(), pid.kI(), pid.kD(), pid.imax());
                                                     ^
2016-02-19 11:51:49 -02:00
Lucas De Marchi edd3e3c34a Filter: silence warning about unused function
../../libraries/Filter/examples/Derivative/Derivative.cpp:16:14: warning: ‘float noise()’ defined but not used [-Wunused-function]
 static float noise(void)
              ^
2016-02-19 11:51:49 -02:00
Lucas De Marchi 1f072c4353 AP_HAL: fix unused variable
../../libraries/AP_HAL/examples/UART_test/UART_test.cpp:13:28: warning: ‘uarts’ defined but not used [-Wunused-variable]
 static AP_HAL::UARTDriver* uarts[] = {
                            ^
2016-02-19 11:51:49 -02:00
Andrew Tridgell cc626d2fc7 PX4Firmware: submodule update (SBUS fix) 2016-02-19 22:30:28 +11:00
Jonathan Challinger c454631be8 AP_InertialSensor: work around gyro and accel errors on startup 2016-02-19 16:40:52 +09:00
Paul Riseborough 047e9fabaf AP_NavEKF2: Fix bug in simple heading fusion
The innovation calculation should have been updated when the heading fusion maths was updated.

We now use a direct heading or yaw angle measurement in the derivation, not the difference between observed and published declination.
2016-02-19 15:35:11 +09:00
Lucas De Marchi bf9cf74c38 StorageManager: replace header guard with pragma once 2016-02-18 14:52:35 -02:00
Lucas De Marchi 98904825cb Filter: replace header guard with pragma once 2016-02-18 14:52:35 -02:00
Lucas De Marchi f5437f30ac AP_Scheduler: replace header guard with pragma once 2016-02-18 14:52:35 -02:00
Lucas De Marchi 008e3c9810 AP_OpticalFlow: replace header guard with pragma once 2016-02-18 14:52:35 -02:00
Lucas De Marchi 09d926fa11 AP_Notify: replace header guard with pragma once 2016-02-18 14:52:35 -02:00
Lucas De Marchi 705393b30c AP_HAL_Linux: replace header guard with pragma once 2016-02-18 14:52:35 -02:00
Lucas De Marchi dbf2aedf1e AP_HAL: replace header guard with pragma once 2016-02-18 14:52:34 -02:00
Lucas De Marchi 2bed317c6c AP_HAL_Empty: replace header guard with pragma once 2016-02-18 14:52:34 -02:00
Lucas De Marchi 1a71c169fe AP_Compass: replace header guard with pragma once 2016-02-18 14:52:34 -02:00
Lucas De Marchi 246f940d01 AP_Buffer: replace header guard with pragma once 2016-02-18 14:52:34 -02:00
Lucas De Marchi 62f50aede7 AP_BattMonitor: replace header guard with pragma once 2016-02-18 14:52:34 -02:00
Lucas De Marchi 6623246cf5 AP_ADC: replace header guard with pragma once 2016-02-18 14:52:34 -02:00
Gustavo Jose de Sousa 393bea8945 waf: boards: use classes for boards definition
In order to provide board-specific behavior. For example, the incoming PX4
build will require custom build behavior.
2016-02-18 14:33:46 -02:00
Leonard Hall 49a4bde5d9 AC_AttControl: lower minimum accelerations for large copters 2016-02-18 20:49:13 +09:00
Leonard Hall 8e790d3f91 Copter: autotune adjustment for large copters 2016-02-18 20:49:12 +09:00
mirkix 8da58226ae AP_HAL_Linux: Fix BBBmini IIO scaling 2016-02-18 00:00:07 -02:00
mirkix d868fe4eff AP_HAL: Remove unused GPIO leds for BBBmini 2016-02-17 23:41:24 -02:00
Paul Riseborough d3c9a0aef1 AP_NavEKF: Limit heading innovations after the consistency check 2016-02-18 08:53:47 +09:00
Paul Riseborough 6a34e4c384 AP_NavEKF2: Fix bug in magnetic heading and declination fusion equations.
The derivation incorrectly used a tan instead of an atan function. This applies the corrected auto-code.
2016-02-18 08:53:45 +09:00
Paul Riseborough 59bf29198d AP_NavEKF2: Remove unnecessary logic preventing constant position
This removes a legacy design concept that is no longer required in this filter implementation. Planes will not be armed without EKF aiding and the proposed copter throw mode also requires EKF aiding to be operating.
The other problem with interrupting fusion during the launch is it doesn't reduce the corrections, it just delays them as wen the launch completes, the EKF inertial position estimate is still moving still moved and the corrections are therefore just delayed by the short launch interval.

Thank you to OXINARF for picking up the inconsistency with the previous logic
2016-02-18 08:53:43 +09:00
Paul Riseborough 7e05646316 AP_NavEKF2: Improvements to non-GPS performance
Change to user adjustable fusion of constant position (as per legacy EKF) instead of constant velocity.
Enable user to specify use of 3-axis magnetometer fusion when operating without aiding.
Don't allow gyro scale factor learning without external aiding data as it can be unreliable
2016-02-18 08:53:41 +09:00
Tom Pittenger a9c985bfb3 AP-Mount: compiler warning
ardupilot/libraries/AP_Mount/SoloGimbal_Parameters.cpp:193:107: warning: comparing floating point with == or != is unsafe [-Wfloat-equal]
2016-02-17 14:54:31 -08:00
Tom Pittenger d0edfa5dfa Plane: compile warning fix
/ardupilot/ArduPlane/quadplane.cpp:773:107: warning: implicit conversion from 'float' to 'double' when passing argument to function [-Wdouble-promotion]
2016-02-17 14:54:02 -08:00
Tom Pittenger 0b26a34f22 Plane: new param LAND_THEN_NEUTRL
// @Description: When enabled, after an autoland and auto-disarm via LAND_DISARMDELAY happens then set all servos to neutral. This is helpful when an aircraft has a rough landing upside down or a crazy angle causing the servos to strain.
2016-02-16 23:40:44 -08:00
Lucas De Marchi 10abec277d AP_HAL: functor: use std::remove_reference 2016-02-16 19:49:09 -02:00
Lucas De Marchi 1b55f5f994 mk: fixup qurt and qflight boards with -DHAVE_STD_REMOVE_REFERENCE=0 2016-02-16 19:49:09 -02:00
Lucas De Marchi d80a0e47bc AP_Common: missing: move definitions to standard headers
This way we don't create problems regarding which header to include: we
just include the normal/c++11 headers and everything works as it should.
2016-02-16 19:49:09 -02:00
Lucas De Marchi 75d58bcfb6 Global: rename HAVE_NULLPTR_T with HAVE_STD_NULLPTR_T
This makes for a more standard name for these overrides.
2016-02-16 19:49:09 -02:00
Andrew Tridgell 815d653283 mk: fixup qurt and qflight builds with HAVE_STD_MOVE=0 2016-02-16 19:49:09 -02:00
Andrew Tridgell 29100937bc AP_Common: allow for nullptr_t but not std::move replacement 2016-02-16 19:49:09 -02:00
Andrew Tridgell 52e36908ff AP_Common: fixed std::move() for qurt build
Thanks Lucas!
2016-02-16 19:49:09 -02:00
Lucas De Marchi cc4504e613 AP_Airspeed: fix coding style
- replace tabs with spaces
  - remove C-style void from function arguments
  - use pragma once
  - fix pointer alignement
  - remove unused header: AP_Airspeed_I2C_PX4 - we actually use
    AP_Airspeed_PX4
2016-02-16 19:49:09 -02:00
Lucas De Marchi 02a7fa5c2b AP_InertialSensor: MPU9250: use AP_HAL::Device abstraction
This makes MPU9250 be almost the same as MPU6000 driver. Work has been
done here to make than similar so it's easier to spot the differences.
2016-02-16 19:49:09 -02:00
Lucas De Marchi d2b267d026 AP_InertialSensor: LSM9DS0: use AP_HAL::SPIDevice abstraction 2016-02-16 19:49:09 -02:00
Lucas De Marchi 58f4624f8c AP_InertialSensor: L3G4200D: use AP_HAL::I2CDevice abstraction 2016-02-16 19:49:09 -02:00
Lucas De Marchi af846636e4 AP_InertialSensor: MPU60x0: use AP_HAL::Device abstraction 2016-02-16 19:49:09 -02:00