simulator_mavlink: fix type passed to param_get()

This commit is contained in:
Beat Küng
2017-10-24 21:59:24 +02:00
committed by Lorenz Meier
parent c35b0aa270
commit 07d7b29729
+3 -2
View File
@@ -1106,8 +1106,9 @@ int Simulator::publish_flow_topic(mavlink_hil_optical_flow_t *flow_mavlink)
flow.quality = flow_mavlink->quality;
/* rotate measurements according to parameter */
enum Rotation flow_rot;
param_get(param_find("SENS_FLOW_ROT"), &flow_rot);
int32_t flow_rot_int;
param_get(param_find("SENS_FLOW_ROT"), &flow_rot_int);
const enum Rotation flow_rot = (Rotation)flow_rot_int;
float zeroval = 0.0f;
rotate_3f(flow_rot, flow.pixel_flow_x_integral, flow.pixel_flow_y_integral, zeroval);