XV on PVR-350

From MythTV Official Wiki
Jump to: navigation, search

Time.png Outdated: The information on this page may no longer be relevant to the current release of MythTV, 34.0. Please consider helping to update it. This page was last modified on 2014-12-16.

Important.png Note: PVR-350 Tv-out support has been dropped from MythTV 0.23 since it was unmaintainable and little used.

This How-To outlines how to get the X Driver (with xv extensions) working on the TV-Out of the Hauppauge PVR-350 in various distributions of Linux.

Configuring X (xorg.conf) (all distributions)

This section describes the changes you will need to make to your XF86Config / xorg.conf file in order to enable the X driver.

  • Edit your xorg.conf (or XF86Config) file to contain the following. Replace with your own fbdev and BusID as appropriate (see below):
Section "Device"
        Identifier "Hauppauge PVR 350 iTVC15 Framebuffer"
        Driver "ivtvdev"
        Option  "ivtv" "/dev/fb2"
        Option "VideoOverlay" "on"
        Option "XVideo" "1"
        BusID  "PCI:0:10:0"
        Screen 0
EndSection

Key points of this section:

  • Driver "ivtvdev" - This is the X driver you downloaded or compiled, I used the downloaded version compiled for XFree86 on my X.org dist:
  • Option "ivtv" "/dev/fb2" - Use ivtv and NOT fbdev. The fbdev is a built in module that is not compatible with ivtv 4.x, and generates all sorts of errors.
    • At least for current SVN snapshots of ivtv xdriver together with an up-to-date X.org (>=7.1), this seems to be wrong - you actually need Option "fbdev" "/dev/fb..." instead. --Gernot 08:59, 11 March 2007 (UTC)
  • Screen 0 - Each graphics device has a list of available screens for example an gforce fx5200 has screen 0 and screen 1:
  • Get your appropriate BusID (for your PVR-350, not your video card) by executing the following command:

X -scanpci (look for the line with iTVC15 MPEG-2 Encoder, and you may need to kill X first)

  • Get the appropriate fb device from /proc/fb:

cat /proc/fb

  • VideoOverlay and XVideo are for enabling XVideo extensions - the driver should work without them.
  • You will probably also want to add the Screen and Monitor sections:

NTSC

Section "Screen"
        Identifier "TV"
        Device "Hauppauge PVR 350 iTVC15 Framebuffer"
        Monitor "NTSC Monitor"
        DefaultDepth 24
        DefaultFbbpp 32
        Subsection "Display"
                Depth 24
                FbBpp 32
                Modes "720x480"
        EndSubsection
EndSection


Section "Monitor"
	Identifier "NTSC Monitor"
	HorizSync 30-68
	VertRefresh 50-120
	DisplaySize 183 122
	Mode "720x480"
		# D: 34.563 MHz, H: 37.244 kHz, V: 73.897 Hz
		DotClock 34.564
		HTimings 720 752 840 928
		VTimings 480 484 488 504
		Flags	"-HSync" "-VSync"
	EndMode
EndSection

PAL

Section "Monitor"
  Identifier "PAL Monitor"
  HorizSync 30-68
  VertRefresh 50-120
  Mode "720x576"
    DotClock 42.6
    HTimings 720 760 832 944
    VTimings 576 577 580 602
    Flags "-HSync" "-VSync"
  EndMode
EndSection

Section "Screen"
  Identifier "TV"
  Device "Hauppauge PVR350"
  Monitor "PAL Monitor"
  DefaultDepth 24
  DefaultFbbpp 32
  Subsection "Display"
    Depth 24
    FbBpp 32
  EndSubsection
EndSection

  • You can now start X by typing X -screen TV

Compiling the X driver on a RedHat Compatible System

I also needed the x driver to get Xine to play nice with the PVR-350. These steps worked to compile it on a CentOS 4.2 (RedHat Enterprise) x86_64 System:

  • Download and extract xdriver source. Here I'll use the home directory (~).
  • Install xorg-x11 source RPM, for me xorg-x11-6.8.2-1.EL.13.20.src.rpm
  • cd /usr/src/redhat/SPECS/
  • rpmbuild -bc xorg-x11.spec -- This took a good half hour on my 2.8Ghz P4-521. This patches and compiles but does not install the source. I wonder if 'rpmbuild -bp' would be enough for this to work?
  • cd ~/ivtv_xdriver_0.10.6/xc/programs/Xserver/hw/xfree86/drivers/ivtv
  • xmkmf /usr/src/redhat/BUILD/xorg-x11-6.8.2/xc
  • make
  • cp ivtvdev_drv.o /usr/X11R6/lib64/modules/drivers. On an i386 system the destination for the copy should be /usr/X11R6/lib/modules/drivers.
  • Edit /etc/X11/xorg.conf (see above edits to XF86Config).
  • Restart X

The xdriver source compiled without any patches or fixes. Check /var/log/Xorg.0.log after restarting X to see that the driver is loading. My log file stated that the driver is compiled for 4.3.99.902 while I clearly have 6.8.2 installed. Odd, but it still works.

