Hello friends,Here we are going to remove the auto rotating sensor not working.You have to aware about the fact that this faults was not for hardware defect or any water damage.While you upgrade software so many error appear on that model.Some time^( ,camera not working, ^( , ^( working etc.
Unlock Boot Loader from BST or Manually.
After unlock boot loader your handset comes in mi logo than immediately goes in EDL mode don`t worry.
Press volume down and power now your handset in fast boot mode.
Now type CMD
Fast boot OEM unlock-go.
Now boot loader unlock
To check boot loader status type fastboot oem device-info
now manually write persist file.
fast boot flash persist persist.img
Now Reboot And Check.