mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-25 05:23:34 +08:00
FlightTasks: move stick handling into library
This commit is contained in:
committed by
Julian Kent
parent
49a543e1b2
commit
9daff24e79
@@ -82,7 +82,7 @@ void FlightTaskManualPosition::_scaleSticks()
|
||||
FlightTaskManualAltitude::_scaleSticks();
|
||||
|
||||
/* Constrain length of stick inputs to 1 for xy*/
|
||||
Vector2f stick_xy = _sticks_expo.slice<2, 1>(0, 0);
|
||||
Vector2f stick_xy = _sticks.getPositionExpo().slice<2, 1>(0, 0);
|
||||
|
||||
const float mag = math::constrain(stick_xy.length(), 0.0f, 1.0f);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user