HDMI Power Signal control


7 posts
by scape » Wed Jun 27, 2012 4:13 pm
I noticed that when my rpi boots my connected tv and stereo (setup to sense hdmi power signals) turns on and switches to the correct input. How can I accomplish this once the rpi is already running? I'd like to be able to turn on and off the tv with a python script/series of bash commands; unfortunately I haven't found anything specific on this, so I'm curious how I can get this to work. Perhaps shutting off and on the hdmi display port or even the display driver on rpi will suffice, but before I go any further I want to ask here.
Posts: 15
Joined: Wed Jun 27, 2012 12:09 pm
by dom » Wed Jun 27, 2012 4:18 pm
Look at /opt/vc/bin/tvservice

You might find there are more options if you update your firmware:
http://elinux.org/R-Pi_Troubleshooting# ... g_firmware
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 4105
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge
by scape » Wed Jun 27, 2012 10:56 pm
dom wrote:Look at /opt/vc/bin/tvservice

You might find there are more options if you update your firmware:
http://elinux.org/R-Pi_Troubleshooting# ... g_firmware



thanks for the info, looks like tvservice does not work for me, atleast the power on and off options don't. i'm curious how the rpi turns on my tv at boot..
Posts: 15
Joined: Wed Jun 27, 2012 12:09 pm
by dom » Wed Jun 27, 2012 11:03 pm
Did you update your firmware?

There is a bug in older firmware where you need to switch on before switching off.
https://github.com/raspberrypi/firmware/issues/53
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 4105
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge
by birdman » Sun Jul 01, 2012 10:55 pm
i'm curious how the rpi turns on my tv at boot..


If your TV is anything like mine it will because you have your TV configured to turn on when a new signal appears on an HDMI connector.
Posts: 17
Joined: Fri Nov 04, 2011 1:11 am
by scape » Sun Jul 08, 2012 2:17 pm
birdman wrote:
i'm curious how the rpi turns on my tv at boot..


If your TV is anything like mine it will because you have your TV configured to turn on when a new signal appears on an HDMI connector.


ahh ok, this could be why. i wonder how i can replicate this after the Pi is already running.


dom wrote:Did you update your firmware?

There is a bug in older firmware where you need to switch on before switching off.
https://github.com/raspberrypi/firmware/issues/53


I did not update firmware yet, but didn't notice its ability to turn off and on my set, only its ability to turn off and on the display video out (when off it's just a blank screen). I was more interested in power control.
Posts: 15
Joined: Wed Jun 27, 2012 12:09 pm
by AndrewS » Thu Jul 12, 2012 12:17 am
scape wrote:
birdman wrote:
i'm curious how the rpi turns on my tv at boot..

If your TV is anything like mine it will because you have your TV configured to turn on when a new signal appears on an HDMI connector.

ahh ok, this could be why. i wonder how i can replicate this after the Pi is already running.

Remove and reinsert the HDMI cable? ;)

dom wrote:Did you update your firmware?
There is a bug in older firmware where you need to switch on before switching off.
https://github.com/raspberrypi/firmware/issues/53

I did not update firmware yet, but didn't notice its ability to turn off and on my set, only its ability to turn off and on the display video out (when off it's just a blank screen). I was more interested in power control.

I believe tvservice uses the CEC commands http://elinux.org/CEC_(Consumer_Electronics_Control)_over_HDMI to do exactly what you're asking for. However it sounds like your TV unfortunately doesn't support CEC. Updating your firmware (using rpi-update) will also get you a newer version of the tvservice program.
User avatar
Posts: 3626
Joined: Sun Apr 22, 2012 4:50 pm
Location: Cambridge, UK