Teclast M40 How to unlock bootloader?

AnKHqz

New member
Nov 3, 2020
1
0
0
I have found a method of Teclast P20HD to unlock bootloader which can be found in "https://forum.xda-developers.com/android/help/teclast-p20hd-android-10-tablet-4g-t4141997" and "https://forum.hovatek.com/thread-32287.html", but I'm not sure if that method also works on Teclast M40. If that method works can I restore the bootloader to lock state instead of relock state so I can keep the warranty.
 

jwoegerbauer

Senior Member
Jul 11, 2009
4,357
1,069
253
I think re-locking a device's bootloader will not reinstate your device warranty as damage might have occurred when the device was unlocked. Take note that re-locking a bootloader will ensure that the device will only boot to Teclast signed and provided Android images.
 

bercypher

New member
Dec 16, 2020
4
6
3
I have found a method of Teclast P20HD to unlock bootloader which can be found in "https://forum.xda-developers.com/android/help/teclast-p20hd-android-10-tablet-4g-t4141997" and "https://forum.hovatek.com/thread-32287.html", but I'm not sure if that method also works on Teclast M40. If that method works can I restore the bootloader to lock state instead of relock state so I can keep the warranty.
I succeeded in unlocking bootloader of M40 by hovatek's method, but didn't try rooting it.(https://forum.hovatek.com/thread-32674.html)

Here's M40 stock rom. In case you need to recover it...
https://1drv.ms/u/s!AtprAlErUyChn0V0socBsjcnolp8?e=DkJfUa
 
Last edited:

bercypher

New member
Dec 16, 2020
4
6
3
If you suceeded to runlock bootloader, You can replace stock system to gsi system. You need to prepare linux PC (or live usb) and vbmeta.img (included in stock rom).

When you flash, you should use linux PC (Windows pc won't recognize fastbootd mode) and android SDK's adb/fastboot (do not use apt-get install adb/fastboot.).
Download from here -> https://developer.android.com/studio/index.html#downloads

If you want to repalce to Gapps included rom, you need to delete product partiton
> ./fastboot delete-logical-partition product

I tried Android 11 GSI, but boot-looped in OS. Android 10 GSI rom works fine and less error happens.
 
Last edited:

jngiag

Senior Member
Jul 19, 2009
174
75
48
If you suceeded to runlock bootloader, You can replace stock system to gsi system. You need to prepare linux PC (or live usb) and vbmeta.img (included in stock rom).

When you flash, you should use linux PC (Windows pc won't recognize fastbootd mode) and android SDK's adb/fastboot (do not use apt-get install adb/fastboot.).

If you want to repalce to Gapps included rom, you need to delete product partiton
> ./fastboot delete-logical-partition product

I tried Android 11 GSI, but boot-rooped in OS. Android 10 GSI rom works fine and less error happens.
That's good news for M40. Would you share in a little more detail how you suceeded in doing that? Greatly appreciate it. If we could flash gsi, that would open up a lot of choices.
 

jngiag

Senior Member
Jul 19, 2009
174
75
48
I have unlocked bootloader successfully.

Which vbmeta.img is needed here? I have extracted vbmeta_system, vbmeta_vendor and vbmeta-sign. Thanks.
 

bercypher

New member
Dec 16, 2020
4
6
3
I have unlocked bootloader successfully.

Which vbmeta.img is needed here? I have extracted vbmeta_system, vbmeta_vendor and vbmeta-sign. Thanks.
According to the source, we have to flash vbmeta. But I flashed vbmeta, vbmeta_system, vbmeta_vendor just in case, as follows.(for unlocked device.)

./fastboot reboot fastboot
./fastboot --disable-verity --disable-verification flash vbmeta vbmeta-sign.img
./fastboot --disable-verity --disable-verification flash vbmeta_system vbmeta_system.img
./fastboot --disable-verity --disable-verification flash vbmeta_vendor vbmeta_vendor.img
./fastboot erase system
./fastboot delete-logical-partition product
./fastboot --disable-verity --disable-verification flash system (your gsi.img)
./fastboot -w

(When I flashed system, I also disabled verity and verification, but it may be unneccesary)

When I replaced GSI rom, I seemed to forget to wiping userdata.
So, if you wipe userdata, android 11 GSI rom may be flashable.
(Android 11 GSI is freshly made and under developing, so some trouble may be happened like MTK devices.)

NOTE: If you want to root M40, hovatek already succeeded to get root. Refer this :)
(Do not simply patch boot.img and flash. Device will boot-loop.)
 
Last edited:
  • Like
Reactions: RudyGireyev

jngiag

Senior Member
Jul 19, 2009
174
75
48
According to the source, we have to flash vbmeta. But I flashed vbmeta, vbmeta_system, vbmeta_vendor just in case, as follows.(for unlocked device.)

./fastboot reboot fastboot
./fastboot --disable-verity --disable-verification flash vbmeta vbmeta-sign.img
./fastboot --disable-verity --disable-verification flash vbmeta_system vbmeta_system.img
./fastboot --disable-verity --disable-verification flash vbmeta_vendor vbmeta_vendor.img
./fastboot erase system
./fastboot delete-logical-partition product
./fastboot --disable-verity --disable-verification flash system (your gsi.img)
./fastboot -w

(When I flashed system, I also disabled verity and verification, but it may be unneccesary)

When I replaced GSI rom, I seemed to forget to wiping userdata.
So, if you wipe userdata, android 11 GSI rom may be flashable.
(Android 11 GSI is freshly made and under developing, so some trouble may be happened like MTK devices.)

NOTE: If you want to root M40, hovatek already succeeded to get root. Refer this :)
(Do not simply patch boot.img and flash. Device will boot-loop.)
Which gsi image did you use? I tried Havoc (Havoc-OS-v3.8-20200821-Official-GApps-arm64-aonly & Havoc-OS-v3.8-20200821-Official-arm64-aonly), BlissROM and AOSP 11.0 v300.j. No luck, all ended up booting into fastboot mode only. I have flashed back to stock rom now.
 

bercypher

New member
Dec 16, 2020
4
6
3
Which gsi image did you use? I tried Havoc (Havoc-OS-v3.8-20200821-Official-GApps-arm64-aonly & Havoc-OS-v3.8-20200821-Official-arm64-aonly), BlissROM and AOSP 11.0 v300.j. No luck, all ended up booting into fastboot mode only. I have flashed back to stock rom now.
I used PE plus Arm64 AB.(https://sourceforge.net/projects/an...us-10.0-20201105-GSI-ARM64-AB.img.xz/download)

I also tried Havoc v3.8 and AOSP 11, but it did not worked.
I don't know why they doesn't work :(
 
  • Like
Reactions: RudyGireyev

jngiag

Senior Member
Jul 19, 2009
174
75
48

RudyGireyev

Member
Jan 12, 2021
10
1
13
Another gsi rom (ShapeShiftOS-1.2.1_arm64-ab_gapps) flashed successfully. This rom has more features than PE Plus and is equally good.
Can you by chance post a link to where you downloaded this from?

Also any other options besides stock Rom available now?

Thank you this is a very nice thread. My first tablet and the mic is not working well. So need to flash the Rom to something else. Now to find out what is involved.

Rudy
 

jngiag

Senior Member
Jul 19, 2009
174
75
48
Can you by chance post a link to where you downloaded this from?

Also any other options besides stock Rom available now?

Thank you this is a very nice thread. My first tablet and the mic is not working well. So need to flash the Rom to something else. Now to find out what is involved.

Rudy
You can download ShapeShift OS from here (https://sourceforge.net/projects/androidgsi/files/ShapeShiftOS/10/).

I have tried most of the Android 10 and 11 (arm64-ab with gapp version) gsi roms provided here ( https://github.com/phhusson/treble_experimentations/wiki/Generic-System-Image-(GSI)-list) and so far, only managed to get 2 gsi roms (PixelExperiencePlus and ShapeShiftOS by Diust) working.

I have also managed to install magisk manager successfully in stock rom but not in gsi roms. I am using ShapeShiftOS. Hope you can find a new one and share with us here. Good luck!
 
  • Like
Reactions: RudyGireyev

RudyGireyev

Member
Jan 12, 2021
10
1
13
Sorry for such a noob question. But what is the difference between a and ab in the names of the releases?

Also have you guys tried using headphones with your M40 while talking to someone on it? Or even recording yourselves? How is the sound?
 

RudyGireyev

Member
Jan 12, 2021
10
1
13
I don't use headphones, only bluetooth earbuds.
Thank you for the report. I assume the volume level is good then in the stock ROM? People you speak to can hear you well?
By the way, bluetooth doesn't seem to work in gsi rom but stock rom is ok.
WOW! So this is not se easy. Is it because the tablet is still new and the processor is so new? Will things settle down and stabilize?
 

jngiag

Senior Member
Jul 19, 2009
174
75
48
Thank you for the report. I assume the volume level is good then in the stock ROM? People you speak to can hear you well?
WOW! So this is not se easy. Is it because the tablet is still new and the processor is so new? Will things settle down and stabilize?
The sound of stock rom in both speaker mode and bluetooth earbud is loud enough and okay. Sound of gsi rom in speaker mode is slightly better. Gsi roms are generic and usually need some fine tunning for specific devices.
 
  • Like
Reactions: RudyGireyev

siamese007

Senior Member
Oct 8, 2017
152
37
28
Bangkok
Sorry for such a noob question. But what is the difference between a and ab in the names of the releases?

Also have you guys tried using headphones with your M40 while talking to someone on it? Or even recording yourselves? How is the sound?
Hello friend, I am newbie in Android. All I know about GSI is A only means your devices can boot only 1 /system partition. A/B means your devices can boot 2 /system partition: /system_a and /system_b.

I was gonna buy this tablet but I saw this is Unisoc which I am afraid of the support tools. So I bought M30 Pro instead. I will consider to buy M40 later if the price drops again.

Edit1: A/B is like seamless update over OTA. When you download firmware Updates from OTA your devices can flash during running the system to the other /system partition. Once your devices reboot the newly flashed /system partition will be active and the other recent /system will be inactive.

Edit2: You can download Project Treble Check app in Play Store to see which types of your system partition would be.
 
Last edited:
  • Like
Reactions: RudyGireyev