[Fire HD 8 and HD 10 Original Android Development] lilsphinx90:
Got past the serial protocol mismatch when doing it from Ubuntu through a bootable USB

However, after sudo ./bootrom-step.sh, I get "Reboot" and not "Reboot to unlocked fastboot"

From the recovery menu, I can't really do any of the fastboot-step.sh or return-to-stock.sh as it just says < waiting for any device >

How do I proceed from here? Do I just use adb sideload to load a compatible img?

EDIT: Tried the ADB sideload with update-kindle-40.6.3.6_user_636558520.bin

Got "E:failed to verify whole-file signature

E:signature verification failed

Installation aborted."

EDIT2: Here is my log after running sudo ./bootrom-step.sh and shorting TP28

ubuntu@ubuntu:~/Downloads/amonet-douglas-v1.2/amonet$ sudo ./bootrom-step.sh
[2019-10-16 07:47:19.581534] Waiting for bootrom
[2019-10-16 07:48:04.383662] Found port = /dev/ttyACM0
[2019-10-16 07:48:04.384359] Handshake

* * * If you have a short attached, remove it now * * *
* * * Press Enter to continue * * *

[2019-10-16 07:48:07.392635] Init crypto engine
[2019-10-16 07:48:07.412500] Disable caches
[2019-10-16 07:48:07.413095] Disable bootrom range checks
[2019-10-16 07:48:07.428163] Load payload from ../brom-payload/build/payload.bin = 0x4888 bytes
[2019-10-16 07:48:07.429401] Send payload
[2019-10-16 07:48:08.047042] Let's rock
[2019-10-16 07:48:08.047920] Wait for the payload to come online...
[2019-10-16 07:48:09.186534] all good
[2019-10-16 07:48:09.186859] Check GPT
[2019-10-16 07:48:09.566554]
[2019-10-16 07:48:09.566822] Sector size (logical): 512 bytes
[2019-10-16 07:48:09.567023] Disk identifier (GUID): 25EDA995-AA50-46BD-A07F-1954035388CA
[2019-10-16 07:48:09.567169] Partition table holds up to 128 entries
[2019-10-16 07:48:09.567304] This partition table begins at sector 2 and ends at sector 33
[2019-10-16 07:48:09.567424] First usable sector is 34, last usable sector is 30777310
[2019-10-16 07:48:09.567536] Other partition table is at sector 30777343
[2019-10-16 07:48:09.567644]
[2019-10-16 07:48:09.567839] Number Start (sector) End (sector) Size Name
[2019-10-16 07:48:09.570141] 1 1024 7167 3.00 MiB proinfo
[2019-10-16 07:48:09.570452] 2 7168 16383 4.50 MiB PMT
[2019-10-16 07:48:09.570763] 3 16384 17407 512.00 KiB lk
[2019-10-16 07:48:09.571068] 4 17408 18431 512.00 KiB lk2
[2019-10-16 07:48:09.571408] 5 18432 51199 16.00 MiB boot_x
[2019-10-16 07:48:09.571709] 6 51200 86015 17.00 MiB recovery_x
[2019-10-16 07:48:09.572007] 7 86016 96255 5.00 MiB tee1
[2019-10-16 07:48:09.572303] 8 96256 106495 5.00 MiB tee2
[2019-10-16 07:48:09.572604] 9 106496 187391 39.50 MiB metadata
[2019-10-16 07:48:09.572907] 10 187392 189439 1024.00 KiB kb
[2019-10-16 07:48:09.573210] 11 189440 191487 1024.00 KiB dkb
[2019-10-16 07:48:09.573516] 12 191488 192511 512.00 KiB MISC
[2019-10-16 07:48:09.573816] 13 192512 208895 8.00 MiB reserved
[2019-10-16 07:48:09.574124] 14 208896 3515391 1.58 GiB system
[2019-10-16 07:48:09.574532] 15 3515392 4383743 424.00 MiB cache
[2019-10-16 07:48:09.574838] 16 4383744 30325759 12.37 GiB userdata
[2019-10-16 07:48:09.575142] 17 30325760 30551039 110.00 MiB boot
[2019-10-16 07:48:09.575446] 18 30551040 30776319 110.00 MiB recovery
[2019-10-16 07:48:09.604103]
[2019-10-16 07:48:09.604205] Check boot0
[2019-10-16 07:48:09.845679] Check rpmb
[2019-10-16 07:48:10.055609] Clear preloader header
[8 / 8]
[2019-10-16 07:48:10.470506] Downgrade rpmb
[2019-10-16 07:48:10.472514] Recheck rpmb
[2019-10-16 07:48:11.367044] rpmb downgrade ok
[2019-10-16 07:48:11.367708] Flash preloader
[272 / 272]
[272 / 272]
[2019-10-16 07:48:23.649679] Flash tz
[6459 / 6459]
[2019-10-16 07:50:41.609426] Flash lk
[950 / 950]
[2019-10-16 07:51:02.154240] Inject payload
[8 / 8]
[962 / 962]
[8 / 8]
[962 / 962]
[2019-10-16 07:51:43.832326] Force fastboot
[2019-10-16 07:51:44.139647] Flash preloader header
[4 / 4]
[4 / 4]
[2019-10-16 07:51:44.553461] Reboot

