Apple magic trackpad linux

Apple hardware and Linux

Part 2: Magic Trackpad and Apple Bluetooth Keyboard

Nov 26, 2018 · 4 min read

This is part of my series of “Moving to Linux” posts. It might be useful to read the introductory post to understand the context.

This post is about input devices: Apple’s Magic Trackpad and the Apple Bluetooth Keyboard. I’ve already written a post in which I talked about configuring the internal touchpad of my Linux laptop. At the same time I wanted to make an external Bluetooth mouse work for my left-handed requirements.

That little and cheap black Bluetooth mouse from that post mentioned above was always meant to be a stop-gap measure. I got it at Saturn in Germany for 4,99 Euros because I got the laptop fresh from there and needed some kind of mouse.

When working on my Apple hardware, I’d usually use a Magic Mouse on the iMac and the Magic Trackpad with a wired USB keyboard on the Macbook Pro. Additionally to that, I have another Trackpad and/or Apple Bluetooth Keyboard at my co-working space or at a client.

So, over the last couple of days, I tried out various of the setups with my Linux laptop.

I did some research before I even started. I realised that a lot of the posts on askubuntu.com or stackoverflow.com were about old versions of Ubuntu or Linux in general. People sometimes had to go through cumbersome efforts trying to get the Magic Trackpad going at all.

At some point I gave it a go and put both the trackpads and the Bluetooth keyboard into pairing mode. Slightly surprised they right away showed up under their previous names from OS X in the Ubuntu Budgie settings application.

Pairing

Connecting them worked without major problems. The Magic Trackpads didn’t need any verification at all for me. They connected, but it seems that if you get asked for a PIN, the correct one would be four times the digit zero: 0000.

The Apple Bluetooth Keyboard required a PIN on first pairing. Ubuntu popped up a dialog asking for it as part of the pairing. I entered it on the keyboard itself, pressed and the pairing was completed.

Stability

It seems the Linux laptop behaves a bit more fiddly and flaky when it comes to connecting to the Apple gear. Not in a way that it’d be unusable, but in particular the pairing at my co-working space took quite a long time. The huge amounts of frequency pollution played a part in that. Pairing another trackpad at home was instant. I also found it useful to make sure that the Apple Bluetooth gear was disconnected from the Macbook Pro.

During ongoing use, it seems that it briefly disconnects and reconnects more often than before when I’m at the co-working space. I’m not seeing this at home. I had noticed this behaviour in noisy and polluted environments on the Mac before, but it seems to have increased with the changeover to Linux. I’m not sure if there’s anything that I can configure to alter this behaviour . It’s not even close to be annoying enough to bother me.

Читайте также:  Linux поменять оболочку пользователя

Gestures

In a nutshell, the Magic Trackpad is a pointer device and shows up on Linux when calling xinput from a shell. There are many ways people use the trackpad. On OS X and macOS it’s very popular to configure all kinds of two-, three- or even four-finger gestures to improve perceived productivity.

I never used a lot of these gestures because I’m much more into using the keyboard. Essentially for me, the trackpad acted as a simple touchpad, pretty much like a built-in touchpad on a laptop. I used it for primary and secondary clicks, cursor movements and two-finger scrolling. I never got into the elaborate ways people use their touchpads with multiple fingers and pinch/zoom etc.

My current Magic Trackpad on Linux pretty much delivers exactly what I need from this point of view and I’m very happy with that.

There are ways to configure and setup all sorts of gestures for more than two fingers and certain movements. I haven’t looked into them, but there are two tools that look promising:

As a final note: Some of the configuration options for primary and secondary clicks that I mentioned in my previous blog post are valid for the Magic Trackpad, too. They don’t apply for my setup because the default click behaviour of the Magic Trackpad already matches my expected behaviour.

I hope you find this informative and useful. As usual, I’d really appreciate any comments and feedback. You can find me as AgentK on Twitter.

Источник

Могу ли я использовать Magic Trackpad в Linux?

