Mi 11 Pro UI crashing when opening camera


Apr 6, 2022
Happy new year.

I have a strange issue with my 11 pro.
When i open the camera app sometimes the gui crashes, the phone is completely unusable for 30-60seconds and then it is fine again. I get a black screen at the camera app then after some time a message that the system UI is not responding and then its fine.
This happens with whatever app is using the camera not just the camera app. So it could be when i scan a qr code or something.

It doesn't happen all the time and its random. it might be ok for 10-20-30 times i use the camera and then it happens.
It happened on latest stable miui 13 android 12, did a clean flash to weekly miui14 Android 13 and happens there as well.

Any ideas?
Thanks for your time