Commit Graph

6574 Commits

Author SHA1 Message Date
Randy Mackay
ad99918fee AC_WPNav: recalc leash lengths if set_horizontal_velocity is called
Resolves bug in which do-set-speed allowed reducing the speed during the
mission but not increasing it.
Slow down distance is also recalculated.
Unnecessary call to calc_wp_leash_length removed from
set_spline_origin_and_destination.
2014-04-24 13:16:08 +09:00
Randy Mackay
46fba47c8e AC_WPNav: slow target point's speed near destination 2014-04-24 13:16:00 +09:00
priseborough
ecc8e45eda AP_NavEKF: Fix bug in position reset logic 2014-04-23 18:16:02 +10:00
Andrew Tridgell
b0fd94f18e AP_GPS: initialise a variable in uBlox driver 2014-04-23 18:15:53 +10:00
Randy Mackay
7c02a02bd8 AC_WPNav: reset_I flag moved to position controller 2014-04-23 15:00:14 +09:00
Randy Mackay
098f8169b0 AC_PosControl: add keep_xy_I_terms method
Stops horizontal PID's I terms from being reset when the controller is
next updated
2014-04-23 15:00:12 +09:00
Randy Mackay
4d5b73b968 AC_WPNav: add reset_I to set_loiter_target 2014-04-23 15:00:07 +09:00
Ju1ien
6c71569775 AC_PosControl: update_xy_controller allows not resetting I term 2014-04-23 14:59:49 +09:00
Ju1ien
5d0476e522 AC_WPNav: add reset_I to init_loiter_target 2014-04-23 14:59:47 +09:00
Randy Mackay
09a35cf90f AC_PosControl: bugfix for freezing I-term build-up 2014-04-23 11:33:53 +09:00
Randy Mackay
559a258ede AC_WPNav: bug fix to limit target point from moving beyond leash
Also pull Z-axis acceleration from position controller instead of using
#define
2014-04-22 23:05:11 +09:00
Randy Mackay
9c6995d8bb AC_PosControl: add get_accel_z method 2014-04-22 23:05:08 +09:00
Randy Mackay
e565ee6d33 AC_PosControl: stop I term build-up when motors at max 2014-04-22 23:05:06 +09:00
Andrew Tridgell
e10542dcae AP_Mission: added get_current_nav_index() function
this will return 0 when there is no current command, which is what is
expected in MAVLink when there is no mission

(it prevents the text to speech announcing "65 thousand 6 hundred and
thirty five", which is quite annoying!)
2014-04-22 11:40:18 +10:00
Michael Day
96173bfb8a AP_Rally: Added one getter method and made a utility method public. 2014-04-22 11:40:18 +10:00
Randy Mackay
0e065e4894 AP_InertialNav: get_velocity_xy const 2014-04-21 21:59:38 +09:00
Randy Mackay
6f6c9e2585 AC_PosControl: bug fix to vertical speed limit
Vehicle was not reaching target climb or descent rate because of
incorrectly defaulted acceleration
2014-04-21 21:36:02 +09:00
Andrew Tridgell
25667a11a0 AP_NavEKF: use AHRS vehicle class for sideslip calculation
Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-04-21 18:13:12 +10:00
Andrew Tridgell
5acd17b843 AP_NavEKF: cleanup some build warnings
Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-04-21 18:13:12 +10:00
Andrew Tridgell
c8c6e05a4a AP_AHRS: added vehicle class to AHRS
used by EKF to control use of get_fly_forward()
2014-04-21 18:13:12 +10:00
priseborough
bd28cdbdcf AP_NavEKF: Improved magnetometer consistency checks
A magnetometer axis that fails the innovation consistency check will cause
all axes not to be used. If this condition continues for 10 seconds, a
magnetometer timeout condition will be declared. When the timeout has
occurred, if it is not a fly forward vehicle, then individual channels
will be used again, but with a reduced weighting.
2014-04-21 16:31:31 +10:00
Randy Mackay
648787a6c8 AC_WPNav: rename some definitions 2014-04-21 15:06:29 +09:00
Randy Mackay
2167dd7d3e AC_WPNav: update target speed immediately 2014-04-21 14:51:26 +09:00
Andrew Tridgell
05bffb5915 HAL_SITL: enable use of SIM_FLOAT_EXCEPT parameter 2014-04-21 15:37:08 +10:00
Andrew Tridgell
e0db7b117f SITL: added SIM_FLOAT_EXCEPT parameter
this enables checking for floating point exceptions
2014-04-21 15:37:08 +10:00
Andrew Tridgell
610a930612 AP_NavEKF: catch covarience errors and reset filter
this catches covariance values beyond a reasonable limit and resets
the filter is they happen
2014-04-21 15:37:08 +10:00
Andrew Tridgell
7e5a491f14 AP_Math: prevent a floating point exception 2014-04-21 15:37:08 +10:00
Andrew Tridgell
4d24a86088 AP_AHRS: prevent a infinity value 2014-04-21 15:37:07 +10:00
Randy Mackay
d382fa51ee AC_WPNav: run loiter and wp nav at 50hz on Pixhawk 2014-04-21 13:32:02 +09:00
Randy Mackay
72d2712c4e AC_WPNav: integrate update_xy_controller name change 2014-04-21 13:31:58 +09:00
Randy Mackay
966340a02a Circle: integrate update_xy_controller name change 2014-04-21 13:31:57 +09:00
Randy Mackay
7e376bc517 PosControl: update_pos_controller renamed to update_xy_controller 2014-04-21 13:31:55 +09:00
Andrew Tridgell
4756dbee84 AP_NavEKF: fixed millisecond subtraction for rollover
Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-04-21 13:16:20 +10:00
Andrew Tridgell
be9d0c1c4d APM_OBC: setup termination values in PX4IO
this sets up the PX4IO board with failsafe values in case the FMU is
not running
2014-04-21 11:52:53 +10:00
Andrew Tridgell
0d4985079e RC_Channel: added support for LimitValue settings
this allows you to set a channel failsafe or radio_out to a limit
value
2014-04-21 11:52:41 +10:00
Andrew Tridgell
7f4178d967 RC_Channel: added setup_failsafe_trim_all() function
sets all channels to output trim values on FMU failure
2014-04-21 08:37:24 +10:00
Andrew Tridgell
5cd145a307 AP_HAL: added set_failsafe_pwm() API
this allows the PWM values for FMU firmware failure to be setup
2014-04-21 08:36:52 +10:00
Andrew Tridgell
7f9a9107c7 APM_Control: logging_started needs to be static
prevents writing log headers twice
2014-04-21 07:13:06 +10:00
Andrew Tridgell
68f1ae3036 AP_NavEKF: fixed some matlab ! -> ~ typos
Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-04-20 21:44:37 +10:00
Andrew Tridgell
5a7afbf2cd AP_GPS: prevent writing GPS log headings multiple times 2014-04-20 21:44:14 +10:00
Randy Mackay
e3ffd5c0dd Common: remove RallyLocation defintion 2014-04-19 15:00:28 +09:00
Randy Mackay
7011ab40c2 Rally: define RALLY_WP_SIZE and RallyLocation 2014-04-19 15:00:25 +09:00
Michael Day
a2aab2ab5e AP_Rally: Minor fixes to AP_Rally after initial testing
- If a Rally point is being used, always respect the altitude set by the
user (don't take the max of that and the home point altitude).

- No need for constructor to pass in size of RallyLocation struct
2014-04-19 09:16:02 +10:00
Andrew Chapman
5825bac410 AP_Rally library 2014-04-19 09:15:59 +10:00
Randy Mackay
5322093475 Mission: fix example sketch after GPS lib changes 2014-04-17 16:41:38 +09:00
Andrew Tridgell
b4c5f31b17 APM_Control: reduce the number of parameter saves in autotune
don't save a parameter unless it has changed by 0.1%
2014-04-17 17:20:40 +10:00
Paul Riseborough
ccc7d36493 APM_Control: Modify D and I gain scaling 2014-04-17 17:11:48 +10:00
Randy Mackay
94d38ee294 AC_Circle: add get_closest_point_on_circle
init_start_angle method added to use current heading or position to
decide on initial start angle
2014-04-16 16:28:04 +09:00
Kevin Hester
c2184cb8e4 PID: fixup line endings 2014-04-15 15:57:56 +09:00
Kevin Hester
72e97cbf5c AP_Param: fixup line endings 2014-04-15 15:57:47 +09:00
Kevin Hester
a7820e6c71 OptFlow: fixup line endings 2014-04-15 15:57:33 +09:00
Kevin Hester
fce1277b0e Notify: fixup line endings 2014-04-15 15:57:11 +09:00
Kevin Hester
b7bed437c2 Compass: fixup line endings 2014-04-15 15:56:57 +09:00
Kevin Hester
80cb13e222 BattMon: fixup line endings 2014-04-15 15:56:43 +09:00
Kevin Hester
d09e871319 AP_Airspeed: fixup line endings 2014-04-15 15:56:26 +09:00
Kevin Hester
c34c4d79f6 AP_ADC: fixup line endings 2014-04-15 15:56:13 +09:00
Kevin Hester
b7410494e3 AC_PID: fixup line endings 2014-04-15 15:55:59 +09:00
L. Preston Sego III
3ecdc4b741 Copter: Add support for V-Tail Quads 2014-04-14 14:54:02 +09:00
Randy Mackay
02775e8dc5 AC_PosControl: get_accel_target returns const ref 2014-04-14 11:34:14 +09:00
Randy Mackay
60f522a094 AC_WPNav: set_wp_destination to use current target
Previously we used the projected stopping point if the vehicle had not
reached the destination but this could lead to large jumps in target
position
2014-04-13 22:42:50 +09:00
Andrew Tridgell
ae7293ef68 APM_Control: added support for AUTOTUNE_LEVEL
10 levels of tune, for what type of tune the user wants
2014-04-13 22:11:57 +10:00
Andrew Tridgell
86f167fc7f AP_Vehicle: added autotune_level to fixed wing parms 2014-04-13 22:11:28 +10:00
Andrew Tridgell
b7350118a6 AP_AHRS: enable EKF wind estimate with no airspeed sensor
EKF can now estimate with IMU and GPS only

Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-04-13 19:42:49 +10:00
Andrew Tridgell
4abc2999a6 AP_NavEKF: start with a wind estimate of 3m/s, when no direct measurement
this will cope better with users with low roll/pitch gains, to ensure
they get enough control on takeoff

Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-04-13 19:42:23 +10:00
priseborough
d745dc2b6f AP_NavEKF : Increased position gate default to reduce impact of accel errors
Flight testing with windup turns has shown that the position gate threshold
can be tripped with good GPS data causing position jerks. This increases the
initial GPS glitch rejection threshold to effectively 5m when using the
default POSNE_NOISE value of 0.5m.
2014-04-13 19:37:22 +10:00
priseborough
188bea6bab AP_NavEKF : Enable calc of wind velocity when not using airspeed sensing
This patch also cleans up the logic associated with use of the synthetic
sideslip measurement so that it can never be used for a non fly-forward
vehicle type

This patch adds functionality that initialises the wind-speed vector to the
reciprocal of the ground speed vector, and scaled to 6 m/s. On average this gives
a better initial wind velocity estimate on launch by assuming:

a) launch will be into wind
b) wind speed is equal to global average

It also helps prevent a headwind causing initial underestimation of airspeed
causing high autopilot gains and limit cycles on climb-out, until first
turn when the EKF is able to estimate the wind.
2014-04-13 19:37:19 +10:00
Andrew Tridgell
df192a9efd AP_AutoTune: lower min tau to 0.2 2014-04-13 19:25:54 +10:00
Andrew Tridgell
3343af602e APM_Control: fixed saving of new rate gains 2014-04-13 15:35:52 +10:00
Andrew Tridgell
b9a8ef3b51 APM_Control: fixed a bug in autotune servo saturation check
its in degrees not centi-degrees
2014-04-13 15:28:36 +10:00
Andrew Tridgell
64170d0f04 APM_Control: added dataflash logging to autotune 2014-04-12 18:21:50 +10:00
Andrew Tridgell
7f5eeabadc DataFlash: reserve a range of msg types for autotuning logs 2014-04-12 18:21:31 +10:00
Andrew Tridgell
50fc75917e APM_Control: first version of APM_Control autotuning
this adds autotune to the roll/pitch controllers using a very simple
mechanism. The plan is that this provides a framework which Paul and
Jon will build upon.
2014-04-12 14:11:33 +10:00
Andrew Tridgell
3b8839d2f7 AP_GPS: fixed num_sensors on APM2 2014-04-11 21:32:55 +10:00
Andrew Tridgell
7404fc9d40 SITL: added SIM_BARO_DISABLE parameter
useful for testing baro failure
2014-04-11 16:47:40 +10:00
Andrew Tridgell
ad18019fb1 APM_OBC: added pressure altitude termination 2014-04-11 16:47:40 +10:00
Andrew Tridgell
41dd280739 AP_Baro: expose get_altitude_difference()
this is useful for pressure altitude calculations
2014-04-11 16:34:02 +10:00
Andrew Tridgell
8b9b4026f0 SITL: support -P option
this allows changing a parameter on initial startup
2014-04-11 12:28:32 +10:00
Michael Day
312a2fc8dc AP_TECS: Parameter TECS_LAND_SPDWGT allows custom landing speed weight. 2014-04-10 15:42:49 +10:00
Andrew Tridgell
95304e27c9 DataFlash: added separate logging of each GPS 2014-04-10 10:29:30 +10:00
Andrew Tridgell
a821b0e198 AP_GPS: fixed a build warning
Debug() should not be exposed in public headers
2014-04-10 10:28:55 +10:00
Andrew Tridgell
27a3b5fb36 AP_AHRS: fixed wind reporting with EKF and no airspeed sensor
the EKF does not estimate wind without an airspeed sensor
2014-04-10 06:49:23 +10:00
Randy Mackay
b78e59ea30 AP_Motors: add stability patch test to example sketch 2014-04-09 21:21:29 +09:00
Andrew Tridgell
a15e4633b7 SITL: prevent wind effects at negative altitudes
this prevents crashes on takeoff with barometer noise
2014-04-09 15:28:14 +10:00
Andrew Tridgell
1ca6583df8 AP_BoardConfig: restore /dev/vroutput change from Emile
my mistake, sorry Emile!
2014-04-08 21:05:41 +10:00
Emile Castelnuovo
79996986ad VRBRAIN: corrected ADC pins for volt and current sensing. 2014-04-08 16:19:20 +10:00
Emile Castelnuovo
7fe4847b6c VRBRAIN: Added NuttX driver vroutput for PWM out
Modified script rc.APM to launch modules vrinput and vroutput
Modified startup scripts to run APM without SD
2014-04-08 16:19:20 +10:00
Emile Castelnuovo
d1e4fbf267 AP_EPM: added #defines for VRBRAIN board 2014-04-08 16:19:20 +10:00
Emile Castelnuovo
e8b9e9d53c AP_Airspeed: added #defines for VRBRAIN board 2014-04-08 16:19:20 +10:00
Emile Castelnuovo
69d2633465 AP_Relay: added #defines for VRBRAIN board 2014-04-08 16:19:19 +10:00
Emile Castelnuovo
25f1c5774f AP_NavEKF: added #defines for VRBRAIN board 2014-04-08 16:19:19 +10:00
Emile Castelnuovo
39d9e93904 AP_BoardConfig: added #defines for VRBRAIN board 2014-04-08 16:19:19 +10:00
Emile Castelnuovo
1d27e0d127 AP_BattMonitor: added #defines for VRBRAIN board 2014-04-08 16:19:19 +10:00
Emile Castelnuovo
ab9a320187 DataFlash: added #ifdefs for VRBRAIN board 2014-04-08 16:19:19 +10:00
Emile Castelnuovo
06744ea7d2 AP_InertialSensor: new files and definitions for VRBRAIN board 2014-04-08 16:19:19 +10:00
Emile Castelnuovo
4ad83f3c8a AP_Notify: new files and definitions for VRBRAIN board 2014-04-08 16:19:19 +10:00
Emile Castelnuovo
1bc199c5bd AP_Compass: new files and definition for VRBRAIN board 2014-04-08 16:19:19 +10:00
Emile Castelnuovo
7b5c002d2f AP_Common: new board ID for VRBRAIN 2014-04-08 16:19:19 +10:00
Emile Castelnuovo
f4784fe6a1 AP_Baro: new files for VRBRAIN board 2014-04-08 16:19:19 +10:00
Emile Castelnuovo
201332caef AP_HAL: New VRBRAIN board definition and libraries 2014-04-08 16:19:19 +10:00
priseborough
db043744a4 AP_NavEKF : Reduce Z accel bias process noise to provide a more stable estimate 2014-04-07 21:08:25 +10:00
priseborough
1f8b5a6d23 AP_NavEKF : Tighten GPS velocity glitch gate default setting for plane 2014-04-07 21:08:15 +10:00
priseborough
0c2489b07b AP_NavEKF : Fix bug in logging of airspeed innovation consistency ratio 2014-04-07 21:01:00 +10:00
priseborough
95c83255d7 AP_NavEKF : adjust default values for accelerometer process noise
Slows down estimate and allows for smaller values to be set
2014-04-07 21:00:43 +10:00
Jonathan Challinger
9959a44453 AP_Motors: properly constrain thr_adj_max 2014-04-07 14:14:32 +09:00
Randy Mackay
3600bed47a Parachute: relay parameter description update 2014-04-07 13:37:14 +09:00
Randy Mackay
879d447404 Parachute: alt_min units to meters 2014-04-07 13:37:11 +09:00
Randy Mackay
50df95316a Parachute: initialise released variable 2014-04-07 13:37:09 +09:00
Randy Mackay
5876a2fe47 AC_AttControl: increase default rp accel to 900deg/s/s 2014-04-07 13:37:08 +09:00
Randy Mackay
95579229ed Parachute: add 0.5sec delay before parachute is released
This allows a short warning to the user through the new parachute_release tone
2014-04-07 13:37:05 +09:00
Randy Mackay
103772abe2 Parachute: add AP_Notify.h to example sketch 2014-04-07 13:37:04 +09:00
Randy Mackay
a639df0256 Parachute: set AP_Notify parachute_release flag 2014-04-07 13:37:02 +09:00
Randy Mackay
e3e7fc284d Notify: add parachute release tune for Pixhawk 2014-04-07 13:37:01 +09:00
Randy Mackay
699b84e8ca Parachute: minor comment changes 2014-04-07 13:36:58 +09:00
Randy Mackay
d8f9a1c6c6 Mission: add support for MAV_CMD_DO_PARACHUTE 2014-04-07 13:36:55 +09:00
Randy Mackay
a682f652d0 GCS_MAVLink: generate after MAV_CMD_DO_PARACHUTE added 2014-04-07 13:36:53 +09:00
Randy Mackay
cec7574465 GCS_MAVLink: add MAV_CMD_DO_PARACHUTE 2014-04-07 13:36:52 +09:00
Randy Mackay
b478c3a321 AC_AttControl: return angle_ef_targets as const ref 2014-04-07 13:36:49 +09:00
Randy Mackay
d4cb51d8f7 AP_Parachute: add example sketch
Only tests that the lib compiles
2014-04-07 13:36:37 +09:00
Randy Mackay
8600b9d4f1 RC_Channel: add parachute_release to function enum 2014-04-07 13:36:33 +09:00
Randy Mackay
9d807802cc Parachute: initial draft library 2014-04-07 13:36:25 +09:00
Andrew Tridgell
efdb678e00 AP_Motors: fixed example build 2014-04-07 11:55:56 +10:00
Andrew Tridgell
f4cbec0ce1 APM_OBC: removed unused example code 2014-04-07 11:55:46 +10:00
Andrew Tridgell
cc212be41e AP_Mission: added get_next_ground_course_cd() API
this gives the ground course of the next navigation leg, which can be
used to calculate the amount of steering required
2014-04-07 09:29:54 +10:00
Andrew Tridgell
e566802bf3 AP_Math: fixed example build 2014-04-07 07:37:34 +10:00
Andrew Tridgell
6f55dc1686 APM_OBC: update for AP_Mission and AP_GPS changes 2014-04-07 07:28:21 +10:00
Andrew Tridgell
43ebd86bb1 AP_GPS: disable SBP driver on APM2
the driver uses double precision floating point, which can't work on
8bit AVR with gcc
2014-04-05 21:47:46 +11:00
Andrew Tridgell
5a585b90e8 AP_GPS: fixed some warnings in SBP driver 2014-04-05 14:18:01 +11:00
Niels Joubert
33576dfdd9 AP_GPS: Swift Binary Protocol SINGLE-POINT-POSITIONING Driver
This is the SBP driver for Piksi, Lodestar and other forthcoming Swift Navigation GPSes.
This driver currently implements three things:
- Implements a lightweight SBP protocol detection system
- Implements Piksi as a single-point-positioning GPS (same as ublox/others)
- Implements hardware logging of GPS health and baseline messages

Forthcoming iin future updates:
- Need to implement the RTK functionality
2014-04-05 13:42:23 +11:00
Niels Joubert
e32b73f075 AP_HAL_AVR_SITL: Adding Swift Binary Protocol stand-alone simulator 2014-04-05 13:42:23 +11:00
Niels Joubert
00064ac883 SITL: Adding GPS types for Swift Binary Protocol 2014-04-05 13:42:23 +11:00
Niels Joubert
879eb5936b AP_MATH: Adding WGS GPS conversions, CRC16 checks, and double-precision Vectors and Matrices 2014-04-05 13:42:23 +11:00
Niels Joubert
161b5f99b3 SITL: Adding Swift Binary Protocol GPS type 2014-04-05 13:42:23 +11:00
Niels Joubert
552f33b39e AP_GPS: Support fix types of DGPS and RTK 2014-04-05 13:42:23 +11:00
Niels Joubert
64d4a1236f AP_Notify: Support all GPS status flags, with status >= GPS_OK_FIX_3D notified as having a lock 2014-04-05 13:42:23 +11:00
Andrew Tridgell
67ed5b73ef AP_GPS: added lock_port() interface
used by SERIAL_CONTROL message
2014-04-05 07:34:33 +11:00
Andrew Tridgell
b8675b9abc GCS_MAVLink: implement SERIAL_CONTROL MAVLink message 2014-04-05 07:34:33 +11:00
Andrew Tridgell
493c5dd63f GCS_MAVLink: rebuild MAVLink headers 2014-04-04 21:57:22 +11:00
Andrew Tridgell
14b3696959 GCS_MAVLink: added SERIAL_CONTROL message definition
will be used for on-board radio and GPS firmware update and control
over USB
2014-04-04 21:57:22 +11:00
Andrew Tridgell
07d621c4be AP_NavEKF: used state structure in more places
makes the code a bit easier to read

Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-04-04 21:30:16 +11:00
priseborough
aa5335b16e AP_NavEKF : Improved GPS position glitch handling
When using GPS after previously rejecting it, the GPS position will
always be offset if outside the specified glitch radius. This was the
original intent of the design and makes handling of glitches smoother.

It has been tested on replay using glitchy flight data
2014-04-04 21:01:22 +11:00
priseborough
b1786cf1e5 AP_NavEKF : Do not reset on GPS velocity timeout if good position data 2014-04-04 21:01:20 +11:00
priseborough
d25883f712 AP_NavEKF : Limit rate of Z accel bias adaptation
Aliasing can causes the bias estimate to fluctuate very rapidly as it tries
to keep up, which degrades the benefit of switching between
accelerometers to avoid aliasing.

This patch give a much more stable bias estimate during aliasing, and
allows the bias to adapt at a maximum rate of 1.0 m/s2 in 50 seconds
2014-04-04 21:01:18 +11:00
priseborough
36b3cbc365 AP_NavEKF : Relax aliasing check limits
This reduces the chance of noisy data inhibiting GPS glitch protection
2014-04-04 21:01:15 +11:00
priseborough
0ae736c3a0 AP_NavEKF : clean up convoluted logic used in sensor health checks
This doesn't change the behavior, but does make the code easier to
understand
2014-04-04 21:01:13 +11:00
Andrew Tridgell
013aaf4d3e GCS_MAVLink: moved comms functions to not be inline
saves a bit of flash space
2014-04-04 13:19:15 +11:00
Andrew Tridgell
d9d038345a AP_GPS: save 800 bytes of code space on APM2
we can assume a single GPS
2014-04-04 10:08:28 +11:00
Andrew Tridgell
9f857529ca AP_GPS: auto-switch primary GPS based on status and number of satellites 2014-04-04 08:32:34 +11:00
Andrew Tridgell
11f196318e RC_Channel: added static functions to simplify operations on all channels
this avoids vehicle code having to loop over all channels for common
operations
2014-04-03 12:18:56 +11:00
Andrew Tridgell
21c205a57e AP_GPS: cope with different MON-HW message size in u-Blox Neo7 2014-04-03 10:55:05 +11:00
Andrew Tridgell
cd3038fabd AP_NavEKF: fixed return of offset in getVariances() 2014-04-03 07:49:06 +11:00
Andrew Tridgell
dcb42af3e9 AP_BattMonitor: fixed example build 2014-04-03 07:49:06 +11:00
Craig Elder
3a92d75936 Ublox: Enable 1Hz Lock LED by default 2014-04-01 20:57:18 -07:00
Andrew Tridgell
067bbf5b5c DataFlash: hdop is unsigned 2014-04-02 07:55:28 +11:00
Andrew Tridgell
e40a048009 AP_GPS: handle multiple GPS in GPS setHIL() 2014-04-02 07:55:28 +11:00
Andrew Tridgell
79f5618f6f AP_GPS: zero state structure on driver release
this ensures no values are left from the previous driver
2014-04-02 07:55:28 +11:00
Randy Mackay
2ddc414f4d InertialNav: replace safe_sqrt with pythagorous2 2014-04-01 20:43:53 +09:00
Randy Mackay
90e205c905 AC_PosControl: replace safe_sqrt with pythagorous2 2014-04-01 20:43:51 +09:00
Randy Mackay
15da01cf3a AC_WPNav: replace safe_sqrt with pythagorous2 2014-04-01 20:43:45 +09:00
Andrew Tridgell
b8e4e35a0d AP_Airspeed: use pythagorous3() 2014-04-01 22:15:12 +11:00
Andrew Tridgell
a7f213a5c5 AP_NavEKF: use pythagorous2() 2014-04-01 22:13:03 +11:00
Andrew Tridgell
9ab1a79b5a AP_Airspeed: changed sqrt() to sqrtf() 2014-04-01 22:09:21 +11:00
priseborough
09c5ba1aed Dataflash : Improved logging of EKF sensor health checks
This changes the definition sof the messages in the EKF4 message to make it more useful
The values shown now relate directly to how much margin there is before a measurement
is rejected, enabling better tuning of error trap parameters
2014-04-01 21:27:07 +11:00
priseborough
04036d7777 AP_NavEKF : Updated GPS glitch protection logic
This adds new functionality to the detection and compensation of GPS
glitches:

1) A maximum allowable innovation is calculated using the GPS noise
parameter multiplied by the gate, with an additional component allowing
for growth in position uncertainty due to acceleration error since
the last valid measurement
2) Includes per vehicle type values for the acceleration error limit
3) If the innovation length exceeds the maximum allowable, no fusion occurs
4) If no fusion has occurred for long enough such that the position uncertainty
exceeds the maximum set by a per vehicle parameter or a maximum time, an offset
is applied to the GPS data to so that it matches the value predicted by the filter
5) The offset is never allowed to be bigger than 100m
6) The offset is decayed to zero at a rate of 1.0 m/s to allow GPS jumps to
be accommodated gradually
7) The default velocity innovation gate has been tightened up for copter and rover
8) The variance data logging output has been updated to make it more useful
2014-04-01 21:22:14 +11:00
Andrew Tridgell
7e2ef0cfc0 AP_GPS: fixed GPS for Replay 2014-04-01 17:25:15 +11:00
Andrew Tridgell
9278685cdf AP_Math: fixed location build on SITL 2014-04-01 14:20:10 +11:00
Andrew Tridgell
77e2f48581 AP_GPS: fixed notify updates for new API 2014-04-01 06:38:25 +11:00
Andrew Tridgell
9781175bf5 AP_GPS: fixed handling of driver destruction
this allows for more complex destructors, and ensures we don't have
multiple backends allocated at once per instance
2014-04-01 06:38:25 +11:00
Andrew Tridgell
7ceba8dce4 AP_GPS: prevent double allocation of GPS drivers 2014-04-01 06:38:25 +11:00
Andrew Tridgell
8779ffe088 AP_GPS: flush pending config strings when uBlox starts 2014-04-01 06:38:25 +11:00
Andrew Tridgell
0191355488 AP_GPS: fixed init strings to all be in progmem
and sent async ...
2014-04-01 06:38:25 +11:00
Andrew Tridgell
bc0c9ad6d5 AP_InertialNav: fixed example build 2014-04-01 06:38:25 +11:00
Andrew Tridgell
35c111a63a AP_AHRS: fixed example build 2014-04-01 06:38:25 +11:00
Andrew Tridgell
7b2d56a8cb AC_Fence: disable example build
fails to build with compiler error
2014-04-01 06:38:25 +11:00
Andrew Tridgell
3b8c6e629d AC_AttitudeControl: updated example for new GPS API 2014-04-01 06:38:25 +11:00
Andrew Tridgell
c2486d8d6e AP_GPS: updated examples for new API
removed old per-driver examples, and updates AUTO example
2014-04-01 06:38:25 +11:00
Andrew Tridgell
d04d33a02d AP_InertialNav: convert to new GPS API 2014-04-01 06:38:24 +11:00
Andrew Tridgell
5a2e84e792 AP_NavEKF: changes for new GPS API 2014-04-01 06:38:24 +11:00
Andrew Tridgell
b7a2db716b AP_Arming: convert to new GPS API 2014-04-01 06:38:24 +11:00
Andrew Tridgell
eb67948171 AP_Mount: convert to new GPS API 2014-04-01 06:38:24 +11:00
Andrew Tridgell
f07e4dee52 AP_AHRS: convert to new GPS API 2014-04-01 06:38:24 +11:00
Andrew Tridgell
31d3b6555f DataFlash: convert to new GPS API 2014-04-01 06:38:23 +11:00
Andrew Tridgell
368daf89f1 AP_GPS: new GPS API
This is a complete rewrite of the GPS driver structure, with a static
main driver and separate backend drivers. This will allow proper
support for multiple GPSes, and will allow parameters to be set on the
GPS object
2014-04-01 06:38:23 +11:00
Andrew Tridgell
2dd92832dc AP_GPS: support multiple AP_GPS_Auto drivers
move all static variables into a dynamically allocated structure in
the AUTO driver which gets freed when we have found a GPS type
2014-04-01 06:38:23 +11:00
Andrew Tridgell
3c4389180e AP_GPS: removed GPS_406 driver
this driver was untested and badly structured. If we want to support
the 406 we can revive it and do it properly
2014-04-01 06:38:23 +11:00
Jonathan Challinger
f0fc0397d3 Notify: add arming failure tone 2014-03-31 20:34:27 +09:00
Randy Mackay
7bb981f2df AP_Notify: correct dos formatting 2014-03-31 20:34:24 +09:00
Andrew Tridgell
31082f4ce2 AP_Mission: fixed a bug re-entering AUTO
this fixes a bug found by Marco where we would continue in CRUISE mode
with no waypoint if we re-entered AUTO after a mission reset
2014-03-31 06:18:07 +11:00
Randy Mackay
93f8d53d1b Mission: make get_prev_nav_cmd_index const 2014-03-30 23:09:54 +09:00
Randy Mackay
b15d4379d8 AC_WPNav: use atan2f, make methods const 2014-03-30 23:09:51 +09:00
Randy Mackay
3ad635feeb AC_AttControl: 45deg/sec yaw rate for Auto, RTL 2014-03-30 15:44:14 +09:00
Randy Mackay
d27ca53a9d AC_WPNav: spline sets origin vel to zero when no prev segment
Issue caught by Michael Oborne
2014-03-30 15:19:18 +09:00
Randy Mackay
7dfde39e19 AC_WPNav: advance_spline to use dt 2014-03-30 15:02:07 +09:00
Randy Mackay
c0458b786a AC_WPNav: check acceleration is non zero 2014-03-30 11:52:44 +09:00
Randy Mackay
f0f3688172 AC_WPNav: rounder corners for short spline segments 2014-03-30 11:52:41 +09:00
priseborough
9c5f564dc5 AP_NavEKF : Fixes bug in initial earth magnetic field states
The calculation for these states was not being bias corrected
2014-03-30 07:43:52 +11:00
Randy Mackay
7bff8e9312 AC_AttControl: constrain earth frame yaw angle error
This temporarily resolves the wobble we see in Auto when the target
heading is suddenly changed leading to a large yaw angle error
2014-03-29 20:42:21 +09:00
Randy Mackay
197683d539 WPNav: clean up spline comments 2014-03-29 17:57:47 +09:00
priseborough
e1819bb53a AP_NavEKF : Add initial parameter defaults for Copter, Rover and Plane 2014-03-29 14:06:43 +11:00
Randy Mackay
ac339a0289 Mission: add decoding of NAV_SPLINE command 2014-03-28 09:23:30 +09:00
Randy Mackay
e7be622eef GCS_MAVLink: generate after adding NAV_SPLINE cmd 2014-03-28 09:23:28 +09:00
Randy Mackay
519d5fc444 GCS_MAVLink: add MAV_CMD_NAV_SPLINE_WAYPOINT cmd
This is the same as a NAV_WAYPOINT except that the vehicle flies a
spline curved path to the destination
2014-03-28 09:23:23 +09:00
Randy Mackay
24eb195aa3 WPNav: add yaw control for straight line wp nav 2014-03-28 09:23:13 +09:00
Randy Mackay
b42b12f7be AC_WPNav: add get_spline_yaw 2014-03-28 09:23:07 +09:00
Randy Mackay
f2d9ad41aa Mission: minor comment update 2014-03-28 09:22:56 +09:00
Randy Mackay
e5e71ce371 WPNav: add spline support 2014-03-28 09:22:53 +09:00
Michael Day
e1d193f539 GCS_MAVLink: Generated code from message additions for autofence. 2014-03-27 09:26:20 +11:00
Michael Day
c5ebd120f1 GCS_MAVLink: XML for MAV_CMD_DO_FENCE_ENABLE and MAV_SYS_STATUS_GEOFENCE 2014-03-27 09:26:20 +11:00
priseborough
55c60b8f07 AP_NavEKF : Reduce Magnetometer innovation consistency check threshold 2014-03-26 21:29:47 +11:00
priseborough
45b1a2fa46 AP_NavEKF : Reduce GPS position innovation consistency fail threshold
This patch reduces the maximum acceptable GPS jump from approximately 16 to 8 metres
This will provide copters with more protection for close in loiter situations
2014-03-26 21:29:45 +11:00
Andrew Tridgell
8c0c9c317e RC_Channel: prevent a numerical exception with bad mount parameters 2014-03-26 17:38:27 +11:00
Andrew Tridgell
bafc664750 AP_NavEKF: use APM_BUILD_TYPE() macro 2014-03-26 12:42:11 +11:00
Andrew Tridgell
fbec098e2f AP_Vehicle: added APM_BUILD_TYPE() macro
this makes checking build type less fragile
2014-03-26 12:41:53 +11:00
Andrew Tridgell
e3792f9b26 AP_NavEKF: added a mechanism for per-vehicle-type defaults in EKF 2014-03-26 12:30:17 +11:00
Andrew Tridgell
6b2f0b9553 AP_Vehicle: added defines for main vehicle types 2014-03-26 12:15:45 +11:00
Andrew Tridgell
6bf2b5033e DataFlash: support logging up to 14 RC input channels 2014-03-25 16:39:19 +11:00
Andrew Tridgell
6039eab442 RC_Channel: support up to 12 aux channels on PX4
this allows RC13 and RC14 to work correctly as aux outputs on Pixhawk
2014-03-25 15:42:48 +11:00
Andrew Tridgell
64772cede8 GCS_MAVLink: rebuild MAVLink headers 2014-03-25 14:47:43 +11:00
Andrew Tridgell
d24547b390 GCS_MAVLink: merge latest msgs from upstream 2014-03-25 14:47:05 +11:00
Andrew Tridgell
6eee2421cc AP_HAL: removed RCInput valid_channels() and added new_input() and num_channels()
the valid_channels() method was inconsistently implemented between
boards, and served two quite different purposes. It is clearer as two
functions
2014-03-25 14:39:41 +11:00
Andrew Tridgell
27dbf608c8 DataFlash: fixed a build warning 2014-03-25 13:31:21 +11:00
Andrew Tridgell
2a9a89e020 HAL_PX4: fixes for merged upstream PX4Firmware 2014-03-25 10:30:00 +11:00
priseborough
17cdac7bc8 AP_NavEKF : Clean up angle and mag field initialisation
This path reduces duplicated code, eliminates unused variables and
causes the earth magnetic field states to be reset when exiting static mode
which will occur every time copter is armed. This enables copters to be
powered on and initialised inside vehicles or houses, without bad earth
field values affecting flight.
2014-03-24 19:54:48 +11:00
Andrew Tridgell
f05b90bfd2 GCS_MAVLink: fixed some compiler warnings 2014-03-24 12:52:39 +11:00
Andrew Tridgell
0af35bd636 AP_Mission: fixed some compiler warnings 2014-03-24 12:52:27 +11:00
Andrew Tridgell
2763393908 AP_InertialSensor: fixed some compiler warnings 2014-03-24 12:52:16 +11:00
Andrew Tridgell
c6f3e0a81c AP_GPS: fixed example builds 2014-03-24 12:20:34 +11:00
Andrew Tridgell
271ba3a6bc AP_InertialNav: fixed example build 2014-03-24 12:03:47 +11:00
Andrew Tridgell
1b1a92251f DataFlash: allow drivers to setup their own logging formats
this allows drivers to ask the dataflash driver to add new log formats
2014-03-24 12:03:31 +11:00
Andrew Tridgell
5630bb1ef6 AP_GPS: added detailed hardware status logging for uBlox
this gives us noise, jamming and RF information from the uBlox
protocol. This will hopefully allow a more detailed investigation of
antenna choices and RF interference
2014-03-24 12:02:37 +11:00
Andrew Tridgell
7ff293ca38 AP_GPS: added DataFlash to GPS init to allow for detailed logging
this will allow GPS drivers to log much more detailed device specific
information
2014-03-24 12:01:13 +11:00
Andrew Tridgell
485ae596fc AP_Compass: fixed last_update for secondary compass with primary failed
this ensures EKF and DCM will use a secondary compass if the primary
fails
2014-03-23 22:05:17 +11:00
Matthew Lloyd
60a4f74de6 AP_Compass: avoid division by zero if we haven't received any mag reports
Otherwise, get_field() will return NaNs after once every few calls to
read() during compassmot on PX4 platforms, which causes compassmot to fail.

This is a quick hack around the deeper issue, which could be something
like the PX4 mag driver experiencing starvation and skipping mag reports,
buffer overrun or something else that causes mag reports to be dropped.
Or perhaps we should never expect in the first place that we will always
receive at least one mag report between calls to read().
2014-03-23 21:22:32 +11:00
priseborough
7ae86b3979 AP_NavEKF : Track baro height observations pre-arm
This prevents copter from failing the pre-arm height discrepancy test
2014-03-23 18:25:50 +11:00
priseborough
7780d55788 AP_NavEKF : Prevent large magnetic field adaptations early in flight 2014-03-22 19:55:26 +11:00
Randy Mackay
3efad982c0 GCS_Mavlink: return MISSION_INVALID when conversion fails
Requested by MichaelO to allow better error message to be displayed to
user when the mission upload from the GCS to vehicle fails
2014-03-22 11:29:36 +09:00
Paul Riseborough
f7007569d1 AP_NavEKF : Fix bug that limits copter sensor delay compensation to 125
msec
2014-03-21 21:52:20 +11:00
Paul Riseborough
b2c0979947 AP_NavEKF : Fixes bug that causes accel bias to diverge in static mode, preventing copter arming 2014-03-21 21:49:50 +11:00
Andrew Tridgell
a55c4e2296 AP_TECS: set target airspeed, not min/max airspeed, on landing
this seems to prevent ballooning of the altitude when we are in the
landing approach, and gives a much smoother landing
2014-03-20 17:34:39 +11:00
Andrew Tridgell
98530928b5 AP_TECS: make target landing speed a float
some users may want more precise control
2014-03-20 17:34:36 +11:00
Andrew Tridgell
b1ad2be897 AP_SpdHgtControl: added get_target_airspeed() interface 2014-03-20 17:34:29 +11:00
Michael Day
bd7e1b82e1 AP_TECS: Auto landing now takes throttle_nudge into account. 2014-03-20 17:34:26 +11:00
Michael Day
861690dea2 AP_TECS: New params LAND_ARSPD and LAND_THR auto-slowing landings.
Also controlling pitch by ignoring height error during landing.
This serves to keep the nose up.
2014-03-20 17:34:23 +11:00
Andrew Tridgell
3bdc22d672 AP_Mission: make p1 16 bit
this gives us a 16 bit value for extra data on a location, allowing
for an accurate angle in centi-degrees.

Also add validation of the size of the union arms in Content
2014-03-20 16:57:09 +11:00
Andrew Tridgell
959cafef8d AP_Common: make alt in Location 24 bit
this allows for up to 83km mission altitudes, while allowing for 1
more byte in the command structure, making p1 16 bits
2014-03-20 16:57:09 +11:00
Andrew Tridgell
d508c7f37f GCS_MAVLink: re-generate MAVLink headers 2014-03-20 10:21:28 +11:00
Andrew Tridgell
106fda773f GCS_MAVLink: merge XML from upstream 2014-03-20 10:20:00 +11:00
Andrew Tridgell
8af9573806 GCS_MAVLink: allow logging of RADIO_STATUS, very useful for link analysis 2014-03-20 09:56:37 +11:00
Michael Day
68dbfd6315 DataFlash: Add Log_Write_Radio to store RSSI and noise on board. 2014-03-20 09:56:37 +11:00
Andrew Tridgell
8202cf437b AP_Relay: fixed Pixhawk relay pin numbers
thanks to Craig for spotting this!
2014-03-20 09:40:08 +11:00
Paul Riseborough
8a2d16d13d AP_NavEKF : modifed Zaccel bias noise parameter to prevent unstable bias estimate 2014-03-20 08:50:00 +11:00
Randy Mackay
c520cb789c Mission: cmd field types to match mavlink commands
Split Set-Servo and Repeat-Servo command structures
Split Set-Relay and Repeat-Relay command structures
2014-03-19 12:14:22 +09:00
Andrew Tridgell
0832aba6bc GCS_MAVLINK: moved deferred message handling into common code 2014-03-19 12:14:15 +09:00
Andrew Tridgell
8d89a64312 GCS_MAVLink: moved handling of MISSION_ITEM into common code 2014-03-19 12:14:09 +09:00
Andrew Tridgell
ba8c4b86a0 AP_InertialNav: fixed example build 2014-03-19 12:14:08 +09:00
Andrew Tridgell
d36989f6a1 AP_HAL: fixed example build 2014-03-19 12:14:06 +09:00
Andrew Tridgell
d3d71d597c AP_Baro: fixed example build 2014-03-19 12:14:05 +09:00
Andrew Tridgell
dbd8f4b735 AP_Airspeed: fixed example build 2014-03-19 12:14:03 +09:00
Andrew Tridgell
afab8a9c5b AP_AHRS: fixed example build 2014-03-19 12:14:02 +09:00
Andrew Tridgell
04587efb2d AC_WPNav: fixed example build 2014-03-19 12:14:00 +09:00
Andrew Tridgell
1e9dcba3da AC_Sprayer: fixed example build 2014-03-19 12:13:59 +09:00
Andrew Tridgell
4507c0fc4c AC_Fence: fixed example build 2014-03-19 12:13:57 +09:00
Andrew Tridgell
73ae38eaf0 AC_AttitudeControl: fixed example build 2014-03-19 12:13:56 +09:00
Andrew Tridgell
23e296dd00 GCS_Console: fixed example build 2014-03-19 12:13:55 +09:00
Andrew Tridgell
5f85792224 DataFlash: fixed example build 2014-03-19 12:13:53 +09:00
Andrew Tridgell
2a199c4f03 AP_Notify: fixed example build 2014-03-19 12:13:51 +09:00
Andrew Tridgell
6eece3a278 AP_Mount: fixed example build 2014-03-19 12:13:50 +09:00
Andrew Tridgell
acd54d0826 AP_Math: fixed example build 2014-03-19 12:13:48 +09:00
Andrew Tridgell
731f980327 AP_InertialSensor: fixed example build 2014-03-19 12:13:47 +09:00
Andrew Tridgell
965f6bd3bd GCS_MAVLink: make DataFlash a pointer
handle sketches where DataFlash is not available
2014-03-19 12:13:37 +09:00
Andrew Tridgell
b85c5123b2 GCS_MAVLink: added save parameter to handle_request_data_stream()
this allows copter to not save stream rate changes
2014-03-19 12:13:35 +09:00
Andrew Tridgell
79bb14b8c1 GCS_MAVLink: moved RADIO_STATUS handling into common code 2014-03-19 12:13:34 +09:00
Andrew Tridgell
144217ac74 GCS_MAVLink: moved parameter and stream handling into common code
this keeps it in common between vehicles, and saves stack space
2014-03-19 12:13:32 +09:00
Andrew Tridgell
06c578eb34 GCS_MAVLink: re-generate MAVLink headers 2014-03-19 12:13:31 +09:00
Andrew Tridgell
0b811ba6a9 GCS_MAVLink: added have_flow_control() method
can be used to change speed of handling some protocol methods, as we
know communication will be reliable
2014-03-19 12:13:25 +09:00
Randy Mackay
c462adf2ee GCS_MAVLink: added five handle_mission methods
The five methods moved from the vehicle specific code are
handle_mission_request_list, set_current, count, clear_all and
write_partial_list
2014-03-19 12:13:19 +09:00
Randy Mackay
3938fb7255 GCS_MAVLink: loiter direction removed
This is now handled in Mission library
2014-03-19 12:13:18 +09:00
Randy Mackay
37cff752c8 Mission: handle Loiter direction
loiter-unlimited, loiter-turns and loiter-time cms specify the turn
direction in Param3.  This is stored in the location's loiter_ccw flag.
Previously supported only in Plane, moving here allows us to share more
code with Plane, Copter, Rover.
2014-03-19 12:13:16 +09:00
Andrew Tridgell
add2416dbe GCS_MAVLink: added handle_mission_request() common function
this handles requests for mission items, using stack saving

Pair-Programmed-With: Randy Mackay <rmackay9@yahoo.com>
2014-03-19 12:13:10 +09:00
Andrew Tridgell
ce29bbe394 GCS_MAVLink: save some memory in log download
use an existing buffer instead of using the mavlink _send()
function. This saves some stack space in log download

Pair-Programmed-With: Randy Mackay <rmackay9@yahoo.com>
2014-03-19 12:13:09 +09:00
Randy Mackay
c75560218d Mission: command specific structures 2014-03-19 12:12:51 +09:00
Randy Mackay
865a4de33d Common: use PACKED instead of pragma pack for Location 2014-03-19 12:12:49 +09:00
Randy Mackay
869f325c66 DataFlash: Log_Write_MavCmd replaces Log_Write_Cmd 2014-03-19 12:12:43 +09:00
Andrew Tridgell
3a6698f54b AP_Mission: fixed typo 2014-03-19 12:12:42 +09:00
Andrew Tridgell
3538621c48 AP_Mission: doc updates 2014-03-19 12:12:40 +09:00
Randy Mackay
48329c1bba Mission: bug fix for loading consecutive do-cmds
The verify step was not being run for the 2nd consecutive do-command in
a mission list
2014-03-19 12:12:37 +09:00
Randy Mackay
ece02b0c9a Mission: get_prev_nav_cmd returns int16 2014-03-19 12:12:34 +09:00
Randy Mackay
266a1ce9af Mission: bug fix set_current_cmd
If mission had completed desired command index was ignored
2014-03-19 12:12:27 +09:00
Andrew Tridgell
107cc2c126 AP_Mission: added truncate() function
Used when loading a mission while flying

