Arkiv för kategori HTPC

Härligt, Tre Kronor (Sverige-Ryssland 3-2)

Så har det gått en dag till med match, den här gången Sverige-Ryssland. Och även idag vann man, precis som mot tjeckerna. Roligt! Tyvärr hade jag programmerat videon fel, så jag lyckades spela in från TV2 istället för från TV1. Skickligt, PG… Nåväl, man får väl se det som att jag hinner göra lite andra roliga grejer ikväll istället. :-)

(Man kan ju också se det som att HTPCn jag bygger, med en fungerande EPG och inspelningsfunktion – vår nuvarande funkar inte helt optimalt – är välbehövd.)

Gillar också Mårds inställning som nämns i länken som jag skrev i början av inlägget: ”Jag är nöjd med det jag ser men jag ag tycker att det är för många blindpassningar. Nu ska vi gå för det fjärde målet och ingenting annat, säger förbundskaptenen Pär Mårts.” Exakt så där vill jag att en svensk förbundskapten ska tänka! Jag är så glad att vi fått in Per Mårds nu, det ska bli mycket intressant att se hur det går. Matchen imorgon, jo, men framförallt i förlängningen. VM 2011, och på lite längre sikt, OS 2014. OS 2010 var ju en stor flopp ur svenskt perspektiv, så jag tycker målsättningen i OS2014 ska vara att göra en ”Turin”, en ”Lillehammer” – att vinna OS-guld helt enkelt. Vi har kapaciteten, framförallt när vi får räkna in våra NHL-stjärnor som Lidas (även om han nog har slutat vid det laget :-) , Alfie (Daniel Alfredsson), Sedinarna, Kronwall, Dougie Murray et cetera. Men det känns tyvärr inte som att vi alls lyckades maximera lagets totala förmåga i Vancouver 2010. Så, mina förhoppningar på Sochi 2014 är stora. Absolut minimum är att det ska gå bättre än förra gången, då vi åkte ut i kvarten. En rimlig förväntan är snarare att Tre Kronor ska spela final – och vinner man, så har man verkligen lyckats riktigt bra (särskilt om det är typ Canada som motståndare).

Inga kommentarer

HTPC project, part 5

Just a quickie this time. Of course, I couldn’t keep my promise of waiting with this until we move into the house. :-) I looked into it again, and this time, I actually got it working! It seemed to work pretty well now, and MythTV surely makes these IPTV streams more useful.

I’ve set up an m3u file for myself, you can get it at this URL. (Please, download it and keep a copy at your own server; don’t point your MythTV installation to my URL.) Using these settings, I can get all channels except for channel 8 working. (I’m unsure what that channel is; it doesn’t work in VLC either.)

So… there are a few channels missing that could be added, but I don’t think I’ll care about them now. (I could get their IP addresses using the VLC Mozilla plugin + tcpdump, but… some other day.)

MythTV definitely seems like a promising program, that’s for sure. Of course, it might be a bit ”too technical” in some senses, and the subtitles did seem to work a bit weird (it was configured to Swedish, but it still didn’t put on Swedish subtitles on FST5 automatically?? Anyway, pressing M and chosing Swedish subtitles worked, so that’s good), but still… the EPG seems great, and its recording availabilities are awesome. You just select a title you want to record, and you can make the program record that title every time it’s being broadcast, on any channel… for example. Just one word: awesome!

Now, all that bugs me is that I want the XMLTV listings in Swedish rather than Finnish… (they are available in Swedish, since www.tv.nu publishes them like that… highly annoying! Maybe I’ll have to make myself an XMLTV grabber for the Finnish channels in Swedish, seems like some Christmas holiday project… :) )

Inga kommentarer

HTPC Project, part 4

I found a quite interesting page here about IPTV and MythTV.

This document describes all the steps you need to take to get an IPTV-based provider added to MythTV. There are quite a few steps involved actually, more than what you might think.

At first, I tried hosting the m3u in a local folder. This did not work. But: the good part is that I have an Apache server set up (on a Windows machine, actually) where I could place the file. By putting it there, it worked better: it complained about how the m3u looked. I compared it to the file provided by avenard.com, and found an error. The error was corrected, but it still didn’t work; mythtv-setup just crashed in the face of me.

