fedops blog

Privacy in Computing

Sat 16 June 2018

Quick Tip - Logitech MX 2 Master under X/Wayland

Posted by fedops in Hardware   

There are lots of mice on the market, but Logitech are my favorites. I like the ergonomic design of their larger mice that fits my hands well, for the most part. Which is why I bought an MX2 Master.

Most mice manufacturers try to distance themselves from the rest by introducing fancy extra features. Some of them are actually useful, while others are just gimmicks. The MX2 is missing a few that would be nice to have, for example a slot to store the Unify receiver when not in use and the tilting scroll wheel. The latter is present even on their basic $8 models and I really miss it.

The next best replacement are the two small thumb buttons which can be used to provide back/forward functions in a web browser. To do so, add the following lines to your .xbindkeysrc:

$ cat .xbindkeysrc
###########################
# xbindkeys configuration #
###########################

# Logitech MX Master 2S
#
# Page-back on thumb button down
"xte 'keydown Alt_L' 'key Left' 'keyup Alt_L'"
  b:7

# Page-forward on thumb button up
"xte 'keydown Alt_L' 'key Right' 'keyup Alt_L'"
  b:6

##################################
# End of xbindkeys configuration #
##################################

With Fedora on the Asus UX410 the MX2 works fine via Bluetooth and without the Logitech receiver. There is an applications called Solaar which can be used to configure a few settings on the mouse, but it doesn't work reliably for me. The one nice feature is the battery charge display; however, the MX2 has three physical LEDs for that so I can do without. YMMV.