Commit Graph

6170 Commits

Author SHA1 Message Date
bugobliterator
34ba77e048 HAL_Linux: Correct faulty RCOutput driver
solve compiler not looking ahead of RCOutput class for read and write methods
2014-07-14 09:10:23 +10:00
bugobliterator
26cd4ad237 HAL_Linux: Correct indentation 2014-07-14 09:10:23 +10:00
Siddharth Bharat Purohit
69a4b7d632 HAL_Linux: Correct Indentation issue 2014-07-14 09:10:23 +10:00
Siddharth Bharat Purohit
731d80e6c5 HAL_Linux: Add Steps to Manually test pwm channels 2014-07-14 09:10:13 +10:00
Siddharth Bharat Purohit
b53b3f415a HAL_Linux: Create Readme.md adding details on manually testing pru pwm 2014-07-14 09:10:03 +10:00
bugobliterator
a7de5e3d0f HAL_Linux: Add initial RCOutput driver
The functions in RCOutput.cpp are defined to access PWM over PRU sysfs
device from userspace using open, read, write and close methods.
2014-07-14 09:09:53 +10:00
Víctor Mayoral Vilches
3354fa9fc8 AP_HAL_Linux: Add support for SPIDevice_MS5611 2014-07-14 09:02:47 +10:00
Víctor Mayoral Vilches
1c07985518 AP_InertialSensor_MPU9150: Comment the suspend_timer_procs
It causes the driver to hang. This matter should be inspected.
2014-07-14 09:02:47 +10:00
Víctor Mayoral Vilches
d65aefbef5 AP_InertialSensor_MPU6000: Fix the test code so that compiles. 2014-07-14 09:02:47 +10:00
Víctor Mayoral Vilches
9797867067 AP_Baro_MS5611: Fix the test code so that compiles.
Add HAL_BOARD_LINUX and HAL_BOARD_ERLE compatibility.
2014-07-14 09:02:47 +10:00
Víctor Mayoral Vilches
9f5b4ffca4 AP_HAL_Linux_Class: Correct deadlock, and infinite loop in setup()
(credit to Mitch Miers <mmiers@mmiers.com>):

setup() is attempting to initialize the hardware, and while doing so
is attempting to output some text via the console (and maybe mavlink
data).  The problem is, the output isn't going to complete once a
write buffer is full, because LinuxUARTDriver::_timer_tick() doesn't
perform work until _initialized is true.  So, what happens is,
setup() (and subroutines) call LinuxUARTDriver::_write(uint8_t c),
which loops waiting for buffer space to become available (once the
write buffer is full).  The buffer never gets space, because the
UART thread is waiting for initialization to complete before it
will write out data and drain the buffer, but that doesn't happen
until setup() returns (see AP_HAL_Linux_main.h).

