[GUIDE] [Mi 4] Fix sensors not working!

Search This thread

userprince

Senior Member
Mar 12, 2012
734
181
So i guess you are here because your sensors are not working after flashing certain Rom or Kernel Right? :(

But Don't worry I'm here to help you :D

NOTE: If you are on new partition table (i.e if you flashed miui mm) use this partion name "mmcblk0p21"

Things you need

Open terminal emulater app and type
su
dd if=/dev/block/mmcblk0p22 of=/sdcard/persist.img

Then you will get the persist.img file on your storage. copy and take it on a safe place... Like on OTG Drive or On PC...

Now copy the downloaded "persistnew.img" file to Internal storage and on terminal emulater app type

dd if=/sdcard/persistnew.img of=/dev/block/mmcblk0p22

Now Reboot... Now check your sensors with "Sensor Box" app on play store :fingers-crossed: Hurray!! Your sensors will be working again :highfive:

Enjoy! :eek:

Thanks to @satvikvg (for new partition name)
 
Last edited:

shabtab

Senior Member
Jun 11, 2013
605
194
26
Kolkata
Is this for CM or MIUI? I know there are lots of sensors not working CM, will this enable all sensors on CM, or this is just for those who revert back to MIUI after using some Custom Roms and Kernels and found some sensors not working?
 

Lennoard

Recognized Developer
  • May 5, 2015
    585
    734
    22
    Teresina
    hebfoptimizer.androidvip.com.br
    So i guess you are here because your sensors are not working after flashing certain Rom or Kernel Right? :(

    Open terminal emulater app and type
    su
    dd if=/dev/block/mmcblk0p22 of=/sdcard/persist.img

    Then you will get the persist.img file on your storage. copy and take it on a safe place... Like on OTG Drive or On PC...

    Now copy the downloaded "persistnew.img" file to Internal storage and on terminal emulater app type

    dd if=/sdcard/persistnew.img of=/dev/block/mmcblk0p22

    Now Reboot... Now check your sensors with "Sensor Box" app on play store :fingers-crossed: Hurray!! Your sensors will be working again :highfive:

    Enjoy! :eek:

    Any chance it work on Xiaomi Redmi 2?
    We' got the same problem on Custom ROMs

    If not, can you help us? :3
     

    Top Liked Posts

    • There are no posts matching your filters.
    • 8
      So i guess you are here because your sensors are not working after flashing certain Rom or Kernel Right? :(

      But Don't worry I'm here to help you :D

      NOTE: If you are on new partition table (i.e if you flashed miui mm) use this partion name "mmcblk0p21"

      Things you need

      Open terminal emulater app and type
      su
      dd if=/dev/block/mmcblk0p22 of=/sdcard/persist.img

      Then you will get the persist.img file on your storage. copy and take it on a safe place... Like on OTG Drive or On PC...

      Now copy the downloaded "persistnew.img" file to Internal storage and on terminal emulater app type

      dd if=/sdcard/persistnew.img of=/dev/block/mmcblk0p22

      Now Reboot... Now check your sensors with "Sensor Box" app on play store :fingers-crossed: Hurray!! Your sensors will be working again :highfive:

      Enjoy! :eek:

      Thanks to @satvikvg (for new partition name)
      3
      can someone upload a working persist file for Mi3?

      edit: got the persist file from my friend, it's working with the latest MM China Dev rom.

      download the file here, (FOR MI3 only)
      https://mega.nz/#!G89BwLgK!H78yTQuFdD2wnJx881itmsZKX1ipgI7FumBsqay4uW0
      2
      @Prince Chandela I've tried that too, after replaced MM file sound sensor, cellular network and WiFi hardware stopped working.

      I flashed later version of MIUI 8 alpha ROM(MM) then tried DU now everything working well.

      Thanks for your support in both thread :)

      Good to hear everything working now :good:
      Enjoy!!! :eek:
      2
      PERSIST in Mi 4 after repartition

      Kindly Note this:
      After repatriation the PERSIST partition changes to mmcblk0p21 in Miui 7 6.1.14 Beta Marshmelow

      EDIT: mmcblk0p22 no longer works if you guys have Re partitioned for Marshmelow
      1
      Even the IR Blaster? :D my ir blaster works only with xcelerate kernel and omni rom. ��

      Yep it will fix Ir blaster too :eek:
      Make sure your kernel is set to Permissive
    Our Apps
    Get our official app!
    The best way to access XDA on your phone
    Nav Gestures
    Add swipe gestures to any Android
    One Handed Mode
    Eases uses one hand with your phone