Wednesday, December 26, 2007

New Laptop

My old Toshiba laptop was starting to wear out (it had been doing double duty ever since the motherboard went out on my desktop machine.) The screen hinges were wore out requiring a hand to hold the screen up or something to prop it on. And the CD/DVD drive had given out long ago. I need a computer for school work, so I started looking around. I happened to check one of the Black Friday websites looking to see if there were going to be any deals on the day after Thanksgiving. I ran into an ad for a pre-Thanksgiving special with a Dell for $399. After customizing it somewhat, my total was around $670 (with free shipping.) As an added bonus, I could get it was XP instead of Vista. (Although the upgrade from XP Home to XP Pro itself added $100.)

Thursday, November 15, 2007

Code Complete, Completed

I finished reading Code Complete a couple of weeks ago. It's a very good book for developers. You'd think a book that just seems to cover some basic stuff (like naming variables) would be boring or not very insightful. But it covers each topic so well and makes you see stuff you probably hadn't thought about. I'm already applying things I've learned to the code I write. (Like keeping variable declarations close to the area they're used. )

And it's not just about the small stuff either. It has chapters that cover programming tools, testing, collaboration and even personal character and the effects it has on your code.

Now, the only thing left on my Becoming a Better Developer list is to finish my Simple Shooter game. (I've still got two months before the self imposed deadline.)

Monday, October 1, 2007

Simple Shooter

I've recently mentioned that in the next six months I wanted to write a simple game. This is what I have so far. Right now it's code named "Simple Shooter." It's currently being developed in C using the Allegro game programming library. The graphics are from Ari Feldman's SpriteLib GPL and the sound effects are from the freesound project.

Monday, August 20, 2007

Becoming a Better Developer, part 2

Last month I posted about Justice Gray’s meme of Becoming a Better Developer. I posted what I was going to do in the next six months to become a better developer and challenged four of my friends to do the same. Here’s what they said:

Brian Whittington:

My goal is to “upgrade” my existing skills to take full advantage of the .Net 2.0 Framework. I’m still stuck in the 1.1 Framework mindset, at least to some degree (I’m still using datagrids!). Also, I want to begin using and researching SQL 2005 more so that I am more comfortable using it. I’ve been using SQL 2000 for so long it’s kind of my comfort blanket and I need to move on. Also also, I want to use better OOP techniques in my code. I’ll probably find some good books and go from there.

As for myself and where I am: I’m on chapter 23 (out of 35) of Code Complete. And I’m on the last chapter of Head First Object-Oriented Analysis and Design. My game is coming along as well (though it has been a few weeks since I worked on it.) It now has sound effects.

Friday, August 10, 2007

I just wanted to use a listbox

I just wanted to use a listbox. How hard could that be? Harder than I thought:

I’ve recently decided to try my hand at writing programs for Windows Mobile Smartphones. I had an idea for a program and wanted to see if I could use the Compact Framework 2.0 and get it to work.

One of the main components of my program is a list. So, not surprisingly, I wanted to use a listbox. But it turns out that the version of the Compact Framework for Smartphones doesn’t have a listbox control.

So, I figured: “Oh well, I’ll just have to use a listview control set to List mode.”

(I first met listview controls in VB 6; didn’t like ‘em then and I’m still not too fond of ‘em now. I guess I never cared for the way they handle multicolumn lists – I found subitems to be a pain. But for this project I just needed a single column list.)

Now, in regular .Net a listbox control can hold objects -- as long as the objects implement a .ToString() method. The listbox uses this method to determine what to display in the list. This is exactly what I needed. Unfortunately, listview controls don’t just hold any arbitrary object. Instead they hold listviewitem objects.

So, I tried creating a new object that was derived from a listviewitem object. I planned on adding methods and properties to support my needs. I overrode the .ToString() method and found that listviewitems don’t use .ToString() to determine what text to display in the listview. Instead they have a .Text property. No, problem. I’ll just override the .Text property. Guess what? Listviewitem’s .Text property isn’t overridable!!!


Thursday, July 12, 2007

Becoming A Better Developer

I recently read a blog post by Justice Gray where he discussed what he plans to do to become a better software developer. His theory was that if he made his plans public, he would be more likely to follow thru with them.

He personally decided to read 27 software development books before October 2007. I don't see how he could possibly absorb everything by reading that fast. But the idea of another technique to become a better developer appealed to me. I consider myself a professional and am always trying to improve my skills. Unfortunately, since I'm not a popular tech blogger, there is no one to tag me. So I'm going to go ahead and tag myself :-)

Here are the things I'm going to do in the next six months to become a better developer:

#1) Read.

#2) Write a simple game
  • I've always wanted to create games, but never got much past Pong. I'd always start on something and never finished it. This time I just started on a simple space shooting game and I'm going to see it through.

As for tagging, I'm picking:
  • Brian Whittington
  • Matt Dyar
  • Angela Free
  • Eric Sansom
You guys have to post to the internet what you're going to do in the next six months to become better developers. (If you don't have a blog or other place to post it, send it to me and I'll add it to the bottom of this post.)

Update: I've added a new post with the responses it've gotten back.

Wednesday, March 14, 2007

My MythTV Journey, Part 11

Ok, I now have the beginnings of a working MythTV system. I can pause live TV and start it back. There are, however, still several things to be worked out:
  • Sound - Something's wrong with the sound output from the system. It sounds attenuated. I don't know if it's my sound cable or a setting in the system.
  • Cables - Some of my cables don't quite reach :-) I need to get some longer ones.
  • Can't change channels - I'm using a DirecTv satellite box so I can't change channels yet. I have to either configure the IR Blaster that came with the PVR150 or aquire a serial blaster cable. I hope to be able to just build the serial blaster cable.
  • Overscan - the picture on the TV is square but my TV isn't. It has sides that are curved out. I believe there is a setting in MythTv to adjust this.
  • Colors - the colors don't seem quite as bright when I run the signal thru the computer. I'll have to see if I can adjust them.
  • Program Guide - I'm using DirecTv which provides it's own guide. I'll have to see what others have done to get a guide that I can use with DirecTv.
  • Internet - The computer isn't hooked to the internet. I've got to figure out how to do that as well. (Would be nice if I had a cable modem or something, but the only thing available out here is dial-up.)

It's alive!

My MythTV Journey, Part 10

I installed the PVR150 and put in the KnoppMyth CD. After installation, I put the batteries in the Haupauge remote, said a quick prayer and pointed it at the IR receiver. I pressed a button and the MythTv menu changed! It worked! Or at least the remote did. Then I selected "Watch Television". After a several second delay I saw The Disney Channel on my screen. Now for the moment of truth. I pressed pause. The image onscreen froze. I bar popped up showing how much time was being recorded. I hit pause again. The characters jumped back to life. It worked! I cheered! There were still some things to do to make it fully functional, but making it this far was a great event. (For me anyway.)

Circuit City to the Rescue!

My MythTV Journey, Part 9

I had read on the MythTV wiki and the forums that ATI All-in-Wonder cards would not work with MythTV. So, I tried it anyway. Didn't work. :-)

Reading the forums I discovered that one of the most popular and not too expensive capture cards for MythTV is the Haupauge PVR150. However, it was also at the forums that I found a warning. It seems that around Christmas, Haupauge experienced a shortage of these cards. So, they began to put PVR1600 cards into the PVR150 boxes. Now, the PVR1600 is a better, more expensive card. I'm sure several people where happy to receive it, but it doesn't work with MythTV. I emailed Haupague and asked if there was any way to tell from looking at the box if it contained a PVR150 or a PVR1600. They should no, but that if I ended up with a PVR1600 they would glady swap it out for a PVR150.

I had been to my local Best Buy and noticed that they didn't carry the PVR150. I checked Circuit City's website. Not only did they carry it, but my "local" store had them in stock. After discussing it with my wife and getting the okay to spend the money, I took a chance and purchased one. Fortunately it was a real PVR150!

local=An hour's drive

Some Research

My MythTV Journey, Part 8

Searching the previously mentioned forums, I discovered several things:
  • My processor and memory should be adequate
  • The GForce 5200 generally works well with MythTV
  • The old ATI All-in-Wonder card I had lying around wouldn't work in MythTV
  • My ATI Remote would work with MythTV.

A hard drive! A hard drive! My kingdom for a hard drive!

My MythTV Journey, Part 7

Well, I had a machine, now I needed a hard drive. I don't want to use the one currently installed. The plan was to unhook the Ubuntu drive and use an older drive that I could format. I searched the house for a hard drive. I found a few, but either they already had data on them that I didn't want to lose, or they were too small. (I even found an 80 MB. That's right MB, not GB). Eventually, I noticed that their was on old, unconnected drive in the computer I wanted to put a drive into! It was 13 GB. Of course, that wouldn't be enough to record a lot of TV shows on, but it would be big enough to install MythTV and see if I could get it working.

By the way, here's a tip for ya:
If you want to play with alternate operating system, but don't want to mess up your Windows install (and aren't afraid of messing around inside your computer) get another hard drive. You can install Linux on the new drive. When you want to run Windows just hook the Windows drive up and unhook the Linux one. (Of course there are more elegant solutions, like using Grub, but this way is simpler if you're just getting your feet wet.)

KnoppMyth Forums

My MythTV Journey, Part 6

I've found a forum where people discuss KnoppMyth here:

KnoppMyth or MythDora?

My MythTV Journey, Part 5

In my research I discovered that there are basically three ways to install MythTV:
  • Install it yourself into your already working Linux distro
  • Use the KnoppMyth Live CD
  • Use the MythDora Live DVD
The last two options sound easier. (I'm not afraid of installing Linux; it's just that these Live CDs will install everything you need and help you get set up.)

MythDora apparently installs a complete installation of Fedora Core plus MythTV. KnoppMyth, however, seems to install a more minimal system focused on running MythTV. This was more what I was looking for, so I chose KnoppMyth.

The Search for Forums

My MythTV Journey, Part 4

Anytime I start to play with something new, I try to find active forums were people are discusing the thing. For MythTV, I discovered

Forums can be a great place to talk with and get help from people who share your interest. But please remember a couple of things: 1) Be nice 2) The people in the forums are generally nice but they are probably tired of answering the same questions over and over. So before you ask something, use the forum's search feature to see anyone has already answered your question in the past.


