
H₂H³ // Smart Twin USB Host Switch & Triple USB Hub & STM32 fourth USB peripheral
Hey everyone, I was tired of flaky commercial KVM switches, so I built a robust alternative for my desk. It toggles 3 USB 2.0 peripherals between 2 hosts.
The Tech: Driven by an STM32 managing the switching logic and driving an I2C OLED for real-time VBUS/current monitoring. The PCB is a 4-layer controlled-impedance board laid out in KiCad 9.0.
The Fun Part: Instead of just managing the hardware, the STM32 is wired natively into the USB hub as a 4th peripheral. This allows the host to talk directly to the MCU, opening up custom HID macro injections or automated switching scripts.
The KVM C++ firmware is about 95% finalized, and everything is 100% open-source (KiCad, FreeCAD 1.0 snap-fit case, and firmware). I'd love to hear your thoughts on the host-to-MCU link applications!
Code & CAD files are here: TwinUSB on Github ask me questions. What are you interested in?
Enthusiastic about open source: TwinUSB on Hackaday.io