Refer to https://groups.google.com/forum/#!topic/beaglepilot/dQlxse11JNI
2014-07-14 09:02:47 +10:00
Víctor Mayoral Vilches
fac3d1c271 AP_InertialSensor_MPU9250: SPI userspace sensor driver.
InvenSense MPU9250 sensor driver and test code (available under
libraries/examples/).
2014-07-14 09:02:47 +10:00
Víctor Mayoral Vilches
27ebf790e2 AP_HAL_Linux: Add support for SPIDevice_MPU9250
The Invensense MPU9250 SPI device is connected to
SPI1, thereby SPIDriver class should return the
corresponding device.
2014-07-14 09:02:46 +10:00
Víctor Mayoral Vilches
5493be1b0d AP_HAL: Add SPIDevice_MPU9250 as a device. 2014-07-14 09:02:46 +10:00
Víctor Mayoral Vilches
815c2df2d0 AP_HAL_Linux: SPIDriver, add MPU6000 support 2014-07-14 08:52:51 +10:00
Víctor Mayoral Vilches
4d79887cc5 L3G4200D: fix in the test example provided.
The test coded had a call to "wait_for_sample" that expected one
argument and 0 where provided.
2014-07-14 08:52:51 +10:00
Andrew Tridgell
74ee70d463 HAL_Linux: updates for ERLE board type 2014-07-14 08:52:27 +10:00
Andrew Tridgell
ab7e96b9de AP_InertialSensor: updates for ERLE board type 2014-07-14 08:51:44 +10:00
Victor Mayoral Vilches
44320708a7 AP_InertialSensor_MPU9150: I2C userspace driver sensor added.
The MPU9150 is a 9 axis sensor that includes 3 accelerometers,
3 gyroscopes and 3 magnetometers. All accessible through I2C.
The AP_InertialSensor_MPU9150 class allows APM to use this sensor.
2014-07-14 08:16:29 +10:00
Victor Mayoral Vilches
1445781104 AP_Common: added fire cape product ID 2014-07-14 08:16:29 +10:00
Randy Mackay
7e04b5d1f1 INS: calibrated method checks all accelerometers 2014-07-13 22:05:21 +09:00
Jonathan Challinger
762bb3e6e8 AC_AttitudeControl: Limit _pos_target.z to below alt_max before computing error 2014-07-13 21:14:34 +09:00
Andrew Tridgell
28fedba4d8 AP_AHRS: fixed gyro_bias sign, and pre-calculate gyro_estimate for EKF
this allows us to return a constant vector for the corrected gyro
estimate. Based on discussions with Jon Challinger
2014-07-13 21:56:39 +10:00
Jonathan Challinger
966d66ef40 AP_AHRS_NavEKF: use gyro drift states from EKF in get_gyro 2014-07-13 21:34:44 +10:00
Jonathan Challinger
61987f6655 AP_AHRS: Fixed DCM get_gyro function
Previously incorporated the attitude correction terms into the return. Now only returns the drift-corrected gyro.
2014-07-13 21:19:29 +10:00
Jonathan Challinger
5f66027ba3 AC_AttitudeControl: Fixup some minor mistakes in AC_PosControl 2014-07-13 17:17:31 +09:00
Robert Lefebvre
92bdf24dba AP_MotorsHeli: Add To-Do. Swash setup hasn't seemed to work right for a while, this might be why. Confirm later. 2014-07-13 17:11:22 +09:00
Robert Lefebvre
a7f6a91827 AC_AttitudeControl_Heli: Remove ToDo. Rate controllers should always run even if throttle is zero. 2014-07-13 17:11:20 +09:00
Randy Mackay
f630f9abc3 GPS: exclude SIRF and NMEA on APM copter build
This only works for the centralised builder, the modified Arduino IDE
will still include the NMEA and SIRF drivers meaning it will require
approximately 4k additional flash which may push us over the limit on
the APM2.  Users will instead need to exclude other features to get
below the APM1/2 flash limit.
2014-07-13 15:41:11 +09:00
Andrew Tridgell
ddb030088d GCS_Mavlink: moved some more mavlink functions to GCS_Common.cpp 2014-07-13 15:37:49 +10:00
Randy Mackay
971411e0db AC_AttControl: fixed typo in parameter description 2014-07-13 10:31:11 +09:00
Randy Mackay
5f623ac859 AC_AttControl: re-enable rate feedforward by default
Roll and Pitch rate controllers became sluggish without feed-forward
enabled.
2014-07-11 15:31:00 +09:00
Randy Mackay
bbf4805b0e Compass: update pixhawk expected device ids 2014-07-11 11:10:18 +09:00
Craig Elder
c9f3adcb5c Compass: Updated COMPASS_PRIMARY parameter description 2014-07-10 15:32:06 -07:00
Craig Elder
0ecd12b1c6 AP_Compass: Corrected typo in parameter description
Corrected typo in parameter description
2014-07-10 14:19:19 -07:00
Randy Mackay
fa2f5d9c68 Arming: accept non-const compass in constructor
The compass.configured() method checks the eeprom and cannot be const
meaning the Arming object requires a non-const reference to the compass.
Removed check for null compass because the compass object is always
created although this could lead to unnecessary pre-arn check failures
even though compass-use is set to false.
2014-07-10 22:50:52 +09:00
Randy Mackay
4995b9ada8 Compass: default device id to zero 2014-07-10 20:25:36 +09:00
Randy Mackay
16d4af8346 Compass: sanity check instance in set_and_save_offsets 2014-07-10 20:25:32 +09:00
Randy Mackay
76369d153f Arming: use compass.configured method
This checks that when compass offset learning is off, that the offsets
are non-zero and that the detected device id matches the device id
stored to eeprom when the offsets were last saved.
2014-07-10 20:25:30 +09:00
Randy Mackay
cf7e1a6339 Compass: example sketch update for set_and_save_offsets 2014-07-10 20:25:13 +09:00
Randy Mackay
a778522cef Compass: add learn_offsets_enabled accessor method 2014-07-10 20:25:11 +09:00
Randy Mackay
108c878b04 Compass: set_offsets modified to also save offsets 2014-07-10 20:25:08 +09:00
Randy Mackay
124bd4b489 Compass: save_offsets accepts compass instance 2014-07-10 20:25:05 +09:00
Randy Mackay
2c1fa5f1e8 GCS_MAVLink: generate after adding deprecated note to SET_MAG_OFFSETS 2014-07-10 20:25:02 +09:00
Randy Mackay
798c749833 GCS_MAVLink: add deprecated note to SET_MAG_OFFSETS 2014-07-10 20:25:00 +09:00
Randy Mackay
05225636da GCS_MAVLink: generate after adding second mag to PREFLIGHT_SET_SENSOR_OFFSETS 2014-07-10 20:24:58 +09:00
Randy Mackay
bf6fd6f984 GCS_MAVLink: add second mag to PREFLIGHT_SET_SENSOR_OFFSETS
Updates the comments for parameter 1 only, this does not affect the
message format.
2014-07-10 20:24:55 +09:00
Randy Mackay
070f1c1bbb Compass: add dev_id for VRBrain 2014-07-10 20:24:49 +09:00
Randy Mackay
f42c9579d7 Compass: add dev_id for PX4
dev_id is retrieved from PX4Firmware via ioctl call
2014-07-10 20:24:46 +09:00
Randy Mackay
b7f33d81ad Compass: add DEV_ID param and configured method
These allow checking the offsets were created with the current compass
device.
2014-07-10 20:24:44 +09:00
svefro
be9bfc5530 Mount: set_mode method made public 2014-07-10 13:03:43 +09:00
Andrew Tridgell
d325f630e5 VibTest: added sample timing to console output 2014-07-09 12:12:23 +10:00
Andrew Tridgell
8af876fe8a AC_AttitudeControl: fixed build
includes are case sensitive on the build server
2014-07-09 10:19:17 +10:00
Andrew Tridgell
863e7a5f93 VibTest: fixed array bounds error 2014-07-09 08:11:52 +10:00
Andrew Tridgell
2c8240dbb4 VibTest: fixed gyro timestamps in logs
it was using the accel timestamps
2014-07-09 08:10:09 +10:00
Robert Lefebvre
789b1018fc AP_MotorsHeli: Change set_delta_phase_angle so that it forces recalculation of collective factors. 2014-07-08 20:18:39 +09:00
Robert Lefebvre
fd542e99d8 AP_MotorsHeli: Create Delta Phase Angle variable and method to set. Will be used by CCComp code. 2014-07-08 20:18:34 +09:00
Robert Lefebvre
0680b88abd AP_MotorsHeli: Add main loop rate time variable and method. Change RSC increment calc to account for loop rate time. 2014-07-08 20:18:20 +09:00
Robert Lefebvre
26be7aed97 AC_AttControl_Heli: Add LPF filter to Rate Feedforward terms 2014-07-08 20:18:13 +09:00
Robert Lefebvre
fa9d625e39 AC_HELI_PID: Add feedforward accessor functions. 2014-07-08 20:18:05 +09:00
Robert Lefebvre
979abb9fbd TradHeli: Cause DDVP Tail Motor to stop immediately when Ch8 is 0. 2014-07-08 20:18:02 +09:00
Andrew Tridgell
b2bc098aee HAL_PX4: avoid some float conversion warnings 2014-07-08 20:27:19 +10:00
Andrew Tridgell
e137bf26ef HAL_Empty: avoid some float conversion warnings 2014-07-08 20:27:13 +10:00
Andrew Tridgell
59de5a8465 AP_GPS: avoid some float conversion warnings 2014-07-08 20:27:03 +10:00
Andrew Tridgell
74c3b404ee AP_Baro: avoid some float conversion warnings 2014-07-08 20:26:54 +10:00
Andrew Tridgell
6b87c9fdf7 AP_Airspeed: avoid some float conversion warnings 2014-07-08 20:26:44 +10:00
Andrew Tridgell
f28946defb AP_ADC_AnalogSource: avoid some float conversion warnings 2014-07-08 20:26:37 +10:00
Andrew Tridgell
198ada2b42 APM_Control: avoid some float conversion warnings 2014-07-08 20:26:20 +10:00
Andrew Tridgell
baa0217bec AP_RangeFinder: trigger a new reading automatically
this fixes Maxbotix I2C
2014-07-08 16:28:18 +10:00
Andrew Tridgell
f6d9bc5d7e AP_RangeFinder: fixed detection of multiple types
Pair-Programmed-With: Allyson Kreft
2014-07-08 15:08:18 +10:00
Andrew Tridgell
7ceb14bec0 HAL_Empty: make I2C ops fail 2014-07-08 15:08:18 +10:00
Andrew Tridgell
9386295428 AP_RangeFinder: added SONAR2_TYPE parameter
thanks to Allyson for noticing
2014-07-08 15:08:18 +10:00
Andrew Tridgell
05d4f5fb5a AP_RangeFinder: convert PX4 driver to new API 2014-07-08 15:08:18 +10:00
Andrew Tridgell
4cba48ade2 AP_RangeFinder: removed old style analog drivers
replaced by generic analog driver
2014-07-08 15:07:51 +10:00
Andrew Tridgell
ed346fd639 AP_RangeFinder: convert MaxbotixI2C driver to new API 2014-07-08 15:07:51 +10:00
Andrew Tridgell
0063d83dbc AP_RangeFinder: convert the PulsedLight driver to new API
not tested yet
2014-07-08 15:07:50 +10:00
Andrew Tridgell
22b9059647 AP_RangeFinder: have two instances on all platforms
rover needs two sonars for obstacle avoidance
2014-07-08 15:07:50 +10:00
Andrew Tridgell
e69a473315 SITL: update simulated sonar support 2014-07-08 15:07:50 +10:00
Andrew Tridgell
6f33ca4988 AP_RangeFinder: added SONAR_RMETRIC option
this allows correct support for non-ratiometric rangefinders such as
the SF/02
2014-07-08 15:07:50 +10:00
Andrew Tridgell
92b76b4be4 AP_RangeFinder: converted analog rangefinder backend to new API
this gets analog rangefinders of all types working
2014-07-08 15:07:50 +10:00
Andrew Tridgell
cb037f3416 AP_RangeFinder: new rangefinder API ready for its first backend
the backends are setup to have just the minimum functionality needed
for a rangefinder, with all of the higher level logic in the
frontend. This should make writing a new backend easier
2014-07-08 15:07:50 +10:00
Andrew Tridgell
429431157b AP_RangeFinder: disable old rangefinder drivers
these will be re-enabled when they are converted to the new class API
2014-07-08 15:07:50 +10:00
akdslr
d759a9dd9b AP_RangeFinder: Seperated the Backend driver functionality into a separate class 2014-07-08 15:07:49 +10:00
akdslr
3f17969b19 AP_RangeFinder: Changes from the May 4th plane test flight 2014-07-08 15:07:49 +10:00
akdslr
2e586ccfb2 AP_RangeFinder_PulsedLightLRF: Updated the value to write to the register to trigger a measurement 2014-07-08 15:07:49 +10:00
akdslr
5f4168d5f8 AP_RangeFinder_PX4_test: Added an example sketch for the PX4 range finder 2014-07-08 15:07:49 +10:00
akdslr
18c06277f8 AP_RangeFinder: Added a new PX4 range finder and modified the RangeFinder parent class to support having multiple devices simultaneously 2014-07-08 15:07:49 +10:00
akdslr
a2df275bd9 AP_RangeFinder_PulsedLightLRF: Updated the register definitions for the new hardware 2014-07-08 15:07:49 +10:00
Andrew Tridgell
e118984c26 AP_Baro: save some flash and memory on APM2
we don't need the I2C MS5611 driver
2014-07-08 14:21:42 +10:00
Andrew Tridgell
d50d5b8f24 VibTest: fixed sample count output on console 2014-07-08 10:59:30 +10:00
Andrew Tridgell
03770c4d34 VibTest: added gyro data and support 3 sensors
will be used for vibration testing on FMUv3
2014-07-08 10:07:58 +10:00
Randy Mackay
2b64c511ed AC_WPNav: update yaw only when track is at least 2m 2014-07-06 17:02:12 +09:00
Randy Mackay
c9661cfb09 AC_WPNav: integrate set_desired_velocity_xy function name change 2014-07-06 17:01:10 +09:00
Randy Mackay
82ed70b25e AC_PosControl: add xyz velocity controller
Velocity controller interpretsthe velocity requests as
desired velocities (i.e. feed forward).  These are then used to update
the target position and also added to the target velocity.
Also renamed the set_desired_velocity() function to
set_desired_velocity_xy() to make clear only lat and lon axis are
updated.
2014-07-06 17:01:02 +09:00
Randy Mackay
fe8a5be802 AP_Mission: support MAV_CMD_NAV_VELOCITY msg 2014-07-06 17:01:00 +09:00
Randy Mackay
34b91496f9 GCS_MAVLink: generate after adding CMD_NAV_VELOCITY 2014-07-06 17:00:57 +09:00
Randy Mackay
35167c262e GCS_Mavlink: add MAV_CMD_NAV_VELOCITY
This is an earth frame velocity request message
2014-07-06 17:00:55 +09:00
Randy Mackay
9103899048 GCS_Common: minor typo in comments 2014-07-06 17:00:52 +09:00
Randy Mackay
f4c9d58051 AP_Mission: add support for MAV_CMD_NAV_GUIDED 2014-07-06 17:00:26 +09:00
Randy Mackay
be003c1906 GCS_MAVLink: generate after adding CMD_NAV_GUIDED 2014-07-06 17:00:24 +09:00
Randy Mackay
05c63592ce GCS_MAVLink: add CMD_NAV_GUIDED to ardupilotmega.xml 2014-07-06 17:00:21 +09:00
Andrew Tridgell
c138244155 AP_Compass: support 3 mags on PX4 2014-07-04 12:07:47 +10:00
Emile Castelnuovo
b420a5c6db AP_HAL_VRBRAIN: removed empty lines 2014-07-03 11:09:20 +10:00
Niels Joubert
fabd7601f0 GPS: Fix dataflash logging bug in SBP driver 2014-07-03 09:57:10 +10:00
Niels Joubert
b57d1f5245 GPS: Include 75-class CPUs in RTK support since they will have 64 bit floating point values. 2014-07-03 09:57:07 +10:00
Andrew Tridgell
849c4905fb HAL_PX4: print overtime message on stuck task
this should make it easier to narrow down stuck task bugs
2014-07-03 09:11:24 +10:00
Andrew Tridgell
67f5ba0b94 AP_Scheduler: added current_task static
will be used to debug stuck tasks on PX4
2014-07-03 09:09:11 +10:00
Emile Castelnuovo
bdd9fe77c7 VRBRAIN: change default pin for analog input. 2014-07-01 12:23:25 +02:00
LukeMike
f70da39206 VRBRAIN: changed the management of the pwm output 2014-07-01 12:21:36 +02:00
LukeMike
fa4fffc878 VRBRAIN: deleted unnecessary customizations 2014-07-01 12:21:35 +02:00
Emile Castelnuovo
b2680984a5 AP_HAL_VRRBAIN: added comment 2014-07-01 12:21:34 +02:00
Andrew Tridgell
bed5db35c7 GCS_MAVLink: fixed missing header 2014-07-01 14:57:41 +10:00
Andrew Tridgell
4c22aa20ad GCS_MAVLink: regenerate headers 2014-07-01 14:26:44 +10:00
Andrew Chapman
7cdd5a700b CameraFeedback: alt rel/msl, renamed CAMERA_EVENT
- include both “alt_msl” and “alt_rel”
- rename CAMERA_EVENT to CAMERA_STATUS
- clarify comments regarding message origin and order
- change pitch/roll/yaw to be camera rather than vehicle, earth frame
2014-07-01 14:25:55 +10:00
Andrew Tridgell
544d872d65 GCS_MAVLink: fixed a shadowed variable 2014-07-01 09:18:20 +10:00
Andrew Tridgell
773bc7bcbe GCS_MAVLink: added missing RTK headers 2014-06-30 20:06:34 +10:00
Andrew Tridgell
f9d87bcc88 AP_GPS: fixed build errors and warnings in SBP driver
shadowed variables and implied casts in structures
2014-06-30 11:15:51 +10:00
Andrew Tridgell
bcb3d1af14 GCS_MAVLink: fixed flymaple build
has dual GPS but no RTK support
2014-06-30 10:51:19 +10:00
Andrew Tridgell
fc11deb547 GCS_MAVLink: regenerate headers 2014-06-30 10:31:11 +10:00
Niels Joubert
fa78634959 AP_GPS: GPS calculates MAVLink messages for GPS and GPS_RTK 2014-06-30 10:30:16 +10:00
Niels Joubert
baf0697f48 GCS_MAVLink: Add support for GPS_RTK messages 2014-06-30 10:30:16 +10:00
Niels Joubert
ad5311c089 MAVLink: New message definitions for GPS_RTK 2014-06-30 10:29:57 +10:00
Niels Joubert
2b1169b0ab AP_GPS: SwiftNav RTK Driver and GPS AutoSwitch param 2014-06-30 10:29:56 +10:00
Niels Joubert
fee79c5bac SITL: Piksi Heartbeat Message support, Integer-RTK baseline simulation 2014-06-30 10:29:56 +10:00
Niels Joubert
a251d0010a AP_NOTIFY: RTK GPS visual notification through faster blink 2014-06-30 10:29:56 +10:00
Niels Joubert
398f32d538 AP_Math: Comments on WGS coordinate conversions 2014-06-30 10:29:56 +10:00
Andrew Tridgell
1ed716976c GCS_MAVLink: regenerate mavlink headers 2014-06-30 08:25:16 +10:00
Andrew Chapman
c6a76e8d97 CameraFeedback: added CAMERA_FEEDBACK_FLAGS for open/closed loop
This is so a GCS can tell if a certain picture was definitely captured
(e.g. with a CCB or machine vision cam) or only requested in the blink
(e.g. uni-directional CHDK)
2014-06-30 08:24:38 +10:00
Andrew Tridgell
fd87f28a07 DataFlash: save some flash space on APM2
don't include log message headers that are not used on APM2
2014-06-30 07:58:42 +10:00
Andrew Tridgell
e6d8e329d5 DataFlash: allow logging of 3 accels/gyros 2014-06-30 07:58:30 +10:00
Andrew Tridgell
ca12592448 AP_InertialSensor: allow for 3 accels and 3 gyros on Pixhawk
this supports FMUv3
2014-06-30 07:58:27 +10:00
Andrew Tridgell
ece01da10e AP_InertialSensor: fixed _dump_registers() for MPU6000
need to take the semaphore to prevent bus errors
2014-06-29 12:11:21 +10:00
lthall
4072fcd99e Inav: use horizontal body frame for accel corrections 2014-06-21 14:58:59 +09:00
Emile Castelnuovo
8f3a4bc88b VRBRAIN: correction to AP_Compass_VRBRAIN.cpp 2014-06-19 11:27:45 +02:00
Emile Castelnuovo
946a461873 VRBRAIN: added VRBRAIN to #if 2014-06-19 11:27:44 +02:00
LukeMike
8f552d5758 VRBRAIN: Changed the management of VirtualRobotix's boards. 2014-06-19 11:27:38 +02:00
Michael Oborne
30a3927ea8 AP_Mount: fix where status_msg() is sent
send to the channel where the trigger msg was sent from
2014-06-18 12:03:18 +10:00
svefro
b473f8fd4d AP_RCMapper: Added warning to RCMAP_THROTTLE
Warning user that changing RCMAP_Throttle could be dangerous
2014-06-17 21:04:19 +10:00
Randy Mackay
9b81e46e61 AP_Common: add example sketch 2014-06-17 20:53:53 +10:00
Randy Mackay
2f7dee3ba5 AP_Mission: squeeze loiter turns radius into high byte of p1 2014-06-17 20:53:50 +10:00
Randy Mackay
b79f729540 AP_Common: add LOWBYTE, HIGHBYTE macros 2014-06-17 20:53:47 +10:00
Randy Mackay
fa16e0967f AP_Common: remove unused location mask definitions 2014-06-17 20:53:45 +10:00
Andrew Tridgell
e2fe3d2de7 GCS_MAVLink: re-generate headers 2014-06-17 20:21:54 +10:00
Andrew Tridgell
0db226daf5 GCS_MAVLink: merge in upstream changes 2014-06-17 20:19:35 +10:00
Andrew Chapman
87fcfbf9dd GCS_MAVLink: re-generate MAVLink headers 2014-06-17 20:16:39 +10:00
Andrew Chapman
048767e389 GCS_MAVLink: camera feedback mavlink messages
CAMERA_EVENT and CAMERA_FEEDBACK messages, and a couple of enums they
use (CAMERA_EVENT_TYPES and CAMERA_FEEDBACK_FLAGS)

