Commit Graph

12505 Commits

Author SHA1 Message Date
Andrew Tridgell
95f00b4891 AP_Param: avoid a notify if value is already correct 2016-12-20 20:18:20 +09:00
Leonard Hall
e1d5b23144 AP_MotorsMulticopter: fix battery resistance calculation 2016-12-20 20:17:35 +09:00
Georgii Staroselskii
e421e95782 AP_BattMonitor: add default PM definitions for Navio boards
As it turns out we haven't had default PM defs for power modules
intended to be used with Navio boards.
2016-12-20 20:16:53 +09:00
Ivan Smirnov
8c67a3fbd2 AP_HAL_Linux: Scheduler: added _timer_tick for uartD 2016-12-07 10:25:10 -08:00
Andrew Tridgell
d9b3b7a9b5 AP_BoardConfig: increase uavcan bus settle time to 2s
needed to ensure zubax mag has time to come up
2016-12-01 12:59:12 +09:00
Leonard Hall
7c6bdfb95c AC_AttControl: allow MOT_THR_MIX_MAX to be 2.0
The parameter description maximum of 0.9 should keep most users from
setting this parameter above 0.9 but there are rare cases for very high powered copters with low hover-throttle values where setting as high as 2.0 improves attitude control
2016-12-01 12:58:48 +09:00
priseborough
b4784d8204 AP_NavEKF2: Fix bug in reporting of vertical position reset
Fixes a bug that allows the last reported reset time to to wind back and an out of date reset delta to be reported if a switch to a core that has previously been reset occurs.
Allows multiple consumers provided they access on the same frame.
2016-12-01 12:55:32 +09:00
priseborough
56262f44f4 AP_NavEKF2: Fix bug in reporting of horizontal position reset
Fixes a bug that allows the last reported reset time to to wind back and an out of date reset delta to be reported if a switch to a core that has previously been reset occurs.
Allows multiple consumers provided they access on the same frame.
2016-12-01 12:55:29 +09:00
priseborough
7c9d2b6ca7 AP_NavEKF2: Fix bug in reporting of yaw reset
Fixes a bug that allows the last reported reset time to to wind back and an out of date reset delta to be reported if a switch to a core that has previously been reset occurs.
Allows multiple consumers provided they access on the same frame
2016-12-01 12:55:26 +09:00
Leonard Hall
297dbbe22f AC_AttControl: do not limit rate if ATC_ACCEL_MAX param is zero 2016-12-01 12:54:50 +09:00
ShingoMatsuura
8c3f7832d2 AP_RangeFilnder: moved the const buffer definition to the header and changed from '8' to 'sizeof(send_request_buffer)' 2016-12-01 12:54:39 +09:00
ShingoMatsuura
d70f89cb67 AP_RangeFilnder: change send_request_buffer member variable to const and other fixes 2016-12-01 12:54:36 +09:00
ShingoMatsuura
714ae5213d AP_RangeFilnder: add clear buffer at INIT state and change send_buffer to member variable to reduce CRC computation for sending request 2016-12-01 12:54:32 +09:00
ShingoMatsuura
dad1432e9e AP_RangeFinder: remove clear buffer in send_request 2016-12-01 12:54:29 +09:00
Randy Mackay
1cfd178e2f AP_NavEKF2: minor comment fix 2016-12-01 12:53:44 +09:00
Randy Mackay
2bee6f55f3 AC_WPNav: remove ekf position reset handler
This has been migrated to the position control library
2016-12-01 12:53:38 +09:00
Randy Mackay
c01467c285 AC_PosControl: add ekf position reset handling
Previously this was in AC_WPNav and used only for loiter but it should work for any flight modes that use horizontal or vertical position control
2016-12-01 12:53:35 +09:00
Randy Mackay
17c06b40b8 AP_AHRS: add getLastPosDownReset accessor 2016-12-01 12:53:30 +09:00
Randy Mackay
327c2b8b9d AC_WPNav: remove unused _loiter_step member 2016-12-01 12:53:25 +09:00
priseborough
9bfbe4c80a AP_NavEKF2: Fix errors in position reset delta publishing 2016-12-01 12:53:22 +09:00
priseborough
52eac34d66 AP_NavEKF2: capture and publish vertical position reset deltas
Calculate the change in vertical position due to a internal EKF state reset or a EKF core switch
2016-12-01 12:53:19 +09:00
priseborough
8a34df6528 AP_NavEKF2: Reduce unnecessary EKF core switching
1) Do not switch to a core until its states have been updated.
2) Distinguish between mandated switches required for health failure and optional switches required due to innovation checks failing.
3) Apply hyseresis to innovation check levels
2016-12-01 12:53:16 +09:00
Alexey Bulatov
fc577120c1 AP_Compass: make LSM9DS1 compass primary for Navio2 2016-11-30 12:10:43 -08:00
Alexey Bulatov
67dd4d3efe AP_Compass: fix rotation for LSM9DS1 compass
Move rotation to the right place. Otherwise live calibration and onboard
calibration show different results.
2016-11-30 12:10:43 -08:00
Lucas De Marchi
bed521e2b5 AP_Compass: Calibrator: use inplace initializer on array
(cherry picked from commit c6b0a71c47)
2016-11-21 16:10:14 -02:00
Siddharth Bharat Purohit
73c83f630a AP_Compass: fix wrong memset in compass calibrator
(cherry picked from commit b36ee10e7c)
2016-11-21 16:10:14 -02:00
Siddharth Bharat Purohit
b71f766aff AP_AccelCal: fix bug preventing accel cal fit to run more than one iteration
The check for fitness being smaller than the last value should use the
absolute value, to mean the fitness isn't changing since last iteration.
It's currently always quiting the function after the first iteration.

