March madness HDTV is my desktop background in Ubuntu Gusty. What's yours? March 16th, 2008
The purpose of this post is for me to contribute all the useful information I've gathered on HDTV recording and playback over the last year on NVIDIA+Ubuntu platform.
First off, I'd like to say that not enough linux tutorials are specific enough about hardware branding. If you have hardware that works well out of the box, be loud about it! Plenty of people are out there looking for good linux compatible hardware and even a random blog post can help someone make the right hardware decision.
Hardware:
To playback/record HDTV in Linux, you gotta have the right hardware. You need an NVIDIA graphics card for great compiz-fusion compatibility and a chance at XvMC (that's short for X-Video Motion Compensation). You also need a pcHDTV 5500 tuner card from these guys. Now, it's important to note, I'm talking about broadcast HDTV here (not cable, because I don't have it).Software:
- Pre-requirements
sudo apt-get install subversion cvs build-essential xserver-xorg-dev dvb-utils
sudo apt-get install mplayer
Alternatively you can download and compile it yourself from www.mplayerhq.hu.$ cat /etc/X11/XvMCConfig
libXvMCNVIDIA.so.1
$ ls -l /usr/lib/libXvMC*
lrwxrwxrwx 1 root root 25 2007-11-23 22:46 /usr/lib/libXvMCNVIDIA.so.1 -> libXvMCNVIDIA.so.1.0.9639
...
cvs -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/xapps co xwinwrap
cd xwinwrap
make
svn co http://svn.rubyonlinux.org/mplayerctl
Using the tools for recording HDTV:
- You can skip to the playback section if you are only interested in HDTV playback
- First off, you need to configure the TV channels using dvb-utils scan.
mkdir ~/.azap
scan -a /dev/dvb/adapter0 > ~/.azap/channels.conf
Using the tools for playback of HDTV
- mplayer-drb-server.rb does not require anything except for ruby + mplayer + linux to run
- I've coded in some defaults for mplayer options that use xwinwrap -or- xvmc (don't try to use both at once). The default is to let mplayer choose automatically
- Here's examples of how to use it To have HDTV as your desktop background:
mplayer-drb-server.rb -f livetv.ts -x /home/user/xwinwrap/xwinwrap
To use XvMC and foreground playback:
mplayer-drb-server.rb -f livetv.ts -n
pause.rb -> pauses
seek.rb +30 -> seeks 30 seconds forward
Hope you enjoy!
Thanks for checking this out. It's a work in progress but could be very useful to someone who's a linux video geek like myself. Leave a comment!Using DRb and ruby to control mplayer and record/playback HDTV. March 14th, 2007
I wanted HDTV broadcast in Ubuntu, so I bought a PC-HDTV 5500 tuner. It needs a 2.6.18 or higher kernel to work.
I’ve been working on some scripts to control my TV. So far I have a rudimentary server and client along with a HDTV record script that uses a direct copy from the device using the linux tool ‘cat’. My system @kernel 2.6.19 had a bug which causes cat to overflow.. So there is error detection and resume recording after a crash.
I’ll be using linux CRON to schedule recordings.
It is a work in progress.
Here is the SVN repository:
http://svn.rubyonlinux.org/mplayerctl/
I used Kazuki Takemura’s code to control mplayer, and extended it to use DRb connections.
Go ahead and comment if you are interested in helping with the project. I want it to become a simpler MythTV style thing eventually.. SIMPLER is better.
New commits, March 2008. Rudimentary recording and scheduling via cron are now possible. Need to improve the actual mplayer part now but it’s working so that’s great.