maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   OS2008 / Maemo 4 / Chinook - Diablo (https://talk.maemo.org/forumdisplay.php?f=29)
-   -   usb keyboard stops on-screen keyboard (https://talk.maemo.org/showthread.php?t=14298)

speculatrix 2008-01-03 10:20

usb keyboard stops on-screen keyboard
 
I have an N800 running release version of OS2008, using a usb mini-B to A converter which auto switches the usb port to host mode.

I can use my usb nano keyboard just fine and the on-screen keyboard if disabled so it doesn't appear when I select a text field... which is good!

However, if I unplug the keyboard, I'd expect the N800 to revert to popping up the on-screen keyboard, but it doesn't. This makes it very difficult to use, and requires a reboot.

Does anyone know how to re-enable the virtual keyboard?

thanks!

xxM5xx 2008-01-03 11:17

Re: usb keyboard stops on-screen keyboard
 
Quote:

Originally Posted by speculatrix (Post 119840)
I have an N800 running release version of OS2008, using a usb mini-B to A converter which auto switches the usb port to host mode.

I can use my usb nano keyboard just fine and the on-screen keyboard if disabled so it doesn't appear when I select a text field... which is good!

However, if I unplug the keyboard, I'd expect the N800 to revert to popping up the on-screen keyboard, but it doesn't. This makes it very difficult to use, and requires a reboot.

Does anyone know how to re-enable the virtual keyboard?

thanks!

I observed this also.

There is probably some xterm command line thing that will work. Unfortunately I do not know what that command string might be.

speculatrix 2008-01-03 11:29

Re: usb keyboard stops on-screen keyboard
 
Quote:

Originally Posted by xxM5xx (Post 119857)
I observed this also.

There is probably some xterm command line thing that will work. Unfortunately I do not know what that command string might be.

I'm sure there must be a command one can enter, but of course it must be done before disconnecting the USB keyboard!

EIPI 2008-01-03 14:27

Re: usb keyboard stops on-screen keyboard
 
I can confirm that this happened to me also (yesterday). My fix was to reboot! I'm researching this, and will post any progress in this thread.

Edit: I cannot reproduce this problem today! Is this a consistent problem, or did it just happen once? Did you try disconnecting the attached USB device (keyboard) by tapping the USB icon in the status bar before unplugging the keyboard? That is the *safe* way to disconnect USB devices... Interesting that I cannot reproduce it again.

ShyBoy 2008-01-03 15:13

Re: usb keyboard stops on-screen keyboard
 
Quote:

Originally Posted by EIPI (Post 119917)
I can confirm that this happened to me also (yesterday). My fix was to reboot! I'm researching this, and will post any progress in this thread.

Edit: I cannot reproduce this problem today! Is this a consistent problem, or did it just happen once? Did you try disconnecting the attached USB device (keyboard) by tapping the USB icon in the status bar before unplugging the keyboard? That is the *safe* way to disconnect USB devices... Interesting that I cannot reproduce it again.


Well thats the *safe* way to disconnect USB devices in windows environment, isn't it?

or this does apply to all environments like MAC and LINUX.

fanoush 2008-01-03 16:21

Re: usb keyboard stops on-screen keyboard
 
Quote:

Originally Posted by speculatrix (Post 119861)
I'm sure there must be a command one can enter, but of course it must be done before disconnecting the USB keyboard!

Thare was such command in 2007 and 2006 system - maemo-gtk-im-switch and it was used like
Code:

maemo-gtk-im-switch xim
maemo-gtk-im-switch osso-input-method

to turn keyboard off and on. Such command is no longer there in OS2008 and it works automagically. Seems like the magic sometimes fails :-)

I noticed that it disables keyboard also if you connect usb mouse or gamepad so I guess it monitors kernel input subsystem and when any device creates new input device in /dev/input/ (like all usb and BT input devices do) keyboard is disabled and when they vanish it is enabled. Maybe those device files sometimes fail to vanish on keyboard disconnection? Maybe because they are in use?

DataPath 2008-01-03 19:34

Re: usb keyboard stops on-screen keyboard
 
I get this problem immediately upon loading penguinbait's joystick.ko kernel module, too, whether I have anything attached or not.

xxM5xx 2008-01-03 22:05

Re: usb keyboard stops on-screen keyboard
 
Quote:

Originally Posted by EIPI (Post 119917)
I can confirm that this happened to me also (yesterday). My fix was to reboot! I'm researching this, and will post any progress in this thread.

Edit: I cannot reproduce this problem today! Is this a consistent problem, or did it just happen once? Did you try disconnecting the attached USB device (keyboard) by tapping the USB icon in the status bar before unplugging the keyboard? That is the *safe* way to disconnect USB devices... Interesting that I cannot reproduce it again.

I just did a couple of quick tests and it does seem that this is inconsistant.

M5

EIPI 2008-01-04 00:07

Re: usb keyboard stops on-screen keyboard
 
Should we bugzilla this?

bukubuku 2008-01-10 15:46

Re: usb keyboard stops on-screen keyboard
 
Did somebody solve this problem?
Your answer is much appreciate ~

Cptnodegard 2008-01-15 12:52

Re: usb keyboard stops on-screen keyboard
 
indeed. i have no idea about xterm so i need to know exactly what to do if its going to help me :/

tuukos 2008-03-28 20:25

Re: usb keyboard stops on-screen keyboard
 
I am experiencing this problem as well... plugging in a USB keyboard to my N800 disables the onscreen keyboard (good)... both unplugging the keyboard or unmounting the USB keyboard by clicking on the icon on the top bar *then* unplugging the keyboard fails to bring back the onscreen keyboard (bad).

The only way I know how to re-enable the onscreen keyboard functionality is to reboot the unit. Anybody come up with a solution that doesn't involve a reboot? Thanks for any help...

tso 2008-03-28 21:41

Re: usb keyboard stops on-screen keyboard
 
given that this also happens when using bluetooth keyboards im starting to wonder if there is some issue with the way the onscreen keyboard is told to show or not.

does anyone have any knowledge about how it gets the signal that a physical keyboard is now "inserted" and it should stay away?

hmm, maybe it could be related to how the slider keyboard on the N810 works, as it should probably trigger some of the same stuff, right?

tso 2008-03-29 18:31

Re: usb keyboard stops on-screen keyboard
 
i just had a look using the gconf editor, and found that there is a box under /system/osso/af labeled keyboard-attached. this becomes checked when i pair my bluetooth keyboard with my N800, and should in theory go unchecked when i turn the keyboard off.

turning the check on manually seems to stop the onscreen keyboard from going active.

so people, if you have trouble getting the onscreen keyboard to show, go and see if the box is checked, and if it is, try to uncheck it.

tuukos 2008-03-29 19:50

Re: usb keyboard stops on-screen keyboard
 
That did it! I installed the gconf editor and noted that - after unplugging the USB keyboard - the 'keyboard-attached' setting was still checked... Unchecking that option restored the onscreen keyboard... Thanks!

tso 2008-03-29 21:35

Re: usb keyboard stops on-screen keyboard
 
glad it worked. now if we could figure out what it is thats forgetting to uncheck that option when a keyboard is unplugged...

funny thing is that i found it while looking for a way to slow down the finger keyboard check, as i currently rather use the center dpad then whack the screen as is currently required...

Cybertrn 2008-04-01 05:02

Re: usb keyboard stops on-screen keyboard
 
Thus, in OS2008, we can execute xterm command
gconftool-2 -t bool -s /system/osso/af/keyboard-attached true
for disabling virtual keyboard and
gconftool-2 -t bool -s /system/osso/af/keyboard-attached false
for enabling virtual keyboard.
It may be more convenient (in the script for example) then manually using gconf editor.

tso 2008-04-01 13:51

Re: usb keyboard stops on-screen keyboard
 
true, but for the odd time when the keyboard gets stuck. having gconf editor handy to unstick it may be just as simple (if it do not happen to often).

jolouis 2008-04-01 17:18

Re: usb keyboard stops on-screen keyboard
 
Good spot with the gconf setting there! I've been looking for that one for a while now (particularly handy for the USB Mouse app since the tablet detects the mouse as a HID device and disables the onscreen keyboard!).

I can shed some light on the strange/random USB keyboard issue by the way (as far as bluetooth, I don't know I've run into it once or twice myself, but I imagine it's something somewhat similar): IF you're using USB host mode (especially if you're using the auto-switching OTG adapter) and you take the device out of host mode BEFORE disconnecting the keyboard itself from the USB bus, the kernel never receives the USB disconnect signal, so it never removes any of the sys or device entries for the keyboard (it thinks it's still connected). It's a problem that we've run into for all of the USB devices, and the only really viable solution at this point is to be careful with how you handle things. For example, if you've got the auto switching OTG adapter:

This scenario will cause the problem every time:
- Connect OTG adapter with USB keyboard plugged into it
- All works, you type, yada yada yada
- You unplug the OTG adapter with the USB keyboard plugged into it
- Onscreen keyboard will not return.

Compared to this which will never cause the problem (as far as I can tell):
- Connect OTG adapter with USB Keyboard plugged into it
- All works, you type, yada yada yada
- UNPLUG USB KEYBOARD from OTG adapter, leaving OTG adapter sitll connected to tablet.
- Wait a second (well probably by this point not really required, but you get the idea)
- Disconnect OTG adapter from tablet.
- Onscreen keyboard will return normally.

Now, that should only affect USB keyboards, since it's a USB problem that's causing it... BUT, I would guess that if for some reason the BT keyboard looses connection or the tablet doesn't "unpair" successfully with it, you'll run into the same scenario...

-Rob

Benson 2008-04-02 23:03

Re: usb keyboard stops on-screen keyboard
 
Another issue that sometimes afflicts the N800 (not N810): After Ctrl-Space or some such (from USB or BT keyboard), you get a narrow, completion-only bar designed for the N810's thumbboard. It could be helpful, but the trouble is, after disconnecting the external keyboard, it locks into that mode; stylus-tap, finger-tap, or d-pad enter all bring the completion bar (but no keyboard) up. The fix for this one:
Code:

gconftool-2 -t bool -s /system/osso/af/slide-open false
Yep, my N800 thinks it has a slide, and that slide is open. :D
Seems like a script that sets keyboard-attached and slide-open both false belongs in powerlaunch, osso-statusbar-cpu, personal menu, and/or command-navigator.

buma 2008-08-03 18:46

Re: usb keyboard stops on-screen keyboard
 
awesome! this just happened to me this morning and was driving me buggy...

so, is there a way to issue both of these xterm commands at once? like concatenating them together in personal menu or something?

tso 2008-08-03 18:49

Re: usb keyboard stops on-screen keyboard
 
A shell script should do the trick Iirc.

buma 2008-08-04 00:06

Re: usb keyboard stops on-screen keyboard
 
uuu... how do i do that?
sorry, my newbieness is showing

I started to do some googlind and found a site - it makes it look like I just 'vi' a script with both commands:
Code:

#start script- rekey
#used to correct virtual keyboard after
#bluetooth keyboard disconnect failure
gconftool-2 -t bool -s /system/osso/af/keyboard-attached false
gconftool-2 -t bool -s /system/osso/af/slide-open false

but then I get stuck - where do iI go from there? anyone can give a newbie linux user a clue?

briand 2008-08-04 00:54

Re: usb keyboard stops on-screen keyboard
 
save the script. :)

chmod +x <script name>

mv <script name> /usr/local/bin/

...then, you can run that script from a button/menu/whatever with one tap.

tso 2008-08-04 01:31

Re: usb keyboard stops on-screen keyboard
 
no need to move it, altho it makes it easier to recall the path to i guess ;)