--Kbocek 21:51, 27 March 2006 (UTC)

Compiling the X driver on Gentoo with Modular X.org (7.0-r1)

  • xf86-video-ivtvdev is now in portage!
  1. Add the following to /etc/portage/package.keywords:
    echo "x11-drivers/xf86-video-ivtvdev ~* *" >> /etc/portage/package.keywords
  2. Add the fbcon use flag to /etc/portage/package.use:
    echo "media-tv/ivtv fbcon" >> /etc/portage/package.use
  3. Add the following lines to /etc/portage/package.mask to prevent x.org from updating:
    >=x11-base/xorg-server-1.0.99
    >=x11-base/xorg-x11-7.1
    >=x11-base/xorg-server-1.1.0
    >=x11-drivers/xf86-input-evdev-1.1.2-r1
    >=x11-drivers/xf86-video-vesa-1.2.0
    >=x11-drivers/xf86-input-mouse-1.1.1
    >=x11-drivers/xf86-input-keyboard-1.1.0
    >=x11-drivers/xf86-video-nv-1.1.2
    >=x11-drivers/xf86-video-fbdev-0.3.0
    >=x11-drivers/xf86-video-v4l-0.1.1
    >=x11-drivers/xf86-video-vga-4.1.0
  4. Edit the following line in /etc/make.conf to contain ivtvdev. An example line:
    VIDEO_CARDS="nv nvidia vga vesa fbdev ivtvdev none"
  5. emerge ivtv
  6. If you don't already have xorg 7.0-r1:
    emerge xorg-x11
  7. xf86-video-ivtvdev should install itself, but if it doesn't:
    emerge xf86-video-ivtvdev
  8. Edit your xorg.conf file as shown in the previous section.


Important.png Note: Depending on the kernel version you have installed, a patched version of xf86-video-ivtvdev may be needed. This should really be kernel-independent, but it's not, so we make it work. If you have a problem getting xf86-video-ivtvdev to compile, try the patches on bugs.gentoo.org or post your compile errors to the IVTV or myth mailinglist.

JeffSimpson 15:04, 4 December 2006 (UTC)

Compiling the X driver on Gentoo with Modular X.Org (6.9/7.0)

Since Modular Xorg has drivers in separate packages, porting the xdriver to one of these packages was just a matter of hijacking the fbdev package and changing which files it compiled.

  1. Put the tar.bz2 file in /usr/portage/distfiles
    cp xf86-video-ivtvdev-0.10.6.tar.bz2 /usr/portage/distfiles
  2. Put the .ebuild in your portage overlay under x11-drivers/xf86-video-ivtv
    mkdir -p /usr/local/portage/x11-drivers/xf86-video-ivtvdev/
    cp xf86-video-ivtvdev-0.10.6.ebuild /usr/local/portage/x11-drivers/xf86-video-ivtvdev/
  3. Build the digest for the ebuild
    ebuild xf86-video-ivtvdev-0.10.6.ebuild digest
  4. Add the package to package.keywords
    echo "x11-drivers/xf86-video-ivtvdev ~x86" >> /etc/portage/package.keywords
  5. Add "ivtvdev" to VIDEO_CARDS in make.conf
  6. Add video_cards_ivtvdev to USE in make.conf
  7. Emerge the package
    emerge xf86-video-ivtvdev
  8. Edit xorg.conf (see configuration instructions above)
  9. Start X!


Important.png Note: These are copies of the source code obtained from ivtvdriver.org, modified for the package structure of modular xorg.

  • ivtvdev_drv.so Binary Driver (no guarantees on if this will work with your specific distribution, you're better off compiling)

--JeffSimpson 20:41, 29 March 2006 (UTC)

Compiling the X driver on Gentoo with X.Org 6.8.X

Important.png Note: These instructions are outdated and may no longer work.

This section focuses on installing the X Driver (with XVideo extensions) in Gentoo under x.org 6.8.X. This assumes that you have tvout working on the PVR-350, or at least some parts of MythTV already working.

  • Upgrade to the newest release of Ivtv, at this time, ivtv-0.3.8.
ACCEPT_KEYWORDS=~x86 emerge ivtv
  • Upgrade/Install x.org. I used version 6.8.2-r5, but any new-ish release should be ok
  • Download the XDriver from here: http://dl.ivtvdriver.org/xdriver/
  • Unzip the archive into the source directory for X, in the

xc/programs/Xserver/hw/xfree86/drivers/ivtv directory

  • Edit xc/config/cf/xorg.cf and look for #define XF86CardDrivers. Add "ivtv" somewhere in that list.
  • Run a make clean and make install in that directory to install the ivtv driver.
  • Edit your XF86Config or xorg.conf file as shown above
  • Start X!

In order to facilitate, I created a patch and custom ebuild to download/install xdriver and patch the xorg.cf file.

  • attachment:ivtv.xorg.cf.patch (now missing)
  • attachment:xorg-x11-6.8.2-r5.ebuild (now missing)

--JeffSimpson 20:52, 29 March 2006 (UTC)

Installing on Debian with Xorg 7.0

References