Commit Graph

1232 Commits

Author SHA1 Message Date
tridge60@gmail.com 9ead82f137 IMU: fixed HIL init with callback
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2988 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-31 23:35:37 +00:00
tridge60@gmail.com 91e101f47e GPS: added delay hook for GPS detection
this allows for MAVLink to be up during GPS detection

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2987 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-31 22:34:37 +00:00
tridge60@gmail.com b6397c089d IMU: added delay callback hooks to IMU initialisation
this allows the imu init() call to use a custom replacement for
delay(), which will allow for the processing of MAVLink packets during
IMU initialisation

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2986 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-31 22:34:25 +00:00
jasonshort 5152d23650 2.0.39
mistake on the defaults for kP - not symmetrical.

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2985 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-31 20:09:27 +00:00
jasonshort 8e02e89534 2.0.39
mistake on the defaults for kP - not symmetrical.

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2984 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-31 20:06:36 +00:00
jasonshort 4223dff94e 2.0.39
limit RTL to 35°

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2983 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-31 19:57:35 +00:00
jasonshort a6bad6b73e 2.0.39
small change to RTL to prevent negative effects from flying backwards.

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2982 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-31 19:42:07 +00:00
jasonshort c637bf0947 small change to RTL to prevent negative effects from flying backwards.
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2981 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-31 19:41:11 +00:00
rmackay9@yahoo.com e81aa43f1c OpticalFlow - add check to see if sensor has initialised correctly.
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2974 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-31 04:31:36 +00:00
mich146@hotmail.com 69bd507d5a fix hil build
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2970 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-31 01:24:20 +00:00
jasonshort 150f58a4bd removed scaling on control in because it might cause rounding issues.
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2969 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-30 23:48:38 +00:00
jasonshort 4339ebb310 Reworked the filtering algorithm based on Maxbotics recommendations to use a Mode filter
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2968 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-30 23:34:25 +00:00
jasonshort 73be185414 Big update 2.0.38
moved ground start to first arming
added ground start flag
moved throttle_integrator to 50hz loop
CAMERA_STABILIZER deprecated - now always on
renamed current logging bit mask to match APM
added MA filter to PID - D term
Adjusted PIDs based on continued testing and new PID filter
added MASK_LOG_SET_DEFAULTS to match APM
moved some stuff out of ground start into system start where it belonged
Added slower Yaw gains for DCM when the copter is in the air
changed camera output to be none scaled PWM
fixed bug where ground_temperature was unfiltered
shortened Baro startup time
fixed issue with Nav_WP integrator not being reset
RTL no longer yaws towards home
Circle mode for flying a 10m circle around the point where it was engaged. - Not tested at all! Consider Circle mode as alpha.


git-svn-id: https://arducopter.googlecode.com/svn/trunk@2966 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-30 20:42:54 +00:00
jasonshort e1b677a25d Reworked the filtering algorithm based on Maxbotics recommendations to use a Mode filter
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2965 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-30 20:35:36 +00:00
jasonshort 61dc79f65b Added some missing functions needed to get HIL to compile
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2964 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-30 20:34:23 +00:00
jasonshort eb39d2d53a Added ability to grab an unfiltered value from the ADC
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2963 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-30 20:33:45 +00:00
tridge60@gmail.com da2a1d72e2 GPS: fixed the GPS specific test programs
This fixes the build

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2962 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-30 08:48:17 +00:00
mich146@hotmail.com 358fd56d57 Fix Hil build on 2560
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2961 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-30 01:39:12 +00:00
jasonshort 915a564b8f Changed the PID derivative filter to a moving average with 4 samples. Having great luck with it and High kD when using noisy sensors.
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2957 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-29 21:52:37 +00:00
tridge60@gmail.com 6061ee4b81 HIL: fixed radio_status in setHIL() for APM_RC
thanks to Michael Oborne for noticing this!

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2952 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-28 12:11:25 +00:00
rmackay9@yahoo.com 48b2f0bd9e TradHeli - updated gps mount design files
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2949 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-26 14:13:48 +00:00
rmackay9@yahoo.com 84a6fc4834 TradHeli - mounting plate and gps mount design files
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2946 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-26 12:42:36 +00:00
jphelirc 8907ee5b0a fixed defaults
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2944 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-26 03:44:16 +00:00
jphelirc 2d094da38e added relay control to CH6
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2943 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-26 03:37:41 +00:00
tridge60@gmail.com 586acf4342 fixed quad PWM clipping
this adopts the simpler approach suggested by Jason.

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2936 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-22 21:25:59 +00:00
mich146@hotmail.com 7210d6decb fix float issues - crosstrack & target alt
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2935 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-21 23:36:22 +00:00
rmackay9@yahoo.com f5d17f756a ACM - partial integration of optical flow sensor
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2934 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-21 23:14:53 +00:00
tridge60@gmail.com e80ed6d687 quad: fixed the clipping of PWM outputs
when we clip a motor output we need to decrease the opposite motor by
the same amount, otherwise we lose the ability to control the quad
when the servo outputs are extreme