What I did then was adding -v 10 and then -v 100 to mythtv-setup. With the last setting, it actually started working (!). Very weird. The channel list was fetched, and the channels was added to MythTV.

The problem now is that when I try to watch TV, it doesn’t get any contact with these rtp streams. I don’t know if the syntax in the m3u file is correct (I’ve tried ”rtp://233.60.167.1:1111″ and this doesn’t seem to work too well). I’ll ned to RTFM, I think…

It might be that you should specify it like udp://233.60.167.1:1111?multicast instead, according to this link. Right now though, I can’t even play the channel in VLC which means that the preconditions are not optimal. :-)

I think I’ll just stall the project for some time now, until we’ve moved in to our new house and I have a real ethernet connection into my computer. I’m on WLAN now and it might not be optimal for these kind of elaborations.

Inga kommentarer

HTPC Project, Part 3

I found an interesting ”HOWTO”-like document here: Installing MythTV on Debian Etch. I can recommend this HOWTO to anyone else interested in getting MythTV set up.

I started off installing mysql-server, as requested. As we all know, this is very convenient and nice with Debian (and its derivatives); you just apt-get install it and get a working configuration set up for you, just like that. In the installation, I was asked which MySQL root password I wanted to use. I chose a good password I use somewhere else (like we all tend to do…).

I installed ALSA, the way I was instructed to. I set the volume, using the alsamixer tool (the old ”aumix” tool I’ve used previously doesn’t seem to work too well with ALSA). Now, how do you test the sound card in text mode? Well, I installed bplay first, but it also seemed to rely on OSS, so I used mpg123 and downloaded an mp3 file from a Windows machine in our network, and tried playing it. At first it wasn’t hearable, but it was just the volume that was too low. :-)

OK, now I’m ready to install X.Org. This is interesting: I already spent some time getting the intelfb driver to work (which it didn’t), so if MythTV uses X11 (rather than directfb), this is probably a positive thing from my perspective.

When installing X11, you have to choose which kind of environment you want to use. The HOWTO recommended Fluxbox; I was considering GNOME. But, interesting enough, the Debian gnome package is HUGE; it will use
1,6 gigs (!) of disk space. This is because we’re talking about a full GNOME environment here, including lots of stuff that will be completely irrelevant on my HTPC. Fluxbox OTOH will only consume a little more than
100 megs of disk space. The choice is easy: we try with the Fluxbox route.

It was a similar thing when installing a terminal emulator. I’m used to gnome-terminal, but because I didn’t have very many other GNOME-related things, it would be above 150 megs to install it. I chose a smaller program called ”mrxvt” instead, which seems to work fairly OK so far. (It looks ugly, but at least the keyboard shortcuts seem to be intuitive. :-) )

What about Firefox? Well… not strictly needed but it will let me read the rest of the HOWTO in a graphical web browser rather than Lynx. :-) Besides, you might want to have a real web browser on an HTPC anyway, to be able to stream flash-based web-TV (SVT Play). So, installing it can be said to be reasonable.

Argh! I just found out (after starting Firefox and playing around) that ”tap-to-click” is enabled in X.Org. Annoying, let’s get rid of it ASAP. (Remember, this is a laptop I’m playing around with so far.)

Let’s hope ”Option ”MaxTapTime” ”0″” does the trick.

Actually, it didn’t. This problem seemed to be much harder to fix than it ought to be. Anyway, what I did was connect a ”real” mouse instead which works better… ;-)

One initial impression is that this Debian installation is very fast and responsive, so far. My other Debian install was also fast, even though I had a full GNOME setup in that one.

I went on to add the Debian-Multimedia repositories to my /etc/apt/sources.list and installed mythtv, along with all the packages listed as ”recommended” by the mythtv package. This took a few minutes, of which some was the download time. (I have an 8 Mbit/s ADSL connection.)

Alright, time to start the mythtv-setup program! Exciting, I wonder if I’ll get this working this evening or some other evening? (I changed the password of the mythtv user before doing this; the mythtv-setup has to be run as the mythtv user.)

The setup program is a pretty nice-looking, graphical program. Its startup screen looks like this:

mythtv_setup

