So I actually bought the Flirc recently and so far I've set it up so my LG tv remote control will communicate with my homebridge automation server to go to the YouTube app if I press the red button, go to the BBC iPlayer app if I press green, turn on our living room lamp if I press yellow and go to Plex if I press blue. I haven't bought a HDMI switch yet, but if I could find one that is wi-fi controllable and it can communicate with homebridge then that will avoid the need to send IR signals to a switch