Seems I am unable to boot to unlocked bootloader to proceed with the next steps..

EDIT3: Read some more posts where I overlooked amonet-res, so I tried the sudo ./bootrom-step.sh from there

ubuntu@ubuntu:~/Downloads/amonet-res$ sudo ./bootrom-step.sh
[2019-10-16 08:03:11.399737] Waiting for bootrom
[2019-10-16 08:04:01.401945] Found port = /dev/ttyACM0
[2019-10-16 08:04:01.402752] Handshake
[2019-10-16 08:04:01.403660] Disable watchdog

* * * Remove the short and press Enter * * *

[2019-10-16 08:04:05.483835] Init crypto engine
[2019-10-16 08:04:05.506579] Disable caches
[2019-10-16 08:04:05.507154] Disable bootrom range checks
[2019-10-16 08:04:05.523974] Load payload from ../brom-payload/build/payload.bin = 0x4690 bytes
[2019-10-16 08:04:05.530154] Send payload
[2019-10-16 08:04:06.168230] Let's rock
[2019-10-16 08:04:06.168820] Wait for the payload to come online...
[2019-10-16 08:04:07.326401] all good
[2019-10-16 08:04:07.326535] Check GPT
[2019-10-16 08:04:07.661213] gpt_parsed = {'proinfo': (1024, 6144), 'PMT': (7168, 9216), 'lk': (16384, 1024), 'lk2': (17408, 1024), 'boot_x': (18432, 32768), 'recovery_x': (51200, 34816), 'tee1': (86016, 10240), 'tee2': (96256, 10240), 'metadata': (106496, 80896), 'kb': (187392, 2048), 'dkb': (189440, 2048), 'MISC': (191488, 1024), 'reserved': (192512, 16384), 'system': (208896, 3306496), 'cache': (3515392, 868352), 'userdata': (4383744, 25942016)}
Traceback (most recent call last):
File "main.py", line 125, in <module>
main()
File "main.py", line 69, in main
raise RuntimeError("bad gpt")
RuntimeError: bad gpt

EDIT 4: And same bad gpt if I do sudo ./bootrom-step.sh from amonet (i initially was using amonet-douglas-v1.2)

ubuntu@ubuntu:~/Downloads/amonet$ sudo ./bootrom-step.sh
[2019-10-16 08:06:23.171336] Waiting for bootrom
[2019-10-16 08:06:38.262157] Found port = /dev/ttyACM0
[2019-10-16 08:06:38.262406] Handshake
[2019-10-16 08:06:38.262900] Disable watchdog

* * * Remove the short and press Enter * * *

