Commit Graph

14676 Commits

Author SHA1 Message Date
Andrew Tridgell
1a25087dd5 AC_AttitudeControl: fixed PIRO_COMP index
this is a new conflict due to stricter checking in AP_Param
2017-08-14 09:28:57 +09:00
Michael du Breuil
58e784024f AP_HAL_SITL: Add support for blocked pitot tube simulations 2017-08-10 20:15:35 +10:00
Michael du Breuil
4dbe282121 SITL: Add airspeed failure parameters 2017-08-10 20:15:35 +10:00
priseborough
2310cb6d19 AP_NavEKF3: Enable external control over use of GPS vertical velocity 2017-08-10 19:49:45 +10:00
priseborough
f2f3067326 AP_NavEKF2: Add interface to control GPS vertical velocity use 2017-08-10 19:49:45 +10:00
Mark Whitehorn
3642ecd9ef AP_COMPASS: fix errors in addition of alternate LIS3MDL I2C address
testing shows ROTATION_YAW_90 is correct for mRo Neo M8N GPS/compass
2017-08-10 19:46:26 +10:00
Mark Whitehorn
a6e9baa8f6 AP_Compass: probe for LIS3MDL in mRo Neo-M8N GPS module 2017-08-10 19:46:26 +10:00
Peter Barker
1fc82442a0 GCS_MAVLink: remove dummy functions; examples are linked with all libs 2017-08-09 16:18:22 +01:00
Peter Barker
7aaabea4ea GCS_MAVLink: send gps messages as separate queued messages 2017-08-09 16:18:22 +01:00
Peter Barker
ee5874ab32 GCS_MAVLink: move sending of gps_raw up 2017-08-09 16:18:22 +01:00
Peter Barker
4e3cc6fd27 GCS_MAVLink: move sending of system_time up 2017-08-09 16:18:22 +01:00
Peter Barker
d1a9128118 GCS_MAVLink: move sending of camera_feedback up 2017-08-09 16:18:22 +01:00
Peter Barker
d03c7389f7 GCS_MAVLink: move sending of meminfo up 2017-08-09 16:18:22 +01:00
Michael du Breuil
5fca7d02b3 AdvancedFailsafe: Rework status texts to be more uniform 2017-08-09 15:39:17 +01:00
Peter Barker
127edce39e AP_RangeFinder: move prearm checks into backend 2017-08-09 13:58:53 +01:00
Peter Barker
0b1c67d170 AP_RangeFinder: remove unused parameters from detect and constructors 2017-08-09 13:58:53 +01:00
Peter Barker
08cd3f4a77 AP_RangeFinder: move instance parameters into instance state 2017-08-09 13:58:53 +01:00
Randy Mackay
f995106c1e AC_PID: minor formatting change 2017-08-09 18:03:09 +09:00
Peter Barker
a841fddb3e GCS_MAVLink: rename MSG_RETRY_DEFERRED to MSG_LAST and clarify comments 2017-08-05 23:13:48 +01:00
Peter Barker
0c5f66dc59 GCS_MAVLink: refactor code into new retry_deferred method 2017-08-05 23:11:09 +01:00
Peter Barker
fdac13d3d3 GCS_MAVLink: tidy send_message function 2017-08-05 23:09:37 +01:00
Randy Mackay
164096225b AP_SteerController: fix get_steering_out_rate bug when reversing 2017-08-05 11:20:58 +09:00
Randy Mackay
638ba02d5f AP_Mission: add support for Set-Yaw-Speed command
This is initially only intended for use by Rover
2017-08-05 11:20:58 +09:00
Randy Mackay
42cab6b533 AP_LandingGear: add startup position selection parameter 2017-08-05 11:20:41 +09:00
Francisco Ferreira
e0f4d3dbe5
AP_HAL: remove unused HAL_AIRSPEED_MS4515DO_I2C_BUS macro 2017-08-05 03:15:53 +01:00
Francisco Ferreira
d3ed4420e6
AP_Airspeed: remove unused MS4525D0_I2C_BUS macro 2017-08-05 03:15:52 +01:00
Vinicius Juvinski
78deddabda AP_Airspeed: MS4525: Add support to I2C Bus 2
BBBMini use I2C Bus number 2 and MS4525 just use up to bus 1, so I
addedd this bus 2 to address struct.
2017-08-05 03:15:32 +01:00
José Roberto de Souza
9ee007f924 AP_HAL_PX4: Map PX4_I2C_BUS_EXPANSION1 2017-08-04 12:47:01 -07:00
José Roberto de Souza
e674d6ee20 AP_HAL_PX4: aeorfc: Move GPS to UART7
The UART3 also have the I2C bus 2 functions so moving GPS to UART7 to
have one additional I2C.
To keep GPS working is also necessary update the FPGA RTL to version
0xC1 or higher.
2017-08-04 12:47:01 -07:00
Francisco Ferreira
6cf8791eb5
AP_Compass: correct comment in LIS3MDL driver
Commit 17f2393c1b decreased timer frequency but didn't change comment to match
2017-08-04 19:56:26 +01:00
Lucas De Marchi
5ea1784838 global: remove AP_HAL::in_timerprocess()
This is not used and in the only places it would make sense would be
internally to the scheduler so remove it.
2017-08-03 20:25:14 -07:00
Lucas De Marchi
08637f1dcc AP_HAL_VRBRAIN: Scheduler: replace use of in_timerprocess()
This function actually checks if we are not in the main thread rather
than if we are in the timer thread.