Pair-Programmed-With: Randy Mackay <rmackay9@yahoo.com>
2014-03-19 12:12:21 +09:00
Andrew Tridgell
acdaf561c8 AP_Mission: fixed typo 2014-03-19 12:12:15 +09:00
Randy Mackay
ebf72f5beb Dataflash: example sketch includes AP_Mission.h 2014-03-19 12:12:10 +09:00
Randy Mackay
150faafaf4 Dataflash: add Log_Write_Cmd method 2014-03-19 12:12:07 +09:00
Randy Mackay
8e117d29eb Mission: test exceeding command storage size 2014-03-19 12:11:55 +09:00
Randy Mackay
9e07070d86 Mission: pass eeprom start into constructor
This allows different storage locations for ArduCopter, Plane and Rover
2014-03-19 12:11:53 +09:00
Randy Mackay
7663c5898e AP_HAL_Boards: board specific storage size definition 2014-03-19 12:11:52 +09:00
Randy Mackay
ddc4cd4f18 Mission: add init and check_eeprom_version methods 2014-03-19 12:11:46 +09:00
Randy Mackay
4c0a31a9dc Mission: init home to zero before writing to eeprom 2014-03-19 12:11:37 +09:00
Randy Mackay
df339c05fc Mission: num_commands returns uint16 2014-03-19 12:11:25 +09:00
Randy Mackay
af186fba05 AP_Common: pack Location structure
This resolves issues storing and retrieving Location to eeprom as part
of AP_Mission
2014-03-19 12:11:13 +09:00
Randy Mackay
e60865b715 Mission: example sketch test for set_current_cmd 2014-03-19 12:11:12 +09:00
Randy Mackay
512b378c4a Mission: allow set_current_cmd when mission is not running
Can now be run when mission is complete or stopped.  When mission is
resumed it will begin at the set command.  This command can be either a
nav or do command
2014-03-19 12:11:10 +09:00
Andrew Tridgell
eaf34bba9a AP_Mission: fixed reset using set mission item to 0
this causes a mission reset
2014-03-19 12:11:07 +09:00
Randy Mackay
8dd301b0c2 Mission: set_current_cmd to use uint16 2014-03-19 12:11:06 +09:00
Randy Mackay
a6e422333e Mission: remove alt_in_cm from mavlink to cmd conversion 2014-03-19 12:11:01 +09:00
Randy Mackay
efd4058e8b AHRS: interate move of p1 from Location to mission cmd 2014-03-19 12:10:51 +09:00
Randy Mackay
5dd86bd7d7 Mission: update example sketch for p1's move to cmd structure 2014-03-19 12:10:49 +09:00
Randy Mackay
87126c9b71 Common: remove id and p1 from Location structure
id and p1 are now part of AP_Mission's Mission_Command structure
2014-03-19 12:10:46 +09:00
Randy Mackay
0dc3c9ab42 Mission: add p1 to command structure
mavlink_to_mission_cmd method extended to support plane including adding
parameter to allow the alt to be expressed in cm or meters
2014-03-19 12:10:45 +09:00
Randy Mackay
4c0ae63169 Mission: example sketch test replace_cmd method 2014-03-19 12:10:42 +09:00
Randy Mackay
61cc5e6b72 Mission: add replace_cmd method 2014-03-19 12:10:40 +09:00
Randy Mackay
ef21e32fbc Mission: example sketch tests set current command 2014-03-19 12:10:37 +09:00
Randy Mackay
3cbbd4ebb9 Mission: add set current command method 2014-03-19 12:10:36 +09:00
Randy Mackay
c7ffd2db90 Mission: reduce unnecessary search for do-commands
do_cmd_all_done flag is set after all do-commands are complete
2014-03-19 12:10:33 +09:00
Randy Mackay
0c92d60406 Mission: command index increase to int16
Once more eeprom space is allocated this will allow more than 255
commands
2014-03-19 12:10:31 +09:00
Randy Mackay
85b979ede9 Mission: support do-jump num_times is -1
do-jump loops forever when num times is set to -1
2014-03-19 12:10:29 +09:00
Randy Mackay
c6c43847b6 Mission: example sketch tests set home command 2014-03-19 12:10:27 +09:00
Randy Mackay
9ef27955b5 Common: add location options masks 2014-03-19 12:10:20 +09:00
Randy Mackay
cc8554fa2b Mission: fix example sketch 2014-03-19 12:10:18 +09:00
Randy Mackay
f4d8ccc128 Mission: add mavlink to cmd conversion methods 2014-03-19 12:10:17 +09:00
Randy Mackay
87c7d19f83 AP_Mission: special handling for cmd 2014-03-19 12:10:14 +09:00
Randy Mackay
e8db57ced3 AP_Mission: replace block read/write for eeprom
Also reserve command #0 for home position
2014-03-19 12:10:00 +09:00
Randy Mackay
fd009d0704 AP_Mission: tests added to example sketch 2014-03-19 12:09:59 +09:00
Randy Mackay
84b3497a82 AP_Mission: fixes to protect against endless loops 2014-03-19 12:09:57 +09:00
Randy Mackay
6086bc14be AP_Mission: mostly working draft 2014-03-19 12:09:56 +09:00
Randy Mackay
4285eba297 AP_Mission: initial draft library 2014-03-19 12:09:54 +09:00
Randy Mackay
dd45647626 AC_PosControl: update some comments re leash lengths 2014-03-17 10:13:02 +09:00
Holger Steinhaus
345115fddd AC_PosControl: fixed leash length calc for descent speed 2014-03-17 10:12:47 +09:00
Andrew Tridgell
6b5d27efbb AP_GPS: fixed example builds with change to init() 2014-03-16 06:44:50 +11:00
Andrew Tridgell
68462025ba RC_Channel: constrain norm_input() to -1 to 1
if RC is not properly calibrated we could get a value beyond 1, which
could cause some flight modes to exceed the roll/pitch limits of the
aircraft
2014-03-15 20:43:13 +11:00
Andrew Tridgell
9cf1fd46c8 AP_GPS: removed nav_setting default
not needed, and apparently caused issue with xcode 5.1
2014-03-14 07:49:56 +11:00
Paul Riseborough
dacba5d911 AP_NavEKF : Update default tuning parameters (for plane use) 2014-03-14 06:07:58 +11:00
Paul Riseborough
d0828d9c15 AP_NavEKF : Prevent bad user parameter causing incorrect GPS fusion 2014-03-14 06:07:58 +11:00
Paul Riseborough
a24bfc1b8a AP_NavEKF : Use synthetic sideslip fusion during GPS denied operation with airspeed 2014-03-14 06:07:57 +11:00
Paul Riseborough
35811758d7 AP_NavEKF : Update comments and remove un-used function declarations 2014-03-14 06:07:57 +11:00
Andrew Tridgell
db48ed9218 AP_Compass: fixed showing of is_external for 2nd compass 2014-03-13 16:26:43 +11:00
Andrew Tridgell
beb6123576 GCS_MAVLink: send a "zero logs" message when no logs available 2014-03-11 17:12:22 +11:00
Andrew Tridgell
ecdd74d580 DataFlash: return number of logs as zero correctly
when we have no file based logs, report no logs :)
2014-03-11 17:11:58 +11:00
Andrew Tridgell
d9e8c34a89 GCS_MAVLink: allow for proxying of larger MAVLink messages on PX4
this makes it possible to deal with large MAVLink messages
2014-03-11 13:48:25 +11:00
Paul Riseborough
784034170d AP_NavEKF : increased useage of helper functions 2014-03-10 21:54:03 +11:00
Paul Riseborough
7b3130cfcc AP_NaVEKF : Enable operation without airspeed and compass 2014-03-10 21:53:09 +11:00
Paul Riseborough
3a5acb9cea AP_NavEKF : improved on-ground, in-air check and GPS yaw alignment 2014-03-10 14:07:34 +11:00
Paul Riseborough
b47a11edf6 AP_NavEKF : improved static and on-ground mode selection logic 2014-03-10 04:39:59 +11:00
Paul Riseborough
15a44571c2 AP_NavEKF : enable operation without a compass for planes 2014-03-09 20:01:45 +11:00
Paul Riseborough
2019708056 AP_NavEKF : Make all compass use autodetect 2014-03-09 19:59:19 +11:00
Paul Riseborough
e485b246e7 AP_NavEKF : update comments 2014-03-09 19:59:18 +11:00
Paul Riseborough
c8bd415b00 AP_NavEKF : Add sideslip constraint to allow plane flight without magnetometer 2014-03-09 19:59:17 +11:00
Paul Riseborough
52fabc822f AP_NavEKF : Add low speed magnetometer calibration option 2014-03-09 19:59:16 +11:00
Paul Riseborough
88b0364fcd AP_TECS : Add protection for airspeed runaway due to pitch errors 2014-03-09 19:59:16 +11:00
priseborough
6ace31b6c1 AP_NavEKF : Fix bug that leaves height unconstrained in static mode 2014-03-09 19:27:21 +11:00
Mike McCauley
c90d3ff59e Flymaple: RCOUtput disable_ch() now supports disabling outputs 2014-03-08 21:55:57 +11:00
Andrew Tridgell
794cc33e6a GPS: added set_secondary() function
for preventing notify updates for 2nd GPS
2014-03-08 21:47:49 +11:00
Paul Riseborough
94ff7522fc AP_NavEKF : Fix bug in initial East mag field state variance 2014-03-08 07:44:34 +11:00
Andrew Tridgell
63234d4c22 AP_Baro: fixed linux build of BMP085 driver 2014-03-07 09:33:43 +11:00
Randy Mackay
4cfe50b70c Notify: brighter RGB LED when on battery power 2014-03-05 21:38:29 +09:00
Randy Mackay
1c457d8448 Mount: add get_mode and set_mode_to_default methods 2014-03-05 16:01:11 +09:00
Andrew Tridgell
dd502e98b4 RC_Channel: added support for separate wheel steering channels on planes 2014-03-05 12:57:50 +11:00
Andrew Tridgell
a788405c8b RC_Channel: added percent_input() function
useful for plane flaps
2014-03-05 09:17:50 +11:00
Randy Mackay
25ee5d5dc8 AC_AttControl: smoothing_gain to angle_ef_roll_pitch_rate_ef_yaw_smooth
pair-programmed with lthall
2014-03-04 22:23:14 +09:00
lthall
15f88c2a2b AC_AttControl: Stabilize input shaping 2014-03-04 21:52:18 +09:00
Andrew Tridgell
5f85e7af6a HAL_PX4: switch to new serial port for 2nd GPS 2014-03-04 20:34:44 +11:00
Andrew Tridgell
af2f72acb0 HAL_SITL: honor SIM_GPS2_ENABLE option 2014-03-03 07:07:29 +11:00
Andrew Tridgell
7a52938f68 SITL: added SIM_GPS2_ENABLE option 2014-03-03 07:07:09 +11:00
Mike McCauley
be34e0358a RC_Channel: Removed duplicate defines from RC_Channel.h 2014-03-03 06:34:34 +11:00
Andrew Tridgell
449d09051e AP_NavEKF: cope with compass going offline while in flight 2014-03-02 14:32:10 +11:00
Andrew Tridgell
77f91e6250 AP_NavEKF: don't assume the number of gyros == number of accels 2014-03-02 13:53:19 +11:00
Paul Riseborough
ebb3cc3348 AP_NavEKF : Use average of dual IMU gyro data when available 2014-03-02 13:28:44 +11:00
Paul Riseborough
a39d00fc13 AP_NavEKF : Fix bug that prevents Zacc bias state variance being updated 2014-03-02 13:27:22 +11:00
Paul Riseborough
573b3210dd AP_NavEKF : Add div0 protection to the IMU1_weighting calc 2014-03-02 08:10:06 +11:00
Paul Riseborough
bd152d332c AP_NavEKF : Add accel aliasing protection 2014-03-02 08:10:04 +11:00
Andrew Tridgell
853271dd37 Replay: moved replay tool into Tools/Replay 2014-03-01 14:30:55 +11:00
Andrew Tridgell
295cd9adba AP_NavEKF: give a sensible error for no such file on replay 2014-03-01 14:24:51 +11:00
Paul Riseborough
854f013146 AP_NavEKF : Fixes zero compass offsets on initialisation 2014-02-28 19:43:12 +11:00
Andrew Tridgell
cc4c443b32 SITL: simulate dual accel/gyro 2014-02-28 17:30:38 +11:00
Jonathan Challinger
e81d2e9584 AP_InertialSensor: Correct out-of-bounds array access that was causing SITL to crash 2014-02-28 17:25:54 +11:00
Andrew Tridgell
736201689b AP_NavEKF: only use the active accel from DCM if fly_forward is set 2014-02-27 17:40:13 +11:00
Andrew Tridgell
aaaae9a222 AP_AHRS: added get_fly_forward() method
will be used to detect a copter
2014-02-27 17:39:49 +11:00
Paul Riseborough
62eff63267 AP_NavEKF : Increase the tuning range for magnetometer measurement noise 2014-02-27 17:20:38 +11:00
Andrew Tridgell
9a5ecc9541 AP_AHRS: use primary accel for accel_ef
Logs from Randy show that the copter INav code can't handle the
accelerometer sensor changing.
2014-02-27 16:28:37 +11:00
Andrew Tridgell
2c85a7ba56 AP_InertialSensor: expose get_primary_accel() for use in AHRS 2014-02-27 16:27:46 +11:00
Andrew Tridgell
cf148fa76c AP_Compass: improved COMPASS_ORIENT and COMPASS_EXTERNAL for Pixhawk 2014-02-27 12:46:27 +11:00
Andrew Tridgell
a9e683dada AP_NavEKF: use the accelerometer chosen by DCM for each step 2014-02-27 09:41:48 +11:00
Andrew Tridgell
b53496d470 AP_AHRS: choose the best accelerometer at each drift correction step
this greatly reduces the impact of aliasing on accelerometers by
choosing the accelerometer that produces the smallest error term in
DCM. The difference can be quite dramatic on the Pixhawk.
2014-02-27 09:41:28 +11:00
Andrew Tridgell
0b45d2bc06 AP_AHRS: removed the AHRS_GPS_DELAY parameter
the best value has turned out to be 1, and tweaking it has not turned
out to be useful, so this simplifies the code in preparation for
adding the anti-aliasing handling with multiple accelerometers
2014-02-27 08:57:44 +11:00
Paul Riseborough
78a1cac560 AP_NavEKF : Improved heading and magnetic field state initialisation 2014-02-27 08:12:10 +11:00
Paul Riseborough
d83b382e59 AP_NavEKF : Fix variance constraint bug
Constraining variances to a minimum value of 1e-9 was causing problems
with gyro bias and angular accuracy in noisy GPS environments.
Because the constraint is applied after every covariance prediction
and correction, a lower value of 0 is more appropriate.
2014-02-27 08:12:03 +11:00
Andrew Tridgell
8b59e564ba AP_NavEKF: improved replay timing 2014-02-27 08:11:04 +11:00
Andrew Tridgell
840f1b9a1e AP_InertialSensor: make HIL timing more accurate
needed for 400Hz replay
2014-02-27 08:10:42 +11:00
Andrew Tridgell
66f238c0da AP_NavEKF: support 400Hz replay from 50Hz logs 2014-02-26 19:34:01 +11:00
Andrew Tridgell
3fa2207a2d AP_HAL: allow for microsecond resolution in scheduler->stop_clock()
this makes 400Hz in the replay code possible
2014-02-26 19:33:39 +11:00
Andrew Tridgell
6fc5c12f1d AP_AHRS: remove unused variable 2014-02-26 10:28:12 +11:00
Andrew Tridgell
866e32f059 AP_Motors: removed unused variable 2014-02-26 09:40:39 +11:00
Andrew Tridgell
e410733682 DataFlash: added GPS2 logging 2014-02-26 09:19:00 +11:00
Andrew Tridgell
0115b9fa07 HAL_SITL: support a 2nd GPS 2014-02-26 08:19:47 +11:00
Andrew Tridgell
836f473db2 HAL_FLYMAPLE: no uartE 2014-02-26 08:19:20 +11:00
Andrew Tridgell
58d5454d65 HAL_Empty: no uartE 2014-02-26 08:19:18 +11:00
Andrew Tridgell
6c74ca58c3 HAL_AVR: no uartE 2014-02-26 08:19:15 +11:00
Andrew Tridgell
4cb61f1f08 AP_HAL: support uartE 2014-02-26 08:18:20 +11:00
Andrew Tridgell
bf2dd141e9 HAL_PX4: support uartE for 2nd GPS 2014-02-26 08:18:11 +11:00
Andrew Tridgell
63874dfffd AP_NavEKF: set fix type in GPS replay 2014-02-25 21:10:49 +11:00
Andrew Tridgell
d7b2a09919 AP_GPS: added fix type to setHIL 2014-02-25 21:10:30 +11:00
Andrew Tridgell
09cce5d24e AP_NavEKF: fixed replay with current copter logs 2014-02-25 20:56:53 +11:00
Jonathan Challinger
f321a5f241 AP_AHRS: Change airspeed_estimate to const in children of AP_AHRS
Allows roll/pitch controllers to use DCM's airspeed estimate. Thanks to Kevin Hester for assistance in finding this.
2014-02-25 18:49:16 +11:00
Paul Riseborough
72a91ccbca AP_NavEKF : Prevents aliasing triggering innovation consistency check failures 2014-02-25 15:55:44 +11:00
Andrew Tridgell
7a6f671659 AP_GPS: added have_vertical_velocity() function
for use by EKF
2014-02-24 18:24:10 +11:00
Andrew Tridgell
a273951f70 HAL_Linux: added missing Util.cpp 2014-02-24 11:59:24 +11:00
Paul Riseborough
5db9a87d31 AP_NavEKF : fixed bug in velocity rate of change filter
This bug meant the velocity rate of change used to scale the GPS measurement variances was noisy and too small
2014-02-23 19:50:37 +11:00
Paul Riseborough
01c84c3f47 AP_NavEKF : fixed bug in height limit range 2014-02-23 19:50:36 +11:00
Paul Riseborough
36d619ec3a AP_NavEKF : Changed default IMU bias process noise to use smallest value 2014-02-23 19:50:36 +11:00
Paul Riseborough
89e0b48320 AP_NavEKF : Bug fix for height drift due to timer wrap-around 2014-02-23 19:50:35 +11:00
Paul Riseborough
939a32a7bb AP_NavEKF : Improved stability of Z accel bias 2014-02-23 19:50:34 +11:00
Paul Riseborough
9f3c19c03a AP_AHRS : change initialisation requirements for EKF and use dynamic method 2014-02-23 19:50:34 +11:00
Andrew Tridgell
6732d6c79b AP_InertialSensor: enable get_accel_count() and get_gyro_count() APIs for HIL 2014-02-23 19:10:07 +11:00
Andrew Tridgell
5d7346b5c2 HAL_SITL: fixed build with new HIL INS API 2014-02-23 19:09:41 +11:00
Andrew Tridgell
ffbd655ba0 AP_NavEKF: support dual sensors in log replay, and fix flight altitude 2014-02-23 08:17:55 +11:00
Andrew Tridgell
707cc2b532 AP_NavEKF: allow log filename to be specified in replay 2014-02-23 08:17:01 +11:00
Andrew Tridgell
0e18079c47 AP_InertialSensor: allow HIL sensors to support multiple instances
this allows log replay to test both sets of sensors on a Pixhawk log
2014-02-23 08:16:33 +11:00
Andrew Tridgell
735c6449a1 AP_HAL: added support for commandline arguments
useful for log replay, specifying log file
2014-02-23 08:15:39 +11:00
Andrew Tridgell
4e56196655 AP_NavEKF: allow states to be accessed using names as well as a Vector22 2014-02-21 20:24:47 +11:00
Andrew Tridgell
009913ec60 AP_Math: make is_nan const for quaternion and add .zero() for vector2 2014-02-21 20:24:47 +11:00
Randy Mackay
33fe778cdd InertialSensor_PX4: resolve compiler warning 2014-02-21 13:53:34 +09:00
Randy Mackay
98bdbb7fed AC_WPNav: set loiter accel to 1/2 of speed
Bug fix from Leonard.
Also fixed some formatting.
2014-02-20 21:37:45 +09:00
Andrew Tridgell
f222f2ef1e DataFlash: fixed logging on PX4v1
large writes break IO, a NuttX bug
2014-02-20 06:55:35 +11:00
Andrew Tridgell
20b0444c15 AP_NavEKF: remove sleep on init of EKF
this prevents HIL from locking up, and also prevents a possible 1s
delay in flight on EKF init
2014-02-19 22:04:12 +11:00
Andrew Tridgell
b434c11215 AP_AHRS: removed empty file 2014-02-19 22:00:25 +11:00
Randy Mackay
aa5ea23245 GCS_MAVLink: regenerate for COMPASSMOT_STATUS msg 2014-02-19 16:04:08 +11:00
Randy Mackay
a7c25ec649 GCS_MALink: improved generate.sh failure msg 2014-02-19 16:04:05 +11:00
Andrew Tridgell
50cbc661ef GCS_MAVLink: added new COMPASSMOT_STATUS message 2014-02-19 16:03:57 +11:00
Andrew Tridgell
c9d0c1face AP_NavEKF: use ahrs->get_armed() for static mode demanded 2014-02-19 10:52:57 +11:00
Andrew Tridgell
3b1f9a4bbf AP_AHRS: added get_armed() and set_armed() calls
will be used by NavEKF to determine static mode
2014-02-19 10:52:24 +11:00
Andrew Tridgell
fe0cb23733 AP_InertialSensor: fixed HIL for 400Hz INS 2014-02-19 10:29:00 +11:00
Andrew Tridgell
536160a3fb AP_NavEKF: use AHRS get_correct_centrifugal() 2014-02-19 10:28:45 +11:00
Andrew Tridgell
fad0b2b233 AP_AHRS: added get_correct_centrifugal()
used by NavEKF to force static mode
2014-02-19 10:28:14 +11:00
Andrew Tridgell
599c3a8abf AP_Math: added more operators to VectorN 2014-02-19 10:14:58 +11:00
Andrew Tridgell
869e41fd03 AP_NavEKF: fixed detection of airspeed sensor
the get_airspeed() AHRS call can change as the user enables/disables
the airspeed sensor, plus it only gets enabled after the NavEKF
constructor runs.
2014-02-19 09:22:45 +11:00
Paul Riseborough
1ade39977a AP_NavEKF : covariance prediction cleanup 2014-02-19 09:22:45 +11:00
Paul Riseborough
8daca145d0 AP_NavEKF : useAirspeed set automatically 2014-02-19 09:22:45 +11:00
Paul Riseborough
6fbada26d3 AP_NavEKF : Improvements to staticMode robustness 2014-02-19 09:22:45 +11:00
Mike McCauley
bd768a0c0c AP_HAL_FLYMAPLE RCOutput.cpp: enable_ch no longer resets servo
FLYMAPLERCOutput::enable_ch incorrectly reset the servo to 0, which caused
servo twitching once per second when RC_Channel_aux::enable_aux_servos
enabled each channel.
2014-02-18 09:25:08 +11:00
Andrew Tridgell
ad4db4de6c AP_Airspeed: added setHIL() method
useful for log playback
2014-02-18 09:25:08 +11:00
Andrew Tridgell
e11ada7bf0 RC_Channel: fixed comment on enable_aux_servos()
thanks to Mike McCauley for spotting
2014-02-18 09:25:07 +11:00
Andrew Tridgell
b2bd81f262 AP_Baro: added alternative setHIL interface
uses pressure and temperature for better log replay
2014-02-18 09:25:07 +11:00
Andrew Tridgell
5bf170c440 AP_NavEKF: fixed log replay code
also added BARO and ARSP messages
2014-02-18 09:25:07 +11:00
jschall
024855014f AC_PosControl: update _pos_error if it is being limited
This fixes a bug that causes 10hz throttle noise.
2014-02-17 22:33:06 +09:00
Andrew Tridgell
9cf70fe3f7 AP_HAL: another broken example build
this one an internal compiler error
2014-02-17 12:42:13 +11:00
Mike McCauley
4f9f87a8c6 AP_HAL_FLYMAPLE: Add notes to FlymaplePortingNotes.txt re GPS selection. 2014-02-17 05:56:37 +11:00
Mike McCauley
54a0b04c12 AP_HAL_FLYMAPLE: RCInput detects stale input readings better. Update test
code.
2014-02-17 05:56:37 +11:00
Mike McCauley
f1533aa350 AP_HAL_FLYAPLE: update documentation in FlymaplePortingNotes.txt 2014-02-17 05:56:37 +11:00
Mike McCauley
81791bdc43 AP_HAL_FLYMAPLE: Added documentation about alternative orientations to FlymaplePortingNotes.txt 2014-02-17 05:56:37 +11:00
Mike McCauley
95bea052d2 AP_HAL_FLYMAPLE: update documentation in FlymaplePortingNotes.txt 2014-02-17 05:56:37 +11:00
Mike McCauley
2c94a40310 AP_InertialSensor: AP_InertialSensor_Flymaple Remove unnecessary
comment
2014-02-17 05:56:37 +11:00
Mike McCauley
dd6abb49a9 AP_InertialSensor: AP_InertialSensor_Flymaple::healthy() was required after
all.
2014-02-17 05:56:37 +11:00
Mike McCauley
0a43cf8c5c AP_InertialSensor: AP_InertialSensor_Flymaple removed redundant definition of
healthy().
2014-02-17 05:56:37 +11:00
Mike McCauley
f7279aa13f AP_InertialSensor: AP_InertialSensor_Flymaple implement get_gyro_health
and get_accel_health.
2014-02-17 05:56:37 +11:00
Mike McCauley
4dc33c8de8 AP_HAL_FLYMAPLE: updated FlymaplePortingNotes.txt 2014-02-17 05:56:37 +11:00
Randy Mackay
d277b6cabd AC_AttControl: fix @Units parameter descriptions 2014-02-16 22:36:59 +09:00
Paul Riseborough
7a82746fcc AP_NavEKF : fixed bug in pos and vel reset when in static mode 2014-02-16 22:35:19 +11:00
Paul Riseborough
275ef86f86 AP_NavEKF : Position and Velocity reset bugfix 2014-02-16 21:05:37 +11:00
Paul Riseborough
b22dc706b2 AP_NavEKF : staticMode bugfix and robustness improvements 2014-02-16 21:04:55 +11:00
Paul Riseborough
2926602718 AP_NavEKF : Cleaned up InitialiseFilterDynamic 2014-02-16 21:04:51 +11:00
Paul Riseborough
404fbafe26 AP_NavEKF : Changed timout behaviour to only reset PosVel states 2014-02-16 21:04:46 +11:00
Andrew Tridgell
856dfd0ee6 AC_AttitudeControl: fixed example build 2014-02-16 18:43:15 +11:00
Andrew Tridgell
ee37bc3d27 AP_AHRS: ensure we have HAL_CPU_CLASS available 2014-02-16 17:57:09 +11:00
Randy Mackay
6af705d455 AC_Circle: bug fix for pos target when radius is zero 2014-02-16 13:46:38 +11:00
Randy Mackay
9130c88f15 AC_PosControl: throttle rate to simple P controller 2014-02-16 13:35:44 +11:00
Randy Mackay
a021d0ca31 AHRS: fix compiler warning 2014-02-16 13:35:37 +11:00
Randy Mackay
34b62fc078 AC_AttControlHeli: add ACCEL_RP_MAX, ACCEL_Y_MAX 2014-02-16 13:35:26 +11:00
lthall
b8d9bdb794 AC_AttControl: accel limit for roll, pitch yaw rates 2014-02-16 13:35:23 +11:00
Andrew Tridgell
189d635493 AP_Compass: constrain compass offsets to +/- 2000
this is prompted by a user log showing NaN compass offsets, resulting
in a crash. The patch ensures we never end up with NaN offsets, and
also constrains the offsets to a reasonable limit
2014-02-16 13:33:41 +11:00
Andrew Tridgell
6618bdae67 DataFlash: periodically use lseek to avoid NuttX seek bug 2014-02-16 13:21:35 +11:00
Andrew Tridgell
9bb8f73d56 Compass: split compass learning out to its own C++ file 2014-02-16 13:21:06 +11:00
Andrew Tridgell
24e1070eb2 AP_NavEKF: initialise quaternion from rotation matrix 2014-02-15 12:21:11 +11:00
Andrew Tridgell
2df314799e AP_Math: added tests for quaternion to/from rotation matrix 2014-02-15 12:20:51 +11:00
Andrew Tridgell
689f230d40 AP_Math: added quaternion.from_rotation_matrix() 2014-02-15 12:20:31 +11:00
Andrew Tridgell
c6b24c521b AP_NavEKF: force healthy false when initialising
this prevents us feeding off our own values when booting

Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-02-15 09:25:40 +11:00
Andrew Tridgell
be33a9634e AP_AHRS: move using_EKF to .cpp to make it easier in gdb 2014-02-15 09:25:40 +11:00
Andrew Tridgell
eedd88c2ec AP_AHRS: give zero lat/lng and baro alt if no position yet in DCM 2014-02-15 09:25:40 +11:00
Andrew Tridgell
4d3f714a5d AP_Notify: fixed example build 2014-02-15 06:40:39 +11:00
Andrew Tridgell
830afefcef AP_HAL: fixed example build 2014-02-15 06:40:29 +11:00
Andrew Tridgell
3af38a778d AP_Baro: fixed example build 2014-02-15 06:40:15 +11:00
Andrew Tridgell
8201f9c928 AP_NavEKF: don't build example 2014-02-15 06:40:06 +11:00
Andrew Tridgell
c1dff6aa65 AP_Math: fixed example build 2014-02-15 06:39:43 +11:00
Andrew Tridgell
f9d0747750 AP_InertialSensor: fixed example build 2014-02-15 06:39:35 +11:00
Randy Mackay
5bdc564191 AP_AHRS: fix example sketch 2014-02-15 06:09:08 +11:00
Randy Mackay
c18b3f6094 AP_Airspeed: fix example sketch 2014-02-15 06:09:08 +11:00
Randy Mackay
bb715424ee Baro: fix BMP085 example sketch 2014-02-15 06:09:08 +11:00
Randy Mackay
d761ddd4af AP_Motors: fix example sketch 2014-02-15 06:09:08 +11:00
Randy Mackay
ae59bef6d1 AC_INav: fix example sketch 2014-02-15 06:09:08 +11:00
Randy Mackay
42d9225fbe HAL_AVR: ArduCopterLibs to use AC_P library 2014-02-15 06:09:08 +11:00
Randy Mackay
bf3effcd10 AC_WPNav: fix example sketch 2014-02-15 06:09:08 +11:00
Randy Mackay
889ee1bfef AC_Sprayer: fix example sketch 2014-02-15 06:09:08 +11:00
Randy Mackay
4484a4232a AC_Fence: fix example sketch 2014-02-15 06:09:08 +11:00
Randy Mackay
c35bd84e21 AC_AttControl: fix example sketch 2014-02-15 06:09:08 +11:00
Randy Mackay
451910fc94 AC_AttControlHeli: replace APM_PI with AC_P 2014-02-15 06:09:08 +11:00
Randy Mackay
ff9f4fe6e7 AC_AttControl: replace APM_PI with AC_P 2014-02-15 06:09:08 +11:00
Randy Mackay
94fb9c4274 AC_PosControl: replace APM_PI with AC_P 2014-02-15 06:09:08 +11:00
Randy Mackay
fbf8106280 AC_Circle: remove AC_PID include
This is no longer required with introduction of PosControl lib
2014-02-15 06:09:08 +11:00
Randy Mackay
e86a21a254 AC_WPNav: remove AC_PID include
This is no longer required with introduction of PosControl lib
2014-02-15 06:09:08 +11:00
Randy Mackay
8fae75ee87 AC_PID: add AC_P controller
Used for stabilize angle controllers, alt hold and loiter
2014-02-15 06:09:08 +11:00
Randy Mackay
fbc5af2705 AC_PID: results returned as float 2014-02-15 06:09:08 +11:00
Randy Mackay
a6ad51b38f AC_AttControl: rename most methods 2014-02-15 06:09:08 +11:00
lthall
65c2fc0cc6 AC_AttControl: ACRO fixes 2014-02-15 06:09:08 +11:00
Andrew Tridgell
0bbe038587 GCS_MAVLink: re-generate MAVLink headers 2014-02-15 05:48:24 +11:00
Andrew Tridgell
801ceacaf2 AP_AHRS: re-run update_trig() after EKF AHRS update 2014-02-15 05:48:24 +11:00
Andrew Tridgell
a88212eb7a AP_InertialNav: fixed EKF version for new AHRS API 2014-02-15 05:48:24 +11:00
Andrew Tridgell
a7a44a9a5c AP_NavEKF: fixed init order warning 2014-02-15 05:48:24 +11:00
Andrew Tridgell
9b8311580b AP_TECS: update for AHRS API change 2014-02-15 05:48:24 +11:00
Andrew Tridgell
25ef0d5a7b AP_AHRS: don't allow get_velocity_NED() and get_relative_position_NED() without EKF
this avoids some linking issues, plus the functions are inaccurate
without EKF
2014-02-15 05:48:24 +11:00
Andrew Tridgell
6964529124 AP_Baro: _calculate can be private 2014-02-15 05:48:24 +11:00
Andrew Tridgell
c62ccce9d8 AP_AHRS: make estimate_wind() public
this avoids it linking into copter
2014-02-15 05:48:24 +11:00
Paul Riseborough
b56c8211c9 AP_NavEKF: Reduced number of Mavlink tuneable parameters 2014-02-15 05:48:23 +11:00
Paul Riseborough
c20fac1269 AP_NavEKF: Updated comments for private functions 2014-02-15 05:48:23 +11:00
Paul Riseborough
deb64c4cbd AP_NavEKF: Pos Vel reset after long GPS timeout 2014-02-15 05:48:23 +11:00
Paul Riseborough
7ac0172db1 AP_NavEKF: removed repeated intialisation 2014-02-15 05:48:23 +11:00
Paul Riseborough
28fb5e364b AP_NavEKF: Fixed bug in pos/vel/hgt reset on timout 2014-02-15 05:48:23 +11:00
Paul Riseborough
f74cce8b4e AP_NavEKF : Removed double to float conversions 2014-02-15 05:48:23 +11:00
Paul Riseborough
80f6dba694 AP_NavEKF: Improved control of fusion update intervals 2014-02-15 05:48:23 +11:00
Paul Riseborough
13b9daeff5 AP_NavEKF: Added constraints to Mavlink tuneable parameters 2014-02-15 05:48:23 +11:00
Paul Riseborough
b123e1bb16 AP_NavEKF: Improved in-air reset behaviour 2014-02-15 05:48:22 +11:00
Paul Riseborough
1651980b9f AP_NavEKF: Improved behaviour following loss and regaining of GPS 2014-02-15 05:48:22 +11:00
Paul Riseborough
14eb63e7c9 AP_NavEKF: Made most tuning parameters Mavlink adustable 2014-02-15 05:48:22 +11:00
Andrew Tridgell
f800f5592d AP_NavEKF: fixup parameter handling 2014-02-15 05:48:22 +11:00
Andrew Tridgell
f09ae0c2d0 AP_AHRS: expose get_NavEKF as non-const
better than having two methods
2014-02-15 05:48:22 +11:00
Paul Riseborough
f0f76920fa AP_NavEKF : Mavlink tunable parameter - first attempt 2014-02-15 05:48:22 +11:00
Paul Riseborough
128f71157d AP_NavEKF: Fixed bug in pre GPS fix updates 2014-02-15 05:48:22 +11:00
Paul Riseborough
08267cea87 AP_AHRS: Scheduling for yaw gain to reduce atitude errors in turning flight 2014-02-15 05:48:22 +11:00
Paul Riseborough
357743ee2d AP_NavEKF: Adjusted tuning parameters for plane use 2014-02-15 05:48:22 +11:00
Paul Riseborough
b4171853b1 AP_NavEKF: allow initialisation before GPS lock to aid indoor testing 2014-02-15 05:48:21 +11:00
Paul Riseborough
7fb60812c2 AP_NavEKF: Added pitch and roll inertial sensor to body trim adjustment 2014-02-15 05:48:21 +11:00
Paul Riseborough
9d375da550 AP_NavEKF: changed sqrt to sqrtf 2014-02-15 05:48:21 +11:00
Paul Riseborough
1f0b4b02d0 AP_NavEKF: fixed merge error that inverted static mode 2014-02-15 05:48:21 +11:00
Paul Riseborough
17e24521e8 DataFlash : Added logging of NavEKF innovations and variances 2014-02-15 05:48:21 +11:00
Paul Riseborough
9bbddb2f66 AP_TECS : Use NavEKF height and height rate data if available 2014-02-15 05:48:21 +11:00
Paul Riseborough
0599817aa9 AP_AHRS : EKF initialisation changed to use bootstrap method 2014-02-15 05:48:21 +11:00
Paul Riseborough
401e3aee43 AP_NavEKF : Changes to test harness to support accel bias states 2014-02-15 05:48:21 +11:00
Paul Riseborough
5219869389 AP_NavEKF : Added Z accel bias state and bootstrap initialisation method 2014-02-15 05:48:21 +11:00
Randy Mackay
301a04b74a AP_NavEKF: update params for copter 2014-02-15 05:48:21 +11:00
Randy Mackay
f068d0ff7e AP_AHRS_NavEKF: expose non-const EKF for tuning 2014-02-15 05:48:20 +11:00
Randy Mackay
7c73020015 AP_NavEKF: make params public so they can be tuned 2014-02-15 05:48:20 +11:00
Randy Mackay
9f130b40a0 AP_AHRS_NavEKF: override set_correct_centrifugal 2014-02-15 05:48:20 +11:00
Randy Mackay
8f6fd86f69 AP_AHRS: make set_correct_centrifugal virtual 2014-02-15 05:48:20 +11:00
Paul Riseborough
a87df0ad56 AP_AHRS : set NavEKF staticMode using call to set_correct_centrigual 2014-02-15 05:48:20 +11:00
Paul Riseborough
5c3dea28dc AP_NavEKF : Enable staticMode to be set externally 2014-02-15 05:48:20 +11:00
Andrew Tridgell
3617c65af7 AP_InertialSensor: make HIL treat time like PX4 does 2014-02-15 05:48:20 +11:00
Andrew Tridgell
77c4968342 AP_NavEKF: enable plotting in plot2.dat too 2014-02-15 05:48:20 +11:00
Andrew Tridgell
ab2a5a0672 AP_NavEKF: enable some debug 2014-02-15 05:48:20 +11:00
Paul Riseborough
0d4d287215 AP_NavEKF: comment and parameter tweaks for ground testing 2014-02-15 05:48:20 +11:00
Paul Riseborough
b6b0c2a489 AP_NavEKF: fixed bug in flag reset for hgt fusion 2014-02-15 05:48:19 +11:00
Paul Riseborough
2f3b2a7111 AP_NavEKF: second attempt at higher rate baro fusion 2014-02-15 05:48:19 +11:00
Paul Riseborough
cdbc5a3f35 AP_NavEKF: added position observations to static mode 2014-02-15 05:48:19 +11:00
Paul Riseborough
da2c341914 Revert "AP_NavEKF: Modifed Vel Pos fusion to fuse height data whenever baro reading has changed"
This reverts commit d1e1be192a0e7ab0771edc9f2c03547da25697cf.
2014-02-15 05:48:19 +11:00
Paul Riseborough
32cc427ff4 AP_NavEKF: Modifed Vel Pos fusion to fuse height data whenever baro reading has changed 2014-02-15 05:48:19 +11:00
Paul Riseborough
2998aa1a6a AP_NavEKF: Amended tuning parameter list, and changed from variance to noise definitions 2014-02-15 05:48:19 +11:00
Paul Riseborough
f9aae1b90b AP_NavEKF: fixed bug in variance constraint code 2014-02-15 05:48:19 +11:00
Paul Riseborough
735c9684da AP_NavEKF: removed error in constructor comments 2014-02-15 05:48:19 +11:00
Paul Riseborough
8f999fe787 AP_NavEKF: Misc tuning adjustments for Plane testing 2014-02-15 05:48:19 +11:00
Paul Riseborough
c87a5aaf34 AP_NavEKF: added PositionReset public function to fix pre-arm loss of solution 2014-02-15 05:48:19 +11:00
Paul Riseborough
fec4fd463c AP_NavEKF: reduced On Ground yaw gyro bias drift variance scaler 2014-02-15 05:48:19 +11:00
Paul Riseborough
619fffec3e AP_NavEKF: added static mode for pre-arm and bench testing 2014-02-15 05:48:18 +11:00
Paul Riseborough
ab08a5c7d6 AP_AHRS : altered NavEKF set home to reset position instead of reset filter 2014-02-15 05:48:18 +11:00
Paul Riseborough
d0831c708d AP_NavEKF : Added position and height reset public method 2014-02-15 05:48:18 +11:00
Andrew Tridgell
1b1f9e41ab AP_NavEKF: improved playback initialisation 2014-02-15 05:48:18 +11:00
Andrew Tridgell
d9ef45234b AP_NavEKF: useful plotting function 2014-02-15 05:48:18 +11:00
Andrew Tridgell
0816642436 AP_NavEKF: handle intertial nav 2014-02-15 05:48:18 +11:00
Andrew Tridgell
77c6e3206a AP_NavEKF: some debug code 2014-02-15 05:48:18 +11:00
Andrew Tridgell
2cd781997f AP_Baro: changed HIL driver to use floats and better handle starup 2014-02-15 05:48:18 +11:00
Andrew Tridgell
c995f994c5 AP_InertialNav: make some functions protected 2014-02-15 05:48:18 +11:00
Andrew Tridgell
c33da7b3a2 AP_NavEKF: fixed log playback for copter 2014-02-15 05:48:18 +11:00
Andrew Tridgell
78ff078988 HAL_Linux: fixed stopped clock delay 2014-02-15 05:48:18 +11:00
Andrew Tridgell
9b53db66cb AP_NavEKF: tweak parameters based on randys copter log 2014-02-15 05:48:18 +11:00
Andrew Tridgell
9e3bf685c2 SITL: use sinf() and cosf()
for some strange reason the double precision functions can crash
2014-02-15 05:48:17 +11:00
Andrew Tridgell
bb0eed5c14 SITL: prevent initialisation error 2014-02-15 05:48:17 +11:00
Andrew Tridgell
574946f0aa AP_AHRS: start EKF 5 seconds after getting GPS lock 2014-02-15 05:48:17 +11:00
Andrew Tridgell
df271fbd59 AP_AHRS: fill in _dcm_matrix whenever EKF started
this ensures get_dcm_matrix() always returns valid data
2014-02-15 05:48:17 +11:00
Andrew Tridgell
4c42f53636 AP_NavEKF: use INS delta_time 2014-02-15 05:48:17 +11:00
Andrew Tridgell
5193ce90dc AP_NavEKF: copter specific dtIMUAvg 2014-02-15 05:48:17 +11:00
Andrew Tridgell
ada7d4fb98 AP_AHRS: use the right DCM matrix when EKF not enabled 2014-02-15 05:48:17 +11:00
Andrew Tridgell
a74fcc5a93 AP_AHRS: added set_ekf_use() 2014-02-15 05:48:17 +11:00
Andrew Tridgell
38ac8d404a SITL: fixed PX4 build 2014-02-15 05:48:17 +11:00
Andrew Tridgell
fba0891617 SITL: fixed SIM df altitude 2014-02-15 05:48:17 +11:00
Paul Riseborough
8b1d056e07 AP_NavEKF: updated timeout for GPS retry and reduced onGround gyro bias noise multiplier 2014-02-15 05:48:16 +11:00
Paul Riseborough
7e026d41df AP_NavEKF: explicitly zeroed covariance matrix priro to setting initial values 2014-02-15 05:48:16 +11:00
Paul Riseborough
6e6e3d923e AP_NavEKF: improved covariance matrix numerical stability protection 2014-02-15 05:48:16 +11:00
Andrew Tridgell
45177df354 DataFlash: moved EKF logging to common code 2014-02-15 05:48:16 +11:00
Andrew Tridgell
9aea781248 GCS_MAVLink: moved send_ahrs2 to common code 2014-02-15 05:48:16 +11:00
Andrew Tridgell
66dbaa6657 AP_NavEKF: make health() API const 2014-02-15 05:48:16 +11:00
Andrew Tridgell
47f541e143 AP_InertialNav: implement InertialNav in terms of AHRS when available 2014-02-15 05:48:16 +11:00
Andrew Tridgell
5d43a1d704 AP_AHRS: added inertial nav interfaces to AHRS 2014-02-15 05:48:16 +11:00
Andrew Tridgell
658110dd8c AP_InertialNav: added AP_InertialNav_NavEKF wrapper class 2014-02-15 05:48:15 +11:00
Andrew Tridgell
99097d80a1 AP_InertialNav: use AHRS home location 2014-02-15 05:48:15 +11:00
Andrew Tridgell
c493d980d8 AP_NavEKF: fixed check for airspeed sensor available 2014-02-15 05:48:15 +11:00
Andrew Tridgell
2dbfed19b8 AP_NavEKF: fixed airspeed estimate check 2014-02-15 05:48:15 +11:00
Paul Riseborough
e69eea3086 AP_NavEKF: Bug fix in covariance error correction 2014-02-15 05:48:15 +11:00
Paul Riseborough
43dc9bc055 AP_NavEKF: Added improved covariance matrix error fix 2014-02-15 05:48:15 +11:00
Paul Riseborough
4a56ea84b5 AP_NavEKF: Removed accel bias states 2014-02-15 05:48:15 +11:00
Andrew Tridgell
093481786e AP_NavEKF: added SIM state to playback tool 2014-02-15 05:48:15 +11:00
Andrew Tridgell
fcd9041e62 SITL: added dataflash logging 2014-02-15 05:48:14 +11:00
Andrew Tridgell
d0a25b53f2 DataFlash: added logging of AHRS2 2014-02-15 05:48:09 +11:00
Andrew Tridgell
5578552574 AP_NavEKF: fixed example for new API 2014-02-15 05:29:48 +11:00
Andrew Tridgell
2acf1e7ce5 AP_NavEKF: allow filter to run as single or double precision
useful for checking if there are numerical precision issues
2014-02-15 05:29:48 +11:00
Paul Riseborough
efd444b02e AP_NavEKF: covariance protection (not enabled) and tuning changes for stability 2014-02-15 05:29:48 +11:00
Paul Riseborough
be9f276f45 AP_NavEKF: fixed compass offset sign error 2014-02-15 05:29:48 +11:00
Andrew Tridgell
ee774f69d0 AP_NavEKF: fixed some time handling bugs
use get_delta_time() and removed broken time wrap code
2014-02-15 05:29:48 +11:00
Andrew Tridgell
b1c5f23bbd AP_InertialSensor: make get_delta_time() const
allows use from AP_NavEKF
2014-02-15 05:29:47 +11:00
Andrew Tridgell
95c5aeaa43 AP_NavEKF: removed more unused variables 2014-02-15 05:29:47 +11:00
Andrew Tridgell
a53fc0636a AP_NavEKF: zero more variables on filter re-init 2014-02-15 05:29:47 +11:00
Andrew Tridgell
392995ef84 AP_AHRS: make AHRS handle altitude
AHRS now holds the home position
2014-02-15 05:29:47 +11:00
Andrew Tridgell
b9128a932f AP_L1_Control: no need to project position for lag
now handled by AHRS
2014-02-15 05:29:47 +11:00
Andrew Tridgell
91cbad52a1 AP_NavEKF: handle conversion of AHRS to handle altitude
fixed accuracy of position for cm level lat/lng
2014-02-15 05:29:47 +11:00
Andrew Tridgell
1e476e511a AP_AHRS: pass baro into AP_AHRS
first step in making AHRS handle altitude
2014-02-15 05:29:47 +11:00
Andrew Tridgell
6e5077b60b AP_AHRS: removed unused AP_AHRS_HIL 2014-02-15 05:29:46 +11:00
Andrew Tridgell
84c7b0d7fd AP_AHRS: check for NavEKF health 2014-02-15 05:29:46 +11:00
Andrew Tridgell
9ef71a9dec AP_NavEKF: added healthy() API 2014-02-15 05:29:46 +11:00
Andrew Tridgell
cfc612b251 AP_InertialNav: use references to AHRS and baro 2014-02-15 05:29:45 +11:00
Andrew Tridgell
18aa08d5c3 GCS_MAVLink: added AHRS2 mavlink msg 2014-02-15 05:29:45 +11:00
Andrew Tridgell
154eb76f4f GCS_MAVLink: new MAVLink headers 2014-02-15 05:29:45 +11:00
Andrew Tridgell
bfd48a95b7 AP_NavEKF: fixed example build 2014-02-15 05:29:45 +11:00
Andrew Tridgell
b39a5062e9 AP_AHRS: use NavEKF for ground vector when available 2014-02-15 05:29:45 +11:00
Andrew Tridgell
b6bc50051f AP_AHRS: allow reporting of secondary AHRS solution 2014-02-15 05:29:45 +11:00
Andrew Tridgell
ea0f9392ef AP_NavEKF: don't report altitude yet, and removed debug code 2014-02-15 05:29:45 +11:00
Andrew Tridgell
a1aebc0c15 GCS_MAVLink: update from upstream 2014-02-15 05:29:23 +11:00
Andrew Tridgell
0e10554dc0 GCS_MAVLink: rename EKF message to AHRS2 2014-02-15 05:28:10 +11:00
Andrew Tridgell
33673c954d AP_NavEKF: implemented getRotationBodyToNED() 2014-02-15 05:28:10 +11:00
Andrew Tridgell
8c5cde4efd AP_AHRS: allow NavEKF to be enabled at runtime with AHRS_EKF_USE=1 2014-02-15 05:28:10 +11:00
Andrew Tridgell
7ac78ff991 AP_AHRS: create AP_AHRS_NavEKF class
subclass of AP_AHRS_DCM, just a wrapper for now, will add EKF calls
next
2014-02-15 05:28:09 +11:00
Andrew Tridgell
2c86a490ed AP_NavEKF: make it possible for NavEKF to be a AHRS member
ready for AHRS integration
2014-02-15 05:28:09 +11:00
Paul Riseborough
6f31961fb5 AP_NavEKF: Added height rate adaptive wind speed process noise 2014-02-15 05:28:09 +11:00
Paul Riseborough
de884dabab AP_NavEKF: brought some tuning parameters out to header 2014-02-15 05:28:09 +11:00
Paul Riseborough
3ee5ef852b AP_NavEKF : improved On Ground check 2014-02-15 05:28:09 +11:00
Paul Riseborough
8bc14d09b2 AP_NavEKF : remove onGround airspeed detect bug 2014-02-15 05:28:09 +11:00
Paul Riseborough
a507fa7570 AP_NavEKF : remove debug code 2014-02-15 05:28:09 +11:00
Paul Riseborough
2f95685bfc Plane : EKF data logging fixes 2014-02-15 05:28:09 +11:00
Paul Riseborough
6b9733c013 AP_NavEKF : Additional flash logging 2014-02-15 05:28:09 +11:00
Paul Riseborough
c28e89e4b7 AP_NavEKF: bug fixes for height fusion and covariance initialisation 2014-02-15 05:28:08 +11:00
Paul Riseborough
aed6c79135 AP_NavEKF: Added gyro bias variance scale for on-ground 2014-02-15 05:28:08 +11:00
Paul Riseborough
cb42e1e490 AP_NavEKF: Added public function to get NED position 2014-02-15 05:28:08 +11:00
Paul Riseborough
2c567cd721 AP_NavEKF: Added tuning parameter for onGround yaw gyro variance 2014-02-15 05:28:08 +11:00
Paul Riseborough
9515f6c745 AP_NavEKF: Cleaned up on-ground state and covariance update logic 2014-02-15 05:28:08 +11:00
Andrew Tridgell
9c5647eef3 AP_NavEKF: stop log for gdb friendly playback 2014-02-15 05:28:08 +11:00
Andrew Tridgell
117b77460e HAL_Linux: added stop_clock hack! 2014-02-15 05:28:08 +11:00
Andrew Tridgell
4adf6000f3 AP_NavEKF: only build on fast CPUs 2014-02-15 05:28:08 +11:00
Paul Riseborough
1647ba9bd0 AP_NavEKF: Reduced heading drift on ground 2014-02-15 05:28:08 +11:00
Paul Riseborough
63d8b1bb0b AP_NavEKF: Scheduler Improvements 2014-02-15 05:28:07 +11:00
Andrew Tridgell
df42dd691c AP_NavEKF: added perf counters on PX4 2014-02-15 05:28:07 +11:00
Andrew Tridgell
3d6cb9eade AP_NavEKF: use float arrays when not doing bounds checking
g++ is doing a lousy job of inlining VectorN, so avoid it when we
don't need bounds checking for production code
2014-02-15 05:28:07 +11:00
Andrew Tridgell
c7533579ac AP_AHRS: added get_airspeed() interface to AHRS 2014-02-15 05:28:07 +11:00
Andrew Tridgell
010250a966 AP_NavEKF: use quaternion normalize and cleanup sqrt calls 2014-02-15 05:28:07 +11:00
Paul Riseborough
406fb31a57 AP_NavEKF: Load levelling scheduler - first attempt 2014-02-15 05:28:07 +11:00
Andrew Tridgell
68283b7aa1 GCS_MAVLink: new ekf header 2014-02-15 05:28:07 +11:00
Andrew Tridgell
163cfd839d AP_NavEKF: enable airspeed and fix getLLH() 2014-02-15 05:28:07 +11:00
Andrew Tridgell
b4153c4d32 GCS_MAVLink: added EKF message for debugging 2014-02-15 05:27:54 +11:00
Andrew Tridgell
4771a4fc77 AP_NavEKF: use radians values from AHRS directly 2014-02-15 05:27:53 +11:00
Paul Riseborough
6b798d2821 AP_NavEKF: first working GPS + Mag fusion 2014-02-15 05:27:53 +11:00
Paul Riseborough
bccadb6e25 AP_NavEKF: first working GPS fusion 2014-02-15 05:27:53 +11:00
Andrew Tridgell
90cd04def3 AP_NavEKF: fixed build for non-Linux 2014-02-15 05:27:53 +11:00
Andrew Tridgell
0b71618f4f AP_NavEKF: use vectorN to make indexes safe 2014-02-15 05:27:53 +11:00
Andrew Tridgell
e972acbc9f AP_NavEKF: removed delay callback 2014-02-15 05:27:53 +11:00
Andrew Tridgell
8f16647a0c AP_NavEKF: added write_flot valgrind functions 2014-02-15 05:27:53 +11:00
Andrew Tridgell
a8ddd51355 AP_NavEKF: added pause to gnuplot scripts 2014-02-15 05:27:53 +11:00
Andrew Tridgell
4298625daf AP_NavEKF: added convenient plotting scripts 2014-02-15 05:27:53 +11:00
Paul Riseborough
fca1090694 AP_NavEKF: debug updates 2014-02-15 05:27:53 +11:00
Andrew Tridgell
95f51123d7 AP_NavEKF: added plot.dat output 2014-02-15 05:27:53 +11:00
Andrew Tridgell
050b0fb9f1 AP_NavEKF: fixed compass declination, baro cal and time shift
now runs much faster
2014-02-15 05:27:53 +11:00
Andrew Tridgell
776cedf368 AP_NavEKF: try running EKF on log data 2014-02-15 05:27:52 +11:00
Andrew Tridgell
ffce1f64cc AP_NavEKF: added euler angle functions 2014-02-15 05:27:52 +11:00
Andrew Tridgell
977ad4bbf6 AP_NavEKF: added dataflash log reader
this gives log playback into HIL
2014-02-15 05:27:52 +11:00
Andrew Tridgell
f3dfde2025 AP_NavEKF: initial test sketch for NavEKF 2014-02-15 05:27:52 +11:00
Paul Riseborough
361bb5b18f AP_NavEKF: Updated comments in header file 2014-02-15 05:27:52 +11:00
Paul Riseborough
00df068967 AP_NavEKF: Explicitly defined numerical constants as single precision using f suffix 2014-02-15 05:27:52 +11:00
Andrew Tridgell
eb505eef91 AP_NavEKF: fixed build for APM environment 2014-02-15 05:27:52 +11:00
Paul Riseborough
0dd5463e77 AP_NavEKF : Changed file and variable names 2014-02-15 05:27:52 +11:00
Paul Riseborough
1e993d2ef5 AP_NavEKF: Added constructor for measurements 2014-02-15 05:27:52 +11:00
Paul Riseborough
4a7f81e50a AP_NavEKF: Corrected height update timeout error 2014-02-15 05:27:51 +11:00
Paul Riseborough
0f3ebb8e31 AP_NavEKF: Updated measurement fusion control 2014-02-15 05:27:51 +11:00
Paul Riseborough
c557bd7df5 AP_NavEKF: Updated GPS input processing 2014-02-15 05:27:51 +11:00
Paul Riseborough
1d4b040c67 AP_NavEKF: Inertial Navigation Code - 24 State EKF
initial version converted from matlab
2014-02-15 05:27:51 +11:00
Andrew Tridgell
03cc777991 AP_Airspeed: added last_update_ms() interface 2014-02-15 05:27:51 +11:00
Andrew Tridgell
e7cf07dfb7 DataFlash: added Columns column to FMT 2014-02-15 05:27:51 +11:00
Andrew Tridgell
1e0f3f5398 AP_Math: make to_euler() const 2014-02-15 05:27:51 +11:00
Andrew Tridgell
90c41981ac AP_Math: added quaternion normalization 2014-02-15 05:27:51 +11:00
Randy Mackay
9e31f0b985 AC_WPNav: use PosControl accessor
Saves 2bytes of RAM
2014-02-15 05:27:50 +11:00
Randy Mackay
78c12eaebf AC_PosControl: get_pos_xy_kP accessor method 2014-02-15 05:27:50 +11:00
Randy Mackay
8d6eb1eceb MotorsMatrix: motor_to_channel_map moved to progmem 2014-02-15 05:27:50 +11:00
Randy Mackay
134289af38 TradHeli: motor_to_channel_map moved to progmem 2014-02-15 05:27:50 +11:00
Randy Mackay
1bee56877c CoaxCopter: motor_to_channel_map moved to progmem 2014-02-15 05:27:50 +11:00
Randy Mackay
3fad8e3630 SingleCopter: motor_to_channel_map moved to progmem 2014-02-15 05:27:50 +11:00
Randy Mackay
0edf039155 AP_MotorsTri: motor_to_channel_map moved to progmem 2014-02-15 05:27:50 +11:00
Randy Mackay
96d433c63e AP_Motors: motor_to_channel_map moved to progmem 2014-02-15 05:27:50 +11:00
Randy Mackay
8baf5ebf4a AC_AttControlHeli: use motor accessors to set roll, pitch, yaw, thr 2014-02-15 05:27:49 +11:00
Randy Mackay
f216cffb77 AC_AttControl: use motor accessors to set roll, pitch, yaw, thr
Saves 8bytes of RAM
2014-02-15 05:27:49 +11:00
Randy Mackay
415e48de19 TriCopter: use refs for all RC_Channels 2014-02-15 05:27:49 +11:00
Randy Mackay
01d30271d8 SingleCopter: use refs for all RC_Channels 2014-02-15 05:27:49 +11:00
Randy Mackay
18d3907928 TradHeli: use refs for all RC_Channels 2014-02-15 05:27:49 +11:00
Randy Mackay
cf1d6854b9 AP_MotorsMatrix: use ref for roll, pitch, yaw, thr channels 2014-02-15 05:27:49 +11:00
Randy Mackay
2f4fe3e192 AP_Motors: accessors to set roll, pitch, yaw, throttle
This saves 16bytes of RAM and slightly reduces the dependence upon the
RC_Channel class as the interface.
2014-02-15 05:27:49 +11:00
Randy Mackay
98224db1e4 AC_AttControl: Leaonard's rate feedforward
Also saves 24bytes of RAM
2014-02-15 05:27:49 +11:00
Randy Mackay
2c6470f87b AP_MotorsMatrix: remove unused _num_motors
Saves 1 byte of RAM
2014-02-15 05:27:49 +11:00
Randy Mackay
32a0992985 MatrixMotors: motor_out array made local 2014-02-15 05:27:48 +11:00
Randy Mackay
2f3fc3a3ce Single: remove use of motor_out array
Also allow fins to move when throttle at zero
2014-02-15 05:27:48 +11:00
Randy Mackay
a036009524 AP_MotorsTri: motor_out array made local 2014-02-15 05:27:48 +11:00
Randy Mackay
83321b8786 AP_Motors: remove motor_out array
Saves 16bytes of RAM
2014-02-15 05:27:48 +11:00
Randy Mackay
5f89e9e746 AC_AttControl: bug fix to yaw rate limit 2014-02-15 05:27:48 +11:00
Randy Mackay
d76180d605 AC_AttControl: use trig values from ahrs 2014-02-15 05:27:48 +11:00
Randy Mackay
8b8d6a8e01 AC_PosControl: use trig values from ahrs 2014-02-15 05:27:48 +11:00
Randy Mackay
598a1b1f43 AC_Circle: use trig values from ahrs 2014-02-15 05:27:48 +11:00
Randy Mackay
64cfcb2308 AC_WPNav: use trig values from ahrs 2014-02-15 05:27:48 +11:00
Randy Mackay
082c5021ee AC_AttControlHeli: add comments 2014-02-15 05:27:47 +11:00
Randy Mackay
17177adccf AC_Circle: remove debug comment 2014-02-15 05:27:46 +11:00
Randy Mackay
37cfbc9ad5 AP_Math: float versions of wrap_360 and wrap_180 2014-02-15 05:27:45 +11:00
Randy Mackay
a7504faa7d TradHeli: empty angle_boost for trad heli 2014-02-15 05:27:44 +11:00
Randy Mackay
80ec61f217 TradHeli: make accessor methods const 2014-02-15 05:27:43 +11:00
Randy Mackay
48a0917670 Copter: make motors armed call const 2014-02-15 05:27:43 +11:00
Randy Mackay
eda376c7f6 AC_AttControl: init_targets() clears body frame angle errors
This should ensure that we don't get sudden jerks when entering acro
mode
2014-02-15 05:27:43 +11:00
Randy Mackay
2643ee9724 AC_AttControl_Heli: adjust for new slew_yaw param 2014-02-15 05:27:43 +11:00
Randy Mackay
2db24659d0 AC_AttControl: add slew_yaw 2014-02-15 05:27:42 +11:00
Randy Mackay
959f5ec3b2 AC_AttControl: tradheli add RATE_RP_MAX 2014-02-15 05:27:42 +11:00
Randy Mackay
2dae0d68c5 AC_AttControl: add RATE_RP_MAX, RATE_Y_MAX params
These replace the ANGLE_RATE_MAX parameter from the main code
2014-02-15 05:27:42 +11:00
Randy Mackay
c2efb91ece AC_AttControl: trad heli angle boost 2014-02-15 05:27:42 +11:00
Randy Mackay
ebbff24a04 AC_AttControl: trad heli yaw 2014-02-15 05:27:42 +11:00
Randy Mackay
4f738ffdba AC_AttControl: add trad heli support 2014-02-15 05:27:42 +11:00
Randy Mackay
551836c49d AC_PosControl: make some methods const 2014-02-15 05:27:40 +11:00
Randy Mackay
a2b017abd2 AC_AttControl: add rateef_rpy
rateef_rpy takes earth frame rates and applies them to the earth frame
angle targets and then converts them to body frame rates
2014-02-15 05:27:40 +11:00
Randy Mackay
468be05867 AC_AttControl: make ahrs, ins objects const 2014-02-15 05:27:40 +11:00
Randy Mackay
864f64b61a AC_Circle: circle control library 2014-02-15 05:27:40 +11:00
Randy Mackay
35ef9c73d1 AC_Sprayer: minor comment fix 2014-02-15 05:27:40 +11:00
Randy Mackay
4c02212404 AC_Fence: minor comment fix 2014-02-15 05:27:39 +11:00
Randy Mackay
d4e4620159 AC_WPNav: remove unused PID references 2014-02-15 05:27:39 +11:00
Randy Mackay
26b257c8ba AC_AttControl: alternative get_stopping_point_z 2014-02-15 05:27:39 +11:00
Randy Mackay
fc427967ae AC_WPNav: set wp origin to horiz and vert stopping point
Also bug fix to set pos_control's down speed as a negative number
2014-02-15 05:27:39 +11:00
Randy Mackay
1b8791a142 AC_PosControl: remove debug 2014-02-15 05:27:39 +11:00
Randy Mackay
4cd45e2edf AC_WPNav: remove debug 2014-02-15 05:27:38 +11:00
Randy Mackay
4003b4da9b AC_AttControl: leonard's body frame rate controller 2014-02-15 05:27:38 +11:00
Randy Mackay
171203370f AC_PosControl: add accessor for speed_up and down 2014-02-15 05:27:37 +11:00
Randy Mackay
1596d83d02 AC_WPNav: move leashes to AC_PosControl 2014-02-15 05:27:37 +11:00
Randy Mackay
de34359808 AC_PosControl: recalculate leash when speed or accel modified 2014-02-15 05:27:37 +11:00
Randy Mackay
ba3ba9e157 AC_AttControl: bug fix for yaw target handling 2014-02-15 05:27:37 +11:00
Randy Mackay
0d4ba04e75 AC_WPNav: make advance_wp_target private 2014-02-15 05:27:37 +11:00
Randy Mackay
80ae3dca2e AC_PosControl: remove debug 2014-02-15 05:27:36 +11:00
Randy Mackay
b9ae3ce2ff AC_PosControl: fixed example sketch 2014-02-15 05:27:36 +11:00
Randy Mackay
0c8cbba644 AC_WPNav: remove xy pos controller 2014-02-15 05:27:36 +11:00
Randy Mackay
9fe4d883d0 AC_AttControl: accessor for lean angle max 2014-02-15 05:27:35 +11:00
Randy Mackay
bbcf8cc84c AC_PosControl: add horizontal pos control 2014-02-15 05:27:35 +11:00
Randy Mackay
2984e492df AC_WPNav: add reference to AC_PosControl
Also remove requirement to pass in inertial nav position and velocity to
init_loiter method
2014-02-15 05:27:35 +11:00
Randy Mackay
0e0a15f4a8 AC_AttControl: add high level angle controllers 2014-02-15 05:27:35 +11:00
Randy Mackay
3ce1c0a9d5 AC_PosControl: add get_alt_error method 2014-02-15 05:27:34 +11:00
Randy Mackay
a0298aee29 AP_Motors: expose throttle min and max 2014-02-15 05:27:34 +11:00
Randy Mackay
89b7e6b1c8 AC_AttControl: implement angle_boost 2014-02-15 05:27:34 +11:00
Randy Mackay
8988b48ad8 AC_PosControl: add init take-off 2014-02-15 05:27:34 +11:00
Randy Mackay
dcac124105 AC_PosControl: add throttle controller 2014-02-15 05:27:33 +11:00
Randy Mackay
05bb943a69 AC_AttControl: first draft of PosControl class 2014-02-15 05:27:33 +11:00
Randy Mackay
b7565affcd INS: add support for 400hz for PX4 2014-02-15 05:27:33 +11:00
Randy Mackay
0521806cc6 AP_Vehicle: add multicopter parameters 2014-02-15 05:27:32 +11:00
Randy Mackay
715c8eaf02 AC_AttitudeControl: first draft of library 2014-02-15 05:27:32 +11:00
Andrew Tridgell
d853d65b84 AP_Airspeed: added ARSPD_TUBE_ORDER parameter
This allows for either order of tube connection by default, but the
order can be specified if need be
2014-02-15 05:12:15 +11:00
Andrew Tridgell
bea0a46410 AP_HAL: added servorail_voltage and power_status_flags() API on AnalogIn 2014-02-15 05:00:09 +11:00
Andrew Tridgell
ce43e674fe DataFlash: added power status logging 2014-02-15 05:00:09 +11:00
Andrew Tridgell
87355127ca GCS_MAVLink: added send_power_status() 2014-02-15 05:00:09 +11:00
Andrew Tridgell
8797f38038 GCS_MAVLink: regenerate MAVLink headers 2014-02-15 05:00:08 +11:00
Andrew Tridgell
0cbd5a2ef0 GCS_MAVLink: added POWER_STATUS message 2014-02-15 05:00:08 +11:00
Andrew Tridgell
63910bf8cd DataFlash: work around a NuttX bug
the seek offset of files can get badly mucked up when it crosses
cluster boundaries. We need to fix this in NuttX, but meanwhile this
works around the bug. It seems that doing a lseek(fd, 0, SEEK_CUR)
fixes the seek offset in the file.

The bug seems to first happen at an offset of 315392. It also
doesn't happen every time - it is more likely to happen on the first
log download after booting
2014-02-15 05:00:08 +11:00
Andrew Tridgell
0aebc18b3f GCS_MAVLink: return early from log send if no log data to send 2014-02-14 21:51:00 +11:00
Andrew Tridgell
1497c33178 GCS_MAVLink: run a bit faster on serial ports with flow control
with flow control we can afford to push the radio a bit harder
2014-02-14 21:51:00 +11:00
Andrew Tridgell
7c1b9b344f AP_HAL: added get_flow_control() API 2014-02-14 21:51:00 +11:00
Andrew Tridgell
81c5edbdb5 GCS_MAVLink: fixed a log download bug for repeated downloads
we were not resetting the offset to 0 correctly
2014-02-14 21:50:59 +11:00
Andrew Tridgell
dcd7f9d26d AP_Airspeed: use raw (signed) airspeed
this allows us to detect when the user has the ports the wrong way
around, and mark the sensor unhealthy
2014-02-14 21:50:59 +11:00
Andrew Tridgell
1849db7074 AP_HAL: added board_voltage AnalogIn method
this makes it easier to get the board voltage from any library,
without having to allocate another analog channel object
2014-02-14 21:25:38 +11:00
Andrew Tridgell
4e2e685d7a HAL_PX4: better fix for IFLOW on all ports
the tcsetattr() call fails to apply the baudrate if the port has no
RTS pin and we ask for IFLOW. So just make a separate call.
2014-02-12 17:47:23 +11:00
Andrew Tridgell
b2cdd39a99 HAL_PX4: don't enable IFLOW on ports without flow control
this should have been harmless, but breaks the GPS on Pixhawk. This
disables it until we work out why.
2014-02-12 17:32:07 +11:00
Andrew Tridgell
35791e1f05 AP_Airspeed: fixed get_temperature on PX4 2014-02-12 13:46:15 +11:00
Andrew Tridgell
ccb7dc640d AP_HAL: fixed a build warning 2014-02-12 10:51:58 +11:00
Andrew Tridgell
c93794999e HAL_PX4: remove an old conditional define 2014-02-11 15:58:25 +11:00
Andrew Tridgell
8095eb0bee AP_BoardConfig: added BRD_SAFETYENABLE option
this allows the safety switch to be disabled on startup
2014-02-11 15:58:25 +11:00
Andrew Tridgell
439a075b30 AP_HAL: added force_safety_off rcoutput function
this forces the safety switch off, enabling PWM on the IO board
2014-02-11 15:58:25 +11:00
Dan Neault
262d384025 Coax: Yaw fix
Was using _rc_yaw servo_out instead of pwm_out to modify motors.
Corrected and less touchy in Yaw
2014-02-11 11:05:02 +09:00
Andrew Tridgell
fce464597a AP_BoardConfig: PX4v1 does not have hw flow control on UART5 2014-02-11 12:11:26 +11:00
Andrew Tridgell
1b5d5dd8c4 AP_BoardConfig: set flow control to AUTO by default 2014-02-11 12:11:26 +11:00
Andrew Tridgell
c5c1d1358a HAL_PX4: added automatic hardware flow control detection
this allows us to detect if hardware flow control is not available and
automatically disable it
2014-02-11 12:11:26 +11:00
Randy Mackay
a0369b85d1 LowPassFilter: make methods non-virtual
No classes inherit from this class so no need for set_cutoff_frequency,
set_time_constant and reset(T) to be declared virtual.  Saves 6 bytes of
RAM.
2014-02-10 20:47:05 +09:00
Randy Mackay
38222d65e9 DerivativeFilter: update and slope non-virtual
No classes inherit from DerivativeFilter so no need to be virtual.
Saves 4bytes of RAM.
2014-02-10 20:47:02 +09:00
Randy Mackay
4040be9990 FilterWithBuffer: make get_sample non-virtual
virtual added to apply() and reset() declaration inline with base class.
This should have no impact on memory usage or functionality
2014-02-10 20:47:00 +09:00
Randy Mackay
6cee33b6fd AP_Curve: remove virtual from method declarations 2014-02-10 17:28:11 +09:00
Randy Mackay
4c38999ca6 Maxsonar Test: remove raw from output to user 2014-02-10 15:00:08 +09:00
Randy Mackay
e1fabadd3c MaxsonarI2C: read method returns int16_t 2014-02-10 14:59:46 +09:00
Randy Mackay
ab22d11110 MaxsonarRFinder: convert_raw returns int16_t 2014-02-10 14:59:27 +09:00
Randy Mackay
32820b4260 PulsedLightRFinder: read method returns int16_t 2014-02-10 14:58:27 +09:00
Randy Mackay
bf3fa8b99b RangeFinder: remove raw_value from SharpGP2Y 2014-02-10 14:57:17 +09:00
Randy Mackay
8d54e50897 RangeFinder: remove raw_value, orientation variables
This saves 10bytes of RAM
2014-02-10 14:56:52 +09:00
Randy Mackay
d19b566d97 OptFlow: remove unused variables
Saves 24bytes RAM by removing several static variables that were used
only for internal calculations
2014-02-10 13:53:49 +09:00
Andrew Tridgell
b907263685 AP_BoardConfig: added BRD_SER1_RTSCTS and BRD_SER2_RTSCTS
used to enable flow control on telemetry ports
2014-02-10 12:57:19 +11:00
Andrew Tridgell
3e637ac5d9 AP_HAL: added enable_flow_control() option in AP_HAL 2014-02-10 12:54:50 +11:00
Randy Mackay
c9415a08f1 AC_WPNav: use ahrs trig values 2014-02-08 18:16:47 +09:00
Randy Mackay
98d667c916 AHRS_HIL: call update_trig 2014-02-08 18:16:44 +09:00
Randy Mackay
6946d68318 AHRS_DCM: call update_trig 2014-02-08 18:16:42 +09:00
Randy Mackay
3dc6ea682c AHRS: add update_trig
Calculates helper trig values including cos_roll, cos_pitch
2014-02-08 18:16:39 +09:00
Andrew Tridgell
a95a3142e0 AP_InertialSensor: use fixed size arrays
apparently helps SITL build on MacOS
2014-02-08 19:32:26 +11:00
Bill Bonney
82ea5926a8 OptFlow: update function added to fix compiler error 2014-02-08 11:53:04 +09:00
Randy Mackay
14409ee20f Copter: disable aux channels used for motors 2014-02-07 22:04:27 +09:00
Randy Mackay
7c25247c87 Copter: disable aux channel 7 for SingleCopter
Move servo range setup to AP_MotorsSingle
2014-02-07 22:04:26 +09:00
Randy Mackay
9b594dc5e1 Copter: disable aux channel ch7 for Tri 2014-02-07 22:04:24 +09:00
Randy Mackay
1426078cdb TradHeli: disable aux channels 7 and 8 2014-02-07 22:04:23 +09:00
Paul Riseborough
bc311542ab AP_TECS : Fixed bug preventing accel launch detection when not using AS sensor 2014-02-07 19:20:54 +11:00
Dneault
5213ec4aa6 Coax: servos to ch1, ch2, motors to ch3, ch4 2014-02-07 12:36:19 +09:00
Randy Mackay
f60d94c4ab Coax: remove unused servo3, servo4
Removed commented out code
2014-02-07 12:36:06 +09:00
Dneault
f48e106271 Copter: add coax heli support
Motors should be attached to RCOutputs 1 and 2, Flaps should be connected
to RC outputs 3 and 4
2014-02-07 12:36:04 +09:00
Andrew Tridgell
00d2d5946c RC_Channel: added disable_aux_channel()
this will be used by copter to ensure motor channels are not enabled
for aux functions
2014-02-06 21:30:55 +11:00
Andrew Tridgell
b4208c7fc0 RC_Channel: added flaperon1 and flaperon2 function outputs 2014-02-06 12:35:32 +11:00
Andrew Tridgell
698736b66d RC_Channel: simplify the setup of aux channels
avoid the nasty mess of #if lines, as the info is in the constructor
anyway
2014-02-06 10:17:16 +11:00
Andrew Tridgell
264c092aa6 AP_ServoRelayEvents: fixed disabling repeated events on set_servo() 2014-02-06 10:03:26 +11:00
Randy Mackay
a963ec7e3b AP_Math: bug fix to wrap_360 and wrap_180
angles above 720deg and below 3200deg might not have been properly
wrapped.
wrap_360_cd could return 36000 when really this should be wrapped back
to zero.
2014-02-03 12:56:56 +09:00
Andrew Tridgell
688f61c087 AP_Param: expose check_var_info() as a public symbol 2014-01-31 13:07:41 +11:00
Andrew Tridgell
c0e548fc60 AP_Notify: fixed example build 2014-01-30 13:33:59 +11:00
Andrew Tridgell
93070a673e AP_Math: fixed example build 2014-01-30 13:33:46 +11:00
Andrew Tridgell
045efdb084 AP_InertialSensor: fixed example builds 2014-01-30 13:33:38 +11:00
Andrew Tridgell
a339ec25c8 AP_Airspeed: fixed example build 2014-01-30 13:33:29 +11:00
Andrew Tridgell
cf1f05a198 AP_Airspeed: expose get_temperature() 2014-01-28 10:35:35 +11:00
Andrew Tridgell
fc3ed61e67 DataFlash: added baro dataflash logging 2014-01-28 10:35:18 +11:00
Andrew Tridgell
8f3071b1b8 AP_Arming: more detail in ARMING_CHECK docs 2014-01-25 22:22:50 +11:00
Andrew Tridgell
23d8bfa976 AP_Notify: reduce the latency in the main task of LED updates
the ioctl now gets called in a IO timer callback
2014-01-24 10:40:39 +11:00
Andrew Tridgell
0d174db05b AP_Math: added equality operator for VectorN 2014-01-24 10:37:08 +11:00
Andrew Tridgell
aae0e3c0e5 AP_Arming: allow checking of pre-arm without reporting
useful for updating AP_Notify LEDs
2014-01-23 21:39:55 +11:00
Andrew Tridgell
330a4649fd AP_Notify: fixed LED colour for no-GPS and armed 2014-01-23 21:39:31 +11:00
Andrew Tridgell
58d3729d16 AP_InertialSensor: fixed default health functions
this fixes INS on APM1. Thanks to Mike McCauley for noticing this!
2014-01-22 22:08:28 +11:00
Andrew Tridgell
54562b0b9a AP_Compass: prevent bad initial values from affecting HMC5883 calibration
the first couple of values after we enter strap mode may be low, but
just above our 0.7 threshold. We now discard the first two values to
prevent these affecting the average.

