mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-16 06:23:33 +08:00
MC controller: Update use to new uORB API
This commit is contained in:
@@ -1447,7 +1447,7 @@ MulticopterPositionControl::task_main()
|
||||
_control_mode.flag_control_velocity_enabled))) {
|
||||
if (_att_sp_pub != nullptr && _vehicle_status.is_rotary_wing) {
|
||||
orb_publish(ORB_ID(vehicle_attitude_setpoint), _att_sp_pub, &_att_sp);
|
||||
} else if (_att_sp_pub <= 0 && _vehicle_status.is_rotary_wing){
|
||||
} else if (_att_sp_pub == nullptr && _vehicle_status.is_rotary_wing){
|
||||
_att_sp_pub = orb_advertise(ORB_ID(vehicle_attitude_setpoint), &_att_sp);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user