[2019-10-16 08:06:40.305864] Init crypto engine
[2019-10-16 08:06:40.326280] Disable caches
[2019-10-16 08:06:40.326938] Disable bootrom range checks
[2019-10-16 08:06:40.344117] Load payload from ../brom-payload/build/payload.bin = 0x4690 bytes
[2019-10-16 08:06:40.351726] Send payload
[2019-10-16 08:06:40.920875] Let's rock
[2019-10-16 08:06:40.921550] Wait for the payload to come online...
[2019-10-16 08:06:42.079252] all good
[2019-10-16 08:06:42.079733] Check GPT
[2019-10-16 08:06:42.415320] gpt_parsed = {'proinfo': (1024, 6144), 'PMT': (7168, 9216), 'lk': (16384, 1024), 'lk2': (17408, 1024), 'boot_x': (18432, 32768), 'recovery_x': (51200, 34816), 'tee1': (86016, 10240), 'tee2': (96256, 10240), 'metadata': (106496, 80896), 'kb': (187392, 2048), 'dkb': (189440, 2048), 'MISC': (191488, 1024), 'reserved': (192512, 16384), 'system': (208896, 3306496), 'cache': (3515392, 868352), 'userdata': (4383744, 25942016)}
Traceback (most recent call last):
File "main.py", line 123, in <module>
main()
File "main.py", line 69, in main
raise RuntimeError("bad gpt")
RuntimeError: bad gpt

EDIT 5: Went to the main thread and got the amonet-douglas-gptfix and did sudo ./gpt-fix-16G.sh

ubuntu@ubuntu:~/Downloads/amonet-douglas-v1.2/amonet$ sudo ./gpt-fix-16G.sh
[2019-10-16 08:09:54.087773] Waiting for bootrom
[2019-10-16 08:10:11.466751] Found port = /dev/ttyACM0
[2019-10-16 08:10:11.467108] Handshake

* * * If you have a short attached, remove it now * * *
* * * Press Enter to continue * * *

