Register Guidelines E-Books Today's Posts Search

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

Notices

Reply
 
Thread Tools Search this Thread
Old 03-30-2015, 11:11 PM   #1
brianinmaine
Evangelist
brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.
 
brianinmaine's Avatar
 
Posts: 456
Karma: 1287375
Join Date: Jan 2013
Location: West Gardiner, Maine
Device: Touch (5.3.7)
Router + USB keyboard <-> Kindle input

Has anyone done this? I've just started searching a bit on this and found a few breadcrumbs, no clear answers.

I have an old Belkin router with a USB port running OpenWRT and am able to add other modules. I have a USB keyboard to plug in to the router. I would like to forward keyboard input from the router to the Kindle (Touch) over wifi.

The router and the Kindle can talk over ssh (both can be either client or server).

Whats the easiest or best way to forward the keystrokes to the Kindle? Ideally into ANY window where the on-screen window is up?

Thanks for any thoughts on this!

edit: I found this as a possible solution: http://superuser.com/questions/67659...d-over-network

Last edited by brianinmaine; 03-31-2015 at 12:28 AM.
brianinmaine is offline   Reply With Quote
Old 04-01-2015, 09:41 AM   #2
volkaoth
Enthusiast
volkaoth began at the beginning.
 
Posts: 39
Karma: 10
Join Date: Jan 2015
Location: ulm, germany
Device: KT2
usually USB Keyboards using a USB HID protocol to connect to any machine.
So if you can install a proper USB HID driver, it should be possible to get the USB Keyboard as standard input.
That far it should work with USBNetwork(SSH over Wifi) on the kindle like a normal terminal connection for your pc.
volkaoth is offline   Reply With Quote
Old 04-01-2015, 07:43 PM   #3
knc1
Going Viral
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: 17,212
Karma: 18210809
Join Date: Feb 2012
Location: Central Texas
Device: No K1, PW2, KV, KOA
Quote:
Originally Posted by volkaoth View Post
- - - -
So if you can install a proper USB HID driver, it should be possible to get the USB Keyboard as standard input.
- - - -
Ah, no.
The Kindles are USB **devices** as are USB Keyboards.
One or the other has to be the **host**.

Although most of the Kindles (since the KT at least) bring out the OTG port of the SoC as the external USB connection . . . .
There are a variety of problems with each model/firmware combination in getting it to work as a **host** device.

Various people over the years have documented their attempts on this forum, some searching should turn up what has been tried.
knc1 is offline   Reply With Quote
Old 04-01-2015, 08:51 PM   #4
brianinmaine
Evangelist
brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.
 
brianinmaine's Avatar
 
Posts: 456
Karma: 1287375
Join Date: Jan 2013
Location: West Gardiner, Maine
Device: Touch (5.3.7)
SO I'm pretty sure my idea will work:
add a keyboard to my router http://h-wrt.com/en/doc/kb
then forward the keystrokes using netcat like in my edit link above.

I didn't have a good version on my router - I'll try some more when I get time. I just thought someone might have done this before and am just looking for pointers. USBIP might be a solution also, but might require more work. If I can just run a KUAL script to start netcat and receive keystrokes, seems simple on the Kindle end.

EDIT: OK, more info. Openwrt has many versions. Because I an old Belkin router, I need to use a 2.4 kernel version if I want wireless (I do), as the 2.6 version wireless is broken. HID support is only in the 2.6 version (of course!) so it looks like one or the other. A more current router would be a simple solution - probably not going to happen soon.

For now I abandon this project, but it does look quite doable.

As an aside, I've also seen USB infrared receivers that could be attached to a router, which could then be forwarded to a Kindle to do ... ANYTHING!

Last edited by brianinmaine; 04-01-2015 at 10:50 PM.
brianinmaine is offline   Reply With Quote
Old 04-02-2015, 12:03 AM   #5
knc1
Going Viral
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: 17,212
Karma: 18210809
Join Date: Feb 2012
Location: Central Texas
Device: No K1, PW2, KV, KOA
First consideration, and a show-stopper if you don't make allowances for it:

Linux (any *nix) **MUST** have an "operator console" device.
It will not boot without one, talk about an early failure, it will not even complete pre-boot initialization.

Note: The system only needs something to send to, it doesn't matter if there is anything "listening" on the other end.
(An unmodified Kindle does not have anything listening on the other end - other than the empty solder pads. )

- - - - -

So to free up the hardwired serial port (that we know of, there are probably at least four others on the SoC) -
Move the "operator console" to something else -
Say, a network console:
https://mindplusplus.wordpress.com/2...sole-on-linux/

If Amazon didn't supply that kernel module (they probably don't) -
You can grab the Amazon, kernel source release, and build one "after the fact" as it where.
It will work just as if Amazon had built it for you.

See:
https://mindplusplus.wordpress.com/2...sole-on-linux/
For a spoiler on this part of your project.

Note: Yes, you could put the "operator console" on one of the ports (if u-boot initializes them) that don't have any external connections.
Above I just assumed you want to log the kernel message output so you have a hint as to why the Kindle bricked when it got to the next part of your modifications.

- - - - -

Next, you want to setup another console device, using the (now freed) known serial port.

A spoiler on this part of the project:
https://www.howtoforge.com/setting_up_a_serial_console

**READ THE COMMENTS**
The devices using series 5.x firmware use upstart for user space initialization.

You can ignore the specifics about GRUB and/or LILO - embedded devices **usually** don't use them (Kindles don't - they use u-boot).

But it is unlikely that you need to export the u-boot console.

- - - -

The above is only a **teaser** - not a worked out solution.
It is hard to provide a worked out solution when the final use of this serial port is unknown.

Ah, but the above should have enough Linux-Specific keywords and phrases to get started with a web-search tool for other parts of the solution.
That is, to whatever it is you want to "solve" .

- - - - -

For GUI input, you will have to tweak the input event device(s) that the standard Kindle GUI listens/talks to so that your new serial input is used instead.

Then use one (or two, send and receive) pairs of Kindle-local and Kindle-remote copies of netcat (or some such tool) to forward your new serial input device somewhere else that is network connected.

Note: you have not opened up your Kindle, only diddled with its system software setup.
Hint: practice on something, such as a Kindle Touch, that can be de-bricked with Kubrick when you screw it up.

Last edited by knc1; 04-02-2015 at 12:25 AM.
knc1 is offline   Reply With Quote
Old 04-02-2015, 07:59 AM   #6
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,379
Karma: 2155307
Join Date: Nov 2010
Location: Goettingen, Germany
Device: Kindle Paperwhite, Kobo Mini
What kind of input events should be generated on the Kindle side?

As for the kernel version: I'm pretty sure 2.4 kernels *did* have USB-HID support.
hawhill is offline   Reply With Quote
Old 04-02-2015, 01:58 PM   #7
knc1
Going Viral
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: 17,212
Karma: 18210809
Join Date: Feb 2012
Location: Central Texas
Device: No K1, PW2, KV, KOA
A rather limited selection of USB serial, but its there:
Ref: https://www.kernel.org/pub/linux/ker...2.4.37.tar.bz2

Code:
#
# Makefile for the USB serial device drivers.
#

O_TARGET    := usb-serial.o

# Object file lists.

