My surface laptop has only one USB-A and one USB-C port. How do I connect HDMI for screen sharing and USB-C for mouse and keyboard control on my laptop? I connected a multiport which accepts USB-C and HDMI to USB-C of my laptop, but mouse and keyboard are not responsive. But I can see a screen of my PC. Could you please help?
You MUST use the USB-A side of the OTG cable to connect to your Surface, even if you have to go through a USB-C to USB-A adapter or plug into a hub/dock that provides USB-A and HDMI. If you plug in a USB-C to USB-C cable to the OTG port in almost all cases you won’t get a proper connection for the PiKVM to control your device.
If you try the USB-A connection to another device you have available (even a game system) and aren’t able to get a proper sync and control of keyboard and mouse inputs to the device, there’s a low chance there is an issue with the OTG port, but you should unplug and replug the cables and make sure they are fully seated on both ends and test with multiple devices.
USB-C power delivery capable cables include a special “e-marker” which is a resistor that prevents a power source from sending more power than a power delivery receiver can handle, but that interferes with the OTG capabilities which require a “dumb” cable that doesn’t have the resistor, and but this is also why it is inadvisable to plug in random USB-C to USB-C cables to that port, because without the e-marker a power delivery source could accidentally fry the PiKVM’s OTG port.