How to eject a USB HID Device from Mac OSX to use in Ubuntu VM?

耗尽温柔 提交于 2019-12-07 07:54:58

问题


I'm running Ubuntu 14.04LTS, 64bit via VirtualBox on a mac. I want to talk to a USB HID device from my VM via a python app (pyusb) but I can't select the device. From VirtualBox -> Devices -> USB Devices I see my device but it's grayed out.

I was hoping to find a command I could run on the mac terminal to 'let go' of it, but it's turning out to be more difficult than I imagined. On an Ubuntu VM via Windows 7, I can take control of the USB HID device via Devices -> USB Devices -> Select my device and talk to it just fine.

Is there some reason why this may not be possible on a mac?


回答1:


There is no concept of 'unmount in host OS to grab it in vm's OS'.

To get a normally plug-and-play device to work:

  1. Shut down the guest machine.
  2. Highlight the guest machine in the VirtualBox panel.
  3. Go to Settings for that vm -> Ports -> USB
  4. Click the green plus icon to add your device.
  5. Your usb device should now be visible, click to add that.
  6. Remove the USB device from your physical machine
  7. Start VB and guest OS (in my case Ubuntu 14.04 LTS, 64bit)
  8. Plug in USB device
  9. Inspect that the device has been captured by the vm's operating system in Devices -> USB Devices


来源:https://stackoverflow.com/questions/24318375/how-to-eject-a-usb-hid-device-from-mac-osx-to-use-in-ubuntu-vm

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!