(The language I’ve chosen is Swedish, if someone wonders.)

After fiddling with it for a while, I managed to get the mythfilldatabase to fill the EPG database with data from an XMLTV source we have here in Finland. But… when trying to watch some TV with the mythfrontend application, absolutely nothing. Whenever I choose the ”Watch TV” option, the screen blanks and I get back to the start menu. No error message, no nothing. I’ll have to look into this some other day to see what it can be that prevents it from working correctly…

Inga kommentarer

HTPC Project, Part 2

(Warning: this posting doesn’t really talk very much about the HTPC project per se; it is more of a general posting regarding the Linux installation and my specific situation with previous partitions causing some issues. If you’re only interested about the HTPC project, skip this posting and go straight to part 3 where I’ll start installing MythTV.)

So, after installation, this beautiful ”Debian GNU/Linux 5.0 nx7400 tty1″ prompt approached me. The installation was smooth; I downloaded the CD1 ISO for Debian 5.0.2 (Lenny), burned it using Imgburn (a free Windows application for burning ISO images to CD/DVD) and started the Windows-based (!) installation program. The installation then proceeded in the Linux-based environment after a few initial questions.

Something really convenient these days is that the Debian installer includes a nice program called ntfsresize, which lets you resize an NTFS partition very easily. You basically just tell it how big you want the remaining NTFS partition to be, and it starts working on the resize. In my experience (two times on this same machine), it works really well.

The NTFS resize was actually my main reason for doing the install in the first place. You see, I already had a working Debian installation on the machine, but its partition was becoming too small, so I had to downsize my Windows partition to get some more space for my Linux stuff. So, actually, I wouldn’t have to install a fresh install (I could have aborted it after the NTFS resizing), but nevertheless I did.

The installation went just fine. One advantage of the ISO-based install is that is it doesn’t (unlike the netinst) require you to have network connectivity in the actual installer. I am on an 802.11bg-based WLAN now, using WPA2, so it is a bit tricky to get it working with the installer (if it works at all). By using the ISO, I worked around this difficulty and will solve it now when the system is actually installed instead (by copying over the config from my previous installation).

I chose to install Debian GNU/Linux on an XFS partition this time, just like the last time. After some more consideration though, I think I’ll install it on a regular ext3 partition on the ”real” HTPC machine. XFS, just like other special ways of handling file systems (LVM) do have their advantage, I guess, but… they also have their disadvantages. For example, consider LVM. It might be nice when it works, but what about when it don’t work (for example when the hard drive fails…)? It’s much harder (or, I’d say, impossible) to try and mount an LVM ext3 volume on a Windows XP machine. Yes, there is an ext2 IFS (that should handle ext3 as well), but I doubt that it would work with an LVM volume.

So, I think I’ll go with a plain ”vanilla” ext3 volume on the ”production” machine. Or actually two volumes: one for the system + applications, and one for the storage (keeping all recorded TV programs).

Now, I have done some minor tweaking to the setup: added a non-privileged user account, installed sudo, set this user up as a sudoer. I was just about to try to mount the Linux partition to try to copy the WLAN config over (to get network connectivity), but when I started cfdisk to look the partition name up, it gave me an evil error message like this:

FATAL ERROR: Bad logical partition 7: enlarged logical partitions overlap
Press any key to exit cfdisk

This doesn’t sound so good. One problem I know of is that the partitions doesn’t come in the proper order: when I resized the NTFS partition, there was a ”free hole” before partition 5 and 6, but when I created a logical partition there, it become partition number 7. The problem might be related to this, but… the error message from cfdisk doesn’t really say that this is /exactly/ the problem.

Maybe it would be easiest to just get the data out that I want to keep from partitions 5-7 and then recreate them from scratch, in the proper order… I wonder if there’s a different way to solve this?

Another problem is that I’m missing some packages: firmware-ipw3945, ipw3945-modules-2.6.18-6-amd64 (I guess I’d need a 2.6.26 version instead) and ipw3945d. These packages control the Intel Pro Wireless
3945 chip in the machine, and without them it is hard to get the wireless LAN to work.

Maybe I’ll just reboot into my Windows partition and download these files there…

[After fixing it]

