Commit Graph

414 Commits

Author SHA1 Message Date
Daniel Agar d641d776f7 mc_pos_control delete unused velocity feed forwards 2017-06-26 11:31:25 -04:00
Daniel Agar f947205cbe delete vehicle_global_velocity_setpoint 2017-06-26 11:31:25 -04:00
ChristophTobler 91a94ce874 check for NAN -> use curr pos and check if first to avoid drifting 2017-06-19 13:26:11 +02:00
ChristophTobler bc406a122e disable min loiter altitude 2017-06-15 09:18:35 +02:00
Dennis Mannhart e0d81b4c5e mc_pos_control: if triplet not valid in z ignore it 2017-06-07 16:43:36 +02:00
Dennis Mannhart 2a943f4bd0 mc_pos_control: only set current_setpoint to true if triplet valid 2017-06-07 16:43:36 +02:00
Dennis Mannhart 32685338c9 mc_pos_control: simplify transition with just using triplets 2017-05-15 15:41:47 +02:00
Dennis Mannhart a98c0ef25d mc_pos_control: during transition set vel_sp to zero 2017-05-15 15:41:47 +02:00
Dennis Mannhart 00c9e4b79f mc_pos_control: set triplets.valid to first time when landed 2017-05-15 15:41:47 +02:00
Dennis Mannhart 9e383f2cd3 navigator: when landed only exit idle if mission/takoff 2017-05-15 15:41:47 +02:00
Dennis Mannhart 29795fa95f mc_pos_control: switch to auto only if triplets have been updated 2017-05-09 11:54:50 +02:00
Julian Oes bcd66f1408 mc_pos_control: ignore a NaN/inf position setpoint (#7186)
* mc_pos_control: ignore a NaN/inf position setpoint

This is a hotfix that prevents the position controller from trying to
do velocity control with a position setpoint that isn't valid in the
first place.

This is only a workaround, ideally the controls later should not scale
down throttle to the minimum just because the position setpoint is far
away if they still have valid setpoint in z.

* mc_pos_control: use PX4_ISFINITE and not isfinite
2017-05-04 22:55:53 +02:00
ChristophTobler dce28454c8 use current local position for land and not GPS -> e.g. flow 2017-05-03 16:52:37 +02:00
Lorenz Meier 118b9aad19 MC pos control: Document the reference update handling function better 2017-05-01 17:23:11 +02:00
Matthias Grob 0c4719de3e mc_pos_control: smooth takeoff, fixed gradient of the velocity ramp by takeoff speed parameter
because we need a workaround for the broken auto takeoff logic which can start the vehicle with a loiter setpoint
in this case the very first moment is still a jump but then it gets taken over by the fix gradient ramp
this can basically be reverted after the auto takeoff logic is fixed
2017-04-27 14:05:20 +02:00
Matthias Grob b5820afa14 mc_pos_control: smooth takeoff, fixed ramp reset bug and takeoff speed limiting condition
currently when the vehicle is landed again (not after bootup) the core position controller does not run anymore
therefore the velocity limit ramp in some cases did not get reset correctly

speed limiting in auto takeoff mode only needs to be limited when the user did not take over
2017-04-27 14:05:20 +02:00
Matthias Grob 9a162a24bb mc_pos_control: improved smooth takeoff and used it for manual takeoff as well
adresses:
there were setpoint twitches at the beginning and end of my smooth takeoff routine
it was to slow and not configurable
it was only available for automatic takeoff
2017-04-27 14:05:20 +02:00
Matthias Grob 75872b0713 mc_pos_control: switched auto takeoff to clean position control to takeoff point with gradual velocity limit
auto takeoff  was pretty chaotic and bypassed the velocity controller until some magic condition
the goal of this approach is to make the behaviour and smoothness more predictable and reuse the exact same logic for manual takeoff
2017-04-27 14:05:20 +02:00
Matthias Grob 5fd6bfc18c mc_pos_control: reorder velocity setpoint limiting, adding comments 2017-04-27 14:05:20 +02:00
Matthias Grob f5964ec237 mc_pos_control: pure refactor, reduce one level of indentation in calculate_thrust_setpoint 2017-04-27 14:05:20 +02:00
Matthias Grob 40d058558b mc_pos_control: pure refactor, split up core position control into velocity and thrust setpoint generation 2017-04-27 14:05:20 +02:00
Matthias Grob 709bd8cb28 mc_pos_control: combine separate pitch and roll maximum tilt angles into one
because there is no sense to have different angle scalings into different directions
it would lead to unintuitive piloting experience
acceleration is directly coupled to the tilt angle regardless of possible assymetric multicopter vehicles
2017-04-20 13:20:01 +02:00
Daniel Agar f460f5b34c mc_pos_control minor cleanup 2017-04-17 20:31:46 +02:00
Chris Lovett 91d2ad17b7 Fix takeoff overshoot (issue #319). 2017-04-17 14:35:16 +02:00
Dennis Mannhart 8687d414bf mc_pos_control: new variable that defines speed in manual controlled mode 2017-04-10 21:34:00 +02:00
Daniel Agar c5e0bf1c2f uORB combine VTOL FW and MC virtual topics (#7008) 2017-04-09 13:17:20 -04:00
Lorenz Meier 3b743fbbe9 MC position control: Smoother takeoff
This patch ramps up the throttle to hover throttle instead of a fixed value and limits the vertical takeoff speed to the value set in the parameter. This should ensure smoother, slower takeoffs, in particular in autonomous flight modes.
2017-04-09 17:22:58 +02:00
Dennis Mannhart 4ff3fb4dee mc_pos_control: if takeoff setpoint in auto mode, then do not enter ground contact 2017-04-09 17:19:28 +02:00
Dennis Mannhart 419c474d53 mc_pos_control: manual input temporary yaw fix 2017-03-30 16:43:43 +02:00
Dennis Mannhart be500723cd mc_pos_control: gradual vel fix for slope 2017-03-22 15:21:34 +01:00
Dennis Mannhart 20a47a1a72 mc_pos_control: limit if just xy distance close to target 2017-03-22 15:21:34 +01:00
Dennis Mannhart f9551c12de mc_pos_control: param fix and gradual vel fix 2017-03-22 15:21:34 +01:00
Matthias Grob 72fb7a5062 mc_pos_control: added gradual landing speed logic
depending on two altitudes that can get set as parameter
the logic linearly slows down from higher land altitude 1 to slower land altitude 2
2017-03-22 15:21:34 +01:00
Matthias Grob 7434bcc693 mc_pos_control: fixed rebase and refactor errors 2017-03-22 15:21:34 +01:00
Dennis Mannhart cd8cc1beaa mc_pos_control: use blockparam, change variable name, delete unused variables 2017-03-22 15:21:34 +01:00
Dennis Mannhart 4c4f214ec7 mc_pos_control: target_threshold value change
mc_pos_control: reorder if statement

mc_pos_control:  add get function for cruising speed
2017-03-22 15:21:34 +01:00
Dennis Mannhart 0d6f994145 mc_pos_control: slow down in auto when close to target
mc_pos_control: move limit vel xy after velocity controller
2017-03-22 15:21:34 +01:00
Dennis Mannhart 8e5a573cb3 mc_pos_control: add default only if there is no previous setpoint 2017-03-22 15:21:34 +01:00
Dennis Mannhart fd3889b5a6 mc pos control: auto handling such that it does not use slewrate when goint to pos 2017-03-22 15:21:34 +01:00
Matthias Grob 5e2f18ebaa mc_pos_control: added separate velocity control setpoint slewrate for deceleration
to improve the smooth user experience while accelerating
but not have any delay when braking
2017-03-22 15:21:34 +01:00
Matthias Grob b32e5e7ec0 mc_pos_control: fixed all pull request complaints
mainly changing parameters to BlockParams, reorder them and comment
2017-03-22 15:21:34 +01:00
Matthias Grob 470c3fdc06 mc_pos_control: refactoring only in manual velocity setpoint generation 2017-03-22 15:21:34 +01:00
Matthias Grob 713ba45876 mcpos_control: remove duplicate deadzone parameters 2017-03-22 15:21:34 +01:00
Matthias Grob eec757915c mc_pos_control: switch manual vertical/z velocity curve to expo with deadzone 2017-03-22 15:21:34 +01:00
Dennis Mannhart 8f1e851911 Stick to velocity fix (#6825)
* mc_pos_control: use just float for vel and cruise in xy

* mc_pos_control: stick map saturate magnitude to 1

* mc_pos_control: take minimum cruising speed for auto

* mc_pos_control: cruise speed triplet higher than from mc_pos_control

mc_pos_control: fix if for cruise in auto

* mc_pos_control: use PX4_ISFINITE criteria
2017-03-21 07:58:47 +01:00
Dennis Mannhart c9643cb075 mc_pos_control: delete leftover from transitional changes for vel_max_z (#6822) 2017-03-20 10:06:29 +01:00
Dennis Mannhart 31aff0b6c0 mc_pos_control: change yaw setpoint to yaw (#6854) 2017-03-20 10:05:33 +01:00
Matthias Grob ca9393eb97 mc_pos_control: fix parameter description of expo for QGC parsing 2017-03-16 11:42:27 +01:00
Dennis Mannhart e892a51afb mc_pos_control: delta_t needs to be positive 2017-03-01 11:46:23 +01:00
Dennis Mannhart 7f54f891c1 land_detector: set max height to 100 2017-02-27 22:54:19 +01:00