OESF Portables Forum

Everything Else => Zaurus Distro Support and Discussion => Distros, Development, and Model Specific Forums => Archived Forums => Sharp ROMs => Topic started by: daniel3000 on April 24, 2006, 12:32:58 pm

Title: Exchanging "/" And ","
Post by: daniel3000 on April 24, 2006, 12:32:58 pm
Hello,

on my new SL-C3100 with Cacko 1.23 the "/" and "," key codes seem to be reversed.
Pushing the / key, I get a /.
Pushing Shift-/ I get a ,.

That's probably how the key is intended to be used, but in Cacko 1.23b1 on the SL-C3000 I had it the other way around, which is good for writing texts.

How can I change that in Cacko 1.23?

I have already removed and reinserted the section

Code: [Select]

 
  
  
  
  

 
  
  
  
  

 
  
  
  
  

and reloaded keyhelper, but to no avail. The keys are always reversed, no matter if I have this section in keyhelper.xml or not.
What setting may be overlaying this?

I have set German and US key mappings in keyboard setting, for fast switching on the symbol in the tray right besides the clock.

Thanks!
daniel
Title: Exchanging "/" And ","
Post by: bam on April 24, 2006, 01:33:20 pm
look into /home/QtPalmtop/etc/keycode.tbl
Title: Exchanging "/" And ","
Post by: tombraider on April 24, 2006, 05:56:04 pm
I have the same wish...to switch the forward slash and comma;  I looked at keycode.tbl, but don't know what to do with it.

Can someone give me a clue?

Thanks.  
 
Quote
look into /home/QtPalmtop/etc/keycode.tbl
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124396\"][{POST_SNAPBACK}][/a][/div]
Title: Exchanging "/" And ","
Post by: Meanie on April 24, 2006, 10:14:56 pm
Quote
Hello,

on my new SL-C3100 with Cacko 1.23 the "/" and "," key codes seem to be reversed.
Pushing the / key, I get a /.
Pushing Shift-/ I get a ,.

That's probably how the key is intended to be used, but in Cacko 1.23b1 on the SL-C3000 I had it the other way around, which is good for writing texts.

How can I change that in Cacko 1.23?

I have already removed and reinserted the section

Code: [Select]

 
  
  
  
  

 
  
  
  
  

 
  
  
  
  

and reloaded keyhelper, but to no avail. The keys are always reversed, no matter if I have this section in keyhelper.xml or not.
What setting may be overlaying this?

I have set German and US key mappings in keyboard setting, for fast switching on the symbol in the tray right besides the clock.

Thanks!
daniel
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124391\"][{POST_SNAPBACK}][/a][/div]

just remove that section and restart keyhelper. the default setting is that the /, key produces , and / is produced with shift mode. the above code section switches it around.
Title: Exchanging "/" And ","
Post by: daniel3000 on April 25, 2006, 04:55:24 am
Quote
just remove that section and restart keyhelper. the default setting is that the /, key produces , and / is produced with shift mode. the above code section switches it around.
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124432\"][{POST_SNAPBACK}][/a][/div]

Hi Meanie,

I did exactly that, but after a khctl reload the key still produces the slash without shift... There must be another place where this is set.
keycode.tbl is somewhat cryptic. There is an entry for Key_Slash, but I don't know exactly what to do there.

Thanks!
daniel
Title: Exchanging "/" And ","
Post by: Meanie on April 25, 2006, 06:33:18 am
Quote
Quote
just remove that section and restart keyhelper. the default setting is that the /, key produces , and / is produced with shift mode. the above code section switches it around.
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124432\"][{POST_SNAPBACK}][/a][/div]

Hi Meanie,

I did exactly that, but after a khctl reload the key still produces the slash without shift... There must be another place where this is set.
keycode.tbl is somewhat cryptic. There is an entry for Key_Slash, but I don't know exactly what to do there.

Thanks!
daniel
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124457\"][{POST_SNAPBACK}][/a][/div]

reload wont help you because you removed something and not added something. does the key work correctly if you turn off keyhelper? you might need to disable keyhelper, reboot and then reload keyhelper.
Title: Exchanging "/" And ","
Post by: daniel3000 on April 25, 2006, 07:42:52 am
Quote
reload wont help you because you removed something and not added something. does the key work correctly if you turn off keyhelper? you might need to disable keyhelper, reboot and then reload keyhelper.
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124471\"][{POST_SNAPBACK}][/a][/div]