Add a new function that does what it's supposed to do.
2017-08-03 20:25:11 -07:00
Lucas De Marchi
1aaba01622 AP_HAL_QURT: Scheduler: replace use of in_timerprocess()
This function actually checks if we are not in the main thread rather
than if we are in the timer thread.

Add a new function that does what it's supposed to do.
2017-08-03 20:25:07 -07:00
Lucas De Marchi
9e66938f68 AP_HAL_PX4: Scheduler: replace use of in_timerprocess()
This function actually checks if we are not in the main thread rather
than if we are in the timer thread.

Add a new function that does what it's supposed to do.
2017-08-03 20:25:01 -07:00
Lucas De Marchi
93a558ce5c AP_HAL_Linux: do not call delay callbacks on other threads
If a thread other than the main one calls Scheduler::delay() we could
end up triggering the call of delay callbacks. Those should only ever
happen on the main thread.
2017-08-03 20:24:57 -07:00
Peter Barker
ad2c3d27ec GCS_MAVLink: move try_send_message queued_param_send up 2017-08-03 14:34:33 +01:00
Peter Barker
679bb7f7a5 GCS_MAVLink: move try_send_message send_hwstatus up 2017-08-03 14:33:37 +01:00
Peter Barker
3b472ccc17 GCS_MAVLink: move try_send_message mission handling up 2017-08-03 14:24:47 +01:00
Peter Barker
b8cb758fac GCS_MAVLink: move try_send_message compass message handling up 2017-08-03 14:24:46 +01:00
Lucas De Marchi
e98fe2d7d5 AP_HAL: RingBuffer: add missing include 2017-08-02 21:10:55 -07:00
Lucas De Marchi
61aed0f0d7 RingBuffer: example: integrate with build system
It's only compatible with Linux so for now disable the other boards.
2017-08-02 16:08:55 -07:00
Murilo Belluzzo
641671a366 AP_HAL: Add simple stress test for RingBuffer class
It runs a Producer/Consumer thread pair endless reading and writing a
ByteBuffer. Producer writes a number sequence that is twice the
ByteBuffer size so a given position have a different data on each write
pass. Consumer makes sure that this pattern is not broken and aborts the
program if it is.

It is possible to spawn more pairs by informing a number as argument of
the program.
2017-08-02 15:30:35 -07:00
Lucas De Marchi
dbd074b250 AP_HAL: remove register_timer_process with extra arg 2017-08-02 08:00:53 -07:00
Lucas De Marchi
c170c2a847 AP_HAL_Linux: remove register_timer_process with extra arg
This is not used anymore.
2017-08-02 08:00:53 -07:00
Lucas De Marchi
6bab28397a AP_Compass: remove user of timesliced logic 2017-08-02 08:00:53 -07:00
Lucas De Marchi
0a158f6d3f AP_HAL_Linux: remove support for timesliced timer
This has long been replaced by the bus per thread scheme.
2017-08-02 08:00:53 -07:00
ljwang
5a7ec7d429 Delete write registers at start,using another way to repair 2017-08-02 16:15:14 +10:00
ljwang
648871a388 Fixed the QMC5883 identification,add check ID 2017-08-02 16:15:14 +10:00
Peter Barker
b445313bf1 AP_Scheduler: remove loop-period argument from load_average
This now comes from a parameter rather than being hard-set
in the vehicle code

