1

First, I have seen this and this old questions.

However meanwhile several years have passed and I have a slightly different use case and therefore are looking for a different hopefully efficient/good solution:

We have a lab with an embedded test device. We cannot install any software on it what so ever. However we can plug in exactly one set of USB mouse and keyboard. Now we want to give developers (one at a time is absolutely enough) pseudo remote access to it.

Our wished setup for this would be a (cheap) windows or linux box in front of our embedded device which has a HD cam filming the console display of our embedded device. Setting up and managing remote access to such a box would be easy. Seeing the console of the embedded device would also work naturally as video stream in the box (delay, frame rate and video quality are not an issue/critical).

However, how could we get mouse and keyboard input from the box to the embedded device? Keystrokes are by the way not enough, the mouse has to be transmitted as well. My problem is that mouse and keyboard input are coming form the remote desktop connection and not hardware on-site; otherwise a simple USB switch would be enough. So a software which simulates/forwards mouse and keyboard as USB output form the remotely accessed box to the embedded device would be best. But I couldn't find something like that.

Is there such software? And if not, is there any other solution to this use case? Anything that works would be okay, I'm just hoping I can ditch the 2-3k KVM over IP solutions which seem like an overkill...

1 Answer 1

2

What you ultimately need here is a way to have a system present itself as a USB device instead of a USB host. It's pretty much impossible to do this with Windows (it's technically possible, but you need Windows 10 IoT edition or an equivalent older version), but Linux has native support for emulating a USB device, and can in fact emulate almost any USB device.

The problem is that you need hardware support for this too, not just software support, and finding such hardware is a bit of a pain because manufacturers use a variety of names for this functionality. Usually, it's labeled as USB OTG (or On-The-Go, which is the official USB-IF term for a dual-mode device), USB Gadget support (the official Linux kernel terminology), or USB Device mode.

I know off the top of my head of two inexpensive Linux single-board computers that support this functionality:

Both are more than sufficient for what you're talking about, but will require some extra coding to actually emulate a keyboard and mouse (don't worry, it's not difficult, it's just that it's usually so application specific that there really isn't good software for it out there). I'd personally go with the Pi Zero W, as it should be easier to get working for this application (the Beaglebone already uses gadget mode actively in it's firmware, so it's going to be more work adding to that than starting from scratch), and it also has native MIPI CSI (camera-serial interface, a widely used standard for cameras in embedded Linux devices)) support, so you could easily integrate a compatible camera (for example, the Raspberry Pi Camera Module V2) into the setup to provide the video feed.

1
  • 1
    Very informativ and the solution with a Pi Zero W sounds great. I'm only a little worried about the "don't worry, it's not difficult" part ;-) Still we'll give it a shot (this tutorial looks promising in that direction: isticktoit.net/?p=1383 )
    – Jey DWork
    Commented Aug 22, 2019 at 20:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .