Commit Graph

7709 Commits

Author SHA1 Message Date
Lucas De Marchi
d640bc8345 AP_HAL_Linux: use kernel's limit of msgs per I2C transaction
Instead of hardcoding 8 as the limit for I2C msgs, use whatever the
kernel exported to us.  In upstream this is 42 so it means we can group
together 21 addr/data pair instead of only 8.
2015-05-05 09:56:44 +10:00
Andrew Tridgell
d8791134f9 HAL_SITL: need to use fabs() for double checking 2015-05-05 09:45:59 +10:00
Andrew Tridgell
b9abf30785 HAL_SITL: removed unused cygwin code 2015-05-05 09:45:58 +10:00
Andrew Tridgell
5158f91263 HAL_SITL: converted command line code to getopt_cpp 2015-05-05 09:45:58 +10:00
Andrew Tridgell
a58a663085 SITL: fixed build on APM2 2015-05-05 09:45:58 +10:00
Andrew Tridgell
35d22b9d57 AP_HAL: added getopt_cpp class
a simple port of getopt_long to C++
2015-05-05 09:45:58 +10:00
Andrew Tridgell
438f954379 DataFlash: fixed some build warnings 2015-05-05 09:45:58 +10:00
Andrew Tridgell
d8ca0658d7 AP_Mount: fixed some build warnings 2015-05-05 09:45:58 +10:00
Andrew Tridgell
b2b5c8cd18 HAL_SITL: fixed some build warnings 2015-05-05 09:45:58 +10:00
Andrew Tridgell
a7c3125bcc AP_GPS: fixed warnings in SBP driver 2015-05-05 09:45:57 +10:00
Andrew Tridgell
212e0ec002 StorageManager: fix for HAL_SITL rename 2015-05-05 09:45:57 +10:00
Andrew Tridgell
fa688a7b14 RC_Channel: fix for HAL_SITL rename 2015-05-05 09:45:57 +10:00
Andrew Tridgell
f449b34fdd PID: fix for HAL_SITL rename 2015-05-05 09:45:56 +10:00
Andrew Tridgell
2d89b8b53d GCS_MAVLink: fix for HAL_SITL rename 2015-05-05 09:45:56 +10:00
Andrew Tridgell
69f9d25cd0 DataFlash: fix for HAL_SITL rename 2015-05-05 09:45:56 +10:00
Andrew Tridgell
cf4602afc1 AP_TECS: fix for HAL_SITL rename 2015-05-05 09:45:56 +10:00
Andrew Tridgell
a4e8d960d2 AP_Scheduler: fix for HAL_SITL rename 2015-05-05 09:45:56 +10:00
Andrew Tridgell
c80a631813 AP_Relay: fix for HAL_SITL rename 2015-05-05 09:45:56 +10:00
Andrew Tridgell
ac43972883 AP_RangeFinder: fix for HAL_SITL rename 2015-05-05 09:45:56 +10:00
Andrew Tridgell
4ee54a8915 AP_OpticalFlow: fix for HAL_SITL rename 2015-05-05 09:45:56 +10:00
Andrew Tridgell
9f10e2d26c AP_Notify: fix for HAL_SITL rename 2015-05-05 09:45:56 +10:00
Andrew Tridgell
c4d6f9d040 AP_NavEKF: fix for HAL_SITL rename 2015-05-05 09:45:55 +10:00
Andrew Tridgell
2e57c62ebb AP_Motors: fix for HAL_SITL rename 2015-05-05 09:45:55 +10:00
Andrew Tridgell
0c142bb25a AP_Mission: fix for HAL_SITL rename 2015-05-05 09:45:55 +10:00
Andrew Tridgell
eca675c556 AP_Math: fix for HAL_SITL rename 2015-05-05 09:45:55 +10:00
Andrew Tridgell
ef527d9daa AP_InertialSensor: fix for HAL_SITL rename 2015-05-05 09:45:55 +10:00
Andrew Tridgell
2be45bc7e6 AP_GPS: fix for HAL_SITL rename 2015-05-05 09:45:55 +10:00
Andrew Tridgell
dd94cc18a1 AP_Common: fix for HAL_SITL rename 2015-05-05 09:45:55 +10:00
Andrew Tridgell
8055e5792d AP_BattMonitor: fix for HAL_SITL rename 2015-05-05 09:45:55 +10:00
Andrew Tridgell
7d9d594283 AP_Baro: fix for HAL_SITL rename 2015-05-05 09:45:55 +10:00
Andrew Tridgell
f23bc463cb AP_Airspeed: fix for HAL_SITL rename 2015-05-05 09:45:54 +10:00
Andrew Tridgell
e597575747 AP_AHRS: fix for HAL_SITL rename 2015-05-05 09:45:54 +10:00
Andrew Tridgell
d8cd986696 APM_Control: fix for HAL_SITL rename 2015-05-05 09:45:54 +10:00
Andrew Tridgell
e789984c98 AC_WPNav: fix for HAL_SITL rename 2015-05-05 09:45:54 +10:00
Andrew Tridgell
777685ce1f AC_PID: fix for HAL_SITL rename 2015-05-05 09:45:54 +10:00
Andrew Tridgell
40e3b422b5 HAL_SITL: rename HAL_AVR_SITL to HAL_SITL
it is nothing to do with the original AVR emulation now
2015-05-05 09:45:54 +10:00
Andrew Tridgell
24fc1d8ebf HAL_SITL: added -F option for FDM address 2015-05-05 09:45:54 +10:00
Andrew Tridgell
630cd14252 HAL_SITL: added rover simulator support 2015-05-05 09:45:53 +10:00
Andrew Tridgell
64fa219c05 SITL: converted rover simulator from python to C++ 2015-05-05 09:45:53 +10:00
Andrew Tridgell
11df612c04 HAL_SITL: added a table of simulator constructors 2015-05-05 09:45:53 +10:00
Andrew Tridgell
6ec6158b8b SITL: converted helicopter simulator from python 2015-05-05 09:45:53 +10:00
Andrew Tridgell
be3d6c924e AP_Compass: rename enum values to avoid header conflicts for 'ERROR' 2015-05-05 09:45:53 +10:00
Andrew Tridgell
963e5c5977 HAL_SITL: removed pthread.h as no longer needed 2015-05-05 09:45:53 +10:00
Michael Oborne
c26f2c9b1c SITL: add missing include 'select' 2015-05-05 09:45:53 +10:00
Andrew Tridgell
878549530d HAL_SITL: g_state is not needed any more 2015-05-05 09:45:53 +10:00
Andrew Tridgell
a17fc9e5ab SITL: fixed time handling type 2015-05-05 09:45:53 +10:00
Andrew Tridgell
ce0a863d01 AP_NavEKF: allow for optimisation of the EKF
disable optimisation when debugging needed
2015-05-05 09:45:53 +10:00
Andrew Tridgell
25de563687 HAL_SITL: support direct RC input 2015-05-05 09:45:52 +10:00
Andrew Tridgell
77f007ab27 SITL: support speedup setting on the command line 2015-05-05 09:45:52 +10:00
Andrew Tridgell
a6f41b3ca6 HAL_SITL: removed the need for the FDM thread
this also removes the need for the barriers
2015-05-05 09:45:52 +10:00
Andrew Tridgell
19147a05f6 SITL: support functions for new simulators 2015-05-05 09:45:52 +10:00
Andrew Tridgell
437e1bdba0 SITL: added fill_fdm() for FDM output from simulator 2015-05-05 09:45:52 +10:00
Andrew Tridgell
ab2d4349b4 HAL_SITL: initial support for internal simulators 2015-05-05 09:45:52 +10:00
Andrew Tridgell
24b051565b AP_Math: added normalize() method to Matrix3f 2015-05-05 09:45:52 +10:00
Andrew Tridgell
914b91af9e SITL: initial conversion of multicopter sim to C++ 2015-05-05 07:12:36 +10:00
Randy Mackay
2a6421d1bf Airspeed: fix example sketch 2015-05-02 20:53:49 +09:00
Randy Mackay
55298a4c73 Baro: fix example sketch 2015-05-02 17:25:44 +09:00
Paul Riseborough
be04be9b43 AP_NavEKF: Fix bug preventing home position being set by copter
The interface definition has been modified so that it returns true for a position obtained usin geither the normal inertial navigation calculation, or a raw GPS measurement.
This enables this function to be used to set a home position before flight.
2015-05-02 17:20:21 +09:00
Randy Mackay
75e2498da2 Scheduler: fix example sketch 2015-05-02 11:55:50 +09:00
Randy Mackay
c78068b8b8 StorageManager: fix example sketch 2015-05-01 21:03:13 +09:00
Randy Mackay
5b15c07d47 RC_Channel: fix example sketch 2015-05-01 21:02:57 +09:00
Randy Mackay
240a845206 Notify: fix example sketches 2015-05-01 20:58:34 +09:00
Randy Mackay
b223e90ef6 AP_Motors: fix example sketches 2015-05-01 20:58:20 +09:00
Randy Mackay
ed61d961c3 Mission: fix example sketch 2015-05-01 20:58:06 +09:00
Randy Mackay
fecbf06008 AP_Math: fix example sketches 2015-05-01 20:57:38 +09:00
Jonathan Challinger
2b29060a4e AC_WPNav: remove unused set_loiter_velocity 2015-05-01 16:46:53 +09:00
Randy Mackay
187dd0dccd HAL_PX4: fix example sketch 2015-05-01 16:44:10 +09:00
Randy Mackay
fb7e75594f AP_NavEKF: replace memset with quaternion.initialise 2015-05-01 16:37:35 +09:00
Randy Mackay
eaedeeb7bf AP_Math: add quaternion.initialise 2015-05-01 16:37:34 +09:00
Randy Mackay
c366fbbc96 AP_NavEKF: remove unused haveDeltaAngles 2015-05-01 16:37:33 +09:00
Randy Mackay
6773c0b232 AP_InertialSensor: default primary accel and gyro 2015-05-01 16:37:33 +09:00
Paul Riseborough
b71b8f4bda AP_NavEKF: Always return a NED relative position if possible
If a calculated position is not available, the function will return a value based on raw GPS or last calculation if available, but the status will be set to false to indicate that it cannot be used for control.
2015-05-01 16:37:32 +09:00
Paul Riseborough
20ba1e6b1b AP_NavEKF: Always return a WGS-84 location if possible
If a calculated location is not available, the function will return raw GPS data if available, but the status will be set to false.
2015-05-01 16:37:31 +09:00
Paul Riseborough
dd1e0b2f0b AP_NavEKF: Add missing function to return the NED to XYZ quaternion 2015-05-01 16:37:30 +09:00
Paul Riseborough
2c4572eb50 AP_NavEKF: Make ground effect variable names more descriptive 2015-05-01 16:37:29 +09:00
Paul Riseborough
3986851c51 AP_NavEKF: Prevent Z accel bias changing during ground effect takeoff
The inconsistent baro data during ground effect takeoff combined with the larger variances in the Z accel bias state early in flight can cause unwanted changes in bias estimate and therefore changes in height estimation error.
This patch turns of the process noise and state updates for the Z accel bias state when takeoff in ground effect is expected.
2015-05-01 16:37:28 +09:00
Paul Riseborough
2cba60c731 AP_NavEKF: Decouple takeoff ground effect compensation from arm transtion
Thsi fixes a potential bug where the vehicle could land at a lower location without disarming and re-enter ground effect takeoff mode wiht a baro height floor above the current altitude, causing unpredictable height gain
2015-05-01 16:37:27 +09:00
Paul Riseborough
c4c0f819b5 AP_NavEKF: Ensure Covariance initialisation uses correct IMU time step 2015-05-01 16:37:26 +09:00
Paul Riseborough
5dc29699ab AP_NavEKF: Publish the INS delta quaternion 2015-05-01 16:37:25 +09:00
Paul Riseborough
d273302ce7 AP_NavEKF: Improve rate of accel bias learning before flight 2015-05-01 16:37:24 +09:00
Paul Riseborough
8dc6354a54 AP_NavEKF: Prevent touchdown baro errors tripping height innovation check
Ground effect baro errors can cause a spike in height innovation on disarming if ground effect compensation was used during the landing. This causes a transient AHRS fault message if this innovation is outside the pre-arm check limits.
Resetting the vertical position state to the measured height after disarming prevents this.
2015-05-01 16:37:23 +09:00
Jonathan Challinger
2f38dd1b67 AP_NavEKF: use quaternion functions to apply IMU delta angles 2015-05-01 16:37:22 +09:00
Jonathan Challinger
9c374eb4a8 AP_NavEKF: apply constrained floor to barometer innovation while landing 2015-05-01 16:37:21 +09:00
Jonathan Challinger
3c6446fadd AP_NavEKF: refactor meaHgtAtTakeOff filter 2015-05-01 16:37:20 +09:00
Paul Riseborough
744de74c16 AP_NavEKF: Reduce ground effect baro induced height errors during takeoff 2015-05-01 16:37:19 +09:00
Paul Riseborough
13616d6436 AP_NavEKF: Add takeoff and touchdown expected to reported filter status 2015-05-01 16:37:19 +09:00
Jonathan Challinger
8c92524b8a AP_NavEKF: add takeoffExpected and touchdownExpected 2015-05-01 16:37:18 +09:00
Jonathan Challinger
b6b55bf6f2 AP_NavEKF: integrate gravity over correct time period 2015-05-01 16:37:17 +09:00
Jonathan Challinger
cb0c424da1 AP_NavEKF: rewrite readIMUData 2015-05-01 16:37:16 +09:00
Jonathan Challinger
bb88a4f8fe AP_InertialSensor: healthy() checks bounds 2015-05-01 16:37:15 +09:00
Jonathan Challinger
af80f20a51 AP_InertialSensor: add get_primary_gyro, fix get_primary_accel 2015-05-01 16:37:14 +09:00
Randy Mackay
0acc06d713 AP_Motors: minor comment for interlock 2015-05-01 14:30:45 +09:00
Robert Lefebvre
1a482de5e2 AP_MotorsHeli: Overload output_armed_zero_throttle 2015-05-01 14:30:25 +09:00
Robert Lefebvre
6bdace30d2 AP_Motors: Add throttle interlock functionality
AP_MotorsMatrix's output_armed_zero_throttle uses output_min default from base class
2015-05-01 14:30:24 +09:00
Randy Mackay
31edd6a72b AC_PosControl: add_takeoff_climb_rate method
This function simply increments the current altitude target given a
climb rate and dt
2015-05-01 12:56:30 +09:00
Jonathan Challinger
348001e786 AP_Motors: add get_throttle_warn function 2015-05-01 12:56:11 +09:00
Andrew Tridgell
74581a55bc HAL_SITL: fixed startup of SITL in synthetic clock mode 2015-04-30 17:19:56 +10:00
Andrew Tridgell
df21c6c68d AP_HAL: support micros64() and millis64() on all platforms
this will allow for 64 bit timestamps in DF logs (Peter is working on
that)
2015-04-30 12:17:34 +10:00
Andrew Tridgell
4c4a4f9ea5 AP_RangeFinder: fixed cm to meter comparison
thanks to EShamaev for this fix (see PR #1352)
2015-04-30 11:26:36 +10:00
Randy Mackay
dfadcad69d Mission: allow zoom_step to be negative 2015-04-29 14:36:25 +09:00