If I type khctl disable, the key works as I want it to work.
Subsequent reboot does NOT help, though: After the reboot, keyhelper is enabled again and the key again works as it should NOT do.

I'm stuck - why doesn't keyhelper accept my change? Is there another file which keyhelper uses?

I did another change: I inserted a mapping for Shift-Space to generate a space rather than the pipe symbol (because I accidentally hit Shift-Space a lot of times, especially with sticky shift key). That one works! So the keyhelper.xml file s really used. Strange..

daniel
Title: Exchanging "/" And ","
Post by: Stubear on April 25, 2006, 08:18:00 am
Quote
Quote
reload wont help you because you removed something and not added something. does the key work correctly if you turn off keyhelper? you might need to disable keyhelper, reboot and then reload keyhelper.
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124471\"][{POST_SNAPBACK}][/a][/div]


If I type khctl disable, the key works as I want it to work.
Subsequent reboot does NOT help, though: After the reboot, keyhelper is enabled again and the key again works as it should NOT do.

I'm stuck - why doesn't keyhelper accept my change? Is there another file which keyhelper uses?

Looks like you haven't properly removed the comma - slash switching section. Post you keyhelper.xml and we can have a look at what you might have missed.

Or if you'd rather start with a new empty keyhelper.xml and slowly add back the functionality you want.

Stu
Title: Exchanging "/" And ","
Post by: daniel3000 on April 25, 2006, 10:02:57 am
Quote
Looks like you haven't properly removed the comma - slash switching section. Post you keyhelper.xml and we can have a look at what you might have missed.

Or if you'd rather start with a new empty keyhelper.xml and slowly add back the functionality you want.

Stu
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124486\"][{POST_SNAPBACK}][/a][/div]


I have doucle-checked the syntax and have found no problems with it. But maybe I missed something. Here is my /home/zaurus/Settings/keyhelper.xml file:

Code: [Select]



    
  
      
  

    
  
      
  

    
  
  


  
  






  
  
      
      
      
      
  



  
  
      
          
      
  

  
  
      
      
      
  




    
    



  
  
      
  

  
  
      
  

  
  
  
  

      
  
  
      
  



Any ideas?

Thanks
daniel
Title: Exchanging "/" And ","
Post by: bam on April 25, 2006, 09:10:56 pm
hmmmz, you could probably get a keycode.tbl from the stock rom and replace the one you have, that would do it for you, make sure to make a backup first (of your cacko keycode.tbl)
Title: Exchanging "/" And ","
Post by: daniel3000 on April 26, 2006, 03:45:12 am
Quote
hmmmz, you could probably get a keycode.tbl from the stock rom and replace the one you have, that would do it for you, make sure to make a backup first (of your cacko keycode.tbl)
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124576\"][{POST_SNAPBACK}][/a][/div]

thanks for the idea.
Could someone send me one please (PM)?

What is the relation between keyhelper.xml and keycode.tbl? How does keyhelper work at all? Knowing that would allow me to understand much better what the issue could be.

THanks a lot
daniel
Title: Exchanging "/" And ","
Post by: bam on April 26, 2006, 04:59:04 am
keyhelper intercepts the keypresses then sends out a modified one(if any exists in the keyhelper.xml), basically speaking, but Stubear is much more detailed and knowledgeable than I at this subject.

keycode.tbl is what the os uses at a lower level, this is just a guess.
Title: Exchanging "/" And ","
Post by: daniel3000 on April 26, 2006, 08:42:08 am
Quote
keyhelper intercepts the keypresses then sends out a modified one(if any exists in the keyhelper.xml), basically speaking, but Stubear is much more detailed and knowledgeable than I at this subject.

keycode.tbl is what the os uses at a lower level, this is just a guess.
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124621\"][{POST_SNAPBACK}][/a][/div]


