yashsingh1/xdaforums huggingface dataset:
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] eliezerjk90:
Well, that's quite a long post. I'll try to answer it as best as I can.

1. Unfortunately, as far as I know there's no other option.

2. Yes. You are in the right direction. Just be sure that you download the fastboot file (the filesize is bigger than recovery flashable ROM). The file format should be .tgz and you'll have to unpack it twice (first will give you a .tar format, twice will give you the actual folder)

3. Theoretically, yes you can. You can use adb to flash the command one by one. If you open the folder you'll see several files with .bat extension. If you open it as a text, you'll see the command you'll need to insert in adb. However, I'm not familiar with Ubuntu so I can't help you with detailed steps.

4.a. Yes. And beside the mentioned partitions you might want to make sure you back up internal memory (copy it to your PC) before the process because it will be deleted and twrp doesn't back it up natively (unless you use tipatch which is another story). You don't need flash LOS first before restore the image, because the image already contain LOS in system partition, and the partition will be wipe before flashed the recovery image. The encryption will be kept after restoring unless you format /data partition. So if you want to restore, just wipe the partition and don't format it.

4.b I'm not sure as I never use adb to backup.

Hopefully it's helpful enough and I don't miss anything. Good luck.

Edit:

Just remember some important things,

1. If you use adb to install MIUI, don't (I repeat DON'T) use commands from flash_all_lock_crc.bat as this will wipe your imei (=disaster). Secondly, skip the command to relock bootloader if it's exist.

2. It is recommended to disable all security measure (pin, fingerprint, etc) before back up with twrp as it might cause trouble when restored (the pin would be wrong and you'll need to delete specific file through twrp to proceed)
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] YKCBastard:
location error

lately after clean flash this rom i notice something unsual. I enable the gps on high accuracy mode. i ise waze as maps and the location is working and perfecty accurate. on the other hand, i use both whatsapp and line to share my location but the gps is not working. there is no gps icon showing that its working/running in status bar. i've allow location permisson both on app settings and privacy guard but the gps still not working. i notice particular differences on privacy guard as i attach few screenshot. the gps permission is missing on both whasapp and line.

anyone can help me solve this problem?

thankyou
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] xdabuntu:
Encryption bug workaround - Flashing MIUI, backup first - Part II

[MENTION=477677]eliezer[/MENTION]jk Terima kasih banyak! Thanks a lot for all the helpful answers and tips!

3. I will probably try first to flash MIUI via Windows in a Virtualbox (that is "where" I unlocked the phone in the first place), hopefully it will work. Unless there is another Linux user who can help with step-by-step instructions as I don't want to brick the phone.

4a Backup & Restore. May I ask whether I understood correctly:

- TWRP backup system/data/cache (disable all security measure (pin, fingerprint, etc) in LOS)

- Backup internal memory to computer (e.g. copy/paste when Android storage is mounted to computer - correct?)

- Flashing MIUI with Miflash fastboot method

- TWRP restore system/data/cache (or is this not needed as it has not been touched by the MIUI flashing?)

- Copy/paste from computer internal memory backup to phone

(You don't need flash LOS first before restore the image, because the image already contain LOS in system partition, and the partition will be wipe before flashed the recovery image. The encryption will be kept after restoring unless you format /data partition. So if you want to restore, just wipe the partition and don't format it.)

What do you mean by "So if you want to restore, just wipe the partition and don't format it."?

Thanks again very much!
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] eliezerjk90:
4.a upon second thought I might be wrong yesterday. You might need to flash LOS before restore backup image. What I wrote is when you already have your phone encrypted. Last time I restored backup was after my device encrypted, so that is what I remember. My bad ?. Since in this case you want to encrypt it so my recommendation would change slightly. The change would be look like this:

- twrp backup system, data, and VENDOR partition. This is important since vendor partition is altered by LOS. Cache backup is optional since it is often wiped after update anyway. Anyway, the partition doesn't take many space so I just include it anyway.

- backup internal storage

- wipe system, data, cache, and vendor partition, then reboot to fastboot mode

- flash miui with miflash and reflash twrp, as the installed twrp would be replaced by stock recovery. You can of course flash twrp later but I do it directly since the phone already connected to computer anyway.

- reboot to miui, it's gonna take a while so be patient. The system might tell you that you need to erase data here. Just say yes because you already backed it up. After it enters miui just set pin you want to use in security setting. You don't need to setup all things (accounts, setting, etc). Just make sure pin is set.

- reboot to twrp, wipe system, data, cache, and vendor partition, install LOS only (this installation would be erased later anyway so no point to flash gapps etc)

- reboot to LOS. You might be asked to insert the pin before startup (I'm not 100% sure). Your phone should be encrypted at this point so you might want to go to settings - security & privacy - trust to see whether it is the case.

If it is encrypted then you just need to reboot to twrp, wipe system, data, cache, and vendor partition, and restore everything from the backup image. The rest is the same as before.

Sorry for my mistake yesterday.

About wipe and format

In twrp, there's options to wipe or to format partition. Wipe means you only erase all the content of the partition without change the format of that partition. Formatting would mean you delete everything and (usually) change the format of the partition and this will erase your encryption.

As an analogy I would use a house. Wipe is when you throw everything out (when you move out from the house for example) from a house without breaking the house down. Formatting is when you break the whole house down and rebuild it. Surely that means everything inside (including key of the house which is like the encryption in this analogy) would need to be also gone.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Wind_Waker:
The other thing that doesn't working on this ROM "EAP-SIM authentication protocol" so I Reside in France I'm using Free Mobile operator, when I'm on MIUI this method of authentication work flawlessly.

The method is u can connect to any Free Mobile Access Point WIFI without entering user ID and Password, it automatically authenticate with SIM of the same operator.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] laska.levin:
I mentioned this EAP-SIM problem many many months ago, but no one seems to care about it. By the way, EAP-SIM works fine on LOS 15.1 for Redmi Note 5 Pro (whyred), so I don't see why it shouldn't work for Redmi Note 4 (mido). Perhaps you should try some other ROM.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Wind_Waker:
Anyway this' a very stable ROM for RN4X there's only like this minor bugs that doesn't impact the user experience very seriously.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] xdabuntu:
Encryption bug workaround - Flashing MIUI, backup & restore LOS - Part III

[MENTION=6458530]eliezerjk90[/MENTION] Thanks again very much for the step-by-step instruction and additional background information. No worries about the slight change. It is quite daunting for a newbie like me but I hope I will be able to do it. Although I will ask again whether somebody has an easier workaround. A few questions:

- When "After it enters miui just set pin you want to use in security setting.": There is no need to encrypt the phone in MIUI or even better not to do it? Or is it encrypted by default?

- What is on the vendor partition?

- Why does the vendor partition needs to be wiped? (I did not do this when I first installed LOS.) You wrote it is altered by LOS, in which way?

- On which partition is the MIUI?

- Is there a way to backup TWRP backups to the computer and restore it again? (Just in case I do something wrong or something goes wrong.)

- System partition: Does this contain LOS with all apps? If I restore this, I will get back all the apps and settings?

Thanks again for your patience and help!
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] eliezerjk90:
1. As far as I remember, you don't need to encrypt it in miui. It would be force encrypted when you change to LOS. Surely you can try to encrypt it but if I remember correctly it is not necessary.

2. Vendor partition is a partition used by OEM (Samsung, Xiaomi, other manufacturers) to contain specific files that are needed for their specific UI. Third party UI that heavily modified compared to AOSP (touchwiz, MIUI, EMUI, etc) would have a lot of these files . LOS on the other hand, does not need these files so they use the partition as storage for treble instead (just do some read about project treble. It would be great to better understand this). Please note that redmi note 4 doesn't support treble when it released so this is a workaround to be able to use treble in redmi note 4.

