[mythtv-users] Wrote Script to Power on Cable Box

jr jraymyth at gmail.com
Mon Jun 25 16:43:18 UTC 2012


On Mon, Jun 25, 2012 at 11:35 AM, Joe Hickey <jfwd at phlobus.net> wrote:
> On Mon, Jun 25, 2012 at 10:40 AM, jr <jraymyth at gmail.com> wrote:
>> I have been having trouble with my Cable Box shutting off on a weekly
>> basis.  Usually at some point during the weekend so that Sunday or
>> Monday night shows are lost.  After a bit of research, I finally sat
>> down last night and wrote a script to cat from my HDPVR into a file
>> for 5 secs, then check the file size.  If its zero, then I use my
>> channel change script to power on the tuner. Is that going to work
>> with any type of reliability?
>>
>> jr
>
> Don't know if checking for zero size is going to work, since a
> continual black screen encoded into whatever video format is probably
> going to be nonzero size.
>
> I have a power-on script that records for a few seconds, then uses
> ffmpeg to dump frames to individual files at 1fps.  By converting to
> ASCII-art file format (there is a tool to do this, I forgot the name)
> it is very easy to check for a black screen.  If all frames are black
> then you can be pretty sure the power is off.  It then sends the POWER
> command and loops back to the beginning to check for non-black frames
> again.
>
> I also use this concept/modification of this script to confirm channel
> changes -- blast the "INFO" key and the cable box puts the channel# at
> a predictable location on the screen, which I can crop out and pass
> through gocr and check the number.  All this nonsense because I'm
> stuck with TW cable, all channels encrypted, and an unreliable cable
> box that periodically just plain ignores the channel change or reboots
> itself.
> _______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://www.mythtv.org/mailman/listinfo/mythtv-users

It *seemed* to work, but the issue that you raised was implied by
another post, which is why I was questioning my work.   I just
remembered that there is a mini-pci slot on my MB.  I will probaly put
a fire wire into it.


More information about the mythtv-users mailing list