yashsingh1/xdaforums huggingface dataset:
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
I appreciate you so much! And I completely understand. I hope everything you're working on gets resolved!

I have backed it up as you suggested! Since the back-up is also on the internal drive, it will be deleted later, correct? It's 5gbs out of the already small storage space.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
With the 5GB TWRP backup folder safely copied off-device you can delete the local copy at any time...although there is no immediate reason to do so.

Next step is to unlock the bootloader:

- verify 'get_code.bat' & 'unlock.bat' reside in the same folder as adb.exe and fastboot.exe

- look around to see if you have a file called 'unlock.code' from a previous run of 'get_code.bat'; if so place it in the same folder

- tether device and boot into fastboot (easiest way: boot into TWRP and then use reboot menu to boot the bootloader) [<--what an awkward sentence!]

- enter 'fastboot devices' to validate communication between host and device

- execute unlock.bat; if you get a green 'OK' the bootloader is unlocked!

- if not boot into FireOS (get past unlock screen), tether, verify adb communication is working and then run 'get_code.bat' to (re)create the 'unlock.code' file

- repeat steps 2-4 (above)

If that doesn't work and/or you are unable to boot into TWRP then a bit of extra work will be needed to generate a valid unlock code. Brief outline:

- download legacy Fire Nexus ROM from here (it does NOT require an unlocked bootloader)

- tether device and into TWRP

- from Windows copy downloaded ROM to a folder on the device (suggest creating a new folder with your initials as the name)

- from the TWRP main menu tap Wipe then swipe to perform a 'factory reset'

- from the TWRP main menu tap Install

- navigate to the folder where you stored the downloaded ROM

- select the ROM zip and then click to install

- when complete allow the device to restart; after a 3-5 min it should boot into Fire Nexus; skip the Google config (not needed)

- enable developer options and adb bridge

- tether device and verify adb connectivity

- run 'get_code.bat' to generate a fresh unlock.code file

I will be traveling much of Sunday with irregular network access. I'll try to respond to an questions/problems as time permits. Apologies in advance for any delays.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
Welp, device won't boot into FireOS. It boots straight to Fastboot. I tried Installing nexus ROM but I got "can't install this package over newer build updater process ended with error:7".
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
Error 7 is pretty generic and can be due to a conflict between install package and TWRP or an issue with the system partition. It's a solvable issue without too much work. They the following in the order listed.

1) In TWRP tap wipe -> advanced. Tick system, data, dalvik and cache; leave internal storage unticked. Tap the appropriate button to execute. Return to main menu and reboot back into recovery. Then try to install the Nexus ROM.

2) Download an older build of TWRP from here and transfer to adb/fastboot folder on Windows. Boot device into fastboot mode and issue the following command to install:

sudo fastboot -i 0x1949 flash recovery <recovery-image>

Will check back in 5-6 hours on progress.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
First one didn't work, second one put this out:

C:\adb>sudo fastboot -i 0x1949 flash recovery signed-thor-twrp-2870.img

'sudo' is not recognized as an internal or external command,

operable program or batch file.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
Drop the sudo prefix ...
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
"

C:\adb>fastboot devices

D0FBA0A0351401GB fastboot

C:\adb>fastboot -i 0x1949 flash recovery signed-thor-twrp-2870.img

target reported max download size of 536870912 bytes

sending 'recovery' (9220 KB)...

OKAY [ 0.361s]

writing 'recovery'...

FAILED (remote: flashing not allowed for locked hw)

finished. total time: 0.424s

C:\adb>

"
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
This suggest the vulnerable bootloader was not properly installed. You will probably need to repeat the installation procedure from the point of placing the device in 'bulk' mode. Be sure to pay attention to file indexes and file identifiers that follow "if=".

[MENTION=5828306]draxie[/MENTION] - would you agree with this assessment? Poster is following this guide and using the files attached to that post.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
Thank you. Just to clarify, my mbn file was "emmc_appsboot-13.3.2.3.2_user_323001720.mbn" and my img was "thor-twrp-3.1.1-1". I input them as "emmc_appsboot-13.3.2.3.2_user_323001720.mbn" and "thor-twrp-3.1.1-1.img" respectively. So I should just restart from the bulk mode then?
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
I actually saved what I did and here it is:

C:\adb>wmic partition where index=22 get diskindex
DiskIndex
1

C:\adb>wmic partition where (index=17 and numberofblocks=20480) get diskindex
DiskIndex
1

C:\adb>wmic partition where (index=5 and numberofblocks=4096) get diskindex
DiskIndex
1

C:\adb>dd of=\\?\Device\Harddisk1\Partition6 if=emmc_appsboot-13.3.2.3.2_user_323001720.mbn
rawwrite dd for windows version 0.5.
Written by John Newbigin <jn@it.swin.edu.au>
This program is covered by the GPL. See copying.txt for details
Error reading file: 87 The parameter is incorrect
678+1 records in
678+1 records out

C:\adb>dd of=\\?\Device\Harddisk1\Partition18 if=thor-twrp-3.1.1-1.img
rawwrite dd for windows version 0.5.
Written by John Newbigin <jn@it.swin.edu.au>
This program is covered by the GPL. See copying.txt for details
18060+0 records in
18060+0 records out

C:\adb>
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
deleted
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
Alright, so I went into bulk mode again and downloaded the TWRP version you gave me and I was able to Flash the Nexus ROM.

With my older TWRP and Nexus ROM I've been repeating the processes getting new codes and trying them over and over again to no avail. How do I proceed?

Update: I tried Flashing TWRP 3.1.1.1 on top of the old version and I get the same error "Fail: flashing not allowed for locked hw." At least right now I have a working OS. I would like to get it to Nougat though so I can start customizing it and using it lol

Also, here's my screen when I try running the get_code batch "https://gyazo.com/c115ed3cafae145ce513507b37a01857" It says failed but it gives me a code. Not sure if this will be useful

Update: I wen't into bulk mode again and installed TWRP3.1.1.0 to see if that would make any difference. It didn't. I think the issue here is the get_code.bat not getting an actual unlock code but idk. After unlocking the screen, it went black once. I restarted it and it didn't happen again. Not sure if it matters. I'm probably going to sleep in a bit. I'm currently at GMT+0, and will be gone tomorrow afternoon and will return in the evening. Thank you Davey. I feel like I'm learning a bit
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
Thanks for saving/posting your prior work. Note the error message on the aboot flash. Most like due to the filename (multiple dots/periods). Please rename the file to 'aboot_vuln.mbn' and try again.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
So I went through the whole process again, renamed my .mbn and my .img to what was in the guide, went through the testing process for unlocking 2x and still nothing. https://gyazo.com/9cc0f81235fdeaf61c8ad9c40fc6166e
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
First line in screen snip suggests you did not have a working fastboot tether. Always a good idea to test connection with 'fastboot devices' before issuing any operational commands. Return to fastboot, adjust Windows drivers as needed and then try the unlock sequence again (just the unlock bat file; no need to reflash aboot). Post screen snip if operation is unsuccessful.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
https://gyazo.com/ddb61e577829d3813b45cb9341210501 I even changed the cable just in case.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
Have no immediate explaination why the batch file is failing. You may need to manually apply the unlock code using raw commands. I'm responding on the road and not in a position to offer an alternative (manual) procedure. Probably going to have to hold for 24-48 hours unless someone else responds before then.

One of the reasons I hate automation ...
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
Not a problem! I'll just make use of it for now. There's no glaring security risks for using this ROM apart from general computer risks, correct? and is this thread at all related to my situation? I was trying to figure out a manual alternative but they either require root or the batch that keeps failing.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
Wait... This ROM has SuperSU on it. Did installing this ROM root me?
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
Yes, ROM is rooted upon installation.

---------- Post added at 05:12 AM ---------- Previous post was at 05:03 AM ----------

- no glaring security risks; Fire Nexus remains is rock solid despite its age

- have you tried issuing the following command in fastboot:

fastboot -i 0x1949 flash unlock unlock.code

This assumes 1) unlock.code was properly generated by get_code and resides in the same folder as fastboot.exe; and 2) a vulnerable bootloader is installed.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] draxie:
Well, it's clear that the device is locked, but I cannot tell if it's because of the wrong bootloader,

or simply not having flashed the unlock.code...

---------- Post added at 08:03 ---------- Previous post was at 07:59 ----------

If you read my original instructions carefully, you'll find this:

This error message on the first command seems normal: "Error reading file: 87 The parameter is incorrect"

(and, the relevant command uses the renamed aboot; no idea why that error pops, though ;^))

---------- Post added at 08:14 ---------- Previous post was at 08:03 ----------

That 'FAILED (unknown status code)' message is not very encouraging.

Normally, you'd get 'Unlock code incorrect' (or correct ;^))...

The size of you 'unlock.code' file should be 256 bytes. Can you verify?
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
The unlock code is 0kb
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] draxie:
Can you show the file system listing please?

You know, something like the output of 'DIR'? (^;
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
I don't follow. Do you mean the files in the adb folder? Or do I just go to CMD and enter "DIR" as a command?
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] draxie:
Yes, open a 'CMD' window, navigate to the folder that holds your 'unlock.code' file, and enter the 'DIR' command.

Alternatively, locate said file in File Explorer and post a screenshot showing the actual size of the file.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
I won't be able to access my computer for another 7 hours or so. But when you asked for the size I made sure to look at what the file explorer said the size of the "unlock.code" file was and I'm almost certain that it said 0kb. When I get home I'll run DIR and check it again though. I can confirm that every time I ran the "Get_code.bat" I got errors but I assumed it was a part of the process because it still output an unlock code file.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] draxie:
I don't use Windows anymore, but I'm skeptical about File Explorer reporting file size as 0kb..

That's why I asked. When you get to it, can you also make sure to display the size in bytes?
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
Will do. Thanks for stopping by to help me out. I really appreciate it.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
https://gyazo.com/3692481bf94a77885fa0100b3b543e65

C:\adb>DIR

Directory of C:\adb

02/19/2018 12:43 AM <DIR> .

02/19/2018 12:43 AM <DIR> ..

10/23/2017 07:57 PM 347,456 aboot_vuln.mbn

01/11/2018 06:53 PM 1,784,320 adb.exe

01/11/2018 06:53 PM 97,792 AdbWinApi.dll

01/11/2018 06:53 PM 62,976 AdbWinUsbApi.dll

08/09/2015 01:50 PM 29,882 cmd-here.exe

02/26/2007 08:50 PM 342,016 dd.exe

01/11/2018 06:53 PM 853,504 fastboot.exe

02/04/2017 09:36 PM 318 get_code.bat

02/18/2018 05:56 PM 9,441,280 signed-thor-twrp-2870.img

02/16/2018 08:46 PM 8,978,432 thor-twrp-3.1.1-0.img

02/16/2018 09:09 PM 9,246,720 twrp_cubed.img

02/17/2018 03:29 PM 1,802 unins000.dat

02/17/2018 03:29 PM 717,985 unins000.exe

01/06/2017 06:49 PM 96 unlock.bat

02/19/2018 12:43 AM 0 unlock.code

15 File(s) 31,904,579 bytes

2 Dir(s) 308,310,306,816 bytes free

C:\adb>[/CODE]
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
Size of the file 'unclock.code' (0 bytes; effectively empty) indicates it was not successfully populated during prior run(s) of get_code.bat. While there are multiple ways to skin the cat I suggest the following:

- boot into Nexus

- verify adb bridge is enabled under settings -> developer options

- tether device; respond to any prompts (device and/or windows)

- open a Windows command prompt

- issue the following command: erase unlock.code

- validate connectivity with 'adb devices'

- run 'get_code.bat' (just type 'get_code' and press enter)

- issue the following command: dir unlock.code

- if length/size of unlock.code is 256 continue with following steps ...

- issue the following command: adb reboot bootloader

- validate connectivity with 'fastboot devices'

- issue the following command: fastboot -i 0x1949 flash unlock unlock.code

Post a screen description and/or screen snip of something fails or returns unexpected results.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
C:\adb>adb devices
List of devices attached
D0FBA0A0351401GB device

C:\adb>erase unlock.code

C:\adb>adb devices
List of devices attached
D0FBA0A0351401GB device

C:\adb>get_code.bat
adb: error: cannot stat 'cuber': No such file or directory
Unable to open /data/local/tmp/cuber: No such file or directory
0x000045 0x09c8805d
/system/bin/sh: /data/local/tmp/cuber: not found
/data/local/tmp/unlock.code: 1 file pulled.
rm failed for /data/local/tmp/cuber, No such file or directory
Press any key to continue . . .