3. Each time you flash LOS zip, vendor partition would be patched, so it might be not necessary to wipe it first. However, I always prefer wipe it before flashing new ROM or restore twrp backup just to ensure that there's no leftover in the partition. It's optional but it might be useful and it is not too complicated to be done.

4. MIUI (and LOS and other ROMs) is stored in system partition.

5. You can just copy and paste the whole backup twrp folder to your computer. It's would be in TWRP/backup folder if you use file manager. It could be on internal/external storage depending on where you set the backup location during backup.

6. System partition contain LOS and system apps. Some other apps would be stored in data partition. Principally, if you restore all the partitions you'll have exact same settings and apps.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Backstab319:
Anyone else's audio fx making everything including google music and youtube bad?
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Wind_Waker:
Very useful information thanks
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] xdabuntu:
[MENTION=6458530]eliezerjk90[/MENTION] Thanks again very much for answering all the answers! Very helpful! If nobody will mention any other workaround, I will endeavor to flash MUIU in March. In the next weeks I won't have the time to do this unfortunately.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] xdabuntu:
Encrypting LOS 15.1 without flashing MIUI?

As the workaround for encryption with flashing of MIUI is quite daunting, I wonder whether somebody knows an alternative.

:confused: Is there a way to encrypt an newly installed LOS 15.1 on a Redmi Note 4 Pro without flashing MIUI?

Any lead is welcome! :good:
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Nicklas Van Dam:
I think you'll need to repartition your /data partition, but proceed it with caution.

Here, try to follow this instruction https://xdaforums.com/showpost.php?p=77330471&postcount=3850

That's for tissot, but that's working correctly for mido, i already try it several times. After try that, charge your phone to 100% and try encryption again.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] DrDOOM4U:
1. Take backup of data partition, and entire internal storage. Use ADB pull to copy it to pc.

2. Install twrp 3.1.0.0 (DL from twrp website).

3. Format data with it.

4. Install latest twrp, go to settings check "use rm -fr instead of formatting" option.

5. Copy entire contents copied to pc back to your storage. (U can use ADB push).

6. Restore data partition taken earlier.

7. Reboot to system. Encrypt the from settings menu.

Edit: on first boot fingerprints disappear. Reboot is required for them to appear in security & privacy menu.

Edit 2: automatic updates and all other functions remains same as before. Only extra is you need to enter password everytime you boot to twrp.

Edit 3: Problem is that latest twrp formats entire partition but encryption needs 16 kB free block at the end of partition (for metadata I guess). So use older version to format data.

Edit 4: installation of latest twrp (4th step) is important because older versions doesn't support encryption.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] amnher:
Truly this rom is still the most stable. Hope someone can update the kernel or upstream it
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Nicklas Van Dam:
what's linux kernel version of stock lineage 15.1 anyway? but you still can install other kernel like franco (before r18 i think) or kud right?
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] amnher:
I think it is 3.18.71 yeah I can use custom kernel but I wanna keep it stock
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Nicklas Van Dam:
Maybe i can help with upstream that kernel, but since i'm not using this ROM, then i can't test it with booting or not after compile. And you'll need to flash that kernel too in every time you're updating your ROM.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] amnher:
only the maintainer can push it to gerrit?
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Nicklas Van Dam:
Yes, of course. Only maintainer have permission to push to ssh lineage gerrit
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] amnher:
i see too bad [MENTION=6664065]ABHS[/MENTION]hek987 is not anymore maintaining our device
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Nicklas Van Dam:
He's maintaining poco now...
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Dyt199412syam:
So, i bought a new mido few days ago. It is very good device. I just have one issue, the dt2w is not working on mine even in stock miui. So i am waiting for three days for unlocking my device officially. Then i installed the latest Lineageos 15.1 on latest global stable firmware. Its really smooth experience at all. No bug. But, i still faced the dt2w issue (stock kernel). I tried to install custom kernel (franco kernel), but still the same. I have ft5435_ts touchscreen. Anyone can tell me an explaination about "whats going on with device"? Thanks for advance.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] xdabuntu:
Encryption workaround option 2 + 3

[MENTION=5608002]Nicklas Van Dam[/MENTION] Thanks a lot for this tip. What are the risks? What can go wrong? If something goes wrong, can you fix the problem?

---------- Post added at 02:18 PM ---------- Previous post was at 02:08 PM ----------

[/COLOR]

[MENTION=9041554]DrDOOM4U[/MENTION] Thank you, too, very much! It looks like the "easiest" option so far (at least to me). Can something go wrong?

Step 1 +5 adb pull & push: Is this done in the fastboot mode of the phone? What would be the full command, e.g. on your phone/computer?

Step 6 Restore data partition is done in TWRP, right?

Could there be even an easier option or a fix to LOS 15.1 on Redmi Note 4?
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Nicklas Van Dam:
I don't know for the risk, but try to follow all procedure correctly and you'll be fine, your device only need 4kb extra partition in your /data to encrypt back your device, so after you find correctly /data partition size, just follow it and reduce it with 4, and complete the procedure.

After that reboot it.

Do it with your own risk...
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] DrDOOM4U:
You mi8 loose some data while transferring to pc via MTP. So it's better to use ADB pull. ADB commands can be executed while in twrp (on main menu screen). For pulling "adb pull -p /sdcard c:\backup". Your entire sd card will be copied to c: backup folder of your pc.

For pushing "adb push -p c:\backup /sdcard",

But for me above command put files in sdcard\backup\sdcard folder. So used "adb push -p c:\backup\sdcard /" only. (figured out by trial and error). this can be done in any file manager later also. 6th step is done in twrp only. But make sure your twrp folder is in /sdcard. Otherwise twrp won't be able to find it.

If anybody can explain better, please step in.

Edit: found this video on yt. For prerequisites and understanding check it. [youtube]vu42yc6Ni54[/youtube]
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] xdabuntu:
Encryption workaround option 2 + 3 - further info

[MENTION=5608002]Nicklas Van Dam[/MENTION] Thank you!

---------- Post added at 02:28 AM ---------- Previous post was at 02:19 AM ----------

[MENTION=9041554]DrDOOM4U[/MENTION] Thank you for the further info. The Youtube video "File Transfer Via ADB Push Command in Custom Recovery" is in Hindi and unfortunately Youtube does not give annotations and translations. But I think I can follow the screenshot's content and commands :o . It will be a bit different as I am a Linux user ;) .
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] DrDOOM4U:
Oh sorry for that. It was late night when I watched it and I mute the sound so didn't notice it.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] xdabuntu:
:D No worries! Hopefully you got enough sleep afterwards.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Dyt199412syam:
Faced weird issue:

When i charge my phone in off condition, i dont see a LED charging indicator. And the battery charging graphical of LOS 15.1 doesn't appear. Otherwise, my phone appears the miui's battery charging graphical. Btw, i tried to install LOS 15.1 on top of firmware v10.2.3. So i supposed it related with the firmware. Then i tried to re-cleaninstall it with the firmware version v9.6.3, but both of it give me the same result. Any suggestions please?

Redmi note 4 mido 3/32 running stock LineageOS 15.1.

---------- Post added at 04:58 AM ---------- Previous post was at 04:57 AM ----------

Faced weird issue:

When i charge my phone in off condition, i dont see a LED charging indicator. And the battery charging graphical of LOS 15.1 doesn't appear. Otherwise, my phone appears the miui's battery charging graphical. Btw, i tried to install LOS 15.1 on top of firmware v10.2.3. So i supposed it related with the firmware. Then i tried to re-cleaninstall it with the firmware version v9.6.3, but both of it give me the same result. Any suggestions please?

Redmi note 4 mido 3/32 running stock LineageOS 15.1.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Moksu:
Anyone having issues with the phone not asking for SIM code after a reboot? Is there a way to force it somehow.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Apoorv_Pandey_:
I'm also facing this Issue ? but I don't know the Fix for this. Waiting...

