Multimedia keys and Xfce

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Multimedia keys and Xfce

Pétùr
Hello,

I have a keyboard with some multimedia keys. These were working until
recently. I binded them to "mpc next" "mpc prev", etc... to use it with
mpd.

Now I have no reaction when pushing "prev" "next" "stop/play" keys (all
mpc commands). The same command launched from a terminal are working
(and use to work with the keys).

Any idea why it is not working anymore? I checked apt log but couldn't
find removing of package linked (and I don't really know when it starts
not working).

Pétùr
_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org
Reply | Threaded
Open this post in threaded view
|

Re: Multimedia keys and Xfce

Pétùr
No one else is experiencing the same bug?

Le 23/03/2019 à 10:31, Pétùr a écrit :

> Hello,
>
> I have a keyboard with some multimedia keys. These were working until
> recently. I binded them to "mpc next" "mpc prev", etc... to use it with
> mpd.
>
> Now I have no reaction when pushing "prev" "next" "stop/play" keys (all
> mpc commands). The same command launched from a terminal are working
> (and use to work with the keys).
>
> Any idea why it is not working anymore? I checked apt log but couldn't
> find removing of package linked (and I don't really know when it starts
> not working).
>
> Pétùr

_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org
Reply | Threaded
Open this post in threaded view
|

Re: Multimedia keys and Xfce

Fabrice Delliaux
Le 11/04/19 à 13:41, Pétùr a tapoté :

> No one else is experiencing the same bug?
>
> Le 23/03/2019 à 10:31, Pétùr a écrit :
> > Hello,
> >
> > I have a keyboard with some multimedia keys. These were working
> > until recently. I binded them to "mpc next" "mpc prev", etc... to
> > use it with mpd.
> >
> > Now I have no reaction when pushing "prev" "next" "stop/play" keys
> > (all mpc commands). The same command launched from a terminal are
> > working (and use to work with the keys).
> >
> > Any idea why it is not working anymore? I checked apt log but
> > couldn't find removing of package linked (and I don't really know
> > when it starts not working).
> >
> > Pétùr

Have you tried to run xev to test if you correctly get those events ?
You should find something like this when pressing/releasing keys :

> KeyPress event, serial 38, synthetic NO, window 0x5600001,
>     root 0x1de, subw 0x0, time 18479792, (488,-94), root:(1239,350),
>     state 0x10, keycode 174 (keysym 0x1008ff15, XF86AudioStop),
>        same_screen YES, XLookupString gives 0 bytes: XmbLookupString
>     gives 0 bytes: XFilterEvent returns: False
>
> KeyRelease event, serial 38, synthetic NO, window 0x5600001,
>     root 0x1de, subw 0x0, time 18479792, (488,-94), root:(1239,350),
>     state 0x10, keycode 174 (keysym 0x1008ff15, XF86AudioStop),
>        same_screen YES, XLookupString gives 0 bytes: XFilterEvent
> returns: False

If you get the events, it seems that some applications can hijack the
media events, like chrome :

        https://bbs.archlinux.org/viewtopic.php?id=207360

Good luck.
_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org
Reply | Threaded
Open this post in threaded view
|

Re: Multimedia keys and Xfce

Pétùr
Le 11/04/2019 à 14:28, Fabrice Delliaux a écrit :

> Have you tried to run xev to test if you correctly get those events ?
> You should find something like this when pressing/releasing keys :
>
>> KeyPress event, serial 38, synthetic NO, window 0x5600001,
>>     root 0x1de, subw 0x0, time 18479792, (488,-94), root:(1239,350),
>>     state 0x10, keycode 174 (keysym 0x1008ff15, XF86AudioStop),
>>        same_screen YES, XLookupString gives 0 bytes: XmbLookupString
>>     gives 0 bytes: XFilterEvent returns: False
>>
>> KeyRelease event, serial 38, synthetic NO, window 0x5600001,
>>     root 0x1de, subw 0x0, time 18479792, (488,-94), root:(1239,350),
>>     state 0x10, keycode 174 (keysym 0x1008ff15, XF86AudioStop),
>>        same_screen YES, XLookupString gives 0 bytes: XFilterEvent
>> returns: False

Thanks!

xev doesn't recognize my multimedia keys. I have for each key:


FocusOut event, serial 37, synthetic NO, window 0x6800001,
    mode NotifyGrab, detail NotifyAncestor

FocusIn event, serial 37, synthetic NO, window 0x6800001,
    mode NotifyUngrab, detail NotifyAncestor

