TWRP 3.0.2 recovery port for X5+ and LEM5

First FULLY WORKING TWRP 3.0.2 recovery port for w616 based smartwatches (Finow X5+, Lemfo LEM5) with multi-language support.

Requirements
X5+ must have firmware v161125 (here).
LEM5 must have firmware v170111 (here).
SP Flash tool must be a newer version, I use the v5.1628

*** WARNING ***
DO NOT APPLY any OTA update after you have flashed this recovery! This could (soft)brick your watch.
OTA updates require stock recovery.

Notes
On both X5+ and LEM the stock ROM includes a service which overwrite recovery partition at every reboot if it’s different from the stock.
To overcome this issue I included also a patched version of the boot.img, from the v161125 ROM for the X5+ and from the v170111 ROM for LEM5, which is exactly as the stock version but the recovery overwrite service is disabled.
The included scatter file is modified to load both the recovery and the boot image files; no changes to partitions layout are present.
* Newer firmwares *
If you have a newer firmware version, please read here the how-to for updating your boot.img after you successfully flash the TWRP recovery.

Installation
To install, use the usual procedure for flashing the recovery with SP Flash Tool. Don’t do it if you are not 101% sure of what you are doing.
Usual disclaimers apply *** I am not responsible for anyone’s issues here. Use this at your own risk !! ***

  1. Load the supplied scatter file in SP Flash Tool
  2. Make sure that no other other files is selected, ONLY boot and recovery must be selected, and press “download”.
  3. Power off the watch and then connect it to your PC and it will flash in few seconds.

After reboot, to access recovery use the “adb reboot recovery” command.

That’s all.

Download
TWRP 3.0.2 for X5+
TWRP 3.0.2 for LEM5

Good morning. I have a Lem5

How do I know the firm I have on my device ?. W616? Or W618?

Where can I look?

regards

In the dial pad type #4321#
You’ll see the exact firmware version with w616 or w618 model number.

May 1, 2017 10:45:17 GMT 1 Ciro Danise said:
In the dial pad type *#4321#* You'll see the exact firmware version with w616 or w618 model n6umber.

Ok. W616 v.s. 170306.
Thank you.

I guess I can put the TWRP without problems.

regards

Well, you could put it, but you have a newer firmware version so you should follow the procedure I wrote to restore your current boot.img after the flash of the TWRP.
The problem is, it’s the full v170306 firmware available for flashing via SP Flash tools?

May 2, 2017 8:59:08 GMT 1 Ciro Danise said:
Well, you could put it, but you have a newer firmware version so you should follow the procedure I wrote to restore your current boot.img after the flash of the TWRP. The problem is, it's the full v170306 firmware available for flashing via SP Flash tools?

[br

No.

I installed the v. 17.01.11 and then upgraded to 170306.

Something I did wrong since after installing the TWRP I did not recognize the Bluetooth.

I reinstalled the w618 of the X5 + and then the W616 of the LEM5 without preloader.

Then I installed the TWRP without updating the firm so my new vs. 17.01.11, I installed the supersu and now I am root with no problems.

Now I recognize the Bluetooth.

Thanks for your job.

Greetings.

Hi,
First, thank you Ciro for making TWRP for LEM5!

I have couple of questions for you guys;

So, this TWRP is for w616 only? Is there any chance on TWRP for w618?

epicuros
You said you “installed the w618 of the X5 + and then the W616 of the LEM5 without preloader”
Doesn’t this mean that you installed preloader for w618 and therefore your watch is w618 and not w616?
Did I get that right?
If your watch is w618, is this TWRP working for you?

I appreciate any hint on installing TWRP on w618 LEM5.

May 3, 2017 23:32:01 GMT 1 tadd said:
Hi,
First, thank you Ciro for making TWRP for LEM5!

I have couple of questions for you guys;

So, this TWRP is for w616 only? Is there any chance on TWRP for w618?

epicuros
You said you “installed the w618 of the X5 + and then the W616 of the LEM5 without preloader”
Doesn’t this mean that you installed preloader for w618 and therefore your watch is w618 and not w616?
Did I get that right?
If your watch is w618, is this TWRP working for you?

I appreciate any hint on installing TWRP on w618 LEM5.


Yes. So is.

I’m doing perfect.

a greeting

May 3, 2017 23:35:30 GMT 1 epicuros said:

May 3, 2017 23:32:01 GMT 1 tadd said:
Hi,
First, thank you Ciro for making TWRP for LEM5!

I have couple of questions for you guys;

So, this TWRP is for w616 only? Is there any chance on TWRP for w618?

epicuros
You said you “installed the w618 of the X5 + and then the W616 of the LEM5 without preloader”
Doesn’t this mean that you installed preloader for w618 and therefore your watch is w618 and not w616?
Did I get that right?
If your watch is w618, is this TWRP working for you?

I appreciate any hint on installing TWRP on w618 LEM5.


Yes. So is.

I’m doing perfect.

a greeting


Thank you epicuros, for confirming it’s working on w618.
Did you ever get updated back to 170307 firmware?
Did you notice any difference between version 170111 and 170307?

Guys, don’t make confusion!
There is no need to change the firmware to install the TWRP.
The only affected component is the boot.img, so if you have a different firmware version than v161125 for X5+ or the v170111 for LEM5 just flash the TWRP and boot.img as reported in the first post, then follow the procedure detailed here /thread/894/twrp-recovery-latest-boot-img for restoring your correct boot.img.
I repeat, there is NO NEED to flash the full firmware; issue reported on Bluetooth is most probably due to old boot.img (kernel) so, just restore your current boot.img and everything will work as before.
About flashing my TWRP on w618 hardware I can’t say anything because I can’t test it, so do it at your own risk!

May 4, 2017 8:54:30 GMT 1 Ciro Danise said:
Guys, don't make confusion! There is no need to change the firmware to install the TWRP. The only affected component is the boot.img, so if you have a different firmware version than v161125 for X5+ or the v170111 for LEM5 just flash the TWRP and boot.img as reported in the first post, then follow the procedure detailed here /thread/894/twrp-recovery-latest-boot-img for restoring your correct boot.img. I repeat, there is NO NEED to flash the full firmware; issue reported on Bluetooth is most probably due to old boot.img (kernel) so, just restore your current boot.img and everything will work as before. About flashing my TWRP on w618 hardware I can't say anything because I can't test it, so do it at your own risk!

Hi Ciro, thank you for clarifying. Yeah I figured that the only thing a new firmware needs is a compatible boot.img after flashing your twrp&boot combo. If I understand correctly, epicuros flashed an older rom not to flash your twrp but to fix a bad flash (w616 preloader on w618 phone). Since the only LEM5 firmware to download is 170111, that's what he's got. So, I was wondering if your twrp is working on epicuros' w618 watch, and whether he found a newer LEM5 firmware. Anyhow, I will back up my rom first before trying your twrp. Thanks guys!

Hello guys,

I flashed Ciro’s TWRP&patched boot on LEM5 w618 fw ver. 20170307.
Then I installed UPDATE-SuperSU-v2.46.zip in TWRP to get root.
I later realized that flashing SuperSU also replaces /system/bin/install-recovery.sh with a script that starts daemonsu, so no need to rename the script yourself. Permission to rename that script from TWRP was denied anyway, with an error: full selinux is supported or something like that.
After that I flashed back boot.img from fw 170307. SuperSU and su binary were updated as well.

Root is working except one annoying glitch. If SuperSU is set to prompt for root access, every time something asks for root SuperSU crashes and prompt never appears. If SuperSU is set to either grant or deny root by default, everything is ok. SuperSU UI also crashes regularly, but gives me just enough time to change settings.

Is anyone experiencing the same issue? If not I wonder where I went wrong?

May 7, 2017 23:03:57 GMT 1 tadd said:
Hello guys,

I flashed Ciro’s TWRP&patched boot on LEM5 w618 fw ver. 20170307.
Then I installed UPDATE-SuperSU-v2.46.zip in TWRP to get root.
I later realized that flashing SuperSU also replaces /system/bin/install-recovery.sh with a script that starts daemonsu, so no need to rename the script yourself. Permission to rename that script from TWRP was denied anyway, with an error: full selinux is supported or something like that.
After that I flashed back boot.img from fw 170307. SuperSU and su binary were updated as well.

Root is working except one annoying glitch. If SuperSU is set to prompt for root access, every time something asks for root SuperSU crashes and prompt never appears. If SuperSU is set to either grant or deny root by default, everything is ok. SuperSU UI also crashes regularly, but gives me just enough time to change settings.

Is anyone experiencing the same issue? If not I wonder where I went wrong?


The same happens to me. I must select grant permissions by default.

regards

May 8, 2017 23:38:39 GMT 1 epicuros said:

May 7, 2017 23:03:57 GMT 1 tadd said:
Hello guys,

I flashed Ciro’s TWRP&patched boot on LEM5 w618 fw ver. 20170307.
Then I installed UPDATE-SuperSU-v2.46.zip in TWRP to get root.
I later realized that flashing SuperSU also replaces /system/bin/install-recovery.sh with a script that starts daemonsu, so no need to rename the script yourself. Permission to rename that script from TWRP was denied anyway, with an error: full selinux is supported or something like that.
After that I flashed back boot.img from fw 170307. SuperSU and su binary were updated as well.

Root is working except one annoying glitch. If SuperSU is set to prompt for root access, every time something asks for root SuperSU crashes and prompt never appears. If SuperSU is set to either grant or deny root by default, everything is ok. SuperSU UI also crashes regularly, but gives me just enough time to change settings.

Is anyone experiencing the same issue? If not I wonder where I went wrong?


The same happens to me. I must select grant permissions by default.

regards


Thanks, epicuros.

Now, I wonder if this is specific to w618, or if this happens to w616 watches, too.

Though the only thing common between my watch and epicuros’s now is the preloader, and I doubt that it would affect how SuperSU works…or, would it?
I hope to hear other people’s experiences, too.

What version of supersu have you installed? 2.46 ? It’s outdated and full of bugs, was released back in February 2015.

There have been problems with supersu and selinux handling in previous releases.

It’s a “trust system user” issue, and according to this changelog has been fixed long time ago:

forum.xda-developers.com/showpost.php?p=64916199&postcount=3

May 9, 2017 11:02:54 GMT 1 m47r1x said:
What version of supersu have you installed? 2.46 ? It's outdated and full of bugs, was released back in February 2015.

There have been problems with supersu and selinux handling in previous releases.

It’s a “trust system user” issue, and according to this changelog has been fixed long time ago:

forum.xda-developers.com/showpost.php?p=64916199&postcount=3


Thank you for the link, m47r1x, I did full unroot and flashed SR3-SuperSU-v2.79-SR3-20170114223742.zip (SR4 is for ODP1 on 5X and 6P only) and still have exactly the same issue.

I would like to know if other people are experiencing the same issue (especially with w616).

Hello,

I confirm same behavior on a W618 with latest SU V2.79. Installation through TWRP.

Hello,
possible to flash only twrp with flashify?
On D5+ ?
Best Regards

May 10, 2017 7:52:19 GMT 1 savi said:
Hello,

I confirm same behavior on a W618 with latest SU V2.79. Installation through TWRP.


The supplied scatter file in this thread is for MT6572 soc, but the W618 in the X5+ has an MT6580.

The files are mainly different in partitions and blocks.

I am wondering if that causes the problems with root and trying to find out.

Any info from you is highly appreciated.

I think not, because everything appears to work well except the SU UI. The only modification to the boot.img is the kernel rewrite protection to be disabled.
And to my understanding this scatter file is for X5+, meaning it has the MTK6580 Boot.img
If what you are saying is correct it means i now use a MTK6580 device with a MTK6572 boot.img?
I understand that the only ported thing is the TWRP recovery, and if that is the cause (not flashing correctly SU binaries) a re-installation of superSU using a different SU app (like SuperUser) should fix the problem?

A bit of off-topic : I got the wakelock detector you was mentioning in the other post and is terrible on the device, but you can get the PC version that works through ADB but you have to replace the files in the ADB folder with the ones provided in the MTKdroid folder (the timeout of the authorization is to small in the original ADB)