Every once in a while I get a hankering for a hands on type project. Back in May that project was the Xbox mod. This time around it was to build myself a new server after the last one I'd been using overheated while I was away on vacation and the air conditioning was off (at least, that's my guess on the diagnosis). Of course, I would have liked to build something from scratch, but college funds being what they are that isn't always the most viable option. Instead, I took a trip up the the local TriftKo (yes, they spell it with a "K") and picked up the cheapest (and at that time, only) computer they had. I really had no idea what kind of computer it was (though, I made a really close guess based on the ports on the back), but that didn't matter for my needs, namely, to run a web and file server.
Whenever I get a new computer I like to boot it in its "virgin" state to see what the computer is and what it was used for before it came into my possession (so far, I've only found mild pron on one computer). After that, I take the thing apart and, dipping into the vast amounts of old computer parts available to me, upgrade it to make it as high tech as possible. After a long amount of research, trial and error, a BIOS upgrade, and some dabbling in GRUB for DOS I was able to get the computer up to the following specs:
Pentium 166Mhz
64MB RAM
1.2GB Primary drive (still has Win98 on it)
4GB Secondary drive (running the latest Debian)
DVD-RW drive (which doesn't have any power since there are only two large molex adapters available)
Ethernet card
PCI USB 2.0 card
Yeah, it's a laughable computer to say the least and its age did prove to be more of an issue than I originally anticipated. The first was the inability to boot from CD even though the BIOS claimed to support it. I figured the old BIOS was the problem, so I set about trying to update it. Unlucky for me, IBM has pulled all BIOS upgrades for old systems off their site so I was stuck wading through forums. Once I got the BIOS upgraded it still wouldn't boot from CD, but it did correct an issue with identifying the 4GB drive (and now I have support for drives up to 8.4GB).
So, after all those many hours I was still unable to boot my Linux install CD. It was about then that I had the genius idea of copying the Linux kernel off of the install disc onto the Windows 98 drive and starting the installer in GRUB from DOS. Took a few tries to get off the ground, but it did wind up working. Things were looking great, then Linux took six or seven hours to install. I decided to sleep at this point.
Luckily, after Linux was installed and I got ssh up and running I could close the box, clean up the mess that had appeared on the floor, and continue the finishing touches from the comfort of my laptop. Everything after that went pretty well, but there was still the issue of not being to use my 120GB hard drive full of stuff that I usually streamed to XBMC. Luckily, the fix for that was really, really simple. Buy a PCI USB card and use my external hard drive enclosure. For the first time in this entire project, and my entire time messing with Linux, it worked first crack out of the barrel without any extra configuration on my part (save changing my home directory mount in fstab).
So, it's been far more useful as of late, but I wanted to take it a step further. The box does have a sound card and seeing as it is sitting right next to my speaker system I figured "Hey, why not use it as a stereo too?" So, that's what I've been doing this evening. Getting the sound card to run was a bitch, especially with the little info I could find on the card itself. Looking through the startup messages it was being found as "AT931 Audio 16". Google turned up two pages on that. It turns out the card is actually a OPTi 82c931, but even finding the correct module for that was a pain in the ass (it's snd-opti93x). After that, I followed this handy guide on the AlsaProject wiki to get the rest up and running.
So now my computer plays sound which is pretty sweet. But, I'm again being bitten in the ass by its age. If you try to do anything while playing an MP3, file access or an HTTP request, the audio starts lagging. So, I think I've devised a clever way around said issue. I'm going to write a series of scripts that will convert the MP3 to a wave file and play the wave (which requires almost no processor time). Couple that with a web interface for making playlists and it'll be the most kick ass twelve year old computer of all time.
The internet has and continues to change the way society operates. The biggest thing the internet has going for it is instant availability for anything you could ever want. Be it from news, to sports, to knowledge, whatever, it's out there and waiting to be accessed whenever your heart desires. It's no surprise that this on demand media is killing the mediums of old: radio, newspapers, magazines, etc. However, the one that seems to be taking a hit the most, recently, is television. Why wait for a show to come on when you can just watch it on the internet whenever you want? Okay, this isn't really about the philosophies of the internet, but it seemed a nice segue into a recent project of mine.
For anybody who's perused the geek community long enough, you've probably heard of console modding. The act of taking a console and breaking it's will so that it becomes your little bitch and does whatever you say. I've done this before, most notably with the PS2 and the DS. I'd been using my PS2 to watch videos, but the media programs out there for it are nowhere near as extensive and awesome as Xbox Media Center (XBMC). This program is truly amazing. It is, by far, the best media center program in existance (yes, it trumps Windows Media Center and Front Row). XBMC has it all: support for more video codecs than actually exist, a beautiful interface, a robust scripting engine (a la Python), and it's open source to boot. It was this promise of media tranquility that pushed me to purchase a second hand Xbox ($60 from GameStop) and take a shot at modding its brains out. What I didn't realize, was that the road that lay before me was a long and bumpy one.
There are many ways to mod your Xbox, but all of them fall under two categories: modchipping and softmod. Modchipping (a word that I honestly just made up) is the act of actually soldering a chip to your Xbox that overrides it's flash bios and runs its own software. Having no soldering skills, I decided to go the safer route and did a soft mod. There are a goodly amount of softmods out there, but I used a combo of a game save exploit and hot swapping to get the job done. Hot swapping, in this case, is the act of swapping the IDE cable of the Xbox hard drive to hook it up to your PC so you can read and write files to it. It has to be done while the Xbox is running becase the drive is locked and only the Xbox that its shipped with can unlock it. I may post a condensed quide to the approach I used later, but here begins (finally) the sordid tale of my three days of agony.
Actuallt, I lied. A little more exposition is needed. The reason I chose to do a hot swap mod instead of the safer transfer a game save to the Xbox via USB drive was due solely to impatience. I would have needed to buy an adapter with which to hook up my fash drive which would mean ordering from some shady mod chip store online, waiting a week or two for delivery and I just didn't want to wait that long. Plus, being a guy whose messed with computer hardware before, I was pretty confident in my ability to pull this off.
So, I got home from buying my Xbox and set to work immediately. I was only a minute into the operation when I ran into my first major problem: the Xbox had torx screws, and I was fresh out of torx screwdrivers. So, instead of bugging my room mate to take back to the store to aquire said screwdrivers, I did what I usually do in this situation: find something else. In this case, I used the spare keys for my bike chain. A few minutes and torn up fingers later, the top came off and I was ready to do the swap.
Being that I only have a laptop, I couldn't plug the hard drive directly into my computer. As such, I had to go through a USB enclosure. This itself presented a myriad of problems, though I didn't realize it at the time. Perusing the intewebs had told me that I needed a program called hdd_driver to copy my stuff to the drive. So, going through the usual channels, I acquired myself a copy of that and was greeted by five thousand missing DLL errors. So, instead I decided to look for an alternative. The next thing I came across was a Linux distro with built-in FatX support (the file system type of Xbox). Attempting to use this raised one issue, though: it would only recognize drives plugged into an IDE channel (hda). Being that I've had some experience with various virtual machines, I knew qemu emulated this. So, I set up my environment and booted. However, I was greeted with "Xbox partitions not found".
I didn't realize it at the time, but I was not going about unlocking my drive properly at the time. Getting this done correctly is something that requires fast movements and, when you've bricked the dashboard, precise timing. Once I realized this and had gotten the drive recognized, I attempted to install my exploit (which was, at that time, a fonts exploit and not the game save one) via a handy little install script that came with the Linux distro. How nice is that? What I didn't realize at this point was that though my drive was recognized and could be read from, writing was not working correctly. So, this script did it's thing: it went and formatted the C drive and replaced all the dashboard files with the hacked versions... or at least tried to.
It came back with a few "unable to copy" errors which unnerved me a little, but I reconnected my Xbox correctly and booted it up only to be greeted by the ambiguous error 21. My dashboard was completely unbootable and with it so shrank my window of opportunity to hot swap while the drive was still unlocked. After about twenty or so tries I finally managed to get a good swap again and found that my C drive was in ruins... and there wasn't anything I could do about it. Everything I tried to do resulted in "Unable to copy. Read-only file system." At this point I thought it was because it couldn't delete the gibberish files that had been written from the script I had run. So, I decided to wait until the next day and pick up a copy of Splinter Cell and use the game save exploit for it.
So, I picked up Splinter Cell and proceeded to get the files necessary. After some time I managed to get a succesful swap again, erased my E drive (where the save games are stored) and attempted to copy over the data. I was again greeted with ominous "Read-only file system" error. I spent the rest of that day and most of the next basically doing the same thing: turn on Xbox, swap the drive, attempt to copy, fail, change something, rinse and repeat. Nothing worked, and I was afraid that I'd just wasted sixty bucks on a console that could only play games. Needless to say, I got really good at swapping the drive.
I was about to give up when I decided to blame something other than the Linux distro I was running. I decided to do two things: swap differently, and use a different IDE cable. The cable I had been using was a one device, 40-wire cable. I moved up to a two device, 80-wire cable and unplugged the DVD drive from the Xbox as well. By unplugging the DVD drive I gave myself a larger window of opportunity to swap as the system will fail that before it checks the hard drive. So, after I'd done this I went through the usual paces and, lo and behold, files were copied. To say I was ecstatic would be an understatement. With the exploit running and the FTP server working, I now had an easy way to transfer my files to and from the box and the rest went down pretty easily (there was one more minor hiccup, but something that I figured out pretty quickly).
So, now my Xbox is fully modded and running XBMC, and it is really freakin' sweet. All the pain and emotional anguish I suffered had finally paid off, and I now have cable television for the price of my internet connection and a one time fee of $60.
Comic
My new 19" widescreen LCD monitor is indeed a thing of beauty, but I wouldn't necessarily kiss.
I seem to have broken the post form when I made it "spam proof". I'll have that fixed in a day or two.
In the mean time I am recovering from a... ahem... computer problem. I shall just say this: don't go around deleting things unless you are absolutely, one hundred precent sure they don't have some sort of low-level hook into your system. And on top of that don't go stopping services unless you are completely certain you aren't going to need it. So, yeah.
That all said I won't be having a comic up today. I'll probably put something up on Tuesday.
Comic
Alright, it's way early but I've been working really hard on it the last couple days and I wasn't about to wait several more just to post it :-P. Anyhoo, I hope you enjoy (and I'm sure I'll enjoy the interesting stream of comments this'll generate....)