Live data from Hacker News

DeskHop – Fast Desktop Switching

github.com

51–60 of 285 posts

Re: DeskHop – Fast Desktop Switching

#51
post #6

I bought 4 USB hubs just to switch the keyboard and mouse, it's just so annoying how most devices are so terrible. Randomly you have to physically detach the hub several times a day. If you plug webcams and/or USB mics, it only gets even worse. I'm using Synergy software and it works well, but I still want a proper KVM that can allow for webcams, mics, audio, etc. Features like moving only a group of plugged devices…

The best setup I've found is what I lucked into at work. It's a Benq monitor (32", 4k) that does the KVM itself. There's a couple of Displayport inputs, each if which has a couple of USBs with it, as well as a USB C which is both peripheral and display input (and decent power output). Then there's a little pick on the desk for switching.

The nice thing is that it continually presents a monitor to all the inputs even when they're not being displayed. Means you don't get the flickering as Windows sorts itself out and so a much faster and more seamless switch.

Re: DeskHop – Fast Desktop Switching

#52
I have a similar project inspired by another similar project (https://github.com/jfedor2/screen-hopper).

My own version of this consists of two programs.

One program runs on a Linux desktop and listens to input events from the Linux input subsystem (evdev). When you press a specific key, it will start consuming all events and sending them over USB serial to a RPI Pico. Pressing the key again will toggle back into passive listening mode.

The RPI Pico is programmed to receive Linux evdev events over serial, translate them into USB HID events and send them to another Windows PC.

The end result is a KM switch that switches instantly between a Linux PC and a PC running an OS of your choice.

Epic wiring photo: https://ibb.co/m0zhzgz. I used another Pico as a USB serial adapter.

As a hardware noob, needing only 2 wires was a huge relief and I think this is a great starter project for other hardware noobs.

Both programs were Ultimately I never ended up open sourcing it because of some USB serial bugs (it would not reconnect properly to the Linux desktop after getting disconnected). Not sure if it was because of Linux or the Pico. I still use it, the bugs aren't a problem because I never disconnect the wires.

I also specifically left out the absolute mouse feature since I play a lot of FPS games and it wouldn't work with those. I have the switch key bound to a button on the side of my mouse anyway so I can switch systems without even touching my keyboard.

Re: DeskHop – Fast Desktop Switching

#53

Seriously, if any VC is reading this, get this man some funding to make it a real project. Even at double or triple what it costs, it's still cheaper than any other commercial competitor.

If it gets really popular here on hacker news won't be long before chinese devices based on it start appearing. Or if someone is willing to invest $10-20k they could have devices ready to sell in less than 2-3 weeks.

With built-in networking so they can send your keylogs ;-)

Re: DeskHop – Fast Desktop Switching

#54
post #20

I recently had the idea of making similar hardware with ESP32 (some of them has USB hardware). You may lose mouse acceleration, but many do not like this to begin with, so it's fine. Does absolute mouse work correctly when two systems have very different (total) resolution? For example, one is a laptop with a single screen, and another one is a desktop with three screens.

How does absolute mouse work? The mouse hw just reports delta x/y and has no idea how the corners of your screen map to your desk surface. So it sounds like special hw. or very frequent recalibration of “corners” after moving mouse when machine is off or lifting+moving (which would essentially be what would happen when using it on machine 2)

It is not putting your mouse itself in absolute mode (only graphics tablets really operate in absolute mouse mode). It's just outputting absolute mode reports to the host.

Absolute mouse HID report has a logical/physical min/max, not just delta. Regardless of size of screen, min/max correspond to the boundaries in absolute mode.

So it's just keeping track internally of the incremental relative accumulation of your mouse as you move it, and i assume, when you hit the min/max, swapping screens.

I assume it's reporting a high enough min/max resolution to make this not happen crappily.

The polling rate on mice is usually only 125hz (8ms), so it has plenty of time to handle the input.

Even "gaming" mice are usually only 1000hz (1ms).

I would guess, looking at it, that it takes a few microseconds to handle the mouse moves, max.

Re: DeskHop – Fast Desktop Switching

#55
post #5

Synergy works well for this purely in software. Unfortunately it's not free or open source, but it's relatively inexpensive. https://symless.com/synergy

Prior to Synergy going to closed source, it was forked into Barrier[0], which then was forked into input-leap[1]. Both open source. [0] https://github.com/debauchee/barrier [1] https://github.com/input-leap/input-leap

I haven’t tried Synergy. barrier and input-leap were useless for me as they don’t capture “ctrl-alt” so my crucial “open a terminal” shortcut always opens it on the primary computer. Maybe Wayland is to blame?

Re: DeskHop – Fast Desktop Switching

#56
post #13

> Ever tried to move that YT video slider to a specific position but your mouse moves too jumpy and suddenly you are moving your hand super-carefully like you're 5 and playing "Operation" all over again? On YouTube specifically, you can scrub through a video frame-by-frame using the , (comma) and . (period) keys, no custom hardware required. :-)

I wish there was a solution for Android. Sliders for fine grained selections are horrible in touch interfaces.

Re: DeskHop – Fast Desktop Switching

#57

I recently had the idea of making similar hardware with ESP32 (some of them has USB hardware). You may lose mouse acceleration, but many do not like this to begin with, so it's fine. Does absolute mouse work correctly when two systems have very different (total) resolution? For example, one is a laptop with a single screen, and another one is a desktop with three screens.

Absolute mouse "works" in any situation. You are responsible for reporting the physical and logical min/max values for the mouse. The host translates these into screen coordinates.

So if you report the max x/y as 32767, and the current x/y as 32767, the host will translate it to the corner, regardless of size of screen.

Re: DeskHop – Fast Desktop Switching

#58

Good to note that it doesn't require client software to detect edges. > To get the mouse cursor to magically jump across, the mouse hid report descriptor was changed to use absolute coordinates and then the mouse reports (that still come in relative movements) accumulate internally, keeping the accurate tally on the position. So it works like synergykm / barrier, without clipboard features and without client software…

Very nice to not require the computers to connect over the network.

Re: DeskHop – Fast Desktop Switching

#60
post #49

Just responding to the clunky and slow switching that is available. I have this wireless DELL mouse+keyboard set that switches quite easily and fast. Supports up to three devices (dongle + 2x BT). Dedicated key for tge switch, wirelss is instant, BT takes roughly 2 seconds. I can't recommend it though, as the mouse scroll wheel broke pretty quickly, and it's apparently a common problem. Can't "warranty it" individual…

Some dell monitors also allow switching video input via keyboard + mouse using the Dell Display Manager utility. You can set custom hotkeys for each input. I have a dell monitor as my daily driver and its my central monitor in a multi display setup simply because of the display input switching capability. Beats having to buy a expensive DisplayPort KVM.
Post reply on HN