Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Readers > Amazon Kindle > Kindle Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 02-27-2013, 05:38 PM   #1
lporter
Member
lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.
 
Posts: 19
Karma: 36674
Join Date: Jan 2013
Device: Kindle Paperwhite
Compiling U-Boot Problem

In an attempt to fix my completely wiped (serial, board ID and all) Paperwhite, I am trying to modify amazon's u-boot source to have the RAM initialisation hardcoded.

However, I am running into issues. While I can get u-boot to compile easily, whenever I try to actually load the u-boot.bin file, I get errors. With mfgtool, I get a "The handle is invalid., Error code:6"" error. When I try to use imx_usb_loader, it tells me:

Spoiler:
Code:
parse mx50_usb_work.conf
15a2:0052(KindleTouch) bConfigurationValue =1
Interface 0 claimed
report 1, wrote 16 bytes, err=0
report 3, read 4 bytes, err=0
read=56 78 78 56
u-boot.bin

unknown load address
report 1, wrote 16 bytes, err=0
report 3, read 4 bytes, err=0
read=56 78 78 56


Other, pre-compiled u-boots work perfectly. I assume I have made some sort of silly error that has caused a load address to be omitted in the header of the file.

Could anyone point me in the right direction?
lporter is offline   Reply With Quote
Old 02-28-2013, 06:24 AM   #2
dsmid
Linux devotee
dsmid ought to be getting tired of karma fortunes by now.dsmid ought to be getting tired of karma fortunes by now.dsmid ought to be getting tired of karma fortunes by now.dsmid ought to be getting tired of karma fortunes by now.dsmid ought to be getting tired of karma fortunes by now.dsmid ought to be getting tired of karma fortunes by now.dsmid ought to be getting tired of karma fortunes by now.dsmid ought to be getting tired of karma fortunes by now.dsmid ought to be getting tired of karma fortunes by now.dsmid ought to be getting tired of karma fortunes by now.dsmid ought to be getting tired of karma fortunes by now.
 
dsmid's Avatar
 
Posts: 552
Karma: 2053595
Join Date: Feb 2011
Device: Kindle 3, Kindle 4B, Kindle PW2
Do I understand it right that you are trying to add magic-key-less USB downloader mode support to u-boot ?
That would be a nice addition to the rescue pack...

I think you would increase the chance to get an advice by posting a diff between working and non-working code. Complete source code would be even more helpful.
dsmid is offline   Reply With Quote
 
Enthusiast
Old 02-28-2013, 06:24 PM   #3
lporter
Member
lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.
 
Posts: 19
Karma: 36674
Join Date: Jan 2013
Device: Kindle Paperwhite
Not quite. When the kindle boots, it uses the board ID to work out what model it is and as such initialise the RAM in the appropriate manner for that board. When one totally wipes a kindle, it removes that information which prevents it from booting.

I want to bypass the detection routine and so remove the need for the board ID.

That being said, the modification you suggested is something I would gladly work on once I get my kindle running again!


However, my issue is that I can't get any u-boot.bin file that I have compiled on my system to boot, even one that was produced from amazon's unmodified source code.

I have tried on multiple machines on multiple os'es, so I assume I am missing something here.
lporter is offline   Reply With Quote
Old 02-28-2013, 06:37 PM   #4
knc1
Embedded Cheerleader
knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.
 
knc1's Avatar
 
Posts: 6,220
Karma: 5830430
Join Date: Feb 2012
Device: Too many.
Quote:
Originally Posted by lporter View Post
Not quite. When the kindle boots, it uses the board ID to work out what model it is and as such initialise the RAM in the appropriate manner for that board. When one totally wipes a kindle, it removes that information which prevents it from booting.

I want to bypass the detection routine and so remove the need for the board ID.

That being said, the modification you suggested is something I would gladly work on once I get my kindle running again!


However, my issue is that I can't get any u-boot.bin file that I have compiled on my system to boot, even one that was produced from amazon's unmodified source code.

I have tried on multiple machines on multiple os'es, so I assume I am missing something here.
Have you tried eureka's u-boot?
knc1 is offline   Reply With Quote
Old 02-28-2013, 06:55 PM   #5
eureka
but forgot what it's like
eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.
 