Also added some commented out debug code and a comment on the scaling
of the calibration code
2014-01-22 17:15:34 +11:00
Andrew Tridgell
67aab44566 AP_ServoRelayEvents: library for handling servo and relay events 2014-01-20 17:06:29 +11:00
Andrew Tridgell
4aa901f203 AP_Relay: added enabled() API 2014-01-20 17:06:29 +11:00
Andrew Tridgell
55b604b147 AP_Camera: updates for relay API change 2014-01-20 17:06:29 +11:00
Andrew Tridgell
e42ba853ec AP_Relay: enable up to 4 relay pins 2014-01-20 17:06:29 +11:00
Andrew Tridgell
b5822cd549 AP_BoardConfig: board specific config library
used to control board specific parameters, such as PWM output count
2014-01-20 17:06:28 +11:00
Andrew Tridgell
99b41f110f HAL_PX4: enable the FMU PWM pins to be used as GPIO when needed 2014-01-20 17:06:28 +11:00
Paul Riseborough
f2c2811ef3 AP_AHRS & AP_Math: fixed bug in use of AHRS_TRIM parameters 2014-01-19 07:19:43 +11:00
Don Gagne
68b3b31499 Param doc typo 2014-01-18 10:18:58 +09:00
Andrew Tridgell
fc6ce42a28 HAL_AVR: fixed build 2014-01-17 15:00:20 +11:00
Randy Mackay
965e5b2dfd INS: check for good calibration for 10seconds
Shortened gyro calibration commit also halved the total time we would
look for a good gyro calibration.  This restores the total time to 10
seconds.
2014-01-17 12:48:11 +09:00
Andrew Tridgell
87cc95dd7f AP_HAL: removed unused enable_mask and disable_mask functions 2014-01-16 17:16:17 +11:00
Randy Mackay
1f76ada9dd INS: shortened gyro calibration
Removed delays before calibration, reduced number of samples taken,
widened convergence criteria
2014-01-16 13:40:49 +09:00
Andrew Tridgell
e1f06c532a HAL_PX4: more checking of IO results in eeprom driver 2014-01-16 13:11:14 +11:00
Andrew Tridgell
3ae6f03761 HAL_PX4: be less verbose about disarmed PWM setup 2014-01-16 13:11:13 +11:00
Andrew Tridgell
db1d438e97 HAL_PX4: implement set_safety_pwm() API
used to set PWM on motors when disarmed
2014-01-15 22:25:50 +11:00
Andrew Tridgell
5e39b6fb11 AP_HAL: added set_safety_pwm() API 2014-01-15 22:25:22 +11:00
Andrew Tridgell
64fbadcc21 HAL_PX4: use eeprom on PX4 FMUv1 as well
this means we no longer store params on SD at all
2014-01-15 19:33:13 +11:00
Randy Mackay
0a3559813a AC_WPNav: accessor for loiter speed 2014-01-15 15:22:30 +09:00
Andrew Tridgell
376ab30366 HAL_PX4: disable rename of old parameter file for now
be nice to release candidate users
2014-01-14 22:00:56 +11:00
Andrew Tridgell
461638780b HAL_AVR: fixed warning on memcheck build 2014-01-14 21:27:52 +11:00
Andrew Tridgell
626086063e HAL_PX4: added a signature to FRAM
this makes for more reliable update
2014-01-14 15:06:51 +11:00
Andrew Tridgell
921f923c5f DataFlash: reset write log on new log 2014-01-14 14:28:56 +11:00
Andrew Tridgell
b5a16a07d3 GCS_MAVLink: support LOG_REQUEST_END 2014-01-14 13:51:20 +11:00
Andrew Tridgell
ef28d087d2 DataFlash: added logging_started() API 2014-01-14 13:51:06 +11:00
Andrew Tridgell
f6db03dfb0 DataFlash: don't fsync on SITL
this makes it much faster on virtual machines
2014-01-14 12:46:26 +11:00
Andrew Tridgell
b4b66210ff DataFlash: improve reliability of microSD for logs 2014-01-14 12:46:26 +11:00
Andrew Tridgell
b88bb0751c HAL_PX4: added support for MTD (FRAM) parameters
this allows us to store parameters and waypoints in FRAM, and
auto-upgrade from microSD
2014-01-14 12:46:26 +11:00
Andrew Tridgell
e78e35f3bd HAL_PX4: try to use uppercase names on NuttX microSD card 2014-01-14 12:46:26 +11:00
Andrew Tridgell
cb23298384 DataFlash: try to keep dataflash writes aligned
also rename lastlog.txt to LASTLOG.TXT as NuttX seems to get less
corruption with VFAT filenames that don't need uppercase mappings
2014-01-14 12:46:26 +11:00
Randy Mackay
fb0fe3793c AP_Notify: external LEDs blink while initialising 2014-01-13 23:31:32 +09:00
Andrew Tridgell
63586e3e23 HAL_PX4: fixed build for new PX4Firmware 2014-01-13 13:54:51 +11:00
JakobSt
986417067e AP_GPS: Improved accuracy of NMEA driver
The conversion of ret (32bit-integer) to float reduced accuracy to ~9cm or ~22cm. Now it's ~1cm.
2014-01-13 09:58:30 +11:00
Robert Lefebvre
d441354961 TradHeli: Minor change to two param defaults
Also one param name in the code clarified.
2014-01-10 10:52:17 +09:00
Don Gagne
1db3c6e688 AP_Arming: param doc fixes
These were confusing the parser, or just incorrect
2014-01-10 10:40:53 +09:00
Don Gagne
e68cf2d1c5 Plane: Fix parameter documentation
Fixes some problems with incorrect docs which would in turn generate
bad amp.pdef.xml files for ground stations.

merge with below
2014-01-09 14:02:21 +09:00
Randy Mackay
3823eed865 OptFlow: update example sketch to work with shrunken library 2014-01-09 12:31:51 +09:00
Randy Mackay
8caa5159f8 OptFlow: shrink lib by removing unused functions
Saves 46bytes of RAM and 1k of flash
2014-01-09 12:31:48 +09:00
Randy Mackay
a53d1075ec DataFlash: add EnableWrites method
This method allows temporarily suspending writes to the dataflash which
will be used in ArduCopter to ensure no messages are written while the
copter is disarmed
2014-01-07 22:43:44 +09:00
Andrew Tridgell
4519aa8867 DataFlash: only fsync every 10 seconds
prevents too much work in SITL
2014-01-04 08:15:38 +11:00
Andrew Tridgell
89676be825 HAL_PX4: fixed RCInput race condition
the number of channels could be zero with thread switch at the wrong
time
2013-12-31 22:25:16 +11:00
Andrew Tridgell
a2997704eb HAL_PX4: removed code which drops throttle to 900 on loss of RC
rely on vehicle code checking for last data coming in
2013-12-31 10:58:49 +11:00
Andrew Tridgell
a8946a5f31 HAL_Linux: fixed build 2013-12-31 10:28:38 +11:00
Andrew Tridgell
8019d45200 DataFlash: use HAL_OS_POSIX_IO 2013-12-31 10:28:38 +11:00
Andrew Tridgell
5e3c4441dc AP_Baro: use HAL_CPU_CLASS in baro driver 2013-12-31 10:28:37 +11:00
Andrew Tridgell
ea649e036b AP_HAL: added HAL_CPU_CLASS define for selecting algorithms
this will make it easier to select the appropiate level of algorithm
for a CPU
2013-12-31 10:28:37 +11:00
Andrew Tridgell
4c99d09265 AP_Math: fixed build of vectorN class on PX4 2013-12-31 10:28:27 +11:00
Andrew Tridgell
bc2d17e76e AP_Compass: added vector compass setHIL method 2013-12-30 14:35:24 +11:00
Andrew Tridgell
e7a1331b81 AP_GPS: allow HIL GPS to show no lock 2013-12-30 14:35:20 +11:00
Andrew Tridgell
ecbfdfba6c HAL_Linux: implement time_shift() API 2013-12-30 14:35:12 +11:00
Andrew Tridgell
7e1e10f941 AP_HAL: added time_shift() scheduler API
used for log replay
2013-12-30 14:35:09 +11:00
Andrew Tridgell
96df09fd08 AP_Math: add const to quaternion API 2013-12-30 14:33:17 +11:00
Andrew Tridgell
2e9744d0b3 AP_Math: prevent transpose usage error in matrix API 2013-12-30 14:33:17 +11:00
Andrew Tridgell
2c1e0ba130 AP_Math: added vectorN class, and index checking 2013-12-30 14:33:17 +11:00
Andrew Tridgell
a96840e194 AP_AHRS: changed default GPS lag to 1 sample
this is based on detailed logs from a LEA-6H and NEO-7N
2013-12-30 10:33:48 +11:00
Andrew Tridgell
2ce1b14cbb GCS_MAVLink: removed unused variable 2013-12-29 18:39:12 +11:00
Andrew Tridgell
828eed1984 AP_Math: allow vector3 and matrix3 objects to be used as arrays 2013-12-29 18:39:09 +11:00
Andrew Tridgell
519a26691e AP_GPS: make last_message_time_ms const 2013-12-29 18:39:07 +11:00
Andrew Tridgell
410d356979 AP_AHRS: make airspeed_estimate const 2013-12-29 18:39:01 +11:00
Andrew Tridgell
87226fed97 GCS_MAVLink: avoid log scans when possible
don't scan logs when the GCS sends a new data request
2013-12-29 15:00:19 +11:00
Andrew Tridgell
a43e0f6f31 DataFlash: stop logging when erasing logs 2013-12-29 15:00:15 +11:00
Andrew Tridgell
a95868e124 HAL_PX4: even larger tx buffer size for faster log transfer 2013-12-28 16:01:48 +11:00
Andrew Tridgell
22bdee8727 HAL_PX4: implement available_memory() 2013-12-28 16:01:28 +11:00
Andrew Tridgell
c1115bd440 GCS_MAVLink: pushed num_sends higher for faster USB log transfer
up to 169 kbyte/sec on pixhawk
2013-12-28 16:01:01 +11:00
Andrew Tridgell
af124a8a45 GCS_MAVLink: moved send_meminfo() to GCS_Common.cpp 2013-12-28 16:00:19 +11:00
Andrew Tridgell
75cb04dd8b HAL_AVR: use memcheck for available_memory() 2013-12-28 14:51:15 +11:00
Andrew Tridgell
172398a971 AP_HAL: added available_memory() interface 2013-12-28 14:51:01 +11:00
Andrew Tridgell
36e06a1709 HAL_AVR: moved memcheck into HAL_AVR 2013-12-28 14:50:42 +11:00
Andrew Tridgell
efc7f88e4b GCS_MAVLink: sped up downloading DF logs over MAVLink 2013-12-28 14:25:54 +11:00
Andrew Tridgell
e1a86440bb DataFlash: stop write logging while reading
prevents nuttx getting confused
2013-12-28 14:25:54 +11:00
Andrew Tridgell
ff7004fcc5 HAL_PX4: use larger buffers on USB 2013-12-28 14:25:54 +11:00
Randy Mackay
a400ddeb88 INS: replace APM with vehicle in accel calibrate 2013-12-28 10:41:49 +09:00
Andrew Tridgell
af27921225 HAL_SITL: fixed GPS delay off by one 2013-12-28 10:17:47 +11:00
Andrew Tridgell
a37a6d68f3 DataFlash: zero-fill FMT packet before logging
this prevents uninitialised data appearing at the end of strings in
logs
2013-12-21 13:56:54 +11:00
Andrew Tridgell
f12dd85e1b AP_Arming: make enum values clearer 2013-12-20 11:59:05 +11:00
Andrew Tridgell
f6d888e0da RC_Channel: added disable_out() method 2013-12-20 11:58:53 +11:00
Andrew Tridgell
765bfbfe43 HAL_SITL: use SIM_RC_FAIL 2013-12-20 09:43:04 +11:00
Andrew Tridgell
5eac5fb26f SITL: added SIM_RC_FAIL
simulate RC failure with no signal
2013-12-20 09:43:04 +11:00
Paul Riseborough
585d61b960 AP_TECS : Reduce tendency to overspeed during climbout
The old code relies on the action of the integrator to raise the nose above the minimum pitch angle which depending on the model and the tuning can be too slow to correct. Biasing the pitch angle to climbout minimum will reduce the taken before an overspeed condition is corrected.
2013-12-20 09:43:04 +11:00
ctech4285
c8aff81c48 AP_EPM: EPM cargo gripper library 2013-12-17 15:36:39 +09:00
John Boiles
d8cdb57efa HAL_SITL: Attempting to avoid SIGPIPE on all platforms 2013-12-17 14:51:27 +11:00
Paul Riseborough
779e32d79f AP_Control : Add true airspeed compensation to pitch controller
turn rate to pitch rate calculation should use true airspeed
2013-12-17 14:17:43 +11:00
Andrew Tridgell
599edeeafb DataFlash: removed debug code for creating logs with no headers 2013-12-17 12:15:41 +11:00
Andrew Tridgell
6d356efa22 GCS_MAVLink: moved some more functions into GCS_Common.cpp 2013-12-17 12:00:44 +11:00
Andrew Tridgell
0641159660 DataFlash: fixed example build 2013-12-17 11:51:37 +11:00
Andrew Tridgell
81fc11cab7 AP_Notify: fixed example build 2013-12-17 11:51:37 +11:00
Andrew Tridgell
9b5b4ced60 AP_Math: fixed example build 2013-12-17 11:51:37 +11:00
Andrew Tridgell
8dd34f8bc4 AP_InertialSensor: fixed example build 2013-12-17 11:51:37 +11:00
Andrew Tridgell
4671aaa367 AP_InertialNav: fixed example build 2013-12-17 11:51:37 +11:00
Andrew Tridgell
e321ad65f4 AP_HAL: fixed example build 2013-12-17 11:51:37 +11:00
Andrew Tridgell
42eba615b4 AP_Baro: fixed example build 2013-12-17 11:51:37 +11:00
Andrew Tridgell
29b37b72e4 AC_WPNAV: fixed example build 2013-12-17 11:51:37 +11:00
Andrew Tridgell
305c6e4b56 AC_Sprayer: fixed example build 2013-12-17 11:51:37 +11:00
Andrew Tridgell
137137d4e1 GCS_MAVLink: remove unused header 2013-12-17 11:51:36 +11:00
Andrew Tridgell
ec584de0c2 GCS_MAVLink: prevent valgrind warnings on unfilled data 2013-12-17 11:51:36 +11:00
Andrew Tridgell
93140bd956 DataFlash: auto-add FMT headers to binary logs if needed
this copes with dataflash wrapping
2013-12-17 11:51:36 +11:00
Andrew Tridgell
e6bafa2d8f DataFlash: added structures to Init() of dataflash
this will allow the get_log_data() call to add FMT headers if a log
has wrapped
2013-12-17 11:51:36 +11:00
Andrew Tridgell
0a9e2d332a GCS_MAVLink: support erase and faster downloads 2013-12-17 11:51:35 +11:00
Andrew Tridgell
9d46f893e6 GCS_MAVLink: new headers for log download 2013-12-17 11:51:35 +11:00
Andrew Tridgell
5d53b780ba DataFlash: added functions for load download support 2013-12-17 11:51:35 +11:00
Andrew Tridgell
d034a4108b GCS_MAVLink: started adding MAVLink log download 2013-12-17 11:51:35 +11:00
Andrew Tridgell
e8f48af1b5 GCS_MAVLink: re-generate MAVLink headers 2013-12-17 11:51:35 +11:00
Andrew Tridgell
028eceefc4 GCS_MAVLink: import new mavlink XML 2013-12-17 11:51:35 +11:00
Andrew Tridgell
eb2cb0abe0 Copter: moved GCS.h to common library 2013-12-17 11:51:34 +11:00
Andrew Tridgell
e245bb07c2 RC_Channel: improved docs for RCn_FUNCTION=0 2013-12-16 11:17:26 +11:00
Robert Lefebvre
782ce54a5c TradHeli: Fix for yaw offset switching. Yaw Offset should switch on and off with the main motor, not waiting until the rotor has reached full speed. 2013-12-15 11:24:09 +09:00
Andrew Tridgell
6d39cf5e49 AP_InertialSensor: another attempt at fixing the spurious bad gyro health warnings
cope with _get_sample() not being called for a while
2013-12-14 15:47:49 +11:00
Andrew Tridgell
4ce2555a65 DataFlash: don't try to create a directory that exists
this is an attempt to avoid microSD card corruption. The most common
corruption is two 'logs' directories, which may indicate an issue with
trying to create it a 2nd time.
2013-12-14 15:47:49 +11:00
Randy Mackay
5767aa47d9 AC_WPNav: reduce leash length for stopping
We now limit the target stopping point to 1x the xy leash length while
previously it was 2x.  This is justified because this limit is only used
when the copter is travelling at higher speeds but at higher speeds air
drag tends to make the copter stop more quickly naturally.
2013-12-13 22:12:30 +09:00
Andrew Tridgell
99e2dc87c9 AP_InertialSensor: prevent INS healthy errors while initialising
during gyro cal we shouldn't mark the gyro unhealthy
2013-12-13 20:47:24 +11:00
Randy Mackay
343ea66cd1 Copter: add OctaQuad V frame 2013-12-12 21:17:49 +09:00
Randy Mackay
952afd296e Copter: initialise waypoint leash length
Without this initialisation the first RTL could be too aggressive as it
tries to stop too suddenly
2013-12-12 16:23:37 +09:00
Randy Mackay
279d515e59 Copter: Y6 new motor factor fix 2013-12-12 11:57:04 +09:00
Andrew Tridgell
23a112c5d5 AP_InertialSensor: reduce the number of format string warnings 2013-12-11 17:29:27 +11:00
Andrew Tridgell
7a12f44a41 AP_GPS: GPS week is unsigned 2013-12-11 17:29:27 +11:00
Andrew Tridgell
c649e4b06f AP_Airspeed: avoid a warning 2013-12-11 17:29:27 +11:00
Andrew Tridgell
4a77a944fa AP_Arming: make it possible to change ARMING_REQUIRED without a reboot 2013-12-11 17:29:27 +11:00
Andrew Tridgell
89bbf5de3a AP_Arming: fixed public/private split 2013-12-11 17:29:26 +11:00
Andrew Tridgell
24658197ff AP_Arming: fixed build 2013-12-11 17:29:26 +11:00
Michael Day
ebf1d9c136 AP_Arming: First commit of AP_Arming library.
Intended to prevent unintentional motor startups.
2013-12-11 17:29:18 +11:00
Michael Day
e5addf86c1 AP_AHRS: Added getters for compass and GPS. 2013-12-11 17:29:14 +11:00
Andrew Tridgell
433ad19335 AP_InertialSensor: fixed loop limits
stops pointless operations
2013-12-11 14:57:13 +11:00
Andrew Tridgell
e54fc6b8e3 AP_InertialSensor: make sure we wait for a sample before update() 2013-12-11 13:50:50 +11:00
Andrew Tridgell
57d5345774 AP_Math: added M_PI_F define 2013-12-11 10:22:47 +11:00
Andrew Tridgell
f433796435 HAL_PX4: removed an unused variable 2013-12-11 10:22:34 +11:00
Andrew Tridgell
137880be70 AP_GPS: fixed a build warning 2013-12-11 10:22:22 +11:00
Andrew Tridgell
c22df0fa60 AP_Airspeed: fixed a build warning 2013-12-11 10:22:07 +11:00
Andrew Tridgell
30fffa5854 AC_WPNav: fixed some build warnings 2013-12-11 10:21:41 +11:00
Andrew Tridgell
dde18093ed AP_Notify: disable autobuild of example
this fails due to an AVR linker bug
2013-12-10 15:54:35 +11:00
Andrew Tridgell
513f4074ce DataFlash: fixed dual sensor dataflash logging 2013-12-10 15:32:11 +11:00
Andrew Tridgell
059324f9da GCS_MAVLink: added new message header 2013-12-10 15:32:11 +11:00
Andrew Tridgell
cba0cb963a AP_InertialSensor: auto-failover to working gyro and accel 2013-12-09 20:02:04 +11:00
Andrew Tridgell
c44d8b45ce AP_Compass: auto-select healthy compass 2013-12-09 20:01:42 +11:00
Andrew Tridgell
61f564d7c9 AP_Compass: support motor compensation for multiple compasses
Pair-Programmed-With: Randy Mackay <rmackay9@yahoo.com>
2013-12-09 19:45:31 +11:00
Andrew Tridgell
0a7a935f63 AP_Compass: fixup 2013-12-09 17:54:54 +11:00
Andrew Tridgell
c538816825 AP_Compass: support compass health status on multiple compasses 2013-12-09 17:46:41 +11:00
Andrew Tridgell
bde89fd4e2 AP_Compass: added compass offsets for 2nd compass 2013-12-09 17:34:07 +11:00
Andrew Tridgell
8a97042fb1 AP_Compass: updates to support multiple compasses 2013-12-09 17:34:07 +11:00
Andrew Tridgell
08658909ad DataFlash: log both IMU packets at once 2013-12-09 17:34:07 +11:00
Andrew Tridgell
dfe3af0b30 SITL: update for compass API change 2013-12-09 17:34:07 +11:00
Andrew Tridgell
baa4ecc2ea APA_AHRS: update for compass API change 2013-12-09 17:34:07 +11:00
Andrew Tridgell
cb16733918 AP_Compass: switched to a vector based interface
this is more consistent with other APIs and makes multi-device support
easier
2013-12-09 17:34:06 +11:00
Andrew Tridgell
df001faf34 GCS_MAVLink: re-generate MAVLink headers 2013-12-09 17:34:06 +11:00
Andrew Tridgell
704ddddfaa GCS_MAVLink: update from upstream XML 2013-12-09 17:34:06 +11:00
Andrew Tridgell
a6b3d4217c DataFlash: fixes for INS API change 2013-12-09 17:34:06 +11:00
Andrew Tridgell
a0688a69d4 AP_InertialSensor: generalise the accel/gyro calibration for N sensors 2013-12-09 17:34:06 +11:00
Andrew Tridgell
db400ffa51 AP_Math: added is_zero() method to Vector3 2013-12-09 17:34:06 +11:00
Andrew Tridgell
eb883fbb0c DataFlash: added Log_Write_IMU2() for logging 2nd INS sensors 2013-12-09 17:34:06 +11:00
Andrew Tridgell
d9b6f7f0f7 AP_InertialSensor: implement up to two sensors on PX4 2013-12-09 17:34:05 +11:00
Andrew Tridgell
2753449e75 AP_InertialSensor: added support for multiple accel/gyro devices
this makes it possible to ask for the gyro and accel vectors from
secondary INS devices.
2013-12-09 17:34:05 +11:00
Randy Mackay
91c17e9848 GPSGlitch: reduce radius to 2m 2013-12-09 11:42:03 +09:00
Randy Mackay
bffa7c3783 Camera: correct _trigger_type comment 2013-12-06 10:28:36 +09:00
Randy Mackay
4148c4e024 TradHeli: bug fix for main rotor ramp up
The main rotor ramp was being held back by the rotor speed estimate
instead of being allowed to jump up to the estimate if it's lower.

