Tom Pittenger
7271586a47
Plane: invert auto_state.no_crosstrack flag to be auto_state.crosstrack. Non-functional change
2017-11-23 09:25:18 -08:00
André Kjellstrup
1d27e21d83
Plane: Option to trig by distance only when in AUTO mode
2017-11-14 00:10:22 +00:00
Michael du Breuil
d52f5155f0
Plane: Rename rc failsafe state members
2017-11-02 16:46:08 -07:00
Andrew Tridgell
af893ddde7
Plane: implement Q_OPTIONS
...
this allows for NAV_TAKEOFF to be treated as NAV_VTOL_TAKEOFF in
quadplanes, and for level flight to be maintained during quadplane
transitions
2017-10-30 16:30:10 +11:00
Tom Pittenger
8adacfeea3
Plane: always log MODE and include reason when logging is enabled
2017-10-25 21:18:29 +11:00
Peter Barker
4ce051af82
Plane: ensure we're in short failsafe before using failsafe.ch3_timer_ms
2017-10-24 09:28:13 +11:00
Peter Barker
7feef72b34
Plane: improve failsafe notifications
2017-10-24 09:28:13 +11:00
Peter Barker
01d8c506d2
Plane: add option to entirely disable short failsafe
2017-10-24 09:28:13 +11:00
Lucas De Marchi
f5c2ffffb9
global: remove DataFlash from AP_Mount::init()
2017-09-26 03:01:21 +01:00
Lucas De Marchi
36c80daa86
ArduPlane: do not include version.h/ap_version.h
...
The interface provided by each vehicle should be used to get the
version.
2017-09-23 21:37:45 -07:00
Peter Barker
c15c1b84a4
Plane: add constant structure holding firmware version
2017-08-30 15:54:46 +01:00
Andrew Tridgell
d541ac509f
Plane: removed TRIM_RC_AT_START parameter
...
this option caused a lot more problems than it solved, and is buggy
2017-08-29 07:35:49 +10:00
Peter Barker
8eeae45300
Plane: use GCS_MAVLINK subclasses to handle set_mode
2017-08-16 11:58:10 +10:00
Peter Barker
1a665280e9
Plane: remove CLI
2017-08-14 10:23:50 +09:00
Peter Barker
fa39f315c6
Plane: move starting of new logs into DataFlash
2017-07-19 16:37:28 +01:00
Peter Barker
5a8f01c19c
Plane: use send_text method on the GCS singleton
2017-07-09 17:17:29 -04:00
Eugene Shamaev
b95ebadf8b
ArduPlane: move of CAN parameters into separate group
2017-07-03 11:44:32 +01:00
Peter Barker
1ca5f243a5
Plane: check dataflash to see if we should log backend gps messages
2017-06-29 15:43:38 +01:00
Peter Barker
949e07c7e3
Plane: use DataFlash should_log to determine raw IMU logging
2017-06-29 15:26:27 +01:00
Peter Barker
88a7167cb9
Plane: move should_log check of log bitmask into DataFlash
2017-06-29 15:26:27 +01:00
Peter Barker
5b70b688cb
Plane: handle knowledge of in_log_download in DataFlash
2017-06-27 03:10:43 +01:00
Peter Barker
30dfd32b87
Plane: stop using in_mavlink_delay as a proxy for disabling logging
2017-06-16 17:07:48 +01:00
Peter Barker
b57a4e9685
Plane: call dataflash should_log method
2017-06-16 17:07:48 +01:00
Peter Barker
4dc241fd22
Plane: StartUnstartedLogging replaces logging_started/start_logging
2017-06-11 20:34:12 +01:00
Peter Barker
927cc75843
Plane: simplify should_log (NFC)
2017-06-11 20:34:12 +01:00
Peter Barker
084242cf03
Plane: move init of DataFlash references into vehicle init
...
It is possible to start a log before the existing codepath is crossed.
2017-05-01 15:04:34 +01:00
Andrew Tridgell
3eeff938b0
Plane: call BoardConfig.init_safety() at end of startup
...
this fixes a bug where motors can start on soft reboot
2017-04-30 21:47:04 +10:00
Andrew Tridgell
954905e0eb
Plane: allow battery failsafe with usb connected
...
some people connect USB to allow connections from a companion
computer. The arming check is sufficient to prevent unwanted battery
failsafes when bench testing
2017-04-28 16:33:49 +10:00
Andrew Tridgell
516bf26719
Plane: fixed QRTL change when coming from loiter
...
the nav controller can think we have already reached the loiter target
if we were last in a LOITER when we switch to RTL. In that case it
would switch to QRTL immediately
found by Leonard (thanks!)
2017-04-24 16:28:59 +10:00
Andrey Kolobov
35d406aeab
Plane: added a soaring controller to Arduplane
2017-03-14 08:53:10 +11:00
Michael du Breuil
9e893eacd1
Plane: Change some user facing statustexts
2017-03-08 00:59:56 -08:00
Andrew Tridgell
abcc75009d
Plane: move relay init earlier
...
allows relay pins to be used as pullups for other sensors (such as
LidarLiteV3)
2017-03-01 22:44:37 +11:00
Peter Barker
97145f20fc
Plane: fix startup of CLI menu system
2017-02-20 00:06:23 -08:00
Peter Barker
1d7994e9ba
Plane: create GCS_Plane subclass
2017-02-13 17:03:06 +11:00
Peter Barker
49bf336539
Plane: Support for a GCS singleton
2017-02-13 09:32:01 +11:00
Peter Barker
d060670ba3
Plane: rename gcs[] to gcs_chan[]
...
Wish to use gcs() to return the gcs singleton
2017-02-13 09:32:01 +11:00
murata
2492b9db7e
Plane: Unify from print or println to printf.
2017-01-27 18:20:22 +11:00
Tom Pittenger
650e694eb1
Plane: move landing.reset to landing.do_land()
2017-01-26 13:11:44 -08:00
Tom Pittenger
61bc0a6206
Plane: check stage==LAND instead of landing.in_progress
2017-01-26 13:11:44 -08:00
Randy Mackay
fc4741395d
Plane: notify initialised after parameters loaded
2017-01-23 15:07:21 -08:00
Randy Mackay
fad2ba608f
Plane: send flight mode string to Notify
2017-01-23 15:07:21 -08:00
Randy Mackay
af514eb101
Copter: remove some comments
2017-01-23 15:07:20 -08:00
Dmitry Prokhorov
497a4bd4a5
ArduPlane: Support for OLED display by Alexey Kozin
...
https://github.com/ArduPilot/ardupilot/pull/5135
2017-01-23 15:07:20 -08:00
Andrew Tridgell
3338b4295e
Plane: use reload_defaults_file()
2017-01-12 17:39:37 +11:00
Andrew Tridgell
cb4ebdd7b4
Plane: fixed throttle_percentage()
...
thanks to Buzz for noticing!
2017-01-12 17:39:37 +11:00
Andrew Tridgell
b83f50be0f
Plane: use new SRV_Channels API
2017-01-12 17:39:37 +11:00
Tom Pittenger
04f32b6ec6
Plane: simplify flight stage landing check to use landing.in_progress
2016-12-30 23:50:03 -08:00
Tom Pittenger
c286ceba43
Plane: move enum FlightStages to AP_Vehicle::FixedWing
2016-12-30 23:50:03 -08:00
Tom Pittenger
83f0a8114b
Plane: use a common reset for uniform landing wipe
2016-12-14 04:32:30 -08:00
Andrew Tridgell
3dcf4cfb55
Plane: removed resetting integrators on mode change
...
this removes the zero of roll, pitch and yaw integrator on mode
change, now only doing the steering integrator.
The zeroing was from the early days when our controllers were not as
good. It should not be needed any more.
2016-12-14 20:22:56 +11:00
Peter Barker
98b5ab4656
Plane: remove incorrect comment about logging/in_mavlink-delay
2016-11-29 15:14:09 -08:00
Peter Barker
17f5ef4610
Plane: inform dataflash of vehicle arm state
2016-11-28 09:42:09 -08:00
Tom Pittenger
e919afad1e
Plane: update comment and remove redundant work
...
- update_flight_stage is already called within restart_landing_sequence()
2016-11-25 19:07:30 -08:00
Tom Pittenger
fc2f518f31
Plane: revert auto_state.checked_for_autoland back to Plane
2016-11-25 19:07:30 -08:00
Tom Pittenger
9a79b79f1e
AP_Landing: port more from plane
2016-11-25 19:07:30 -08:00
Tom Pittenger
f556f705e6
Plane: move various g params to aparms
2016-11-25 19:07:30 -08:00
Tom Pittenger
d2376b7c8b
Plane: migrate two helper functions to AP_Landing
...
- move functions restart_landing_sequence() and jump_to_landing_sequence() to AP_Landing
- NOTE: jump_to function can not set mode, so it is now done externally in vehicle
2016-11-25 19:07:30 -08:00
Tom Pittenger
896b931a7c
Plane: Move auto_state variables to AP_landing members
2016-11-25 19:07:30 -08:00
Andrew Tridgell
5ed8418305
Plane: move radio init after boardconfig init
...
to ensure px4io is setup first
2016-11-13 14:55:35 +11:00
murata
ab99ea54eb
Plane: To nullptr from NULL.
2016-10-29 10:32:05 -03:00
Peter Barker
98ae6c776a
Plane: support for AP_Stats (flight time, bootcount, runtime)
2016-10-29 14:53:25 +09:00
Mathieu OTHACEHE
152edf7189
Global: remove mode line from headers
...
Using a global .dir-locals.el file is a better alternative than
reincluding the same emacs header in every file of the project.
2016-10-24 09:42:01 -02:00
Andrew Tridgell
c3aaff122b
Plane: fixed startup order of setting mavlink system ID
2016-10-17 09:20:55 +11:00
Tom Pittenger
94f83c3e78
Plane: frsky telem init to utilize default arguments
2016-09-25 10:42:02 -07:00
floaledm
4f6a8a017c
Plane: consolidate into a single frsky.init()
2016-09-25 10:42:02 -07:00
floaledm
0b666d4933
Plane: Plane support for Frsky passthrough protocol
2016-09-21 12:12:37 -07:00
Andrew Tridgell
9b83781b4f
Plane: fixed mixer arming error with FMUv4
...
thanks to Tim Gold for reporting this
2016-09-11 08:25:40 +10:00
Andrew Tridgell
a0fb426a34
Plane: fixes for Fraky_Telem API changes
2016-08-25 10:16:20 +10:00
floaledm
71921f3aa4
Plane: removed frsky_telemetry_send scheduled task
2016-08-25 10:16:17 +10:00
Tom Pittenger
b187e1f9a6
Plane: add reason to set_mode()
2016-08-17 22:38:54 -07:00
Tom Pittenger
ca32bcc58d
Plane: add new flight mode AVOID_ADSB to mimic GUIDED
2016-08-17 22:38:54 -07:00
Andrew Tridgell
76b6cbbda1
Plane: prevent motor startup on reboot in quadplanes
...
we need to prevent RC overrides within px4io from running
2016-08-16 12:53:34 +10:00
Andrew Tridgell
82382a7e9c
Plane: changed startup order
...
this allows BoardConfig to report errors in a way that allows for
BRD_TYPE to be changed by the user
2016-08-10 19:54:01 +10:00
Tom Pittenger
f90957e7ed
Plane: remove all threat logic in adsb lib in favor of avoidance lib
2016-08-01 15:27:41 -07:00
mirkix
5f5c200625
ArduPlane: Fix filename in header
2016-07-28 18:24:24 -03:00
Tom Pittenger
ab38b12f2c
Plane: adsb specific status updates
2016-07-20 22:40:14 -07:00
Andrew Tridgell
e8976d3a89
Plane: check for optflow enable in more places
2016-07-12 09:05:52 +10:00
mirkix
d018a32545
Plane: Only init optflow when enabled by parameter
2016-07-12 09:00:46 +10:00
Andrew Tridgell
96d785f1c6
Plane: added auto_navigation_mode flag
...
this fixes a problem where modes like loiter and auto would allow for
rudder stick mixing even with STICK_MIXING=0
2016-07-05 12:52:13 +10:00
Tom Pittenger
0597dbd033
Plane: allow SET_ATTITUDE_TARGET to set rpy and throttle
2016-07-01 08:28:53 -07:00
Tom Pittenger
85afd9e245
Plane: remove guided roll flag, handle it with timer=0
2016-06-30 07:48:37 -07:00
Michael Day
8ac433f991
Plane: Can now command roll from a companion computer.
2016-06-30 10:27:44 -04:00
Andrew Tridgell
ec367d4a09
Plane: re-order channel initialisation
...
this fixes a problem with spurious throttle output during board
startup. Many thanks to Marco for finding this!
2016-06-30 16:48:30 +10:00
Andrew Tridgell
bf2e30f858
Plane: removed demo_servos()
...
this really didn't help much and slows down startup
2016-06-27 10:19:26 +10:00
Andrew Tridgell
d3494d1369
Plane: don't stall EKF during baro cal
2016-05-24 17:00:56 +10:00
Andrew Tridgell
4a7dea0c5b
Plane: simplify UART setup
2016-05-21 15:25:16 +10:00
dgrat
48c243bed0
ArduPlane: Do not use is_zero() for non-float types
2016-05-16 19:08:35 -03:00
Andrew Tridgell
12e0012b16
Plane: allow for NAV_LOITER_UNLIM and NAV_LOITER_TIME in quadplane
2016-05-11 15:57:41 +10:00
Andrew Tridgell
3fc43b94f9
Plane: separate out auto and guided VTOL states
...
this prevents a switch to AUTO from using VTOL mode incorrectly
2016-05-11 15:14:43 +10:00
skyscraper
7f29903287
ArduPlane: Fix up after refactoring RC_Channel class
...
Further to refactor of RC_Channel class which included
adding get_xx set_xx methods, change reads and writes to the public members
to calls to get and set functionsss
old public member(int16_t) get function -> int16_t set function (int16_t)
(expression where c is an object of type RC_Channel)
c.radio_in c.get_radio_in() c.set_radio_in(v)
c.control_in c.get_control_in() c.set_control_in(v)
c.servo_out c.get_servo_out() c.set_servo_out(v)
c.pwm_out c.get_pwm_out() // use existing
c.radio_out c.get_radio_out() c.set_radio_out(v)
c.radio_max c.get_radio_max() c.set_radio_max(v)
c.radio_min c.get_radio_min() c.set_radio_min(v)
c.radio_trim c.get_radio_trim() c.set_radio_trim(v);
c.min_max_configured() // return true if min and max are configured
Because data members of RC_Channels are now private and so cannot be written directly
some overloads are provided in the Plane classes to provide the old functionality
new overload Plane::stick_mix_channel(RC_Channel *channel)
which forwards to the previously existing
void stick_mix_channel(RC_Channel *channel, int16_t &servo_out);
new overload Plane::channel_output_mixer(Rc_Channel* , RC_Channel*)const
which forwards to
(uint8_t mixing_type, int16_t & chan1, int16_t & chan2)const;
Rename functions
RC_Channel_aux::set_radio_trim(Aux_servo_function_t function)
to RC_Channel_aux::set_trim_to_radio_in_for(Aux_servo_function_t function)
RC_Channel_aux::set_servo_out(Aux_servo_function_t function, int16_t value)
to RC_Channel_aux::set_servo_out_for(Aux_servo_function_t function, int16_t value)
Rationale:
RC_Channel is a complicated class, which combines
several functionalities dealing with stick inputs
in pwm and logical units, logical and actual actuator
outputs, unit conversion etc, etc
The intent of this PR is to clarify existing use of
the class. At the basic level it should now be possible
to grep all places where private variable is set by
searching for the set_xx function.
(The wider purpose is to provide a more generic and
logically simpler method of output mixing. This is a small step)
2016-05-10 16:21:16 +10:00
Andrew Tridgell
dcb24f2bc1
Plane: use DataFlash::log_while_disarmed()
2016-05-09 12:05:25 +10:00
Lucas De Marchi
baa287e5e5
ArduPlane: use separate header for version macro
...
Having the version macro in the config.h and consequently in the main
vehicle header means that whenever the version changes we need to
compiler the whole vehicle again. This would not be so bad if we weren't
also appending the git hash in the version. In this case, whenever we
commit to the repository we would need to recompile everything.
Move to a separate header that is include only by its users. Then
instead of compiling everything we will compile just a few files.
2016-05-06 13:11:28 -03:00
Andrew Tridgell
4666b25258
Plane: initial implementation of QRTL for quadplane RTL
2016-04-30 14:34:47 +10:00
Andrew Tridgell
00c2b4b30f
Plane: reload airspeed after VTOL landing
2016-04-28 08:42:19 +10:00
Andrew Tridgell
38a7bfd81f
Plane: added Q_ENABLE=2 for starting AUTO in VTOL
2016-04-23 21:03:46 +10:00
Andrew Tridgell
cf7b6123a9
Plane: log the number of lost log messages
2016-04-21 16:45:02 +10:00
Andrew Tridgell
8683616d8c
Plane: redo scheduler table and improve perf logging
...
The scheduler table was still setup for a worst case CPU of
AVR2560. Adjust times for the stm32 and improve perf logging
2016-04-21 16:45:02 +10:00
Andrew Tridgell
a7006a7784
Plane: refactor perf variables into a structure
2016-04-21 16:45:02 +10:00
Michael du Breuil
78442b7e81
Plane: make the initialization of the gcs instances follow the define
2016-04-11 17:54:46 -07:00
Andrew Tridgell
8b30569ad1
Plane: setup quadplane earlier in startup
...
this ensures the GCS gets the full parameter list as the param count
will be set before mavlink starts
2016-04-03 06:49:38 +10:00