My MythTV Journey, Part 3

Now that I knew what software I was going to use, I needed some hardware. I had recently been playing with Ubuntu on an older system and decided to see if it would work.

It has these specs:

AMD 950 MHz Duron
256 MB memory
GForce FX 5200
80 HD with Ubuntu and other Linux distros installed.

The plan was to reuse as much as I could and try to buy as few new parts as possible. I had an old ATI All-in-Wonder and an ATI Remote control lying around. I planned on working them in if I could.

Tuesday, March 13, 2007

And the winner is...

My MythTV Journey, Part 2

I decided to research the available Media Center programs. On the Window's side, there is Media Portal which I had already played with. On the Linux side there is MythTV, GeeXboX , Freevo and some others.

I had planned to research each one, but the more I looked into MythTV, the more I liked it. I originally wasn't interested in its TiVo like features. Don’t get me wrong, I have a TiVo and absolutely love it. But I was just trying to view videos on my computer. I figured I could install MythTV and then add the TiVo features later. But the more I thought about it, they more I wanted those features too.

Plus, just glancing around MythTV seemed to have a lot of support in terms of websites and forums.

So, MythTV won without much of a fight.

And so it begins..

My MythTV Journey, Part 1

It all started a while back when I decided that it would be nice if I could view some of the videos I had on my computer on my TV screen. My first attempt at this involved hooking up some wireless A/V sender/recievers I had lying around. This worked, but had a few problems. For one, my 2.4GHz phone interfered with the 2.4GHz A/V sender (even on different channels.) Another problem was that I would have to run back to the other room to start the video, which, of course, was a pain.

