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 04-16-2012, 08:05 PM   #1
seaniko7
wannabe developer
seaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Time
 
seaniko7's Avatar
 
Posts: 142
Karma: 49916
Join Date: Mar 2011
Device: Kindle: 2xKeyboard, Classic, 2xTouch, PW; Onyx: Boox M92
[K3] Custom Kernel (rescue shell !, kexec, patched recovery)

Hello again.

Here's my custom kernel for Kindle 3 with some nice features :

- Rescue shell access over USB-Serial
- Kexec support
- Patched Recovery Mode

1. Rescue shell Boot procedure :
- After kernel is loaded by bootloader it creates required nodes and loads g_serial module for serial-over-usb mode.
- It waits 70s for connection with host machine

Connection parameters :
Spoiler:
Code:
ttyACM0, 115200 8N1


If user connected to Kindle terminal ( let's say via minicom )
Spoiler:
It asks for login and password, which is :
Code:
login : root
password : fiona


If no connection is found, Kindle boots as usual.

1.1 Additional scripts :
start-os - starts Kindle OS

2. Recovery mode Boot procedure :
- Reboot Kindle holding power switch for 20s, and then hold enter key on keyboard for 80s
- From Recovey mode press ALT+E to export mmcblk0p1 over USB

3. Kexec kernel execution :
- run "kexec -l <path to your uImage>"
- run "kexec -e"

v0.1


Enjoy.

PS: In not-so-far future I'll prepare similiar kernels for KT & KNT with shell over usbNetwork and scp support.

Last edited by seaniko7; 04-16-2012 at 08:11 PM.
seaniko7 is offline   Reply With Quote
Old 04-17-2012, 09:02 PM   #2
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,022
Karma: 6352591
Join Date: Nov 2011
Location: Щедрость не имеет пределов.
Device: *.*
Awesome!
geekmaster is offline   Reply With Quote
 
Enthusiast
Old 04-18-2012, 02:44 AM   #3
inameiname
Groupie
inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.
 
Posts: 156
Karma: 20390
Join Date: Feb 2009
Device: none
What is the advantage of having this over, say, the default kernel, with the USBNetwork hack and/or terminal emulator program installed?

Sorry to sound so ignorant, I just am curious what the benefits are. Does the custom kernel make the whole firmware and OS run better/faster? Again, for us less-kernel-knowledged people. Hehe.

Also, is it possible to get an uninstall.bin for this hack? I always like the ability to easily uninstall all that I install.

Thanks in advance.
inameiname is offline   Reply With Quote
Old 04-18-2012, 02:58 AM   #4
giorgio130
Addict
giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.
 
Posts: 214
Karma: 82666
Join Date: May 2011
Device: Kobo Glo
[root@kindle us]# kexec -l main_kernel.img
Cannot open /proc/atags: No such file or directory
kexec_load failed: Function not implemented
entry = 0x80008000 flags = 280000
nr_segments = 2
segment[0].buf = 0x28028
segment[0].bufsz = 10
segment[0].mem = 0x80001000
segment[0].memsz = 1000
segment[1].buf = 0x40154008
segment[1].bufsz = 20f000
segment[1].mem = 0x80008000
segment[1].memsz = 20f000

I get the same error as in the other thread. Did you read my post?

To avoid confusion, I'm on a K3G, maybe you're testing on another platform...

Last edited by giorgio130; 04-18-2012 at 04:45 AM.
giorgio130 is offline   Reply With Quote
Old 04-18-2012, 02:40 PM   #5
seaniko7
wannabe developer
seaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Timeseaniko7 possesses cleverness exceeding the boundaries of Space and Time
 
seaniko7's Avatar
 
Posts: 142
Karma: 49916
Join Date: Mar 2011
Device: Kindle: 2xKeyboard, Classic, 2xTouch, PW; Onyx: Boox M92
Quote:
Originally Posted by inameiname View Post
What is the advantage of having this over, say, the default kernel, with the USBNetwork hack and/or terminal emulator program installed?

Sorry to sound so ignorant, I just am curious what the benefits are. Does the custom kernel make the whole firmware and OS run better/faster? Again, for us less-kernel-knowledged people. Hehe.

Also, is it possible to get an uninstall.bin for this hack? I always like the ability to easily uninstall all that I install.

Thanks in advance.
Rescue shell gives you possibility to :

- fix changes that caused so called "brick"
- boot another OS, for example Debian, Android ( only on KT with usbNetwork via NFS mounted from kernel level )
- create boot-menu for above by loading eink modules ( atm I have no idea how to achieve this ... )

I don't have original 3.3 kernel for uninstaller. I'd be very thankful if someone could extract it using geekmaster awesome getkernels tool.

@giorgio130, I've flashed two K3W without issues. If update doesn't work, you can also flash it manually using Amazon tools.

- Download uImage from here : http://dl.dropbox.com/u/16679763/uImage
- Copy it to /mnt/us
- Execute :
Code:
cp /mnt/us/uImage /tmp ; /test/flashtools/luigi/update /tmp/uImage

Last edited by seaniko7; 04-18-2012 at 02:44 PM.
seaniko7 is offline   Reply With Quote
Old 04-18-2012, 03:10 PM   #6
giorgio130
Addict
giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.giorgio130 can do the Funky Gibbon.
 
Posts: 214
Karma: 82666
Join Date: May 2011
Device: Kobo Glo
Thanks, it worked this time! Is it possible that the update package for k3g contains a stock kernel?
giorgio130 is offline   Reply With Quote
Old 04-18-2012, 03:18 PM   #7
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,022
Karma: 6352591
Join Date: Nov 2011
Location: Щедрость не имеет пределов.
Device: *.*
Quote:
Originally Posted by seaniko7 View Post
I don't have original 3.3 kernel for uninstaller. I'd be very thankful if someone could extract it using geekmaster awesome getkernels tool.
Done! Download URL is at the bottom of this list: http://pastebin.com/Wdw4L7yT

EDIT: This compressed very little with gzip. Is it a compressed kernel?


Last edited by geekmaster; 04-18-2012 at 03:30 PM.
geekmaster is offline   Reply With Quote
Old 04-18-2012, 03:57 PM   #8
thomass
Wizard
thomass ought to be getting tired of karma fortunes by now.thomass ought to be getting tired of karma fortunes by now.thomass ought to be getting tired of karma fortunes by now.thomass ought to be getting tired of karma fortunes by now.thomass ought to be getting tired of karma fortunes by now.thomass ought to be getting tired of karma fortunes by now.thomass ought to be getting tired of karma fortunes by now.thomass ought to be getting tired of karma fortunes by now.thomass ought to be getting tired of karma fortunes by now.thomass ought to be getting tired of karma fortunes by now.thomass ought to be getting tired of karma fortunes by now.
 
Posts: 1,407
Karma: 1358805
Join Date: Mar 2011
Location: Türkiye
Device: Kindle 5.3.2.1
Quote:
Originally Posted by geekmaster View Post
to have a better url I shorten(?) it: tinyurl.com/kindleimages

well, if you don't trust me then use this one: preview.tinyurl.com/kindleimages

Last edited by thomass; 04-18-2012 at 04:00 PM.
thomass is offline   Reply With Quote
Old 04-18-2012, 04:33 PM   #9
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,022
Karma: 6352591
Join Date: Nov 2011
Location: Щедрость не имеет пределов.
Device: *.*
Quote:
Originally Posted by thomass View Post
to have a better url I shorten(?) it: tinyurl.com/kindleimages

well, if you don't trust me then use this one: preview.tinyurl.com/kindleimages
We are removing direct links due to warnings on the parent Amazon Kindle forum. Links to lists of links are MUCH less likely to be a problem.
geekmaster is offline   Reply With Quote
Old 04-18-2012, 09:18 PM   #10
inameiname
Groupie
inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.
 
Posts: 156
Karma: 20390
Join Date: Feb 2009
Device: none
Quote:
Originally Posted by seaniko7 View Post
Rescue shell gives you possibility to :

- fix changes that caused so called "brick"
- boot another OS, for example Debian, Android ( only on KT with usbNetwork via NFS mounted from kernel level )
- create boot-menu for above by loading eink modules ( atm I have no idea how to achieve this ... )

I don't have original 3.3 kernel for uninstaller. I'd be very thankful if someone could extract it using geekmaster awesome getkernels tool.

@giorgio130, I've flashed two K3W without issues. If update doesn't work, you can also flash it manually using Amazon tools.

- Download uImage from here : http://dl.dropbox.com/u/16679763/uImage
- Copy it to /mnt/us
- Execute :
Code:
cp /mnt/us/uImage /tmp ; /test/flashtools/luigi/update /tmp/uImage
Thanks for the info. I love the idea of being able to boot Debian or Android, however, it is a shame that is for the Kindle Touch, and not also for Kindle 3. Will it ever be possible to get that working for the Kindle 3?

Now, would having a K3G versus K3W (which you used) matter in terms of using this custom kernel?
inameiname is offline   Reply With Quote
Old 09-10-2012, 03:40 AM   #11
twobob
( ͡° ͜ʖ ͡°){ʇlnɐɟ ƃǝs}Týr
twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.
 
twobob's Avatar
 
Posts: 5,125
Karma: 5324371
Join Date: Jun 2012
Location: uti gratia usura (Yao ying da ying; Mo ying da yieng)
Device: PW, K5 B011, K3 us, K4, DXG, XDA I&II, Omnia, Ematic E6 + E8 :) etc.
Quote:
Originally Posted by seaniko7 View Post
Rescue shell gives you possibility to :

- fix changes that caused so called "brick"
- boot another OS, for example Debian, Android ( only on KT with usbNetwork via NFS mounted from kernel level )
- create boot-menu for above by loading eink modules ( atm I have no idea how to achieve this ... )

I don't have original 3.3 kernel for uninstaller. I'd be very thankful if someone could extract it using geekmaster awesome getkernels tool.

@giorgio130, I've flashed two K3W without issues. If update doesn't work, you can also flash it manually using Amazon tools.

- Download uImage from here : http://dl.dropbox.com/u/16679763/uImage
- Copy it to /mnt/us
- Execute :
Code:
cp /mnt/us/uImage /tmp ; /test/flashtools/luigi/update /tmp/uImage

Thanks very much for your work on this
__________________
Audiophile and electron bully.
My tunes (for free) soundcloud.com/twobob. DONATE TO KUAL BY CLICKING THIS SIMPLE LINK
Kung-Fu. Hard work over time to accomplish skill. A painter can have kung-fu... The musician can have kung-fu, or the poet who paints pictures with words and makes emperors weep. This, too, is kung-fu. Formless, nameless, the true master dwells within. Only you can free him.
The album I'm headlining on at the moment: s.beatport.com/OCp9dT - FREE: 2012 Award winning set
twobob is online now   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
Custom 3.3 kernel with kexec support and patched recovery seaniko7 Kindle Developer's Corner 10 09-09-2012 04:14 PM
PRS-T1 Can't root/un-root/use SD Rescue/boot into Recovery Console bookp Sony Reader Dev Corner 4 07-10-2012 07:57 AM
Custom kernel in Kindle 4 NT? zatix Kindle Developer's Corner 1 02-27-2012 09:09 AM
Custom kernel for Kindle 3 yifanlu Kindle Developer's Corner 58 11-17-2011 11:25 AM


All times are GMT -4. The time now is 10:41 PM.


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