Я хотел бы иметь возможность использовать мой Magic Trackpad с Linux. Хотя я еще не установил Linux, чтобы протестировать его, трекпад будет подключаться к Windows на машине (т. Е. У него есть Bluetooth). Я собираюсь использовать Fedora 14 на Lenovo T410.

1 ответ 1

Я предполагаю, что вы хотели бы знать, делают ли они драйверы для Magic Trackpad для Linux. После 1 минуты гугл-поиска я нашел этот форум. Я знаю, что основные моменты немного обширны, но эти посты являются единственными реальными информативными, которые помогают теме, и которые не являются повторяющимися, которые я нашел в течение двух минут после просмотра форума.

Особенности

Я купил Magic Trackpad вчера, и он отлично работает на моих Mac, как и в Linux. За исключением того, что Linux не поддерживает эти классные жесты OSX, но вы можете использовать его в качестве замены мыши .

Например, в Ubuntu Karmic (10.04) вам просто нужно получить ядро 2.6.35, которое можно получить из репозитория ppa:kernel/ppa. После перезагрузки и сопряжения bt все работает . щелчок левой / правой кнопкой мыши, указание и щелчок (последний — только с помощью встроенной кнопки). В Ubuntu 10.10 он работает с нуля, следовательно, 10.10 включает в себя 2.6.35 или более новое ядро .

С помощью волшебного трекпада вы сможете прокручивать максимум два пальца вверх / вниз в Linux. Скользящая прокрутка, прокрутка с тремя и четырьмя пальцами не работает. что делает его так же хорошо, как дорогой пресс-папье.

Говорят, что поддержка мультитач идет с Ubuntu Maverick (10.10). Также сообщается, что Firefox и Chrome скоро будут работать над поддержкой Multitouch. Тем не менее мне нравится тот факт, что я могу использовать трекпад на моих Mac, а также на моих Linux-коробках

Источник

Apple magic trackpad linux

Driver is mainlined

Читайте также:  Слабая скорость wi fi windows 10

This driver was merged into the official Linux kernel in 4.20 (see update 2018-12-15 below). If uname -srm shows 4.20 or greater, you already have this driver installed and likely have no use for the driver in this repo.

Installed today Xubuntu 19.04 and the pressure problem was back. I had to add the following file:

To pair via Bluetooth disconnect from USB, then turn it off and on again and you will find it when you search for devices.

Tried today the beta of Ubuntu 19.04 with Kernel 5.0 and the Magic Trackpad 2 works out of the box. No quirks needed.

As the pressure offsets have been removed from the official release, the driver needs a libinput quirks file. schmunk42 suggested the following quirks file in his comment https://github.com/torvalds/linux/pull/332#issuecomment-451859484:

The driver will be included in the 4.20 release of the official linux kernel.

This means that the active development in this repository is stopped and you should use the official code for modifications.

  • Thank you to everybody who helped, whether through testing or active development!
  • https://github.com/bobbysue/Linux-Magic-Trackpad-2-Driver
  • https://github.com/ponyfleisch/hid-magictrackpad2
  • https://github.com/adam-h/Linux-Magic-Trackpad-2-Driver

This repository contains the linux hid-magicmouse driver with Magic Trackpad 2 support for Linux 4.18. For older kernels you might have to diff and backport.

The driver is tested in combination with the xf86-libinput and xf86-mtrack driver.

The driver supports bluetooth and USB. To connect the Trackpad via bluetooth, it must be clicked once after it is turned on, then the Trackpad tries to reconnect to the last paired (and trusted) connection.

Please help to test this driver and report issues.

You can just use the standard xf86-libinput driver and configure it through your Window-Manager-Settings. This driver works very well, but does not support three-finger-drag, but tap-to-drag.

An example configuration for mtrack can be found in:

This configuration supports tap-to-click, two-finger-scroll and three-finger-drag. Though scrolling is not as smooth as with xf86-libinput. It can be used as starting point for your own configuration. Make sure, that you have xf86-input-mtrack-git installed and it gets loaded. You find more information about the options here: https://github.com/p2rkw/xf86-input-mtrack

@adam-h made a DKMS which can be used for testing:

Or just use regular dkms commands once you’ve added ./linux/drivers/hid .