Found using the quad HIL test. Thanks to Jani for testing this on a
real quad!

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2929 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-20 00:33:04 +00:00
rmackay9@yahoo.com 09256e12da DataFlash library - changed to use standard arduino SPI library
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2928 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-19 23:00:18 +00:00
tridge60@gmail.com 6e179db689 HIL: fixed build with HIL and logging
thanks to Jani for noticing this

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2925 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-19 10:51:07 +00:00
tridge60@gmail.com efae9dddd5 HIL: we only need 50Hz attitude for HIL
putting it in the fastest loop clogged up mavlink too much

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2923 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-19 09:49:57 +00:00
rmackay9@yahoo.com 3d641a3b45 AP_OpticalFlow - fixes to position calculations (lat was reversed and would calculate position even with surface quality was very low)
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2913 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-18 21:51:27 +00:00
jasonshort c79ff4f583 doubled Slew rate limiter to 2 m/s max @ 10 hz.
git-svn-id: https://arducopter.googlecode.com/svn/trunk@2912 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-18 18:18:47 +00:00
tridge60@gmail.com 98980d6f61 HIL: fixed altitude calculation
ACM uses a zero home altitude, so we need an offset when using GPS for
altitude

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2910 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-18 12:44:02 +00:00
tridge60@gmail.com 60bf2182e4 GPS-HIL: set new_data on setHIL()
this fixes navigation for ACM in HIL

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2909 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-18 12:42:36 +00:00
jasonshort b3e629cfbf 2.0.37
Added rate of change limit for noisy Sonars.
converted to static functions - Tridge
New Throttle PIDs from Jack

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2904 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 19:14:23 +00:00
jasonshort e07c0aab7a 2.0.37
Added rate of change limit for noisy Sonars.
converted to static functions - Tridge


git-svn-id: https://arducopter.googlecode.com/svn/trunk@2902 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 19:08:29 +00:00
jasonshort d04d32c40c 2.0.37
Added rate of change limit for noisy Sonars.
converted to static functions - Tridge


git-svn-id: https://arducopter.googlecode.com/svn/trunk@2901 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 19:08:17 +00:00
jasonshort a1733ee901 Added a slew rate limit
reworked filter, same results, just wanted to get rid of modulus.

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2900 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 19:05:18 +00:00
tridge60@gmail.com 6b0c938176 CLI: make it possible to completely disable the CLI
set CLI_ENABLED to DISABLED for no CLI. This saves a lot of memory

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2895 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:34:05 +00:00
tridge60@gmail.com e6d9a6921a HIL: don't access dcm functions in HIL mode
the dcm is not valid in HIL_MODE_ATTITUDE

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2894 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:33:53 +00:00
tridge60@gmail.com 863e77677e HIL: enable reception of GPS and ATTITUDE via MAVLink
this allows us to get GPS position and ATTITUDE in HIL_MODE_ATTITUDE

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2893 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:33:42 +00:00
tridge60@gmail.com 93a8deac7d HIL: send location information
we don't send MSG_LOCATION in HIL mode during GPS updates, as we don't
call the GPS update routines, so we need to send MSG_LOCATION as part
of the Position stream

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2892 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:33:33 +00:00
tridge60@gmail.com aff9e9a831 HIL: when in HIL_MODE_ATTITUDE, we get altitude from gps setHIL
we need to skip the barometer and sonar calls

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2891 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:33:17 +00:00
tridge60@gmail.com eb2a6403e0 don't force config in default APM_Config.h
defaults for these are already in config.h, but protected with #ifndef
wrappers. The #ifndef wrappers are useful to allow users to have
makefile targets for different configs, so you can (for example), do
"make heli" with a local makefile

This makes it easier for developers to ensure that all configs build
correctly

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2890 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:33:09 +00:00
tridge60@gmail.com df6a1b51f3 make a lot more functions and variables static
this saves about 1k of code space through better compiler optimisation

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2889 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:32:00 +00:00
tridge60@gmail.com 0b1262a685 make main variables and functions static
this makes most of the variables and functions in the main
ArduCopterMega.pde code static, which allows the compiler to optimise
better, and exposes unused variables as compiler warnings

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2888 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:31:46 +00:00
tridge60@gmail.com f9105a056e logging: moved the default log_bitmask calculation to compile time
this saves a little bit of code by moving the calculation of the
default log bitmask to compile time from runtime

(merge from APM)

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2887 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:31:17 +00:00
tridge60@gmail.com 8a7466d1a2 make it possible to completely disable logging
set LOGGING_ENABLED  to DISABLED to disable all logging. This saves
about 10k of flash when disabled.

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2886 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:31:07 +00:00
tridge60@gmail.com fdf090b471 allow flight modes to be setup over MAVLink
this adopts the same method of setting up flight modes over MAVLink as
APM now has

git-svn-id: https://arducopter.googlecode.com/svn/trunk@2885 f9c3cf11-9bcb-44bc-f272-b75c42450872
2011-07-17 10:30:53 +00:00