---------- Post added at 09:09 AM ---------- Previous post was at 09:08 AM ----------

I'm also facing this, BTW can you provide me the link for the firmware? Would be great
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Dyt199412syam:
[MENTION=7203984]Apoorv_Pandey_[/MENTION]

Here it is https://github.com/XiaomiFirmwareUpdater/firmware_xiaomi_mido/releases. Choose one what u like! Weekly or stable!
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Apoorv_Pandey_:
Thank you so much! BTW do you face any issues in WhatsApp camera in night?. While capturing photo from the rear camera in dark the picture quality Really bad. I got green tint and grey picture. ?
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] eliezerjk90:
Whatsapp camera is not optimized for specific device since it's intended to be installed in various devices. That's why it's understandable that the camera is not that good. Normally I just use gcam and then share through WhatsApp.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Zile995:
Live Display and System UI (QS tile edit button) FC here on latest nightly. Does anyone have a similar problem?

Clean flashed without Magisk.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Walden0:
Try los extended by alexey or mdroid by hikari no tenshi.

xD :p
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Thoraku:
Thanks :)
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] amnher:
Thats weird though I have not updated but theres almost no noticeable changelog included on MIDO here https://www.cmxlog.com/15.1/mido/
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Dyt199412syam:
The team are working and focus on LOS 16.0 development. So, the LOS 15.1's development will be slower until LOS 16.0 release. Keep calm, bcoz our devs (thescarastic and aryan kedare) are hard-working on LOS 16.0 for mido. https://review.lineageos.org/q/mido. So, just wait for LOS 16.0 releases and mido will come with it!!!

Cheers!!
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] amnher:
Well its about [MENTION=5839502]Zile995[/MENTION] post about FC on LOS15.1 not LOS 16.0

[MENTION=5839502]Zile995[/MENTION]

I tried using 2192019 build and no FC whatever. I used mindthegapps for oreo
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] eliezerjk90:
So would mido receive 16.0 officially? I read that no one wants to be maintainer now. And without that, it won't go official. Just curious how this will turn out.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Dyt199412syam:
Hmm, on lineageos gerrit, we can see and tracking aryan kedare is more active and working to push mido on lineageos 16's branch. So we can hope mido will get the lineageos 16 official. I hope abhisek still have a time tobe an official maintainer for this device in the future so he can working with aryan kedare to make this device better. One great-dev is good, two great-devs are better.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] karamancho:
Does anybody use BSGs 6.1 google camera mod on this rom? If yes what version?

I cant use anything past V2a+. Thats the last version that is working for me. On any version past that the viewfinder is black and the shutter button is disabled.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] J5user19:
Can I flash official Lineageos 15.1 with official twrp 3.2.3-1?
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] OmnioPT:
Yes you Can!

---------- Post added at 01:00 PM ---------- Previous post was at 12:54 PM ----------

Hello friends!

I've noticed a bit of battery drain in the latest ROM builds.

Do you also noticed this or it was just me?

For example today I went from 100% to 80% in 25minutes... only using Telegram over wifi.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Backstab319:
Hey guys i am unable to switch off the shutter sound from the google camera. Could anybody please help me? Btw loving the build!! Keep up the good work guys :)
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] eliezerjk90:
Wrong thread... Gcam is third party app and has nothing to do with LOS...
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Backstab319:
Was worth a shot.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] eliezerjk90:
https://xdaforums.com/redmi-note-4/themes/google-camerawith-hdr-mido-t3656196/page289

Try to look and ask there. You might get your answer there.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] Walden0:
If it is not in camera settings, then you are using an older version of gcam 5.2. 025.xxx

update it.
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] varun_77:
Is fp and wakeup still slow on this ROM?
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] jazzh:
Excellent rom! Just a few questions:

Can I make pull down notifications look dark?

Can I shorten long click back button duration for killing an app?
[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] DrDOOM4U:
Only for 2 days. Then I updated firmware to latest now battery backup is same as before. So try updating firmware and also give 1 or 2 days time.