Commit Graph

11627 Commits

Author SHA1 Message Date
Saloni Jain ff843448aa AC_Fence: Added a new function to check whether the guided waypoint is within the fence 2016-05-21 09:56:12 +09:00
Gustavo Jose de Sousa 9a100afede AP_HAL_Linux: Thread: add doc about rounding function 2016-05-20 16:31:15 -03:00
Lucas De Marchi 359417d544 AP_HAL_Linux: Thread: make sure pointer is aligned
Implementation of alloca() is very much architecture and compiler
dependent. Avoid the case in which it could return a non-aligned
pointer, which would mean Thread::_poison_stack() would do the wrong
thing.
2016-05-20 16:31:15 -03:00
Lucas De Marchi 7e49d0c53f AP_HAL_Linux: Thread: fix alignment warning
../../libraries/AP_HAL_Linux/Thread.cpp: In member function ‘void Linux::Thread::_poison_stack()’:
../../libraries/AP_HAL_Linux/Thread.cpp:87:31: warning: cast from ‘uint8_t* {aka unsigned char*}’ to ‘uint32_t* {aka unsigned int*}’ increases required alignment of target type [-Wcast-align]
         for (p = (uint32_t *) end; p > curr; p--) {
                               ^
../../libraries/AP_HAL_Linux/Thread.cpp:93:31: warning: cast from ‘uint8_t* {aka unsigned char*}’ to ‘uint32_t* {aka unsigned int*}’ increases required alignment of target type [-Wcast-align]
         for (p = (uint32_t *) end; p < curr; p++) {
                               ^
../../libraries/AP_HAL_Linux/Thread.cpp:98:39: warning: cast from ‘uint8_t* {aka unsigned char*}’ to ‘uint32_t* {aka unsigned int*}’ increases required alignment of target type [-Wcast-align]
     _stack_debug.start = (uint32_t *) begin;
                                       ^
../../libraries/AP_HAL_Linux/Thread.cpp:99:37: warning: cast from ‘uint8_t* {aka unsigned char*}’ to ‘uint32_t* {aka unsigned int*}’ increases required alignment of target type [-Wcast-align]
     _stack_debug.end = (uint32_t *) end;
                                     ^
2016-05-20 16:31:15 -03:00
Lucas De Marchi 18af4da690 AP_HAL_Linux: Thread: fix warning regarding shadow member
../../libraries/AP_HAL_Linux/Thread.cpp: In member function ‘void Linux::Thread::_poison_stack()’:
../../libraries/AP_HAL_Linux/Thread.cpp:63:20: warning: declaration of ‘start’ shadows a member of 'this' [-Wshadow]
     uint8_t *end, *start, *curr;
                    ^
2016-05-20 16:31:15 -03:00
Tom Pittenger 684ac12dd6 AC_WPNav: fix compile when using AP_TERRAIN_AVAILABLE 0 2016-05-20 12:29:19 -07:00
Tom Pittenger f085666032 AP_Common: fix compile when using AP_TERRAIN_AVAILABLE 0 2016-05-20 12:28:46 -07:00
Leandro Pereira 3555e439a4 AP_HAL_Linux: Simplify I2C initialization in HAL_Linux_Class 2016-05-20 10:12:17 -03:00
Aaron Wang Shi cb9cd9008a AP_HAL_Linux: fix bhat spi device driver build error 2016-05-20 10:09:50 -03:00
Lucas De Marchi 035937ea7e AP_GPS: add some safety checks to _parse_decimal_100() 2016-05-20 10:06:45 -03:00
Lucas De Marchi 994b2fc966 AP_GPS: add unit test for _parse_decimal_100() 2016-05-20 10:06:44 -03:00
Lucas De Marchi fc6dd97e61 AP_GPS: make _parse_decimal_100() a static function
This allows to easily write tests for it as opposed to having to
construct the entire object.
2016-05-20 10:06:44 -03:00
Bert Regelink 7379d120e1 AP_GPS: fix _parse_decimal_100() with negative numbers
_parse_decimal_100() did not parse the fractional part for negative
numbers. Furthermore, use the third decimal (when present) for proper
rounding.
2016-05-20 10:06:44 -03:00
AndersonRayner aaa8709194 AP_RPM: Added an example script 2016-05-19 19:01:03 -03:00
Vinicius Juvinski ed2718a183 AP_Notify: Buzzer: change pin 11(P8_31) to pin 12(P8_32)
Avoid boot conflict during power on.
2016-05-19 17:22:27 -03:00
Randy Mackay 54731a139f AP_Mission: rename starts_with_takeoff_cmd 2016-05-19 19:43:22 +09:00
Niti Rohilla 9ec0000691 AP_Mission: add check_takeoff_cmd
This checks that the first command in the mission is a takeoff command which helps avoid mission setup errors in which users forget to start a mission with a takeoff command
2016-05-19 19:43:17 +09:00
Niti Rohilla d771017c25 AP_Mission: support MAV_CMD_NAV_DELAY command 2016-05-19 16:16:02 +09:00
Randy Mackay 67620f312d AP_HAL: fix comment for get_time_utc 2016-05-19 16:05:29 +09:00
Niti Rohilla faec752801 AP_HAL: add get_system_clock_utc functions to Util 2016-05-19 16:05:26 +09:00
Andrew Tridgell 4080c6091d AP_NavEKF2: fixed an assumption that _ahrs->get_compass() always works
if MAG_ENABLE=0 in plane there is no compass
2016-05-19 14:16:40 +10:00
Lucas De Marchi 71e10c9132 AP_HAL_Linux: fix include order
Sort include alphabetically and make them in order:

Main header
system headers
library headers
local headers

While reordering, change a include of endian.h to our sparse-endian.h
which is more reliant to toolchain changes.
2016-05-18 23:05:56 -03:00
Lucas De Marchi 45c6b750f2 AP_HAL_Linux: remove ifdef checks for HAL_BOARD_LINUX
Everything inside libraries/AP_HAL_Linux is for Linux boards, there's
not need to add the ifdefs.
2016-05-18 23:05:56 -03:00
Lucas De Marchi c4306de122 AP_Common: fix build on windows
The way the build was fixed for gcc >= 5.3 breaks the build for older
compiler versions on waf. Fix this by ifdef'ing for WAF_BUILD and
checking the compiler version.
2016-05-18 22:56:50 -03:00
Lucas De Marchi 9ccce2c980 AP_Compass: explicitely add compasses for erlebrain2, pxf and pxfmini 2016-05-18 18:24:14 -03:00
Lucas De Marchi 8372e74c0f AP_Compass: simplify handling of sensors for Linux boards
In addition:
    - bbbmini, navio and navio2 can force HMC5843 backend to
      be external.
    - there was a typo in the backend name that's now fixed:
      AK8953 vs AK8963
2016-05-18 18:24:14 -03:00
Lucas De Marchi 1ddbafabdd AP_Compass: add name field to internal compass drivers 2016-05-18 18:24:14 -03:00
Gustavo Jose de Sousa ef61096e08 AP_Math: geodesic_grid tool: show triangle number for sections too 2016-05-18 13:28:52 -03:00
Gustavo Jose de Sousa a6deb65d95 AP_Math: geodesic_grid tool: add option --section 2016-05-18 13:28:52 -03:00
Andrew Tridgell f7ac6c8d86 AP_Compass: make internal compasses use a higher cal threshold
they tend to be a lot noisier
2016-05-18 16:32:32 +10:00
Tom Pittenger d67b1edf10 AP_NavEKF2: (potential) compiler warning of float to double promotion 2016-05-17 20:30:51 -07:00
Tom Pittenger 3c6323dd82 AP_TECS: Log TEC2.LF as Aerodynamic Load Factor 2016-05-17 20:17:27 -07:00
Tom Pittenger 32d51e346d DataFlash: optimize logging climbrate - call function one and reuse result 2016-05-17 18:59:14 -07:00
Tom Pittenger ad11f3815b AP_HAL_SITL: rename aspd variables to arspd 2016-05-17 16:36:14 -07:00
Tom Pittenger c77a5e6764 SITL: rename aspd variables and params to arspd 2016-05-17 16:36:07 -07:00
Tom Pittenger d55401aa18 AP_Tuning: fixed float->double promotion compiler warning 2016-05-17 16:32:10 -07:00
Tom Pittenger ae91804aaa AP_Arming: updated comment for z-axis accel threshold 2016-05-17 16:31:42 -07:00
Tom Pittenger f9335e9d8c AP_TECS: fixed float->double print warning 2016-05-17 15:58:03 -07:00
Lucas De Marchi 1ac712fa65 AP_Math: fix is_zero() after template conversion 2016-05-17 15:49:29 -07:00
Andrew Tridgell 7b47d54d6b AP_Common: workaround for SITL on windows 2016-05-17 20:55:57 +10:00
Lucas De Marchi fa6f2c6b67 AP_Math: fix some coding style mistakes
- fix alignement of &
    - remove const from bool arguments
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 0c31354539 AP_Compass: implement completion mask
Fill the completion mask and send that through MAVLink while calibrating the
compass.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 390b196eda AP_Math: AP_GeodesicGrid: add notice for auto generated code 2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa b3068baa11 AP_Math: add geodesic_grid toolset
That was used to aid development AP_GeodesicGrid and understanding its
concepts.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 9d34b3b996 AP_Math: AP_GeodesicGrid: make all methods static
Since all members are.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 3b05ec1157 AP_Math: make vectors and matrix constructors constexpr
That allows some object to be constructed at compile time.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 77223a7fcb AP_Math: AP_GeodesicGrid: make data static
That gives the change of storing that data in flash storage in some
architectures. That doesn't happen yet though, some extra changes are required
for that to happen.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa fd2428db34 AP_Math: AP_GeodesicGrid: reduce number of _neighbor_umbrellas items
Only the first half is necessary. The values for the other half can be derived.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 43d9e00ab7 AP_Math: AP_GeodesicGrid: use uint8_t for _neighbor_umbrellas
All integers there are limited to the range [0,20), so uint8_t is enough.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 54889e4175 AP_Math: AP_GeodesicGrid: reduce number of inverses by half
We don't actually need all of them, since the second half is for the opposite
triangles. In that case we just need to negate the resulting vector when
changing basis.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa f31161ecb6 AP_Math: AP_GeodesicGrid: remove triangles
There's no need to keep those triangles, since we just need the inverses.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa b34c04a4f9 AP_Math: test_geodesic_grid: test also non-centroid vectors 2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 8e8ab3af96 AP_Math: AP_GeodesicGrid: remove section_triangle() function
That function was only being used by the unit tests and the benchmark. In order
to remove memory usage, the triangles will be removed, since we don't actually
need to keep them in real situations. Thus, this patch removes that function
and copy those triangles to the test and benchmark.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa c7eb46fae2 AP_Math: AP_GeodesicGrid: optimize _from_neighbor_umbrella()
This is the second optimization. With that we don't have to iterate over the
umbrella's components.

The table below summarizes the mean CPU time in ns from the brenchmark results
on an Intel(R) Core(TM) i7-3520M CPU @ 2.90GHz processor:

       | Naive implementation | First Optimization | Second Optimization
------------------------------------------------------------------------
Min.   |                 26.0 |              28.00 |                26.0
1st Qu.|                 78.0 |              48.75 |                39.0
Median |                132.0 |              57.00 |                41.0
Mean   |                130.1 |              61.20 |                41.6
3rd Qu.|                182.2 |              76.00 |                47.0
Max.   |                234.0 |              98.00 |                54.0
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa eb90ef23a1 AP_Math: AP_GeodesicGrid: fix algorithm for null vector
If v is the null vector, then alpha * v is still the null vector for any alpha
as a real number. That means that the null vector doesn't cross any section.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa c28c3265c8 AP_Math: AP_GeodesicGrid: optimize with neighbor umbrellas
This is a first optimization of the algorithm. The struct for the neighbor
umbrella has only one member, but new members will be added in the next
optimization.

The table below summarizes the mean CPU time in ns from the brenchmark results
on an Intel(R) Core(TM) i7-3520M CPU @ 2.90GHz processor:

Cases  | Naive implementation | First Optimization
--------------------------------------------------
Min.   |                 26.0 |              28.00
1st Qu.|                 78.0 |              48.75
Median |                132.0 |              57.00
Mean   |                130.1 |              61.20
3rd Qu.|                182.2 |              76.00
Max.   |                234.0 |              98.00

This optimization reduces the mean time for the worst case (Max. line) by more
than 50%.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 0ff05b7af3 AP_Math: test_geodesic_grid: test triangles indexes
That helps figuring out which intermediate step failed the high level call.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 4398e1e49b AP_Math: AP_GeodesicGrid: change order of triangles
- Change the order of the icosahedron triangles so that there's a uniform way of
finding the opposite triangle. The order visually still makes sense.

 - Change test to accommodate the order change.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa ea412ad629 AP_Math: benchmark_geodesic_grid: add benchmark
That will help to benchmark improvements on the section search algorithm.
2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa 797a2da031 AP_Math: test_geodesic_grid: test when inclusive=true 2016-05-16 19:08:36 -03:00
Gustavo Jose de Sousa b299261ad4 AP_Math: AP_GeodesicGrid: add first implementation
The search for the geodesic section is still naive in this version.
Additionally, add unit tests.
2016-05-16 19:08:35 -03:00
Gustavo Jose de Sousa 3f2ad764ca AP_Math: Matrix3: add inverse() and invert() functions
Additionally, add unit tests.
2016-05-16 19:08:35 -03:00
Gustavo Jose de Sousa 06eea2838f AP_Math: Matrix3: add det() function
Function to calculate determinant. Additionally, add unit tests.
2016-05-16 19:08:35 -03:00
Gustavo Jose de Sousa 26959f1448 AP_Math: define golden ratio constant 2016-05-16 19:08:35 -03:00
dgrat f8540f1a80 AP_Compass: Do not use is_zero() for non-float types 2016-05-16 19:08:35 -03:00
dgrat 7ff8004f8f AP_Math: Replace is_zero() with a template function
This function only makes sense for floating point types. However this
function was also used for ints.
2016-05-16 19:08:35 -03:00
Tom Pittenger ebd993dabb AP_Arming: updated z-axis accel threshold comment 2016-05-16 13:46:17 -07:00
Tom Pittenger 9073ac91ff AP_Mission: 2of3 add loiter_xtrack option flag for post-loiter navigation via param4
0 to crosstrack from center of waypoint, 1 to crosstrack from tangent exit location
2016-05-16 11:50:54 -07:00
Tom Pittenger 02eeb2d4f0 AP_Common: 1of3 add loiter_xtrack option flag for post-loiter navigation
0 to crosstrack from center of waypoint, 1 to crosstrack from tangent exit location
2016-05-16 11:50:53 -07:00
Gustavo Jose de Sousa 2246343ec7 AP_HAL_SITL: pass signed value to abs()
Passing an unsigned value to abs() causes compilation error in gcc 6.1.1
(and doing that doesn't make sense too).

As a bonus, this patch fixes the code, since, for two unsigned integers
a and b, such that a > b, (a - b) without the casting to a signed
integer would produce garbage in the context of this patch. The type
int32_t is enough for the cases covered by this patch.
2016-05-16 15:04:22 -03:00
Lucas De Marchi 421b9ef54a AP_Mount do not use flexible array in union
We actually don't want a flexible array in this union, but rather a way
to access it byte by byte. This fixes the build for gcc >= 6

In file included from ../../libraries/AP_GPS/AP_GPS_UBLOX.cpp:23:0:
../../libraries/AP_GPS/AP_GPS_UBLOX.h:387:23: error: flexible array member in union
         uint8_t bytes[];
                       ^
compilation terminated due to -Wfatal-errors.

In file included from ../../libraries/AP_Mount/AP_Mount.cpp:9:0:
../../libraries/AP_Mount/AP_Mount_Alexmos.h:291:23: error: flexible array member in union
         uint8_t bytes[];
                       ^
compilation terminated due to -Wfatal-errors.
2016-05-16 13:50:56 -03:00
Lucas De Marchi 39bd196481 AP_GPS: do not use flexible array in union
We actually don't want a flexible array in this union, but rather a way
to access it byte by byte. This fixes the build for gcc >= 6

In file included from ../../libraries/AP_GPS/AP_GPS.cpp:24:0:
../../libraries/AP_GPS/AP_GPS_ERB.h:93:23: error: flexible array member in union
         uint8_t bytes[];
                       ^
compilation terminated due to -Wfatal-errors.

In file included from ../../libraries/AP_GPS/AP_GPS_ERB.cpp:22:0:
../../libraries/AP_GPS/AP_GPS_ERB.h:93:23: error: flexible array member in union
         uint8_t bytes[];
                       ^
compilation terminated due to -Wfatal-errors.

In file included from ../../libraries/AP_GPS/AP_GPS_MTK.cpp:25:0:
../../libraries/AP_GPS/AP_GPS_MTK.h:75:23: error: flexible array member in union
         uint8_t bytes[];
                       ^
compilation terminated due to -Wfatal-errors.

In file included from ../../libraries/AP_GPS/AP_GPS_MTK19.cpp:26:0:
../../libraries/AP_GPS/AP_GPS_MTK.h:75:23: error: flexible array member in union
         uint8_t bytes[];
                       ^
compilation terminated due to -Wfatal-errors.

In file included from ../../libraries/AP_GPS/AP_GPS_SIRF.cpp:22:0:
../../libraries/AP_GPS/AP_GPS_SIRF.h:101:23: error: flexible array member in union
         uint8_t bytes[];
                       ^
compilation terminated due to -Wfatal-errors.

In file included from ../../libraries/AP_GPS/AP_GPS_UBLOX.cpp:23:0:
../../libraries/AP_GPS/AP_GPS_UBLOX.h:387:23: error: flexible array member in union
         uint8_t bytes[];
                       ^
compilation terminated due to -Wfatal-errors.
2016-05-16 13:50:39 -03:00
Gustavo Jose de Sousa d615628367 AP_HAL_Linux: I2CDevice: add missing stdio.h include
This was probably being included by another header, but it's not on
gcc >= 6.1 and glibc 2.23.
2016-05-16 13:12:53 -03:00
Peter Barker 8d5ceda534 AP_HAL_SITL: ensure specified SITL model is found
Without this check we get a null pointer exception the first time we attempt
to use the model object
2016-05-16 13:04:15 -03:00
Andrew Tridgell c6620b03b4 HAL_SITL: added --rtscts option to SITL
useful for radio testing
2016-05-16 16:51:26 +10:00
Rustom Jehangir 39fc17f384 DataFlash: Fix parameter description for param_parse.py 2016-05-16 11:09:31 +10:00
Andrew Tridgell 8571202199 AP_RPM: allow for low RPM measurements on PX4
this automatically adjusts the timer resolution to allow for low RPM
measurements on PX4
2016-05-14 18:05:13 +10:00
Tom Pittenger 38b7d7e1c6 DataFlash: log baro drift offset 2016-05-13 17:22:12 -07:00
Tom Pittenger f1f58e2026 AP_Baro: created baro drift offset accessor 2016-05-13 17:22:11 -07:00
Tom Pittenger f1186b8b5c AP_Mission: store previous nav cmd id 2016-05-13 17:22:03 -07:00
Tom Pittenger d900988a23 DataFlash: Log airspeed.Use 2016-05-13 17:22:02 -07:00
Jonathan Challinger 0281b948df AP_Arming: loosen accelerometer consistency check on Z axis
Original author @jschall via 88f5d9f858
2016-05-13 17:16:12 -07:00
Tom Pittenger d55050e5e3 AP_Baro: slow down the LPF for slewing to a new GND_ALT_OFFSET
Instead of a couple seconds, make it about 15sec. This makes TECS happy by not glitching the height demand as much. When applied too fast the TECS height demand causes a large single oscillation as it chases the filter lag.
2016-05-13 17:15:53 -07:00
Tom Pittenger 37ee3b44d2 AP_Baro: add accessor for baro drift 2016-05-13 17:15:41 -07:00
Tom Pittenger 2e1eef7cf0 AP_Airspeed: airspeed healthy should also check if enabled 2016-05-13 17:14:55 -07:00
Andrew Tridgell e3107a7e10 AP_HAL: fixed optflow typos 2016-05-14 08:26:10 +10:00
Andrew Tridgell 1b7830c577 AP_SpdHgtControl: update for changed API 2016-05-14 08:26:10 +10:00
Andrew Tridgell 98a86bd205 AP_TECS: create TEC2 log message for detailed energy internals 2016-05-14 08:26:10 +10:00
Andrew Tridgell ff97f52555 AP_TECS: removed log_tuning structure 2016-05-14 08:26:10 +10:00
Andrew Tridgell bc911d15d1 AP_TECS: convert to using Log_Write
preparation for a TEC2 message
2016-05-14 08:26:10 +10:00
Andrew Tridgell 9a6ac77c64 AP_TECS: prevent large glitches in the specific energy integrator
this tries to prevent problems like in issue#4066, or at least
reducing the impact when it happens
2016-05-14 08:26:10 +10:00
Andrew Tridgell c52451b01b AP_TECS: rename some variables to make them clearer 2016-05-14 08:26:09 +10:00
Andrew Tridgell e698d1f47e AP_TECS: use 64 bit micros
prevent possible wrap if TECS is not run for a long time
2016-05-14 08:26:09 +10:00
Ricardo de Almeida Gonzaga 64d14356b9 AP_NavEKF2: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 2f88e32657 AP_HAL_FLYMAPLE: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 2236640f66 AP_HAL_Linux: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 267a74ebb2 AP_NavEKF: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 4047fb63fc AP_GPS: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 481e3a2af6 AP_Math: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 00b1915034 AP_HAL_Empty: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 892cc2ea6f AP_HAL_PX4: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 1efa4a4115 doc: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 2bf9aa94ad AP_AHRS: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 2802775e7d AP_Motors: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga dfe38b61de AP_Mission: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga 91e9dd10ba AP_HAL_SITL: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga eb418f54ee AP_HAL: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga aa4b66509f AP_AccelCal: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga fcbed13533 AP_Mount: Fix typos 2016-05-13 19:20:06 -03:00
Ricardo de Almeida Gonzaga af13e2cca4 AP_Declination: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga e6564c2efa AP_BoardConfig: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga 2e58653983 AP_Compass: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga 5237c86bca AP_BattMonitor: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga d5a2c57c5e AP_InertialSensor: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga 08a022fa6a AP_Frsky_Telem: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga 8d6cc587c5 APM_Control: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga 3033c53834 AC_WPNav: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga a8889e5765 AP_Common: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga f6ad89103c AP_Arming: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga 3f92a64b99 GCS_MAVLink: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga e31a37e7a8 AP_Notify: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga 287eb69502 PID: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga dc7acdf03f DataFlash: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga 2ee6a85e67 AP_RangeFinder: Fix typos 2016-05-13 19:20:05 -03:00
Ricardo de Almeida Gonzaga 099fc69032 RC_Channel: Fix typos 2016-05-13 19:20:05 -03:00
Lucas De Marchi 388a6683ad AP_OpticalFlow: fix optical flow initialization
This fixes the initialization for Linux boards using the PX4Flow module.
The problem is that after the conversion to use I2CDevice we now need to
use I2CDeviceManager, which is statically constructed after the vehicle
object.

So, if we try to call hal.i2c_mgr->get_device(), it will call the
get_device() method before the constructor is called and receive a
SIGSEGV:

Program received signal SIGSEGV, Segmentation fault.
0x000b06c0 in OpticalFlow::OpticalFlow (this=0x140914 <copter+4980>, ahrs=...)
    at ../../libraries/AP_OpticalFlow/OpticalFlow.cpp:54
54      ../../libraries/AP_OpticalFlow/OpticalFlow.cpp: No such file or directory.
2016-05-13 11:22:12 -03:00
Lucas De Marchi 37f6b51746 AP_HAL_Linux: Scheduler: set stack sizes to 256k
Running the vehicles we check the stack size doesn't grow too much by
enabling the DEBUG_STACK in the scheduler. Even on 64bit boards the
stack is consistent around 4k. Just to be a little conservative, let it
be a little bit more that that: 256kB.

Since we have RT prio and we call mlock(), the memory for the stack of
each thread is locked in memory. This means we are effectively taking
that much memory. The default stack size varies per distro, but it's
common to have 8MB for 64 bit boards and 4MB for 32 bit boards. Here is
the output of ps -L -o 'comm,rtprio,rss $(pidof arducopter-quad)', showing the
RSS of arducopter-quad before and after this change:

Before:
	COMMAND         RTPRIO   RSS
	arducopter-quad     12 46960
	sched-timer         15 46960
	sched-uart          14 46960
	sched-rcin          13 46960
	sched-tonealarm     11 46960
	sched-io            10 46960

After:
	COMMAND         RTPRIO   RSS
	arducopter-quad     12  7320
	sched-timer         15  7320
	sched-uart          14  7320
	sched-rcin          13  7320
	sched-tonealarm     11  7320
	sched-io            10  7320
2016-05-12 13:35:23 -03:00
Lucas De Marchi b2d4da4b0a AP_HAL_Linux: Thread: allow to set stack size
This allows the code that is creating the thread to set the size of the
stack.
2016-05-12 13:35:23 -03:00
Lucas De Marchi d970451331 AP_HAL_Linux: Scheduler: debug stack usage 2016-05-12 13:35:23 -03:00
Lucas De Marchi f5f4aa7c21 AP_HAL_Linux: Thread: allow to debug stack usage 2016-05-12 13:35:23 -03:00
proficnc 20a569a4d5 AP_Mount: block forwarding of MAVlink by bitmask 2016-05-12 17:44:09 +10:00
proficnc c8b3c527f9 GCS_MAVLink: add route mask for blocking MAVlink forwading 2016-05-12 17:44:06 +10:00
Andrew Tridgell 9bf0ada875 AC_AttitudeControl: removed use of AFF for tail control in heli 2016-05-12 17:37:22 +10:00
Andrew Tridgell a6404cf1ea AC_PID: removed AFF from heli PID
this is not used any more. Discussed with Rob on dev call
2016-05-12 17:37:01 +10:00
Andrew Tridgell cf08c46f30 AC_PID: fixed default leak min for heli 2016-05-12 17:34:23 +10:00
Lucas De Marchi aa974399d0 AP_Math: use inline wrappers for constrain_* functions
This avoids some warnings about "constrain_float defined but not used"
in some compilers.
2016-05-11 22:51:19 -03:00
Vinicius Juvinski 3bae8373e6 AP_Notify: play vehicle lost tone 2016-05-11 22:49:52 -03:00
Vinicius Juvinski c1dd3cb921 AP_Notify: add support for for Buzzer on BBBMini
Use GPIO P8_31 for buzzer in BBBMini
2016-05-11 22:49:52 -03:00
Peter Barker 7510e4d0a7 SITL: setsid() when starting JSBSim so Ctrl-C doesn't kill it in GDB 2016-05-11 14:10:48 +10:00
Andrew Tridgell eeef28be5e AP_HAL_PX4: fixed hexacopter on Pixracer
the _servo_count was 4 as we didn't re-fetch the count after applying
changes in AP_BoardConfig from BRD_PWM_COUNT
2016-05-11 13:01:15 +10:00
Andrew Tridgell 8a7627474f Revert "AP_HAL_PX4: use new I2CDevice interface"
This reverts commit f767918e0e.

These commits broke startup on PX4
2016-05-11 12:19:00 +10:00
Andrew Tridgell 8c06e6cddc Revert "AP_HAL_PX4: embed PX4_I2C object into I2CDevice"
This reverts commit 54fd3702c3.

These commits broke startup on PX4
2016-05-11 12:18:45 +10:00
Staroselskii Georgii a2ae662b3e AP_Compass: add an extra rotation for internal LSM9DS1 on Navio2
In order not to force users to set rotation themselves, we need this
hack to make an extra rotation needed for a second compass.
2016-05-10 17:24:43 -03:00
Staroselskii Georgii 2e5cfc2849 AP_Compass: added external compass autodetection on Navio 2016-05-10 17:24:43 -03:00
Staroselskii Georgii 62f2695e83 AP_Compass: added several compasses' autodetection on Navio 2 2016-05-10 17:24:43 -03:00
Staroselskii Georgii 8be5ef1642 AP_HAL: added possibility to use several compassed on Navio 2 2016-05-10 17:24:43 -03:00
Staroselskii Georgii 71736a0ecc AP_Compass: enable LSM9DS1 magnetometer for boards without default one 2016-05-10 17:24:43 -03:00
Staroselskii Georgii f7846403e1 AP_HAL_Linux: enabled SPI-driven LSM9DS1 for Navio 2 2016-05-10 17:24:43 -03:00
Staroselskii Georgii b677f975e7 AP_Compass: added LSM9DS1 magnetometer support 2016-05-10 17:24:43 -03:00
Andrew Tridgell 88b910c13d SITL: changed firefly motors to be suitable for a pixhawk
get channel groupings right
2016-05-11 05:55:25 +10:00
Andrew Tridgell 3e1cad5df2 SITL: adjust tricopter so default yaw servo values will work 2016-05-11 05:55:24 +10:00
Andrew Tridgell 48ca1a8d92 SITL: increase the mass of the plane to 2kg
less wafty in the air
2016-05-11 05:55:24 +10:00
Andrew Tridgell 9c90709872 SITL: fixed namespace of SITL classes 2016-05-11 05:55:23 +10:00
Andrew Tridgell 91abc636f4 SITL: fixed quadplanes with elevons 2016-05-11 05:55:23 +10:00
Andrew Tridgell a41ffc176c RC_Channel: added motor tilt auxillary channel 2016-05-11 05:55:23 +10:00
Andrew Tridgell 2d47ca8095 SITL: fixed moment of rotated motors 2016-05-11 05:55:23 +10:00
Andrew Tridgell 60b3625950 AP_Motors: added hook for vehicle based thrust compensation
allow vehicle code to compensate for thrust effectiveness changes due
to properties outside the scope of AP_Motors. This allows for
compensation in tiltrotors and tiltwings.
2016-05-11 05:55:23 +10:00
Andrew Tridgell 37d6b5fdaf AP_Motors: added output_motor_mask()
this will be used for tiltrotors in forward flight
2016-05-11 05:55:23 +10:00
Andrew Tridgell bd8cd71745 SITL: fixed fwd motor angles for tri and y6 frames
should be 60 degrees to have motors evenly spaced around frame for
equal lift per motor when level
2016-05-11 05:55:23 +10:00
Andrew Tridgell 125a9feb3d SITL: added tilttri frame type
tiltrotor tricopter
2016-05-11 05:55:22 +10:00
Lucas De Marchi 68ae619448 AP_Compass: detect compasses for minlure
Minlure has an onboard compass (HMC5883L) as slave of MPU-6000, but also
allows the use of an external HMC5883L compass, which should be
connected to the lure's I2C port.
2016-05-10 16:08:39 -03:00
Lucas De Marchi 424434e31e AP_HAL: allow to build without HAL_COMPASS_DEFAULT
Otherwise we need to change the ifdef chain adding HAL_COMPASS_<BOARD>
definitions.
2016-05-10 16:07:23 -03:00
Lucas De Marchi 3315f46800 AP_HAL_Linux: inline I2C bus options for minlure
We don't need all the comments in the array declaration and we can
inline its declaration in the function call. This makes it easier to
copy it to other places.
2016-05-10 16:06:53 -03:00
Gustavo Jose de Sousa 91246ad8af AP_Compass: HMC5843: apply HMC5883L "arrow" rotation only if external
That rotation is done because of the "arrow" pointing the sensor direction in
3DR GPS+Compass kit (which isn't natural to the sensor orientation, by the
way). Thus, do that rotation only for external HMC5883L compasses.
2016-05-10 16:05:29 -03:00
Gustavo Jose de Sousa 35cddc7af0 AP_Compass: HMC5843: move hardcoded rotation to before call to rotate_field()
That rotation is set for AP_COMPASS_TYPE_HMC5883L, because it's usually
the compass from 3DR GPS+Compass kit, which has an arrow pointing the
"correct" direction. That rotation should be done before rotate_field()
as it represents the "standard" position for the kit.

This patch also makes published values consistent with respect to rotation.
Before this, raw fields used in calibration were published with a
rotation different from the filtered field when _product_id is
AP_COMPASS_TYPE_HMC5883L.
2016-05-10 15:56:38 -03:00
Gustavo Jose de Sousa ad91a810b3 AP_Compass: Backend: add method is_external() 2016-05-10 15:55:58 -03:00
Gustavo Jose de Sousa 670b0071f9 AP_Compass: HMC5843: add parameter force_external to constructor
And to the detection probe() method. That way we don't need to use a board
`#ifdef` inside the class code.  Additionally, we make raspilot board use it.
2016-05-10 15:52:54 -03:00
Lucas De Marchi 54fd3702c3 AP_HAL_PX4: embed PX4_I2C object into I2CDevice
Otherwise we would destroy PX4_I2C object after returning from
I2CDeviceManager::get_device(). Since this implementation is very
simple, just make PX4_I2C as an internal class and embed it into the
I2CDevice object.
2016-05-10 15:39:24 -03:00
Luiz Ywata f767918e0e AP_HAL_PX4: use new I2CDevice interface 2016-05-10 15:12:30 -03:00
Lucas De Marchi 3c7d80a270 AP_Baro: BMP085: use a moving average of 10 samples in BMP085
Instead of depending on the frequency accumulate() is called, use
AverageIntegralFilter with 10 samples. The data obtained by BMP085 is
too noisy with any value of OVERSAMPLING so use twice the number of
samples as currently used. Besides that now we are sure there's always
10 samples used in the average.
2016-05-10 14:24:59 -03:00
Lucas De Marchi 18f1f8bea8 Filter: add AverageFilter variant to save current sum
When the the variable in which we are saving the current sum is of
integral type we can use a much more optimized apply() method: instead
of looping the entire number of samples adding them up, we always keep
the current sum in a member.  It also allows the caller to decide the
type it wants to use to get the average: this may be dictated by another
interface it uses or it may want to avoid the implicit truncate in the
return of apply().
2016-05-10 14:24:59 -03:00
Lucas De Marchi 8da5275b03 AP_Baro: BMP085: don't average temperature in BMP085
The temperature readings is not subject to white noise so there's no
point in averaging its reading. Moreover since for a normal 50Hz
accumulate() / 10Hz update() it would read temperature only once per
update(), it's pointless to keep averaging and introducing rounding
error.

The temperature doesn't need to be checked as frequent as pressure, too.
The datasheet even suggests on section 3.3, page 10 to enable standard
mode and read the temperature at 1Hz. Here we reduce it to 2Hz
(considering the accumulate() function being called at 50Hz).
2016-05-10 14:24:59 -03:00
Lucas De Marchi c5c52076ca AP_Baro: BMP085: rename private member 2016-05-10 14:24:58 -03:00
Lucas De Marchi e40b88aa70 AP_Baro: BMP085: use DigitalSource interface in BMP085
Use the DigitalSource interface rather than going through the "static"
interface hal.gpio provides
2016-05-10 14:24:58 -03:00
Lucas De Marchi 56fa1b6214 AP_Baro: BMP085: change oversampling in BMP085 without EOC
If we don't have EOC pin and assuming the accumulate() function is
called at 50Hz (or higher) we would take very few samples to accumulate
before the update is called. That's because since we have to wait 26ms
to get a sample and we calling accumulate() every 20ms, half of the
times it will return without getting anything.  So we will
be using 2 or 3 samples only to average.

If we don't have EOC, use OVERSAMPLING=2 which gives us more noise, but
that we can filter out by using measurements to average. When we have
EOC we don't need it because most of the time the conversion will take
less than 20ms: I'm getting 16ms on most of them while bench-testing.
2016-05-10 14:24:58 -03:00
Lucas De Marchi 37e2f6c52e AP_Baro: BMP085: allow to easily change oversampling in BMP085
This way it's possible to easily change it if a board requires.
2016-05-10 14:24:58 -03:00
Lucas De Marchi bd6e268122 AP_Math: fix coding style
- cleanup whitespace
  - function reorder
  - fix brace position
2016-05-10 11:41:26 -03:00
Lucas De Marchi 6f87195eb7 AP_L1_Control: remove tabs and trailing whitespaces 2016-05-10 11:41:26 -03:00
Lucas De Marchi 1dbffef7ea AP_Math: remove trailing whitespace on headers 2016-05-10 11:41:26 -03:00
Lucas De Marchi ab1fa4b435 AP_Math: reorganize headers
Sort and add pragma once where needed.
2016-05-10 11:41:26 -03:00
dgrat 6d3b491c02 AP_Math: Replace is_equal with a type safe template function
It makes sense to consider also other floating point types.
2016-05-10 11:41:26 -03:00
dgrat 503867b7dc AP_Math: Replace safe_sqrt() by template function 2016-05-10 11:41:26 -03:00
dgrat 5deb0e8e03 AP_Math: Replace safe_asin() by template function 2016-05-10 11:41:26 -03:00
Lucas De Marchi 846b4927ec AP_Math: use if/else chain instead of 2 ternary operators 2016-05-10 11:41:26 -03:00
dgrat 174f899a29 AP_Math: Replace the constrain_* functions by a single template
Besides being simpler this reduces ~4k in the binary size for PX4.
2016-05-10 11:41:26 -03:00
Lucas De Marchi 348b07609c AP_Math: remove macros from unit tests
Avoid warnings like:

[2130/2168] Compiling libraries/AP_Math/tests/test_math.cpp
../../libraries/AP_Math/tests/test_math.cpp: In member function ‘virtual void MathTest_IsZero_Test::TestBody()’:
../../libraries/AP_Math/tests/test_math.cpp:73:196: warning: converting ‘false’ to pointer type for argument 1 of ‘char
testing::internal::IsNullLiteralHelper(testing::internal::Secret*)’ [-Wconversion-null]
../../libraries/AP_Math/tests/test_math.cpp:74:199: warning: converting ‘false’ to pointer type for argument 1 of ‘char
testing::internal::IsNullLiteralHelper(testing::internal::Secret*)’ [-Wconversion-null]

Use EXPECT_TRUE() and EXPECT_FALSE() from gtest instead.
2016-05-10 11:41:26 -03:00
dgrat 41661f815f AP_Math: Replace the pythagorous* functions with a variadic template
The new function can deal with a variable number of function parameters.
Additionally, I renamed the functions to norm(), because this is the
standard name used in several other projects.
2016-05-10 11:41:26 -03:00
Lucas De Marchi 880f130670 AP_Math: fix loss of precision on float addition
When using wrap_180_cd() we are adding a small float (180 * 100) to a
possibly big number. This may lose float precision as illustrated by the
unit test failing:

    OUT: ../../libraries/AP_Math/tests/test_math.cpp:195: Failure
    OUT: Value of: wrap_180_cd(-3600000000.f)
    OUT:   Actual: -80
    OUT: Expected: 0.f
    OUT: Which is: 0
2016-05-10 11:41:26 -03:00
dgrat 76362caee0 AP_Math: Replace wrap_* functions with template versions 2016-05-10 11:41:26 -03:00
dgrat 49cfd6fd9b AP_Math: Add gtest support for some functions
These functions (or variants thereof) now have unit tests:

  - is_zero()
  - is_equal()
  - sq()
  - pythagorous()
  - constrain()
  - wrap_180()
  - wrap_360()

Some tests in wrap_180_cd are failing: -180 should be wrapped to 180,
not -180.
2016-05-10 11:41:26 -03:00
Lucas De Marchi ceea7540fd AP_Math: rename test file
This will be reused for more math tests.
2016-05-10 11:41:26 -03:00
skyscraper c0c8f1a5cc RC_Channel: RC_Channel refactor
Fix up RC_Channel examples.

Change direct access to data members
to access via member functions
2016-05-10 16:21:17 +10:00
skyscraper de5130fa13 AP_Motors: RC_Channel refactor
More fixing up of RC_Channel change access to
data members to functions
2016-05-10 16:21:16 +10:00
skyscraper 12cf65baed AP_Tuning: Fix up after RC_Channels refactor
Further to refactor of RC_Channel class which included
adding get_xx set_xx methods, change reads and writes to the public members
to calls to  get and set functionsss

old public member(int16_t)   get function -> int16_t     set function (int16_t)
(expression where c is an object of type RC_Channel)
c.radio_in                     c.get_radio_in()           c.set_radio_in(v)
c.control_in                   c.get_control_in()         c.set_control_in(v)
c.servo_out                    c.get_servo_out()          c.set_servo_out(v)
c.pwm_out                      c.get_pwm_out()            // use existing
c.radio_out                    c.get_radio_out()          c.set_radio_out(v)
c.radio_max                    c.get_radio_max()          c.set_radio_max(v)
c.radio_min                    c.get_radio_min()          c.set_radio_min(v)
c.radio_trim                   c.get_radio_trim()         c.set_radio_trim(v);

c.min_max_configured() // return true if min and max are configured

Because data members of RC_Channels are now private and so cannot be written directly
 some overloads are provided in the Plane classes to provide the old functionality

new overload Plane::stick_mix_channel(RC_Channel *channel)
which forwards to the previously existing
void stick_mix_channel(RC_Channel *channel, int16_t &servo_out);

new overload Plane::channel_output_mixer(Rc_Channel* , RC_Channel*)const
which forwards to
(uint8_t mixing_type, int16_t & chan1, int16_t & chan2)const;

Rename functions

 RC_Channel_aux::set_radio_trim(Aux_servo_function_t function)
    to RC_Channel_aux::set_trim_to_radio_in_for(Aux_servo_function_t function)

 RC_Channel_aux::set_servo_out(Aux_servo_function_t function, int16_t value)
    to RC_Channel_aux::set_servo_out_for(Aux_servo_function_t function, int16_t value)

 Rationale:

        RC_Channel is a complicated class, which combines
        several functionalities dealing with stick inputs
        in pwm and logical units, logical and actual actuator
        outputs, unit conversion etc, etc
        The intent of this PR is to clarify existing use of
        the class. At the basic level it should now be possible
        to grep all places where private variable is set by
        searching for the set_xx function.

        (The wider purpose is to provide a more generic and
        logically simpler method of output mixing. This is a small step)
2016-05-10 16:21:16 +10:00
skyscraper c4aa55a6d9 AP_ServoRelayEvents: Fix up after RC_Channels refactor
Further to refactor of RC_Channel class which included
adding get_xx set_xx methods, change reads and writes to the public members
to calls to  get and set functionsss

old public member(int16_t)   get function -> int16_t     set function (int16_t)
(expression where c is an object of type RC_Channel)
c.radio_in                     c.get_radio_in()           c.set_radio_in(v)
c.control_in                   c.get_control_in()         c.set_control_in(v)
c.servo_out                    c.get_servo_out()          c.set_servo_out(v)
c.pwm_out                      c.get_pwm_out()            // use existing
c.radio_out                    c.get_radio_out()          c.set_radio_out(v)
c.radio_max                    c.get_radio_max()          c.set_radio_max(v)
c.radio_min                    c.get_radio_min()          c.set_radio_min(v)
c.radio_trim                   c.get_radio_trim()         c.set_radio_trim(v);

c.min_max_configured() // return true if min and max are configured

Because data members of RC_Channels are now private and so cannot be written directly
 some overloads are provided in the Plane classes to provide the old functionality

new overload Plane::stick_mix_channel(RC_Channel *channel)
which forwards to the previously existing
void stick_mix_channel(RC_Channel *channel, int16_t &servo_out);

new overload Plane::channel_output_mixer(Rc_Channel* , RC_Channel*)const
which forwards to
(uint8_t mixing_type, int16_t & chan1, int16_t & chan2)const;

Rename functions

 RC_Channel_aux::set_radio_trim(Aux_servo_function_t function)
    to RC_Channel_aux::set_trim_to_radio_in_for(Aux_servo_function_t function)

 RC_Channel_aux::set_servo_out(Aux_servo_function_t function, int16_t value)
    to RC_Channel_aux::set_servo_out_for(Aux_servo_function_t function, int16_t value)

 Rationale:

        RC_Channel is a complicated class, which combines
        several functionalities dealing with stick inputs
        in pwm and logical units, logical and actual actuator
        outputs, unit conversion etc, etc
        The intent of this PR is to clarify existing use of
        the class. At the basic level it should now be possible
        to grep all places where private variable is set by
        searching for the set_xx function.

        (The wider purpose is to provide a more generic and
        logically simpler method of output mixing. This is a small step)
2016-05-10 16:21:15 +10:00
skyscraper 8b9c96814b AP_Mount: Fix up after RC_Channels refactor
Further to refactor of RC_Channel class which included
adding get_xx set_xx methods, change reads and writes to the public members
to calls to  get and set functionsss

old public member(int16_t)   get function -> int16_t     set function (int16_t)
(expression where c is an object of type RC_Channel)
c.radio_in                     c.get_radio_in()           c.set_radio_in(v)
c.control_in                   c.get_control_in()         c.set_control_in(v)
c.servo_out                    c.get_servo_out()          c.set_servo_out(v)
c.pwm_out                      c.get_pwm_out()            // use existing
c.radio_out                    c.get_radio_out()          c.set_radio_out(v)
c.radio_max                    c.get_radio_max()          c.set_radio_max(v)
c.radio_min                    c.get_radio_min()          c.set_radio_min(v)
c.radio_trim                   c.get_radio_trim()         c.set_radio_trim(v);

c.min_max_configured() // return true if min and max are configured

Because data members of RC_Channels are now private and so cannot be written directly
 some overloads are provided in the Plane classes to provide the old functionality

new overload Plane::stick_mix_channel(RC_Channel *channel)
which forwards to the previously existing
void stick_mix_channel(RC_Channel *channel, int16_t &servo_out);

new overload Plane::channel_output_mixer(Rc_Channel* , RC_Channel*)const
which forwards to
(uint8_t mixing_type, int16_t & chan1, int16_t & chan2)const;

Rename functions

 RC_Channel_aux::set_radio_trim(Aux_servo_function_t function)
    to RC_Channel_aux::set_trim_to_radio_in_for(Aux_servo_function_t function)

 RC_Channel_aux::set_servo_out(Aux_servo_function_t function, int16_t value)
    to RC_Channel_aux::set_servo_out_for(Aux_servo_function_t function, int16_t value)

 Rationale:

        RC_Channel is a complicated class, which combines
        several functionalities dealing with stick inputs
        in pwm and logical units, logical and actual actuator
        outputs, unit conversion etc, etc
        The intent of this PR is to clarify existing use of
        the class. At the basic level it should now be possible
        to grep all places where private variable is set by
        searching for the set_xx function.

        (The wider purpose is to provide a more generic and
        logically simpler method of output mixing. This is a small step)
2016-05-10 16:21:15 +10:00
skyscraper daec4ea10e AP_Motors: Fix up after RC_Channels refactor
Further to refactor of RC_Channel class which included
adding get_xx set_xx methods, change reads and writes to the public members
to calls to  get and set functionsss

old public member(int16_t)   get function -> int16_t     set function (int16_t)
(expression where c is an object of type RC_Channel)
c.radio_in                     c.get_radio_in()           c.set_radio_in(v)
c.control_in                   c.get_control_in()         c.set_control_in(v)
c.servo_out                    c.get_servo_out()          c.set_servo_out(v)
c.pwm_out                      c.get_pwm_out()            // use existing
c.radio_out                    c.get_radio_out()          c.set_radio_out(v)
c.radio_max                    c.get_radio_max()          c.set_radio_max(v)
c.radio_min                    c.get_radio_min()          c.set_radio_min(v)
c.radio_trim                   c.get_radio_trim()         c.set_radio_trim(v);

c.min_max_configured() // return true if min and max are configured

Because data members of RC_Channels are now private and so cannot be written directly
 some overloads are provided in the Plane classes to provide the old functionality

new overload Plane::stick_mix_channel(RC_Channel *channel)
which forwards to the previously existing
void stick_mix_channel(RC_Channel *channel, int16_t &servo_out);

new overload Plane::channel_output_mixer(Rc_Channel* , RC_Channel*)const
which forwards to
(uint8_t mixing_type, int16_t & chan1, int16_t & chan2)const;

Rename functions

 RC_Channel_aux::set_radio_trim(Aux_servo_function_t function)
    to RC_Channel_aux::set_trim_to_radio_in_for(Aux_servo_function_t function)

 RC_Channel_aux::set_servo_out(Aux_servo_function_t function, int16_t value)
    to RC_Channel_aux::set_servo_out_for(Aux_servo_function_t function, int16_t value)

 Rationale:

        RC_Channel is a complicated class, which combines
        several functionalities dealing with stick inputs
        in pwm and logical units, logical and actual actuator
        outputs, unit conversion etc, etc
        The intent of this PR is to clarify existing use of
        the class. At the basic level it should now be possible
        to grep all places where private variable is set by
        searching for the set_xx function.

        (The wider purpose is to provide a more generic and
        logically simpler method of output mixing. This is a small step)
2016-05-10 16:21:15 +10:00
skyscraper ba9462d13d APM_OBC: Fix up after RC_Channels refactor
Further to refactor of RC_Channel class which included
adding get_xx set_xx methods, change reads and writes to the public members
to calls to  get and set functionsss

old public member(int16_t)   get function -> int16_t     set function (int16_t)
(expression where c is an object of type RC_Channel)
c.radio_in                     c.get_radio_in()           c.set_radio_in(v)
c.control_in                   c.get_control_in()         c.set_control_in(v)
c.servo_out                    c.get_servo_out()          c.set_servo_out(v)
c.pwm_out                      c.get_pwm_out()            // use existing
c.radio_out                    c.get_radio_out()          c.set_radio_out(v)
c.radio_max                    c.get_radio_max()          c.set_radio_max(v)
c.radio_min                    c.get_radio_min()          c.set_radio_min(v)
c.radio_trim                   c.get_radio_trim()         c.set_radio_trim(v);

c.min_max_configured() // return true if min and max are configured

Because data members of RC_Channels are now private and so cannot be written directly
 some overloads are provided in the Plane classes to provide the old functionality

new overload Plane::stick_mix_channel(RC_Channel *channel)
which forwards to the previously existing
void stick_mix_channel(RC_Channel *channel, int16_t &servo_out);

new overload Plane::channel_output_mixer(Rc_Channel* , RC_Channel*)const
which forwards to
(uint8_t mixing_type, int16_t & chan1, int16_t & chan2)const;

Rename functions

 RC_Channel_aux::set_radio_trim(Aux_servo_function_t function)
    to RC_Channel_aux::set_trim_to_radio_in_for(Aux_servo_function_t function)

 RC_Channel_aux::set_servo_out(Aux_servo_function_t function, int16_t value)
    to RC_Channel_aux::set_servo_out_for(Aux_servo_function_t function, int16_t value)

 Rationale:

        RC_Channel is a complicated class, which combines
        several functionalities dealing with stick inputs
        in pwm and logical units, logical and actual actuator
        outputs, unit conversion etc, etc
        The intent of this PR is to clarify existing use of
        the class. At the basic level it should now be possible
        to grep all places where private variable is set by
        searching for the set_xx function.

        (The wider purpose is to provide a more generic and
        logically simpler method of output mixing. This is a small step)
2016-05-10 16:21:15 +10:00
skyscraper d16659331f RC_Channel_aux: Rename static member functions
Further to refactor of RC_Channel class which included
adding get_xx set_xx methods, some methods names are now
in conflict with those in the derived RC_Channel_aux class.
To keep a uniform naming convention in RC_Channel where
functions are most used and most numerous, the offending
functions in RC_Channel__aux are renamed as follows

 RC_Channel_aux::set_radio_trim(Aux_servo_function_t function)
    to RC_Channel_aux::set_trim_to_radio_in_for(Aux_servo_function_t function)

 RC_Channel_aux::set_servo_out(Aux_servo_function_t function, int16_t value)
    to RC_Channel_aux::set_servo_out_for(Aux_servo_function_t function, int16_t value)

 Rationale:

        RC_Channel is a complicated class, which combines
        several functionalities dealing with stick inputs
        in pwm and logical units, logical and actual actuator
        outputs, unit conversion etc, etc
        The intent of this PR is to clarify existing use of
        the class. At the basic level it should now be possible
        to grep all places where private variable is set by
        searching for the set_xx function.

        (The wider purpose is to provide a more generic and
        logically simpler method of output mixing. This is a small step)
2016-05-10 16:21:15 +10:00
skyscraper d9ab3baf84 RC_Channel: Refactor to make data members private
rename all public data members of RC_Channnels with
leading underscore and make all data members private.
Provide get_xx and set_xx methods for access

 Rationale:

        RC_Channel is a complicated class, which combines
        several functionalities dealing with stick inputs
        in pwm and logical units, logical and actual actuator
        outputs, unit conversion etc, etc
        The intent of this PR is to clarify existing use of
        the class. At the basic level it should now be possible
        to grep all places where private variable is set by
        searching for the set_xx function.

        (The wider purpose is to provide a more generic and
        logically simpler method of output mixing. This is a small step)

add function to save radio trim
(expression where c is an object of type RC_Channel)
old public member(int16_t)   get function -> int16_t     set function (int16_t)

(expression where c is an object of type RC_Channel)

c.radio_in                     c.get_radio_in()           c.set_radio_in(v)
c.control_in                   c.get_control_in()         c.set_control_in(v)
c.servo_out                    c.get_servo_out()          c.set_servo_out(v)
c.pwm_out                      c.get_pwm_out()            // use existing
c.radio_out                    c.get_radio_out()          c.set_radio_out(v)
c.radio_max                    c.get_radio_max()          c.set_radio_max(v)
c.radio_min                    c.get_radio_min()          c.set_radio_min(v)
c.radio_trim                   c.get_radio_trim()         c.set_radio_trim(v);
// other
c.min_max_configured() // return true if min and max are configured
c.save_radio_trim()    // save radio trim to eeprom
2016-05-10 16:21:15 +10:00
Gustavo Jose de Sousa b594b5a08b AP_Math: matrix_alg: disable FE_OVERFLOW in inverse4x4() for SITL
There are occasional overflows on the determinant calculation in inverse4x4()
when using calibration SITL model.
2016-05-10 16:16:37 +10:00
Gustavo Jose de Sousa a7543d369f AP_Math: matrix_alg: protect inverseixi() against overflow
Fail on inverse3x3() and inverse4x4() if there's float overflow during the
determinant calculation.
2016-05-10 16:16:37 +10:00
Gustavo Jose de Sousa 39f72610e2 AP_Math: quaternion: fix style
Remove trailing spaces and run astyle.
2016-05-10 16:16:37 +10:00
Gustavo Jose de Sousa 8c4c9ccfa6 AP_HAL_SITL: add calibration model 2016-05-10 16:16:37 +10:00
Gustavo Jose de Sousa 9fa85d9bcf SITL: add SIM_Calibration
That model can be used to run compass and accelerometer calibration by rotating
the vehicle through the servos channels.
2016-05-10 16:16:37 +10:00
Gustavo Jose de Sousa 45754ef37c SITL: Multicopter: remove leftover comment
That went unnoticed by 8a98ce4 ("SITL: moved to common code for attitude/pos
update")
2016-05-10 16:16:37 +10:00
Gustavo Jose de Sousa ce8766e1cd SITL: remove set_yaw_degrees()
That function isn't being used anywhere.
2016-05-10 16:16:37 +10:00
Andrew Tridgell 50908edc91 RC_Channel: added parameter docs for missing RCn_FUNCTION values 2016-05-09 17:33:21 +10:00
Andrew Tridgell 31ed1eabfb AP_Tuning: use better tones for next parameter 2016-05-09 17:24:56 +10:00
Andrew Tridgell 3e75fc4f3d AP_Notify: improved tones for AP_Tuning 2016-05-09 17:24:38 +10:00
Andrew Tridgell ea508f1b80 AP_NavEKF2: use LOG_REPLAY and EK2_LOG_MASK parameters 2016-05-09 12:26:57 +10:00
Andrew Tridgell 202eb3af35 DataFlash: added imu_mask to Log_Write_IMUDT 2016-05-09 12:26:30 +10:00
Andrew Tridgell 8ca6ed54c5 DataFlash: added LOG_REPLAY and LOG_DISARMED parameters 2016-05-09 12:00:55 +10:00
Andrew Tridgell 5398283c9b DataFlash: fixed BAR2 and BAR3 log formats 2016-05-09 11:09:44 +10:00
Andrew Tridgell 25c7b43628 AP_Tuning: removed chans 1 to 4 from TUNE_CHAN choices 2016-05-08 21:06:56 +10:00
Andrew Tridgell 2a2abb8be6 GCS_MAVLink: log parameter changes to DataFlash
this means param notifies also get logged in the DF log
2016-05-08 19:12:09 +10:00
Andrew Tridgell d72df80968 AP_Tuning: added a small dead-zone on mid-point detection
thanks to Leonard for the suggestion
2016-05-08 18:35:26 +10:00
Andrew Tridgell aa38539ecb AP_Tuning: move to using a nested parameter set for AP_Tuning
this allows the list of tunable parameters in the auto-docs to be
separated out
2016-05-08 18:35:26 +10:00
Andrew Tridgell 8a65481551 AP_Tuning: allow for tuning with no selector switch
this makes tuning with a single parameter possible
2016-05-08 14:47:51 +10:00
Andrew Tridgell f69806deff AP_Tuning: detect change to TUNE_PARMSET while tuning 2016-05-08 14:36:30 +10:00
Andrew Tridgell 6d1c7c9082 AP_Tuning: make it possible to tune a single parameter 2016-05-08 14:36:30 +10:00
Leandro Pereira f23bd7e09d GCS_MAVLink: Use a single stream_trigger() implementation
This has no side effects, but since all implementations were basically
the same, move the implementation to GCS_Common and the only part that
adjusts the rate based on which which stream to each individual
GCS_MAVLINK implementation.
2016-05-07 23:49:35 -03:00
Andrew Tridgell 9cd4f8a856 AP_Notify: added tones for tuning stages 2016-05-07 18:34:13 +10:00
Andrew Tridgell ebee79fb3a AP_Tuning: added transmitter tuning library
needs to be subclassed in vehicle code
2016-05-07 18:34:08 +10:00
Andrew Tridgell a9f1b608ed APM_Control: expose parameters as AP_Float 2016-05-07 18:34:06 +10:00
Andrew Tridgell 412dc10353 AC_PID: expose parameters as AP_Float
this enables full tuning capability
2016-05-07 18:34:03 +10:00
Andrew Tridgell 5ddb872b79 AP_GPS: allow Replay to set last sample time 2016-05-07 18:27:23 +10:00
Andrew Tridgell 2f4f38b85f DataFlash: log the last message sample time for GPS 2016-05-07 18:27:23 +10:00
Andrew Tridgell 428923b4b1 AP_GPS: use 3D velocity for uBlox
this makes uBlox use the 3D velocity for ground course and speed,
ensuring we use a consistent value everywhere (so same vector in EKF
as in navigation)
2016-05-07 18:27:23 +10:00
Andrew Tridgell 679b43efc9 DataFlash: make timestamps in EKF messages all match 2016-05-07 18:27:22 +10:00
Andrew Tridgell 32af886ba9 AP_NavEKF2: use consistent logging timestamps for sensors 2016-05-07 18:27:22 +10:00
Andrew Tridgell 35c3adb1ad DataFlash: use caller supplied timestamps for sensor logging
used to support EK2_LOGGING=1
2016-05-07 18:27:22 +10:00
Andrew Tridgell 6aa02f06a9 DataFlash: use INS_USE to prevent logging of unused IMUs 2016-05-07 18:27:22 +10:00
Andrew Tridgell d24bbcd1ff AP_GPS: convert vdop to cm 2016-05-07 18:27:22 +10:00
Andrew Tridgell b424c49bc7 AP_GPS: change ground course to be in degrees
more accuracy for replay
2016-05-07 18:27:21 +10:00
Andrew Tridgell e8142b0b5b AP_Math: added wrap_360() 2016-05-07 18:27:21 +10:00
Andrew Tridgell 9300092840 DataFlash: changed GPS ground course to float and add VV for GPA
more accurate replay
2016-05-07 18:27:21 +10:00
Andrew Tridgell 8b7bf5cf7a AP_Baro: allow setHIL to set last update time 2016-05-07 18:27:21 +10:00
Andrew Tridgell 1bf057be45 DataFlash: log last update time in BARO msg 2016-05-07 18:27:21 +10:00
Andrew Tridgell d61ba14037 DataFlash: switched to float for GPS ground speed
same size and more precision
2016-05-07 18:27:21 +10:00
Andrew Tridgell 0b71652afc AP_Baro; allow for exact replay of baro data 2016-05-07 18:27:20 +10:00
Andrew Tridgell d97074dc9d DataFlash: round baro temp to nearest centi-degree
makes replay logs a tiny bit closer
2016-05-07 18:27:20 +10:00
Andrew Tridgell 73d3797a7e AP_AHRS: finish implementing have_ekf_logging() 2016-05-07 18:27:20 +10:00
Andrew Tridgell 4e4c575f16 AP_NavEKF2: added have_ekf_logging() 2016-05-07 18:27:20 +10:00
Andrew Tridgell b7ba0fa458 AP_NavEKF2: added ad-hoc logging example to EKF2 2016-05-07 18:27:20 +10:00
Andrew Tridgell 4e5f1374da AP_GPS: added setHil_Accuracy() 2016-05-07 18:27:19 +10:00
Andrew Tridgell 88a1ebaf0e AP_Compass: allow setting of exact timestamp in HIL compass 2016-05-07 18:27:19 +10:00
Andrew Tridgell 4318fd0ab8 HAL_SITL: update for changed API 2016-05-07 18:27:19 +10:00
Andrew Tridgell 61da827c16 DataFlash: added sample timestamp to mag messages
allows for exact mag timings in replay
2016-05-07 18:27:19 +10:00
Andrew Tridgell 795080742e AP_AHRS: added have_ekf_logging() API 2016-05-07 18:27:19 +10:00
Andrew Tridgell 7ab1367ec4 DataFlash: removed logging of relative alt in GPS messages
not related to GPS and makes it impossible to do bit-identical replay
2016-05-07 18:27:18 +10:00
Andrew Tridgell 223c512188 AP_NavEKF2: added logging of sensor data in EKF2 2016-05-07 18:27:18 +10:00
Andrew Tridgell 2718b0649b HAL_SITL: fixed GPS rate in SITL when speedup used 2016-05-07 18:27:18 +10:00
Andrew Tridgell 8a987bf67d AP_Baro: removed filtering of baro data in HIL/SITL
this was just causing lag in replay and doesn't actually help in SITL
2016-05-07 18:27:18 +10:00
Andrew Tridgell c85607b80c AP_GPS: added time_epoch_convert() function
used by replay to get identical timestamps
2016-05-07 18:27:18 +10:00
Andrew Tridgell 07060051cf AP_AHRS: added API for forcing EKF to start
used by Replay to sync start times
2016-05-07 18:27:18 +10:00
Andrew Tridgell f92279f436 AP_NavEKF2: allow logging of IMT data from inside EKF2 2016-05-07 18:27:17 +10:00
Andrew Tridgell 2965e67d5d HAL_Linux: cope with non-root for Replay 2016-05-07 18:27:17 +10:00
Randy Mackay 4a06ca4be2 AC_AttControl: remove unused call to motors.set_stabilizing
Also minor change to order of a call to motors library to make stabilizing
and non-stabilizing calls consistent.

Non functional change
2016-05-07 10:08:38 +09:00
Randy Mackay e41f798ba1 AP_Motors: remove unused set_stabilizing 2016-05-07 10:08:36 +09:00
Andrew Tridgell ab0b76764f RC_Channel: added set_servo_failsafe_pwm() 2016-05-07 07:25:27 +10:00
Andrew Tridgell 46f257fd9b DataFlash: convert Log_Write() to use a linked list
this saves some memory and means we don't need to know how many we
will need in advance
2016-05-07 07:21:16 +10:00
Andrew Tridgell 9a1cbff850 DataFlash: allow access to DataFlash instance as a static singleton 2016-05-07 07:21:16 +10:00
Peter Barker 11dd254498 DataFlash: Log_Write optimisations 2016-05-07 07:21:16 +10:00
Peter Barker cf15bb5f6e DataFlash: AllTypes example also covers Log_Write 2016-05-07 07:21:16 +10:00
Peter Barker b273514cf9 DataFlash: create example outputting all field types 2016-05-07 07:21:16 +10:00
Peter Barker 518fabe035 DataFlash: StopLogging method, virtual stop_logging on backends 2016-05-07 07:21:16 +10:00
Peter Barker 77dd170e03 DataFlash: Log_Write support
A generic logging method to avoid the need to set up a format and structures etc
2016-05-07 07:21:16 +10:00
Peter Barker 334af1ecd7 DataFlash: base class method for resetting state on log open 2016-05-07 07:21:16 +10:00
Peter Barker eea2d5dcb5 DataFlash_File: avoid integer wrap when checking minimum time 2016-05-07 07:21:15 +10:00
Michael Day 62a7074dd7 AP_Mission: Added mavlink_cmd_long_to_mission_cmd method. 2016-05-06 11:59:44 -07:00
Lucas De Marchi fea084a596 Global: use ap_version.h
This header is used by waf to contain the generated version macros,
particularly using the git hash. For waf it's better to be in a separate
header since it then can keep track of changes on it a trigger
recompilation.

For the make build system, a dummy ap_version.h file has been added in
the missing/ folder so both implementations can co-exist.
2016-05-06 13:11:28 -03:00
Lucas De Marchi 1238c872a9 AP_Common: remove unused Arduino.h header 2016-05-06 13:11:27 -03:00
Allan Matthew d01db0edd6 AC_PrecLand: remove PI controller, speed limits as they are unused 2016-05-06 11:04:12 +09:00
skyscraper 134ea338da RC_Channel: remove unused control_mix method 2016-05-05 18:58:17 -03:00
Andrew Tridgell 9c4dd024bf AP_NavEKF2: auto change EK2_GPS_TYPE for NMEA
this fixes a problem where users of NMEA GPS receivers could not arm
with default EK2 parameters.
2016-05-05 19:46:33 +10:00
Andrew Tridgell 826cb0887a AP_SerialManager: changed default for SERIAL4_PROTOCOL to 5
this makes it a documented protocol number. No functionality change
2016-05-05 08:08:30 +10:00
Lucas De Marchi cf11776150 AP_HAL: fix signed and unsigned comparison warning
../../libraries/AP_HAL/examples/Printf/Printf.cpp:63:17: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         if (ret != strlen(float_tests[i].result)) {
                 ^
...

ardupilot/modules/gtest/include/gtest/gtest.h:1448:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   if (expected == actual) {
                ^
And similar ones.
2016-05-04 08:58:37 -03:00
Lucas De Marchi 9ac63d7128 AP_HAL: examples: fix coding style 2016-05-04 08:58:37 -03:00
Lucas De Marchi b5d3094738 AP_ADC: fix warning on printf
../../libraries/AP_ADC/examples/AP_ADC_test/AP_ADC_test.cpp: In function ‘void show_timing()’:
../../libraries/AP_ADC/examples/AP_ADC_test/AP_ADC_test.cpp:61:88: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘uint32_t {aka unsigned int}’ [-Wformat=]
     hal.console->printf("timing: mint=%lu maxt=%lu avg=%lu\n", mint, maxt, totalt/count);
                                                                                        ^
../../libraries/AP_ADC/examples/AP_ADC_test/AP_ADC_test.cpp:61:88: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 4 has type ‘uint32_t {aka unsigned int}’ [-Wformat=]
../../libraries/AP_ADC/examples/AP_ADC_test/AP_ADC_test.cpp:61:88: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 5 has type ‘uint32_t {aka unsigned int}’ [-Wformat=]
2016-05-04 08:58:37 -03:00
Randy Mackay 53785d1f72 AP_RangeFinder: add Bebop and MAVLink types
Thanks OXINARF!
2016-05-04 15:00:48 +09:00
Randy Mackay 96f665061e AP_RangeFinder: call handle_msg for all backends 2016-05-04 12:10:58 +09:00
Randy Mackay 9b940687c1 AP_RangeFinder: rename CompanionComputer files to MAVLink 2016-05-04 12:10:58 +09:00
Randy Mackay c541cb27f8 AP_RangeFinder: rename CompanionComputer to MAVLink 2016-05-04 12:10:58 +09:00
Allan Matthew d3831e4a5d RangeFinder: add MAVLink rangefinder 2016-05-04 12:10:58 +09:00
Andrew Tridgell 7cdab2a6c9 SITL: FlightAxis can support 8 channels 2016-05-04 13:05:43 +10:00
Andrew Tridgell 9081310ff1 HAL_SITL: support simulator RC input 2016-05-04 12:51:28 +10:00
Andrew Tridgell 3b0cd9f101 SITL: added RC input from FlightAxis
use the interlink controller for input for 6 channels
2016-05-04 12:51:27 +10:00
Julien Beraud 33a699f29c AP_RangeFinder: Add support for bebop Rangefinder
This rangefinder uses an spi device to send pulses and an iio driver
in buffer mode to get data
The data is then analyzed and the maximum pulse received is considered to
represent the echo of the pulses that have been sent. The distance in time
between the pulse that is sent and the pulse with the maximum amplitude
is used to calculate the altitude based on the speed of sound.

There is a dependency with libiio, and in order to build, there is a need
to provide a rootfs that includes libiio.a.
The other solution is to build dynamically after having updated the rootfs
to use on compiled with a more recent toolchain and include libiio
2016-05-03 16:43:39 -03:00
Julien Beraud c22d791bfc AP_HAL_Linux: Add SPI driver for bebop 2016-05-03 16:43:39 -03:00
Julien Beraud d0114eac05 AP_HAL: Add bebop SPI Device to spi devices
Added to namespace
2016-05-03 16:43:39 -03:00
Julien Beraud 738096b3ae AP_HAL_Linux: Add support for Sonar GPIO 2016-05-03 16:43:39 -03:00
Andrew Tridgell 664ce5c16e AP_AHRS: don't use disabled gyro in rate controllers
obey INS_USE* parameters in gyro estimate
2016-05-01 22:16:06 +10:00
Andrew Tridgell 0e32c047c3 AP_Compass: allow for COMPASS_EXTERNAL=2 for forced external
this allows users with unusual compass bus connections to force the
compass to external
2016-05-01 10:54:46 +10:00
Michael du Breuil a17ea5c121 GCS_MAVLink: Add POSITION_TARGET_GLOBAL_INT to the list of messages 2016-05-01 07:38:23 +10:00
Michael Oborne 848fa27d1c GCS_MAVLink: support MAVLINK_MSG_ID_MISSION_ITEM_INT 2016-05-01 07:13:45 +10:00
Michael Oborne fb3fc118f1 AP_Mission: support MAVLINK_MSG_ID_MISSION_ITEM_INT 2016-05-01 07:13:23 +10:00
Andrew Tridgell ed999a283f AP_Compass: added get_learn_type() API
this allows caller to determine if EKF offsets should be saved
2016-04-30 16:43:14 +10:00
Michael du Breuil fff21a1db9 Mission: Remove support for CONDITION_CHANGE_ALT 2016-04-30 10:56:09 +09:00
Randy Mackay 85963cecb4 Location: add additional comments 2016-04-30 10:33:01 +09:00