Commit Graph

378 Commits

Author SHA1 Message Date
Lucas De Marchi de680dac5b global: use static method to construct AP_Scheduler 2017-09-26 03:01:21 +01:00
Lucas De Marchi 8094482f21 global: use static method to construct AP_GPS 2017-09-26 03:01:21 +01:00
Lucas De Marchi 87b30b4552 global: use static method to construct AP_InertialSensor 2017-09-26 03:01:21 +01:00
Lucas De Marchi c1a957fbf3 global: use static method to construct Compass 2017-09-26 03:01:21 +01:00
Lucas De Marchi 91feec0e14 global: use static method to construct AP_Baro 2017-09-26 03:01:21 +01:00
Lucas De Marchi 7eba6572ea ArduSub: move version to a static member
We should never include version.h or ap_version.h headers directly
on a header since this will trigger a complete rebuild of the
codebase when we commit to the repository. The ap_version.h header
is auto-generated containing information from the current commit.

If we include it in a header, every other file that ends up including
that header (directly or indirectly) will need to be rebuilt. No
ccache's cache beats having to do nothing when the header is just
not included.

version.h contains information that is kept on a struct inside
each vehicle. Rather than using the macros from each vehicle,
the getter should be preferred, which returns an AP_FWVersion
referente.
2017-09-23 21:37:45 -07:00
Randy Mackay a477ef7cd6 Sub: support SET_GPS_GLOBAL_ORIGIN message 2017-09-19 10:30:15 +09:00
Peter Barker 89e3f1dbd8 Sub: move gcs_out_of_time into GCS object 2017-09-12 18:28:07 +01:00
Peter Barker ae9891d291 Sub: add constant structure holding firmware version 2017-08-30 15:54:46 +01:00
Jacob Walser 0bd5d6ca18 Sub: send useful information to GCS 2017-08-23 13:40:52 +01:00
Peter Barker 5a9af5bc28 Sub: use GCS_MAVLINK subclasses to handle set_mode 2017-08-16 13:11:07 +01:00
Peter Barker 7c5ed54ffc Sub: move try_send_message send_hwstatus up 2017-08-03 14:33:37 +01:00
Peter Barker 7a72c3b1fb Sub: move try_send_message mission handling up 2017-08-03 14:24:47 +01:00
Peter Barker b299772a75 Sub: camera is responsible for taking distance-based-images and logging 2017-07-28 14:27:53 +01:00
Peter Barker 342d95ad2f Sub: move starting of new logs into DataFlash 2017-07-19 16:37:28 +01:00
Peter Barker 9f73d2f9d8 Sub: eliminate gcs_send_mission_item_reached wrapper 2017-07-11 23:45:16 +01:00
Peter Barker f82fa22833 Sub: eliminate gcs_end_message wrapper 2017-07-11 23:45:16 +01:00
Peter Barker 279072cf25 Sub: use send_text method on the GCS singleton 2017-07-09 17:17:29 -04:00
Peter Barker fadff24674 Sub: create GCS subclass, use inheritted methods
This also adds a patch to set up gcs channel 0 early to make
BoardConfig happy
2017-07-07 16:18:37 +01:00
Eugene Shamaev 7314b515c0 ArduSub: move of CAN parameters into separate group 2017-07-03 11:44:32 +01:00
Peter Barker f3a717f3c0 Sub: handle knowledge of in_log_download in DataFlash 2017-06-27 03:10:43 +01:00
Pierre Kancir 57ef598c07 ArduSub: change rangefinder msg for common one 2017-06-08 01:31:58 +01:00
Randy Mackay 5936fc1ff8 Sub: compass set-initial-location uses ahrs location
Previously it could attempt to use a gps location even if gps was not being used
Also compass-accumulate moved to sensors.cpp
2017-06-07 13:01:38 +09:00
Randy Mackay 7bae493138 Sub: consolidate set_home functions
added lock argument instead of having twice as many functions
no functional change
2017-06-07 13:01:38 +09:00
Jacob Walser 131e1bdef5 Sub: Bugfix for external baro failsafe handling when no baro is
connected at boot
2017-05-03 18:13:31 -04:00
Jacob Walser 697b095e99 Sub: Remove unused command_ack_counter 2017-04-16 14:25:13 -04:00
Jacob Walser d0171395b8 Sub: Remove baro_alt and baro_climbrate members
We can get this from baro object directly
2017-04-16 14:25:13 -04:00
Jacob Walser 8c6fa6f651 Sub: Remove unused ap.usb_connected flag 2017-04-16 14:25:13 -04:00
Jacob Walser c093e1c37e Sub: Add failsafe mechanisms for depth sensor error 2017-04-16 14:25:13 -04:00
Jacob Walser b7de1eb88a Sub: failsafe.manual_control -> failsafe.pilot_input
reset pilot input failsafe timer when RC_CHANNELS_OVERRIDE is received
2017-04-16 14:25:13 -04:00
Jacob Walser f7c4810eaa Sub: Remove ignore_check argument from control mode init functions 2017-04-16 14:25:13 -04:00
Jacob Walser b28c3584d4 Sub: Add ekf failsafe check 2017-04-16 14:25:13 -04:00
Jacob Walser 0b1a2c3959 Sub: Remove ekf_check.cpp and unused ekf failsafe methods 2017-04-16 14:25:13 -04:00
Jacob Walser 8b3c414ca7 Sub: Remove cliSerial alias for hal.console 2017-04-14 13:26:37 -04:00
Jacob Walser 84527d6e66 Sub: Remove unused auto_armed flag 2017-04-14 13:26:37 -04:00
Jacob Walser eb36153752 Sub: Reorganize #includes 2017-04-14 13:26:37 -04:00
Jacob Walser c599ba8c97 Sub: Disable Camera object by default and rework guards
Camera object hasn't been tested on Sub yet
2017-04-14 13:26:37 -04:00
Jacob Walser 9a35b4d7a4 Sub: Dont include AC_Rally if it's not enabled 2017-04-14 13:26:37 -04:00
Jacob Walser 4fb5a90446 Sub: Remove unused AP_Airspeed library dependency 2017-04-14 13:26:37 -04:00
Jacob Walser 6806989d86 Sub: Remove unused AP_ADC library dependency 2017-04-14 13:26:37 -04:00
Jacob Walser 5110c9cb40 Sub: Remove unused Buffer library dependency 2017-04-14 13:26:37 -04:00
Jacob Walser d3927e34e4 Sub: Remove unused InputManager library dependency 2017-04-14 13:26:37 -04:00
Jacob Walser af8514f1a3 Sub: Don't declare gripper functions if it's not enabled 2017-04-14 13:26:37 -04:00
Jacob Walser 854275459d Sub: Fix compile-time OPTFLOW enabling switch 2017-04-14 13:26:37 -04:00
Jacob Walser b3beb5e1c4 Sub: Remove undefined methods from Sub.h 2017-04-14 13:26:37 -04:00
Jacob Walser c16046aadf Sub: Remove unused motor emergency stop and interlock 2017-04-14 13:26:37 -04:00
Jacob Walser 2fac49a163 Sub: Remove unused pre_arm_check()
This is performed by AP_Arming now
2017-04-14 13:26:37 -04:00
Jacob Walser 1ee1c01e43 Sub: Remove two unused functions 2017-04-07 14:47:48 -04:00
Jacob Walser 3e471e808a Sub: Refactor methods in navigation.cpp 2017-04-07 14:47:48 -04:00
Jacob Walser 23c18335a3 Sub: failsafe_xxx -> mainloop_failsafe_xxx 2017-04-06 17:58:26 -04:00
Jacob Walser 875fb3946b Sub: Remove remaining references to simple mode 2017-04-06 17:31:40 -04:00
Jacob Walser ea8dbbf96c Sub: Remove HIL_MODE stuff 2017-04-06 14:11:12 -04:00
Jacob Walser 4349eaba32 Sub: Clean up radio.cpp 2017-04-06 14:11:12 -04:00
Jacob Walser 3df1aa09e8 Sub: Remove dead save_trim() 2017-04-06 14:11:12 -04:00
Jacob Walser 3b1827ca21 Sub: Remove throttle-zero flag
Doesn't help us like in Copter
2017-04-06 14:11:12 -04:00
Jacob Walser d794bf88cb Sub: Remove old/unused motor test code and motor_test.cpp 2017-04-06 14:11:12 -04:00
Jacob Walser d629d4ba9e Sub: Change mode button function implementation 2017-04-05 13:29:06 -04:00
Jacob Walser 69c9dbc286 Sub: Remove deprecated/unused CLI and AP_Menu 2017-04-05 13:29:06 -04:00
Jacob Walser b32b552d1e Sub: Implement crash failsafe check/action 2017-03-24 16:31:09 -04:00
Jacob Walser bc5d9b1a19 Sub: Remove unused lost_vehicle_check 2017-03-24 16:31:09 -04:00
Jacob Walser 1a68fce2d0 Sub: Remove auto_disarm_check
There isn't a good set of conditions to determine if we should
automatically disarm
2017-03-24 16:31:09 -04:00
Jacob Walser 45328f220c Sub: set_leak_status() -> failsafe_leak_check() 2017-03-24 16:31:09 -04:00
Jacob Walser 7859f6426e Sub: Implement battery failsafe 2017-03-24 16:31:09 -04:00
Jacob Walser 6bd05e4bac Sub: failsafe_battery_event() -> failsafe_battery_check() 2017-03-24 16:31:09 -04:00
Jacob Walser 3934281b43 Sub: Remove esc calibration 2017-03-23 11:59:30 -04:00
Jacob Walser b0e5a93099 Sub: Remove VELHOLD mode
Obsolete since GUIDED implemented
2017-03-23 01:36:17 -04:00
Jacob Walser 5b4ec88f11 Sub: Remove one layer of abstraction for ServoRelayEvents.update_events
call
2017-03-23 01:36:17 -04:00
Jacob Walser 2fa9d31787 Sub: Remove auto-trim
Sub vehicles usually have some static stability
2017-03-23 01:36:17 -04:00
Jacob Walser 15a117dfb4 Sub: Remove ch6 tuning 2017-03-23 01:36:17 -04:00
Jacob Walser 6886952438 Sub: Remove simple mode 2017-03-22 23:39:37 -04:00
Jacob Walser 0966dcb665 Sub: Implement MAV_CMD_NAV_RETURN_TO_LAUNCH 2017-03-22 15:53:38 -04:00
Jacob Walser 7c552d3545 Sub: Remove unsused aux switch code 2017-03-10 15:46:30 +11:00
Jacob Walser c1959952b3 Sub: Bug fix for camera_tilt_smooth() conflict with RC_CHANNELS_OVERRIDE 2017-03-10 15:46:30 +11:00
Jacob Walser 0ce2896e22 Sub: Remove rc receiver code 2017-03-10 15:46:30 +11:00
Jacob Walser 5acfc164df Sub: Implement crash check 2017-03-10 15:46:30 +11:00
Jacob Walser 93c6f64a91 Sub: Clean out/remove references to old landing code 2017-03-10 15:46:30 +11:00
Jacob Walser 9f5605ff57 Sub: Implement DO_NAV_LAND commands.
Auto return to surface in analagous manner to Copter's auto land.
2017-03-10 15:46:30 +11:00
Jacob Walser 8dc09440d8 Sub: Implement guided mode 2017-03-08 15:58:28 -05:00
jaxxzer 1ec592a2c5 Sub: Implement NAV_CMD_LOITER_TURNS 2017-03-07 09:35:41 +11:00
Jacob Walser ca38a344f8 Sub: Remove unsupported autotune 2017-03-07 09:35:41 +11:00
Jacob Walser dacdd542b7 Sub: Remove unsupported compassmot 2017-03-07 09:35:41 +11:00
Jacob Walser a62d728933 Sub: Move arming checks under AP_Arming_Sub 2017-03-01 10:57:27 -05:00
Jacob Walser d21cd513cd Sub: Add AP_Arming_Sub class 2017-03-01 10:57:27 -05:00
Jacob Walser 262f3213e7 Sub: Ditch relative include path 2017-02-28 16:55:00 -05:00
Randy Mackay 6798162a98 Sub: use only downward facing rangefinder 2017-02-27 15:18:34 +09:00
Jacob Walser 84c3c0d234 Sub: Add support for AP_AHRS_View 2017-02-21 11:26:14 +11:00
Jacob Walser 840521ac8c Sub: Remove transect mode
This experimental mode is no longer relevant
2017-02-21 11:26:14 +11:00
Peter Barker ee07a06fa2 Sub: support for a GCS singleton 2017-02-21 11:26:14 +11:00
Peter Barker 6fb2a6814f Sub: rename gcs[] to gcs_chan[]
Wish to use gcs() to return the gcs singleton
2017-02-21 11:26:14 +11:00
Jacob Walser 1990aa7829 Sub: Update stale references to Copter 2017-02-21 11:26:14 +11:00
Jacob Walser 65cd28cc6c Sub: Only save baro calibration parameters when user zeros 2017-02-21 11:26:14 +11:00
Jacob Walser 4112fd1316 Sub: Remove mode header 2017-02-21 11:26:14 +11:00
Jacob Walser 8d60a34474 Sub: Switch to AC_PosControl_Sub 2017-02-21 11:26:14 +11:00
Jacob Walser 565afc23ad Sub: Switch to AC_AttitudeControl_Sub 2017-02-21 11:26:14 +11:00
Jacob Walser 5233b25910 Sub: Format all C++ with Tools/CodeStyle/astylerc 2017-02-21 11:26:14 +11:00
Jacob Walser ed87bd9e59 Sub: fixes from rebase on ArduPilot master 2017-02-21 11:26:14 +11:00
Jacob Walser 852374ab4d Sub: Manual control failsafe 2017-02-21 11:26:14 +11:00
Jacob Walser 029cf3b388 Sub: Update to library changes 2017-02-21 11:26:14 +11:00
Jacob Walser 098a716d41 Sub: Add TSYS01 'celsius' object 2017-02-21 11:26:14 +11:00
Jacob Walser 6b3610ea70 Sub: Set frame configuration with parameter instead of make target
Now only one firmware is required for ArduSub
2017-02-21 11:26:14 +11:00
Jacob Walser b7e419cf9c Sub: Configure default joystick buttons 2017-02-21 11:26:14 +11:00
Jacob Walser 9ec79ab654 Sub: Remove RC radio failsafe 2017-02-21 11:26:14 +11:00
Jacob Walser 45de3b1163 Sub: Disable Avoidance and Proximity by default 2017-02-21 11:26:14 +11:00
Jacob Walser 8d2203b437 Sub: Remove use of throttle-hover 2017-02-21 11:26:14 +11:00
Jacob Walser 0d575681de Sub: Remove RTL 2017-02-21 11:26:14 +11:00
Jacob Walser 3010114adb Sub: Disable CH6 Tuning 2017-02-21 11:26:14 +11:00
Jacob Walser f10f1a0bae Sub: Remove throw mode 2017-02-21 11:26:14 +11:00
Jacob Walser 4571dbc57c Sub: Fix -Wundef compile warnings 2017-02-21 11:26:14 +11:00
Jacob Walser 6426ceec27 Sub: Disable RCMAP 2017-02-21 11:26:14 +11:00
Jacob Walser ee8670e73d Sub: Disable RPM 2017-02-21 11:26:14 +11:00
Jacob Walser 4cb9ee947b Sub: Disable autotune parameters 2017-02-21 11:26:14 +11:00
Jacob Walser 9c5b304626 Sub: Remove RSSI 2017-02-21 11:26:14 +11:00
Jacob Walser 7e1c63aba3 Sub: Remove sprayer 2017-02-21 11:26:14 +11:00
Jacob Walser 9503e8d140 Sub: Remove ADSB 2017-02-21 11:26:14 +11:00
Jacob Walser 8aebeac6d7 Sub: Remove precision landing 2017-02-21 11:26:14 +11:00
Jacob Walser db56bdf8b0 Sub: Remove landing gear 2017-02-21 11:26:14 +11:00
Jacob Walser 7b5d209aba Sub: Remove parachute 2017-02-21 11:26:14 +11:00
Jacob Walser a430f5a7ae Sub: Remove land/landed code 2017-02-21 11:26:14 +11:00
Jacob Walser b6d76912cf Sub: Remove takeoff code 2017-02-21 11:26:14 +11:00
Jacob Walser 41d892666b Sub: Remove Drift mode 2017-02-21 11:26:14 +11:00
Jacob Walser bc4084931f Sub: Remove Brake mode 2017-02-21 11:26:14 +11:00
Jacob Walser 2959ecc70f Sub: Remove Flip mode 2017-02-21 11:26:14 +11:00
Jacob Walser e2f75d2451 Sub: Remove old RC-style arm and disarm checks 2017-02-21 11:26:14 +11:00
Jacob Walser dd2d0711c0 Sub: Remove baro ground effect compensation 2017-02-21 11:26:14 +11:00
Jacob Walser 6682e93bf3 Sub: Refactor delay()
We don't need a dedicated file only to define a delay function.
This will also provide a preventitive measure for people trying to use
delay() without an understanding of the implications
2017-02-21 11:26:14 +11:00
Jacob Walser cbddc7d814 Sub: Remove control_switch_state struct and reset_control_switch() 2017-02-21 11:26:14 +11:00
Jacob Walser 8367bb4626 Sub: Ditch control mode RC switch logic
Call set_mode() directly from joystick button handler
2017-02-21 11:26:14 +11:00
Jacob Walser eb9aa93486 Sub: Remove dead poshold function declarations 2017-02-21 11:26:14 +11:00
Jacob Walser 5cc1d3293d Sub: Add gain parameters 2017-02-21 11:26:14 +11:00
Jacob Walser 456f5e2e93 Sub: Update Sub to match relevant Copter and Library developments 2017-02-21 11:26:14 +11:00
Jacob Walser 4704faf60d Sub: Revert to 29f8ce95, prior to deadzone PR 2017-02-21 11:26:14 +11:00
Jacob Walser 0b0cda02cc Sub: add method to get throttle channel control_in, while applying
deadzone to center like angle type channels
2017-02-21 11:26:14 +11:00
Jacob Walser dcc96a5705 Sub: First attempts at AUTO mode 2017-02-21 11:26:14 +11:00
Jacob Walser 56207ac284 Sub: AP_WaterDetector -> AP_LeakDetector 2017-02-21 11:26:14 +11:00
Jacob Walser 88e234272f Sub: add params for internal pressure/temperature failsafe actions 2017-02-21 11:26:14 +11:00
Jacob Walser 579f58e9f2 Sub: hold absolute heading in depth hold and poshold 2017-02-21 11:26:14 +11:00
Jacob Walser 1143f98fad Sub: Add GCS warnings for high internal pressure/temperature 2017-02-21 11:26:14 +11:00
Jacob Walser 0085cc8a27 Sub: rename modes loiter->velhold, sport->transect 2017-02-21 11:26:14 +11:00
Jacob Walser 5911785455 Sub: Add leak and gcs failsafe actions 2017-02-21 11:26:14 +11:00
Jacob Walser e2a7ba5b0c Sub: replace land with surface mode 2017-02-21 11:26:14 +11:00
Jacob Walser b364d94c43 Sub: Warn for leak detection 2017-02-21 11:26:14 +11:00
Jacob Walser a811cfe7fb Sub: Add WaterDetector object and parameters 2017-02-21 11:26:14 +11:00
Rustom Jehangir e1882d9596 Sub: Fix camera low pass filter and allow button holding. 2017-02-21 11:26:14 +11:00
Rustom Jehangir e9c2ad9192 Sub: Changes to match upstream Copter changes. 2017-02-21 11:26:14 +11:00
jaxxzer 38be177e47 Sub: Add manual mode functions 2017-02-21 11:26:14 +11:00
jaxxzer e016e906f5 Sub: Create new Vectored 90DEG (6DOF) class 2017-02-21 11:26:14 +11:00
Rustom Jehangir 5adcb2cbef Sub: Changes based on diff with Copter. 2017-02-21 11:26:14 +11:00
Rustom Jehangir 814605c461 Sub: Make changes to match Copter changes 2017-02-21 11:26:14 +11:00
Rustom Jehangir accbbce304 Sub: Turn counter (#23)
* Sub: Add turn counter to avoid tether tangling.

* Sub: Add turn counter.

* Sub: Bug fix in turn counter.
2017-02-21 11:26:14 +11:00
Rustom Jehangir 9198b8cb29 Sub: Changes to match recent Copter updates. 2017-02-21 11:26:14 +11:00
Rustom Jehangir 26d0a922c1 Sub: Changes to match recent Copter updates. 2017-02-21 11:26:14 +11:00
Rustom Jehangir e857f20784 Sub: Changes to match Copter 2017-02-21 11:26:14 +11:00
Rustom Jehangir d628b0d022 Sub: Add 'SimpleROV' frame configuration for 3/4-dof ROVs 2017-02-21 11:26:14 +11:00
Rustom Jehangir 617b439d0e Sub: Match Copter changes 2017-02-21 11:26:14 +11:00
Rustom Jehangir 3b679808f3 Sub: Match Copter changes. 2017-02-21 11:26:14 +11:00
Rustom Jehangir c1f05b9e25 Sub: Match copter mode change stuff 2017-02-21 11:26:14 +11:00
Rustom Jehangir 837f429bf0 Sub: Refactor 'strafe' to 'lateral' 2017-02-21 11:26:14 +11:00
Rustom Jehangir 3a942434e7 Sub: Change to cmath header. 2017-02-21 11:26:14 +11:00
Rustom Jehangir 7e7b7c9afb Sub: Add low pass filter (from Copter) 2017-02-21 11:26:14 +11:00
Rustom Jehangir 684bc249b6 Sub: Update to match upstream, part 1 2017-02-21 11:26:14 +11:00
Rustom Jehangir e0d3eba5a4 Sub: Match Copter changes 2017-02-21 11:26:14 +11:00
Rustom Jehangir 802f4f617f Sub: Clean joystick code with helpers 2017-02-21 11:26:14 +11:00
Rustom Jehangir ef53455e2d Sub: Implement joystick button actions 2017-02-21 11:26:14 +11:00
Rustom Jehangir 44904760cc Sub: Add JSButton parameters to necessary places 2017-02-21 11:26:14 +11:00
Rustom Jehangir 85f972ec65 Sub: Update to match Copter changes. 2017-02-21 11:26:14 +11:00
Rustom Jehangir d159320ac0 Sub: Add throw mode to match Copter.
This is probably never going to be used for Sub unless there is some crazy situation I can't think of. However, we are continuing to maintain Copter changes for now to minimize divergence of the code and make maintenance easy.
2017-02-21 11:26:14 +11:00
jaxxzer bde64bc919 Sub: top and bottom detection working well
althold makes good use of the information and will refuse to attempt to
fly out of the water or dig underground
2017-02-21 11:26:14 +11:00
jaxxzer b36300135a Sub: Add surface and bottom detection capabilities 2017-02-21 11:26:14 +11:00
jaxxzer 00e1c847a6 Sub: top and bottom detection working well
althold makes good use of the information and will refuse to attempt to
fly out of the water or dig underground
2017-02-21 11:26:14 +11:00
jaxxzer b6a0237a63 Sub: Add surface and bottom detection capabilities 2017-02-21 11:26:14 +11:00
Rustom Jehangir 3869ce55e8 Sub: Changes to match Copter updates. 2017-02-21 11:26:14 +11:00
David Ingraham 473016b41d Sub: Add support for Vectored 6DOF ROV
Sub: Various defines for vectored-6dof configuration

Sub: fix compile errors for vector6dof rov

More fixes
2017-02-21 11:26:14 +11:00
Rustom Jehangir 6cf24c2770 Sub: Remove heli support from sub. 2017-02-21 11:26:14 +11:00
Rustom Jehangir 105eae0e86 Sub: Remove ADSB support 2017-02-21 11:26:14 +11:00
Rustom Jehangir 1d0ddcc270 Sub: Changes to match Copter updates 2017-02-21 11:26:14 +11:00
Rustom Jehangir 771ce2f607 Sub: Separated motor files and frame types 2017-02-21 11:26:14 +11:00
Rustom Jehangir c15d7299fa Sub: Sub changes to match newest Copter changes 2017-02-21 11:26:14 +11:00
Rustom Jehangir 83ff3931b8 Sub: Refactor "Copter" to "Sub". 2017-02-21 11:26:14 +11:00