Also fixed some incorrect indentation
2013-12-05 21:24:20 +09:00
Randy Mackay
8149b54807 Copter: add Y6 with all top props CW
Set FRAME parameter to 10
2013-12-03 23:22:14 +09:00
Randy Mackay
e54bf3e87c RangeFinder: reduce PulsedLight max distance
Reduced from 25m to 14m
2013-12-03 20:26:23 +09:00
Randy Mackay
3970c8f038 RangeFinder: add PulsedLight example sketch 2013-12-02 20:06:49 +09:00
Randy Mackay
e88251f7e1 RangeFinder: add PulsedLight LRF 2013-12-02 20:06:43 +09:00
Randy Mackay
f8e269cd04 OptFlow: correct SPI mode and baud rates 2013-12-01 23:20:02 +09:00
Randy Mackay
def5ddb747 AP_Notify: disable buzzer along with external leds 2013-11-30 23:27:58 +09:00
Randy Mackay
f8b4187148 AP_Notify: define external led pins for non APM boards
resolves compiler errors
2013-11-30 23:27:27 +09:00
Randy Mackay
aae18f9ead AP_Notify: allow external leds to be disabled 2013-11-30 22:53:40 +09:00
Randy Mackay
1f0fb3f06b AP_Notify: add Buzzer 2013-11-30 18:20:51 +09:00
Robert Lefebvre
d1cf9f949f AP_Notify: ExternalLED library 2013-11-30 18:20:49 +09:00
Andrew Tridgell
ee7c742863 AP_Airspeed: changed default pin for SITL to pin 1
this leaves room for the sonar
2013-11-28 21:44:32 +11:00
Andrew Tridgell
b075f8735f SITL: moved airspeed pin to pin 1
keep it separate from the sonar, allowing both to be used at the same time
2013-11-28 21:44:05 +11:00
Ben Nizette
339da1c21b SITL: Add noise and glitching behaviour for the sonar sensor 2013-11-28 21:38:05 +11:00
Ben Nizette
70d37d2cf6 SITL: Wire in basic support for SITL downward-looking sonar sensors 2013-11-28 21:38:05 +11:00
Ben Nizette
f4d349eff8 SITL: Wire in random noise and fixed drift for the SITL barometer 2013-11-28 21:38:05 +11:00
Ben Nizette
59a54aae20 SITL: Add barometer drift parameter to the SITL library 2013-11-28 21:35:13 +11:00
Randy Mackay
90937be3d4 AP_Motors: fix example sketch 2013-11-28 11:34:00 +09:00
Randy Mackay
f9e19b8006 TradHeli: remove use of motor_out array
No longer required for logging purposes as we have RCOU
2013-11-27 22:33:02 +09:00
Randy Mackay
851a538692 Copter: motor matrix comment change 2013-11-27 22:33:01 +09:00
Randy Mackay
652b4b4fe5 SingleCopter: motor test flaps servos in order 2013-11-27 22:33:00 +09:00
Randy Mackay
ccedf98238 Tri: call output_min at end of motors test
Minor change to comments
2013-11-27 22:32:49 +09:00
Randy Mackay
9f2086baf2 Copter: make motor_out array private
With new method of logging rc outputs access to the motor_out array is
not longer required
2013-11-27 21:55:28 +09:00
Randy Mackay
ef2597a626 DataFlash: rename Log_Write_SERVO to Log_Write_RCOU 2013-11-27 20:17:41 +09:00
Randy Mackay
84fdff4cd6 Compass: slightly relax HMC5843 calibration limits
Some users have reported Z axis values as high as 1.33.  Their compasses
seem otherwise health so extending the limits slightly.
2013-11-27 15:36:34 +09:00
Randy Mackay
f8e2947823 RC_Channel: parameter @Units to pwm 2013-11-26 22:34:28 +09:00
Randy Mackay
fd9b115d01 INS: move Product ID to @User Advanced 2013-11-26 22:18:28 +09:00
Randy Mackay
c4df3ea187 Fence: parameter display name fix 2013-11-26 22:18:05 +09:00
Andrew Tridgell
4b4f5ed1c0 HAL_PX4: support get_system_id() on PX4 2013-11-26 13:00:03 +11:00
Andrew Tridgell
f95bea699b AP_HAL: added get_system_id() method on Util 2013-11-26 13:00:03 +11:00
Andrew Tridgell
825b360fb0 DataFlash: added RCIN and SRVO log methods 2013-11-26 09:04:43 +11:00
Andrew Tridgell
0a2f2619de DataFlash: fixed SITL dataflash logging
block numbers are 1 based
2013-11-26 09:04:43 +11:00
Randy Mackay
e489224c6b GPSGlitch: update @Range for RADIUS and ACCEL params 2013-11-24 23:21:19 +09:00
Randy Mackay
bd6511dd0a GPS: add GPS_UBLOX_passthrough sketch
This sketch allows the user to configure the Ublox GPS using U-Center
without the need for an FTDI cable.
2013-11-24 14:53:08 +09:00
Randy Mackay
2d202df98a Sprayer: fixed example sketch 2013-11-24 14:11:52 +09:00
Andrew Tridgell
b248cc0868 AP_AHRS: fixed a build warning 2013-11-23 21:44:56 +11:00
Andrew Tridgell
710d5119b5 AP_AHRS: added attitude_reset() method for HIL_SENSORS 2013-11-23 19:29:23 +11:00
Andrew Tridgell
ac24ff0b1e GCS_MAVLink: added support for 3 UARTs
support 3 UARTs on non-AVR platforms
2013-11-23 19:29:22 +11:00
Andrew Tridgell
0b25ff0a16 HAL_PX4: added uartD 2013-11-23 19:29:22 +11:00
Andrew Tridgell
c000a08d6f HAL_LINUX: added uartD 2013-11-23 19:29:22 +11:00
Andrew Tridgell
0848412479 HAL_FLYMAPLE: added uartD 2013-11-23 19:29:22 +11:00
Andrew Tridgell
5e980a5b49 HAL_EMPTY: added uartD 2013-11-23 19:29:22 +11:00
Andrew Tridgell
18eadfd69e HAL_SITL: added uartD 2013-11-23 19:29:22 +11:00
Andrew Tridgell
4fb1fdb627 HAL_AVR: added NULL uartD 2013-11-23 19:29:22 +11:00
Andrew Tridgell
cbc0f3ec27 AP_HAL: support uartD on some boards
PX4 and SITL get an extra UART
2013-11-23 19:29:22 +11:00
Andrew Tridgell
72415ed358 AP_GPS: change HIL GPS to always be 5Hz
this prevents too short updates in DCM from affecting attitude
2013-11-23 18:50:57 +11:00
Andrew Tridgell
6ed493b10f AP_AHRS: added attitude_reset() method for HIL_SENSORS 2013-11-23 18:50:56 +11:00
Andrew Tridgell
8b254f2947 HAL_EMPTY: prevent valgrind errors
zero I2C transfers
2013-11-23 18:50:55 +11:00
Andrew Tridgell
316ec5864e AP_Motors: removed incorrect Makefile target 2013-11-23 18:50:55 +11:00
Andrew Tridgell
b62501aaea HAL_FLYMAPLE: removed incorrect Makefile target 2013-11-23 18:50:55 +11:00
Andrew Tridgell
6c2e392d5d AP_Baro: fixed BMP085 examples build in autotest 2013-11-23 18:50:55 +11:00
Andrew Tridgell
8d227b801f GCS_MAVLink: increase max packet size to 104
this enables the DATA96 packet to be sent
2013-11-22 15:08:34 +11:00
Randy Mackay
dacca04b21 INav: record error_count when GPS msg is late 2013-11-21 17:02:02 +09:00
Randy Mackay
7c52572020 Ublox: disable NMEA info in 3DR config 2013-11-21 17:02:00 +09:00
Randy Mackay
4e5cb72604 Ublox: set default rate to 5hz in 3DR config 2013-11-21 17:01:58 +09:00
Randy Mackay
b349d95269 Ublox: disable TimePulse Timedata in 3DR config 2013-11-21 17:01:55 +09:00
Randy Mackay
25046b4e6d Ublox: update config to ver 7.03 2013-11-21 17:01:52 +09:00
Randy Mackay
afbb199544 TradHeli: remove slash from parameter description
This may fix the issue in which the parameter descriptions are appearing
twice on the arducopter-parameters wiki page
2013-11-19 11:23:07 +09:00
Randy Mackay
a147eeb1e3 INav: degrade pos error slowly on loss of GPS
When GPS message is late by 100ms or we are glitching, degrade the GPS
vs inertial nav position error to 10% over 2 seconds instead of
immediately setting it to zero.  This avoids jumpy position estimates
when the GPS misses an update
2013-11-18 23:19:57 +09:00
Randy Mackay
330aa95769 Copter: default MOT_SPIN_ARMED to 70 2013-11-18 17:00:17 +09:00
Randy Mackay
80059d3516 AP_HAL_AVR: resolve compiler warning 2013-11-16 16:58:32 +09:00
Randy Mackay
7233a567fb TradHeli: add accessor for phase_angle 2013-11-15 22:58:41 +09:00
Randy Mackay
c9c803ffd4 TradHeli: move STAB_COL_MIN to main parameter list 2013-11-15 22:58:32 +09:00
Randy Mackay
b71c6bfd76 TradHeli: add RSC_RUNUP_TIME param and rotor speed estimate 2013-11-15 22:58:29 +09:00
Randy Mackay
bc4dba0eea TradHeli: ext gyro gain range 0 to 1000 2013-11-15 22:58:26 +09:00
Randy Mackay
197fc67897 TradHeli: move pilot desired rotor speed to heli.pde 2013-11-15 22:58:24 +09:00
Randy Mackay
942c14258b TradHeli: ramp up changes
Rewrote tail and main rotor ramp up methods
Moved direct drive ESC speed control into rsc_control method
Pass in ch7 servo as servo_aux to TradHeli motors object constructor
split CH7_SETPOINT parameter into GYR_GAIN and DIRECTDRIVE parameters
replaced RSC_RATE with uint8_t RSC_RAMP_TIME parameter
rename GOV_SETPOINT parameter to RSC_SETPOINT
RSC_MODE parameter description updated to indicate it controls the
source of main rotor speed
2013-11-15 22:58:13 +09:00
Robert Lefebvre
9ac051c56d TradHeli: BugFix to ColYaw
Credit to Jolyon Saunders for finding this bug.
2013-11-15 22:58:11 +09:00
Robert Lefebvre
4426060ccc TradHeli: COLYAW not applied when the motor is not running 2013-11-15 22:58:06 +09:00
Robert Lefebvre
9ae66c1773 TradHeli: add support for drive tail rotors
Repurposed external gyro and made it multi-funcitonal.
required PWM on Ch8 to start the motor in RSC Mode moved up from 100 to 400. This is to facilitate two-stage switching of the motors with PWM>100 starting the tail motor, and PWM>400 starting the main motor.
Additional amendments by Randy
2013-11-15 22:58:04 +09:00
Randy Mackay
7ae0d3320b TradHeli: add landing collective min 2013-11-15 22:57:58 +09:00
Randy Mackay
1f65bb537f TradHeli: add get_pilot_desired_collective
Perhaps this should be moved to the main code's heli.pde sketch
2013-11-15 22:57:51 +09:00
Randy Mackay
13a412ee21 TradHeli: make parameters and variables private
add accessors for variables and params required in main code
replace tabs with spaces
2013-11-15 22:57:41 +09:00
Randy Mackay
2cc48ffcd6 Copter: formatting and param description changes 2013-11-15 22:57:37 +09:00
Randy Mackay
f5488bc447 HAL: MPU6k and Baro SPI to 8Mhz 2013-11-15 21:58:32 +09:00
Andrew Tridgell
08a6503364 HAL_AVR: force all devices on SPI0 to low speed when one is low speed
this forces MS5611 to low speed when MPU6K is low speed
2013-11-15 21:58:30 +09:00
Andrew Tridgell
71bb462ad0 AP_InertialSensor: use fabsf() 2013-11-15 10:43:10 +11:00
Andrew Tridgell
aef9289476 AP_InertialSensor: added INS_PRODUCT_ID values 2013-11-15 10:43:10 +11:00
Randy Mackay
d54b1ea446 CopterMotors: fix example sketch 2013-11-14 22:27:10 +09:00
Randy Mackay
ce045c77a4 Copter: remove unused variable from Single copter 2013-11-14 22:26:53 +09:00
Randy Mackay
bcbf0feff0 GPS Glitch: revert accel max to 10m/s/s
This may not be the best real world value but it keeps the autotester
from failing because it recovers from the glitch before the 5second
time-out on the GPS failsafe
2013-11-13 21:33:34 +09:00
Randy Mackay
14dc1a1c88 Copter: add @User and @Increment to motor params description 2013-11-13 12:28:59 +09:00
Randy Mackay
e53c57b0a6 Copter: default SPIN_WHEN_ARMED to zero 2013-11-13 12:28:01 +09:00
Randy Mackay
3bd124eb72 GPS Glitch: radius and accel max to 5m and 5m/s/s 2013-11-13 11:49:21 +09:00
Randy Mackay
81d83f1c55 SingleCopter: formatting changes
replace tab with 4-spaces
remove blank lines
2013-11-12 23:40:29 +09:00
ssq870424
07d3f2a3c5 Copter: add support for singlecopter airframe
this is the newest singlecopter airframe programme.
This kind of aerial vehicles include Honeywell T-hawk and Goldeneye.
2013-11-12 23:40:27 +09:00
Andrew Tridgell
f10a4b04ae AP_InertialSensor: make PX4 healthy call _get_sample()
this prevents a false positive during times like arming where we are
not reading the sensors
2013-11-10 17:03:16 +11:00
Andrew Tridgell
cfad814bfb AP_L1_Control: fixed switchover from loiter capture to circling
Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2013-11-09 15:52:11 +11:00
Paul Riseborough
49fe7fea07 L1_Control : Added hysteresis for rear WP capture 2013-11-09 15:40:14 +11:00
Andrew Tridgell
1393ed58d0 AP_L1_Control: fixed waypoint approach logic
this could cause the RTL approach to not break off onto the circle
correctly
2013-11-09 12:54:26 +11:00
Andrew Tridgell
80def01fbe AP_InertialSensor: fixed semaphore error on startup for MPU6000 2013-11-09 11:26:50 +11:00
Andrew Tridgell
3262022195 DataFlash: print FMT messages for wrapped logs
this ensures we have FMT messages in every log, even if the log was
wrapped and the FMT messages were overwritten
2013-11-09 11:09:42 +11:00
Andrew Tridgell
4f871c87f1 AP_AHRS: detect and try to cope with bad accels 2013-11-07 13:54:16 +11:00
Andrew Tridgell
f5299e2e11 AP_InertialSensor: added healthy check for PX4 and HIL
used to detect bad accels
2013-11-07 13:53:59 +11:00
Andrew Tridgell
428479b9d5 SITL: added SIM_ACCEL_FAIL option
used to test accelerometer failure in flight
2013-11-07 12:49:08 +11:00
Andrew Tridgell
9d7f24f754 AP_Airspeed: added healthy() API 2013-11-07 12:48:17 +11:00
Andrew Tridgell
8a65a729f3 AP_Baro: start MS5611 at high speed 2013-11-07 12:48:17 +11:00
Andrew Tridgell
9ecd889e9d AP_InertialSensor: detect bad MPU6000 SPI transactions and lower bus speed
this uses bad data or bad INT_STATUS values from the MPU6000 to detect
the sensor running too fast and lower bus speed
2013-11-07 12:48:17 +11:00
Andrew Tridgell
d2deee07df AP_Math: fixed zero function for integer vectors 2013-11-07 12:48:16 +11:00
Andrew Tridgell
b98bcbf715 AP_InertialSensor: automatically lower bus speed on mpu6k bad reads 2013-11-07 12:48:16 +11:00
Andrew Tridgell
bdc40cc7df AP_InertialSensor: try to lower SPI bus speed on errors 2013-11-07 12:48:16 +11:00
Andrew Tridgell
11e1cf31c4 HAL_AVR: changed to 16 byte bulk transfer on SPI0 2013-11-07 12:48:16 +11:00
Andrew Tridgell
900ea5dde0 DataFlash: make the SITL dataflash log 4x larger 2013-11-07 10:18:38 +11:00
Andrew Tridgell
a86ec8c786 AP_Menu: fixed double display of prompt 2013-11-06 10:49:47 +11:00
Andrew Tridgell
45381e5341 AP_Menu: added check_for_input() API
this allows for async use of the menus, so that a main loop can run
while allowing the user to enter menu commands
2013-11-06 09:40:49 +11:00
Andrew Tridgell
46724db144 AP_Menu: zero buffer contents on allocation 2013-11-06 09:40:46 +11:00
Andrew Tridgell
470e5f570d AP_Menu: dynamically allocate the menu buffers
this saves memory when the menus are not used, and allows for the
commandline and argument limits to be changed
2013-11-06 09:40:40 +11:00
Andrew Tridgell
ff73773de4 AP_GPS: try harder to get 5Hz updates from a uBlox
check for getting at least one 5Hz update every 15s
2013-11-05 15:18:25 +11:00
Andrew Tridgell
56bcda7252 AP_AHRS: lower default roll and yaw drift correction speed
the gyros sustain accuracy over much longer time periods than
previously expected
2013-11-05 14:52:39 +11:00
Andrew Tridgell
24d1cf3bd6 HAL_PX4: don't check USB for data if not connected 2013-11-05 14:41:42 +11:00
Andrew Tridgell
8dc6b758f3 HAL_PX4: switch to delay_microseconds_semaphore() for UART timer
this may prevent some timing jitter on the GPS UARTs
2013-11-05 14:41:24 +11:00
Andrew Tridgell
1fb636d57f DataFlash: added APM time and GPS velz to logged GPS messages 2013-11-04 21:37:10 +11:00
Andrew Tridgell
b096881f81 AP_TECS: added time to TECS messages 2013-11-04 21:36:40 +11:00
Andrew Tridgell
ea9a2eda3f AP_L1_Control: reduced demanded bank angle by cos(pitch)
this prevents attempts to do too tight turns while at a steep pitch

Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2013-11-04 21:21:42 +11:00
Andrew Tridgell
9b5cae2134 APM_Control: reduce roll compensation in pitch controller by cos(pitch)
This reduces the use of the pitch compensation when in a steep climb
or dive

Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2013-11-04 21:21:42 +11:00
Andrew Tridgell
5e915fbde3 DataFlash: added timestamp to IMU and VelZ to GPS logging
both are very useful for analysis
2013-11-04 21:21:42 +11:00
Andrew Tridgell
02d6f012ce AP_AHRS: added accel sum delay buffer to account for GPS lag 2013-11-04 21:21:42 +11:00
Andrew Tridgell
55b7903456 AP_InertialNav: update for AHRS API changes 2013-11-04 21:21:42 +11:00
Andrew Tridgell
1cd070a2e7 AP_InertialSensor: use const reference returns
saves some vector copies
2013-11-04 21:21:42 +11:00
Andrew Tridgell
28a4b6ad9f AP_TECS: update for AHRS API change 2013-11-04 21:21:42 +11:00
Andrew Tridgell
4e82a8e1d4 DataFlash: use const ins reference
save some pointer dereferences
2013-11-04 21:21:42 +11:00
Andrew Tridgell
2930184680 AP_YawController: update for AHRS API change 2013-11-04 21:21:42 +11:00
Andrew Tridgell
979c6ae3b6 AC_Fence: update for AHRS API changes 2013-11-04 21:21:42 +11:00
Andrew Tridgell
d31e557983 AP_AHRS: save memory and reduce pointer references
use a refence for ins, and don't save gyro and accel between updates
2013-11-04 21:21:37 +11:00
Andrew Tridgell
cb52b6f367 AP_AHRS: removed limit on normalisation of accel reference vectors
this could lead to a bias in the accel drift correction
2013-11-04 21:20:41 +11:00
Andrew Tridgell
31eaaada62 AP_AHRS: removed vertical G limit on GPS velocity correction
this limit could lead to a bias in the accel drift correction, and is
frequenctly exceeded
2013-11-04 21:20:41 +11:00
Andrew Tridgell
a7931b1581 AP_AHRS: fixed wrapping bug in GPS based heading error
this bug could cause the GPS based yaw to use an expensive reset far
too often
2013-11-04 21:20:41 +11:00
Andrew Tridgell
17b27a47de AP_AHRS: prevent GPS yaw resets on compass errors
when we switch from compass heading to GPS heading we don't want to
trigger a sudden GPS yaw reset
2013-11-04 21:20:41 +11:00
Andrew Tridgell
fc5f825b6d AP_Notify: make APM2 ToshibaLED driver more efficient
use one I2C transfer, not 3
2013-11-04 17:48:53 +11:00
Robert Lefebvre
5d946be77c TradHeli: Change user description for COLYAW parameter. 2013-11-03 12:56:59 +09:00
Jason Short
1c7d9f43c1 InertialNav: fix for get_velocity_xy
forgot to sq
2013-11-03 10:14:01 +09:00
Jason Short
2de6dbd3d8 InertialNav: added get_velocity_xy 2013-11-02 21:34:45 +09:00
Paul Riseborough
71de4ddcd0 AP_Airspeed : Fixes bug that caused airspeed calibration to be sent a zero airspeed
This bug resulted in the airspeed ratio going to the maximum value of 4 and staying there. This could lead to a very slow flying model and a stall.
2013-11-02 21:41:11 +11:00
Andrew Tridgell
f4dde44b8d AP_InertialSensor: SITL doesn't use Oilpan code any more 2013-11-02 21:41:11 +11:00
Randy Mackay
330687a754 RC_Channel: formatting 2013-10-31 15:23:52 +09:00
Randy Mackay
bb1664185f Copter: correct @Range of MOT_TCRV_MAXPCT parameter 2013-10-30 20:53:21 +09:00
Andrew Tridgell
c64aa0e4de AP_Airspeed: fixed I2C semaphore handling for I2C airspeed
this affects MS4525DO on APM2
2013-10-29 14:55:38 +11:00
Randy Mackay
d09fd0d035 BattMonitor: add @Increment to CAPACITY description 2013-10-29 11:23:27 +09:00
Randy Mackay
24147a370a BoardLEDs: all leds off during init 2013-10-29 10:54:08 +09:00
Andrew Tridgell
580e7b8a4a HAL_AVR: switch back to 500kHz SPI for MPU6k until we understand the issues
this is for new plane release. We need for analysis before we can
re-enable high speed SPI
2013-10-28 16:55:22 +11:00
Andrew Tridgell
5800c2a2c8 HAL_PX4: prevent excessive writes on startup from blocking
this could cause copter on PX4 to hang on startup
2013-10-28 16:12:44 +11:00
Randy Mackay
c602f7da0c AC_Fence: fix example sketch 2013-10-27 21:53:22 +09:00
Andrew Tridgell
c5b36ef3d2 AP_InertialNav: fixed example build 2013-10-27 22:11:59 +11:00
Randy Mackay
4348a272bf AP_InertialNav: remove unused velocity fns
remove get_longitude_velocity and get_latitude_velocity
2013-10-27 13:41:55 +09:00
Randy Mackay
8fc16d5cdf AP_InertialNav: add comments, make ahrs const from neurocopter
These fixes are provided by neurocopter but with my name because of
merge conflicts
_position and _velocity vectors added to save some floating point add
operations
unused reference to ins in constructor removed
2013-10-27 13:41:50 +09:00
Tobias
0b181dd995 AP_Buffer: remove header/source separation to allow arbitrary template
parameters without explicit instantiation in the cpp file.

