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 10-28-2014, 09:44 AM   #1
miomaz
Member
miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.
 
Posts: 11
Karma: 25090
Join Date: Nov 2012
Device: kindle 4.1.0
Smile Get keystrokes over putty

hi,

I've been fooling around on my kindle (k4nt), (got USBnetwork to work, tried to setup vncviewer by hawhill, used kranu's webserver), in an attempt to play NEOscavenger on my kindle. Is there a way to have the kindle send keystrokes to the pc, possibly over putty?
I could then have kranus webserver running and program a small autoit3 script that translates the kindle output into windows keystrokes and mouse movements. I picture the kindle sending the pressed keys, it popping up as some identfying string in the putty console. Then I could copy the console's contents to the clipboard and parse for the identifying

Neoscavenger is a pretty baddass survival game check it out: Neoscavenger

thanks in advance.

Last edited by Dr. Drib; 10-28-2014 at 10:42 AM.
miomaz is offline   Reply With Quote
Old 10-28-2014, 10:54 AM   #2
HarryT
eBook Enthusiast
HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.
 
HarryT's Avatar
 
Posts: 85,544
Karma: 93383043
Join Date: Nov 2006
Location: UK
Device: Kindle Oasis 2, iPad Pro 10.5", iPhone 6
Please use the forums correctly. This clearly belongs in the Kindle Developers' forum, to where I'm moving it.

Thanks.
HarryT is offline   Reply With Quote
Advert
Old 10-28-2014, 12:26 PM   #3
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
I can't see that it would be a pleasurable exercise at all.
The graphics will be awful (low-contrast in the game means almost no contrast whatsoever on the Kindle).
The input - well, the number of keys is limited. Controlling a mouse cursor with that - ugh.

That said, it shouldn't be all that hard to script the needed parts in kindlevncviewer - but of course, you would need to learn a bit of Lua scripting. It's well possible that forwarding keypresses does work already.
hawhill is offline   Reply With Quote
Old 10-28-2014, 01:04 PM   #4
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
Then again, from a K4 OSK - maybe not.
knc1 is offline   Reply With Quote
Old 10-28-2014, 01:13 PM   #5
miomaz
Member
miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.
 
Posts: 11
Karma: 25090
Join Date: Nov 2012
Device: kindle 4.1.0
This game is perfect for it, because it's more or less a board game lacking animations. the main map looks alittle like die Siedler von Catan with its Hexagonal tiles. Plus I use something called NegativeScreen to adjust the colors and of course inverse the brightness of the monitor. The game is partially played with a mouse, but I can automate the mouseclicks with autoit, and also draw on the screen to see what I select in the game.
Anyhow, could you point me to some website/tutorial that might help me code this lua? In pseudo code i think all that needs scripting is:

If (button x pressed) {
//send message to putty
}

could you translate that into viable code? or is it more complicated than that?
miomaz is offline   Reply With Quote
Advert
Old 10-28-2014, 05:05 PM   #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
I mentioned Lua because kindlevncviewer is scripted in Lua. But it is only prepared to send keystrokes (and, by the way, mouse pointer actions, i.e. absolute "movements") to the VNC server. So - not via PuTTY/SSH, but via VNC.

Just to get things straight: You want to forward the screen, too? And you want to use the "webserver" based way, i.e. emonitor? Or VNC? Via eMonitor, I guess your options are restricted to what the web browser actually can offer via event interfaces (I have no idea if it would work at all). Via VNC, and the vncviewer on the Kindle, you just have to push the proper events to the VNC server. You would probably have to extend https://github.com/hwhw/kindlevncvie...ter/config.lua to handle all the keys that the K4 offers (all keys handled now are K3/KDX centric). When you look at the file, you see the logic that sends a key event to the server - using the XK_Keyname constants - when a keypress is seen on the Kindle (the KEY_... events). K4 keys would probably have to be added. I'd add a line at the bottom, after all the
Code:
elseif code == KEY...
lines, that looks like this:
Code:
else print("unknown key event, code", code)
and then see what it outputs on console when you press the K4 keys. When you have the event codes, you can add your own lines, sending keystrokes to the VNC server.
hawhill is offline   Reply With Quote
Old 10-29-2014, 03:52 PM   #7
miomaz
Member
miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.miomaz knows what's going on.
 
Posts: 11
Karma: 25090
Join Date: Nov 2012
Device: kindle 4.1.0
I figured it would only work through your vncviewer when you mentioned the lua scripts. So yes, this project is intended for the vncviewer (plus the emonitor runs over the webbrowser ans consequently has that ugly bar that eats up 50 pixels or so). You have my thanks, I will see if I can get this to work and keep you guys updated.
miomaz is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Can we load putty into the LUNIX in kindle paper white? edyedy Kindle Developer's Corner 9 08-09-2013 08:24 AM
KPW Win8 x64 PuTTy network error: connection refused Bagerfahrer Kindle Developer's Corner 2 01-19-2013 12:18 PM
Think I need to rename path in PuTTY? Caterix Kindle Developer's Corner 3 09-07-2012 08:26 AM
Kindle Touch and PuTTy qrafzv Kindle Developer's Corner 19 06-20-2012 04:08 PM


All times are GMT -4. The time now is 09:21 AM.


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