RawMouse icon indicating copy to clipboard operation
RawMouse copied to clipboard

Spacemouse on Big Sur broken

Open gilgen opened this issue 5 years ago • 27 comments

Recently I upgraded to Big Sur and unfortunately this handy plugin no longer functions. I've tested on Cura versions 4.7.1 and 4.8.

gilgen avatar Nov 17 '20 22:11 gilgen

Hi, can you please provide the cura.log file, it may possibly contain something that gives a hint as to what is going wrong, thanks.

smartavionics avatar Nov 18 '20 06:11 smartavionics

This is what I'm getting when I restart the rawmouse plugin:

2020-11-18 11:46:33,568 - DEBUG - [MainThread] RawMouse.RawMouse._cacheProfileValues [120]: Device 3Dconnexion / SpaceMouse Wireless, profile spacemouse
2020-11-18 11:46:33,568 - DEBUG - [MainThread] RawMouse.RawMouse._cacheProfileValues [139]: axis 0, scale = -0.100000, threshold = 0.010000, offset = 0.000000, target = movx
2020-11-18 11:46:33,568 - DEBUG - [MainThread] RawMouse.RawMouse._cacheProfileValues [139]: axis 1, scale = -100.000000, threshold = 1.000000, offset = 0.000000, target = zoom
2020-11-18 11:46:33,568 - DEBUG - [MainThread] RawMouse.RawMouse._cacheProfileValues [139]: axis 2, scale = -0.100000, threshold = 0.010000, offset = 0.000000, target = movy
2020-11-18 11:46:33,569 - DEBUG - [MainThread] RawMouse.RawMouse._cacheProfileValues [139]: axis 3, scale = -0.050000, threshold = 0.010000, offset = 0.000000, target = rotpitch
2020-11-18 11:46:33,569 - DEBUG - [MainThread] RawMouse.RawMouse._cacheProfileValues [139]: axis 4, scale = -0.050000, threshold = 0.010000, offset = 0.000000, target = rotroll
2020-11-18 11:46:33,569 - DEBUG - [MainThread] RawMouse.RawMouse._cacheProfileValues [139]: axis 5, scale = 0.100000, threshold = 0.010000, offset = 0.000000, target = rotyaw
2020-11-18 11:46:33,570 - DEBUG - [RawMouse] RawMouse.RawMouse._run_hid [219]: Trying to open IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/PEG2@1,2/IOPP/UPSB@0/IOPP/DSB1@1/IOPP/UPS0@0/IOPP/pci-bridge@1/IOPP/pci1b73,1100@0/AppleUSBXHCIFL1100@00000000/AppleUSB20XHCIPort@00100000/USB2.1 Hub@00100000/AppleUSB20Hub@00100000/AppleUSB20HubPort@00130000/SpaceMouse Wireless@00130000/IOUSBHostInterface@0/AppleUserUSBHostHIDDevice
2020-11-18 11:46:33,571 - ERROR - [RawMouse] RawMouse.RawMouse._run_hid [246]: IOError while reading HID events: open failed```

gilgen avatar Nov 18 '20 16:11 gilgen

Thanks for the info. That looks like it could be that the library I use to access the HID device doesn't work on Big Sur. I looked at the github repo for that library and it doesn't look like that is (yet) a known problem. I will see if I can learn more and get back to you.

smartavionics avatar Nov 18 '20 17:11 smartavionics

Cool, thanks 😄

gilgen avatar Nov 18 '20 17:11 gilgen

Hi, do you have the 3dconnexion driver enabled? If so, can you please disable it and see if that makes any difference? On Windows, there is a command to enable/disable the driver, perhaps MacOS does also?

smartavionics avatar Nov 19 '20 12:11 smartavionics

Hm, there's no way to turn off the driver, that I know of. 3dconnexion released a beta level driver recently that I'm using. The spacemouse works everywhere else since installing this driver.

https://3dconnexion.com/uk/support/faq/beta-driver-for-macos-11-big-sur/

gilgen avatar Nov 19 '20 14:11 gilgen

Hmm, looking at that 3dconnexion page it seems that their driver has some problems. So perhaps it's not surprising that RawMouse is broken. if it's not too much hassle, could you try uninstalling their driver and then checking if RawMouse works again. That would at least tell us something.

smartavionics avatar Nov 19 '20 18:11 smartavionics

Thanks @smartavionics. I really don't want to mess up my configuration by removing the driver. Maybe we can just wait to see if a non-beta version of the driver resolves the issue.

gilgen avatar Nov 19 '20 19:11 gilgen

Understood. Let's just leave this issue open and hope that either the driver gets fixed (if that is the problem) or the underlying library gets fixed. Unfortunately, I have no way of testing this myself.

smartavionics avatar Nov 19 '20 19:11 smartavionics

Just want to mention that I get the same error message in the cura.log. I am looking for a way to disable the drivers or a clean deinstallation.

SmithyAT avatar Nov 20 '20 12:11 SmithyAT

Thanks for your help, I can't really do much here as I don't have a recent MacOS system. I have opened an issue on the library I use (https://github.com/libusb/hidapi/issues/212) and it may be that yields a result.

smartavionics avatar Nov 20 '20 13:11 smartavionics

This seems to have been fixed in the Mac OS 11.1 Public Beta. My Spacemouse now works again after updating to the Mac OS Public Beta 11.1 and the beta plugin from 3D Connexion. Haven't tried with RawMouse

7a50n avatar Nov 22 '20 12:11 7a50n

Looks like the RawMouse plugin is is still no working for Cura. I just tested on Big Sur. Working great on fusion 360.

hursto75 avatar Jan 12 '21 03:01 hursto75

Hello, I have the same problem and would love to use Spacemouse with Cura....

Notyly avatar Jan 22 '21 15:01 Notyly

As far as I can tell, the hidapi library does not yet work right on Big Sur when accessing the SpaceMouse. Sorry, until that is fixed or a workaround is created, I can't make RawMouse work on Big Sur.

smartavionics avatar Jan 22 '21 17:01 smartavionics

Basically if there is another driver active on the macOS for the device, there is no way to use HIDAPI.

mcuee avatar Jan 26 '21 02:01 mcuee

From https://github.com/libusb/hidapi/issues/212 This means that 3dconnection driver opens the device in exclusive mode, in that case, no way to use HIDAPI without disabling the 3dconnection driver. In order to use HIDAPI, then the user has to disable 3dconnection driver.

mcuee avatar Jan 27 '21 02:01 mcuee

Just a thought. Is the behavior for the driver in macOS the same as for Windows? There you need to deactivate Cura via 3dconnexion device driver properties first for using the plugin driver.

Cura3DConnexionSpaceMouse plugin driver.

DivingDuck avatar Jan 27 '21 09:01 DivingDuck

I'm pretty sure that users have reported that RawMouse works on Windows without deactivating the 3dconnexion software.

smartavionics avatar Jan 27 '21 09:01 smartavionics

I guess, I was this first :) Maybe my answer was misleading. You don't need to deactivate the whole 3dConnexion driver, only disable the Cura app within the driver. This is what you need to do for avoiding interfering between your and 3DConnexion driver in windows. Most people do not recognize this interfering in first place but wonder why the mouse is not running smooth as for e.g. CAD or other software.

DivingDuck avatar Jan 27 '21 09:01 DivingDuck

Hi, I have big sur 11.3 on a macbook pro M1. By desabling all the feature in the 3d connexion beta driver nothing is working. But when I kill all "3D" related process, something happen (hard to explain with my poor english). It's impossible to use rawmouse but at least the spacemouse is saying something to cura. See the attached log file if it can help

cura.log

Thanks

ChristopheBis avatar Apr 28 '21 23:04 ChristopheBis

Hi,

Thanks for the log file, unfortunately, it's just confirming that the mouse device could not be accessed. Even with the 3D related processes inactive, it may not be possible for Cura to access that device. Perhaps it is a permissions problem and it would succeed if run by the system administrator. But that is not a good idea for security reasons. Sorry, I don't have a solution for this problem.

smartavionics avatar Apr 29 '21 06:04 smartavionics

Thanks for your hard work. It's working perfectly with parallel desktop and windows 10 on the mac.

ChristopheBis avatar May 01 '21 03:05 ChristopheBis

Hi,

when i uninstall the driver for the space mouse in big sur, the RawMouse plugin works... ! Seems that's the issue with accessing the device in exclusive mode. Maybe 3dConnexion has to provide a Plugin for Cura.

togeis avatar Jun 05 '21 18:06 togeis

Hi @togeis. Yes, the 3dconnexion driver opens the device in exclusive mode so no other software can access the device and that stops RawMouse from working. Why they made that change from the earlier driver which didn't do that, I do not know.

smartavionics avatar Jun 05 '21 18:06 smartavionics

I have tested to use the Beta driver (3DxWareMac_v10-7-0_r3333 ) and FreeCad, it works. Blender also ! Seem to be an issue with hidapi. I am not really sure if it has something to do with the exclusive mode, because FreeCad and Blender work with the installed driver under Big Sur. They had to change the driver because Apple has changed the way drivers can access devices. Many drivers have to be modified to be used in BigSur. :-( So i am not sure if the driver is "responsible" for the malfunction of the python lib hidapi.

togeis avatar Jun 05 '21 18:06 togeis

Well, I'm not going to look into using the 3dconnexion driver because:

1 - The whole point of RawMouse is that it doesn't use other drivers, it interacts directly with the HID device.

2 - I don't have access to a computer running Big Sur.

3 - Cura doesn't work reliably on Big Sur anyway.

4 - I'm too lazy!

smartavionics avatar Jun 05 '21 20:06 smartavionics