Gimbal IMU data error. Contact DJI Support for assistance(Code: 40021)

You don’t say which model of drone this relates to … which would help others to advise.

There was a similar gimbal related code report the other day … that was resolved by reconnecting a cable that had come lose Worth making sure they’re all well seated.