Thursday, December 18, 2008

Myth upgrade and problems related to other crap that I blamed on the upgrade.

My mythtv-backend box was making some funny noises, and considering /dev/hda is no-less-than 9 years old, I decided it was time to upgrade. I used Mythbuntu 8.10 and combined the frontend and backend on the machine I had previously used as just a frontend. I was able to do this because of a recent black friday special where I snagged an HDHomeRun for only $120. I have been nothing but impressed with it.

So the upgrade was actually very easy now that I look back. I did have one issue with the Nvidia driver which comes with 8.10. I chose the 177 driver, which as it turns out is incompatible with my Geforce FX 5200. If you have this card, or a similar vintage, save yourself some headache and choose the 173 driver.

I was worried about losing my old recordings. Well, let's be honest... I didn't want to sleep in the doghouse after destroying all my wife's recordings. Anyway, this was actually the easiest thing to do, just two commands: mysqldump to a file and mysql to reinsert on the new machine. http://www.mythtv.org/wiki/index.php/Backup_your_database Of course, this assumes that you have also moved over your recordings directories. In my case I moved the same drives over to the new machine so no copying was necessary.

There was one issue I ran into though, and I'll note it here in case anyone else has the same problem. While scrolling through the list of recordings I found a bunch that would not load. In fact, once I tried to view one, mythfrontend would refuse to play any, and occasionally segfault. The error I got was:
NVP: Couldn't find a matching decoder for: /storage/recordings/filename.mpg

This problem actually existed before my upgrade, and might have been related to some disk corruption. I tracked it down to a single video entry that when viewed in the selection window, would mess up all viewing of other recordings. It turned out that the actual .mpg file did exist, but there were no .png files generated for it. Is this what caused the error? I'm not sure, and I opted for the quick-fix, which was to delete the .mpg and then delete it from myth. Once I had removed that file, mythfrontend returned to its rock-solid, heart-touching glory.

Tuesday, October 7, 2008

Technobabble

Being a fan of tech and sci-fi, I am fairly accustomed to the occasional bit of technobabble thrown into a script. Some writers use it much more elegantly than others. I nominate the following clip from CSI New York as the poster-child for terrible technobabble.

Wednesday, August 20, 2008

My love/hate relationship with Steam

I play quite a few online games, and those which are the most fun are on Steam. At first I hated Steam, since it was yet-another account I had to sign-up for, and required me to be online to play my games. It has come a long way since the early days, and has grown to be the main distribution method for games. Indie developers are able to make their games available to millions of people without having to package or ship any cardboard boxes. Think of how many trees have been saved! I love that new content is continually added to the game I bought a year ago. Team Fortress 2 feels fresh, and Steam is able to deliver it without me having to download and apply countless patches manually.

Unfortunately this automation comes with a price- last night I wanted to play TF2, but could not because of a bug in the Heavy Update. In the old world I would simply roll-back to a previous release, but Steam does not allow that... and I'd be out of sync with the servers.

What was the bug? It didn't actually show up until after I had played the new version for an hour and exited the game. When trying to launch the game again, it failed because it didn't like this file c:\program files (x86)\steam\YourUserName\steamapps\tf\tf2_playerstats.dmx Simply deleting it fixes the issue. I found the details the following morning, here.

How does a bug like this get past QA? Sure this was a tricky one, but in reading through that thread, you'll see that likely thousands of people were affected by this. Most have Nvidia graphics cards like mine, but I saw some ATI references as well. Some are using Vista, some XP. It seems to me that this release was rushed. What for? It's not like this patch is bringing in more direct revenue for Valve, so why release something that hasn't been fully tested? Why risk breaking my favorite game to add a few new bells and whistles. TF2 was rendered useless and I spent the rest of my evening trying to fix it.

I realize that a QA department cannot catch every error, but I feel like this one could have been prevented had the release not been rushed.
As PC gamers, are we too forgiving when a game is buggy? Do we have lower expectations than console gamers? Maybe Valve expects the world to be their QA department. They run some quick checks, but all regression is performed by the end user. If that's the case I'd just like to know ahead of time.

Comments?

Thursday, March 13, 2008

Mythical Television

I was reading through my blog here, and the last two posts make it sound like a long-running rant. So today, I've decided to write about something I completely love, something that I enjoyed setting up; something that has freed me from the shackles of monthly subscription television- MythTV.

MythTV is much more than a do-it-yourself TiVo™. It represents open-source ingenuity and digital rights freedom all on your television. It's like all the things you wanted your TV to do, all rolled up into a convenient package, eager to control your home theater.

I decided to build my solution as cheaply as possible and scrounged up used parts wherever I could. I also decided I only cared to watch/record digital television since over-the-air analog broadcasts will cease in February 2009.

The machine I built for MythTV uses an older Athlon64 3000+ socket 754 2.0Ghz CPU. 1GB RAM. My display is an 8-year-old 24" SUN Widescreen CRT. (it's a rebranded Sony) It was very cheap since I got it used, and it does 1920x1200, so the 1080i stuff looks fantastic. The video card is a nicely aged Nvidia Geforce FX 5200 AGP. Everything I've read online has shown that people have better success with Nvidia cards since they seem to be more Linux-friendly than ATI. Let me know if you find otherwise.

Myth has two main processes:
mythbackend- talks to your tuners, writes captured video to disk, maintains your TV schedule database, and much more.
mythfrontend- displays video, provides the user interface.

I used to run both the front and backend on that machine and it handled it without issue. I decided to separate them just for fun and to see how well it worked; so now I am free to power-down/tinker/completely reformat the frontend machine since all recording is done elsewhere. This has worked well, since the backend machine is a file-server that runs constantly anyway.

One issue I have had in my setup is occasional stuttering. After manually or auto-skipping commercials on 1080i recordings, both video and audio freeze for a quarter-second, continue for a half-second, freeze again, etc. This usually resolves itself in 10 seconds or less, but is slightly annoying. Lower quality recordings don't seem to have the same problem. I believe it is due to a lack of processing power on my backend machine. The problem was *much* worse when I had other CPU-intensive processes like transcoding start up while trying to stream a recording at the same time. A dual-core proc should fix the problem, but I'm doing this on-the-cheap remember? Thankfully, Myth gives you the flexibility to restrict when those processes can run. Mine now only run between 2AM and 6AM- problem solved.

By the way, commercial flagging is one of those CPU-intensive tasks, and it works incredibly well. Try to get your Comcast™ DVR to do that! Be sure to enable "Auto-Skip," you won't be disappointed.

My backend machine specs:
AMD Athlon XP 2400+
1GB RAM
GeForce 4 MX (pretty near vintage now, but it doesn't matter since I don't display TV here)
Two Hauppauge HVR-950 USB2.0 HDTV tuners.

The tuner cards are often the most difficult piece to setup. My cards use an experimental driver which actually works quite well, but definitely isn't plug-and-play. I went with these because they are cheap; only $50. My first had a rebate and I bought my second used from a friend. Also, I am only recording over-the-air digital ATSC signals. Digital Cable TV channels use QAM and these cards can't read that. If you decide to use these cards, I highly recommend this helpful guide.

I read somewhere that the MythTV 'reference-card' is the PCHDTV HD-5500. It has native Linux support and they don't even write Windows drivers.

Another compelling alternative is the HDHomeRun. It is a box with two tuners that sits on your LAN and puts video wherever you want. They provide step-by-step instructions for setting it up in Myth.

Both of those tuners can read unencrypted QAM signals from the cable company, but unfortunately many premium high-def channels are encrypted, and as far as I know only their proprietary boxes can display that content.

You'll also want a remote control for your frontend machine. I like the StreamZap since it comes with a receiver and was extremely simple to setup.

There are a few ways to install Myth. I believe I chose the easier path. My backend runs Ubuntu, so I just used apt-get and it walked me though the setup. For the frontend I tried out a few ready-to-go Myth distros: KnoppMyth, MythDora, and Mythbuntu. I like Mythbuntu best- they wrote a sort of Control Panel UI which eliminates the need for manually editing a bunch of config files. It is very well done and they follow the 6-month release schedule of Ubuntu.

I bought one year of TV schedules from schedulesdirect.org . They provide TV listings for all local/cable/sat providers throughout the US for $20/year. I went with this option because it is simple- you just setup an account with them and tell Myth your user/pass to login. I wanted my solution to be completely free, but at that price I'm probably just barely covering the amount of bandwidth that I use. Myth retrieves two weeks of TV listings everyday.

I'm happy with my solution- especially since it is using mostly older hardware I had laying around. Myth is more than just a DVR- it'll play anything mplayer can read, which is, well, anything. My machine isn't quite fast enough to display h.264 1080p recordings, but handles h.264 720p just fine. There are some pretty cool plugins that let you do everything from view your local forecast, to ordering a netflix movie, to running videogame emulators. All on your TV, with a remote, from your couch.

Myth is truly awesome, and I highly recommend you give it a try. I dumped my Dish, as well as the $50/month price tag that came with it. Few other D-I-Y projects can match the feeling of liberation MythTV provided.

Tuesday, February 5, 2008

AT&T Wireless is trying to milk me

Yes ladies and gentlemen, the old American Telephone & Telegraph company (aka AT&T, Cingular, Ma Bell) is treating me like a farm animal; only I yield monthly amounts of cash rather than a warm lactate every morning. Lately, they've been trying to squeeze even more out of me.

My most recent trouble with them has been over this month's bill. I finally noticed a few things have changed. For one, text messages are $0.15 to send, rather than $0.10. I don't have a text message plan- frankly, it's ridiculous that I should have to pay extra to send messages that use less bandwidth than a fraction of a second of voice traffic; but that is an entirely separate argument.

The real issue this month is a change in policy about when nighttime billing starts. I got my first mobile phone back in college- long before the Cingular merger. Money was really tight back then, so I made sure to know the rules on when my nighttime minutes began. 9pm is my starting time, and if I placed a call at 8:59pm and talked for an hour, I would only be billed for 1 minute. According to my bill, this is no longer the case. I placed a call at 8:28PM and spoke for 117 minutes. Unbeknownst to me (as usual), I had already used up my monthly plan minutes, so this was a $0.35/minute call! According to the normal system, I should have been billed for 32 minutes, or $11.20. I was actually billed $16.80, the equivalent of 48 minutes. Time to call 611!

I explained the situation to Angelina at AT&T customer service...

Angelina: <in a southern accent> "Well sir, we had a big meeting about this, and if you place a call before your nighttime minutes begin, you will be billed for the full time of that particular call."
Me: "If that's true, why was I billed for 48 minutes instead of 117?"
Angelina: "uhh, lucky glitch?"
Me: "You mean to tell me that I and millions of other AT&T customers have our personal information in a system with 'billing glitches?' Are you going to fix this glitch so that it doesn't happen again?"
Angelina: "Sir, I don't know how to fix it, but I can remove that charge."
Me: "Well, that's a start."

In the end she removed the $16.80 charge, but I really shouldn't have to run a fine-toothed comb over my bill every month. Their website reminds customers: "Paying your wireless bill has never been easier! Sign up for Auto Pay." Thanks, I'll pass...