There are times, when mouse or keyboard won’t do the job on hand. Controlling applications sometimes needs special interfaces. A sturdy buzzer or wireless transmission is required. Sometimes, even switching a signal is required.
Nowadays, I would use an Atmel ATMEGA32U4 or even an ESP32 C3 or S3, if CPU power is required. I describe the solution mostly out of historic interest. It consists of components, that were never meant to run USB protocol but do it amazingly stable.

Years ago, when the above components were not available, I developped this PCB. It contains several modules that may come in handy to solve a special task.
The core element of the PCB is a free programmable USB HID device. No, joking, it contains an Atmel Tiny 45 controller. It features two pins, that may be independantly configured as input or output. Therefore it is also possible to signal a status or switch a device. To protect the connected PC, one of the inputs is available as isolated input.
Extensions may be powered through a voltage regulator which provides 3V output. The PCB may be equipped with an USB A plug or a cable.

The circuit is designed to be controlled by common open source software packages.
I provided a basic implementation that sends a left mouse click when shorting one of the inputs to ground. Other implementations were available on request.

I used this PCB to wireless control a Breeze Photobooth. The Yongnuo receiver I used, needs a 3V power supply, which is provided on the PCB.
I built a small batch of devices and still have a few PCBs lying around in the back of my cupboard. As said above, I wouldn’t build a HID device based on this platform anymore, but would do so with the above mentioned components. Please use the contact form to get more information on HID devices.