I am dealing with issue that when I use takeoff button in QGroundControl, the drone flies up and then hold, but in a few seconds he starts rotating slowly on one side and then on the other side. It looks like he is patrolling. It is happening in Auto.Loiter or in hold mode. What I am doing wrong? Is it possible that I have something configured wrong? I tried pulling changes from px-autopilot git and reinstalling qgroundcontrol, but none if this was helpful.
Thank you for your answers.
Please upload a logfile to logs.px4.io where the behavior is visible, and link it here.
I have found out the reason. It is not some kind of bug, but it is caused by me. I added a pendulum under the drone and i used universal joint and I allowed movement only in axis x and y, so the z axis was causing a torque, that was rotating my drone.