PDA

View Full Version : DTV Serial command set conversion



snipeman
November 4th, 2003, 12:54 PM
Hi, I don't currently run Girder and have a problem that I think it might be able to help with.

Please forgive me if this has already been addressed: there's a lot of information to assimilate here. OK, here's my problem:



I own a Replay TV, which has serial out control to tune a Direct TV STB. Unfortunately, the maker of ReplayTV won't update it to work with the newer command set.

The Replay only puts out DTV serial control for 5th gen recerivers or earlier. Some manufactures on 6th gen and newer sadly changed the format of the command set.

Many of you are famililar with the details of the new command set, contained here: http://www.pcmx.net/dtvcon/

My question: could I use Girder to receive the OLD DTV serial commands out of the Replay TV, and output them on another serial port with NEW commands that are required by a 6th gen STB. Is anyone doing this with Girder?

Here's a Perl script that does this, but requires LINUX to work:

http://www.lobstein.org/~mike/tivo/download.php

I want to do this with Girder on my already existing HTPC, and not need to create a whole new PC for just this purpose.

Thanks for any help,

Andy

JimHugh
November 4th, 2003, 01:09 PM
Perl runs on on Windows as well.

http://www.activeperl.com/

snipeman
November 4th, 2003, 01:55 PM
The implementation of PERL in Windows does not support the serial commands used in the TIVO Translate utility.

I actually tried running the perl script with activeperl and it doesn't work because of the lack of serial support.

I was hoping for a Girder solution. Is this possible?

JimHugh
November 4th, 2003, 02:00 PM
Yes it is possible!

You would need to download and install the Generic Serial Plugin.

Then in the the receive script you would need to use TriggerEvent to trigger the correct Girder command using the plugin or use SERIAL_SendData in Variable Manipulation Script directly to send translated serial commands.

There is a GML file available for download here that has the older generation commands. I have one that I tried to modify to use the newer command set that I have emailed to a couple of people but have not received responses back as to how well it works.

JimHugh
November 4th, 2003, 02:05 PM
While I am a HUGE proponent of Girder, Perl may still be an OK solution,

Just change the lines in the TivoTranslate.pl script



#DSS serial port
$dss_port="/dev/ttyS0";

#TiVo serial port
$tivo_port="/dev/ttyS1";

#to

#DSS serial port
$dss_port="COM1";

#TiVo serial port
$tivo_port="COM2;



From the http://www.xav.com/perl/faq/Windows/ActivePerl-Winfaq8.html


How do I read from and write to serial ports?
Serial ports can be opened just like files in ActivePerl. To open COM1, just do this:

open( PORT, "+>COM1" ) or die "Can't open COM1: $!";

You should be able to read from and write to the file handle using the standard I/O functions (read() and print()), but not the system functions (sysread() and syswrite()).

It has been noted (but not tested) that modems that use the Hayes command set require a carriage return (\r) rather than a line feed (\n) at the end of the command.

snipeman
November 4th, 2003, 08:16 PM
Jim,

Thanks for the time and your several responses. I think I'll try your PERL suggestion first. I still want to run Girder for my HTPC (and to control my Panny plasma) but I'm not quite "ready" for that phase yet.

If your suggestion of the COM string edit works, the perl script should hold me for a while.

Thanks,

Andy

snipeman
November 4th, 2003, 08:23 PM
Jim,

I read what you sent a little closer.

The FAQ on Activeperl said: "You should be able to read from and write to the file handle using the standard I/O functions (read() and print()), but not the system functions (sysread() and syswrite())."

TivoTranslate does indeed use sysread and syswrite. Can you suggest any other changes to get around this?

Andy