Screenly Forum

Remotely turn on/off a connected TV

I am deploying a couple of Pis running Screenly OSE connected to normal LCD flat TVs used as monitors via their HDMI inputs. The displayed content is needed only during the working hours, (it is a social project in a community building I do for free), and I need to turn off the TVs when not used to save electric power for the hosting organization, the Pis can remain on and online the whole time.

My first idea is to cut-off the power to the TV set via a relay board that is connected to the Pi’s io ports.
I have made several such iot gadgets already, I use MQTT for the remote control, no problem with this part…

The problem is that no TV I know of ‘autoboot’ after reconnected to the power line, they need a separate turn-on signal sent from their remotes. This a problem also when an accidental power outage causes the TV to turn off, even after the power is restored, the TV needs to be turned on manually. In new models there is also a dead-man’s function that would automatically turn-off the TV after x hours of operation of not overruled manually, I hope this could be disabled (?)

Sending a ‘turn-on’ IR signal to the TV with my add-on board is an option, and it could also regularly reselect the HDMI input source on the TV set for being safe. (i could stick small plastic cover with an IR led inside on the TV’s IR sensor directly, this would also serve as blocking any outside IR signal of somebody messing with a remote), but the whole thing is getting too much complicated and my main concern is that how could I make this not depending on a particular TV model and manufacturer.

Do you guys have any advice how it could be done reliably, professionally?

I managed to find an easy solution using HDMI CEC signaling, luckily the Raspberry has the hardware for it already, and almost all modern TV sets also have CEC interface in their HDMI inputs.

Hi @matrix - glad you found a solution. Yes, we have some documentation for that here.

Your approach with CEC is probably the best approach for consumer grade monitors. Commercial monitors usually provide an RS232 interface for controlling the monitor. This is however rare in consumer grade monitors.

Do however note that if the power is off on the monitor when the Raspberry Pi reboots/boots, it will likely detect the wrong resolution.