Twinhan Mini Ter Ubuntu Breezy Install

From MythTV

Jump to: navigation, search

1. Install Ubuntu 5.10 (breezy). Default install. If you have other operating systems then this is not covered, so you should figure this out yourself. I choose to do a custom install and create my own filesystem slices of certain size to suit myself, however you can do this too. Our host is called mythmbe (myth master backend).

2. vi /etc/network/interfaces Hash out existing line relating to dhcp assignment on eth0, and add the lines below it as shown.

# iface eth0 inet dhcp
iface eth0 inet static
       address 192.168.7.15
       network 192.168.7.0
       netmask 255.255.255.0
       broadcast 192.168.7.255
       gateway 192.168.7.254

3. vi /etc/hosts Add the following entry;

192.168.7.15    mythmbe.home.heimic.net         mythmbe

4. vi /etc/modules Add the following 2 lines;

dvb-bt8xx
dst
  • note

'dmesg | grep bttv' will tell you which card has been autodetected, if it says something like '*** UNKNOWN/GENERIC *** [card=0,autodetected]' you will need to add a module option to bttv to override the autodetection of the card by the driver. options bttv card=113 (add to /etc/modprobe.d/bttv?)


5. Modify /etc/apt/sources.list

mv /etc/apt/sources.list /etc/apt/sources.list.old

Now create a new one via

vi /etc/apt/sources.list

And populate it with the following entries;

# Ubuntu Breezy
#
# /etc/apt/sources.list
#

deb http://mirror.isp.net.au/ftp/pub/ubuntu breezy main restricted universe multiverse
deb-src http://mirror.isp.net.au/ftp/pub/ubuntu breezy main restricted universe multiverse

deb http://mirror.isp.net.au/ftp/pub/ubuntu breezy-updates main restricted universe multiverse
deb-src http://mirror.isp.net.au/ftp/pub/ubuntu breezy-updates main restricted universe multiverse

deb http://mirror.isp.net.au/ftp/pub/ubuntu breezy-security main restricted universe multiverse
deb-src http://mirror.isp.net.au/ftp/pub/ubuntu breezy-security main restricted universe multiverse

6. Now update package list from repository, issue the following command;

apt-get update

Now upgrade any packages that might need so, by the following command;

apt-get upgrade

7. Now we need to install some tools that will be needed later, as well as some usefull stuff. Issue the command below to obtain those packages we need.

apt-get install libwww-perl libdate-manip-perl xmltv mysql-server lynx wget ssh

7a. If you wish to have a password on the mysql root user, then now is the perfect time to set it. This is not needed, but I feel its important to atleast have it set to something. Issue the command below to create/set one.

mysqladmin password new-password

[new-password = your mysql root password]

Now to test it, issue the command below. When prompted for password, type it in and hit enter.

mysql -uroot -p

If it works you should be presented with the following prompt.

mysql>

8. By default the mysql install on ubuntu only binds to localhost, and if you plan on using a mythfrontend across the network, then we need to change this to bind on all interfaces. You can do this by editing the file below and making the changes suggested.

vi /etc/mysql/my.cnf

Find the following line in the file;

bind-address            = 127.0.0.1

Place a # infront of it. So that it looks like so;

#bind-address            = 127.0.0.1

Now save the file and exit.

9. Now its time to reboot, so reboot the box.

10. When the system is back you can confirm your tuner card is detected by looking in the output of "dmesg" like so;

[4294686.264000] bttv0: Bt878 (rev 17) at 0000:00:09.0, irq: 17, latency: 32, mmio: 0xe2000000
[4294686.264000] bttv0: detected: Twinhan VisionPlus DVB [card=113], PCI subsystem ID is 822:0001
[4294686.264000] bttv0: using: Twinhan DST + clones [card=113,autodetected]
[4294686.264000] bttv0: gpio: en=00000000, out=00000000 in=00f500ff [init]
[4294686.265000] bttv0: using tuner=4
[4294686.276000] bttv0: add subdevice "dvb0"
[4294686.276000] bttv: Bt8xx card found (1).

And you can confirm that the following devices exist;

ls -l /dev/dvb*

If you see adapter0, adapter1 etc. Then its pretty much going to work (and if it dont then we will find out down the track). If you have the correct card and have followed the steps above (it should work as mine does).

11. Now we need the script that will scrape the tv guide data, in this case I use the following one and can be obtained from the site below;

http://www.immir.com/tv_grab_au

In a command shell issue;

wget http://www.immir.com/tv_grab_au

This will download a copy and save it to the current dir, now we need to put a copy of it in the correct location for later use.

cp tv_grab_au /usr/bin

12. Now thats complete, we can install mythtv suite (and mythweb if you want it). Issue the following command to obtain it;

apt-get install mythtv mythweb

13. During the install if prompted for your mysql root password, then input it as requested.

14. Now we need to fix up something from earlier as its going to be used in next few steps, better to do this now and save having problem later.

mkdir /var/local/tv_grab_au
chown mythtv.mythtv /var/local/tv_grab_au
chmod 755 /var/local/tv_grab_au

15. Now we should have what we need installed, with the user your currently logged on as in a terminal window run the following;

mythtv-setup

16. To get channels to scan, be sure to add the following transports (these were for Sydney, NSW) other states/locations might vary. Consult dba.org.au

ABC    226500 (added as 226500000 - add 3 zeros to existing figures to make valid transports)
SEVEN  177500 (added as 177500000)
NINE   191625 (added as 191625000)
TEN    219500 (added as 219500000)
SBS    571500 (added as 571500000)

Then do a scan using transports only, and all channels should tune. If it dont then you could not be getting enough signal to complete the scan. Be sure to have a good strong antenna connection.

17. The xmltv ids used from the immir script are as follows

ABC   = nsw.abc.gov.au
ABC2  = abc2.abc.gov.au
SEVEN = sydney.seven.com.au
NINE  = sydney.nine.com.au
TEN   = sydney.ten.com.au
SBS1  = sydney.sbs.com.au
SBS2  = news.sbs.com.au

18. Once you have setup the video source section, it will produce a config file in the dir of the user your currently logged onto X as. The file will be in

/home/username/.mythtv/videosourcename.xmltv

Be sure to copy that file to

/home/mythtv/.mythtv/

As this file is used by /etc/cron.daily/mythtv-backend script and it expects it to be in the mythtv home dir.

19. If mythweb is not working after install check that the mysql passwd for the mythtv user (found in /etc/mythtv/mysql.txt) is populated into the /etc/mythtv/mythweb-* config files. Then restart apache2.

20. If you need help, contact me via purana (at) gmail (dot) com

Personal tools