I have seen many variations of this question but never found a definitive answer or a working solution.
I´m trying to implement a AI controller for a quad copter running APM 3.1 by continuously sending velocity targets through mavlink. I have a SITL simulation running and can control the copter by putting it in guided mode and sending SET_POSITION_TARGET_LOCAL_NED. My problem is that I cant find a way to control the heading of the copter. The closest I have gotten was sending MAV_CMD_CONDITION_YAW but that does not seam accept continuous updates. It turns once and then maintains that heading forever.
Is there any way to control the target heading and/or target yaw rate in the same way as the target velocity? Or, is there a way to make the copter face its target velocity?
Any help would be appreciated, Thanks.
Replies