Hey, I am trying to understand how ArduPilot control works(both outer and inner loop). With a MAVLINK message of type SET_POSITION_TARGET_LOCAL_NED
, one can send the velocity commands for x, y and z. When we send these commands where are these desired values set? looking into the AC_PosControl.cpp
I found that there are methods to set position, velocity, and acceleration together(set_pos_vel_accel
and set_pos_vel_accel_xy
), but no methods to set alone the velocity and acceleration. If these methods are used to set the desired position, velocity, and acceleration, what does it initialize the position when only velocity and acceleration setpoints are given? Looking more, I found that there is a method called update_pos_vel_accel_xy
where to kinematic equations of motion are followed to update the target position with the delta position. Is this used when only velocity and acceleration setpoints are available?