it also just dawned on me that it may be unwise to argue with someone thats using a evil genius as a avatar...

least of all as i do not consider myself on sid's level of knowledge, experience, or age for that matter...

i fear i would be more in the area of a cross between greg and mike, with the majority being greg (basically, i need to come up with a way to deliver pain via the phone lines)...

buma 2008-08-04 10:16

Re: usb keyboard stops on-screen keyboard
 
@briand
thanks!!

so I'm guessing I run it in personal menu with:
Code:

./ <script_name>
is that right?

thanks in advance

Benson 2008-08-04 16:25

Re: usb keyboard stops on-screen keyboard
 
Well, if you move it to a location on the path, just the name would work. If you place it in the current directory, ./name would be right. (Note that I've no clue what directory hildon-desktop runs in, so this is pretty useless here.) If it's anywhere, the full path /path/to/name will work.

lm2 2008-08-04 17:00

Re: usb keyboard stops on-screen keyboard
 
Thanks SO MUCH for this script! This is a wonderful development!

briand 2008-08-04 18:47

Re: usb keyboard stops on-screen keyboard
 
Quote:

Originally Posted by tso (Post 209898)
it also just dawned on me that it may be unwise to argue with someone thats using a evil genius as a avatar...

Индеед. Анд, ас Питр доесн'т ацтуаллы спеак руссиан, бут йуст претендс то, И ам респондинг ин тче цыриллиц фонт, бут вритинг ин енглисч. Цонфусинг, но? (ацтуаллы, иф ыоу кнов чов то проноунце тче цыриллиц леттерс, ыоу цан реад тчис яуите еасилы!)

Quote:

Originally Posted by tso (Post 209898)
least of all as i do not consider myself on sid's level of knowledge, experience, or age for that matter...

Nor I. ...and, as much as I like my coffee, I wouldn't be drinking some weird talking mold that grew in the cup! yecccch!


Quote:

Originally Posted by tso (Post 209898)
i fear i would be more in the area of a cross between greg and mike, with the majority being greg (basically, i need to come up with a way to deliver pain via the phone lines)...

Likewise. (although, I will neither admit or deny the ability to deliver pain via telephone lines!)

Benson 2008-08-04 19:44

Re: usb keyboard stops on-screen keyboard
 
Heh.
Quote:

Originally Posted by Google Language Tools
Indeed. Andes, Al Pitr doesn't atstually speak russian, bottles yust pretends it, I am responding information tche tsyrillits font, bottles vriting information englisch. Tsonfusing, but? (atstually, if you knov chov then pronountse tche tsyrillits letters, you read tsan tchis yauite easily!)

I thought that was what was going on, but I can't pronounce the Cyrillic alphabet, so I hoped it would transliterate for me. Google faileth not!

briand 2008-08-04 21:32

Re: usb keyboard stops on-screen keyboard
 
Quote:

Originally Posted by Benson
I thought that was what was going on

ah.. but you forget. Pitr isn't Russian... he only pretends to be (see original thread in the strip, or the more recent strip where he went to work for Google, and when he tries to impress this random programmer he learns she actually _is_ Russian, and he retreats!).. .anyway... as such, I wrote in english, but using the cyrillic characters (or closest equivalent) for the above. Had I used our alphabet, the text above would have read:

"Indeed. And, as Pitr doesn't actually speak Russian, but just pretends to, I am responding in the cyrillic font, but writing in English. Confusing, no? (actually, if you know how to pronounce the cyrillic letters, you can read this quite easily!)"

..it's just something we evil geniuses do, from time to time...

;)

Benson 2008-08-04 21:52

Re: usb keyboard stops on-screen keyboard
 
I know; I thought that (i.e. writing english, with a fake slavic accent alphabet) was what was going on. But being to lazy to figure out the transliteration manually, I fed it through Google Language Tools, which translated a few words that got (un)lucky, but transliterated everything it couldn't translate. The result, while giving a very good sense of the meaning, was highly amusing, that's all.


All times are GMT. The time now is 23:28.

vBulletin® Version 3.8.8