Adjusted some types and added more explicit descriptions of units as
suggested on the call last week.

I will add camera parameter list/get/set functionality as suggested
using the existing parameter mechanism and component IDs rather than
the new CAMERA_INFO messages I had proposed.
2014-06-17 20:15:20 +10:00
Randy Mackay
11e08e1492 DataFlash: common Log_Write_Camera
pair programmed with Craig Elder
2014-06-17 14:11:36 +10:00
Randy Mackay
0c9a496262 AC_AttControlHeli: add ATC_RATE_FF_ENAB parameter
Because this class inherits from AC_AttitudeControl library this new
parameter must be added here as well
2014-06-10 21:25:33 +09:00
Randy Mackay
46f25c52a4 AC_AttControl: allow enabling/disabling feedforward and accel limiting 2014-06-10 20:03:02 +09:00
Randy Mackay
a2f54fdf2c AC_WPNav: smooth waypoint by freezing feed-forward and allowing overshoot
First part of this fix is freezing the position controller's xy-axis
feed foward as we transition to the new segment.
Second part is work-around for straight line segments in that we allow
the target point to actually overshoot the end of the segment by up to
2m if the segment is a "fast waypoint".  Ideally we would instead notice
the waypoint has been completed and take any left over time or distance
and move our target along the track towards the next waypoint but that
would require a much larger change to allow the wpnav lib to hold the
next two waypoints.
2014-06-10 20:03:01 +09:00
Randy Mackay
ce85d1f6b2 AC_WPNav: use curr pos target as spline origin
We only use the current target position as origin if the waypoint
controller is active (i..e has been used in the past 1 second).  This is
consistent with how we initialise straight line waypoints
2014-06-10 20:02:59 +09:00
Randy Mackay
130eb07d48 AC_AttControl: angle_ef_roll_pitch_rate_ef_yaw supports zero yaw accel 2014-06-10 20:02:58 +09:00
Randy Mackay
02b4b21f67 AC_AttControl: disable feed forward by default
Can be re-enabled by setting ATC_RATE_FF_ENAB parameter to 1
2014-06-10 20:02:55 +09:00
Randy Mackay
b57c0dabf6 AC_AttControl: check accel_rp_max instead of rate_bff_ff_enabled
We use the accel_rp_max, accel_y_max to check whether to apply accel
limiting or not.  This is related to separate from the
body-frame-feed-forward.
2014-06-10 20:02:54 +09:00
Randy Mackay
2bb30b3ef9 AC_AttControl: add set_yaw_target_to_current_heading method 2014-06-10 20:02:49 +09:00
Randy Mackay
d9c966c927 AC_AttControl: RATE_FF_ENAB param to disable rate feed forward 2014-06-10 20:02:48 +09:00
Randy Mackay
4d4c7a2118 AC_AttControl: move freeze_ff to flags structure 2014-06-10 20:02:46 +09:00
Randy Mackay
a662f87ffb AC_AttControl: remove resolved To-Do
This To-Do is resolved by heli flight modes calling the
relax_bf_rate_controller method
2014-06-10 20:02:45 +09:00
Randy Mackay
7f734f38d6 AC_AttControl: add earth frame angle constraints
This should help recovery time if pilot switches out of ACRO (into
Stabilize, AltHold, etc) while inverted
2014-06-10 20:02:43 +09:00
Randy Mackay
698cf934b8 AC_AttControl: formatting fixes 2014-06-10 20:02:42 +09:00
lthall
2bb63857fa AC_AttControl: clean up stabilize 2014-06-10 20:02:40 +09:00
lthall
c24d293e1b AC_AttControl: zero _accel_xyz_max stops feed forward
Also added place holder for turning off feed forward.
2014-06-10 20:02:39 +09:00
lthall
8bbce7e658 AC_PosControl: freeze feed forward for alt control in Auto 2014-06-10 20:02:36 +09:00
lthall
922026c15c AC_AttControl: rate compensation for yaw 2014-06-10 20:02:34 +09:00
lthall
0d87298221 AC_PosControl: freeze feed forward and vector fixes 2014-06-10 20:02:33 +09:00
Randy Mackay
5209598459 AC_AttControl: rename init_targets to relax_bf_rate_controller 2014-06-10 20:02:27 +09:00
lthall
1bdde31f6b Copter: Fix zero throttle flip issue Stabilize
The problem is that the init_targets is intended to ensure the
controller doesn't build up the I term when the throttle is low. Because
it is poorly named (or used) it have been written to do something else.
Here I change it to do what the code is trying to use it to do.
2014-06-10 20:02:01 +09:00
Randy Mackay
915dad2da4 AC_Circle: use fast_atan2 to calc bearing from center
This does not save much time because it's only called at initialisation
2014-06-06 18:51:09 +09:00
Randy Mackay
f23e94707c AC_WPNav: use fast_atan2 for bearing calcs 2014-06-06 18:51:08 +09:00
David Dewey
17374ff5e8 AP_Math: fast_atan2
This is 126us per call vs 199us on the AVR.  it is accurate to about
0.28 degrees

Committed by rmackay9 but contribution is from David Dewey
2014-06-06 18:50:41 +09:00
Ju1ien
28ce66f314 INav: clear historic z-axis position estimate when set_altitude called 2014-06-06 18:42:42 +09:00
Randy Mackay
efd6d6dc70 AC_WPNav: spline div by zero fix
Also add check for straight line navigation to ensure speed is not
reduced below zero when it hits the leash limit
Also minor formatting changes
2014-06-05 22:23:38 +09:00
lthall
0912bec8f5 Spline div zero and leash limit fix 2014-06-05 22:23:35 +09:00
Andrew Tridgell
f0df912a11 AP_Mission: added support for MAV_CMD_DO_INVERTED_FLIGHT 2014-06-05 15:44:18 +10:00
Andrew Tridgell
ef4a79cc9a GCS_MAVLink: rebuild MAVLink headers 2014-06-05 15:44:03 +10:00
Andrew Tridgell
67937b5b79 GCS_MAVLink: added MAV_CMD_DO_INVERTED_FLIGHT
used to invert from a mission
2014-06-05 15:43:46 +10:00
Andrew Tridgell
5a1aa8dfe7 AP_L1_Control: implement turn_distance() with turn angle
uses a linear approximation for now.
2014-06-05 09:34:23 +10:00
Andrew Tridgell
7a6186f7e6 AP_Navigation: added a turn_distance() method with turn_angle 2014-06-05 09:33:42 +10:00
Andrew Tridgell
49f93b91b2 APM_OBC: fixed formatting to match APM coding standard 2014-06-02 10:47:02 +10:00
Andrew Tridgell
e9e1799700 AP_Compass: fixed VRBrain build 2014-06-02 10:42:37 +10:00
Andrew Tridgell
d554616e86 AP_EPM: fix for HAL_GPIO_* 2014-06-02 10:42:36 +10:00
Andrew Tridgell
3705c90b8e AP_Baro: fix for HAL_GPIO_* 2014-06-02 10:42:36 +10:00
Andrew Tridgell
d70bee9249 AP_AHRS: fix for HAL_GPIO_* 2014-06-02 10:42:36 +10:00
Andrew Tridgell
0d83d4f4f5 APM_OBC: fix for HAL_GPIO_* 2014-06-02 10:42:36 +10:00
Andrew Tridgell
1e2214f8d1 DataFlash: fix for HAL_GPIO_* 2014-06-02 10:42:36 +10:00
Andrew Tridgell
732cd0e130 AP_Relay: fix for HAL_GPIO_* 2014-06-02 10:42:36 +10:00
Andrew Tridgell
50c08ced4c AP_Notify: fixes for HAL_GPIO_* 2014-06-02 10:42:35 +10:00
Andrew Tridgell
4c43cd9775 AP_InertialSensor: fixes for HAL_GPIO_* 2014-06-02 10:42:35 +10:00
Andrew Tridgell
805d79debe HAL_FLYMAPLE: fix for HAL_GPIO_* 2014-06-02 10:42:35 +10:00
Andrew Tridgell
3015356671 HAL_AVR: fixes for HAL_GPIO_ define change 2014-06-02 10:42:35 +10:00
Andrew Tridgell
18a64d17d3 AP_HAL: added HAL_ prefix to GPIO_ defines
this fixes a bug caused by GPIO_INPUT and GPIO_OUTPUT already being
defined in NuttX, which caused pinMode() not to setup pins for output
when requested
2014-06-02 09:24:52 +10:00
Andrew Tridgell
fa4eb5475a HAL_PX4: implement analog input stop pins
this allows multiple sonars to cooperate without interference
2014-06-02 08:35:41 +10:00
Randy Mackay
2b0f142a17 AC_PosControl: fix typo in D-filter definition 2014-05-29 17:50:48 +09:00
Randy Mackay
7e3213edbf AC_AttControl: increase default accel max 2014-05-29 17:40:26 +09:00
Randy Mackay
29ca7a10df AC_PosControl: set alt hold accel control D term filter 2014-05-29 17:40:23 +09:00
Randy Mackay
0969e464fb AC_AttControl: set roll, pitch, yaw rate control D term filters 2014-05-29 17:40:17 +09:00
Randy Mackay
faf3415e5e AC_PID: example sketch prints individual P, I and D values 2014-05-29 17:39:19 +09:00
Robert Lefebvre
b35ec4339e AC_PID: Add method to set the D-term Filter Rate from main code. 2014-05-29 17:39:10 +09:00
Robert Lefebvre
f1c3f2a3d1 AC_PID: Remove get_leaky_i function which is now found in AC_HELI_PID. 2014-05-29 17:39:08 +09:00
Robert Lefebvre
7c9249de93 AC_AttitudeControl_Heli: Change to use AC_HELI_PID class instead of AC_PID. Remove FF parameters from class. 2014-05-29 17:39:06 +09:00
Robert Lefebvre
6333b4bba6 AC_PID: update example sketch to test AC_HELI_PID 2014-05-29 17:39:01 +09:00
Robert Lefebvre
ef7dc815cd AC_PID: Change Private members to Protected so that AC_HELI_PID can access them. 2014-05-29 17:38:59 +09:00
Robert Lefebvre
94e9bed9cf AC_PID: Add new AC_HELI_PID as a child of AC_PID 2014-05-29 17:38:57 +09:00
Andrew Tridgell
0b6407256c GCS_MAVLink: moved 3 more send_*() functions to GCS_Common.cpp 2014-05-28 09:35:30 +10:00
Andrew Tridgell
37c50d9587 HAL_PX4: fixed use of FMU servo pins as digital inputs
these pins can be PWM output or digital input or digital output
2014-05-25 22:03:44 +10:00
Andrew Tridgell
2d9e9d9bc3 AP_Compass: added COMPASS_PRIMARY parameter
this allows selection of which compass is the primary. Useful if the
first compass starts giving spurious data (as happened in our plane)
2014-05-25 22:03:44 +10:00
priseborough
edc79ca2a4 AP_NavEKF: Increase divergence test margin based on analysis of more user flight logs
Analysis of copter logs has shown cases with a healthy EKF where spikes in EKF4.DS of up to 25% of the threshold have occurred.
A value of closer to 10% for normal operation is preferred.
2014-05-24 22:20:24 +10:00
Andrew Tridgell
aba11a0634 AP_L1_Control: wrap the target_bearing 2014-05-23 07:30:58 +10:00
Randy Mackay
cde7d31dad AC_WPNav: fix divide by zero when origin and dest are same location 2014-05-22 21:18:24 +09:00
Andrew Tridgell
63da53c842 GCS_MAVLink: moved main update() routine into GCS_Common.cpp
this fixes a common timeout error with loading large missions, and
means less per-vehicle code
2014-05-21 12:45:25 +10:00
Andrew Tridgell
42c1501563 AP_Common: moved map_baudrate() into AP_Common
this version supports a much wider range of baudrates
2014-05-21 12:45:25 +10:00
Andrew Tridgell
7d712f90bf APM_OBC: adjusted docs for FS_HB_PIN
thanks to Warren for the question
2014-05-21 12:45:25 +10:00
Randy Mackay
69ad632e2a GPS: correct NAVFILTER parameter description
These corrected values match the GPS_Engine_Setting enum in GPS.h
Thanks to Adolfo R for noticing the issue and providing the fix
2014-05-20 22:08:40 +09:00
Andrew Tridgell
a7d6a26bec HAL_PX4: fixed auto-flow control
the 6 bytes written to break the radio out of bootloader broke
auto flowcontrol detection
2014-05-19 22:02:39 +10:00
Randy Mackay
597d5227f5 AC_WPNav: rename set_loiter_target to init_loiter_target 2014-05-19 12:27:25 +09:00
Randy Mackay
e7b3c00767 AC_WPNav: set_loiter_target uses set_xy_target
Loiter is only a horizontal position controller so it should not set the
z-axis position.
Moved pos_control.set_speed and accel functions so order matches
init_loiter_targets function order
2014-05-19 12:27:20 +09:00
Ju1ien
aed5787c1b AC_WPNav: bug fix for loiter init in Hybrid
AC_PosControl::init_xy_controller() has been added to PosControl and is
called by init_loiter_target.
Hybrid is currently using set_loiter_target function to init the loiter
controller. So we have to call init_xy_controller() by set_loiter_target
function.
What happens otherwise?
In AC_PosControl::update_xy_controller, we update "now" with
now = hal.scheduler->millis();
and, as _last_update_xy_ms has not been updated previously by
init_xy_controller(), we just call init_xy_controller().
So, _dt_xy  will be negative and used anyways in all the functions and
PID called by update_xy_controller.
That will avoid at least _accel_target.x/y to be set to 0 but I'm not
sure for the high values, probably an I_term that is not reset and
reached very high value.
Or maybe a cast error somewhere... no clue at all
2014-05-19 12:27:16 +09:00
priseborough
5fe0d2c1b2 AP_NavEKF: Add protection for accel bias estimation errors
Don't do bias estimation if tilted by more than 60 degrees to prevent scale
factor errors affecting result unnecessarily.
Prevent Kalman gain from having the wrong sign due to numerical errors
associated with small process noise values.
Allow smaller Z accel bias process noise values to be set
2014-05-18 08:09:00 +10:00
priseborough
3222e8f7cb AP_NavEKF: Default parameter adjustments
Bring Plane glitch protection thresholds into alignment with copter and
rover
Slight increase in accelerometer bias process noise to prevent bias
estimate divergence into limits (Rover and Plane only as Copter does not
seem respond as well to this change)
effective increase in threshold on divergence test to allow increased
margin for bad GPS velocities
2014-05-18 08:08:49 +10:00
Andrew Tridgell
65fd25fb5a AP_InertialSensor: fixed example build 2014-05-18 08:08:19 +10:00
Andrew Tridgell
b99ae63cbb HAL_Linux: more generic fix for scheduler issues in example sketches
this ensures drivers can run
2014-05-16 22:40:38 +10:00
Andrew Tridgell
30f5e2c37f AP_GPS: work around scheduling issue in example code 2014-05-16 22:35:32 +10:00
priseborough
e40e50e2e1 AP_NavEKF: Prevent start-up transients re-tripping divergence test 2014-05-16 22:05:22 +10:00
Andrew Tridgell
73976e2ca4 AP_GPS: fixed example build 2014-05-16 22:05:04 +10:00
Andrew Tridgell
8533aecf18 AP_InertialSensor: fixed example build 2014-05-16 21:24:25 +10:00
priseborough
a19015ed61 AP_NavEKF: Scale divergence check with covariance
This provides consistent behaviour for a range of gyro bias process
noise settings and automatically adjusts sensitivity as filter learns bias
2014-05-16 21:24:25 +10:00
priseborough
0337d44b2e AP_NavEKF: Fix bug causing immediate clearing of diverged status on reset 2014-05-16 21:24:04 +10:00
priseborough
d150904dc6 AP_NavEKF: Increase gyro bias process noise
This is required to stop the bias estimate from becoming too static
towards the end of longer flights.
2014-05-16 21:24:04 +10:00
Andrew Tridgell
49e7ee9ba7 GCS_MAVLink: added setup_uart() method
this provides a common way of dealing with UART setup for a GCS
instance. It includes code to cope with SiK radios stuck in bootloader
mode.
2014-05-16 11:44:33 +10:00
Andrew Tridgell
b3c1e515dc AP_AHRS: when no accel info available in buffer use current value
this prevents an initialisation error, and is reasonable in flight too

Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-05-15 22:19:54 +10:00
Andrew Tridgell
315290029a AP_AHRS: fixed check of accel sensor health
we need to check health of each accelerometer separately
2014-05-15 22:18:56 +10:00
Andrew Tridgell
5edf4ba596 AP_NavEKF: fixed up handling of bitfields in faultStatus
Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-05-15 21:42:39 +10:00
Andrew Tridgell
79edc4b467 GCS_MAVLink: re-generate with addition of MAV_SYS_STATUS_AHRS 2014-05-15 21:14:21 +10:00
Andrew Tridgell
ccebeba5a5 GCS_MAVLink: added MAV_SYS_STATUS_AHRS
will be used to indicate AHRS health
2014-05-15 21:14:21 +10:00
priseborough
f01cc78d37 DataFlash: Add EKF fault status logging 2014-05-15 21:14:21 +10:00
priseborough
ce8e1daa16 AP_NavEKF: Improved divergence detection and reset
Divergence is now detected by looking for very large changes in the gyro
bias. This will cause the filter to be reset and declared unhealthy for
10 seconds.