KeymapNotify event, serial 37, synthetic NO, window 0x0,
    keys:  2   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0
           0   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0


*but* I doesn't prevent the volume keys to works perfectly. And the
prev/next/toggle which are not working are "active". If I press to one
of them while a terminal is opened, the cursor blinks.

And if I use a  multimedia keys as shortcut in the Xfce keyboard
shortcut interface, I have the name "XF86AudioNext" appearing (but the
shortcut doesn't work).


> If you get the events, it seems that some applications can hijack the
> media events, like chrome :
>
> https://bbs.archlinux.org/viewtopic.php?id=207360

Maybe. Maybe also I have something not installed?

I have two computers (laptop + tower) with the same model of keyboard,
both running debian sid and xfce.

On my tower, prev/next/toggle works (they launch mpc next/prev/toggle).
On the laptop, they don't. The laptop has a built-in keyboard with
multimedia keys (FN+...) which works, maybe it is related.
_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org
Reply | Threaded
Open this post in threaded view
|

Re: Multimedia keys and Xfce

houghi
On 2019-04-16 11:23, Pétùr wrote:

>
> Thanks!
>
> xev doesn't recognize my multimedia keys. I have for each key:

Yes, it does.

>
> FocusOut event, serial 37, synthetic NO, window 0x6800001,
>     mode NotifyGrab, detail NotifyAncestor
>
> FocusIn event, serial 37, synthetic NO, window 0x6800001,
>     mode NotifyUngrab, detail NotifyAncestor
>
> KeymapNotify event, serial 37, synthetic NO, window 0x0,
>     keys:  2   0   0   0   0   0   0   0   0   0   0   0   0   0   0  
> 0
>            0   0   0   0   0   0   0   0   0   0   0   0   0   0   0  
> 0

If it wouldn't, you would get nothing. The keys just do not do what you
want them to do.
_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org
Reply | Threaded
Open this post in threaded view
|

Re: Multimedia keys and Xfce

Pétùr
In fact, the next/prev/toggle keys works time to time.

It is really weird: I reboot, the play/pause key was working (mpc
toggle). I rebooted, none of the prev/next/toggle was working. I
rebooted again, only the next is working now...

Any idea?

Le 16/04/2019 à 11:47, houghi a écrit :

> On 2019-04-16 11:23, Pétùr wrote:
>
>>
>> Thanks!
>>
>> xev doesn't recognize my multimedia keys. I have for each key:
>
> Yes, it does.
>
>>
>> FocusOut event, serial 37, synthetic NO, window 0x6800001,
>>     mode NotifyGrab, detail NotifyAncestor
>>
>> FocusIn event, serial 37, synthetic NO, window 0x6800001,
>>     mode NotifyUngrab, detail NotifyAncestor
>>
>> KeymapNotify event, serial 37, synthetic NO, window 0x0,
>>     keys:  2   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0
>>            0   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0
>
> If it wouldn't, you would get nothing. The keys just do not do what you
> want them to do.
> _______________________________________________
> Xfce mailing list
> [hidden email]
> https://mail.xfce.org/mailman/listinfo/xfce
> http://www.xfce.org

_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org
Reply | Threaded
Open this post in threaded view
|

Re: Multimedia keys and Xfce

houghi
On 2019-04-16 15:41, Pétùr wrote:
> In fact, the next/prev/toggle keys works time to time.
>
> It is really weird: I reboot, the play/pause key was working (mpc
> toggle). I rebooted, none of the prev/next/toggle was working. I
> rebooted again, only the next is working now...
>
> Any idea?

Faulty keyboard?

houghi
_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org
Reply | Threaded
Open this post in threaded view
|

Re: Multimedia keys and Xfce

Wojciech S. Czarnecki
In reply to this post by Pétùr
On Tue, 16 Apr 2019 15:41:45 +0200
Pétùr <[hidden email]> wrote:

> Any idea?

Something is messing with your keyboard map likely.

After reboot open console and do fresh dump:
~$ xmodmap -pke > after_reboot_xmodmap

Then after your keys stopped working as expected
do next dump

~$ xmodmap -pke > wrongmedia_xmodmap

Then do diff:

diff -U0 after_reboot_xmodmap wrongmedia_xmodmap

If these two dumps differ, you may start to search for culprit within
programs/scripts ran inbetween.

If these two are identical it looks 1-unfortunate, or 2-dim, or 3-doom.

1. your hw at some point went astray. It happened with some Acers where media keys
were at chord with 'Fn'. Box somewhat changed scancodes after unknown to
me Fn-something slip.

2. you activated some kind of 'User Experience Feedback' (Chrome?) that mess.

3. you've got a rootkit/trojan with buggy keylogger


Hope this helps,


--
Wojciech S. Czarnecki
 << ^oo^ >> OHIR-RIPE
_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org
Reply | Threaded
Open this post in threaded view
|

Re: Multimedia keys and Xfce

Pétùr
Thanks a lot for this.

The diff shows no difference even when a key works, and then does not
work after a reboot. the change of behavior appears only when rebooting.

Like I have the two same keyboards (logitech K780), I tried to plug the
older keyboard to my laptop. And it multimedia keys works !

To sum up :

- newer K780 keyboard + laptop : bug with multimedia keys
- old K780 keyboard + laptop or tower : ok

I used a windows computer to install the logitech software. It shows the
older keyboard run firmware 001.004.00028 when newer uses 001.005.00029.

I think this explains the issue. The newer version seems not completely
recognize by linux kernel (I guess). I use 4.19.0-4-amd64.

I also installed last git version of Solaar
(https://pwr.github.io/Solaar/) but it doesn't change this.

Pétùr


Le 17/04/2019 à 02:05, Wojciech S. Czarnecki a écrit :

> On Tue, 16 Apr 2019 15:41:45 +0200
> Pétùr <[hidden email]> wrote:
>
>> Any idea?
>
> Something is messing with your keyboard map likely.
>
> After reboot open console and do fresh dump:
> ~$ xmodmap -pke > after_reboot_xmodmap
>
> Then after your keys stopped working as expected
> do next dump
>
> ~$ xmodmap -pke > wrongmedia_xmodmap
>
> Then do diff:
>
> diff -U0 after_reboot_xmodmap wrongmedia_xmodmap
>
> If these two dumps differ, you may start to search for culprit within
> programs/scripts ran inbetween.
>
> If these two are identical it looks 1-unfortunate, or 2-dim, or 3-doom.
>
> 1. your hw at some point went astray. It happened with some Acers where media keys
> were at chord with 'Fn'. Box somewhat changed scancodes after unknown to
> me Fn-something slip.
>
> 2. you activated some kind of 'User Experience Feedback' (Chrome?) that mess.
>
> 3. you've got a rootkit/trojan with buggy keylogger
>
>
> Hope this helps,
>
>

_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org
Reply | Threaded
Open this post in threaded view
|

Firmware update of Logitech K780 (was: Multimedia keys and Xfce)

Paul Menzel
Dear Pétùr,


On 04/18/2019 11:11 AM, Pétùr wrote:

[…]

> To sum up :
>
> - newer K780 keyboard + laptop : bug with multimedia keys
> - old K780 keyboard + laptop or tower : ok
>
> I used a windows computer to install the logitech software. It shows the
> older keyboard run firmware 001.004.00028 when newer uses 001.005.00029.
>
> I think this explains the issue. The newer version seems not completely
> recognize by linux kernel (I guess). I use 4.19.0-4-amd64.
By the way, this keyboard seems to be supported by the Linux Vendor
Firmware Service [1]. So you should be able to use `fwupdmgr refresh` and
`fwupdmgr update` to update the firmware.

The uploaded versions look older than the ones you have though.

Version MPK01.02_B0021
Version MPK01.03_B0024

Some desktop environments also integrate that in their graphical update
applications.


Kind regards,

Paul


[1]: https://fwupd.org/lvfs/device/com.logitech.MPK01.firmware


_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org

smime.p7s (6K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Multimedia keys and Xfce

Pétùr
In reply to this post by Pétùr
Le 18/04/2019 à 11:11, Pétùr a écrit :
> Like I have the two same keyboards (logitech K780), I tried to plug the
> older keyboard to my laptop. And it multimedia keys works !

Update: Correction, both keyboards are affected. Multimedia keys doesn't
function properly.

Since xmodmap shows no difference when these keys works as espected and
when they don't, I have most likely something which messed with the
keyboard.

I am trying to disable everything automatically launched when Xfce
starts.

Any idea about the origin of interference? (I am not using chrome, the
issue occurres even before launching any program so it must be some
library or startup launch).
_______________________________________________
Xfce mailing list
[hidden email]
https://mail.xfce.org/mailman/listinfo/xfce
http://www.xfce.org