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.86k stars 112 forks source link

Unable to start service on Linux (Ubuntu 20.04) #59

Closed Th4ntis closed 3 years ago

Th4ntis commented 3 years ago

I'm working on getting this to run between Windows 10 and Ubuntu 20.04 but I can't get the service to start and I can't seem to figure out why. when I run "sudo systemctl status display-switch.service" and I have the display-switch.ini in the proper directory with Hdmi is my Ubuntu and DisplayPort is Windows. What part am I missing or doing wrong?

usb_device = "1A40:0101"
on_usb_connect = "Hdmi1"
on_usb_disconnect = "DisplayPort1"
● display-switch.service - Display switch via USB switch
     Loaded: loaded (/etc/systemd/system/display-switch.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Mon 2021-03-15 01:26:44 EDT; 1s ago
    Process: 4777 ExecStart=/usr/local/bin/display_switch (code=exited, status=1/FAILURE)
   Main PID: 4777 (code=exited, status=1/FAILURE)

Mar 15 01:26:44 Blade systemd[1]: display-switch.service: Scheduled restart job, restart counter is at 5.
Mar 15 01:26:44 Blade systemd[1]: Stopped Display switch via USB switch.
Mar 15 01:26:44 Blade systemd[1]: display-switch.service: Start request repeated too quickly.
Mar 15 01:26:44 Blade systemd[1]: display-switch.service: Failed with result 'exit-code'.
Mar 15 01:26:44 Blade systemd[1]: Failed to start Display switch via USB switch.