C:\adb>dir unlock.code
Volume in drive C is OS
Volume Serial Number is B684-989C

Directory of C:\adb

02/19/2018 09:43 PM 0 unlock.code
1 File(s) 0 bytes
0 Dir(s) 308,308,631,552 bytes free

C:\adb>
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] draxie:
You're missing a file named 'cuber' that should've been part of 'unlock.zip'.

Note that 'cuber' didn't show up in the listing you posted, either...

Try to extract that file and run 'get_code' again!

You can replace the last 3 steps in the previous post

- issue the following command: adb reboot bootloader

- validate connectivity with 'fastboot devices'

- issue the following command: fastboot -i 0x1949 flash unlock unlock.code

by simply running 'unlock.bat', since that's almost exactly what that

command does (except for the '-i 0x1949', which shouldn't be necessary

on Windows).
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] hwwof:
...I can't believe that this whole time it's just been a missing file. rip me. Thank you so much. it says that the "unlock code is correct". How do I proceed from here to properly install AEX without messing my device up? Also, since the Nexus ROM had SuperSU and that means I'm rooted now, how do I work with OpenGapps and Magisk? [MENTION=297200]Davey[/MENTION]216
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
Nice work, [MENTION=5828306]draxie[/MENTION]. You are annoyingly consistent at ferreting out root (or something close to root) cause whether the 'problem' is simple or complex. :)

As you probably guessed I broke down the 'unlock.bat' file as it appeared to be failing based on screen snips shared by the poster. Completely overlooked the missing 'cuber' file ... although that only became fully apparent with the last set of snips (although there was an earlier clue as you alluded).
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] 8675Thr:
Hello. Forgive the necro, but I've repeated the exact mistake made by hwwof: not extracting the cuber file to C:/adb (the unlock guide did not say to do so, only the .bat files) and receiving an empty unlock.code file.

Additional wrinkle: I cannot seem to boot into TWRP. Holding power+volume up just boots into fastboot as normal. The person I inherited the device from did report having nonfunctional sound, so it is a possibility that the volume up button is simply shot. What (if any) are my options here?

Command prompt log:

C:\adb>adb reboot bootloader

C:\adb>fastboot -i 0x1949 erase aboot
erasing 'aboot'...
OKAY [ 0.052s]
finished. total time: 0.053s

C:\adb>fastboot -i 0x1949 reboot
rebooting...

finished. total time: 0.021s

C:\adb>wmic partition where index=22 get diskindex
DiskIndex
8

C:\adb>wmic partition where (index=17 and numberofblocks=20480) get diskindex
DiskIndex
8

C:\adb>wmic partition where (index=5 and numberofblocks=4096) get diskindex
DiskIndex
8

C:\adb>dd of=\\?\Device\Harddisk8\Partition6 if=emmc_appsboot-13.3.2.3.2_user_323001720.mbn
rawwrite dd for windows version 0.5.
Written by John Newbigin <jn@it.swin.edu.au>
This program is covered by the GPL. See copying.txt for details
Error reading file: 87 The parameter is incorrect
678+1 records in
678+1 records out

C:\adb>dd of=\\?\Device\Harddisk8\Partition18 if=thor_twrp-3.2.3-1.img
rawwrite dd for windows version 0.5.
Written by John Newbigin <jn@it.swin.edu.au>
This program is covered by the GPL. See copying.txt for details
18120+0 records in
18120+0 records out

C:\adb>unlock.bat
error: device '(null)' not found
target reported max download size of 536870912 bytes
sending 'unlock' (0 KB)...
FAILED ()
finished. total time: 0.001s
Press any key to continue . . .
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] draxie:
Another case of blind leading the sightless.... (-;

You may be able to apply pressure to the right place to revive the volume keys.

There's a thread (or two) on that somewhere. Unfortunately, I don't have a link.

If that doesn't work, you can always disassemble the device, re-seat the connector,

and put it back together.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] Chrisrokc1:
I have this same issue with one of mine, except the volume buttons do work on mine. If I hold the + it takes me to a screen with the Kindle Fire logo. If I hold the - it takes me to Fastboot. If I don't use the + OR - it takes me to Fastboot.

Should have understood the instructions better to know the unlock.code was incorrect before proceeding.