Posts: 710
Karma: 2290994
Join Date: Dec 2011
Location: north (by northwest)
Device: Kindle Touch
http://www.mobileread.com/forums/sho...ghlight=code:6
eureka is offline   Reply With Quote
Old 02-28-2013, 07:41 PM   #6
lporter
Member
lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.
 
Posts: 19
Karma: 36674
Join Date: Jan 2013
Device: Kindle Paperwhite
I've tried charging the battery for 24 hours - I don't think this is a battery issue. Bear in mind that u-boots that I have not compiled work perfectly.


EDIT: Just worked out that his u-boot is the one that auto-enters fastboot. Yeah, I have tried that. Bizarrely, no computer I have tried it with recognises a fastboot device or in fact any device at all when I use that.

I can't seem to find eureka's u-boot. Mind pointing me in the right direction? Also, while his u-boot might enable me to fix my kindle, I would still love to know if you have any ideas with regards to what on earth is wrong with my build environment!

Last edited by lporter; 02-28-2013 at 07:43 PM.
lporter is offline   Reply With Quote
Old 02-28-2013, 07:51 PM   #7
eureka
but forgot what it's like
eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.
 
Posts: 710
Karma: 2290994
Join Date: Dec 2011
Location: north (by northwest)
Device: Kindle Touch
Quote:
Originally Posted by lporter View Post
Bear in mind that u-boots that I have not compiled work perfectly.
Yep, sorry, diidn't notice that.

Quote:
Originally Posted by lporter View Post
EDIT: Just worked out that his u-boot is the one that auto-enters fastboot. Yeah, I have tried that. Bizarrely, no computer I have tried it with recognises a fastboot device or in fact any device at all when I use that.

I can't seem to find eureka's u-boot. Mind pointing me in the right direction?
You've just mentioned it, so you've certainly found it. But here is canonical source. It's also mentioned in top post of Simple Debricking thread.
eureka is offline   Reply With Quote
Old 02-28-2013, 10:06 PM   #8
eureka
but forgot what it's like
eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.
 
Posts: 710
Karma: 2290994
Join Date: Dec 2011
Location: north (by northwest)
Device: Kindle Touch
Are you using this recipe to build U-Boot?
eureka is offline   Reply With Quote
Old 03-01-2013, 10:50 AM   #9
hawhill
Wizard
hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.
 
hawhill's Avatar
 
Posts: 1,083
Karma: 2114647
Join Date: Nov 2010
Location: Goettingen, Germany
Device: Kindle Paperwhite, Kobo Mini
lporter: The original message in the <spoiler> part suggests that your binary is in a format that imx_usb_loader doesn't understand correctly. At least it looks as if it is an imx_usb_loader error, not an error reported by the unit.

I'm still scratching my head - probably I missed important bits of communication here in the board: How do you (or anyone else) bring a KPW into USB downloader mode? Or does that happen automatically because the flash/MMC is fully erased? It seems to be in USB downloader mode, the return codes reported by imx_usb_loader indicate this.
hawhill is offline   Reply With Quote
Old 03-01-2013, 01:15 PM   #10
lporter
Member
lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.
 
Posts: 19
Karma: 36674
Join Date: Jan 2013
Device: Kindle Paperwhite
Okay, so I got the compiler to work by including
Code:
TYPE=prod
to the make command. I didn't realise it needed this as it wasn't mentioned in the readme!

With a working u-boot, I made up a fake pcbsn so that the device would boot properly and set the idme variable accordingly.

Bizarrely, loading a stock u-boot.bin to my paperwhite then allowed me to use eureka's fastboot u-boot. I then tried to reflash the diags partition using the command:
Code:
>fastboot flash diags pw_5.2.0-mmcblk0p2.img
, which appeared to be successful on the fastboot end, but the serial terminal shows this error repeatedly:

Code:
ERROR : [fsl_arc_udc.c] udc_irq:1127: Packet sys err

Any idea what's going on here?
lporter is offline   Reply With Quote
Old 03-01-2013, 01:36 PM   #11
eureka
but forgot what it's like
eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.
 
