Forked from TobiasWooldridge/gist:22f0cdca75190b9a473f
Last active
February 20, 2024 15:02
-
-
Save brianpow/d19f98ddef5cf7ad504a632b5abfe213 to your computer and use it in GitHub Desktop.
Revisions
-
brianpow revised this gist
Jun 21, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -70,7 +70,7 @@ Instead, we'll just mangle the diagnostic image to 'dd' the file after it's done ``` 5. Now when we flash pw_5.2.0-mmcblk0p2.img, it'll automatically check the userstore directory for a file named 'mmcblk0p1.img' and flash it to the system partition # Procedure 1. Pry open Kindle using a prying tool (*The cover is just sticked with double-side adhesive tape, without any snap-in joint) 2. Unscrew the screen and remove it from the base. (*Note that there's a screw hidden under the adhesive at the top in the middle) 3. Solder tin wire to serial ports on the bottom -
brianpow revised this gist
Jun 21, 2016 . 1 changed file with 8 additions and 8 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,31 +2,31 @@ This guide instructs you in how to unbrick an Amazon Kindle Paperwhite. The consequences of following it are your own responsibility. This method (opening the Kindle and using the serial interface) should be a last resort and should only be considered if other methods fail # Prerequisite ## Hardware * Prying tool * Screw driver * USB to serial cable (1.8V the best, other not tried and may fried your kindle) * USB to micro USB cable ## Software * Putty/Kitty/Pietty * [Fastboot-Kindle](https://github.com/brianpow/Fastboot-Kindle) (Pre-compiled binary for Linux and Windows available, for Mac OSX User, please download and build from the source) ## Firmware * Download [Paperwhite Image](http://ixtab.tk/kindle-touch-images/PaperWhite/), unpack and modify as shown ```bash wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-diags_kernel.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-main_kernel.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-mmcblk0p1.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-mmcblk0p2.img.gz gunzip pw_5.2.0-*.img.gz ``` ### How to modify pw_5.2.0-mmcblk0p2 to automatically dd pw_5.2.0-mmcblk0p1 to the system partition #### Why Unfortunately pw_5.2.0-mmcblk0p1 is too big for fastboot (or, fastboot doesn't like it for some reason). This causes us a little bit of grief because we need to use some other means to get it onto our kindle @@ -35,7 +35,7 @@ We'd usually use the 'dd' tool on the kindle over ssh to copy this file to its r Instead, we'll just mangle the diagnostic image to 'dd' the file after it's done initializing filesystems. #### Procedure 1. Back up then mount the diagnostics image to some directory -
brianpow revised this gist
Jun 21, 2016 . 1 changed file with 66 additions and 70 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,18 +1,20 @@ # How to unbrick an Amazon Kindle Paperwhite? This guide instructs you in how to unbrick an Amazon Kindle Paperwhite. The consequences of following it are your own responsibility. This method (opening the Kindle and using the serial interface) should be a last resort and should only be considered if other methods fail # Prerequisite # ## Hardware ## * Prying tool * Screw driver * USB to serial cable (1.8V the best, other not tried and may fried your kindle) * USB to micro USB cable ## Software ## * Putty/Kitty/Pietty * [Fastboot-Kindle](https://github.com/brianpow/Fastboot-Kindle) (Pre-compiled binary for Linux and Windows available, for Mac OSX User, please download and build from the source) ## Firmware ## * Download [Paperwhite Image](http://ixtab.tk/kindle-touch-images/PaperWhite/), unpack and modify as shown ``` wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-diags_kernel.img.gz @@ -22,57 +24,9 @@ This guide instructs you in how to unbrick an Amazon Kindle Paperwhite. The cons gunzip pw_5.2.0-*.img.gz ``` # How to modify pw_5.2.0-mmcblk0p2 to automatically dd pw_5.2.0-mmcblk0p1 to the system partition ## Why ## Unfortunately pw_5.2.0-mmcblk0p1 is too big for fastboot (or, fastboot doesn't like it for some reason). This causes us a little bit of grief because we need to use some other means to get it onto our kindle @@ -81,19 +35,19 @@ We'd usually use the 'dd' tool on the kindle over ssh to copy this file to its r Instead, we'll just mangle the diagnostic image to 'dd' the file after it's done initializing filesystems. ## Procedure ## 1. Back up then mount the diagnostics image to some directory ```bash cp pw_5.2.0-mmcblk0p2.img pw_5.2.0-mmcblk0p2.img.bak mkdir mmcblk0p2 mount -t ext3 pw_5.2.0-mmcblk0p2.img mmcblk0p2/ ``` 2. Open its /etc/upstart/diags file (the diagnostics boot script) ```bash vim mmcblk0p2/etc/upstart/diags ``` @@ -111,12 +65,54 @@ To do this, 4. Unmount mmcblk0p2 ```bash umount mmcblk0p2/ ``` 5. Now when we flash pw_5.2.0-mmcblk0p2.img, it'll automatically check the userstore directory for a file named 'mmcblk0p1.img' and flash it to the system partition # Procedure # 1. Pry open Kindle using a prying tool (*The cover is just sticked with double-side adhesive tape, without any snap-in joint) 2. Unscrew the screen and remove it from the base. (*Note that there's a screw hidden under the adhesive at the top in the middle) 3. Solder tin wire to serial ports on the bottom 4. Attach tin wire to USB TTY device (order is ground, RX, TX, from the kindle's perspective, where GND is the smallest pad) and plug USB TTY device into your computer 5. Open Putty/Kitty/Pietty on your computer in serial mode, with the serial port specified as your USB device and baud configured to 115200 6. Reboot kindle 7. When the kindle is booting, repeatedly pressed `enter` on your computer's keyboard 8. Now that we're in the bootloader, run `bist fastboot` to put your Kindle into fastboot mode and run `fastboot` 9. Connect the micro USB port of the Kindle Paperwhite to your computer by USB 10. On your computer, open your terminal/commmand prompt, run `./fastboot` (Be careful not to run `fastboot`, as that may use an installed Android fastboot binary). This will list the paritions on your Kindle Paperwhite 11. Run the following commands under your terminal/commmand prompt ```bash ./fastboot flash system pw_5.2.0-mmcblk0p1.img ./fastboot flash kernel pw_5.2.0-main_kernel.img ./fastboot flash diags pw_5.2.0-mmcblk0p2.img ``` to flash all of our images to the Kindle Paperwhite EXCEPT for the main system image 12. Run the following under your terminal/commmand prompt to reboot your Kindle and get into Diags mode ```bash ./fastboot setvar bootmode diags ./fastboot reboot ``` 13. Once your kindle's booted to diags mode, start USB mode 14. Rename pw_5.2.0-mmcblk0p1.img to mmcblk0p1.img and copy it to your kindle 15. Safely unmount your kindle 16. Reboot your kindle into diagnostics mode again from the "Exit, Reboot or Disable Diags" menu 17. If you're watching your Kindle's serial output as it boots, you should see something like ``` /dev/loop/0: 84 files, 44940/174079 clusters info filesystems:installdata:KINDLEFIX looking for /mnt/us/mmcblk0p1.img ...: info filesystems:installdata:KINDLEFIX found mmcblk0p1.img, trying to install:I ``` 19. This indicates that it's flashing the system partition. It will take a while, during which the Kindle will only show the Amazon Kindle screen 20. Once diags mode has booted, open "Exit, Reboot or Disable Diags", hit disable diagnostics, then hit continue. This will reboot your kindle. 21. Hooray! Your kindle is now unbricked. 22. Optionally delete the mmcblk0p1.img on your Kindle over USB. If you leave it there, every time the diags tool is run, it'll flash it to the system partition. -
TobiasWooldridge revised this gist
Sep 17, 2014 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -9,8 +9,8 @@ This guide instructs you in how to unbrick an Amazon Kindle Paperwhite. The cons 2. Attach tin wire to USB TTY device (order is ground, RX, TX, from the kindle's perspective, where GND is the smallest pad) and plug USB TTY device into your computer 3. Open Putty on your computer in serial mode, with the serial port specified as your USB device and baud configured to 115200 3. Reboot kindle 4. When the kindle is booting, there exists a brief window where sending data to it over the serial line will cause it to enter it's bootloader. To achieved this I repeatedly pressed enter on my computer's keyboard as my kindle started booting 5. Now that we're in the bootloader, run 'bist fastboot' to put your Kindle into fastboot mode 6. On a Mac, build https://github.com/TobiasWooldridge/Fastboot-Kindle -- if you get this building on anything else, please send me a pull request :) 7. Download Paperwhite images from http://ixtab.tk/kindle-touch-images/PaperWhite/ -
TobiasWooldridge revised this gist
Sep 17, 2014 . 1 changed file with 4 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,11 +6,12 @@ This guide instructs you in how to unbrick an Amazon Kindle Paperwhite. The cons 0. Pry open Kindle using a prying tool 1. Unscrew the screen and remove it from the base. Note that there's a screw hidden under the adhesive at the top in the middle 1. Solder tin wire to serial ports on the bottom 2. Attach tin wire to USB TTY device (order is ground, RX, TX, from the kindle's perspective, where GND is the smallest pad) and plug USB TTY device into your computer 3. Open Putty on your computer in serial mode, with the serial port specified as your USB device and baud configured to 115200 3. Reboot kindle 4. When the kindle is booting, it'll have a brief window where sending data down the serial line will cause it to enter it's bootloader. To achieved this I repeatedly pressed enter on my computer's keyboard as my kindle started booting get to bootloader 5. Run 'bist fastboot' to put your Kindle into fastboot mode 6. On a Mac, build https://github.com/TobiasWooldridge/Fastboot-Kindle -- if you get this building on anything else, please send me a pull request :) 7. Download Paperwhite images from http://ixtab.tk/kindle-touch-images/PaperWhite/ ``` -
TobiasWooldridge revised this gist
Sep 7, 2014 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -118,4 +118,4 @@ To do this, ## Misc If you find this useful or find an error, feel welcome to leave a comment below or email [email protected] - thanks! -
TobiasWooldridge revised this gist
Sep 7, 2014 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,6 +1,6 @@ # How to unbrick an Amazon Kindle Paperwhite™ This guide instructs you in how to unbrick an Amazon Kindle Paperwhite. The consequences of following it are your own responsibility. This method (opening the Kindle and using the serial interface) should be a last resort and should only be considered if other methods fail ## The Guide 0. Pry open Kindle using a prying tool -
TobiasWooldridge revised this gist
Sep 7, 2014 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,5 +1,8 @@ # How to unbrick an Amazon Kindle Paperwhite™ This guide instructs you in how to unbrick an Amazon Kindle Paperwhite. It is your responsibility what you do with it. This method (opening the Kindle and using the serial interface) should be a last resort and should only be considered if other methods fail ## The Guide 0. Pry open Kindle using a prying tool 1. Unscrew the screen and remove it from the base. Note that there's a screw hidden under the adhesive at the top in the middle 1. Solder tin wire to serial ports on the bottom -
TobiasWooldridge revised this gist
Sep 7, 2014 . 1 changed file with 4 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -112,3 +112,7 @@ To do this, ``` 5. Now when we flash pw_5.2.0-mmcblk0p2.img, it'll automatically check the userstore directory for a file named 'mmcblk0p1.img' and flash it to the system partition ## Misc If you find this useful or find an error, feel welcome to email [email protected] - thanks! -
TobiasWooldridge revised this gist
Sep 2, 2014 . 1 changed file with 47 additions and 41 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -10,33 +10,35 @@ 6. On your Mac, build https://github.com/TobiasWooldridge/Fastboot-Kindle 7. Download Paperwhite images from http://ixtab.tk/kindle-touch-images/PaperWhite/ ``` wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-diags_kernel.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-main_kernel.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-mmcblk0p1.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-mmcblk0p2.img.gz gunzip pw_5.2.0-*.img.gz ``` 8. *Modify the pw_5.2.0-mmcblk0p2.img on something which can mount ext3 using the guide below* 9. In bist, run 'fastboot' (if it isn't running already) 10. Make sure Kindle Paperwhite is plugged in to your Mac by USB as well 11. On your Mac, run `./fastboot` (Be careful not to run `fastboot`, as that may use an installed Android fastboot binary). This will list the paritions on your Kindle Paperwhite 12. We want to overwrite diags_kernel, main_kernel, system and diags 13. We now want to run ``` ./fastboot flash system pw_5.2.0-mmcblk0p1.img ./fastboot flash kernel pw_5.2.0-main_kernel.img ./fastboot flash diags pw_5.2.0-mmcblk0p2.img ``` to flash all of our images to the Kindle Paperwhite EXCEPT for the main system image 13. Run the following to reboot your Kindle and get into Diags mode ``` ./fastboot setvar bootmode diags ./fastboot reboot ``` 14. Once your kindle's booted to diags mode, start USB mode @@ -47,11 +49,12 @@ 17. Reboot your kindle into diagnostics mode again from the "Exit, Reboot or Disable Diags" menu 18. If you're watching your Kindle's serial output as it boots, you should see something like ``` /dev/loop/0: 84 files, 44940/174079 clusters info filesystems:installdata:KINDLEFIX looking for /mnt/us/mmcblk0p1.img ...: info filesystems:installdata:KINDLEFIX found mmcblk0p1.img, trying to install:I ``` 19. This indicates that it's flashing the system partition. It will take a while, during which the Kindle will only show the Amazon Kindle screen @@ -77,32 +80,35 @@ Instead, we'll just mangle the diagnostic image to 'dd' the file after it's done To do this, 1. Back up then mount the diagnostic image to some directory ``` cp pw_5.2.0-mmcblk0p2.img pw_5.2.0-mmcblk0p2.img.bak mkdir mmcblk0p2 root@debian:~# mount -t ext3 pw_5.2.0-mmcblk0p2.img mmcblk0p2/ ``` 2. Open its /etc/upstart/diags file (the diagnostics boot script) ``` vim mmcblk0p2/etc/upstart/diags ``` 3. At the end of init_filesystems function, before the "#end script" comment, add ```bash # INSTALL MAIN PARTITION FROM USERSTORE f_log I filesystems installdata "KINDLEFIX looking for /mnt/us/mmcblk0p1.img ..." if [ -e /mnt/us/mmcblk0p1.img ] ; then f_log I filesystems installdata "KINDLEFIX found mmcblk0p1.img, trying to install" I dd if=/mnt/us/mmcblk0p1.img of=/dev/mmcblk0p1 bs=4K f_log I filesystems installdata "KINDLEFIX Install successful" I fi ``` 4. Unmount mmcblk0p2 ``` umount mmcblk0p2/ ``` 5. Now when we flash pw_5.2.0-mmcblk0p2.img, it'll automatically check the userstore directory for a file named 'mmcblk0p1.img' and flash it to the system partition -
TobiasWooldridge revised this gist
Sep 2, 2014 . 1 changed file with 17 additions and 24 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -10,35 +10,33 @@ 6. On your Mac, build https://github.com/TobiasWooldridge/Fastboot-Kindle 7. Download Paperwhite images from http://ixtab.tk/kindle-touch-images/PaperWhite/ ``` wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-diags_kernel.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-main_kernel.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-mmcblk0p1.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-mmcblk0p2.img.gz gunzip pw_5.2.0-*.img.gz ``` 8. *Modify the pw_5.2.0-mmcblk0p2.img on something which can mount ext3 using the guide below* 9. In bist, run 'fastboot' (if it isn't running already) 10. Make sure Kindle Paperwhite is plugged in to your Mac by USB as well 11. On your Mac, run `./fastboot` (Be careful not to run `fastboot`, as that may use an installed Android fastboot binary). This will list the paritions on your Kindle Paperwhite 12. We want to overwrite diags_kernel, main_kernel, system and diags 13. We now want to run ``` ./fastboot flash system pw_5.2.0-mmcblk0p1.img ./fastboot flash kernel pw_5.2.0-main_kernel.img ./fastboot flash diags pw_5.2.0-mmcblk0p2.img ``` to flash all of our images to the Kindle Paperwhite EXCEPT for the main system image 13. Run the following to reboot your Kindle and get into Diags mode ``` ./fastboot setvar bootmode diags ./fastboot reboot ``` 14. Once your kindle's booted to diags mode, start USB mode @@ -49,10 +47,11 @@ 17. Reboot your kindle into diagnostics mode again from the "Exit, Reboot or Disable Diags" menu 18. If you're watching your Kindle's serial output as it boots, you should see something like ``` /dev/loop/0: 84 files, 44940/174079 clusters info filesystems:installdata:KINDLEFIX looking for /mnt/us/mmcblk0p1.img ...: info filesystems:installdata:KINDLEFIX found mmcblk0p1.img, trying to install:I ``` 19. This indicates that it's flashing the system partition. It will take a while, during which the Kindle will only show the Amazon Kindle screen @@ -78,38 +77,32 @@ Instead, we'll just mangle the diagnostic image to 'dd' the file after it's done To do this, 1. Back up then mount the diagnostic image to some directory ``` cp pw_5.2.0-mmcblk0p2.img pw_5.2.0-mmcblk0p2.img.bak mkdir mmcblk0p2 root@debian:~# mount -t ext3 pw_5.2.0-mmcblk0p2.img mmcblk0p2/ ``` 2. Open its /etc/upstart/diags file (the diagnostics boot script) ``` vim mmcblk0p2/etc/upstart/diags ``` 3. At the end of init_filesystems function, before the "#end script" comment, add ```bash # INSTALL MAIN PARTITION FROM USERSTORE f_log I filesystems installdata "KINDLEFIX looking for /mnt/us/mmcblk0p1.img ..." if [ -e /mnt/us/mmcblk0p1.img ] ; then f_log I filesystems installdata "KINDLEFIX found mmcblk0p1.img, trying to install" I dd if=/mnt/us/mmcblk0p1.img of=/dev/mmcblk0p1 bs=4K f_log I filesystems installdata "KINDLEFIX Install successful" I fi ``` 4. Unmount mmcblk0p2 ``` umount mmcblk0p2/ ``` 5. Now when we flash pw_5.2.0-mmcblk0p2.img, it'll automatically check the userstore directory for a file named 'mmcblk0p1.img' and flash it to the system partition -
TobiasWooldridge revised this gist
Sep 2, 2014 . 1 changed file with 92 additions and 15 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,38 +1,115 @@ # How to unbrick an Amazon Kindle Paperwhite™ 0. Pry open Kindle using a prying tool 1. Unscrew the screen and remove it from the base. Note that there's a screw hidden under the adhesive at the top in the middle 1. Solder tin wire to serial ports on the bottom 2. Attach tin wire to USB TTY device (order is ground, RX, TX, from the kindle's perspective, where GND is the smallest pad) 3. Reboot kindle 4. When the kindle is booting, immediately mash enter to get to bootloader 5. Run 'bist fastboot' to put your Kindle into fastboot mode 6. On your Mac, build https://github.com/TobiasWooldridge/Fastboot-Kindle 7. Download Paperwhite images from http://ixtab.tk/kindle-touch-images/PaperWhite/ wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-diags_kernel.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-main_kernel.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-mmcblk0p1.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-mmcblk0p2.img.gz gunzip pw_5.2.0-*.img.gz 8. *Modify the pw_5.2.0-mmcblk0p2.img on something which can mount ext3 using the guide below* 9. In bist, run 'fastboot' (if it isn't running already) 10. Make sure Kindle Paperwhite is plugged in to your Mac by USB as well 11. On your Mac, run `./fastboot` (Be careful not to run `fastboot`, as that may use an installed Android fastboot binary). This will list the paritions on your Kindle Paperwhite 12. We want to overwrite diags_kernel, main_kernel, system and diags 13. We now want to run ./fastboot flash system pw_5.2.0-mmcblk0p1.img ./fastboot flash kernel pw_5.2.0-main_kernel.img ./fastboot flash diags pw_5.2.0-mmcblk0p2.img to flash all of our images to the Kindle Paperwhite EXCEPT for the main system image 13. Run the following to reboot your Kindle and get into Diags mode ./fastboot setvar bootmode diags ./fastboot reboot 14. Once your kindle's booted to diags mode, start USB mode 15. Rename pw_5.2.0-mmcblk0p1.img to mmcblk0p1.img and copy it to your kindle 16. Safely unmount your kindle 17. Reboot your kindle into diagnostics mode again from the "Exit, Reboot or Disable Diags" menu 18. If you're watching your Kindle's serial output as it boots, you should see something like /dev/loop/0: 84 files, 44940/174079 clusters info filesystems:installdata:KINDLEFIX looking for /mnt/us/mmcblk0p1.img ...: info filesystems:installdata:KINDLEFIX found mmcblk0p1.img, trying to install:I 19. This indicates that it's flashing the system partition. It will take a while, during which the Kindle will only show the Amazon Kindle screen 20. Once diags mode has booted, open "Exit, Reboot or Disable Diags", hit disable diagnostics, then hit continue. This will reboot your kindle. 21. Hooray! Your kindle is now unbricked. 22. Optionally delete the mmcblk0p1.img on your Kindle over USB. If you leave it there, every time the diags tool is run, it'll flash it to the system partition. ## How to modify pw_5.2.0-mmcblk0p2 to automatically dd pw_5.2.0-mmcblk0p1 to the system partition Unfortunately pw_5.2.0-mmcblk0p1 is too big for fastboot (or, fastboot doesn't like it for some reason). This causes us a little bit of grief because we need to use some other means to get it onto our kindle We'd usually use the 'dd' tool on the kindle over ssh to copy this file to its respective partition; however, Amazon has removed the diagnostic partition's ssh application, so we can't use that to copy the file to the kindle and dd it. Instead, we'll just mangle the diagnostic image to 'dd' the file after it's done initializing filesystems. To do this, 1. Back up then mount the diagnostic image to some directory cp pw_5.2.0-mmcblk0p2.img pw_5.2.0-mmcblk0p2.img.bak mkdir mmcblk0p2 root@debian:~# mount -t ext3 pw_5.2.0-mmcblk0p2.img mmcblk0p2/ 2. Open its /etc/upstart/diags file (the diagnostics boot script) vim mmcblk0p2/etc/upstart/diags 3. At the end of init_filesystems function, before the "#end script" comment, add # INSTALL MAIN PARTITION FROM USERSTORE f_log I filesystems installdata "KINDLEFIX looking for /mnt/us/mmcblk0p1.img ..." if [ -e /mnt/us/mmcblk0p1.img ] ; then f_log I filesystems installdata "KINDLEFIX found mmcblk0p1.img, trying to install" I dd if=/mnt/us/mmcblk0p1.img of=/dev/mmcblk0p1 bs=4K f_log I filesystems installdata "KINDLEFIX Install successful" I fi 4. Unmount mmcblk0p2 umount mmcblk0p2/ 5. Now when we flash pw_5.2.0-mmcblk0p2.img, it'll automatically check the userstore directory for a file named 'mmcblk0p1.img' and flash it to the system partition -
TobiasWooldridge created this gist
Aug 28, 2014 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,38 @@ # How to unbrick an Amazon Kindle Paperwhite™ 1. Solder tin wire to serial ports 2. Attach tin wire to USB TTY device 3. Reboot kindle 4. When the kindle is booting, immediately mash enter to get to bootloader 5. Run 'bist fastboot' to put your Kindle into fastboot mode 6. On your Mac, build https://github.com/TobiasWooldridge/Fastboot-Kindle 7. Download Paperwhite images from http://ixtab.tk/kindle-touch-images/PaperWhite/ wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-diags_kernel.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-main_kernel.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-mmcblk0p1.img.gz wget http://ixtab.tk/kindle-touch-images/PaperWhite/pw_5.2.0-mmcblk0p2.img.gz gunzip pw_5.2.0-*.img.gz 8. In bist, run 'fastboot' (if it isn't running already) 9. Make sure Kindle Paperwhite is plugged in to your Mac by USB as well 10. On your Mac, run `./fastboot` (Be careful not to run `fastboot`, as that may use an installed Android fastboot binary). This will list the paritions on your Kindle Paperwhite 11. We want to overwrite diags_kernel, main_kernel, system and diags 12. We now want to run ./fastboot flash system pw_5.2.0-mmcblk0p1.img ./fastboot flash kernel pw_5.2.0-main_kernel.img ./fastboot flash diags pw_5.2.0-mmcblk0p2.img ./fastboot flash diags_kernel pw_5.2.0-diags_kernel.img to flash all of our images to the Kindle Paperwhite 13. Run the following to reboot your Kindle ./fastboot reboot ## Errors you might get ### <waiting for device> Check that you're running ./fastboot (the fastboot binary we built) and not some system-installed fastboot binary