Hotfix: Copying from right actuator topic on IO if FMU and IO PWM outs are enabled

This commit is contained in:
Lorenz Meier 2013-01-09 13:11:06 +01:00
parent b5424a4d02
commit d957f8e004
1 changed files with 2 additions and 1 deletions

View File

@ -388,7 +388,8 @@ PX4IO::task_main()
if (fds[1].revents & POLLIN) {
/* get controls */
orb_copy(ORB_ID_VEHICLE_ATTITUDE_CONTROLS, _t_actuators, &_controls);
orb_copy(_primary_pwm_device ? ORB_ID_VEHICLE_ATTITUDE_CONTROLS :
ORB_ID(actuator_controls_1), _t_actuators, &_controls);
/* scale controls to PWM (temporary measure) */
for (unsigned i = 0; i < _max_actuators; i++)