My next attempt was a little more successful. I placed my laptop next to the TV and hooked them together. Using Media Portal and my ATI Remote Control, I was able to watch computer videos on my TV. This worked, but it had quite a few problems:
  • It was a hassle to hookup all the wires (power cable, video cable, audio cable, usb adatper for remote, etc.) everytime I wanted to do it.
  • If I wanted to use my laptop, I had to unhook it.
  • Media Portal would sometimes slow down or lockup.
  • Couldn't play all the formats I wanted to.
  • Needed access to videos on desktop computer (w/ large hard drive). I could have fixed this by setting up a wireless network, but I never made it that far.
  • Took up space in entertainment center. (Space had to stay empty so I could ad and remove laptop.)
  • Pain to run Media Portal and them change settings on laptop to output to TV only.

My MythTV Journey

I’m currently in the process of constructing a MythTV for my living room. I thought this would be a good topic to write about so I’ve created a series of posts to bring you up to date on my progress. These are based partly on notes, but mostly on my memory so the timeline may appear wrong at certain times.

Hello, world!

Hi everyone. This blog is my outlet to express my thoughts and opinions on computers and technology.

I’m not really doing this to try to gain readership—it is more to fulfill a need to express myself. I’m a 30-something year old computer programmer. And while I don’t claim to be the best coder in the world, I would like to think that I have enough experience to share some useful information.