If the driver is not working, please make sure that the correct hid-magicmouse driver gets loaded and try the following steps:

Now unplug the trackpad and plug it back in, to see which driver gets loaded.

Источник

Magic Trackpad vs Ubuntu — кто косячит?

Есть у меня такой вот трекпад от говноэппла. Вроде терпимая штука, за неимением альтернатив (на кровати с мышкой очень неудобно).

Но есть одна проблемка — он не выключается сам при неактивности. А я регулярно забываю его выключить перед сном. В результате батарейки выжираются и приходится регулярно их менять.

Вопрос в том кто лажает? (ну кроме меня). Либо эппловские продукты и впрямь такое говно и они не предусмотрели такую элементарную вещь — или всетаки моя бубунта этому припятствует и шлет какието keepalive (как вариант, хз бывает ли такое). Вдруг это всеже можно както исправить?

з.ы. у меня первой версии, оказывается они его уже перевыпустить успели лол

Косячишь в данном случае ты. Не надо использовать аппле устройства на неаппле ОС. Драйверов нет, ничего нет, поэтому работает не лучше мышки за 150 деревянных, а то и хуже. Разве что на ощупь приятнее. А в макос с соответствующими драйверами равных трекпаду нет. Мышь расчехляю только если вдруг захочется поиграть в какой-нибудь спинномозговик.

Читайте также:  Windows app certification kit что это

И по памяти: мышь эппловская у меня была, разряжалась достаточно быстро 2 недели-1 месяц даже при эксплуатации с маком. Не сравнить с логитеком (привет соседнему треду) в котором я батарейки менял раз в год наверное, не чаще.

о, эпплодрочер чтоль?
тачпад как тачпад. в офисе пользовался ей с маком пару недель — никаких различий (разве что жесты из коробки есть). и кстати ничего крутого в нем нет, кусок фекалий разработанный дизайнерами и маркетологами. пользоваться можно, но своих денег не стоит даже близко — просто аналогов на момент покупки небыло. такчто не неси херни

Источник

Apple magic trackpad linux

Instructions for installing the Apple Magic Trackpad 2 on Linux

I should start this by pointing out that I currently do not have a working configuration for the Magic Trackpad 2 on Linux. This is meant to document my experiments in hope that someone more experienced than me can jump in at some point and magically provide with a solution.

I am running Ubuntu 14.04 LTS (trusty) with kernel 3.13.0-66-generic .

Plugging the trackpad via USB does work to some extent, but only normal movements and left clicks are working. No multitouch, no right click, no scrolling, no option to change sensitivity exist.

The first thing I tried was to load the Synaptics drivers for the device.

With lsusb , I found out the USB ID of the device:

I then used this to select the synaptic drivers for the input class, by adding the following lines to my /etc/X11/xorg.conf :

I then restarted X with sudo restart lightdm (note: it closes all your running programs, so make sure you know what your are doing).

After this, the trackpad stopped working entirely (not even basic movements and click), and I then looked into the X logs ( /var/log/Xorg.0.log ), and found the following:

Since the error message mentioned not being able to identify the protocol, I looked up the possible alternatives in man synaptics , which lists auto-dev , event , psaux , psm .

The following configuration gave me a different error:

I also tried tapping into the raw event stream, and after playing around with byte sizes, I concluded that the events are 24 bytes each, and can be print like:

Let’s try to break a single row down:

  • The first 16 bytes are probably just a timestamp (the second byte increments by one every second)
  • The next 8 bytes seem to represent the relative position of the cursor, basically the direction in which the finger is moving on the trackpad (positive towards the bottom and to the left of the surface of the trackpad).

Notably, events seem to only be produced when the finger is actually moving (not tapping or pressing), which suggests that the device is not even emitting events related to multitouch or pressure sensitivity at all.

At this point, my conclusion is that the more advanced functionalities are disabled in hardware, and only OSX knows the magic combination to unlock them. When plugged to any other computer, the trackpad will only send basic events.

About

Instructions for installing the Apple Magic Trackpad 2 on Linux

Источник

Оцените статью