\[2019-10-16 08:10:13.471787] Init crypto engine
[2019-10-16 08:10:13.493715] Disable caches
[2019-10-16 08:10:13.494370] Disable bootrom range checks
[2019-10-16 08:10:13.511997] Load payload from ../brom-payload/build/payload.bin = 0x4888 bytes
[2019-10-16 08:10:13.518199] Send payload
[2019-10-16 08:10:14.156719] Let's rock
[2019-10-16 08:10:14.157841] Wait for the payload to come online...
[2019-10-16 08:10:15.296436] all good
[2019-10-16 08:10:15.297243] Check GPT
[2019-10-16 08:10:15.298453] Flashing 16G GPT
[34 / 34]
[2019-10-16 08:10:16.424253]
[2019-10-16 08:10:16.424328] Sector size (logical): 512 bytes
[2019-10-16 08:10:16.424375] Disk identifier (GUID): BE9E3536-6B98-4084-A368-36B21A533077
[2019-10-16 08:10:16.424409] Partition table holds up to 128 entries
[2019-10-16 08:10:16.424440] This partition table begins at sector 2 and ends at sector 33
[2019-10-16 08:10:16.424467] First usable sector is 34, last usable sector is 30535646
[2019-10-16 08:10:16.424492] Other partition table is at sector 30535679
[2019-10-16 08:10:16.424516]
[2019-10-16 08:10:16.424561] Number Start (sector) End (sector) Size Name
[2019-10-16 08:10:16.425250] 1 1024 7167 3.00 MiB proinfo
[2019-10-16 08:10:16.425644] 2 7168 16383 4.50 MiB PMT
[2019-10-16 08:10:16.426030] 3 16384 17407 512.00 KiB lk
[2019-10-16 08:10:16.426413] 4 17408 18431 512.00 KiB lk2
[2019-10-16 08:10:16.426837] 5 18432 51199 16.00 MiB boot
[2019-10-16 08:10:16.427212] 6 51200 86015 17.00 MiB recovery
[2019-10-16 08:10:16.427584] 7 86016 96255 5.00 MiB tee1
[2019-10-16 08:10:16.427958] 8 96256 106495 5.00 MiB tee2
[2019-10-16 08:10:16.428333] 9 106496 187391 39.50 MiB metadata
[2019-10-16 08:10:16.428726] 10 187392 189439 1024.00 KiB kb
[2019-10-16 08:10:16.429125] 11 189440 191487 1024.00 KiB dkb
[2019-10-16 08:10:16.429511] 12 191488 192511 512.00 KiB MISC
[2019-10-16 08:10:16.429887] 13 192512 208895 8.00 MiB reserved
[2019-10-16 08:10:16.430272] 14 208896 3515391 1.58 GiB system
[2019-10-16 08:10:16.430682] 15 3515392 4383743 424.00 MiB cache
[2019-10-16 08:10:16.431080] 16 4383744 30535646 12.47 GiB userdata
[2019-10-16 08:10:16.464502]
[2019-10-16 08:10:16.464602] Modify GPT
[2019-10-16 08:10:16.464738] Validate GPT
[2019-10-16 08:10:16.465157]
[2019-10-16 08:10:16.465199] Sector size (logical): 512 bytes
[2019-10-16 08:10:16.465236] Disk identifier (GUID): BE9E3536-6B98-4084-A368-36B21A533077
[2019-10-16 08:10:16.465263] Partition table holds up to 128 entries
[2019-10-16 08:10:16.465288] This partition table begins at sector 2 and ends at sector 33
[2019-10-16 08:10:16.465312] First usable sector is 34, last usable sector is 30535646
[2019-10-16 08:10:16.465333] Other partition table is at sector 30535679
[2019-10-16 08:10:16.465354]
[2019-10-16 08:10:16.465391] Number Start (sector) End (sector) Size Name
[2019-10-16 08:10:16.465679] 1 1024 7167 3.00 MiB proinfo
[2019-10-16 08:10:16.465976] 2 7168 16383 4.50 MiB PMT
[2019-10-16 08:10:16.466272] 3 16384 17407 512.00 KiB lk
[2019-10-16 08:10:16.466566] 4 17408 18431 512.00 KiB lk2
[2019-10-16 08:10:16.466860] 5 18432 51199 16.00 MiB boot_x
[2019-10-16 08:10:16.467154] 6 51200 86015 17.00 MiB recovery_x
[2019-10-16 08:10:16.467447] 7 86016 96255 5.00 MiB tee1
[2019-10-16 08:10:16.467745] 8 96256 106495 5.00 MiB tee2
[2019-10-16 08:10:16.468044] 9 106496 187391 39.50 MiB metadata
[2019-10-16 08:10:16.468341] 10 187392 189439 1024.00 KiB kb
[2019-10-16 08:10:16.468638] 11 189440 191487 1024.00 KiB dkb
[2019-10-16 08:10:16.469004] 12 191488 192511 512.00 KiB MISC
[2019-10-16 08:10:16.469401] 13 192512 208895 8.00 MiB reserved
[2019-10-16 08:10:16.469703] 14 208896 3515391 1.58 GiB system
[2019-10-16 08:10:16.470091] 15 3515392 4383743 424.00 MiB cache
[2019-10-16 08:10:16.470620] 16 4383744 30084095 12.25 GiB userdata
[2019-10-16 08:10:16.470970] 17 30084096 30309375 110.00 MiB boot
[2019-10-16 08:10:16.471272] 18 30309376 30534655 110.00 MiB recovery
[2019-10-16 08:10:16.499584]
[2019-10-16 08:10:16.499663] Flash new primary GPT
[34 / 34]
[2019-10-16 08:10:17.224612] Flash new backup GPT
[33 / 33]
[2019-10-16 08:10:18.066115]
[2019-10-16 08:10:18.066389] Sector size (logical): 512 bytes
[2019-10-16 08:10:18.066592] Disk identifier (GUID): BE9E3536-6B98-4084-A368-36B21A533077
[2019-10-16 08:10:18.066734] Partition table holds up to 128 entries
[2019-10-16 08:10:18.066862] This partition table begins at sector 2 and ends at sector 33
[2019-10-16 08:10:18.066982] First usable sector is 34, last usable sector is 30535646
[2019-10-16 08:10:18.067096] Other partition table is at sector 30535679
[2019-10-16 08:10:18.067205]
[2019-10-16 08:10:18.067402] Number Start (sector) End (sector) Size Name
[2019-10-16 08:10:18.069096] 1 1024 7167 3.00 MiB proinfo
[2019-10-16 08:10:18.070785] 2 7168 16383 4.50 MiB PMT
[2019-10-16 08:10:18.072511] 3 16384 17407 512.00 KiB lk
[2019-10-16 08:10:18.074223] 4 17408 18431 512.00 KiB lk2
[2019-10-16 08:10:18.075868] 5 18432 51199 16.00 MiB boot_x
[2019-10-16 08:10:18.077473] 6 51200 86015 17.00 MiB recovery_x
[2019-10-16 08:10:18.079092] 7 86016 96255 5.00 MiB tee1
[2019-10-16 08:10:18.080919] 8 96256 106495 5.00 MiB tee2
[2019-10-16 08:10:18.082889] 9 106496 187391 39.50 MiB metadata
[2019-10-16 08:10:18.084882] 10 187392 189439 1024.00 KiB kb
[2019-10-16 08:10:18.086582] 11 189440 191487 1024.00 KiB dkb
[2019-10-16 08:10:18.088162] 12 191488 192511 512.00 KiB MISC
[2019-10-16 08:10:18.089849] 13 192512 208895 8.00 MiB reserved
[2019-10-16 08:10:18.091441] 14 208896 3515391 1.58 GiB system
[2019-10-16 08:10:18.093026] 15 3515392 4383743 424.00 MiB cache
[2019-10-16 08:10:18.094673] 16 4383744 30084095 12.25 GiB userdata
[2019-10-16 08:10:18.095817] 17 30084096 30309375 110.00 MiB boot
[2019-10-16 08:10:18.096936] 18 30309376 30534655 110.00 MiB recovery
[2019-10-16 08:10:18.139855]
[2019-10-16 08:10:18.139962] Check boot0
[2019-10-16 08:10:18.382687] Check rpmb
[2019-10-16 08:10:18.592550] Clear preloader header
[8 / 8]
[2019-10-16 08:10:19.075760] Downgrade rpmb
[2019-10-16 08:10:19.077523] Recheck rpmb
[2019-10-16 08:10:19.972178] rpmb downgrade ok
[2019-10-16 08:10:19.972718] Flash preloader
[272 / 272]
[272 / 272]
[2019-10-16 08:10:32.128085] Flash tz
[6459 / 6459]
[2019-10-16 08:12:50.092668] Flash lk
[950 / 950]
[2019-10-16 08:13:10.603907] Inject payload
[8 / 8]
[962 / 962]
[8 / 8]
[962 / 962]
[2019-10-16 08:13:52.522035] Force fastboot
[2019-10-16 08:13:52.830273] Flash preloader header
[4 / 4]
[4 / 4]
[2019-10-16 08:13:53.245359] Reboot

