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 Yesterday, 05:54 AM   #346
nasser
Evangelist
nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.
 
nasser's Avatar
 
Posts: 446
Karma: 371106
Join Date: Feb 2010
Device: Too many..
Quote:
Originally Posted by knc1 View Post
...
If you don't have anything installed that depends on en_GB set of jar files, change the settings to match the other two, just in case it makes a difference.
...
Will try it and check.

knc1, Can you check if the end key works on your pw3 and kt3?
nasser is offline   Reply With Quote
Advert
Old Yesterday, 06:04 AM   #347
nasser
Evangelist
nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.
 
nasser's Avatar
 
Posts: 446
Karma: 371106
Join Date: Feb 2010
Device: Too many..
The end key is working on PW1 with en_GB.
Changed language on PW1 to en_US.
The end key still works.

Now, I'll try changing the setting on PW3 and KT3 to en_GB and get back.
nasser is offline   Reply With Quote
Old Yesterday, 08:03 AM   #348
baf
Addict
baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.
 
Posts: 399
Karma: 2010718
Join Date: May 2012
Device: kt
Please try with attached kterm binary.
I recompiled vte library with debug enabled.

To show debug output you need to ssh to you kindle export VTE_DEBUG environment variable and start attached binary.

Code:
export VTE_DEBUG="signals,io,lifecycle,pty,keyboard,work,timeout,draw,ally,pangocairo,events,updates,adj,misc,parse,selection,substitution,ring,cursor,matcher,cel
ls,widget-size,style,resize"
The variable contains list of individual debug options. We don't need all of them enabled. You can probably skip some if you realize they are useless for our investigation. Or just post output of all enabled.

Most interesting options output while pressing End

Option "keyboard":

Code:
[root@kindle bin]# export VTE_DEBUG="keyboard"
[root@kindle bin]# ./kterm-debug
Mapping GDK_End via ncurses to '<0x1b>OF', returning.
Sending <1b> to child.
Sending 'O' to child.
Sending 'F' to child.
Maybe there are differences in ncurses on newer platforms?

Option "io":

Code:
[root@kindle bin]# export VTE_DEBUG="io"
[root@kindle bin]# ./kterm-debug
Set terminal encoding to `UTF-8'.
polling vte_terminal_io_read
Feed 29 bytes, in 1 chunks.
read 29/4096 bytes, again? yes, active? yes
read 29/4096 bytes, again? yes, active? no
Handler processing 29 bytes over 1 chunks + 0 bytes pending.
0 chars and 0 bytes in 1 chunks left to process.
Wrote ^[
Wrote  O
Wrote  F
Option "events":
Code:
[root@kindle bin]# export VTE_DEBUG="events"
[root@kindle bin]# ./kterm-debug
Keypress, modifiers=0x0, keyval=0xffe7, raw string=`(null)'.
Keypress, modifiers=0x0, keyval=0xff57, raw string=`(null)'.
Attached Files
File Type: zip kterm-debug.zip (376.0 KB, 2 views)
baf is offline   Reply With Quote
Old Yesterday, 12:12 PM   #349
nasser
Evangelist
nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.
 
nasser's Avatar
 
Posts: 446
Karma: 371106
Join Date: Feb 2010
Device: Too many..
Quote:
Originally Posted by nasser View Post
The end key is working on PW1 with en_GB.
Changed language on PW1 to en_US.
The end key still works.

Now, I'll try changing the setting on PW3 and KT3 to en_GB and get back.
Changed setting on PW3 and KT3 to en_GB. No effect. End key still doesn't work.
nasser is offline   Reply With Quote
Old Yesterday, 01:08 PM   #350
nasser
Evangelist
nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.
 
nasser's Avatar
 
Posts: 446
Karma: 371106
Join Date: Feb 2010
Device: Too many..
Quote:
Originally Posted by baf View Post
Please try with attached kterm binary.
I recompiled vte library with debug enabled.
...
...
Thanks, baf!

Most of the debug options are not significant.
I'm giving below the ones which are. The output in bold is what is triggered after pressing the mod1 and end keys.

Option: "signals":
Code:
PW1 gives:
"Emitting `encoding-changed'.
Emitting `emulation-changed'.
Emitting adjustment_changed.
Emitting `char-size-changed'.
Queueing `contents-changed'.
Emitting adjustment_changed.
Queueing `contents-changed'.
Emitting adjustment_changed.
Emitting `contents-changed'.
Queueing `contents-changed'.
Emitting adjustment_changed.
Emitting buffered `text-inserted'
Emitting buffered `text-deleted'
Emitting `contents-changed'.
Queueing `cursor-moved'.
Emitting `cursor-moved'.
Emitting `commit' of 3 bytes."