Don't reset filterDiverged status immediately during reset

Set filterDiverged true if covariance blows up

Add fault status reporting
2014-05-15 21:14:21 +10:00
Andrew Tridgell
5d2d6e0063 GCS_MAVLink: regenerated MAVLink headers 2014-05-15 21:14:21 +10:00
Andrew Tridgell
983ac9cbf4 GCS_MAVLink: merge in latest upstream XML changes 2014-05-15 21:14:21 +10:00
Andrew Tridgell
1a05c27bbb AP_AHRS: added healthy() function
this will be used to report when the AHRS subsystem becomes unhealthy
2014-05-15 21:14:21 +10:00
Andrew Tridgell
086142580a AP_InertialSensor: added VibTest sketch
logs all accel data at high rate to SD card
2014-05-15 21:14:21 +10:00
Jonathan Challinger
e883b889b6 SITL: Add compassmot interference 2014-05-15 21:14:20 +10:00
Randy Mackay
4ebde25a26 AP_Relay: add -1:Disabled to list of param values 2014-05-15 17:13:37 +09:00
Randy Mackay
5d20594fa4 AC_WPNav: bug fix for loiter and waypoint update rate
Thanks to EmileC for spotting this
2014-05-12 20:13:46 +09:00
Andrew Tridgell
85ebe81ed3 AP_NavEKF: fixed logic for divergence test
Pair-Programmed-With: Paul Riseborough <p_riseborough@live.com.au>
2014-05-11 18:00:38 +10:00
priseborough
40dc0e56fe AP_NavEKF: Add protection for badly conditioned innovation variances 2014-05-11 18:00:38 +10:00
priseborough
925c5751bd AP_NavEKF: Add ability to inhibit in-flight mag cal and clean up moding
This will enable in-flight magnetometer calibration to be inhibited unconditionally,
This is required for long balloon carriage flights where ground speed can be high
enough to put it into in-air state, but with very poor observability of magnetic field
states causing bad state estimates and heading offsets to develop over time.

