2006-11-18, 03:56 AM
I use GBPVR on a dedicated PC that sits by the TV, and I use a laptop for myself. I also commute 1 hour to work each way; I wanted to set up a way to automatically update my ipod with the audio from shows recorded on GBPVR. I thought that others might be interested...
It's actually really easy...
1) I set up the GBPVR box to act as a webserver for an intranet, as itunes needs to lookup podcasts from an http:// address. I did this using APACHE
(available here:http://www.ricocheting.com/server/apache.html for instructions, and here: http://httpd.apache.org/download.cgi for the software). The ip address on your home network will be the location for the podcast address
2) To generate files for the podcast, I made the following batch file. It uses ffmpeg to change .mpg files to .mp3 files, and place the mp3 files in a podcast directory
Contents of batch file:
for %%I in ("E:\TV\The Daily Show With Jon Stewart\*.mpg") DO FOR /F "tokens=1-5 delims=/: " %%J IN ("%%~tI") DO "C:\Program Files\ffmpeg.rev6830\ffmpeg" -i "E:\TV\The Daily Show With Jon Stewart\%%~nI.mpg" "C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\podcasts\DailyShow\DS%%J%%K.mp3"
cd "C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\podcasts"
xmlerator "dailyshowtxt.txt"
Contents of "dailyshow.txt" which is in the same directory as xmlerator
[GENERAL]
basedirectory=C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\podcasts\DailyShow
rssfilename=Dailyshowpodcast.xml
linkbasedirectory=C:\Program Files\Apache Software Foundation\Apache2.2\htdocs
aggregatefiles=true
includesubdirectories=true
[RSS]
Title=Daily Show Podcast
Link=http://192.168.0.101/<DirectoryOffset><RssFileName>
Description=Daily show Audio Podcast
Category=TV
ItemTitle=
ItemLink=http://192.168.0.101/<DirectoryOffset><FileNameFull>
[FILEEXT]
mp3=audio/mpeg
3) The location of the mp3 files and metadata have to be wrapped up in an XML file that can be read by itunes. A file called xmlerator can create this xml file. This file is from the following website:
http://www.merage.uci.edu/~dvdotnet/xmlerator.html
The author of this file wrote it in C# (.net 2.0) and when it is run, it creates an XML file. There is an options file that indicates where the mp3 file is, what the name of the podcast is, and what the website is for the podcast. This file is invoked in the batch file above.
And that's it! This can be scheduled in the Windows task scheduler for after the show is on, and then in the morning, the podcast xml file will tell itunes to update with the new podcast. I haven't tried it, but probably this could be a method to create podcasts of videos for the video ipod (will need to convert to a compatible video format though).
It's actually really easy...
1) I set up the GBPVR box to act as a webserver for an intranet, as itunes needs to lookup podcasts from an http:// address. I did this using APACHE
(available here:http://www.ricocheting.com/server/apache.html for instructions, and here: http://httpd.apache.org/download.cgi for the software). The ip address on your home network will be the location for the podcast address
2) To generate files for the podcast, I made the following batch file. It uses ffmpeg to change .mpg files to .mp3 files, and place the mp3 files in a podcast directory
Contents of batch file:
for %%I in ("E:\TV\The Daily Show With Jon Stewart\*.mpg") DO FOR /F "tokens=1-5 delims=/: " %%J IN ("%%~tI") DO "C:\Program Files\ffmpeg.rev6830\ffmpeg" -i "E:\TV\The Daily Show With Jon Stewart\%%~nI.mpg" "C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\podcasts\DailyShow\DS%%J%%K.mp3"
cd "C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\podcasts"
xmlerator "dailyshowtxt.txt"
Contents of "dailyshow.txt" which is in the same directory as xmlerator
[GENERAL]
basedirectory=C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\podcasts\DailyShow
rssfilename=Dailyshowpodcast.xml
linkbasedirectory=C:\Program Files\Apache Software Foundation\Apache2.2\htdocs
aggregatefiles=true
includesubdirectories=true
[RSS]
Title=Daily Show Podcast
Link=http://192.168.0.101/<DirectoryOffset><RssFileName>
Description=Daily show Audio Podcast
Category=TV
ItemTitle=
ItemLink=http://192.168.0.101/<DirectoryOffset><FileNameFull>
[FILEEXT]
mp3=audio/mpeg
3) The location of the mp3 files and metadata have to be wrapped up in an XML file that can be read by itunes. A file called xmlerator can create this xml file. This file is from the following website:
http://www.merage.uci.edu/~dvdotnet/xmlerator.html
The author of this file wrote it in C# (.net 2.0) and when it is run, it creates an XML file. There is an options file that indicates where the mp3 file is, what the name of the podcast is, and what the website is for the podcast. This file is invoked in the batch file above.
And that's it! This can be scheduled in the Windows task scheduler for after the show is on, and then in the morning, the podcast xml file will tell itunes to update with the new podcast. I haven't tried it, but probably this could be a method to create podcasts of videos for the video ipod (will need to convert to a compatible video format though).