Suggestions?
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
Answered here: https://xdaforums.com/kindle-fire-h...ing-bootloader-firmware-t3463982/post78585887
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] wave_sailor:
I am at fastboot step (get_code worked and I can see the unlock file), but my device manager shows Other Devices -> ! Android. I try changing driver to Fire by letting it search, but it doesn't find anything. I tried pointing to c:\adb, but it doesn't find anything there either. I reran the driver install and that works ok, but Android doesn't change to Fire Device.

adb devices list is blank.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] irfan67670:
I have the same problem here. Tried many windows reboots, different versions of adb fastboot drivers. Kindle boots fine into fastboot and says Ready, but windows cannot use any driver for it.

HDX7 3rd Gen
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
Use drivers included with Motorola Device Manager 2.5.x; my goto for many years. Don't need to do anything with the manager itself; just install to get the drivers.

That said, not an instant panacea for all. Windows is a finiky platform; you'll have to experiment and read to find the elixure that works for you.

Don't asks for download link or other help; I moved on from this device. My 7 years of posts have all the details. Good luck.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] exokinetic:
Well the instructions that everyone STILL point to for the procedure have not been edited to reflect the fact that cuber needs to be copied into the c:\adb\ folder

I have fallen into the same trap as hwwof (and TheZenGuy), except that I can not boot into twrp for some reason, and the links in this thread for the older version of twrp for flashing the Nexus ROM that will work with a locked bootloader are no longer alive.

I mean, its not like all the college kids are screaming for unlocked Kindle Fires...

But, still, all searches for "unlock kindle fire hdx 8.9" sinkhole into THIS set of instructions.

And that set of instructions contains a fatal flaw with regards to the placement of Cuber.

ANYONE who follows those instructions explicitly will get stuck right here.

I am not exactly blind, or sightless. The fact is the instructions explicitly suggest cuber should NOT be moved into the c:\adb\ folder.

I realize it should have been a glaring red flag to see:

c:\adb>get_code

cannot stat 'cuber': No such file or directory

Unable to open /data/local/tmp/cuber: No such file or directory

0x000045 0x251b3b67

/system/bin/sh: /data/local/tmp/cuber: not found

rm failed for /data/local/tmp/cuber, No such file or directory

Press any key to continue . . .

But, even though it fails, it still generates unlock.code (albiet as an empty file) implying that the operation completed as intended.

If anyone has any idea for where I am currently stuck, I would seriously appreciate any insight anyone else can provide!

If a moderator is willing to edit the post with the instructions, I would be happy to ammend the text for an easy copy/ paste update.

I really dont want to sound like I am complaining or pointing any fingers, but it would be nice to get this error updated in the instructions everyone links too.

/Exo
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] exokinetic:
There is no doubt you have put in the work, and we all owe you and those who worked on this a debt of grattitude.

But the Nexus ROM used for saving yourself from soft brickage (caused by inadequate instructions) IS dead linked.

So like *scratches cheek* you got any o' those doooooooooooownload links?

;)

/Exo
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] DB126:
I discarded any/all HDX related content a few years back. Great device in her day and well beyond. Those days have passed. It's unfortune XDA links were not sticky. That said, content owners and providers have their reasons for pulling content.

Sorry I couldn't help.
[Kindle Fire HDX 7" & 8.9" Q&A, Help & Troubleshoot] exokinetic:
No worries, friend!

Draxie has been given me some solid assistance, I am confident I will get this baby flashed up in no time ;)

I am going to make another post with my progress, and thanks for the tip on the Motorola drivers from the Motorola Device Manager 2.5.~

If I get up the motivation I will make a new post with the required cuber correction to the instructions copy/pasta.

I have interesting functionality with the fire device drivers;

When loggen into the OS, adb sees the fine perfectly, everything works as expected.

But, in the bootloader, adb devies, and fastboot devices with both yield an empty return, as in, no devices seen?

But if I do SOME commands from the bootloader, like for instance, a simple reboot, the device will reboot faithfully.

All of the code from the instructions seemed to fire off properly, I have TWRP 3.1.1.1 flashed and bootable, but, regardless, adb/fastboot 'devices' acts like it doesnt see the device.

Going to try those specific motorola drivers...

Thanks for all of your efforts!

/Exo