The covariance matrix no longer has rows and columns artificially zeroed when in static
mode. Instead booleans indicating whether wind or magentic field state estimation is
active are used to:

a) Set the process noise on these states to zero to stop their variances from increasing
unchecked when not being updated, and
b) Turn off updates for these states when measurement fusion is being performed.

This reduces the likelihood of a badly conditioned covariance matrix forming
during static mode operation.

A filter divergence check has also been added that will declare the filter unhealthy if
position, velocity and magnetic field observations are all failing their innovation
consistency checks. This unhealthy status will persist for 10 seconds after the
condition clears.

AP_NavEKF: Remove unnecessary zeroing of wind covariances
2014-05-11 18:00:38 +10:00
priseborough
3026ccee13 AP_NavEKF: Use baro data during launch transients whilst in static mode
Baro data can be used as it will still be valid during the launch and
is not a synthesised measurement.
2014-05-11 18:00:38 +10:00
Randy Mackay
05f5164dfa Mission: rename AUTORESET to RESTART 2014-05-09 11:31:37 +09:00
Hug0
6b0d5f9770 AP_InertialNav: fix pos error degradation rate
degrate position_error to 10% over 2 seconds (assumes 5hz update rate)
must be *0.7943 instead of 0.7934
2014-05-08 23:09:39 +09:00
Randy Mackay
badc127c34 AC_WPNav: fix example sketch 2014-05-08 16:25:13 +09:00
Randy Mackay
9b6a4e0fc7 AC_Sprayer: fix example sketch 2014-05-08 16:25:11 +09:00
lthall
9ab9eaec25 AC_WPNav: Loiter jerk default to 10m/s/s/s
Pair programmed with Randy
2014-05-08 16:16:05 +09:00
Randy Mackay
1cb297580f Copter: reduce Circle init twitch by using stopping point 2014-05-08 16:15:57 +09:00
Randy Mackay
091ff91a70 WPNav: add wp_and_spline_init to set speeds an init pos controller 2014-05-08 16:15:50 +09:00
Randy Mackay
c13db680b7 AC_PosControl: remove reset_I_xy
lean_angles_to_accel is now used to load the position rate I terms based
on vehicle's initial roll and pitch angle
2014-05-08 16:15:48 +09:00
Randy Mackay
cd8b1f278c AC_PosControl: remove unused _cos_yaw variable
Also removed _sin_yaw, _cos_pitch, _step saving a total of 17bytes of
RAM
Also made get_speed_up, get_speed_down, lean_angles_to_accel functions
const
2014-05-08 16:15:46 +09:00
Randy Mackay
48ec0caf75 AC_WPNav: run navigation at 10hz in SITL 2014-05-08 16:15:44 +09:00
Randy Mackay
0819e05896 AC_PosControl: lean_angles_to_accel added for smooth initialisation
init_xy_controller also added to capture initialisation all in one place
2014-05-08 16:15:41 +09:00
lthall
b38c484874 AC_WPNav: add LOIT_JERK parameter
Limit accel output from loiter controller.
Call new pos_control.init_xy_controller when loiter starts
Remove sudden stop when pilot requested acceleration is zero