Also adds a method returning the max loop period based on the
loop rate
2017-08-01 19:39:27 +01:00
Michael du Breuil
efe70c8d3a AP_NavEKF3: Fix possible compass nullptr dereference 2017-08-01 15:25:05 +01:00
Michael du Breuil
dffa3d3b40 AP_NavEKF2: Fix possible compass nullptr dereference 2017-08-01 15:25:05 +01:00
Andrew Tridgell
99f5229a34 SRV_Channel: added copy_radio_in_out_mask() 2017-08-01 08:25:32 +10:00
Andrew Tridgell
1f1b4241c3 SRV_Channel: added get/set for reversed and function
these are needed in plane for auto-conversion of old elevon code
2017-08-01 08:25:32 +10:00
Andrew Tridgell
75999dbb39 SRV_Channel: prevent negative slew rate
thanks to Michael for pointing this out
2017-08-01 08:25:32 +10:00
khancyr
15398f8b0e AP_Math: correct variable init and remove define in polygon 2017-07-31 17:35:08 +09:00
Randy Mackay
f5f6ec5238 AP_Arming: rename _MIN_VOLT to _VOLT_MIN
Also _MIN_VOLT2 to _VOLT2_MIN
2017-07-31 17:19:55 +09:00
Randy Mackay
2f3a57e0aa AP_Arming: minor variable type change
no functional change
2017-07-31 17:19:55 +09:00
Randy Mackay
330a6065ca AP_Arming: Copter gets MIN_VOLT parameters 2017-07-31 17:19:55 +09:00
Michael du Breuil
2894b7cbea L1_Control: Ensure that LIM_BANK passes a sea level sanity check
This fixes #6637 where the LIM_BANK can be set such that the vehicle demands a radius at sea level that is much higher then the loiter radius was configured to be. This effectively feels like a fly away and is due to bad parameters usually. If this happens just fall back to the simple EAS2TAS scaling of the radius.
2017-07-30 12:42:21 -07:00
Peter Barker
975d2fd0d1 DataFlash: add debug for io thread failure 2017-07-28 17:06:49 +01:00
Peter Barker
b4688bd3d4 GCS_MAVLink: move common mavlink camera handling up 2017-07-28 14:32:58 +01:00
Peter Barker
bb06b02df6 AP_Camera: add const to some parameters 2017-07-28 14:32:58 +01:00
Peter Barker
a94bf851eb AP_Camera: use multiplication in place of division 2017-07-28 14:27:53 +01:00
Peter Barker
9390539231 AP_Camera: tidy up usage of trigger_pic 2017-07-28 14:27:53 +01:00
Peter Barker
84ef63edc7 AP_Camera: camera is responsible for taking distance-based-images and logging 2017-07-28 14:27:53 +01:00
Peter Barker
7f59279670 AP_GPS: make time_epoch_usec const 2017-07-28 14:27:53 +01:00
priseborough
db7c8439c6 AP_NavEKF3: Fix bug in wheel odometry timestamp correction 2017-07-28 12:48:38 +09:00
Matt
5b605d6e1c AP_Notify: Fix for Oreo LED gyro init inidication
If parameter INS_GYRO_CAL is disabled, usually because operator is
arming on a moving vehicle such as a boat, the Oreo LEDs would wait
indefinitely for a gyro calibration that will never happen.  This
removes that dependency.  The LEDs will strobe blue only when gyros are
actually initializing. Not before.  Consequently, this greatly
simiplifies that portion of the code.
2017-07-27 20:43:58 +09:00
khancyr
f583121433 AC_Fence: reset fences breach on disable
Also rename enable function parameter
2017-07-27 20:41:40 +09:00
Peter Barker
e7ff5107fb AP_GPS: tidy mavlink message handling using switch statement 2017-07-27 12:03:25 +01:00
Peter Barker
2ad453fc89 AP_GPS: handle inject packets as part of handle_msg 2017-07-27 12:03:25 +01:00
Peter Barker
60ffe00164 GCS_MAVLink: move gps inject handling up
Also, make AP_GPS responsible for decoding inject packets
2017-07-27 12:03:25 +01:00
priseborough
c7f6d52065 AP_NavEKF3: Add wheel encoder odometry
Uses the existing body frame odometry observation model.
Handles each sensored wheel as a separate sensor.
2017-07-27 16:52:27 +09:00
priseborough
cbe8f97489 AP_NavEKF3: rename struct used for velocity odometry observations
Do this so we can add other odometry observation types.
2017-07-27 16:52:26 +09:00
priseborough
08a3f55c90 AP_NavEKF3: Fix error in scaling of observation error 2017-07-27 16:52:25 +09:00
priseborough
593437ca95 AP_NavEKF3: Add tuning of visual odometry observation error
Also adjust default values based on replay analysis.
2017-07-27 16:52:25 +09:00
Randy Mackay
eaf8aad5ad AP_WheelEncoder: last_reading is last update time instead of system time 2017-07-27 14:19:08 +09:00
Randy Mackay
2c7b9d9cf7 AP_WheelEncoder: add get_delta_angle
The total angular change measured by the wheel encoder in radians
2017-07-27 14:19:08 +09:00
Randy Mackay
a53e254bd0 AP_WheelEncoder: replace scaling with CPR and radius
CPR is the wheel encoder's counts per revolution of the wheel
radius is the radius of the wheel in meters
2017-07-27 14:19:08 +09:00
Randy Mackay
cd71984705 AP_WheelEncoder: 3d position offset 2017-07-27 14:19:08 +09:00
Randy Mackay
1ddf38869a AP_AHRS: set AP_Notify gps_glitching flag 2017-07-27 14:16:23 +09:00
Randy Mackay
0d5c98ad45 AP_Notify: add gps glitch notification 2017-07-27 14:16:23 +09:00
Randy Mackay
9123b6034e SRV_Channel: update_aux_servo_function first checks function is valid
This resolves a bug in which the board could become unresponsive if an invalid function is selected
2017-07-27 11:09:57 +09:00
Patrick José Pereira
1eeea82e31 AP_Parachute: Add function to return _release_in_progress status
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2017-07-26 17:51:34 +01:00
Randy Mackay
572df8b859 SRV_Channel: minor formatting fixes
no functional change
2017-07-26 13:28:07 +09:00
Randy Mackay
298eaaeb3e SRV_Channels: rename SERVO_DEF_RATE to SERVO_RATE 2017-07-26 13:28:07 +09:00
Randy Mackay
687ec98e5d AP_HAL_PX4: set default servo update rate only when changed
This removes the chance a small switch occurring whenever this function is called
2017-07-26 13:28:07 +09:00
Peter Barker
85a0da6178 GCS_MAVLink: handle common GPS messages in base GCS_MAVLINK class 2017-07-25 14:00:45 +01:00
Randy Mackay
a657daf635 Compass: disable QMC5883 compass driver by default
This driver causes occasional heading issues so disabling until these are resolved
2017-07-25 09:27:29 +09:00
khancyr
2d0bce18a8 AP_Baro: rename all local variable with prefix
fix last missing spaces
2017-07-24 10:15:15 -07:00
khancyr
35ac86ff8d AP_Baro: fix some style and const correctness 2017-07-24 10:15:15 -07:00
khancyr
0e895f5c74 AP_Baro: fix instance shadowing 2017-07-24 10:15:15 -07:00
khancyr
42516f7079 DataFlash: simplify Log_Write_Proximity 2017-07-24 13:44:43 +01:00
khancyr
8abcb7a0e3 GCS_MAVLink: simplify send_proximity 2017-07-24 13:44:43 +01:00
khancyr
603621f2c4 DataFlash: move proximity log from Copter (NFC) 2017-07-24 13:44:43 +01:00
khancyr
ec2ea1c903 GCS_MAVLink: move send_proximity to GCS common code (NFC)
Also clean two comments
2017-07-24 13:44:43 +01:00
Andrew Tridgell
4ca3546551 SRV_Channel: added SERVO_DEF_RATE parameter
this allows for the default rate of servo outputs to be set. This is
needed for some planes where 50Hz isn't enough (eg. tailsitters)
2017-07-24 14:07:28 +10:00
Andrew Tridgell
5b43698e25 HAL_PX4: added rcout set_detault_rate() 2017-07-24 14:07:28 +10:00
Andrew Tridgell
0188d6463d AP_HAL: added rcout set_detault_rate() 2017-07-24 14:07:28 +10:00
Kevin Lopez Alvarez
df406c4389 AP_Compass : increase max possible offset 2017-07-24 13:48:20 +10:00