http://stackoverflow.com/questions/495021/why-can-templates-only-be-implemented-in-the-header-file
2013-10-27 13:41:43 +09:00
Randy Mackay
e23135faa1 AP_InertialNav: bug fix for gps delay handling 2013-10-27 13:41:40 +09:00
Tobias
cfaaf4b1e7 AP_InertialNav: rename AP_Buffer functions, fix delay handling bug
The most recent value was used instead of the intended historical value
as indicated by the comment.
2013-10-27 13:41:38 +09:00
Tobias
dc62398821 AP_Buffer: add comments and rename functions to conform with the
STL-container naming conventions
Comment format changes by Randy
2013-10-27 13:41:36 +09:00
Tobias
6c825eace2 AP_InertialNav: move variable definitions to elide unused default
construction of objects (saves 106 bytes)
2013-10-27 13:41:32 +09:00
Tobias
c3309d909c AC_WPNav: make more member pointers const 2013-10-27 13:41:29 +09:00
Tobias
bb5cf4a311 AC_WPNav: make member pointer to AP_InertialNav object const since it's
never modified
2013-10-27 13:41:23 +09:00
Tobias
b94d6848de AC_Fence: replace "_ina->geT_position().z" with more efficent
"_inav->get_altitude()"
2013-10-27 13:41:19 +09:00
Tobias
596c7a25b7 AC_Fence: make member pointer to AP_InertialNav const, remove unused
gps-pointer member
2013-10-27 13:41:09 +09:00
Randy Mackay
f56d00ebb6 AC_Sprayer: add doxygen info 2013-10-27 13:40:57 +09:00
Tobias
1ecb583dd9 AC_WPNav: replace unnecessary objects with const refs 2013-10-27 13:40:53 +09:00
Tobias
c62f2e3d0c AC_Sprayer: replace unnecessary object with const ref 2013-10-27 13:40:44 +09:00
Tobias
e2c3ea0f56 AC_Sprayer: add consts, update comments
* removed some comments that were left over from the classes this class
was copypasta'ed from
2013-10-27 13:39:32 +09:00
Tobias
f4000e66e6 Filter: add consts 2013-10-27 13:39:28 +09:00
Tobias
7855d242c7 AP_Baro: add time-unit comment 2013-10-27 13:39:23 +09:00
Tobias
c9f68fcd1b AP_InertialNav: remove unused AP_InertialSensor pointer 2013-10-27 13:39:10 +09:00
Tobias
cbff58e2ed AP_InertialNav: add comments, rename incorrectly named member,
initialize member, remove redundant assignment
adjustments to original commit by randy
2013-10-27 13:39:08 +09:00
Andrew Tridgell
5af51140a9 HAL_Linux: fixed scheduler initialisation bug in Linux HAL as well 2013-10-26 18:25:27 +11:00
Andrew Tridgell
622f0dcc1d HAL_PX4: prevent threads running before subsystems are initialised
this fixes a bug where the timer thread would hang waiting for the
console on startup. This caused the "hit enter" behaviour with recent
PX4 bugs, as AnalogIn tried to read from fd==0, which was a console
read
2013-10-26 18:12:35 +11:00
Paul Riseborough
97cdd36dd8 APM_Control : Moved scaler on roll and pitch integrator to be before integrator
This means that the value of aileron and elevator trim offset won't change with airspeed
2013-10-25 22:37:49 +11:00
Randy Mackay
0049351f2f GCS_MAVLink: generate after adding RC reciever to SYS_STATUS enum 2013-10-24 16:32:49 +09:00
Randy Mackay
d1906abb5c GCS_MAVLink: add RC receiver to SYS_STATUS enum 2013-10-24 16:32:09 +09:00
Andrew Tridgell
de96ad9445 AP_GPS: fixed date handling in NMEA driver 2013-10-24 14:22:48 +11:00
Andrew Tridgell
65ebdfa786 HAL_SITL: fixed time strings in simulated NMEA GPS 2013-10-24 14:22:48 +11:00
Andrew Tridgell
6b2222c32e DataFlash: show timestamps on flash logs 2013-10-24 14:22:48 +11:00
Andrew Tridgell
34cde1a640 HAL_PX4: implement set_system_clock() 2013-10-24 14:22:48 +11:00
Andrew Tridgell
0ca82d5e3c AP_HAL: added set_system_clock() API 2013-10-24 14:22:48 +11:00
Andrew Tridgell
744819cec8 AP_GPS: added fake time to fake GPS lock 2013-10-24 14:22:48 +11:00
Andrew Tridgell
d7a9888e26 DataFlash: updates for new GPS API 2013-10-24 14:22:47 +11:00
Andrew Tridgell
19ba07a3f9 AP_InertialNav: updates for new GPS API 2013-10-24 14:22:47 +11:00
Andrew Tridgell
b7b9efd120 HAL_SITL: properly emulate timestamps on ublox and MTK 2013-10-24 14:22:47 +11:00
Andrew Tridgell
6f5ac1d553 AP_GPS: added support for GPS time in week/millisec
also adds time_epoch_usec() for MAVLink SYSTEM_TIME
2013-10-24 14:22:47 +11:00
Andrew Tridgell
6438be74e0 HAL_SITL: get the ublox GPS timestamps right in SITL 2013-10-24 14:22:47 +11:00
Andrew Tridgell
f34b1c280d AP_BattMonitor: added set_monitoring() API
needed for test sketch
2013-10-23 09:40:42 +11:00
Andrew Tridgell
d305dd5946 AP_AHRS: debounce the GPS/compass consistency test
we will only consider the compass inconsistent with GPS if it is off
for more than 2 seconds
2013-10-23 09:40:42 +11:00
texlan
78acea820f Copter: fix symmetry in stability patch for Tricopters
Removes the "Increase opposing motors by 1/2 the overage of the high
motor" logic and merely moves all 3 motors down by the same amount if
one is over out_max. This eliminates the asymmetric scaling of
the previous logic when more than one motor is over out_max. This
resolves #537
2013-10-21 20:12:53 +09:00
Randy Mackay
8f4665c4c7 ToshibaLED: ignore I2C errors during init 2013-10-21 20:01:34 +09:00
Randy Mackay
443023bbbf AP_HAL: add ignore_errors to I2C driver 2013-10-21 20:01:32 +09:00
Randy Mackay
943d7374f6 Copter: slow start motors from 0 to min throttle 2013-10-20 14:51:35 +09:00
texlan
53553751d1 Copter: Correctly set limit.lower flags for Tricopters
Resolves #536
2013-10-19 23:08:25 +09:00
Andrew Tridgell
1c091cbca5 HAL_PX4: fixed a scheduler bug that affects UART IO
we need to detect if we are in a timer task using a PID, not a
flag. This is the same type of bug I fixed last week, but now fixed
properly.

The bug could well be the "USB bug" that Craig has been chasing
2013-10-19 16:50:38 +11:00
Randy Mackay
e0c4785b2a Copter: OctaQuad H-frame support 2013-10-18 10:41:07 +09:00
Andrew Tridgell
3393a5c99e AP_Baro: prevent a race condition in the SITL baro driver 2013-10-17 17:22:19 +11:00
Andrew Tridgell
86afc26609 HAL_SITL: decrease wind with altitude
this prevents JSBSim crash on the runway
2013-10-17 17:22:19 +11:00
Andrew Tridgell
98d391efa0 AP_Camera: added note on DO_SET_CAM_TRIGG_DIST in docs 2013-10-15 10:09:39 +11:00
Andrew Tridgell
ede927f68a HAL_SITL: added airspeed noise control 2013-10-14 15:40:45 +11:00
Mike McCauley
c524a7c717 AP_HAL_FLYMAPLE: remove obsolete debugging code from RCInput 2013-10-14 11:34:47 +10:00
Mike McCauley
6f04e5f2e7 AP_HAL_FLYMAPLE: RCInput now more robust in the face of connect/disconnect of
a PPM-SUM source

Also remove some left over debug code.
2013-10-14 11:34:47 +10:00
Mike McCauley
ce1a8fb831 AP_HAL_FLYMAPLE: Added new example test sketch RCInput.pde 2013-10-14 11:34:47 +10:00
Mike McCauley
3226a81611 AP_HAL_FLYMAPLE: Improvements to RCInput
More reasonable sync pulse times, add input filter to prevent false triggering
2013-10-14 11:34:47 +10:00
Mike McCauley
fe6cacf081 AP_InertialSensor: Minor correction to comments in AP_InertialSensor_Flymaple.cpp 2013-10-14 11:34:47 +10:00
Mike McCauley
0920d9ac49 AP_HAL_FLYMAPLE: UARTDriver Use new libmaple TX buffers.
Caution: requires latest libmaple from
git@github.com:mikemccauley/libmaple.git
2013-10-14 11:34:47 +10:00
Mike McCauley
38512e3756 AP_HAL_FLYMAPLE: I2CDriver improvements to interrupt hygiene 2013-10-14 11:34:47 +10:00
Mike McCauley
8e5a9b06fb AP_HAL_FLYMAPLE: Fix example Scheduler.pde fo recent changes to API 2013-10-14 11:34:47 +10:00
Mike McCauley
bc55a2844c AP_HAL_FLYMAPLE: Fix example Scheduler.pde to compile with recent changes to
scheduler API
2013-10-14 11:34:47 +10:00
Andrew Tridgell
72b97168c9 AP_RangeFinder: improved SONAR_PIN docs 2013-10-14 10:03:52 +11:00
Andrew Tridgell
7831113f84 AP_InertialSensor: yield the CPU for the right time in wait_for_sample()
this improves timing performance
2013-10-14 08:45:58 +11:00
Andrew Tridgell
d973730b88 HAL_PX4: use hrt timer and semaphores to improve timing
this gives much more accurate microsecond delays, while also ensuring
we yield the CPU when possible
2013-10-14 08:29:30 +11:00
Andrew Tridgell
8532e2bff8 AP_InertialSensor: fixed timing of PX4 sensor samples 2013-10-13 22:15:50 +11:00
Andrew Tridgell
c4d62f6b92 AP_Scheduler: fixed SCHED_DEBUG docs 2013-10-13 21:41:01 +11:00
Andrew Tridgell
0f4da25e68 AP_Scheduler: make sure we run remaining tasks on overrun
when a task overruns its time, we can still run the rest of the tasks
in the task list
2013-10-13 21:41:01 +11:00
Andrew Tridgell
a5788dde8f HAL_AVR: added Scheduler.set_timer_speed() support 2013-10-13 11:03:37 +09:00
Andrew Tridgell
7ef187fcfd AP_HAL: added optional set_timer_speed() scheduler API
will be used by copter to reduce interrupt load on APM2
2013-10-13 11:03:35 +09:00
Andrew Tridgell
4de2a654ab AP_Mount: changed ahrs to be a const reference
saves a bit of code
2013-10-13 11:03:24 +09:00
Andrew Tridgell
34770fe6bf HAL_AVR: fixed SPI bus speed switching
this fixes a bug in changing the bus speed between devices
2013-10-13 11:03:17 +09:00
Randy Mackay
f2f61af125 HAL_AVR: scheduler interrupt 500hz for APM2 2013-10-13 11:03:13 +09:00
Andrew Tridgell
9833900f91 AP_InertialSensor: run MPU6000 sensor register reads at 8MHz
run other register IO at 500kHz
2013-10-13 11:03:08 +09:00
Andrew Tridgell
04836ea763 HAL_AVR: set initial bus speed on MPU6k to 500kHz, then change to 8MHz
this should allow us to work even with older chips. See the MPU6000
product specification, which says max 20MHz for sensor and interrupt
regs, and max 1MHz for all other regs
2013-10-13 11:03:06 +09:00
Andrew Tridgell
5ccf8409b4 AP_HAL: added an optional spi.set_bus_speed() API
this will be used by MPU6000 on APM2 to change speed after init
2013-10-13 11:03:04 +09:00
Andrew Tridgell
4dc2f4bd58 HAL_AVR: spi3 at 8mhz for mpu6k and ms5611 2013-10-13 11:03:02 +09:00
John Arne Birkeland
f6038f36bf HAL_AVR: Improved AVRTimer micros() and millis()
- More efficient code by using 16-bit timer
- micros() now has proper 1 us resolution and less overhead
- millis() has less overhead
- removed unneeded/unwanted initializatin of timers in AVRTimer::init()
2013-10-13 11:03:00 +09:00
Andrew Tridgell
5ba34b38c1 HAL_AVR: added specialised transfer functions for MPU6k and APM1 ADC
this saves quite a lot of time in interrupts
2013-10-13 11:02:57 +09:00
Andrew Tridgell
d60a68fd9c AP_Baro: check baro at exactly 100Hz
prevent waits for samples
2013-10-13 11:02:53 +09:00
Randy Mackay
499bc52c5b Perfmon: fixes to work with HAL 2013-10-13 11:02:49 +09:00
Andrew Tridgell
e34cc6dd9a HAL_PX4: added some UART debugging
this may help to track down USB issues
2013-10-13 12:43:25 +11:00
Andrew Tridgell
55ba536331 HAL_SITL: fixed a warning 2013-10-12 13:13:00 +11:00
Andrew Tridgell
84336bc74e AP_TECS: added initial flight_stage handling 2013-10-12 13:12:43 +11:00
Andrew Tridgell
2b80df6319 AP_SpdHgtControl: added FightStage parameter to update_pitch_throttle()
will be used for special landing handling
2013-10-12 13:12:16 +11:00
Andrew Tridgell
0f0b040891 AP_Camera: added set_trigger_distance() call 2013-10-11 21:37:27 +11:00
Andrew Tridgell
1c7a44a595 GCS_MAVLink: regenerate mavlink headers 2013-10-11 21:37:27 +11:00
Andrew Tridgell
8198bfe756 MAVLink: added MAV_CMD_DO_SET_CAM_TRIGG_DIST 2013-10-11 21:36:50 +11:00
Andrew Tridgell
63bee0b2d8 HAL_PX4: disable checks for in_timerprocess
these are not valid in this form for the way the timer thread works on
PX4.
2013-10-11 16:06:35 +11:00
Andrew Tridgell
25d3e5b7e9 AP_GPS: changed fake GPS fix to have a latitude/longitude
Pair-Programmed-With: Randy Mackay <rmackay9@yahoo.com>
2013-10-11 16:06:35 +11:00
Andrew Tridgell
ae1fd4baa4 HAL_AVR: reduce the latency of semaphore waits
this reduces the average cost of waiting for the MPU6000 semaphore
from the main loop
2013-10-10 15:41:51 +11:00
Andrew Tridgell
cfa1b5353f AP_Scheduler: show slips only for SCHED_DEBUG>1
this allows us to see PERF reports in copter without console writes
slowing things down
2013-10-10 15:41:34 +11:00
Andrew Tridgell
dd4b9275fd AP_Scheduler: improved the accuracy of the scheduling code
prevent accumulated micros() errors in run()
2013-10-10 14:14:39 +11:00
Randy Mackay
1a070e61f0 BattMon: amp-per-volt reduced to 17 (was 18.002) 2013-10-10 11:14:01 +09:00
Andrew Tridgell
eb0176d509 GCS_Console: don't build this example
it doesn't build any more
2013-10-10 09:54:20 +11:00
Andrew Tridgell
b3af59cc0c AP_InertialSensor: don't build L3G4200D example 2013-10-10 09:54:20 +11:00
Andrew Tridgell
fc7f3c8aa6 AP_HAL: fixed example build 2013-10-10 09:54:20 +11:00
Andrew Tridgell
a04c056598 AP_InertialSensor: remove unused get_last_sample_time_micros() 2013-10-10 09:54:19 +11:00
Craig3DRobotics
e5501bf911 AP_BattMonitor: Updated parameter descriptions 2013-10-09 15:33:03 -07:00
Andrew Tridgell
cd65e2109d AP_BattMonitor: fixed type in docs 2013-10-10 07:22:05 +11:00
Andrew Tridgell
0d682e74c1 HAL_Linux: run threads a bit more slowly
this was just wasting cycles
2013-10-10 07:21:38 +11:00
Andrew Tridgell
8f79a03c25 HAL_Linux: use larger UART buffers
might as well use the memory
2013-10-10 07:21:38 +11:00
Randy Mackay
13cf7c96cd GPSGlitch: parameters for accel and always-ok-radius 2013-10-09 13:02:14 +09:00
Andrew Tridgell
5d685385eb AP_InertialSensor: use gyro sample count on L3G4200D
this gives more even timing in ArduCopter
2013-10-08 19:20:34 +11:00
Andrew Tridgell
6444b0bddd AP_InertialSensor_L3G4200D: a sample is only available if gyro had a sample 2013-10-08 19:20:34 +11:00
Andrew Tridgell
e5e4cdee18 AP_InertialSensor: added wait_for_sample() API call
this waits for a new INS sample to arrive, using whatever method is
most efficient on each INS type
2013-10-08 17:31:15 +11:00
Andrew Tridgell
67db1cedaa HAL_PX4: fixed delay_microseconds() on PX4
we could underflow and delay a very long time!
2013-10-08 17:31:15 +11:00
Andrew Tridgell
f59d0099a4 AP_Notify: fixed RGBLED on PX4 with latest PX4Firmware
now needs a RGBLED_MODE_ON
2013-10-08 14:55:10 +11:00
Randy Mackay
9aea577eb1 BattMonitor: correct default pins for PX4 2013-10-08 10:28:48 +09:00
Andrew Tridgell
c17a5e5ed1 AP_InertialSensor: added a small delay in accel calibration
allows threads to run on Linux
2013-10-08 11:50:54 +11:00
Andrew Tridgell
1ccd6bb7ef AP_Compass: don't wait more than 1ms for compass sample
this prevents 5ms delays in compass accumulate
2013-10-08 11:50:54 +11:00
Andrew Tridgell
28b4ae1c3a HAL_Linux: improved latency of timed semaphores 2013-10-08 11:50:54 +11:00
Andrew Tridgell
6fa55d101f AP_Baro: fixed I2C semaphore handling for BMP085 driver 2013-10-08 11:50:54 +11:00
Andrew Tridgell
f286369990 AP_Compass: fixed orientation on Linux 2013-10-08 11:50:54 +11:00
Andrew Tridgell
83c942a512 AP_Compass: prevent NULL deref on enable mag while running 2013-10-08 11:50:53 +11:00
Andrew Tridgell
77e8061170 AP_Common: added product ID for L3G4200D 2013-10-08 11:50:53 +11:00
Andrew Tridgell
a216e1d239 HAL_Linux: don't prevent write while timer is busy
the timer can block on I2C writes, which causes the main loop to run
2013-10-08 11:50:53 +11:00
Andrew Tridgell
91511e6503 HAL_Linux: better realtime setup
lock all memory and pre-fault the stack in all threads
2013-10-08 11:50:53 +11:00
Andrew Tridgell
2422b94292 DataFlash: prevent valgrind errors from Empty driver 2013-10-08 11:50:53 +11:00
Andrew Tridgell
12af23bb7c AP_InertialSensor: added L3G4200D example 2013-10-08 11:50:53 +11:00
Andrew Tridgell
1aabd7155e AP_InertialSensor: added L3G4200D driver
this is for a cheap ebay 10DOF sensor
2013-10-08 11:50:53 +11:00
Andrew Tridgell
64c8cb4739 APM_Control: improved auto docs for AP_SteerController 2013-10-07 09:31:02 +11:00
Mike McCauley
84edbb335a AP_HAL_FLYMAPLE: UARTDriver now uses the new libmaple tx ring buffers
This requires the libmaple fork at
https://github.com/mikemccauley/libmaple.git
which includes low level support for buffered usart transmits
2013-10-07 08:41:53 +11:00
Mike McCauley
11317dcec4 AP_HAL_FLYMAPLE: FlymaplePortingNotes.txt improvements to install/build
documentation.
2013-10-07 08:41:53 +11:00
Mike McCauley
7f9d4a155f AP_HAL_FLYMAPLE: UARTDriver begin now honours txS == 0 which means no change 2013-10-07 08:41:52 +11:00
Mike McCauley
60921f7dfa AP_HAL_FLYMAPLE: Improved libmaple version detection 2013-10-07 08:41:52 +11:00
Andrew Tridgell
07b8f45770 HAL_Linux: use CLOCK_MONOTONIC_RAW to ensure clock never goes backwards
this avoids ntp mucking with APM timing
2013-10-07 08:41:52 +11:00
Andrew Tridgell
1518217952 HAL_FLYMAPLE: removed unused backend console code 2013-10-05 22:03:58 +10:00
Andrew Tridgell
de4d505f62 HAL_AVR: fixed examples build 2013-10-05 22:03:42 +10:00
Andrew Tridgell
487caea3a5 AP_Baro: added update_calibration() method
used for auto baro calibration when disarmed
2013-10-05 18:44:00 +10:00
Andrew Tridgell
7cab8cb3bb HAL_PX4: removed Console driver 2013-10-05 18:33:07 +10:00
Andrew Tridgell
b30f652cec HAL_Linux: removed Console driver 2013-10-05 18:32:57 +10:00
Andrew Tridgell
21f0086647 HAL_FLYMAPLE: removed Console driver 2013-10-05 18:32:46 +10:00
Andrew Tridgell
8e7d9bb464 HAL_Empty: removed Console driver 2013-10-05 18:32:35 +10:00
Andrew Tridgell
930d664677 AVR_SITL: removed Console driver 2013-10-05 18:32:23 +10:00
Andrew Tridgell
7072c52b57 HAL_AVR: removed Console driver 2013-10-05 18:32:12 +10:00
Andrew Tridgell
9f24c45502 AP_HAL: removed separate Console class
the idea of a separate console class was never really used, and just
added confusion in a HAL port. It also consumes some much needed ram
and flash space on APM2
2013-10-05 18:32:00 +10:00
Andrew Tridgell
39bfd809c2 APM_Control: disable integrator below minimum speed
this reduces the impact on initial takeoff
2013-10-05 18:11:35 +10:00
Andrew Tridgell
ad30f8effa HAL_PX4: try to reopen UARTs if safety switch is disarmed
this allows attaching to the USB port after power on

Pair-Programmed-With: Randy Mackay <rmackay9@yahoo.com>
2013-10-05 15:47:28 +10:00
Andrew Tridgell
34a328f66d AP_HAL: added safety_switch_state() function in hal.util
will be used by copter to check safety switch is set
2013-10-05 15:46:35 +10:00
Andrew Tridgell
58187ea449 APM_Control: change minspeed on steering controller to 1.0 2013-10-05 12:56:28 +10:00
Andrew Tridgell
5abf060c41 APM_Control: enable integrator in ACRO rate controller
this work better for unlocked mode
2013-10-05 07:42:48 +10:00
Andrew Tridgell
d27f5e89d7 APM_Control: remove public AP_PitchController::get_coordination_rate_of|cat() 2013-10-05 07:42:48 +10:00
Andrew Tridgell
bd848a6a7f APM_Control: added rate and angle steering controllers 2013-10-05 07:42:48 +10:00
Mike McCauley
72aa8a18ab AP_HAL_FLYMAPLE: update documentation in FlymaplePortingNotes.txt
Added info about where to get my patched version of libmaple.
2013-10-04 07:21:56 +10:00
Mike McCauley
6b003ae551 AP_HAL_FLYMAPLE: Fixed problem with tx buffer that caused slow parameter
delivery
2013-10-04 07:21:56 +10:00
Mike McCauley
c90c1b9998 AP_InertialSensor: Improvements to Flymaple sensors
Fix a bug that caused hang after 71 minutes. Use I2CDriver semaphore.
Remove test for in_accumulate: not needed.
2013-10-04 07:21:55 +10:00
Mike McCauley
39f9b7bbc9 AP_HAL_FLYMAPLE: Add test for correct version of libmaple
Patched version of libmapl is required for Flymaple I2Driver to work.
2013-10-04 07:21:55 +10:00
Mike McCauley
1f7272978c AP_HAL_FLYMAPLE: fix compile error in example AP_Baro_BMP085_test.pde
due to need for new library AP_Notify
2013-10-04 07:21:55 +10:00
Mike McCauley
2d3c86ee80 AP_HAL_FLYMAPLE: I2CDriver now uses low level hardware i2c librray from
libmaple

