You are not logged in.

#1 2020-02-13 21:11:12

copygirl
Member
Registered: 2020-02-13
Posts: 1

Panasonic Toughbook CF-C2 buttons incorrectly recognized

I recently got gifted a lovely Panasonic Toughbook CF-C2 laptop and after some problem-solving got it to run pretty well. However, now that I'm trying to set up some of the 6 extra buttons on the lid itself (see picture), I'm running into more issues and seeing that perhaps my earlier issues are connected with my inability to set up these buttons.

- As soon as the laptop booted into the login prompt (not from install USB drive), it thought the hibernate key was pressed multiple times.
- When the lid was turned around into "tablet mode" and then raised, it thought the suspend key was pressed.

I have mediated these problems by disabling the hibernate and suspend keys in /etc/systemd/logind.conf:

HandleSuspendKey=ignore
HandleHibernateKey=ignore

Now, the 6 additional keys work the following way:

- Windows key counts as KEY_LEFTMETA, however press+release occur simultaneously when the button is physically released. Oddly enough this makes my keyboard shortcut application not recognize the button but the binding still works when I use the regular Windows button on the keyboard to set it.
- Volume keys work as expected, thankfully. (phew)
- Screen rotation key is also recognized as KEY_LEFTMETA, making it useless for binding a screen rotation script to.
- A1 and A2 buttons are not recognized at all.

Here is the output of "xinput list":

⎡ Virtual core pointer                          id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]
⎜   ↳ Wacom ISDv4 101 Pen stylus                id=11   [slave  pointer  (2)]
⎜   ↳ SynPS/2 Synaptics TouchPad                id=13   [slave  pointer  (2)]
⎜   ↳ Wacom ISDv4 101 Pen eraser                id=15   [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)]
    ↳ Power Button                              id=8    [slave  keyboard (3)]
    ↳ USB2.0 Camera: USB2.0 Camera              id=9    [slave  keyboard (3)]
    ↳ USB HD Webcam: USB HD Webcam              id=10   [slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard              id=12   [slave  keyboard (3)]
    ↳ Panasonic Laptop Support                  id=14   [slave  keyboard (3)]

Here is some output from "evtest" (run in virtual terminal (Ctrl+Alt+F2) just in case):

## Device: "AT Translated Set 2 keyboard"

# Keyboard Windows button
type 4 (EV_MSC), code 4 (MSC_SCAN), value db
type 1 (EV_KEY), code 125 (MSC_LEFTMETA), value 1
------------- SYN_REPORT -------------
type 4 (EV_MSC), code 4 (MSC_SCAN), value db
type 1 (EV_KEY), code 125 (MSC_LEFTMETA), value 0
------------- SYN_REPORT -------------

# Lid Windows button:
type 4 (EV_MSC), code 4 (MSC_SCAN), value db
type 1 (EV_KEY), code 125 (MSC_LEFTMETA), value 1
------------- SYN_REPORT -------------
type 4 (EV_MSC), code 4 (MSC_SCAN), value db
type 1 (EV_KEY), code 125 (MSC_LEFTMETA), value 0
------------- SYN_REPORT -------------

# Screen rotate button:
type 4 (EV_MSC), code 4 (MSC_SCAN), value db
type 1 (EV_KEY), code 125 (MSC_LEFTMETA), value 1
------------- SYN_REPORT -------------
type 4 (EV_MSC), code 4 (MSC_SCAN), value 65
------------- SYN_REPORT -------------
type 4 (EV_MSC), code 4 (MSC_SCAN), value 65
------------- SYN_REPORT -------------
type 4 (EV_MSC), code 4 (MSC_SCAN), value db
type 1 (EV_KEY), code 125 (MSC_LEFTMETA), value 0
------------- SYN_REPORT -------------

# A1 and A2 buttons:
# ... Nothing.


## Device: "Panasonic Laptop Support"

# Keyboard and lid Windows buttons:
# Nothing, and that's okay.

# Screen rotate button:
type 4 (EV_MSC), code 4 (MSC_SCAN), value 04
------------- SYN_REPORT -------------
type 4 (EV_MSC), code 4 (MSC_SCAN), value 05
------------- SYN_REPORT -------------

# A1 and A2 buttons:
# ... Nothing, again.

(I haven't included the volume keys as they're working correctly.)

Now I've found out that I am not the only one who had this problem, there was also a user on reddit and I've found this article that mentions similar problems with a different model (CF-18) and operating system (Xubuntu). I've also found what I think is the associated GitHub repository to the solution provided in the article.

The mentioned article resorts to, from my understanding, building a custom device driver and installing it. Now, I'm not quite ready to go ahead and try that right away, especially since I lack any experience on that matter. I wanted to ask for advice first. I imagine this driver would not solve all of the problems I've had instantly, as its made for a different model, with different keys. I'm also wondering about the hibernate and suspend keys being "pressed". Perhaps those are meant to be "laptop" and "tablet" mode key events. Is the "Panasonic Laptop Support" driver flawed? Should I look into patching together my own driver in addition to it? Where would I even be looking for the device IDs and keymap values?

Any pointers would be appreciated.
(As my first post, I hope I did alright.)

Thank you!

Last edited by copygirl (2020-02-13 21:14:34)

Offline

Board footer

Powered by FluxBB