then I ran amonet-res/bootrom-step.sh again and got bad gpt, so not going to use the files in amonet-res anymore

But either way, at this point when i write lsusb, i see Bus 001 Device 069: ID 0e8d:0003 MediaTek Inc. MT6227 phone

and not Preloader anymore, so that's progress?

EDIT 6: Tried running sudo ./bootrom-step.sh one last time to see if anything has changed since doing the gpt fix, still says "Reboot" and not to unlocked fastboot

ubuntu@ubuntu:~/Downloads/amonet-douglas-v1.2/amonet$ sudo ./bootrom-step.sh
[2019-10-16 08:25:34.101781] Waiting for bootrom
[2019-10-16 08:25:52.228652] Found port = /dev/ttyACM0
[2019-10-16 08:25:52.228870] Handshake

* * * If you have a short attached, remove it now * * *
* * * Press Enter to continue * * *

[2019-10-16 08:25:54.233123] Init crypto engine
[2019-10-16 08:25:54.249836] Disable caches
[2019-10-16 08:25:54.250143] Disable bootrom range checks
[2019-10-16 08:25:54.261592] Load payload from ../brom-payload/build/payload.bin = 0x4888 bytes
[2019-10-16 08:25:54.263890] Send payload
[2019-10-16 08:25:54.900755] Let's rock
[2019-10-16 08:25:54.901377] Wait for the payload to come online...
[2019-10-16 08:25:55.831009] all good
[2019-10-16 08:25:55.831354] Check GPT
[2019-10-16 08:25:56.210845]
[2019-10-16 08:25:56.211109] Sector size (logical): 512 bytes
[2019-10-16 08:25:56.211312] Disk identifier (GUID): BE9E3536-6B98-4084-A368-36B21A533077
[2019-10-16 08:25:56.211461] Partition table holds up to 128 entries
[2019-10-16 08:25:56.211597] This partition table begins at sector 2 and ends at sector 33
[2019-10-16 08:25:56.211719] First usable sector is 34, last usable sector is 30777310
[2019-10-16 08:25:56.211833] Other partition table is at sector 30777343
[2019-10-16 08:25:56.211944]
[2019-10-16 08:25:56.212150] Number Start (sector) End (sector) Size Name
[2019-10-16 08:25:56.215376] 1 1024 7167 3.00 MiB proinfo
[2019-10-16 08:25:56.217216] 2 7168 16383 4.50 MiB PMT
[2019-10-16 08:25:56.218866] 3 16384 17407 512.00 KiB lk
[2019-10-16 08:25:56.220477] 4 17408 18431 512.00 KiB lk2
[2019-10-16 08:25:56.222378] 5 18432 51199 16.00 MiB boot_x
[2019-10-16 08:25:56.224042] 6 51200 86015 17.00 MiB recovery_x
[2019-10-16 08:25:56.225809] 7 86016 96255 5.00 MiB tee1
[2019-10-16 08:25:56.227393] 8 96256 106495 5.00 MiB tee2
[2019-10-16 08:25:56.229465] 9 106496 187391 39.50 MiB metadata
[2019-10-16 08:25:56.231421] 10 187392 189439 1024.00 KiB kb
[2019-10-16 08:25:56.232786] 11 189440 191487 1024.00 KiB dkb
[2019-10-16 08:25:56.234388] 12 191488 192511 512.00 KiB MISC
[2019-10-16 08:25:56.235629] 13 192512 208895 8.00 MiB reserved
[2019-10-16 08:25:56.236591] 14 208896 3515391 1.58 GiB system
[2019-10-16 08:25:56.237497] 15 3515392 4383743 424.00 MiB cache
[2019-10-16 08:25:56.238348] 16 4383744 30084095 12.25 GiB userdata
[2019-10-16 08:25:56.239232] 17 30084096 30309375 110.00 MiB boot
[2019-10-16 08:25:56.240099] 18 30309376 30777310 228.48 MiB recovery
[2019-10-16 08:25:56.278058]
[2019-10-16 08:25:56.278161] Check boot0
[2019-10-16 08:25:56.519760] Check rpmb
[2019-10-16 08:25:56.729625] Clear preloader header
[8 / 8]
[2019-10-16 08:25:57.144670] Downgrade rpmb
[2019-10-16 08:25:57.146747] Recheck rpmb
[2019-10-16 08:25:58.041294] rpmb downgrade ok
[2019-10-16 08:25:58.041892] Flash preloader
[272 / 272]
[272 / 272]
[2019-10-16 08:26:10.213271] Flash tz
[6459 / 6459]
[2019-10-16 08:28:28.388989] Flash lk
[950 / 950]
[2019-10-16 08:28:48.942639] Inject payload
[8 / 8]
[962 / 962]
[8 / 8]
[962 / 962]
[2019-10-16 08:29:30.928420] Force fastboot
[2019-10-16 08:29:31.237220] Flash preloader header
[4 / 4]
[4 / 4]
[2019-10-16 08:29:31.652780] Reboot