Well, I meant more what keyhelper does when configuring the keycode conversion (i.e. e.g. "read in the XML, convert it into keycode.tbl, which is ued by lower system layer..." but that's only my guess yet).

daniel
Title: Exchanging "/" And ","
Post by: Stubear on April 26, 2006, 10:15:06 am
Sorry, my bad. I had forgotten that Anton had integrated keyhelper with cyrinput and that some of the keyhelper stuff is over-ridden by the cyrinput settings.

To get get slash and comma back to their default settings and to keep keyhelper working you will need to edit the "english" file in /home/zaurus/Application/cyrillica.

This is the default input method used by cyrinput for Cacko, if you have changed that using the Keyboard app in the Settings tab then you will need to edit that language file.

Anyway, a quick overview of what is happening with keypresses in Cacko (at least my understanding of it anyway).

Cyrinput (called CyrKeyboard in the input methods menu) parses the default language file in /home/zaurus/Application/cyrillica. This file has 4 sections [label], [screen], [keyboard] and [keyboard-fn]. The [screen] section maps out the onscreen keyboard seen when you select CyrKeyboard as an input method, the [keyboard] and [keyboard-fn] are used for the physical keyboard.

If you look at the default english file the keyboard section is
Code: [Select]
[keyboard]
','  ','  '/'
'/'  ','  ','
'?'  '?' '.'
0   0   0

which from a very dusty memory (search for cyrinput on the forums for a long thread on the layout of this file) tells cryinput to map slash to comma and comma to slash. If you want to do some other mappings here the order is
'original key'   'new value with shift'  'new value'
Not sure why the second line is '/' ',' ',' and not '/' '/' ',' but hey it works

These values overide anything that is mapped in keyhelper.xml, that is why you still see the slash-comma reversal after you edit keyhelper.xml.

to get your desired effect, remove the first 2 lines in the [keyboard] section and reboot.

Stu
Title: Exchanging "/" And ","
Post by: daniel3000 on April 26, 2006, 11:04:26 am
Quote
to get your desired effect, remove the first 2 lines in the [keyboard] section and reboot.
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124652\"][{POST_SNAPBACK}][/a][/div]


THANKS!!

Partial success.

I use the English and German layout via fast-switch. The "english" is now fixed. If english is activated I have the desired behavior.
However, I also removed these lines from the "german" file, but in the german keyboard setting the ke functions are still reversed...

The only difference of the two files is the [keybord-fn] section, which in the english file contains only "0 0 0" but in the german file it contains some lines with key codes:

Code: [Select]
[keybord-fn]
0x201b 0x20ac 0x20ac #euro
0x200a 0xd6 0xf6
0x200b 0xdc 0xfc
0x200c 0xc4 0xe4
0x2007 0xdf 0xdf
#0x2008 0  0
0 0 0

Could there be another mapping inside this code block?
BTW: How can I determine the codes of the keys?


Another question:
In about one year of heavy daily Zaurus usage I have never used that virtual keyboard or any other of these virtual input methods (only the physical keyboard). Is there a way to remove them cleanly from the entire system (and thus to avoid such kinds of problems)?


thanks again

daniel
Title: Exchanging "/" And ","
Post by: bam on April 26, 2006, 10:05:51 pm
cool now I know how the cacko keyboard control works, time for some nice editing...
Title: Exchanging "/" And ","
Post by: daniel3000 on April 27, 2006, 03:49:13 am
Quote
THANKS!!

Partial success.
[div align=\"right\"][a href=\"index.php?act=findpost&pid=124664\"][{POST_SNAPBACK}][/a][/div]


Never mind... I found the problem.
There are two files for the German keyboard: "german" and "deutsch". I edited the "german" but used the "deutsch".  

Now I edited both and it works like a charm.
Thanks for all your help!

daniel
Title: Exchanging "/" And ","
Post by: sdjf on May 30, 2006, 07:51:48 pm
Trying to see if keyhelper will work on my sl5500.  It installed okay from the command line, but the keyhelper GUI with all those boxes don't recognize anything I enter from the keyboard although tapping on the boxes with my stylus does move the cursor.

I tried using khctl to see if that would work and what I get is:

May30# khctl
bash: khctl: command not found
May30#  

May30# khctl reload
bash: khctl: command not found
May30#  

Is this a lost cause until someone ports it for the sl5xxx keyboards?  Has anybody already?

What I have is  (couldn't figure out how to download a more recent version if there is one):
    keyhelperconf_0.3.0-1_arm.ipk

Really could use this app.

Thanks,
sdjf
Title: Exchanging "/" And ","
Post by: Snappy on June 03, 2006, 10:08:08 pm
Neat! I commented out the mappings in
/home/zaurus/Settings/keyhelper.xml

and removed the two lines in
/home/zaurus/Application/cyrillica/english
[keyboard]
','  ','  '/' <-- remove
'/'  ','  ',' <-- remove

and it works fine in Cacko already.

I use English primarily but read and input Chinese characters occasionally.
Title: Exchanging "/" And ","
Post by: sdjf on June 04, 2006, 02:05:25 pm
Somebody please help!

Downloaded the keyhelper auxiliary ipk from bam's
http://www.thegrinder.ws/main/downloadable...1.2.2-1_arm.ipk (http://www.thegrinder.ws/main/downloadables/keyhelper_1.2.2-1_arm.ipk)
 so the GUI's boxes now recognize me pressing keys, but I still don't have a clue how to use this thing.

Well, I've got a lot of clues from Introduction_to_KeyHelper, but it's still pretty confusing.

I've written an earlier post in this thread and in another with more specific questions about writing the xml file, explaining what I want keyhelper to do for me, and they still are up in the air.

At least there's some progress, but I'm stuck.

sdjf
Title: Exchanging "/" And ","
Post by: tombraider on June 04, 2006, 02:57:06 pm
This worked for me also.  I have been struggling with this FOREVER.

A big THANK YOU to Stubear.

Quote
Neat! I commented out the mappings in
/home/zaurus/Settings/keyhelper.xml

and removed the two lines in
/home/zaurus/Application/cyrillica/english
[keyboard]
','  ','  '/' <-- remove
'/'  ','  ',' <-- remove

and it works fine in Cacko already.

I use English primarily but read and input Chinese characters occasionally.
[div align=\"right\"][a href=\"index.php?act=findpost&pid=129670\"][{POST_SNAPBACK}][/a][/div]
Title: Exchanging "/" And ","
Post by: sdjf on June 05, 2006, 05:26:35 am
Okay, I've got keyhelperconf installed, and figured out the folllowing sequence enables me to load without a "Load Error".

khctl disable
khctl enable
khctl load keyhelperconf.xml

However, the following simple xml file I wrote, just to start with, has no effect on the mapping of the \ I'm going for.

<?xml version="1.0"?>
<keyhelper>
<modifiers>
<define key="Control" type="Control" toggle="True"/>
<define key="Alt" type="Alt" toggle="True"/>
</modifiers>
<mappings>

<define key="/">
<modifier Control="On"/>
<map code="0092"/>
<map_unicode char="\"/>
<map_modifier Control="Off"/>
</define>
</mappings>
<repeater>
</repeater>
<extensions>
</extensions>
</keyhelper>

I tried instead with NumLock (which is [ctl] + [/] on sl5500) instead of / and no change either.  What's wrong here?

sdjf
Title: Exchanging "/" And ","
Post by: Snappy on June 05, 2006, 08:17:15 am
Should it perhaps be:

<define key="Slash">   <----- and not "/"
<modifier Control="On"/>
<map code="0092"/>
<map_unicode char="\"/>
<map_modifier Control="Off"/>
</define>
Title: Exchanging "/" And ","
Post by: sdjf on June 05, 2006, 03:24:51 pm
Quote
Should it perhaps be:

<define key="Slash">   <----- and not "/"
<modifier Control="On"/>
<map code="0092"/>
<map_unicode char="\"/>
<map_modifier Control="Off"/>
</define>
[div align=\"right\"][a href=\"index.php?act=findpost&pid=129864\"][{POST_SNAPBACK}][/a][/div]
Snappy,

Nope, same as before, I get a NumLock. I mean, when I enter Ctrl+/ I end up with the Numlock icon character showing and I get numbers and symbols when I hit any key, as usual before keyhelper.

So, looked more carefully.  When I enter my Fn key into the GUI (the control for the sl5500) I get F22 in the K box and ffff in the U box.   Not sure what that means, but does that info help?

Maybe I need to remap F22 to be Control?  Wierd as my Z knows it's a control..  

So I tried using F22 instread of Control in the Modifiers section, and that totally made the GUI stop working even when I disabled khctl.  But I didn't use a line saying 'Release Key ' because I didn't know what to put there and I don't have any official function keys on this keybooard to my knowledge.

What does the <Release key=...> line do?

Thanks,
sdjf