mm2 icon indicating copy to clipboard operation
mm2 copied to clipboard

uninstall script?

Open sla-te opened this issue 8 years ago • 3 comments

i tried this on 16.04. it loaded the module but there were mistakes while executing ./magicmouse2_build.sh and now apple keyboard and mouse can be paired but are not working anymore.

sla-te avatar Oct 02 '16 00:10 sla-te

heres the output i just ran it again:

guru@linux:~/mm2/mm2$ ./magicmouse2_build.sh mkdir: cannot create directory ‘./hid.dist’: File exists mkdir: cannot create directory ‘./dist_src’: File exists Reading package lists... Done NOTICE: 'linux' packaging is maintained in the 'Git' version control system at: git://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux/+git/xenial Please use: git clone git://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux/+git/xenial to retrieve the latest (possibly unreleased) updates to the package. Skipping already downloaded file 'linux_4.4.0-38.57.dsc' Skipping already downloaded file 'linux_4.4.0.orig.tar.gz' Skipping already downloaded file 'linux_4.4.0-38.57.diff.gz' Need to get 0 B of source archives. Skipping unpack of already unpacked source in linux-4.4.0 cp: cannot stat '/lib/modules/4.4.0-38-generic/kernel/drivers/hid/_': No such file or directory patching file hid-ids.h patching file hid-core.c patching file hid-magicmouse.c Hunk #6 succeeded at 522 (offset -2 lines). Hunk #7 succeeded at 530 (offset 4 lines). Hunk #8 succeeded at 571 (offset 4 lines). make: Entering directory '/usr/src/linux-headers-4.4.0-38-generic' CC [M] /home/guru/mm2/mm2/hid/hid-core.o In file included from /home/guru/mm2/mm2/hid/hid-core.c:34:0: /home/guru/mm2/mm2/hid/hid-core.c: In function ‘hid_connect’: include/linux/hid.h:614:2: error: expected expression before ‘.’ token .bus = BUS_BLUETOOTH, .vendor = (ven), .product = (prod) ^ /home/guru/mm2/mm2/hid/hid-core.c:1631:4: note: in expansion of macro ‘HID_BLUETOOTH_DEVICE’ { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE_INC, USB_DEVICE_ID_APPLE_MAGICMOUSE ^ include/linux/hid.h:614:22: warning: left-hand operand of comma expression has no effect [-Wunused-value] .bus = BUS_BLUETOOTH, .vendor = (ven), .product = (prod) ^ /home/guru/mm2/mm2/hid/hid-core.c:1631:4: note: in expansion of macro ‘HID_BLUETOOTH_DEVICE’ { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE_INC, USB_DEVICE_ID_APPLE_MAGICMOUSE ^ include/linux/hid.h:614:39: warning: left-hand operand of comma expression has no effect [-Wunused-value] .bus = BUS_BLUETOOTH, .vendor = (ven), .product = (prod) ^ /home/guru/mm2/mm2/hid/hid-core.c:1631:4: note: in expansion of macro ‘HID_BLUETOOTH_DEVICE’ { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE_INC, USB_DEVICE_ID_APPLE_MAGICMOUSE ^ /home/guru/mm2/mm2/hid/hid-core.c:1631:85: error: expected expression before ‘,’ token BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE_INC, USB_DEVICE_ID_APPLE_MAGICMOUSE_2) }, ^ /home/guru/mm2/mm2/hid/hid-core.c:1631:85: warning: left-hand operand of comma expression has no effect [-Wunused-value] scripts/Makefile.build:258: recipe for target '/home/guru/mm2/mm2/hid/hid-core.o' failed make[1]: ** [/home/guru/mm2/mm2/hid/hid-core.o] Error 1 Makefile:1403: recipe for target 'module/home/guru/mm2/mm2/hid' failed make: *** [module/home/guru/mm2/mm2/hid] Error 2 make: Leaving directory '/usr/src/linux-headers-4.4.0-38-generic' make: Entering directory '/usr/src/linux-headers-4.4.0-38-generic' DEPMOD 4.4.0-38-generic make: Leaving directory '/usr/src/linux-headers-4.4.0-38-generic' cp: cannot stat '/lib/modules/4.4.0-38-generic/extra/*': No such file or directory modprobe: ERROR: ../libkmod/libkmod-module.c:192 kmod_module_parse_depline() ctx=0x558df4c12010 path=/lib/modules/4.4.0-38-generic/kernel/drivers/hid/hid.ko error=No such file or directory modprobe: ERROR: ../libkmod/libkmod-module.c:192 kmod_module_parse_depline() ctx=0x558df4c12010 path=/lib/modules/4.4.0-38-generic/kernel/drivers/hid/hid.ko error=No such file or directory modprobe: ERROR: could not insert 'hid_magicmouse': Unknown symbol in module, or unknown parameter (see dmesg)

Magicmouse module failed to load. Time to debug?

Magicmouse module loaded but no MM2 input device detected. Check udev hwdb for MM2 exists in /etc/udev/hwdb.d/

sla-te avatar Oct 02 '16 00:10 sla-te

both keyboard and mouse are paired cant also can be disconnected and paired again. they just dont work at all :)

sla-te avatar Oct 02 '16 00:10 sla-te

As noted in the README, the script is only expected to work without issues on Ubuntu 14.04 Trusty. It has not been tested on Ubuntu Xenial or any other release or distro. Brief uninstall instructions have been added to README.md. In short, restore the contents of hid.dist to /lib/modules/${KERNEL_VER}/krernel/drivers/hid/ and delete /etc/udev/hwdb.d/21-apple-magicmouse-vendor-model.hwdb before unloading the hid_magicmouse module.

biggreenogre avatar Oct 03 '16 19:10 biggreenogre