Uncommanded Yaw during Acceleration and Deceleration

Hello everyone,

I have been flying with a 20 kg vehicle with the Octorotor Coaxial airframe (Airframes Reference | PX4 Guide (main)) and having an uncommanded yaw during some acceleration and deceleration. The pitch/roll arm length is 45cm. The vehicle keeps altitude and position track but has a yaw of up to 100 degrees. This behavior seems to occur as soon as the vehicle enters the NAV_ACC_RAD. MPC_JERK_AUTO has been minimized. Minimizing the MPC_ACC_HOR doesn’t seem to have a consistent effect on the behavior. Activating MC_AIRMODE seems to introduce oscillations.

I would prefer the vehicle to have smoother vehicle motions and limited agility such as for video shooting. Has anyone seen this behavior and have recommendations for getting rid of this yaw behaviour?

Attached are the flight logs:

Log with MPC_ACC_HOR = 2: https://review.px4.io/plot_app?log=db2dbc0e-5e6a-43b1-be61-92b2a6f3e128

Log with MPC_ACC_HOR =5: https://review.px4.io/plot_app?log=de15be31-e6b9-438c-946d-0be563becde3

Log with MC_AIRMODE = roll/pitch/yaw: https://review.px4.io/plot_app?log=bd289598-a4b7-4877-8bbf-187e8b8fe6be

Thank you for your feedback.

That doesn’t sound right. Could it be that you have the PID gains too high/aggressive? What sort of oscillations do you see, in which axes? I’m not sure from the log what you mean.

The attitude gains were lowered from default for this vehicle (MC_PITCH/ROLL_P = 1.75). The rates were tuned for increased yaw control.

Regarding the oscillations, below is a screenshot from the log with MC_AIRMODE enabled for roll/pitch/yaw.

RTH was initiated because the motors were throttling to 0% which is reflected in the logs of the thrust (vehicle_local_setpoint/thrust.02). The attitude of the aircraft was oscillating and the motor outputs were saturating. From the setpoints, it looks to be commanded in the pitch/roll while uncommanded in the yaw. Pitch/roll/yaw was derived from quaternions vehicle_attitude_q.00/01/02/03 and setpoints are from vehicle_attitude_setpoint. There is also an instance where Motor Output 5 (motor 6) is disarmed (900 us) during this behaviour.

This sounds problematic. Are you sure that’s not causing your problems? To improve yaw performance it’s usually a good idea to slighly tilt the motors, so that their tilt helps with yaw. For more info see: Info about Angled Motor Mounts for Multicopters - Oscar Liang

Initially vehicle was tested with default gains and started tuning from there following PX4 PID tuning guide but it only made the yaw behavior more aggressive and more frequent. Then the idea was having lower gains on attitude loop to limit/smooth immediate changes especially on pitch/roll which were deprioritizing the yaw control. Yaw controls were tuned to be better to respond commands and not create bigger convergence. Its observed that it improved the yaw rate response and limited some uncommanded yaw.

Another consideration was that default gains might be too high which were set for smaller and lighter vehicle. Basically the performance aimed is slow transition up to higher speeds(15-17 m/s) in a straight line. I appreciate any recommendations to configure or tune my vehicle within PX4 to have slower and smoother acceleration/deceleration before completely moving to tilted configuration.

I have some tests competed with tilted but initial tests introduced increased accelerometer clippings and vibration warnings which also caused excessive oscillations on attitude during tuning. Another challenge is coaxial configuration requires tilting the motors on the same arm to different directions so tilting arm wouldn’t be sufficient.