Skip to content

Commit

Permalink
mc_pos_control limit to 50 Hz
Browse files Browse the repository at this point in the history
  • Loading branch information
dagar committed Mar 15, 2019
1 parent f3533d3 commit 1083af2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/modules/mc_pos_control/mc_pos_control_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -582,11 +582,13 @@ MulticopterPositionControl::run()
_vehicle_land_detected_sub = orb_subscribe(ORB_ID(vehicle_land_detected));
_control_mode_sub = orb_subscribe(ORB_ID(vehicle_control_mode));
_params_sub = orb_subscribe(ORB_ID(parameter_update));
_local_pos_sub = orb_subscribe(ORB_ID(vehicle_local_position));
_att_sub = orb_subscribe(ORB_ID(vehicle_attitude));
_home_pos_sub = orb_subscribe(ORB_ID(home_position));
_traj_wp_avoidance_sub = orb_subscribe(ORB_ID(vehicle_trajectory_waypoint));

_local_pos_sub = orb_subscribe(ORB_ID(vehicle_local_position));
orb_set_interval(_local_pos_sub, 20); // 50 Hz updates

// get initial values for all parameters and subscribtions
parameters_update(true);
poll_subscriptions();
Expand Down

0 comments on commit 1083af2

Please sign in to comment.