obj-$(CONFIG_USB_SERIAL)                        += usbserial.o
obj-$(CONFIG_USB_SERIAL_VISOR)            += visor.o
obj-$(CONFIG_USB_SERIAL_IPAQ)            += ipaq.o
obj-$(CONFIG_USB_SERIAL_WHITEHEAT)        += whiteheat.o
obj-$(CONFIG_USB_SERIAL_FTDI_SIO)        += ftdi_sio.o
obj-$(CONFIG_USB_SERIAL_KEYSPAN_PDA)        += keyspan_pda.o
obj-$(CONFIG_USB_SERIAL_XIRCOM)            += keyspan_pda.o
obj-$(CONFIG_USB_SERIAL_KEYSPAN)        += keyspan.o
obj-$(CONFIG_USB_SERIAL_OMNINET)        += omninet.o
obj-$(CONFIG_USB_SERIAL_DIGI_ACCELEPORT)    += digi_acceleport.o
obj-$(CONFIG_USB_SERIAL_BELKIN)            += belkin_sa.o
obj-$(CONFIG_USB_SERIAL_EMPEG)            += empeg.o
obj-$(CONFIG_USB_SERIAL_MCT_U232)        += mct_u232.o
obj-$(CONFIG_USB_SERIAL_EDGEPORT)        += io_edgeport.o
obj-$(CONFIG_USB_SERIAL_EDGEPORT_TI)        += io_ti.o
obj-$(CONFIG_USB_SERIAL_PL2303)            += pl2303.o
obj-$(CONFIG_USB_SERIAL_CYBERJACK)        += cyberjack.o
obj-$(CONFIG_USB_SERIAL_IR)            += ir-usb.o
obj-$(CONFIG_USB_SERIAL_KLSI)            += kl5kusb105.o
obj-$(CONFIG_USB_SERIAL_KOBIL_SCT)        += kobil_sct.o

# Objects that export symbols.
export-objs    := usbserial.o

include $(TOPDIR)/Rules.make
knc1 is offline   Reply With Quote
Old 04-02-2015, 02:08 PM   #8
knc1
Going Viral
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: 17,212
Karma: 18210809
Join Date: Feb 2012
Location: Central Texas
Device: No K1, PW2, KV, KOA
Quote:
Originally Posted by brianinmaine View Post
- - - -
A more current router would be a simple solution - probably not going to happen soon.

For now I abandon this project, but it does look quite doable.
- - - -
Hint: NetGear not only ships their firmware source code, but packaged in a manner to allow it to re-build the firmware image.

I.E: 110% complete release, including all scripting (as required by the GPL license).
knc1 is offline   Reply With Quote
Old 04-02-2015, 09:07 PM   #9
brianinmaine
Evangelist
brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.brianinmaine ought to be getting tired of karma fortunes by now.
 
brianinmaine's Avatar
 
Posts: 456
Karma: 1287375
Join Date: Jan 2013
Location: West Gardiner, Maine
Device: Touch (5.3.7)
Quote:
Originally Posted by hawhill View Post
What kind of input events should be generated on the Kindle side?

As for the kernel version: I'm pretty sure 2.4 kernels *did* have USB-HID support.
From the quote in the top post:
load the evdev kernel module on both machines
On the router:
$ cat /dev/input/by-path/platform-i8042-serio-0-event-kbd | nc <IP> 4444
On the Kindle:
$ nc -l -p 4444 > /dev/input/by-path/platform-i8042-serio-0-event-kbd

That was my plan. I did find an HID 2.4 module for my Openwrt router - loaded and inserted - didn't work for me. I could have spent more effort on it by rebuilding the whole deal but I lacked the interest in spending a lot of effort on this as I don't really need it, I was just playing and thought it would be kinda cool.

Thanks for the replies - I went on to make the router a streaming radio player with a USB audio card... maybe I'll check out some bluetooth stuff or SIP...
Speaking of - twobob was working on a SIP player for the Kindle a while back, I should check out that old project...
brianinmaine is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Kindle 3 keyboard usb demo mode awfargo Kindle Developer's Corner 6 11-07-2013 05:27 PM
Demo Kindle Keyboard USB Problems tommytomtom Kindle Developer's Corner 1 01-25-2013 03:42 AM
902 Have you tested the Bluetooth keyboard input? How fast is it? firebelow PocketBook 5 04-11-2012 03:49 PM
Shell script to wait for user input from K3g keyboard jmseight Kindle Developer's Corner 33 04-01-2012 04:32 PM
Request An idea to use the e-ink display as keyboard input. Leadlight enTourage Archive 6 05-30-2010 02:05 PM


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


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