CAUTION: requires a patched version of libmaple, to be provided by mikem.
2013-10-04 07:21:55 +10:00
Mike McCauley
68a7cac9a2 AP_HAL_FLYMAPLE: Improvements to FLYMAPLEStorage
Fix a number of bugs and expand storage to an emulated 4kb, as needed by AP.
2013-10-04 07:21:55 +10:00
Mike McCauley
29707f4401 AP_HAL_FLYMAPLE: Modest speed improvements to I2CDriver
Can now achieve about 285kHz using bitbanging.
Proper low-level hardware I2C support has been written and stashed,
but has to wait until a bug in libmaple is addressed.
Ref: http://forums.leaflabs.com/topic.php?id=13458
2013-10-04 07:21:55 +10:00
Mike McCauley
9ea1108d4e AP_InertialSensor: Flymaple filter constructor arguments non non-zero 2013-10-04 07:21:55 +10:00
Randy Mackay
ecd4ed2277 GCS_MAVLink: generate mavlink includes 2013-10-03 22:12:58 +09:00
Randy Mackay
8aec70af1d GCS_MAVLink: add SYS_STATUS_SENSOR enum 2013-10-03 22:12:48 +09:00
Randy Mackay
688dd5374e ToshibaLED: flashing green if disarmed with GPS lock
solid blue if armed without GPS lock
2013-10-03 14:33:39 +09:00
Andrew Tridgell
7a9ed0a5a1 AP_GPS: fixed warning 2013-10-03 12:21:08 +10:00
Andrew Tridgell
86b58314c4 AP_Common: pack the RallyLocation structure
so it can be written as a single binary block
2013-10-03 12:21:08 +10:00
Michael Day
823a40c203 AP_Common: Added RallyLocation struct. 2013-10-03 12:21:08 +10:00
Michael Day
1777db91cb GCS_MAVLink: import latest upstream.
This add rally points.
2013-10-03 12:21:08 +10:00
Andrew Tridgell
99a8ba4634 DataFlash: fixed display of last page of flash logs 2013-10-03 12:21:08 +10:00
Andrew Tridgell
89f121ea77 DataFlash: wait for blocks to finish writing to flash on log read 2013-10-03 12:21:08 +10:00
Andrew Tridgell
8e0a136d78 HAL_AVR: mark some examples as not building 2013-10-03 12:21:08 +10:00
Andrew Tridgell
a250c13c79 HAL_PX4: fixed build 2013-10-03 12:21:08 +10:00
Andrew Tridgell
1440c8cebd HAL_Linux: implement a dummy console buffered write() 2013-10-03 12:21:08 +10:00
Andrew Tridgell
9624821493 HAL_FLYMAPLE: implement a dummy buffered write 2013-10-03 12:21:08 +10:00
Andrew Tridgell
a8c97f99d1 HAL_Empty: implement a dummy buffered write 2013-10-03 12:21:08 +10:00
Andrew Tridgell
c035eef845 HAL_SITL: implement a dummy buffered write 2013-10-03 12:21:07 +10:00
Andrew Tridgell
a59f505d25 HAL_AVR: implement an efficient buffer write() call for AVR
this saves some cycles in the telemetry code
2013-10-03 12:21:07 +10:00
Andrew Tridgell
efe1e01700 AP_HAL: require a buffer write() function in all ports
this makes a sufficient performance difference that it is worth it
2013-10-03 12:21:07 +10:00
Andrew Tridgell
5489097476 AP_GPS: update the UBLOX rates async from the start
this saves a bit of startup time
2013-10-03 12:21:07 +10:00
Andrew Tridgell
cee8a017ab AP_GPS: added UBLOX_FAKE_3DLOCK debugging option
useful when unable to get 3D lock
2013-10-03 12:21:07 +10:00
Andrew Tridgell
f1e120113c AP_Common: added OPTIMIZE() macro
this can be used to change the compiler optimization level of
individual functions

Pair-Programmed-With: Randy Mackay <rmackay9@yahoo.com>
2013-10-03 12:21:07 +10:00
Andrew Tridgell
fb19dbb404 AP_Math: cope with large values passed into the wrap functions
this uses modulus if the function would loop too many times

Pair-Programmed-With: Randy Mackay <rmackay9@yahoo.com>
2013-10-03 12:21:07 +10:00
Andrew Tridgell
34f7f88190 AP_GPS: check for corret GPS solution rates in flight and fix
if the GPS is giving us data at less than 300ms intervals then re-send
the configuration messages to try to kick it into the right rates

Pair-Programmed-With: Randy Mackay <rmackay9@yahoo.com>
2013-10-03 12:21:07 +10:00
Randy Mackay
db2975901d AP_HAL_AVR_SITL: use SIM_BATT_VOLTAGE parameter 2013-10-03 11:16:36 +09:00
Randy Mackay
8d1d8c78b5 SITL: add SIM_BATT_VOLTAGE 2013-10-03 11:16:35 +09:00
Randy Mackay
f1309ed63f BattMonitor: bug fix for current_total_mah 2013-10-03 11:16:24 +09:00
Randy Mackay
7d73e62a23 BattMonitor: add exhausted method
Current total calculations changed to use micros instead of millis for
improved accuracy
Removed unused pack_capacity accessor
Initialise private members
2013-10-03 11:16:19 +09:00
Randy Mackay
d9fe099885 BattMonitor: update comments and defaults 2013-10-03 11:16:17 +09:00
Andrew Tridgell
366d73124a AP_Battery: fixed parameter name and default voltage ratio
also setup SITL with right pins
2013-10-03 11:16:15 +09:00
Andrew Tridgell
c7df0eaf2a SITL: added battery voltage and current
assume 3DR brick
2013-10-03 11:16:14 +09:00
Andrew Tridgell
88777beab0 AP_BattMonitor: minor cleanups
cleanup name to be multiplier not div ratio, and make 2 variables
non-static
2013-10-03 11:16:10 +09:00
Randy Mackay
8b06a12fa4 BattMonitor: initial draft lib 2013-10-03 11:16:01 +09:00
Andrew Tridgell
42bc8b12df SITL: added a SIM_GPS_HZ option
this allows simulation of slow GPS updates (for example, the 1Hz GPS
problem)
2013-10-01 16:39:16 +10:00
Andrew Tridgell
c9fea2c706 HAL_Linux: fixed scheduling priorities
need to be between 1 and 99
2013-10-01 13:05:04 +10:00
Andrew Tridgell
134bf5a5c9 AP_Menu: be friendly to multi-tasking OSes in menus 2013-10-01 13:04:40 +10:00
Andrew Tridgell
2819dd99fa AP_Menu: copy with newline from console
helps debugging on HAL_Linux
2013-10-01 13:00:48 +10:00
Andrew Tridgell
bbac3265b2 HAL_Linux: default to hal.console on stdout 2013-10-01 12:49:58 +10:00
Andrew Tridgell
bcc9cdbf43 HAL_Linux: make I2CDriver more portable
this allows it to build on the Beaglebone
2013-10-01 12:37:13 +10:00
Andrew Tridgell
51c19331a6 HAL_Linux: fixed build 2013-10-01 12:11:48 +10:00
Andrew Tridgell
e60d5d4f33 AP_Airspeed: fixed some warnings 2013-09-30 21:06:43 +10:00
Andrew Tridgell
d83dbb38b4 AP_ADC: updates for AP_HAL::MemberProc 2013-09-30 21:06:42 +10:00
Andrew Tridgell
2095b2a2d7 AP_Airspeed: updates for AP_HAL::MemberProc 2013-09-30 21:06:42 +10:00
Andrew Tridgell
c04d9b0c03 AP_Baro: updates for AP_HAL::MemberProc 2013-09-30 21:06:42 +10:00
Andrew Tridgell
a86bb15a05 DataFlash: updates for AP_HAL::MemberProc 2013-09-30 21:06:42 +10:00
Andrew Tridgell
b178ad7344 AP_OpticalFlow: updates for AP_HAL::MemberProc 2013-09-30 21:06:42 +10:00
Andrew Tridgell
dda68bddcb AP_InertialSensor: updates for AP_HAL::MemberProc 2013-09-30 21:06:42 +10:00
Andrew Tridgell
942ae70651 HAL_PX4: updates for AP_HAL::MemberProc 2013-09-30 21:06:42 +10:00
Andrew Tridgell
f2ebb2ca87 HAL_Linux: updates for AP_HAL::MemberProc 2013-09-30 20:56:15 +10:00
Andrew Tridgell
82fe40224b HAL_AVR_SITL: updates for AP_HAL::MemberProc 2013-09-30 20:56:15 +10:00
Andrew Tridgell
a2b879493d HAL_Empty: updates for AP_HAL::MemberProc 2013-09-30 20:56:15 +10:00
Andrew Tridgell
c27a61f210 HAL_FLYMAPLE: updates for AP_HAL::MemberProc 2013-09-30 20:56:15 +10:00
Andrew Tridgell
6d58f5e188 HAL_AVR: updates for AP_HAL::MemberProc 2013-09-30 20:51:20 +10:00
Andrew Tridgell
f2de4bb7b0 AP_HAL: implement AP_HAL::MemberProc via FastDelegate.h
this provides a more portable way to encapsulate member functions in
variables
2013-09-30 20:51:13 +10:00
Andrew Tridgell
0784c01f19 APM_Control: added STEER2SRV_MINSPD
this is the assumed min speed when in STEERING or AUTO mode
2013-09-30 09:05:37 +10:00
Andrew Tridgell
53f66b23f4 AP_HAL_Linux: fixed APM2 build 2013-09-29 14:24:55 +10:00
Andrew Tridgell
1698e1800c HAL_Linux: timer calls may block on HAL_Linux
timer calls can do SPI transfers, which can block
2013-09-29 10:48:22 +10:00
Andrew Tridgell
5102f1511b HAL_Linux: fixed callbacks from delay() 2013-09-29 10:32:51 +10:00
Andrew Tridgell
a1ef1a9318 HAL_Linux: tweak the scheduling priorities 2013-09-29 12:04:37 +10:00
Andrew Tridgell
d3fe625742 HAL_Linux: make the SPI driver much more efficient
use a single transaction for multiple bytes. This makes the APM1
Oilpan driver generate only 2 interrupts per sensor read
2013-09-29 12:04:36 +10:00
Andrew Tridgell
7067569103 HAL_PX4: fixed end() on UARTs 2013-09-29 12:04:36 +10:00
Andrew Tridgell
1e786b3e20 HAL_Linux: added buffering on the UARTs 2013-09-29 12:04:36 +10:00
Andrew Tridgell
605e6c3cf7 HAL_Linux: use pthread mutexes for semaphores 2013-09-29 07:49:30 +10:00
Andrew Tridgell
30b6b23b10 AP_ADC: enable APM1 ADC on Linux 2013-09-29 00:57:13 +10:00
Andrew Tridgell
1191607036 AP_InertialSensor: enable Oilpan on Linux 2013-09-29 00:57:13 +10:00
Andrew Tridgell
884af71ef6 HAL_Linux: added SPI support 2013-09-29 00:57:13 +10:00
Andrew Tridgell
8a699f6189 AP_Baro: enable BMP085 on Linux 2013-09-28 22:04:15 +10:00
Andrew Tridgell
8ee848a788 AP_AHRS: update for Stub -> HIL 2013-09-28 22:04:15 +10:00
Andrew Tridgell
350af4d92f HAL_AVR_SITL: updates for InertialSensor 2013-09-28 22:04:15 +10:00
Andrew Tridgell
cf726c6642 AP_InertialSensor: rename Stub to HIL
more consistent with other drivers
2013-09-28 22:04:15 +10:00
Andrew Tridgell
dd081ab23b AP_Notify: enable toshibaled on all I2C capable platforms 2013-09-28 22:04:15 +10:00
Andrew Tridgell
291369db7f AP_Airspeed: split up airspeed driver
this gives us separate backends for PX4, analog and I2C. This allows
the MS airspeed sensor to work on Linux, and it should work on APM2 as well.
2013-09-28 21:24:03 +10:00
Andrew Tridgell
f03315237a HAL_Linux: fixed timer scheduler 2013-09-28 21:24:03 +10:00
Andrew Tridgell
20b1131059 AP_Baro: use new scheduler API 2013-09-28 21:24:03 +10:00
Andrew Tridgell
6134d9d0d7 AP_ADC: use new scheduler API 2013-09-28 21:24:03 +10:00
Andrew Tridgell
19e9c95983 DataFlash: use new scheduler API 2013-09-28 21:24:03 +10:00
Andrew Tridgell
f53afaa5ac AP_OpticalFlow: use new scheduler API 2013-09-28 21:24:03 +10:00
Andrew Tridgell
03036c632d AP_InertialSensor: use new scheduler API 2013-09-28 21:24:03 +10:00
Andrew Tridgell
7ec242146d HAL_PX4: update for new scheduler API 2013-09-28 21:24:03 +10:00
Andrew Tridgell
cca59ce3c9 HAL_Linux: update for new scheduler API 2013-09-28 21:24:02 +10:00
Andrew Tridgell
1d820761be HAL_FLYMAPLE: updates for new scheduler API 2013-09-28 21:24:02 +10:00
Andrew Tridgell
6bc4a830ac HAL_Empty: updates for new scheduler API 2013-09-28 21:24:02 +10:00
Andrew Tridgell
c08f29fca6 HAL_AVR_SITL: updates for new scheduler API 2013-09-28 21:24:02 +10:00
Andrew Tridgell
0ade02a624 HAL_AVR: updates for new scheduler API 2013-09-28 21:24:02 +10:00
Andrew Tridgell
f0f5761e8d AP_HAL: make timed processes take void *argument
this allows the class to be passed in, meaning that drivers that use
register_timer_process() and register_io_process() don't need to use
static members. That results in simpler, easier to read code
2013-09-28 21:24:02 +10:00
Andrew Tridgell
49d3d624d7 DataFlash: enabled DataFlash_File for Linux 2013-09-28 21:24:02 +10:00
Andrew Tridgell
bcf4f48e65 HAL_Linux: switched to pthread based scheduling 2013-09-28 21:24:02 +10:00
Andrew Tridgell
da14ad2e2d AP_Compass: neaten up HMC5883 debug 2013-09-28 21:24:02 +10:00
Andrew Tridgell
ce7d458855 AP_Compass: added Linux support to the compass test 2013-09-28 21:24:02 +10:00
Andrew Tridgell
6fc5b06043 AP_Compass: fixed some old Serial.print calls 2013-09-28 21:24:02 +10:00
Andrew Tridgell
58a31318ee AP_HAL_Linux: initial I2C driver implementation
this works sufficiently for the HMC5883
2013-09-28 21:24:02 +10:00
Andrew Tridgell
6b95d870ad AP_Progmem: only AVR uses progmem
no need to list all other boards
2013-09-28 21:24:02 +10:00
Andrew Tridgell
1f3a051e7b AP_Progmem: Linux doesn't use progmem 2013-09-28 21:24:02 +10:00
Andrew Tridgell
018b8fde95 AP_Notify: blank Linux LED defines 2013-09-28 21:24:02 +10:00
Andrew Tridgell
1243ab9e63 AP_Compass: added HAL_Linux support 2013-09-28 21:24:02 +10:00
Andrew Tridgell
296417a228 AP_HAL: added AP_HAL_LINUX define 2013-09-28 21:24:01 +10:00
Andrew Tridgell
4ba044c441 AP_HAL_Linux: initial Linux AP_HAL 2013-09-28 21:24:01 +10:00
Andrew Tridgell
096660c4f9 AP_InertialSensor: mark flymaple as nobuild
won't build with build_examples.sh script
2013-09-27 16:57:13 +10:00
Mike McCauley
e4eef61ec3 AP_InertialSensor: Flymaple sensors improvements
Flymaple sensors are now raw sampled at 800Hz, and LowPassFilter2p is used
to filter to the desired filter cutoff frequency.
Flymaple sensor polling is done in the main thread NOT in the timer
interrupts.
2013-09-27 15:45:59 +10:00
Mike McCauley
23429b6b9c AP_InertialSensor: Flymaple now polls sensors at 800Hz. More changes to
come...
2013-09-27 15:45:57 +10:00
Mike McCauley
29bced05bd AP_InertialSensor: Added examples/Flymaple for testing 2013-09-27 15:45:54 +10:00
Mike McCauley
d11f952ef1 AP_InertialSensor: Formalise and document Flymaple Gyro scaling factor 2013-09-27 15:45:52 +10:00
Mike McCauley
db2b7ed4e3 AP_HAL_FLYMAPLE: UARTDriver libmaple internal ring buffers enlarge on demand 2013-09-27 15:45:49 +10:00
Mike McCauley
adfcdca074 AP_HAL_FLYMAPLE: Sensor reading improvements
I2C speed increased to 400kHz
Accelerometer 8g max, Normal power, 800Hz bandwidth
Gyros: 2000 degrees/sec, 256Hz LPF, 8kHz internal sample rate
2013-09-27 15:45:47 +10:00
Randy Mackay
f7ba0438ef InertialSensor: remove DMP
this saves 3K of flash
2013-09-27 10:43:33 +09:00
Randy Mackay
8306d74da0 AHRS: remove DMP as an ahrs 2013-09-27 10:42:46 +09:00
Andrew Tridgell
14636e1cdf AP_InertialSensor: changed num_samples_available() to sample_available()
this makes the interface clearer. It also fixes a 3D accel cal bug.
2013-09-27 10:49:00 +10:00
Andrew Tridgell
99da118faa Filter: added in Leonards LowPassFilter2p filter
this is a backport from PX4
2013-09-26 22:38:32 +10:00
Andrew Tridgell
3c86fceed9 AP_Progmem: removed SMACCM support 2013-09-26 22:38:32 +10:00
Andrew Tridgell
2469dcf8e6 AP_Notify: removed SMACCM support 2013-09-26 22:38:31 +10:00
Andrew Tridgell
1ec5cbed81 AP_InertialSensor: removed SMACCM support 2013-09-26 22:38:31 +10:00
Andrew Tridgell
60f3a8b6cf AP_HAL: removed SMACCM support 2013-09-26 22:38:31 +10:00
Andrew Tridgell
3f0f8dfa62 AP_Compass: removed SMACCM support 2013-09-26 22:38:31 +10:00
Andrew Tridgell
13cdc56a5a AP_Common: removed SMACCM support 2013-09-26 22:38:31 +10:00
Andrew Tridgell
58f9349af4 HAL_SMACCM: removed SMACCM HAL port
this port is no longer maintained or used. Pat asked me to remove it
2013-09-26 22:38:31 +10:00
Randy Mackay
f144de21b4 AC_Fence: fix example sketch 2013-09-26 17:52:13 +09:00
Randy Mackay
e5c5084e76 InertialNav: fix example sketch 2013-09-26 14:40:32 +09:00
Mike McCauley
708c603420 AP_HAL_FLYMAPLE: UARTDriver now has correct implementation of txspace that looks at HardwareSerial ring buffer 2013-09-25 15:46:07 +10:00
Mike McCauley
e4b5d0a3d6 AP_InertialSensor: Final Flymaple orientation fixes 2013-09-25 15:46:07 +10:00
Mike McCauley
276068356e AP_InertialSensor: Further Flymaple orientation fixes 2013-09-25 15:46:07 +10:00
Mike McCauley
06478bde52 AP_HAL_FLYMAPLE: Console is now a thin wrapper around uartA, consistent with AVR 2013-09-25 15:46:07 +10:00
Mike McCauley
b02dbca9d4 AP_InertialSensor: fix orientation of Flymaple sensors 2013-09-25 15:46:07 +10:00
Mike McCauley
4cd952446d AP_HAL_FLYMAPLE: added documentation about safety of noInterrupts()/interrupts() 2013-09-25 15:46:07 +10:00
Randy Mackay
ab71f2e535 AP_Camera: remove unused methods
throttle_pic, distance_pic and transistor_pic were not defined nor
called
2013-09-24 23:25:54 +09:00
Randy Mackay
cddbaf0459 GPS_Glitch: make accessor functions const 2013-09-24 21:41:56 +09:00
Randy Mackay
55c94b3b41 GPS_Glitch: bug fix for enable/disable parameter 2013-09-24 21:41:54 +09:00
Randy Mackay
54cb815fec AP_Notify: add gps glitching and failsafe flags 2013-09-24 21:41:51 +09:00
Randy Mackay
a2c0415ba9 GPS_Glitch: make enable/disable a parameter 2013-09-24 21:41:42 +09:00
Randy Mackay
78124f2fca GPS_Glitch: remove unused recovered flag 2013-09-24 21:41:38 +09:00
Randy Mackay
90953a96e5 ToshibaLED: flash blue-yellow for gps failsafe and glitch 2013-09-24 21:41:25 +09:00
Randy Mackay
4bac26171b AP_Notify: add gps_glitch flag 2013-09-24 21:41:22 +09:00
Randy Mackay
262fcb301a InertialNav: rename set_current_position to set_home_position 2013-09-24 21:41:19 +09:00
Randy Mackay
81dd4f8b0c InertialNav: integrate GPS glitch detection 2013-09-24 21:41:13 +09:00
Randy Mackay
4dcfce7104 GPS_Glitch: glitch detection class 2013-09-24 21:41:10 +09:00
Randy Mackay
c6a99ac24a AutoTest: add support for GPS glitching 2013-09-24 21:41:04 +09:00
Andrew Tridgell
c1d56f74b5 AP_Common: change flymaple product ID to 0x100
keep it well away from the Invensense product IDs for the MPU6000
2013-09-24 13:51:28 +10:00
Mike McCauley
7850d1f2ce AP_Progmem: Add Flymaple support 2013-09-24 13:51:28 +10:00
Mike McCauley
b7e182e056 AP_Notify: Add flymaple LED definitions 2013-09-24 13:51:28 +10:00
Mike McCauley
4d10a96077 AP_InertialSensor: Add flymaple support 2013-09-24 13:51:27 +10:00
Mike McCauley
ec5425578e AP_HAL: Added Flymaple board 2013-09-24 13:33:25 +10:00
Mike McCauley
8f61a36e58 AP_Common: Flymaple compatibility 2013-09-24 13:33:25 +10:00
Mike McCauley
e3c20f06ac AP_Baro: Chnages to flymaple port.
Flymaple has no EOC pin
2013-09-24 13:33:25 +10:00
Mike McCauley
c1d3bedb60 AP_Airspeed: changes for Flymaple port pins and caibration constants 2013-09-24 13:33:25 +10:00
Mike McCauley
9bfc52d9af HAL_FLYMAPLE: initial port to flymaple board
See libraries/AP_HAL_FLYMAPLE/FlymaplePortingNotes.txt
2013-09-24 13:32:50 +10:00
Mike McCauley
2fa0c39f3a AP_Compass: added Flymaple orientation 2013-09-24 13:18:35 +10:00
Andrew Tridgell
37ad9e3f82 PID: fixed example build 2013-09-24 11:57:21 +10:00
Andrew Tridgell
d64660739e AP_OpticalFlow: fixed example build 2013-09-24 11:57:14 +10:00
Andrew Tridgell
448167e958 AP_GPS: fixed examples build 2013-09-24 11:57:03 +10:00
Andrew Tridgell
af2d7232c5 APM_Control: make the default time constant 0.75
thanks to Tom for the testing!
2013-09-24 07:37:12 +10:00
Andrew Tridgell
770b7b5901 AP_InertialSensor: prevent a lockup in MPU6000 driver
thanks to the VRBrain port for noticing this bug.

Failing to get the semaphore is an expected error with the MPU6000, as
we read data both from timer context and mainline code. That means
semaphore conflicts are inevitable. We shouldn't consider them an
error, and shouldn't panic when some arbitrary number of them have
happened since boot.

Instead the wait_for_sample() code checks that we receive new data at
least every 50ms. That is a much safer test.
2013-09-23 22:48:36 +10:00
Andrew Tridgell
36ea705956 AP_OpticalFlow: fixed build with print() API change 2013-09-23 18:10:22 +10:00
Andrew Tridgell
0e9aef7e52 AP_HAL: changed base defines for print()
this avoids a conflict with wirish from libmaple
2013-09-23 18:10:21 +10:00
Mike McCauley
2e061fc507 AP_Param: Fix compiler warning on Flymaple 2013-09-23 18:10:21 +10:00
Mike McCauley
4c65c42411 AP_Compass: fixed ARM 32 bit compatibility 2013-09-23 18:10:21 +10:00
Andrew Tridgell
87bb3bc5dc AP_HAL: added AP_HAL_PX4 define 2013-09-22 16:02:42 +10:00
Andrew Tridgell
21010104e6 AP_HAL_Empty: added register_io_process() 2013-09-22 16:02:05 +10:00
Andrew Tridgell
928e06f52c AP_HAL: use fabs() in print
fixes build on Arduino
2013-09-22 13:18:40 +10:00
Andrew Tridgell
45d9140946 AP_HAL_SMACCM: updates for new API 2013-09-22 12:22:15 +10:00
Andrew Tridgell
40af9ab674 AP_HAL_PX4: updates for new API 2013-09-22 12:22:05 +10:00
Andrew Tridgell
d0bb998352 AP_HAL_Empty: updates for new API 2013-09-22 12:21:54 +10:00
Andrew Tridgell
dbb70fc57c AP_HAL_AVR_SITL: implement betterstream functions in AP_HAL
this gives more consistancy between ports
2013-09-22 12:21:22 +10:00
Andrew Tridgell
33fe27a104 AP_HAL_AVR: implement betterstream functions in AP_HAL
this gives more consistancy between ports
2013-09-22 12:21:11 +10:00
Andrew Tridgell
d46f5f6943 AP_HAL: implement betterstream functions in AP_HAL
this gives more consistancy between ports
2013-09-22 12:20:59 +10:00
Michael Oborne
54fc004956 SITL: fix sitl timer issues under cygwin 2013-09-21 22:06:38 +10:00
Andrew Tridgell
fc119d9b80 AP_Baro: cleaned up temperature and pressure units
thanks to Mike McCauley for pointing this out
2013-09-21 21:30:41 +10:00
Andrew Tridgell
7de47931a8 DataFlash: use %f not %.6f 2013-09-21 15:48:39 +10:00
Andrew Tridgell
16a7faa223 AP_Param: use %f not %.6f for param show 2013-09-21 15:45:19 +10:00
Andrew Tridgell
0d662c52b3 AP_HAL: fixed length return from snprintf 2013-09-21 15:45:05 +10:00
Andrew Tridgell
0063f1fad8 AP_HAL: added Util.cpp
common printf functions
2013-09-21 14:25:42 +10:00
Andrew Tridgell
05b426c1fc HAL_PX4: use common printf implementation on UARTs 2013-09-21 14:23:52 +10:00
Andrew Tridgell
f5c0f765fc AP_HAL_SMACCM: use common printf implementation 2013-09-21 14:23:13 +10:00
Andrew Tridgell
b9d6f8e8b1 AP_HAL_AVR: removed unused script 2013-09-21 13:30:02 +10:00
Andrew Tridgell
85b3f0d18d AP_HAL: expanded printf test suite 2013-09-21 13:29:52 +10:00
Andrew Tridgell
e12a4178f3 AP_HAL_SMACCM: convert to new AP_HAL printf 2013-09-21 13:29:40 +10:00
Andrew Tridgell
80e2a5cc32 AP_HAL_PX4: convert to new AP_HAL printf 2013-09-21 13:29:32 +10:00
Andrew Tridgell
4c1925b578 AP_HAL_Empty: convert to new AP_HAL printf 2013-09-21 13:29:22 +10:00
Andrew Tridgell
bb44fa4385 AP_HAL_AVR_SITL: convert to new AP_HAL printf 2013-09-21 13:29:12 +10:00
Andrew Tridgell
60122f9877 AP_HAL: moved printf implementation from AP_HAL_AVR to AP_HAL
this gives a common printf implementation on all boards, which
simplifies testing, and also simplifies porting to new boards
2013-09-21 13:28:46 +10:00
Andrew Tridgell
4ad4b60fbc HAL: added Printf test sketch
for testing new non-asm printf code
2013-09-21 11:16:08 +10:00
Andrew Tridgell
16a0dfc38c HAL_AVR: changed to C implementation of float formatting
Many thanks to Soren Kuula for this work!
2013-09-21 11:16:08 +10:00
Randy Mackay
4b18c670e3 DataFlash: explicitly print floats to 6 dec places
C++ default is to print 6 decimal places but nuttx displays none by
default
2013-09-20 22:13:02 +09:00
Randy Mackay
3f84e0adf6 AP_Param: explicitly print floats to 6 dec places
C++ default is to print 6 decimal places but nuttx displays none by
default
2013-09-20 22:12:33 +09:00
Andrew Tridgell
4d2bfe1078 AP_InertialSensor: fixed another example build 2013-09-19 21:09:34 +10:00
Andrew Tridgell
e1aa6e3ff1 libraries: fixed examples for no flash_leds() callback 2013-09-19 18:38:28 +10:00
Andrew Tridgell
f8e9d48a76 AP_InertialSensor: removed the flash_leds() callback
AP_Notify now handles this
2013-09-19 18:32:19 +10:00
Andrew Tridgell
66ee484b3c AP_Notify: convert to unix style file 2013-09-19 16:27:31 +10:00
Andrew Tridgell
445edb8793 GCS_MAVLink: remove CR/LF 2013-09-19 16:27:14 +10:00
Andrew Tridgell
18896d9c9b AP_Math: fixed DOS CR/LF errors 2013-09-19 16:26:32 +10:00
Andrew Tridgell
cf633e4d79 AP_HAL: convert to unix file format 2013-09-19 16:26:14 +10:00