I didn't have the problem until later firmware, though I don't necessarily think it was the firmware but I don't know. You could calibrate, but it was almost like the gimbal level was tied to the heading because if you turn the drone, the level would get thrown off more as you turned, and if you turned back to the original heading, it would almost straighten out. This was true also if you manually adjusted the roll while flying.
I also had an issue where on a mission it would fly the line straight, but with the the drone angled off to the left.
I contacted Autel, they said the common gimbal issue was fixed under previous firmware, and so it must be hardware and send it in. After they got it, they said they are going to replace the main board under warranty.
So if your problems are similar, I would recommend contacting Autel.