KVM over IP with arduino?

I would like to have a KVM over IP solution for my home server, ideally going through a backup GSM connection.

I read the the Leonardo and Micro can emulate a keyboard and mice.

But how can I capture the VGA output?

I'm aware that that might be not so strait forward as this are really big data rates.
But if I say 1 frame per second would be enough that should be doable in somehow?
How to do that?

Any advice would be greatly appreciated.

But how can I capture the VGA output?

AFAIK you cannot do that with Arduino, must be integral be supported from the OS.

So use windows 7 pro edition or goto linux and use some remote desktop.

PhilippMacGeyer:
But how can I capture the VGA output?

I'm aware that that might be not so strait forward as this are really big data rates.
But if I say 1 frame per second would be enough that should be doable in somehow?
How to do that?

Any advice would be greatly appreciated.

Say you're using a low screen resolution of 800 * 600 and 256 (16 bit) colours. That's 7.68Mb of data that you want to send in 1 second through a microcontroller operating at 16MHz. Probably impossible, especially if you want the Arduino to do other things at the same time or need a higher screen and/or colour resolution. I don't know anything about them, but a Raspberry Pi might be a better solution.

PhilippMacGeyer:
I would like to have a KVM over IP solution for my home server, ideally going through a backup GSM connection.

Do you definitely need a separate KVM relay? The options would depend what OS your server is running, but there are remote desktop access options for most mainstream operating systems.

I use VNC,

I need the remote KVM for when VNC fails, for example when the PC does not boot properly into windows, but hands on some recovery or error screen.

How much data it is does not really mather, i just have to go to 0.1 Hz refresh rate or so...
I dont need the KVM to show me windows while draging them, i need it to show me some boot error message or so.

Also i did not said i want to use the uno, i would probably go witha fork of the due: EtherDue (100% Arduino Due compatible with onboard Ethernet) | Freetronics
it has ethernet on board and a 84 mhz 32 bit cpu.

I have no idea how to use a raspberry pi for that task other than pointing a camera module on the TFT and thats really grose.
The pi has only very few gpio pins and i gues the rate you can reat them at is really low...
this would be what I need: https://www.kickstarter.com/projects/1419380698/connect-your-hd-camcorder-to-your-raspberry-pi
but aprearently thay run into some unresorvable problem right now.

There are 20€ VGA boards to attach arbitrary lvds panels to a vga signal, i dont know if that helps but it would at least already take care about the digitalisation...
I would just need some idea how to get the data into some ram and than slowly read it by the arduino and send it over the lan.
or may be i can force sucha board to run slow enough for the arduino to understand the digital data, or may be somehow scan the analog data, for example every n'th bit of each frame and after enough frames given thay are static i would have the full image???

and help would be greatly appriciated.

Philipp

I kind of get the idea. I've had the same pain of remote devices getting stuck in a partially-running state needing physical local access to recover.

I can see a few approaches you could consider. I haven't used them, but it's possible to get a VGA USB decoder which would receive a VGA signal output from your remote computer, and present it as a video stream (similar to a USB web cam) at another computer. See vgacapture.com for an example. It's also possible to get a VGA to s-video converter (intended to present a computer image onto an analog TV screen) and then use a conventional USB video capture card to decode it and present it is a video input device. I've used examples of each of these, but not combined them in this way. I think it ought to work, though. Both of these approaches would require you to have another PC near by to act as a host which receives the video by USB and lets you access it remotely. The PC might be an RPi, or any old PC you have kicking around. If you need to apply this solution to more than one PC, they could even act as remote proxies for each other.

I see there are some cheap VGA-to-NTSC converters which would let you feed the signal into a Video Experimenter shield for an Arduino-based solution, but I have no idea how well that would work and it doesn't feel like a very good approach to me.

Clearly the Arduino could come in useful to generate synthetic keyboard events or work a reset button for you, but I'd see it doing this under the control of a PC and not as a self-contained solution.

vga to usb + a pie sounds really teasty :wink:
can you recomnd me any vga to usb adapters that would have drivers for the pie, or that would run with generic drivers the pie has?

I know they exist but I've no personal experience of using a VGA to USB adapter so I can't recommend one. They aren't hard to find - you would have to look at what is on the market to see what the driver support situation was.

hmm... i guess the most vga to usb adapters wil not habe pi drivers...

Well, the Pi is going to be running whatever OS you have installed on it but that'll probably be some flavour of Linux, so that may not be as hopeless as you think, but I agree that Windows drivers will probably be more widely available.

