View Single Post
Old 09-24-2009, 03:32 AM   #106
jyavenard
Zealot
jyavenard has a complete set of Star Wars action figures.jyavenard has a complete set of Star Wars action figures.jyavenard has a complete set of Star Wars action figures.jyavenard has a complete set of Star Wars action figures.
 
Posts: 141
Karma: 383
Join Date: Sep 2009
Device: Kindle 2
Thank you all !

Hi

Great stuff guys.

Got my Kindle 2 to share my macbook connection ; allowing my to browse the Amazon store and access some neat features reserved to the lucky US resident otherwise.

For those not willing to read the whole thread, here is how I did it, hoping it will be useful to others.

Get the binary file to re-enable usb networking there:
http://www.mobileread.com/forums/sho...1&postcount=14

Copied the file update_usbnetwork-k2.bin to the root of the Kindle mounted disk.

Then:
Home -> Menu -> Settings
Menu -> Update your Kindle

After the reboot, I edited the file usbnet/usbnetwork uncommenting the line:
Code:
route add default gw ${HOST_IP}
(remove the # in front of it).

Eject the kindle, and unplug the USB cable.

Put the Kindle in debug mode:
Home.
Type any letter on the keyboard to start the Search mode.
Press DEL to blank the line.
type:
;debugOn
(you get the ; character in the SYM menu).

Type any letter on the keyboard to start the Search mode.
Press DEL to blank the line.
type:
`usbNetwork
(you get the ` character in the SYM menu, 2nd last character on the 3rd line).

Plug the USB cable.

I'm on a Mac, using 10.6 (snow Leopard)
The interface wasn't added automatically, so I went into the System Preferences -> Network

I press the + button just above the lock
Selected the Interface "RNDIS/Ethernet Gadget" , I named it "Kindle"

I set the interface as follow:
Configure IPv4: Manually
IP Address: 192.168.2.1
Subnet mask: 255.255.255.0
Click Apply.

Then I went in Network Preferences -> Sharing
Configured the Internet Sharing
To share my Airport connection to "RNDIS/Ethernet Gadget" (I had two listed there, for me the first one worked)

Then I opened a Terminal (use in the Finder Command-Shift-U to get to the utility folder)
telnet 192.168.2.2
I was welcomed by the friendly prompt:
[root@kindle root]#

Remount the root partition in read-write mode:
# mntroot rw

I configured the default DNS to use the OpenDNS servers:
# vi /etc/resolv.d/resolv.conf.default
Code:
nameserver 208.67.222.222
nameserver 208.67.220.220
(to enter edit mode in vi, press 'i', to save and quit: ':wq!')

# vi /opt/amazon/ebook/config/framework.mario.conf
change the line:
Code:
USE_WAN : true
into:
Code:
USE_WAN : false
create the file /etc/init.d/usbnet with:
Code:
#!/bin/sh

_FUNCTIONS=/etc/rc.d/functions
[ -f ${_FUNCTIONS} ] && . ${_FUNCTIONS}

US_ENABLE=/mnt/us/usbnet/AUTO

case "$1" in

        start)
                if [ -f ${US_ENABLE} ]; then
                        /mnt/us/usbnet/usbnetwork
                else
                        msg "not usbnet" I
                fi
        ;;

        stop)
                ;;
        *)
                msg "Usage: $0 {start|stop}" W >&2
                exit 1
                ;;
esac

exit 0
Make the file executable
Code:
# chmod +x /etc/init.d/usbnet
Create the link to active the init script
Code:
# ln -s /etc/init.d/usbnet /etc/rcS.d/S72usbnet
Now create the file AUTO in the usbnet folder:
Code:
# touch /mnt/us/usbnet/AUTO
reboot your Kindle (either using the reboot command, or by doing Menu -> Settings -> Restart.

That's it...
Now whenever I plug my Kindle to my mac, I enjoy all the internet goodness.

Edit: To revert the changes and make the Kindle seen as a USB storage device once again do the following:
telnet 192.168.2.2
Code:
rm /mnt/us/usbnet/AUTO
reboot.

To activate it again, simply create a file AUTO in the usbnet folder. The file system is case insensitive. So AUTO or auto for the name of the file doesn't matter.
Then either reboot ; or enter debug mode (see above); and start `usbNetwork again

Last edited by jyavenard; 09-25-2009 at 01:16 AM. Reason: Add how to unable/disabled following the installation
jyavenard is offline   Reply With Quote