<div class="gmail_extra"><div class="gmail_quote">2012/11/2 Joseph Fry <span dir="ltr">&lt;<a href="mailto:joe@thefrys.com" target="_blank">joe@thefrys.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br><div class="gmail_quote"><div class="im"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="gmail_extra"><div class="gmail_quote">But I have an other problem, before I suspend the machine I use to switch of the TV with a irsend command. But when I return from suspend mode the TV is off.</div>



<div class="gmail_quote"><br></div><div class="gmail_quote">I don&#39;t know how to manage this, do I need a special script to run before return from suspend? how could I check if the TV is off?</div><div class="gmail_quote">


<br></div></div></blockquote><div><br></div></div><div>I would use an IRSEND to power the tv back on when the system resumes from suspend (eg <a href="http://askubuntu.com/questions/141702/how-to-run-a-script-after-the-system-resumes-from-hibernate-suspent-to-disk" target="_blank">http://askubuntu.com/questions/141702/how-to-run-a-script-after-the-system-resumes-from-hibernate-suspent-to-disk</a>)</div>


<div><br></div><div> To determine if the TV is already on, there are several approaches you might take:</div><div>1. do an edid query (should only work if the tv is on)</div><div>2. use a serial cable, if your tv has a db9, and see if you get a response from the set.</div>


<div>3. ping the tv (assuming it has network connectivity)</div><div><br></div><div>I have also read that you could wire the tv&#39;s usb +5v and GND to a serial port&#39;s CTS and GND and sense the CTS status of the port using a python or C program... but that&#39;s far more complicated.</div>


</div>
<br></blockquote><div><br>Thanks <span name="Joseph Fry" class="">Joseph, I will try the first approach, I installed the &quot;ddccontrol&quot; package, but how could find the TV information?<br><br>Now I am not at home and the TV is off, this is what I get:<br>
<br># ddccontrol -p<br>ddccontrol version 0.4.2<br>Copyright 2004-2005 Oleg I. Vdovikin (<a href="mailto:oleg@cs.msu.su">oleg@cs.msu.su</a>)<br>Copyright 2004-2006 Nicolas Boichat (<a href="mailto:nicolas@boichat.ch">nicolas@boichat.ch</a>)<br>
This program comes with ABSOLUTELY NO WARRANTY.<br>You may redistribute copies of this program under the terms of the GNU General Public License.<br><br>Probing for available monitors...I/O warning : failed to load external entity &quot;/usr/share/ddccontrol-db/monitor/SNYC901.xml&quot;<br>
Document not parsed successfully.<br>...<br>Detected monitors :<br> - Device: dev:/dev/i2c-2<br>   DDC/CI supported: No<br>   Monitor Name: VESA standard monitor<br>   Input type: Digital<br>No monitor supporting DDC/CI available.<br>
If your graphics card need it, please check all the required kernel modules are loaded (i2c-dev, and your framebuffer driver).<br><br>Is there any other way to detect the TV? Maybe CEC?<br></span> </div></div><br clear="all">
Thanks and best regards.<br><br>-- <br>Josu Lazkano<br>
</div>