<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Oct 31, 2014 at 4:11 PM, Tom Lichti <span dir="ltr"><<a href="mailto:tom@redpepperracing.com" target="_blank">tom@redpepperracing.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span class="">On Fri, Oct 31, 2014 at 3:47 PM, Justin Alcorn <span dir="ltr"><<a href="mailto:justin@jalcorn.net" target="_blank">justin@jalcorn.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><span>On Fri, Oct 31, 2014 at 3:43 PM, Andrew C. (AFPup) Stadt<br>
<<a href="mailto:acstadt@stadt.ca" target="_blank">acstadt@stadt.ca</a>> wrote:<br>
><br>
<br>
>> My setup: TWC with Cisco STB. Ubuntu 14.04.1 and MythTV 0.28<br>
>><br>
> I used to do something like that though I was doing something like R.G.<br>
> suggested to see if the tuner was in use, and if not then running the<br>
> script. I (accidently) discovered one day that my STB also supported the<br>
> same ir command set as dish network boxes, and that the dish commands<br>
> included a discrete power-on command (versus power toggle). So, just made my<br>
> channel change command include a power-on command first.<br>
><br>
> Just something to think about.<br>
<br>
</span>I spent a bunch of time trying to find a power-on command for my STB.<br>
No such luck.<br>
<div><div><br></div></div></blockquote><div><br></div></span><div>Even though I record my SA4250 via an HD-PVR, I can send the power-on through firewire, so that's what I do in my channel change script, as I did not find a discrete 'power on' message via IR, it is a toggle. If I could find a power on only IR command, then I'd use that.</div></div></div></div>
<br>_______________________________________________<br>
mythtv-users mailing list<br>
<a href="mailto:mythtv-users@mythtv.org">mythtv-users@mythtv.org</a><br>
<a href="http://www.mythtv.org/mailman/listinfo/mythtv-users" target="_blank">http://www.mythtv.org/mailman/listinfo/mythtv-users</a><br>
<a href="http://wiki.mythtv.org/Mailing_List_etiquette" target="_blank">http://wiki.mythtv.org/Mailing_List_etiquette</a><br>
MythTV Forums: <a href="https://forum.mythtv.org" target="_blank">https://forum.mythtv.org</a></blockquote><div><br></div><div>This is the script I use to check my stb, its toggle power:</div><div><br></div><div> #! /bin/bash</div><div><br></div><div># Authored by Evuraan_AT_gmail_DOT_com</div><div><br></div><div># ABSOLUTELY NO WARRANTY, to the extent permitted by</div><div># applicable law.</div><div><br></div><div># YMMV.</div><div># Use at your own risk.</div><div><br></div><div><br></div><div>lirc_socket="/var/run/lirc/lircdSerial"</div><div>pvr="/dev/videopvr150"</div><div>t="$RANDOM-$RANDOM"</div><div>out="/tmp/$t.mpg"</div><div>mark="1727"</div><div>blank="0"</div><div>say="/usr/bin/logger -p info -t mythstb-check"</div><div>POWEROFF="0"</div><div>POWERON="0"</div><div>#wakeup="/usr/bin/irsend SEND_ONCE DCT700 POWER"</div><div>wakeup="/usr/bin/irsend -d ${lirc_socket} SEND_ONCE DCT700 POWER"</div><div>#info="/usr/bin/irsend SEND_ONCE DCT700 info" </div><div>info="/usr/bin/irsend -d ${lirc_socket} SEND_ONCE DCT700 info"</div><div><br></div><div><br></div><div><br></div><div>send_power_on() {</div><div>$say "`date` STB seems to be turned off, last count was $blank, attempting to Power it on" &</div><div>$wakeup 1>/dev/null 2>/dev/null || :</div><div>sleep 2</div><div>}</div><div><br></div><div>scan_images(){</div><div>for i in `echo /tmp/$t*.jpeg`</div><div>do</div><div>if [ -s "$i" ]</div><div>then</div><div>#blank="`jp2a $i --invert --size=72x24 | sed -e 's/./& \n/g'|grep -c "M"`"</div><div>blank="`jp2a $i --invert --size=72x24 | sed 's/W/M/g' | sed -e 's/./& \n/g'|grep -c "M"`"</div><div> rm -f "$i" 1>/dev/null 2>/dev/null || :</div><div>else</div><div> :</div><div>fi</div><div>[ "$blank" -gt "$mark" ] && export POWERON="100"</div><div>[ "$blank" -le "$mark" ] && export POWEROFF="100"</div><div>done</div><div>if [ "$POWERON" -eq "100" -a "$POWEROFF" -ne "100" ]</div><div>then</div><div># its off</div><div>send_power_on</div><div>else</div><div># power is on, non blank frames</div><div>$say "`date` STB seems to be turned on, last count was $blank"</div><div>:</div><div>fi</div><div><br></div><div>}</div><div><br></div><div>purge_stuff(){</div><div>[ -f "$out" ] && rm -f "$out" 1>/dev/null >/dev/null || :</div><div>}</div><div><br></div><div>#ivtv-tune -c 3 -d "$pvr" 1>/dev/null 2>/dev/null &</div><div><br></div><div>cd /tmp</div><div>$info &</div><div><br></div><div>dd if="$pvr" of="$out" bs=64K count=2 1>/dev/null 2>/dev/null</div><div><br></div><div>if [ -s "$out" ]</div><div>then</div><div>ffmpeg -i $out -f image2 -vcodec mjpeg /tmp/$t%d.jpeg 1>/dev/null 2>/dev/null</div><div>[ -s "/tmp/${t}1.jpeg" ] && scan_images</div><div>else</div><div>$say "`date` Unable to query $pvr, as it seems to be in use."</div><div>:</div><div>fi</div><div><br></div><div>purge_stuff &</div><div><br></div><div><br></div><div>and it is called by the channel change script.</div></div><br></div></div>