haimgel / display-switch

Turn a $30 USB switch into a full-featured multi-monitor KVM switch
https://haim.dev/posts/2020-07-28-dual-monitor-kvm/
MIT License
2.85k stars 112 forks source link

Any advice on Thunderbolt equipped display? #12

Closed ckunte closed 4 years ago

ckunte commented 4 years ago

Any advice on connecting two (Thunderbolt USB-C connector equipped) computers (HP 830 G5 and 2020 Mac Mini) to a single display with two thunderbolt ports (LG 24MD4KL-B)?

Here's what I did but did not succeed with the instructions in README:

  1. Installed pyusb with python3 -m pip install pyusb

  2. With a mouse connected to the UGREEN hub's central port, I ran the following script to get vendor ID and product IDs

    #!/usr/bin/python
    import sys
    import usb.core
    # find USB devices
    dev = usb.core.find(find_all=True)
    # loop through devices, printing vendor and product ids in decimal and hex
    for cfg in dev:
      sys.stdout.write('Decimal VendorID=' + str(cfg.idVendor) + ' & ProductID=' + str(cfg.idProduct) + '\n')
      sys.stdout.write('Hexadecimal VendorID=' + hex(cfg.idVendor) + ' & ProductID=' + hex(cfg.idProduct) + '\n\n')

    For this, I got the following output for my barebones Logitech M90 mouse:

    Decimal VendorID=1133 & ProductID=49271
    Hexadecimal VendorID=0x46d & ProductID=0xc077
  3. Followed the rest of the process described in the README.

shanempope commented 4 years ago

hex ids should be 4 hex characters I believe

try looking at the logs when you run. You can find where logs are in this issue: https://github.com/haimgel/display-switch/issues/6

ckunte commented 4 years ago

hex ids should be 4 hex characters I believe

Thank you. I fixed it to "046d:c077".

try looking at the logs when you run. You can find where logs are in this issue: #6

On MacOS Catalina, I get:

com.apple.xpc.launchd[1] (dev.haim.display-switch.daemon[419]): removing service since it exited with consistent failure - OS_REASON_EXEC | Gatekeeper policy blocked execution

I then explicitly allowed it under Security and Privacy.

On Windows 10, the application display_switch.exe does not run perhaps because I am a locked user. I suppose it is too much of a stretch for end users like me with handicap(s) like these.