I have OSMC connected to my TV via an HDMI switch with auto switching capabilities.
Are there any commands that can be sent (via SSH or API) to force the HDMI switch to change to the correct HDMI input for OSMC? I believe something similar could work with CEC, however my TV is a good 5 years old and doesn’t have that feature. Usually restarting the RaspberryPi completely forces the HDMI switch to change to the correct input. But that’s a time consuming method that’s less than ideal.
That’s a really good idea but unfortunately that doesn’t seem to work. I might have to resort to doing a hard restart each time. There must be some sort of command or loss of signal on the HDMI that happens during a restart. Which then in turn the HDMI switch picks up on and changes to a different input.
The issue is that as my TV only has 2xHDMI inputs I’m having to use a HDMI switch. So in this case I wouldn’t be able to use the TV remote to switch to OSMC.
Out of interest, how does doing a hard-restart cause damage to the SD card?
I’m assuming you mean pull the plug, when you say hard reset; rather than restarting via the command line.
If the pi is powered off, with out being shutdown properly: a process may be reading or or writing to sd card; if stopped by power outage can lead to corruption of data.