View Full Version : Unattended batch capture from DVR w/ Girder + UIRT

June 15th, 2005, 01:10 AM
Greetings all,

My cable company, Comcast, wll rent you a cable box, for an extra $10/month, with a builtin DVR (Motorola DCT6412) which provides TIVO-like functionality. The box has assorted ports which, as I understand it, could have been enabled by the Comcast-provided UI software to allow retreiving saved programs from the DVR to a PC; but enabling such features would surely so alienate Comcast's copyright-mongering bedfellows that there's probably little chance they ever will.

So if you want to retrieve shows off of the thing you've got to do it the old-fashioned way: record them as they play back. But right now I've got like 43 episodes of SCTV that have been playing on TV Land for the last couple months & there is no way I want to have to personally operate the video capture program I like to use to get them all off of there -- nor can I tie up my "fast" machine to do this kind of mass capturing during waking hours.

Enter Girder. I have put together a Girder group that uses a daisy chain of Alarm Timer commands to control the DVR box w/ a USB-UIRT, and also control ATV2000 (a TV & capture program with some darn good features), to record a sequence of programs from the DVR completely unattended. The programs to record are specified by a string variable like "9,10,13,17" in a Config script. Start it going & it advances to and plays each show in turn, and sends keys to ATV2000 to record each one.

Going to give it a shot tonight to see if it can successfully record say 4 shows as modestly compressed XViD while I sleep. Would like to upload this command group when it's working well; could be adapted by users with similar batch capturing needs, even if they have different hardware and/or a different capture program.

I just about fell out of my chair when I realized this would be doable. Praise Girder, etc.,

"What a time to be alive"

June 15th, 2005, 06:56 AM
:D, let us know how it works...

June 15th, 2005, 08:02 PM
I also have a Comcast DVR box and am trying to figure out how to make Girder send the commands to the DVR box to start playing the next show every 32 minutes, since every show thats on it is 30 min long. I have been useing Intervideo WinDVD 5 to record shows because thats what came with my Plextor PX-M402U. If you figure this out please post how you did it. All help is greatly appreciated!

June 15th, 2005, 10:24 PM
It did work! I set it up to record 3 shows and it recorded 'em and moved/renamed the files. (Pity that I screwed up the ATV2000 capture settings and got 3 .avi files with bad audio sync, but I'm used to that kind of frustration with video capture -- I know the Girder trickery is working).

As I said in my first post it hinges on a chain of Alarm Timer commands that each fire some action command, wait their delay, and then fire the next Alarm Timer command.

Another important part of it is some Lua which accomplishes skipping to each show in the program list. It sends just enough PgDn and Down signals from the UIRT to move down to the current program, pausing about a second between each.

I will definitely submit the whole group soon -- I just want to clean it up a bit.

"Moon pie. What a time to be alive."

July 11th, 2005, 12:55 AM
I have just uploaded my Unattended Batch Capture group, after cleaning things up a bit and adding the capability to optionally move/rename the capture files on a show by show basis. I've already begun using it to extract 47 saved episodes of SCTV from my DVR box.

Finishing it was delayed by the not-so-tragic, mercifully gradual demise of my main drive... yet now that I've moved into a cavernous new 120 gig drive, I don't need the ability to move files to different drives so much, heh.

Anyway, it's uploaded to the program groups collection, and attached to this post. Behold the overblown readme!


TPC / 20050710N
Unattended Batch Capture (v1.0) for Girder 3.3 + USB-UIRT

This is a Program Group for Girder 3.3 which performs unattended batch video
capture of stored programs from a device like, say, the DCT6412 DVR CATV
Converter available from Comcast in southeastern Pennsylvania, using a
capture program like, oh, say, ATV2000, with the help of a USB-UIRT
(Universal Infrared Receiver/Transmitter) and its Girder plugin.

Load the .GML file into Girder or Import it into your main Girder .GML.

As-is, the group requires the following Girder Plugins to be installed and
enabled: 'AlarmTimer' and 'USB-UIRT driver'.

Probably extensive. The group comes configured to control my particular
hardware and software -- i.e., a Comcast DCT6412 DVR and ATV2000. As a
matter of fact, it comes configured to record 8 episodes of SCTV from my
particular instance of a Comcast DCT6412. But I've tried to organize the
group in such a way as to make it a decent starting point for users with
other gear.