However for Gauss Newton we anyway want to run as many iterations as we
can, because there are ups and downs along the iteration so we might get
say best result where before and after iterations were bad. The lines
above takes care that sane and the best is selected.

(cherry picked from commit 451c2f146d)
2016-11-21 16:10:14 -02:00
Michael Oborne
5f505a0f37 AP_GPS_SBF: fix accuracy reported by driver 2016-11-16 09:16:47 +09:00
Michael du Breuil
4d8053afc9 Compass: Rework compass calibrator
Summary of significant changes:
  -Autsave doesn't depend on STREAM_EXTRA3
  -Don't risk only saving one compass on copter if CAL_ALWAYS_REBOOT is set
  -Only calibrate compasses that are both health and marked for use (there was a inconsistency in handling the mask)
  -Fix incorrect failure reporting on DO_ACCEPT_MAG_CAL with a mask of 0 if a channel was specifically not started
  -Fix not starting the buzzer if the delay is set to 0 seconds
  -Always send MAG_CAL_REPORT until its acknowledged
  -Correct the field in MAG_CAL_REPORT for autosave to indicate if the compass had actually been saved, rather then being scheduled to be saved
  -Remmove unused public interfaces
2016-11-07 13:07:59 +09:00
Randy Mackay
67bbf486fc AP_GPS: fix MAV compile error 2016-11-07 12:39:08 +09:00
Randy Mackay
0c54025e82 AP_GPS: MAV driver uses existing baud rates
GPS_INPUT messages can arrive through any mavlink serial port so we shouldn't be modifying any port's baud rates.
2016-11-07 12:38:58 +09:00
Leonard Hall
f4605b863c AC_PosControl: set Alt_Hold filter for PID not just D
We normally don't use the D term here so setting the filter for PID not
just D lets us smooth the throttle response.
2016-11-07 12:37:49 +09:00
Shingo Matsuura
6abe6448d6 AP_RangeFinder: change enum name, add "state" word 2016-11-07 12:36:15 +09:00
Shingo Matsuura
98ba554fdc AP_RangeFinder: change comment about fall through LEDDARONE_MODBUS_INIT case 2016-11-07 12:36:12 +09:00
Shingo Matsuura
22a2067375 AP_RangeFinder: add comment about no break at LEDDARONE_MODBUS_INIT case 2016-11-07 12:36:09 +09:00
Shingo Matsuura
05723ee4f5 AP_RangeFinder: remove case indent 2016-11-07 12:36:05 +09:00
Shingo Matsuura
c348a6d0fe AP_RangeFinder: change magic numbers to define 2016-11-07 12:36:02 +09:00
Shingo Matsuura
5b5c482e55 AP_RangeFinder: remove break in LEDDARONE_MODOBUS_INIT case and and use () around (read_len == 0) for clarity 2016-11-07 12:35:59 +09:00
Shingo Matsuura
023c613196 AP_RangeFinder: modified regarding to advices from @magicrub - san. 2016-11-07 12:35:57 +09:00
Shingo Matsuura
47d8e96f06 AP_RangeFinder: fixed LeddarOne busy wait 2016-11-07 12:35:53 +09:00
Peter Barker
9dd4755084 AP_ADSB: do not transmit by default
In various countries transmitting on the ADSB frequencies is a
federal offence.

Let's not have our users do that be default.
2016-11-07 12:33:23 +09:00
Michael Oborne
5e63abf431 AP_GPS_SBF: change reported altitude from geoid to MSL 2016-11-07 12:33:14 +09:00
Andrew Tridgell
a494b2fd73 AP_RangeFinder: disabled LeddarOne driver
this driver is broken and could cause a vehicle to crash. It does busy
waits on a UART from the main thread.

It will be re-enabled when fixed
2016-10-31 11:58:47 +09:00
Francisco Ferreira
5a7f9a38fe DataFlash: fix RCIN and RCOU structure types 2016-10-26 10:10:19 +09:00
murata
762a66c9e5 AP_GPS_SBF: Adjust the initial value of HDOP 2016-10-26 09:54:59 +11:00
Peter Barker
2bd13af43d AP_Param: unhide groups when generating parameters in autotest 2016-10-26 09:53:14 +11:00
Peter Barker
dd7d41b1f3 SITL: unhide groups when generating parameters in autotest 2016-10-26 09:53:14 +11:00
Andrew Tridgell
d2287caf1c HAL_SITL: removed old servo slew rate code 2016-10-25 20:39:38 +11:00
Andrew Tridgell
5e03358b0b SITL: added servo filtering
SIM_SERVO_SPEED is servo time constant in seconds
2016-10-25 20:39:38 +11:00
Lucas De Marchi
539b727e5e AP_HAL_Linux: Remove misleading constant
The constant passed to cflag is BOTHER, meaning the actual baud is set
in the other specific members.  Don't define B* constants as they are
misleading here and this is why it doesn't work with e.g.
cfset[io]speed()... that function expect a B* constant which in Linux
is not the speed, but an index to an array with speeds.
2016-10-25 16:55:33 +11:00