Posts: 710
Karma: 2290994
Join Date: Dec 2011
Location: north (by northwest)
Device: Kindle Touch
If you have serial access and proper booting with stock U-Boot pre-flashed on device, then you can use fastboot mode included in pre-flashed U-Boot: don't use custom U-Boots, just reboot PW and execute bist fastboot in U-Boot console.
eureka is offline   Reply With Quote
Old 03-01-2013, 01:37 PM   #12
geekmaster
Всё гениальное просто.
geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.
 
geekmaster's Avatar
 
Posts: 5,066
Karma: 6789001
Join Date: Nov 2011
Location: Щедрость не имеет пределов.
Device: *.*
Quote:
Originally Posted by lporter View Post
In an attempt to fix my completely wiped (serial, board ID and all) Paperwhite, I am trying to modify amazon's u-boot source to have the RAM initialisation hardcoded.

However, I am running into issues. While I can get u-boot to compile easily, whenever I try to actually load the u-boot.bin file, I get errors. With mfgtool, I get a "The handle is invalid., Error code:6"" error. When I try to use imx_usb_loader, it tells me:

Spoiler:
Code:
parse mx50_usb_work.conf
15a2:0052(KindleTouch) bConfigurationValue =1
Interface 0 claimed
report 1, wrote 16 bytes, err=0
report 3, read 4 bytes, err=0
read=56 78 78 56
u-boot.bin

unknown load address
report 1, wrote 16 bytes, err=0
report 3, read 4 bytes, err=0
read=56 78 78 56


Other, pre-compiled u-boots work perfectly. I assume I have made some sort of silly error that has caused a load address to be omitted in the header of the file.

Could anyone point me in the right direction?
I hardcoded my PCBSN and SERIAL with a custom u-boot, to debrick a K4 with corrupted idme vars. Somebody else here, with my guidance.

For compiling tips, check out some of the early links in the simple debricking sticky thread (with links to posts from yifanlu and eureka, I think) that suggests what flags to set when compiling u-boot.

EDIT: Ahh... Nevermind! I see after reading more posts in this thread that eureka already provided a link to such information. Sorry!
geekmaster is offline   Reply With Quote
Old 03-01-2013, 02:00 PM   #13
lporter
Member
lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.lporter can successfully navigate the Paris bus system.
 
Posts: 19
Karma: 36674
Join Date: Jan 2013
Device: Kindle Paperwhite
Sorry, I wasn't clear. Nothing at all is flashed on to my device. Whenever I upload the stock u-boot to my kindle with mfgtool, it works, but crashes when I use anything bist-related for some reason.
lporter is offline   Reply With Quote
Old 03-01-2013, 02:14 PM   #14
eureka
but forgot what it's like
eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.
 
Posts: 710
Karma: 2290994
Join Date: Dec 2011
Location: north (by northwest)
Device: Kindle Touch
Quote:
Originally Posted by lporter View Post
Sorry, I wasn't clear. Nothing at all is flashed on to my device. Whenever I upload the stock u-boot to my kindle with mfgtool, it works, but crashes when I use anything bist-related for some reason.
Well, now I'm curious not only about how you've got to USB downloader mode on PW (as was pointed by hawhill), but also about how exactly did you wipe your device, so that pre-flashed U-Boot had been wiped too.
eureka is offline   Reply With Quote
Old 03-01-2013, 02:31 PM   #15
ixtab
(offline)
ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.
 
ixtab's Avatar
 
Posts: 2,903
Karma: 6677485
Join Date: Dec 2011
Device: K3, K4, K5, KPW, KPW2
...which still leaves the question that hawhill posted, and which I'm also very much interested in: how did you manage to get your Paperwhite into USB downloader mode in the first place? Did you find the holy grail that we have all desperately been looking for?
ixtab is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
K3 How to show kernel boot information instead Amazon boot picture? madtrapper Kindle Developer's Corner 8 01-04-2013 08:51 AM
Smartq v5 boot problem exscentric Android Devices 0 08-09-2012 06:11 PM
Compiling for Lubuntu (regarding compiling instructions) jgratero Sigil 5 07-15-2012 07:54 PM
Problem compiling booxsdk rfog Onyx Boox 1 07-07-2012 05:36 AM
Connection problem on dual boot Nook Color pops1959 Barnes & Noble NOOK 0 02-03-2012 05:27 PM


All times are GMT -4. The time now is 10:54 AM.


MobileRead.com is a privately owned, operated and funded community.