mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-18 06:13:35 +08:00
uavcan escs: Modified esc_status reporting to have _rotor_count published.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
This commit is contained in:
committed by
Beat Küng
parent
187a025dfe
commit
1e04d718f6
@@ -919,6 +919,7 @@ int UavcanNode::run()
|
||||
|
||||
new_output = true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if (new_output) {
|
||||
@@ -993,6 +994,7 @@ int UavcanNode::run()
|
||||
_esc_controller.enable_idle_throttle_when_armed(_idle_throttle_when_armed > 0);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
orb_unsubscribe(params_sub);
|
||||
@@ -1123,6 +1125,11 @@ UavcanNode::ioctl(file *filp, int cmd, unsigned long arg)
|
||||
} else {
|
||||
|
||||
_mixers->groups_required(_groups_required);
|
||||
printf("Groups required %d \n", _groups_required);
|
||||
|
||||
_rotor_count = _mixers->get_multirotor_count();
|
||||
_esc_controller.set_rotor_count(_rotor_count);
|
||||
printf("Number of rotors %d \n", _rotor_count);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user