I bought a cheap HDMI switch; pressing the button cycles through Inputs 1, 2, and 3 to the same output. I like to keep my home laptop closed on my desk with my work laptop open on top of it, and my external monitor switching between the two. If I use both HDMI inputs on the monitor, my home laptop recognizes that it is still connected, even if I am viewing my work laptop, and does not go to sleep.
The problem, though, is that the HDMI switch is cheap. When I'm using the switch and switch away from my (closed) home laptop, the switch shuts off all signals to the laptop; the laptop subsequently recognizes that it has no longer has a display connected, and since it is closed it just goes to sleep. I now have a chicken-and-egg problem: I can't wake the computer via USB keyboard because it has no display attached, and the HDMI switch won't switch to that laptop because it is asleep and outputs no signal.
My question is: how does the laptop detect that HDMI is connected? If it is as simple as seeing +5 volts on the correct pin, I can simply tie all three +5 volt pins together so my laptop will still think it is plugged in and therefore not go to sleep. If it's a more complicated way (e.g. some kind of data transfer between laptop and monitor) then I might be out of luck.