It turned out the only package needed nowadays to get this going was the firmware-iwlwifi package. I downloaded this package on Windows, but still couldn’t get it going (even after copying the identical
configuration I had on my other Linux partition). But… it started working when I used tasksel and chose to install the ”Laptop” software. This software included the wpasupplicant package, which seemed to be the missing link to get this going. (It seems like wpasupplicant installs certain ”hooks” into the system that gets run when certain keywords are being configured in /etc/network/interfaces.)

So… here I am now, with a working ”minimal” system and working networking. I don’t have any GNOME installed; maybe I should get that set up to more easily access this blog and so forth (or, even better, see if there is a Firefox for framebuffer package available somewhere…).

Time to get started with the MythTV setup and all of that! This will be covered in the next blog posting.

Inga kommentarer

HTPC Project, Part 1

Hi,

This is my first posting in a series about my new HTPC, which I aim to construct and use for my family’s home entertainment needs. Currently, I’m downloading the ISO of Debian 5.0.3, which means I can take some time to elaborate on the ”hows, whys and whats” of this project.

We start with the ”whys”. Why build an HTPC, hasn’t everyone done this already?

Well, I haven’t, so why not? We all need some interesting & fun sparetime project to work on, don’t we? Besides, we have some clear needs (I’m tempted to call them ”business needs”, but hey – this is a private project, not a work thing after all…).

We currently have a setup that looks like this:

  • A CRT TV (28″, 4:3) with analogue TV receiver.
  • An STB (Set-Top Box) for DVB-C (digital cable TV used here in Finland and all of the rest of Europe).
  • An STB for DVB-S (digital satellite broadcasts), and a satellite dish with 2 LNBs directed to Sirius 4.8°E and Thor 0.8°W.
  • A recordable DVD player with a 160 GiB HDD (with analogue TV receiver).

Through the outlet in the wall, we receive a quite good mix of Swedish and Finnish TV channels (we definitely watch the Swedish channels much more than the Finnish, since neither one of us understands Finnish well enough to watch Finnish programs), both in analogue form and digital. Through the satellite dish, we receive the Swedish channels once again (so we have an ”overlap” reception of some of the channels), as well as some very good FTA Christian channels.

(These FTA Christian channels are a must when we plan the future of our home entertainment, which you will notice further down in this text.)

This leads us to a living room with 1 TV and 3 different boxes, giving us a total of 4 remote controls. Needless to mention, we still only have 2 hands. If we want to record a program from one of the STBs, we need to use 3 different remote controls (!). One for the TV, one for the STB, one for the DVD player. Not convenient at all, of course.

Thus, the ”one-remote-to-rule-them-all” idea was born. Of course, we will need two remote controls – one for the TV, and one for the HTPC. This is still much better than the current situation.

Another problem with the current situation is that we cannot even plug all the boxes in at the same time. The DVD player only has 2 SCART outlets. One is used for the DVB-S STB, the other one is plugged in to the TV. This means that if we would want to record something from the DVB-C STB, we would have to make sure that the TV is turned on, to let the signal ”pass through” to the DVD player.

Now… something more to take into consideration is that we are currently building ourselves a house. Getting a cable TV connection to the house is pretty expensive; almost 900€. This doesn’t feel like too much of a forward-looking solution. After all, fiber connectivity will come sooner or later. It might take 5 or 10 years, but it will come, so paying 900€ for something that will only last for a couple of years doesn’t feel like a long-term solution. (We would possibly get some discount on the fiber if we already have the cable, but still…)

So, I’ve started the investigation for alternative solutions to our TV viewing. Let’s forget the HTPC for a while and just think about this, because it’s kind of the fundamental thing: how do we get the TV signal into our TV?

