Status
Not open for further replies.

CASPER

New member
Mythtv and Ubuntu 8.10

--------------------------------------------------------------------------------

Thanks goes to dr_dred5 visiting S/M for this information on ubuntu 8.10

Mythtv and Ubuntu 8.10.

This is an updated howto for installing Mythtv on Ubuntu 8.10. In truth, there isn't a whole lot of difference between 8.10 and 8.04. If you already have a working setup, you aren't going to notice much of a difference. Plus 8.04 has long term support. (3 years) So I don't recommend upgrading unless you need to.

As usual I'd like to thank the coders at dvbn and to the folks here at fta-newbies.com who have tried my howtos and helped me refine them. (This means you!)

As usual, let me know if there are problems with it, so I can fix it.

I'm including the instructions for patching DN long term EIT. There is a full list of patches at


Code:
Code:
http://www.fta-newbies.com/forums/showthread.php?t=112159


I recommend taking a look at it to see what patches may apply to your setup. Thanks to Hoochster for proving the list.

The setup is similar to 8.04, but there are dependency issues as many of the packages have changed. I've included a workaround for this.

Here we go.

Note, all commands in terminal should be done with “sudo” (just in case I forget to add it)

First, let's install the Mythbuntu-control center. This isn't needed, but it's a handy tool for configuring extra features.

In a terminal,
sudo apt-get install mythbuntu-control-center

check to make sure your DVB card is detected.

Quote:
Code:
sudo ls -al /dev/dvb

The output should look something like this:

Quote:


Code:
dr_dred5@dr_dred5-desktop:~$ sudo ls -al /dev/dvb
drwxr-xr-x 3 root root 60 2008-02-21 08:19 . 
drwxr-xr-x 14 root root 14280 2008-02-21 08:20 .. 
drwxr-xr-x 2 root root 120 2008-02-21 08:19 adapter0

Note the “adapter0” on the bottom right. That means your card is detected and has the drivers installed.

If you don't see your card there, go to the wiki at



Code:
Code:
www.linuxtv.orgthey have great instructions on installing cards.

Enable restricted repository's

Open a terminal. Applications>Accessories>terminal.


Quote:
Code:
sudo gedit /etc/apt/sources.list


This will open your sources list. Make sure there are no “#” before Universe or Multiverse sources.
Save and exit

Update your system

Quote:
Code:
sudo apt-get update
sudo apt-get upgrade


Install all the necessary codecs and drivers. This will also promt you to install mysql. Enable all options. This is a long line of commands. Copy and paste the entire section! It may take a while to run.

*Note: I'm going to do this in two stages.


Quote:
Code:
sudo apt-get install libc6-dev kernel-package libqt3-mt-dev libncurses-dev libttf-dev libqt4-core libqt4-dev mysql-common mysql-server phpmyadmin xmltv xmltv-gui build-essential fakeroot qt3-dev-tools libqt3-mt-dev liblircclient-dev libasound2-dev libdts-dev libdvdnav-dev libxv-dev libxvmc-dev libxxf86vm-dev libqt3-mt-mysql libxxf86vm-dev libqt3-mt-mysql subversion libdvdread3-dev libsamplerate0 subversion libsamplerate0 liba52-0.7.4-dev liba52-0.7.4-dev libcdio-dev kdelibs4-dev flac libflac-dev libcdaudio-dev libxml-simple-perl libxml-rss-perl exif libexif-dev liblame-dev liblame0 lame libssl-dev devscripts openssl libssl-dev mercurial devscripts subversion linux-headers-$(uname -r) build-essential gettext rcconf unzip ncftp lynx feh openbox dvbsnoop fakeroot gstreamer0.10-fluendo-mpegmux gstreamer0.10-fluendo-mpegdemux gstreamer0.10-plugins-base gstreamer0.10-lame gstreamer0.10-ffmpeg lame sox ffmpeg mjpegtools vorbis-tools flac debhelper
Now install the dependency's specific to 8.10


Quote:
sudo apt-get install autotools-dev ccache comerr-dev dpatch libartsc0-dev libasound2-dev libaudio-dev libavc1394-dev libcups2-dev libcupsys2-dev libdts-dev libdvb-dev libdvdnav-dev libdvdread-dev libexpat1-dev libfaac-dev libfaad-dev libfftw3-dev libfontconfig1-dev libfreetype6-dev libgcrypt11-dev libgif-dev libgl1-mesa-dev libglib2.0-dev libglu1-mesa-dev libgnutls-dev libgpg-error-dev libice-dev libiec61883-dev libimlib2-dev libjack-dev libjack0.100.0-dev libjpeg62-dev libkadm55 libkrb5-dev liblcms1-dev liblircclient-dev libltdl7-dev libmng-dev libmysqlclient15-dev libogg-dev libpng12-dev libpthread-stubs0 libpthread-stubs0-dev libqt3-compat-headers libqt3-headers libqt3-mt-dev libraw1394-dev libsm-dev libtasn1-3-dev libtiff4-dev libtiffxx0c2 libtool libungif4-dev libvorbis-dev libx11-dev libx264-dev libxau-dev libxcb-xlib0-dev libxcb1-dev libxcursor-dev libxdmcp-dev libxext-dev libxfixes-dev libxft-dev libxi-dev libxinerama-dev libxmu-dev libxmu-headers libxrandr-dev libxrender-dev libxt-dev libxv-dev libxvidcore4-dev libxvmc-dev libxxf86vm-dev mesa-common-dev pkg-config qt3-dev-tools texi2html x11proto-core-dev x11proto-fixes-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-video-dev x11proto-xext-dev x11proto-xf86vidmode-dev x11proto-xinerama-dev xtrans-dev libmp3lame-dev



Download the current Emunation from the general DVB files section


Code:
Code:
http://www.fta-newbies.com/forums/forumdisplay.php?f=1204

Open and extract the file. In there you will find a folder called Nagra.
Open, then copy the entire contents of Nagra (the .bin files) and the softcam.key fileto your /home/<your user name here>

Now to install sasc-ng.
Just to warn you, the dr_dred5 method is a little different from other installs. Mine is quite a bit simpler, especially if you are migrating from Windows.

Ubuntu 8.10 uses a newer version of G++ and sasc-ng wont compile with it. To get around this we need to install the older version.

sudo apt-get install g++-4.2

Now let's get the latest build of open-sasc-ng and set up our directories.


Code:
cd /usr/src/
sudo svn co opensascng - Revision 68: /open-sasc-ng
cd open-sasc-ng/
sudo mkdir -p sc_files/nagra sc/PLUGINS/lib
sudo touch sc_files/ecm.cachet


this point, I am going to stray from the terminal and get us into Nautilus.

TIP: If you already have another working installation of sasc-ng on another partition, copy it over to the new installation.

This saves you waiting for your keys to populate.


Code:
sudo nautilusIn the window that pops up, navigate to /usr/src/open-sasc-ng/sc_files


Copy and paste the softcam.key into sc_files
Make sure softcam.key is renamed to SoftCam.Key (case sensitive)
Copy your .bin files to the nagra folder.

Navigate back to /usr/src and grant read/write privalages.

Right click on the open-sasc-ng folder.
Click Properties.
Click the permissions tab.
In the dropdown menus, change the file access to Read and Write for each category.
Click Apply Permissions to Enclosed files and Folders.

Check the status of sasc-ng
Back to the terminal.

Make sure you are still in /usr/src/open-sasc-ng/

For SVN


Code:
sudo./configure --cxx=/usr/bin/g++-4.2For Binary

Code:
sudo ./configure --cxx=/usr/bin/g++-4.2 --sharedThen

Code:
sudo make
sudo make moduleIf a binary fix is required, continue. If SVN is up, skip the next secion


Code:
sudo cp ~/libsc-nagra-20.so.1.5.5 sc/PLUGINS/lib/
sudo cp sc/PLUGINS/lib/* /usr/lib/
sudo ldconfigSVN and binary continues here.

Code:
sudo insmod dvbloopback.ko #(if you already have this module loaded then do sudo rmmod dvbloopback first)
At this point we need to make sure our softcam.key is up to date.

Edit it with,

Code:
sudo gedit /usr/src/open-sasc-ng/sc_files/SoftCam.KeyMake sure all the keys are correct.

Save and exit.


Code:
sudo ./sasc-ng -j 0:1 &This will start sasc-ng. You need this to be running for the remainder of the setup.
Open a new terminal.

Quote:
Code:
dr_dred5@dr_dred5-desktop:~$ sudo ls -al /dev/dvb

If you look at the output, you will notice that there should now be two DVB cards listed. Adapter1 is a virtual card that does the decrypting!


Now to start installing Myth. For this we are going to be building Myth from source. We do this so that we can patch, or alter the program to do things that the original version can't do.

A lot of the following has been copied from older howtos done by Slashdork and Minotaur I have updated them for the newer OS and added some of my own dr_dred5 shortcuts to simplify things a bit.

OK. First we need to set up a place to work with the source code.


Quote:

cd /usr/src
mkdir mythbuild
cd mythbuild

Install build dependancies for mythtv


Quote:
apt-get build-dep mythtv -y

You will get a warning about a package that isn't available. You can safely ignore this.

Download the mythbuntu mythtv source


Quote:
apt-get source mythtv -y
Create a directory for the patches you with to install


Quote:
mkdir patches
cd patches
Grab the patches we need


I am including all the ones that I use, but you can add more if they apply to your setup.


Code:
Code:
wget http://www.hoochvdr.info/files/mythbe_1_mysqlconnfix_r17758-fixes.diff 
wget wget http://www.hoochvdr.info/files/mythbe_2_eitcachefix_r17758-fixes.diff 
wget http://www.hoochvdr.info/files/mythbe_3_dbconnfix_r17758-fixes.diff  
wget http://www.hoochvdr.info/files/mythbe_4_slavefix_r17758-fixes.diff 
wget http://www.hoochvdr.info/files/mythbe_5_sdt_r17758-fixes.diff  
wget http://www.hoochvdr.info/files/mythbe_6_siscan_r17758-fixes.diff  
wget http://www.hoochvdr.info/files/mythbe_7_pesfix_r17758-fixes.diff  
wget http://www.hoochvdr.info/files/mythbe_8_scanfix_r17758-fixes.diff  
wget http://www.hoochvdr.info/files/mythbe_9_eit-bev-dn3_r17758-fixes.diff  
wget http://www.hoochvdr.info/files/mythbe_11_casc_diseqc_sw_r17758-fixes.diff  
wget http://www.hoochvdr.info/files/mythbe_12_dbs-fssfix_r17758-fixes.diff
Change directories to MythTV source



Quote:
cd ..
cd mythtv-0.21.0+fixes16838/


Patch the source


Quote:
Code:
patch -p1 < ../patches/mythbe_1_mysqlconnfix_r17758-fixes.diff
patch -p1 < ../patches/mythbe_2_eitcachefix_r17758-fixes.diff
patch -p1 < ../patches/mythbe_3_dbconnfix_r17758-fixes.diff 
patch -p1 < ../patches/mythbe_4_slavefix_r17758-fixes.diff 
patch -p1 < ../patches/mythbe_5_sdt_r17758-fixes.diff 
patch -p1 < ../patches/mythbe_6_siscan_r17758-fixes.diff 
patch -p1 < ../patches/mythbe_7_pesfix_r17758-fixes.diff 
patch -p1 < ../patches/mythbe_8_scanfix_r17758-fixes.diff 
patch -p1 < ../patches/mythbe_9_eit-bev-dn3_r17758-fixes.diff 
patch -p1 < ../patches/mythbe_11_casc_diseqc_sw_r17758-fixes.diff 
patch -p1 < ../patches/mythbe_12_dbs-fssfix_r17758-fixes.diff


Edit debian/changelog to prevent updates from breaking your stuff


Quote:
nano ./debian/changelog

Use the arrow keys to navigate and change the first line from ...

Code:
mythtv (0.21.0+fixes16838-0ubuntuX)
to
mythtv (0.21.0+fixes16838-0ubuntu4)

Build your .deb packages


Quote:
debuild -us -uc
Go grab a beer, or better yet go out for a beer this will take a while...

When it finishes.


Quote:
Code:
apt-get install -f
dpkg -i *.deb
Answer any questions during the update.

Configure MythTV Backend.



* Choose your language

* In "General" section - check the box for "Cross Source EIT"
This gives us 9-day guide data on birds other than 119

* Go to "Capture Cards" > "New Capture Card"

Set card type to DVB DTV card, and set device number to 1

If you have a DisEqc or Tone switch, set it up in 'DisEqc' section. I run a 4x1 DisEqc switch,
so I set it to "Switch", Repeat Count "1", type "DisEqc", number of Ports "4"

Then I name each port underneath the switch, in order of the ports on the switch... my DisEqc ports are
as below, and this is the order I put them in to MythTV. So each of the unconnected entries get set to "LNB"
and named by bird they are hitting. My 121 is Universal LNB, 110 & 119 are Circular NA

1 - 119W
2 - 110W
3 - 82W
4 - 91W

** Ensure you set description to something that makes sense for the port, such as "119W" **

After that is set up, go back to screen with "Recording Options" and set max recordings to "1" if you only have 1 tuner in the card

I leave everything else as default.

41. Set up Video Sources

Create a Video Source for each of the sattellites you tune. I create 4, as indicated above, named the same as the LNB's (121W, 119W, 110W, 91W)
and set the listings source to "Transmitted Guide Only" on all 4

42. Set up Input Connections

We'll set up 119 first, since it is the primary bird for DN, and contains the 9-day guide.

Create "New Input"
Source set to the one with 119W
I use a Display Name of "Echo 119"
Set Video Source to 119W
Un-check "Use Unencrypted Channels Only"
Check "Use DishNet Long Term EIT Data" (this is only done on 119)
Choose "Scan for Channels"
Scan Type "Full Scan (Tuned)"

Frequency 12472000
Polarity "Left Circular"
Symbol Rate "20000000"

You should get a lock, and it should find a bunch of channels with names. This is also the transponder that sends the 9 day guide data.

Exit and allow mythfilldatabase to run.

Start the backend.

sudo mythbackend

Start the frontend (Applications>Sound and Video>Mythtv Frontend) and try to watch TV. The screen should initially be black for up to a few minutes, possibly even 20 while keys roll. I have found that by changing channels every 15 seconds speeds this up.

Hopefully you get video. If not, maybe your sasc-ng is outdated or improperly configured. Look at the output in the sasc-ng terminal. It should provide a clue.

If you have get video, move forward.

Get all the channels.


you can use Myth's built in scanner.

Return to MythTV Backend Setup.
Sudo mythtv-setup

and go to "Channel Editor", then to "Channel Scanner"
Perform a "Full Scan of Existing Transports" Note 119 and 110 are very slow.

Save and exit, let mythfilldatabase run.

Almost there!

Now we need to set up the database for extended guide data. Basically, we are telling the database to only collect data from one transport.
[sudo mythconverg
and it will spit out.

Quote:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 393
Server version: 5.0.51a-3ubuntu5 (Ubuntu)

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql>

Enter the following.

Code:
use mythconverg;
ALTER TABLE diseqc_tree ADD COLUMN address TINYINT(3) UNSIGNED NOT NULL default 0 AFTER description;
DELETE from program where chanid not in (select distinct chanid from channel);
DELETE from eit_cache;
insert into dtv_privatetypes (sitype,networkid,private_type,private_value) VALUES ('dvb',4100,'force_guide_present','yes');
insert into dtv_privatetypes (sitype,networkid,private_type,private_value) VALUES ('dvb',4100, 'extended_guide_tid',18);
insert into dtv_privatetypes (sitype,networkid,private_type,private_value) VALUES ('dvb',4100, 'guide_on_single_tid','yes');
exitNow restart mysql with.



Code:
sudo /etc/init.d/mysql restartIt will take several hours to get all the guide data.


And I think that's it.

If you want to, you can now use Mythbuntu Control Center to install plugins. Also you can disable Mythtv auto start, add themes, set up a diskless server etc.
__________________
P4 2.4ghz
512 mb ram
Twinhan VP 1020a/Digiwave 103g
ATI All in Wonder 128mb
SB Live 5.1
Stock B3V dish and LNB No switch
Ubuntu 8.04 Hardy W/Mythtv front/backend.
3 remote frontends including 1 diskless and 1 Linux based Xbox
 
Status
Not open for further replies.
Top