At home I have the following setup: A PC with three screens. For watching movies or gaming, I use a projector with a console, and for the input setup, I use an AV receiver. Sometimes, I want to connect my PC to the projector. For this, I use an HDMI switcher. This requires me to climb under my desk to switch the input source. It became annoying, so I decided to make things smart using Home Assistant to control devices at home.

Due diligence
Before I delve into a new project it is always a good idea to check if something similar is out there. So I used the help of the AI to see if there is something existing already out there..

This quick search yielded two promising projects. One was a custom PCB sold pre-assembled. It was not too expensive, but it did not feature the one-in, two-out setup I require. The other option was to hack an existing off-the-shelf component by soldering in an ESP32 controller. As I enjoy doing such small soldering projects like this, I selected the second option.
Hacking
The switch was ordered fast but after disassembly I noticed that the board internal PCB differs from the one used in the projects repository. As I lack some the required skills PCB design and setup I here tried out to use the AI again to assist me in finding the new connections. After a quick prompt I got some suggestions what to test and measure and if I can use the different test pads on the new revision.

This instruction was followed by a suggestion to upload pictures of the PCB, to enable further inspection by the AI. So I did. The AI managed to spot a pad labeled SEL that I had failed to see during the initial prompt. After some probing, it became clear that this pad was low if HDMI port 1 was selected, and high if HDMI port 2 was selected. It was also able to confirm earlier assessments and map the other components.
The tactile switch has 4 through-hole legs, soldered on the back (the four pads in the middle of photo 2). That is the easiest place to attach your toggle wires, and you don’t need to touch the front at all.
Ultimately, the plan was to use the SEL pad to read the current state and an NPN transistor across the two upper button pads to detect button presses. In the original repository, I found a reported issue that described the same problem I was facing: a different PCB revision. IFD3 solved the problem by using a transistor. He also provided detailed instructions and images. This helped me validate my plan and proceed further.
Putting things together
In the end I decided to follow the approach of IFD3 as it used the least amount of components and was able to fit into the original case.

One software piece missing, was to update the ESP32 controller code. The wiring was different from the original projects config. ESPHome offers a great and simple abstraction layer to quickly program the ESP32 and with the help of the AI a new config was created. The hack is invisible from the outside as the original case can be used and power comes via the HDMI port. To document this, I forked the original repository and updated the images, controller config and readme. This allows anyone who wants to solve the same issue in the future to replicate the same hack we did.
One Day Projects Side Note: Sourcing takes time. Although I had all the parts at home or had ordered them, I noticed that I did not have a transistor. I complained to a friend about this, and he told me that he had encountered a similar problem when he couldn’t find a transistor. He bought a kit with 200 transistors and was able to provide me with one. Thanks!