HTC U19e - Unlock - Flashing GSIs Rom
HTC U19e - Unlock - Flashing GSIs Rom
Reference
- Andy Yan's personal builds GSI Files, https://sourceforge.net/projects/andyyan-gsi/files/
- Generic System Images (GSIs), https://developer.android.com/topic/generic-system-image
- Flashing GSIs, https://source.android.com/docs/core/tests/vts/gsi#flashing-gsis
- ADB|FASTBOOT|LINUX COMMAND, https://xdaforums.com/t/adb-fastboot-linux-commands-bootloader-kernel-recovery-rom-root-backup.3597181/
- Project Treble GSI通刷ROM刷入方法, https://forum.gamer.com.tw/C.php?bsn=60559&snA=41781
- HTC U19e root方式&心得, https://forum.gamer.com.tw/C.php?bsn=60559&snA=61118
HTC U19e Stock Rom Information
- Android 9
- Software Number 1.00.709.30
Check the Treble GSI Requirements
- Install Treble Info apk from F-Droid, https://f-droid.org/packages/tk.hack5.treblecheck/
Download 'vbmeta.img' from Google GSIs
Download Platform Tools, ADB/fastboot
- Platform Tools, https://dl.google.com/android/repository/platform-tools-latest-linux.zip
- Using ADB and fastboot, https://wiki.lineageos.org/adb_fastboot_guide
HTC U19e GSIs Boot Result (Arm64/AB-System)
- Boot GSIs Pass. The boot time is long at first boot
- lineage-17.1-20210808-UNOFFICIAL-treble_arm64_bvS.img, Android10
- lineage-19.1-20240419-UNOFFICIAL-arm64_bgN.img, Android12
- lineage-20.0-20240516-UNOFFICIAL-arm64_bgN.img, Android13
- PixelExperience_Plus_arm64-ab-13.0-20230914-UNOFFICIAL.img, Android13
- Boot GSIs Fail.
- lineage-21.0-20240518-UNOFFICIAL-gsi_arm64_gN.img, Android14
- lineage-21.0-20240526-UNOFFICIAL-arm64_bgN.img, Android14
HTC U19e Unlock & Flashing GSIs
Boot to FastMode
- The method of Reboot to Bootloader, https://community.htc.com/tw/chat.php?mod=viewthread&tid=35763
- Method 1
The phone is power-on, then
press power key untiles phone power-off and release power key, then
press volumn down key untiles vibration is starting, then release volumn down key - Method 2
Press volumn down key + power key untiles phone vibration is starting, then leave all key
Unlock
$sudo ./adb devices $sudo ./adb reboot bootloader $sudo ./fastboot devices $sudo ./fastboot flashing unlock
- on the phone screen select 'unlock bootloader', then the phone will erase and
reboot to welcome screen
- on the phone screen select 'unlock bootloader', then the phone will erase and
Make sure the (bootloader) current-slot:b
$sudo ./fastboot getvar all
Erase
$sudo ./fastboot erase system_b
Flash
$sudo ./fastboot flash system_b lineage-20.0-20240516-UNOFFICIAL-arm64_bgN.img
Disable Android Verified Boot(AVB)
$sudo ./fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
Using Volumn Key and reboot to 'Recovery Mode'
- Do not use command '$fastboot -w' to erase userdata, the phone will be boot in power cycle.
1. In Recovery Mode, select 'Wipe data/factory reset' to wipe /data mount 2. If /data wipes compete, select reboot system now.
Work Around - fastboot < waiting for any device >
- Work around, https://discuss.grapheneos.org/d/3419-fastboot-waiting-for-device/2
- fastboot connecting method
- A template flow. Because this usb driver is really hard to use.
1. Disable autoprobe $cat /sys/bus/usb/drivers_autoprobe $sudo echo 0 | sudo tee /sys/bus/usb/drivers_autoprobe 2. plug usb $sudo ./fastboot devices $sudo ./fastboot getvar all $show < waiting for any device > 3. enable autoprobe $cat /sys/bus/usb/drivers_autoprobe $sudo echo 1 | sudo tee /sys/bus/usb/drivers_autoprobe 4. replug usb & connected
HTC OTA Downloader
- HTC OTA Downloader App, Download Link
- Information can be read from ADB command. Remember to enable Developer Options/USB Debug.
$sudo ./adb shell $getprop [ro.product.vendor.name]: [htc_tetdugl] [ro.cid]: [HTC__621] [ro.product.version]: [1.00.709.30]
HTC U19e OTA Rom, Curl Download Link
- Version: 1.00.709.24-1.00.709.28, Size: 567.8MB
$curl -H "User-Agent: Android-Checkin/8.0" -H "htc1s: 670246FA64RBN019231720627" "http://fotadl.htc.com/OTA_1.00.709.24-1.00.709.281whkapyegkf42pto.zip" -o "OTA_1.00.709.24-1.00.709.281whkapyegkf42pto.zip"
- Version: 1.00.709.26-1.00.709.28, Size: 569.8MB
$curl -H "User-Agent: Android-Checkin/8.0" -H "htc1s: 1CC57KYJ01493172062856886" "http://fotadl.htc.com/OTA_1.00.709.26-1.00.709.2867vioep3fxj4a8z1.zip" -o "OTA_1.00.709.26-1.00.709.2867vioep3fxj4a8z1.zip"
- Version: 1.00.709.28-1.00.709.30, Size: 154.8MB
$curl -H "User-Agent: Android-Checkin/8.0" -H "htc1s: 42HT464WM0653917206274992" "http://fotadl.htc.com/OTA_1.00.709.28-1.00.709.300d96mg614cdk074q.zip" -o "OTA_1.00.709.28-1.00.709.300d96mg614cdk074q.zip"
Download 'payload_dumper'
- payload_dumper App, https://github.com/vm03/payload_dumper
ADB Backup System Partition
- COPY WHOLE PARTITION IMAGE (within device), https://xdaforums.com/t/adb-fastboot-linux-commands-bootloader-kernel-recovery-rom-root-backup.3597181/
- HTC U19e Partition of A/B system
- boot.img
- boot_a -> /dev/block/mmcblk0p12
- boot_b -> /dev/block/mmcblk0p13
- dtbo.img
- dtbo_a -> /dev/block/mmcblk0p46
- dtbo_b -> /dev/block/mmcblk0p47
- system.img
- system_a -> /dev/block/mmcblk0p14
- system_b -> /dev/block/mmcblk0p15
- vbmeta.img
- vbmeta_a -> /dev/block/mmcblk0p63
- vbmeta_b -> /dev/block/mmcblk0p64
- factory.img
- factory -> /dev/block/mmcblk0p65
- boot.img
- Check Device Mount Mapping
$sudo ./adb shell $cd /dev/block/platform/soc/7c4000.sdhci $ls -al $cd by-name $ls -al lrwxrwxrwx 1 root root 21 1970-01-01 16:42 abl_a -> /dev/block/mmcblk0p28 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 abl_b -> /dev/block/mmcblk0p29 lrwxrwxrwx 1 root root 20 1970-01-01 16:42 aop_a -> /dev/block/mmcblk0p7 lrwxrwxrwx 1 root root 20 1970-01-01 16:42 aop_b -> /dev/block/mmcblk0p8 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 apdp -> /dev/block/mmcblk0p32 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 apppreload -> /dev/block/mmcblk0p66 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 bluetooth_a -> /dev/block/mmcblk0p42 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 bluetooth_b -> /dev/block/mmcblk0p43 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 boot_a -> /dev/block/mmcblk0p12 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 boot_b -> /dev/block/mmcblk0p13 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 cmnlib64_a -> /dev/block/mmcblk0p21 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 cmnlib64_b -> /dev/block/mmcblk0p23 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 cmnlib_a -> /dev/block/mmcblk0p20 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 cmnlib_b -> /dev/block/mmcblk0p22 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 cota -> /dev/block/mmcblk0p67 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 ddr -> /dev/block/mmcblk0p40 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 devcfg_a -> /dev/block/mmcblk0p53 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 devcfg_b -> /dev/block/mmcblk0p54 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 devinfo -> /dev/block/mmcblk0p31 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 dip -> /dev/block/mmcblk0p30 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 dpo -> /dev/block/mmcblk0p35 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 dsp_a -> /dev/block/mmcblk0p26 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 dsp_b -> /dev/block/mmcblk0p27 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 dtbo_a -> /dev/block/mmcblk0p46 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 dtbo_b -> /dev/block/mmcblk0p47 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 factory -> /dev/block/mmcblk0p65 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 frp -> /dev/block/mmcblk0p57 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 fsc -> /dev/block/mmcblk0p44 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 fsg -> /dev/block/mmcblk0p11 lrwxrwxrwx 1 root root 20 1970-01-01 16:42 hyp_a -> /dev/block/mmcblk0p9 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 hyp_b -> /dev/block/mmcblk0p10 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 keymaster_a -> /dev/block/mmcblk0p18 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 keymaster_b -> /dev/block/mmcblk0p19 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 keystore -> /dev/block/mmcblk0p52 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 limits -> /dev/block/mmcblk0p37 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 logdump -> /dev/block/mmcblk0p58 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 logfs -> /dev/block/mmcblk0p39 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 misc -> /dev/block/mmcblk0p51 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 modem_a -> /dev/block/mmcblk0p24 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 modem_b -> /dev/block/mmcblk0p25 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 modemst1 -> /dev/block/mmcblk0p48 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 modemst2 -> /dev/block/mmcblk0p49 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 msadp -> /dev/block/mmcblk0p33 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 persist -> /dev/block/mmcblk0p50 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 qupfw_a -> /dev/block/mmcblk0p55 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 qupfw_b -> /dev/block/mmcblk0p56 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 rawdump -> /dev/block/mmcblk0p62 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 sec -> /dev/block/mmcblk0p41 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 splash -> /dev/block/mmcblk0p36 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 spunvm -> /dev/block/mmcblk0p34 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 ssd -> /dev/block/mmcblk0p45 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 sti -> /dev/block/mmcblk0p59 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 storsec_a -> /dev/block/mmcblk0p60 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 storsec_b -> /dev/block/mmcblk0p61 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 system_a -> /dev/block/mmcblk0p14 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 system_b -> /dev/block/mmcblk0p15 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 toolsfv -> /dev/block/mmcblk0p38 lrwxrwxrwx 1 root root 20 1970-01-01 16:42 tz_a -> /dev/block/mmcblk0p5 lrwxrwxrwx 1 root root 20 1970-01-01 16:42 tz_b -> /dev/block/mmcblk0p6 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 userdata -> /dev/block/mmcblk0p68 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 vbmeta_a -> /dev/block/mmcblk0p63 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 vbmeta_b -> /dev/block/mmcblk0p64 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 vendor_a -> /dev/block/mmcblk0p16 lrwxrwxrwx 1 root root 21 1970-01-01 16:42 vendor_b -> /dev/block/mmcblk0p17 lrwxrwxrwx 1 root root 20 1970-01-01 16:42 xbl_a -> /dev/block/mmcblk0p1 lrwxrwxrwx 1 root root 20 1970-01-01 16:42 xbl_b -> /dev/block/mmcblk0p2 lrwxrwxrwx 1 root root 20 1970-01-01 16:42 xbl_config_a -> /dev/block/mmcblk0p3 lrwxrwxrwx 1 root root 20 1970-01-01 16:42 xbl_config_b -> /dev/block/mmcblk0p4
留言
張貼留言