You don't need analogue to digital conversion, or a Pi, just a USB monitor adaptor (which outputs HDMI/DVI and possibly VGA). They're cheap & easy to find and work well via a hub that also does keyboard & mouse. A point to point USB extender and a hub should enable you to use any console (keyboard/mouse/monitor) with a bit of replugging or switching. I'm typing this on exactly that system at 1680x1050 with about 20m of cat5 in the extender.

That's an interesting approach. At what point in the boot sequence does the USB display come up? For example, do you see the BIOS screens, BSOD etc?

I'm using a laptop with the lid closed and dual screens, one via USB. Boot messages only occur on the laptop screen, both the external ones are blank during boot. The USB adaptor relies on a Windows driver though, so I doubt it could be configured to show any boot messages.

That's probably better than the conventional VNC / terminal services approach then, but would still leave you without remote access in some situations.

perplexed:
You don't need analogue to digital conversion, or a Pi, just a USB monitor adaptor (which outputs HDMI/DVI and possibly VGA). They're cheap & easy to find and work well via a hub that also does keyboard & mouse. A point to point USB extender and a hub should enable you to use any console (keyboard/mouse/monitor) with a bit of replugging or switching. I'm typing this on exactly that system at 1680x1050 with about 20m of cat5 in the extender.

I need it to work over IP not an extender and a hardwired cable, it must go over a packet switching network and a VPN.

PhilippMacGeyer:
I need it to work over IP not an extender and a hardwired cable, it must go over a packet switching network and a VPN.

You can get USB over IP extenders which carry the USB bus over an IP network. I don't know whether there would be any issues carrying a video stream over USB over IP over a (slow) wide area network, or whether this would work better or be cheaper than the other approaches mentioned, but it definitely seems worth considering.

hmm... ok thas a posibility, but there are a few problems

  1. USB 2 VGA adapters work only after the BIOS initialised the driver, so no bios level access.
  2. where i am and want to use it i woudl need that usb 2 vga plug + the ip to usb adapter,
    i would like to do that from my phone, so thats not realy a workable solution
  3. to get that to run i would need a second router with a own internet connection
    with a arduino i could have used a gsm shield, and some prepaid -> cheep simcard

PS: i really dont waht to sound so negative, but i thought about the issue for quite a while, and I need a proper KVM over IP solution it just has to be cheep.

PhilippMacGeyer:
hmm... ok thas a posibility, but there are a few problems

  1. USB 2 VGA adapters work only after the BIOS initialised the driver, so no bios level access.

So how does my USB keyboard (and USB mouse, on my 64bit machine) allow me to access BIOS?

Henry_Best:

PhilippMacGeyer:
hmm... ok thas a posibility, but there are a few problems

  1. USB 2 VGA adapters work only after the BIOS initialised the driver, so no bios level access.

So how does my USB keyboard (and USB mouse, on my 64bit machine) allow me to access BIOS?

modern BIOSes have generic HID drivers integrated, thay can recognize usb mouse and usb keyboard,
moderner BIOSes have also generic storage drivers alowing you to boot from USB.
but they don't have generic USB video drivers, to my knowledge there are even no generic USB video drivers standardized yet.

I know I'm resurrecting an ancient topic but the responses seem to "not get it", but if the OP is still alive then I actually feel like doing the same kind of project.

Why? Yes there are options like VNC etc but what you really want a lot of the time is completely out-of-band management. If your PC has no screen or keyboard attached, how do you install an operating system onto it or fix it if it decides not to boot up? By using an IP KVM, that's how. And they're super expensive, and they all always have completely terrible software. So why not make an open source project?

I looked into the VGA specifications, and essentially what is required is an A/D converter capable of sampling at at least 48Mhz (for 640x480). You also need some fast memory to buffer that into, so the usual Arduino boards are a no-go. But, the Due and Zero might just be! Only problem is their on-board ADC's are far too slow, so right away this isn't going to be in the budget category, but hopefully we can beat the markup of Raritan etc.

Then I came across this little guy, the AD9984 by Analog Devices http://www.analog.com/en/products/audio-video/analoghdmidvi-interfaces/analog-hdmidvi-display-interfaces/ad9984a.html#product-overview and surprisingly they don't seem that expensive, about $15 each in single quantity.

So, my thinking is bolt some DRAM onto a ATSAM4S16CA-AU and connect that to the AD9984 with undefined magic, and end up with an IP KVM, maybe... Or just learn how to use FPGA's and do it all there (but they look very expensive too).

Thoughts?