Pair programmed with Randy
2014-05-08 16:15:38 +09:00
Randy Mackay
71fae1e6f2 AC_AttControl: lean_angle_max accessor fn const 2014-05-08 16:15:36 +09:00
Randy Mackay
fd9f8f571f AC_WPNav: replace inav, ahrs pointers with references 2014-05-08 16:15:26 +09:00
lthall
21c93e48ab AC_PosControl: include vel error when get_stopping_point_z
Pair programmed with Randy
2014-05-08 16:15:24 +09:00
Randy Mackay
a1f1dd8059 AC_PosControl: add is_active_z method
Consolidated z-axis timeout checks to save 4bytes of RAM
Added POS_CONTROL_ACTIVE_TIMEOUT_MS to make timeout consistent
2014-05-08 16:15:22 +09:00
Andrew Tridgell
74227cd7f0 AP_HAL: prevent some FastDelegate warnings 2014-05-08 11:11:03 +10:00
Andrew Tridgell
a295760e56 AP_Rally: fixed indentation
previous indentation confused emacs24
2014-05-08 11:01:52 +10:00
Andrew Tridgell
4efcae46ab SITL: cope with more rubbish startup values from JSBSim 2014-05-04 17:30:10 +10:00
Andrew Tridgell
320834a5e7 HAL_PX4: read from FRAM in 128 byte chunks (2nd try)
this time without the amazingly silly bug
2014-05-02 22:12:45 +10:00
Andrew Tridgell
db6b96caa0 Revert "HAL_PX4: read from FRAM in 128 byte chunks"
This reverts commit a92366c455.

This commit may be associated with FRAM corruption on Pixhawk. Revert
until we understand why
2014-05-02 21:52:26 +10:00
Andrew Tridgell
a92366c455 HAL_PX4: read from FRAM in 128 byte chunks
this fixes FRAM read on Roberts Pixhawk. We don't know why yet.
2014-05-02 12:24:54 +10:00
Randy Mackay
937e9ea687 AC_PosControl: add set_target_to_stopping_point_xy method
Fixed bug in get_stopping_point_xy in which it would update Z-axis
target if vehicle was moving less than 10cm/s horizontally
2014-04-30 21:46:20 +09:00
Randy Mackay
7dd366d84e AC_WPNav: init_loiter sets speed, accel before calcing stopping distance
The stopping distance depends upon the speed and acceleration so these
must be updated first
2014-04-30 21:46:18 +09:00
Randy Mackay
0103ae2eb0 AC_WPNav: add WPNAV_ACCEL_Z
Allows configurable z-axis acceleration during missions
2014-04-30 21:46:12 +09:00
Randy Mackay
9f63de9b59 AC_PosControl: set_speed_z accepts positive descent speeds 2014-04-30 21:46:09 +09:00
Randy Mackay
510c9920a6 AC_WPNav: rename get_horizontal_velocity to get_speed_xy
This new method name is consistent with the equivalent in the
AC_PosControl class
2014-04-30 21:46:06 +09:00
Andrew Tridgell
eb1fb63e57 APM_Control: added logging of parameter changes in AUTOTUNE
this will make it easier to analyse logs
2014-04-30 22:22:13 +10:00
Andrew Tridgell
871d0c0e44 APM_Control: moved the log structure to ArduPlane core
this allows it to work with old style .log files
2014-04-30 21:22:28 +10:00
Andrew Tridgell
4f250579db DataFlash: added LOG_ATRP_MSG define 2014-04-30 21:22:28 +10:00
priseborough
114bd56e2a AP_NavEKF: Fix display names in parameter list 2014-04-30 06:35:41 +10:00
Randy Mackay
5cc26569fc AP_Motors: fix example sketch 2014-04-29 20:46:34 +09:00
priseborough
5fefce5899 AP_NavEKF: Synthetic sideslip fusion numerical error protections 2014-04-29 17:26:45 +10:00
Jonathan Challinger
0bb7b8e938 AP_GPS: Fix bug that causes permanent lag if we miss a message 2014-04-29 15:35:46 +10:00
Randy Mackay
2be99d7a92 TriCopter: output_test for individual motors
Based on original work by Nils Hogberg
2014-04-29 11:41:16 +09:00
Randy Mackay
07766e55f9 SingleCopter: output_test for individual motors
Based on original work by Nils Hogberg
2014-04-29 11:41:14 +09:00
Randy Mackay
3610cfe24c TradHeli: output_test for individual motors
Based on original work by Nils Hogberg
2014-04-29 11:41:13 +09:00
Randy Mackay
8f74f5b3b0 CoaxCopter: output_test for individual motors
Based on original work by Nils Hogberg
2014-04-29 11:41:12 +09:00
Randy Mackay
d63d82ec17 MotorMatrix: output_test for individual motors
Based on original work by Nils Hogberg
2014-04-29 11:41:10 +09:00
Vizual54
11d02ea5d2 AP_Motors: output_test for individual motors
Modified and integrated by Randy Mackay
2014-04-29 11:36:58 +09:00
Randy Mackay
6517638670 GCS_MAVLink: generate after adding DO_MOTOR_TEST 2014-04-29 11:23:07 +09:00
Randy Mackay
28846c6c99 GCS_MAVLink: add DO_MOTOR_TEST message 2014-04-29 11:23:04 +09:00
Andrew Tridgell
818e500509 AP_Mission: improve the AP_Mission docs
DisplayName isn't a description
2014-04-29 11:46:06 +10:00
Andrew Chapman
782fbe1ec5 AP_Mission: added reset() function 2014-04-29 11:46:06 +10:00
Andrew Chapman
a80e72ff82 AP_Mission: added MIS_AUTORESTART parameter
- added MIS_AUTORESTART parameter, defaults to 0
- added start_or_resume() function to either start or resume a mission
based on that parameter value
2014-04-29 11:46:06 +10:00
Andrew Tridgell
cf9b67d8fc GCS_MAVLink: prevent uninitialised bytes being written to a serial port 2014-04-27 15:34:30 +10:00
Randy Mackay
e855cfec02 AC_Fence: add 10sec manual recovery
This resolves issue #461 by giving the pilot a minimum of 10 seconds to
attempt to manually recover before the autopilot will attempt to retake
control to bring the copter home or land.
2014-04-27 11:11:07 +09:00
Randy Mackay
db51d37071 AC_WPNav: add clear_pilot_desired_acceleration
This allows quickly clearing out the pilot desired acceleration for
loiter contoller.
2014-04-25 14:45:14 +09:00
Randy Mackay
06bef6e3b8 Parachute: clear release time when enabled
This resolves an issue in which the parachute could be suddenly released
when the user enabled the parachute.  The sequence that could have
caused this bad behaviour were (1) the parachute is triggered (2) the
user disables the parachute in the 0.5sec between the trigger and the
actual release, (3) the user re-enables the parachute and the old
release time from (1) is used.
2014-04-24 19:22:11 +09:00
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