Changes will be needed throughout. Adapting this group for use with other
hardware and software might turn out to be about as difficult as creating it
from scratch. Heck, just throwing the idea of doing this out there to other
Girder users was probably enough (I had a USB-UIRT and a DVR box for more
than a month before it dawned on me that this would be doable).

See below for clues about how it's supposed to work, and see below that for
a checklist of things that might need customization for use with different

The playback and capture is orchestrated by the daisy chain of Alarm Timer
commands contained in the subgroup called Program. Each Alarm Timer
generally fires one of the commands from subgroup Actions, waits its
configured delay, and then calls the next command below it in the Program

At least one line in the Program subgroup in fact isn't an Alarm Timer; it's
a Goto that jumps to a sequence of commands in the Subroutines subgroup,
which then jumps back to continue with the next Program line. The
"subroutine" in question is the script and set of commands which send PgDn
and DownArrow commands to the DVR box to skip to the correct stored show.

This was done simply for the sake of organization; this way the Program
subgroup stays nice and linear-like.

Individual commands to do things like navigate through the DVR box's
interface and control the video capture program were put into the Actions
subgroup. They are generally invoked from Alarm Timer and Variable
Manipulation Script commands in the Program and Subroutines groups.

The batch capturing process is started by triggering the Start multicommand
in the "Start and Finish" subgroup. It comes bound to a user-defined Girder
event, but that's just as a demo (you can even just right-click the Start
multicommand and do "Test Command" to kick things off).

The Finish multigroup is executed by the final line in the Program subgroup.
As given, it's not really even necessary.

Anyone interested in modifying this group to serve their own purposes should
do at least the following:

Change the USB-UIRT commands in the subgroup given as "Comcast DVR" to
create a set capable of sending the remote codes which will be needed to
control your particular playback device (or use any other kind of Girder
commands as needed; who knows what kind of playback device might be used).

Change the Girder commands in the subgroup given as "ATV2000" to create a
set which can operate whatever video capture program will be used. ATV2000
was easy -- all I had to send to it were keystrokes.

Examine each "line" in the Program subgroup. Add or remove lines and adjust
timer delays as needed to create a solid program which will coordinate the
playback and recording progress with your gear. The supplied program works
for me.

Note the quaint "line numbers" in the Program subgroup; they are only there
for reference/nostalgia -- the commands happen in sequence only because they
form a linked chain of Alarm Timer and Script commands. Don't forget to
maintain these links when adding or removing lines in the program. And
don't forget about links from outside the Program subgroup that come back
in, say from Subroutines.

The "Navigate to Show" script might need changes; as written, it coordinates
sending PgDn and DownArrow commands to my DVR in order to skip to the
current show in the batch list. If your gear has a radically different way
of navigating to a show, you might be in for some Lua editing (I hope the
comments are helpful).

USAGE (once customized for your hardware/software)
The "Start and Finish" groups's Start multigroup contains a script called
Config. Within in are several variables which control which shows to play
from the DVR and what filenames to give to the capture program's output file
when it is renamed.

A numeric series of filenames and/or several unique filenames can be
specified. Unique per-show filenames can be given to move capture files to
different drives or partitions if you're choked for space (like I was before
the mercifully-slow drive crash that delayed finishing this thing).

Comments and examples in the Config script explain how to set the episode
list & file renaming variables.

Once configured, trigger the Start multicommand and let 'er rip, so to

ATV2000 http://mikecrash.wz.cz/
TV and Capture program with lots of great features

FFDShow http://ffdshow.sourceforge.net/
Capture codec for encoding many video and audio formats including DivX and
XviD. Great, useful DirectShow playback features too.

VirtualDub http://www.virtualdub.org/
Capture, trim, edit, and reencode video with this popular freebie

Girder 3.3 http://www.promixis.com/
USB-UIRT http://www.usbuirt.com/
Lua 4 http://www.lua.org/manual/4.0/

For now, this program group only supports capturing a series of shows of
equal length -- say, a bunch of half-hour episodes. That was fine for what
I needed. You can imagine hacky ways around this limit (say, clone the
whole group, change the duration for the timer in the clone, and chain them
together using the Finish commands), but it would be nice to add an optional
duration element in the show list variable. That would require using
something other than the AlarmTimer, which can't use registers or variables
in its timeout arg; the Timer object in WinLuaEx for instance.

Happy capping! Praise Girder!

TPC (Frostillicus)