For the past year or so I've been using a KVM switch to be able to easily swap between my work computer and personal computer. This is great for having the same dual monitor and standing desk setup in my home office, regardless of what I am hacking on.

The Problem

The only problem was my custom keyboard(s) running QMK weren't recognized as a keyboard by the KVM, and only work in the USB hub port. The KVM does have a remote, but the IR is buggy and inconsistent. Having to reach across the desk and hit the number of the computer I want to control wasn't the end of the world, but was annoying enough that I found a solution.

The Solution

To fix the problem I had to disable n-key rollover in QMK. It turns out that keyboards that support more than six simultaneous key presses actually report as a USB hub, not a plain hardware keyboard (or something to that effect). I updated my config files in my custom key-map as follows.

if present, remove the following line from config.h

  #define FORCE_NKRO

add or modify the following lines in rules.mk

  NKRO_ENABLE = no # usb nkey rollover
  FORCE_NKRO = no

QMK + KVM Harmony

Once I made these changes and re-flashed my firmware, I was able to plug my custom keyboard into the hardware keyboard port on my KVM and everything just worked. I could now double-tap right control, followed by the number of the computer I wanted to switch to without issue.