There are basically three different options:

  1. Anvia’s Svea TV option. This is a DVB-T-based solution (e.g. regular terrestrial television).

    Pros:
    legal option, gives me 5 of the basic Swedish TV channels.
    Cons: requires me to buy a new terrestrial antenna, doesn’t include the Christian FTA channels, quite expensive per-month fee.
  2. Anvia’s IPTV option. In the area where we live, Anvia doesn’t provide DVB-C. There is only the local cable TV company, which cost about 900€ (mentioned above). But: Anvia do offer an IPTV-based solution, via ADSL.

    Pros: legal option, less expensive than Svea TV. Also gives to opportunity to buy some additional channels (like Kanal 10, one of the Christian FTA channels mentioned before), uses existing infrastructure that we are already paying for (we have 8 Mbit ADSL at the moment, so the additional cost for the IPTV is pretty small).

    Cons: too much of a ”locked in” solution. I can only use the provider’s own STB; there is no PCI-based solution for example, that lets me use this solution in an HTPC. It also doesn’t include the Christian FTA channels (well, some of them are available but as ”pay” channels).

  3. And finally, the option I’ve decided to go for: Viasat’s ”SVT Package”. This package is one of their best kept secrets. If you look at it, you can even get the impression that they don’t want you to find out about this. You’re right: they don’t. Of course, Viasat (just like Canal Digital for that matter) of course prefers to have you order one of their ”pay” packages, where they get a greater benefit than they get when you use one of the ”free”, minimal packages.

    Pros: DVB-S-based; I can get all the Christian FTA channels I want from the same satellite where I’ll get the regular Swedish SVT channels (or the other satellite my dish is pointed towards). More open and flexible solution than the IPTV-based solution (i.e. possible to use in an HTPC).

    Cons: not 100% legal in the country where I live. Of course, the problem is not with the reception but rather with the subscription. Viasat’s SVT package is only available from within the borders of Sweden; I’ll get it by using a Swedish care-of address. But what I’ll also do, is that I’ll order the channel package from Anvia (without getting the IPTV box or the IPTV subscription), so I’ll pay for SVT + TV4 anyway. That way, I will have a moral (but maybe not strictly 100% legal) right to receive the channels. :-)

The only channels I’ll get ”for free” with this is TV6 and Kanal 7, but I’m only watching TV6 during the ice hockey world championships (and I’m ”kind-of” paying for the channel to Viasat anyway… and it’s an advertisment-funded channel anyway…).

Well, it’s not strictly legal, but for the channels we watch regularly (SVT and TV4), I argue that we have the moral right on our side (since we’re paying for the channels anyway).

How about the Finnish channels then? The good thing about them is that they are being broadcast freely (as in ”free non-alcoholic beer”) through the Anvia ADSL service. Getting them into the HTPC should definitely be possible.

So… my choice is the DVB-S-based solution + free IPTV for the Finnish channels. What about the rest of the reaons for the HTPC then? Well, one of the things I want to be able to do is to record programs for later viewing. We can do this now, but it’s far from simple (because of the 4 remote controls and plethora of STBs/etc). Having all the TV channels in one single HTPC will simplify this, of course.

Something else we want to do is to watch downloaded programs. Yes, it happens that we download TV series, for example if we’ve missed one episode. This can be seen as ”fair use”/”peer sharing”, if we’re talking about a channel that is included in our subscription anyway. (yeah, I know the TV BitTorrent publishers remove the advertisments… it’s a shame, don’t blame me… But really, if I would have had a friend record a program, they could have removed them afterwards as well…)

Finally, something that we want to support is streaming of programs. Sports events (Malmö Redhakws games, for example :-) ) or movies (SF Anytime). Now, here is where we’re getting into problems.

You see, I’m thinking about building a Linux-based solution for this, maybe with MythTV. The only problem is that SF Anytime and Viasat OnDemand only streams their programs using Windows Media Player technology, which doesn’t work so well on Linux. SVT Play is better, since they use Flash (which is supported on Linux). On the other hand, buying a Windows Media Center (or similar) license just to be able to stream seems a bit expensive. Besides, I like the Linux solution, it’s more geeky and cool. :-)

So, my download is finished by now, and Debian is on a CD. This became a long blog posting, it took quite some time to write… I’ll go ahead in a future posting and describe my ideas for the hardware in this HTPC. The Debian installation I will do now (maybe tomorrow since time is so late already) is on my laptop, for testing out MythTV and see how well it works with the free IPTV I mentioned above. I’ve heard that MythTV is slow in the channel switching because of how it records all programs you’re watching automatically. Time will tell if this is indeed a problem.

En guldstjärna till alla som orkade läsa ända hit. :-)

Inga kommentarer