PW3 and KT3 give the same, but the last line is missing.
Option: "io"
Code:
PW1 gives:
"Set terminal encoding to `UTF-8'.
polling vte_terminal_io_read
Feed 29 bytes, in 1 chunks.
read 29/4096 bytes, again? yes, active? yes
read 29/4096 bytes, again? yes, active? no
Handler processing 29 bytes over 1 chunks + 0 bytes pending.
0 chars and 0 bytes in 1 chunks left to process.
Wrote ^[
Wrote  O
Wrote  F"


PW3 and KT3 give the same, but the last 3 lines are missing.
Option: "keyboard":
Code:
PW1 gives:
"Mapping GDK_End via ncurses to '<0x1b>OF', returning.
Sending <1b> to child.
Sending 'O' to child.
Sending 'F' to child."


PW3 and KT3 give only:
Mapping GDK_End (ignoring, no match for modifier state).
Option : "events":
Code:
PW1, PW3 and KT3 all give the same:

Keypress, modifiers=0x0, keyval=0xffe7, raw string=`(null)'.
Keypress, modifiers=0x0, keyval=0xff57, raw string=`(null)'
Option: "adj":
Code:
PW1, PW3 and KT3 all give the same:

"Changing step increment from 0 to 24
Changing page size from 0 to 24
Changing page increment from 0 to 24
Changing page size from 24 to 27
Changing page increment from 24 to 27
Changing upper bound from 0 to 1
Snapping to bottom of screen
Changing upper bound from 1 to 27
Snapping to bottom of screen"
nasser is offline   Reply With Quote
Old Yesterday, 05:47 PM   #351
baf
Addict
baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.
 
Posts: 399
Karma: 2010718
Join Date: May 2012
Device: kt
Nasser!
Thanks a lot for the debugging. I think I know what is going on.
The crucial part is this:

Code:
PW1 gives:
"Mapping GDK_End via ncurses to '<0x1b>OF', returning.

PW3 and KT3 give only:
Mapping GDK_End (ignoring, no match for modifier state).
VTE first tries to check the mapping in termcap file, but there is no entry for End key. Then it tries a lookup in terminfo database. There is terminfo entry for xterm on my KT (with End key mapping), but it is probably missing on newer kindles (I remember some problems with that).

Please try following solution:
Start kterm with TERMINFO variable, like this:

Code:
[root@kindle bin]# TERMINFO=/mnt/us/extensions/kterm/vte/terminfo ./kterm
If it works we will just have to add this to kterm.sh script.
I was fooled by TERMINFO env being present in kterm environment, but I didn't think that it is not accessible to VTE library, only to programs running in terminal.

Hope this helps
baf is offline   Reply With Quote
Old Yesterday, 08:58 PM   #352
nasser
Evangelist
nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.nasser ought to be getting tired of karma fortunes by now.
 
nasser's Avatar
 
Posts: 446
Karma: 371106
Join Date: Feb 2010
Device: Too many..
That fixed it!
Now end keys work on PW3 and KT3!
Great detective work, baf!
nasser is offline   Reply With Quote
Old Yesterday, 09:06 PM   #353
knc1
Snappy answers department
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: 14,777
Karma: 16114753
Join Date: Feb 2012
Location: Central Texas
Device: No K1, PW2, KV, KOA
NiLuJe has a large number of extra applications included in the USBnetworking package.
That includes Nano -
For which he ships his own build of termcap.
I don't recall the details, but the general reason is variations in things missing/supported in the various firmware versions.
knc1 is offline   Reply With Quote
Old Today, 04:15 AM   #354
baf
Addict
baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.
 
Posts: 399
Karma: 2010718
Join Date: May 2012
Device: kt
Quote:
Originally Posted by knc1 View Post
NiLuJe has a large number of extra applications included in the USBnetworking package.
That includes Nano -
For which he ships his own build of termcap.
I don't recall the details, but the general reason is variations in things missing/supported in the various firmware versions.
You are right.
AFAIR newer Kindles lack terminfo entry for xterm emulation. That's why I included terminfo in kterm package. Some programs run in kterm complained about it missing, as default emulation in kterm is xterm.

But I didn't realize the Vte library also uses terminfo as a fallback to termcap (via ncurses). And Vte didn't know the path to the custom terminfo database.

I'll prepare new package.
baf is offline   Reply With Quote
Old Today, 06:50 AM   #355
baf
Addict
baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.
 
Posts: 399
Karma: 2010718
Join Date: May 2012
Device: kt
kterm 2.4

New release is on github.

Thanks again to nasser and knc1 for help!
baf is offline   Reply With Quote
Reply

Tags
kindle touch, kindle touch hacks, terminal emulator

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
K3 One more terminal emulator for kindle. Matan Kindle Developer's Corner 149 08-23-2015 03:15 AM
PRS-T1 Terminal Emulator in rupor-minimal jcromero Sony Reader Dev Corner 2 09-26-2012 02:07 PM
K5 Anybody working on terminal for Kindle Touch? markatlnk Kindle Developer's Corner 3 06-02-2012 10:07 AM
Development Terminal Emulator oddity twichy enTourage Archive 5 05-01-2011 11:51 AM
DR800 rxvt (terminal emulator) for DR800 GregorRichards iRex 13 01-04-2011 06:56 AM


All times are GMT -4. The time now is 07:11 AM.


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