|
|
Status: Mainly complete. I think that the information in this page is correct, but I will review it again later. If you have any comments, please contact me
This is part of a series of documents about how to set up TV reception on FreeBSD. In most countries, you can get programme guide data with xmltv, available in FreeBSD as /usr/ports/textproc/p5-xmltv, but that doesn't support Australian TV guide data. For that you need the port /usr/ports/multimedia/tv_grab_au. This page is a version of the instructions by William Uther, adapted to FreeBSD.
tv_grab_au --configure --config-file ~mythtv/.mythtv/<InputSourceName>.xmltvand creates a default config file for you. <InputSourceName> is the name you selected in the previous step. In the following examples I use the name that I have chosen in my setup, Antenna.
--- .mythtv/Antenna.xmltv~ Sat Mar 3 10:54:25 2007 +++ .mythtv/Antenna.xmltv Sat Mar 3 11:02:52 2007 @@ -11,8 +11,7 @@ information for those data services with which you have registered. --> -<login provider="icetv" user="MyIceTVUserName" password="myIcePassword" filter="false"/> -<login provider="tvguide" user="MyCamelCaseName" password="myTvguidePassword" filter="false"/> +<login provider="tvguide" user="UpandDown" password="GoodOne" filter="false"/> <!-- There are two ways that the script can now be used. If the attribute 'filter' @@ -92,6 +91,13 @@ attribute works very much like an offset in that case. --> + <channel display="31-Adl" tvguide="31-Adl"/> + <channel display="ABC-SA" tvguide="ABC-SA"/> + <channel display="ABC2" tvguide="ABC2"/> + <channel display="Nine-SA" tvguide="Nine-SA"/> + <channel display="SBS-SA" tvguide="SBS-SA"/> + <channel display="Seven-SA" tvguide="Seven-SA"/> + <channel display="Ten-SA" tvguide="Ten-SA"/>The names of the channels are what chose from your guide data provider. These ones are correct for South Australian listings from tvguide.org.au. The comments tell you that the list of channels at the end is optional, but it isn't for MythTV. If you don't enter this list, MythTV won't understand any of the data.
2007-03-03 11:09:19.595 New DB connection, total: 3 2007-03-03 11:09:19.597 Connected to database 'mythconverg' at host: localhost Aborting: Config file does not exist: /home/grog/.mythtv/Antenna.xmltv Do you need to run with --config-file or --configure? 2007-03-03 11:09:19.970 ------------------ End of XMLTV output ------------------ Error in 1:1: unexpected end of file 2007-03-03 11:09:19.976 Updating icons for sourceid: 1 2007-03-03 11:09:19.979 New DB connection, total: 4 2007-03-03 11:09:19.982 Connected to database 'mythconverg' at host: localhost Updated programs: 0 Unchanged programs: 0 2007-03-03 11:09:20.111 New DB connection, total: 5 2007-03-03 11:09:20.113 Connected to database 'mythconverg' at host: localhost 2007-03-03 11:09:20.119 Failed to fetch some program info ... =============================================================== | Attempting to contact the master backend for rescheduling. | | If the master is not running, rescheduling will happen when | | the master backend is restarted. | =============================================================== 2007-03-03 11:09:24.793 Connecting to backend server: 192.109.197.177:6543 (try 1 of 5) 2007-03-03 11:09:24.799 Using protocol version 30 2007-03-03 11:09:24.855 mythfilldatabase run complete.
In other words, don't assume by the messages at the end that the run has been successful. In this case, the run was a complete failure, caused by not setting up the configuration file (only the default file, ~/.xmltv/tv_grab_au_reg, was present).
$ mysql mythconverg Welcome to the MySQL monitor. Commands end with ; or \g. ... mysql> SELECT chanid, channum, freqid, callsign, name FROM channel; +--------+---------+--------+----------+----------+ | chanid | channum | freqid | callsign | name | +--------+---------+--------+----------+----------+ | 1006 | 31 | 548250 | 31-AD | 31-Adl | | 1001 | 2 | 64250 | ABC-S | ABC-SA | | 1007 | | NULL | ABC2 | ABC2 | | 1003 | 9 | 196250 | NINE- | Nine-SA | | 1005 | 28 | 527250 | SBS-S | SBS-SA | | 1002 | 7 | 182250 | SEVEN | Seven-SA | | 1004 | 10 | 209250 | TEN-S | Ten-SA | +--------+---------+--------+----------+----------+ 7 rows in set (0.26 sec)This is the information you want to see, and if you have it, you're done. Note that the guide data includes ABC2, which is a digital-only channel, so it doesn't have a channel number here.
You might, however, see something like this (this example is after running a different version of tv_grab_au):
+--------+---------+--------+-------------------+-------------------+ | chanid | channum | freqid | callsign | name | +--------+---------+--------+-------------------+-------------------+ | 1001 | | NULL | ABCSA | ABC SA | | 1003 | | NULL | CHASE | Channel Seven |
In this case, you need to update the table. You can do this in one of two ways:
$ mysql mythconverg mysql> drop table channel; mysql> source adelaide-channel.sql
+--------+---------+--------+-------------------+-------------------+ | chanid | channum | freqid | callsign | name | +--------+---------+--------+-------------------+-------------------+ | 1001 | | NULL | ABCSA | ABC SA | | 1003 | | NULL | CHASE | Channel Seven | | 1007 | 2 | 64250 | Adding Channel 2 | Adding Channel 2 | | 1013 | 7 | 182250 | Adding Channel 7 | Adding Channel 7 |
Use this data to update the tables. Here we update the data for ABC SA, channel 2:
mysql> UPDATE channel SET channum = 2, freqid = 64250 WHERE chanid = 1001; mysql> SELECT chanid, channum, freqid, callsign, name FROM channel; +--------+---------+--------+----------+--------+ | chanid | channum | freqid | callsign | name | +--------+---------+--------+----------+--------+ | 1001 | 2 | 64250 | ABC-S | ABC-SA | +--------+---------+--------+----------+--------+
When you've done with them, you can delete the scanned channels:
mysql> DELETE FROM channel WHERE name LIKE "Adding %";
If you run into this problem and find this information useful, please contact me and let me know the details and how you solved the problem.
$ mkdir ~/.xmltv $ tv_grab_au --configure
This creates a file ~/.xmltv/tv_grab_au_reg.xml. The configure script does not create the directory if it doesn't exist; it just dies with a stack trace that only a python hacker could love.
--- .xmltv/tv_grab_au_reg.xml~ Sat Mar 3 10:54:25 2007 +++ .xmltv/tv_grab_au_reg.xml Sat Mar 3 11:02:52 2007 @@ -11,8 +11,7 @@ information for those data services with which you have registered. --> -<login provider="icetv" user="MyIceTVUserName" password="myIcePassword" filter="false"/> -<login provider="tvguide" user="MyCamelCaseName" password="myTvguidePassword" filter="false"/> +<login provider="tvguide" user="UpandDown" password="GoodOne" filter="false"/> <!-- There are two ways that the script can now be used. If the attribute 'filter'
$ tv_grab_auThis outputs the guide data to stdout. I don't use this method, so I don't know what to do next.
Greg's home page | Greg's diary | Greg's photos | ||
$Id: tv_grab_au_reg.html,v 1.2 2007/03/04 14:31:52 root Exp $ |