Page 1 of 2 12 LastLast
Results 1 to 10 of 18

Thread: Lenovo X230 Tablet Functionality on 12.04

  1. #1
    Join Date
    Oct 2012
    Beans
    9

    Lenovo X230 Tablet Functionality on 12.04

    So I've been plugging away at getting the full tablet functionality and some specific things d

    one on this brand new Laptop, and I am kind of stumped. I've done searches but I can't find anything to reactivating the buttons that are associated with the x230t's touchpad.

    The original purpose of the buttons were:

    Power Button
    Ctrl-Alt-Delete
    Rotate Screen

    What I did was research how to identify these buttons in ubuntu and I went to kern.log.

    So here's what kern.log returns.

    Oct 21 00:19:06 DustWarband kernel: [23053.891039] atkbd serio0: Unknown key released (translated set 2, code 0x6c on isa0060/serio0).
    Oct 21 00:19:06 DustWarband kernel: [23053.891046] atkbd serio0: Use 'setkeycodes 6c <keycode>' to make it known.
    Oct 21 00:19:05 DustWarband kernel: [23052.999808] atkbd serio0: Unknown key released (translated set 2, code 0x67 on isa0060/serio0).
    Oct 21 00:19:05 DustWarband kernel: [23052.999815] atkbd serio0: Use 'setkeycodes 67 <keycode>' to make it known.
    the 6c part comes up for both the power off and screen rotate button
    67 comes up for the ctr-alt-delete button.

    So my question is how do I better identify the keys? and how would I go about attaching appropriate action to them? And has all this been done before.

    Also as reference, this is xinput:

    ⎡ Virtual core pointer id=2 [master pointer (3)]
    ⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
    ⎜ ↳ Logitech Unifying Device. Wireless PID:1025 id=9 [slave pointer (2)]
    ⎜ ↳ Wacom ISDv4 E6 Pen stylus id=10 [slave pointer (2)]
    ⎜ ↳ Wacom ISDv4 E6 Finger touch id=11 [slave pointer (2)]
    ⎜ ↳ SynPS/2 Synaptics TouchPad id=13 [slave pointer (2)]
    ⎜ ↳ Wacom ISDv4 E6 Pen eraser id=15 [slave pointer (2)]
    ⎜ ↳ TPPS/2 IBM TrackPoint id=16 [slave pointer (2)]
    ⎣ Virtual core keyboard id=3 [master keyboard (2)]
    ↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
    ↳ Power Button id=6 [slave keyboard (3)]
    ↳ Video Bus id=7 [slave keyboard (3)]
    ↳ Sleep Button id=8 [slave keyboard (3)]
    ↳ AT Translated Set 2 keyboard id=12 [slave keyboard (3)]
    ↳ ThinkPad Extra Buttons id=14 [slave keyboard (3)]
    ThinkPad Extra buttons looks, interesting? Any ideas?

  2. #2
    Join Date
    Nov 2008
    Beans
    9,635
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Lenovo X230 Tablet Functionality on 12.04

    Hi Dustpaw,

    Welcome to Ubuntu forums!


    You look to already pretty much have all you need. Normally the thinkwiki.org is a good place to look but I don't see much for your model. There are a couple of pages on hot key activation.

    Anyway information on the bezel buttons is available on the Rotation HOW TO esp. appendix 2 and 3. Also description of how to bind a rotation script to a key.

    ThinkPad Extra Buttons is what Magick Rotation reads to provide automatic rotation for Lenovo tablets: https://launchpad.net/magick-rotation

    Have you found the X230t thread?

  3. #3
    Join Date
    Oct 2012
    Beans
    9

    Re: Lenovo X230 Tablet Functionality on 12.04

    I have not found the x230t thread, but that may just be on the part of poor looking/searching. Do you have a link?

    Thanks for the info from the appendix! should be a good example and I'll take a crack at it later.

    So thinkpad extra buttons records the changes to the screen rotation from the joint on the screen? Interesting...

    Also I just derped into why the power button doesn't appear to return a code of its own, its already implemented, holding it down vs just pressing it.

    Thanks for the info, I'll post back the script and setup in case other users want it for their x230 Tablet.

    While we are here, few extra questions:
    - Cursor change based on input? Is that possible? I liked the snazzy windows cursors they had vs mouse pointer...
    - I notice cellwriter is magick rotations "suggested" is that accepted as the standard?
    Last edited by Dustpaw; October 21st, 2012 at 04:54 PM.

  4. #4
    Join Date
    Nov 2008
    Beans
    9,635
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Lenovo X230 Tablet Functionality on 12.04

    Sorry, I meant the X220t thread: http://ubuntuforums.org/showthread.php?t=1785015 Since there doesn't seem to be much on the X230t yet I figured some of the X220t stuff might apply.
    So thinkpad extra buttons records the changes to the screen rotation from the joint on the screen? Interesting...
    We don't actually know where the switch is physically. For convenience we act as if it is in the hinge and call it the hinge switch. It may be different for different tablet PCs.
    Also I just derped into why the power button doesn't appear to return a code of its own, its already implemented, holding it down vs just pressing it.

    Cursor change based on input? Is that possible? I liked the snazzy windows cursors they had vs mouse pointer...
    Don't know, never tried/looked into that.
    I notice cellwriter is magick rotations "suggested" is that accepted as the standard?
    No. Onboard is the Ubuntu default. And many folks prefer one of the other OSK (on screen keyboards) available. However CellWriter is the only one I am aware of that toggles between an OSK and a hand written letter input/recognition mode. Which is why we suggest it for tablet PCs.

  5. #5
    Join Date
    Oct 2012
    Beans
    9

    Re: Lenovo X230 Tablet Functionality on 12.04

    You were a huge help, I decided to utilize easystroke for my gestures (as opposed to ginn). I now have all the applications I do and don't need at startup running and when it switches seems to get everything swapped up the way I want it.

    Now I just need to figure out those two buttons, onto that next.

  6. #6
    Join Date
    Oct 2012
    Beans
    9

    Re: Lenovo X230 Tablet Functionality on 12.04

    Finally getting around to looking at the bezel buttons and I ran into an issue while looking at this:
    http://ubuntuforums.org/showthread.php?t=996830

    I found that there is a previous keymapping for the lenovo tablet that properly maps the keycodes. Here's the cat of the keymap:

    0x5D menu
    0x63 fn
    0x66 screenlock
    0x67 cyclewindows # bezel circular arrow
    0x68 setup # bezel setup / menu
    0x6c direction # rotate screen


    The 0x6c and 0x67 is correct based on what I found to be the keycodes for those particular bezel buttons. My problem is when I try to apply the keymap to the device based it doesn't take.

    I followed the instructions and the dmiencode returns:
    3434CTO

    So I tried altering the rules.d/95-keymap file to include this as the product and properly apply the lenovo keymapping similar to the old thinkpad tablet keymap. Here's what I editted in the 95-keymap.rules file:

    ENV{DMI_VENDOR}=="LENOVO*", ATTR{[dmi/id]product_version}=="3434CTO", ATTR{[dmi/id]product_version}=="3434CTO", RUN+="keymap $name lenovo-thinkpad_x200_tablet"

    What did I miss?

  7. #7
    Join Date
    Nov 2008
    Beans
    9,635
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Lenovo X230 Tablet Functionality on 12.04

    Assuming:
    Code:
    ENV{DMI_VENDOR}=="LENOVO*", KERNELS=="input*", ATTRS{name}=="ThinkPad Extra Buttons", RUN+="keymap $name module-lenovo"
    in the low key code section doesn't cut it then it appears to be this rule:
    Code:
    ENV{DMI_VENDOR}=="LENOVO*", ATTR{[dmi/id]product_version}=="ThinkPad X2[02]* Tablet*", ATTR{[dmi/id]product_version}=="* Tablet", RUN+="keymap $name lenovo-thinkpad_x200_tablet"
    in the high key code section. Further assuming the product_version's naming conventions are the same (HP uses product_name) then you should just need to change [02] to [023].
    Code:
    ENV{DMI_VENDOR}=="LENOVO*", ATTR{[dmi/id]product_version}=="ThinkPad X2[023]* Tablet*", ATTR{[dmi/id]product_version}=="* Tablet", RUN+="keymap $name lenovo-thinkpad_x200_tablet"
    That will match a ThinkPad X20*, X22*, or X23* to lenovo-thinkpad_x200_tablet in /lib/udev/keymaps.
    Last edited by Favux; November 11th, 2012 at 10:24 PM.

  8. #8
    Join Date
    Oct 2012
    Beans
    9

    Re: Lenovo X230 Tablet Functionality on 12.04

    Was I wrong in using the dmiencode results of "3434CTO" in the keymap rules?

  9. #9
    Join Date
    Nov 2008
    Beans
    9,635
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Lenovo X230 Tablet Functionality on 12.04

    Don't know for sure. Don't see an example of using baseboard-product-name in 95-keymap.rules. I doubt using:
    Code:
    ATTR{[dmi/id]product_version}=="3434CTO"
    is going to work and I don't know why you repeated it. Not sure what the ATTR syntax is for baseboard-product-name. Maybe?
    Code:
    ATTR{[dmi/id]board_name}=="3434CTO"
    Do you see board_name in /sys/class/dmi/id? And it says "3434CTO"?

  10. #10
    Join Date
    Oct 2012
    Beans
    9

    Re: Lenovo X230 Tablet Functionality on 12.04

    That's correct, same for the product name.

    My understanding was that the rules noted in the 95-keymap are compared to board/product name and the keymaps are then applied. Is that incorrect?

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •