Switch manual_control_setpoint.z scaling from [0,1] to [-1,1]

To be consistent with all other axes of stick input and avoid future
rescaling confusion.

Note: for the MAVLink message 69 MANUAL_CONTROL it's using the full range
according to the message specs now [-1000,1000].
This commit is contained in:
Matthias Grob
2022-11-28 19:25:55 +01:00
parent 5579e319ff
commit 83246c84cf
13 changed files with 38 additions and 52 deletions
@@ -59,7 +59,7 @@ public:
if (_topic.update(&manual_control_setpoint)) {
_data[0] = manual_control_setpoint.y; // roll
_data[1] = manual_control_setpoint.x; // pitch
_data[2] = manual_control_setpoint.z * 2.f - 1.f; // throttle
_data[2] = manual_control_setpoint.z; // throttle
_data[3] = manual_control_setpoint.r; // yaw
_data[4] = manual_control_setpoint.flaps;
_data[5] = manual_control_setpoint.aux1;