Tuesday, 3 July 2007

Developer Developer Day 5 Report

On Saturday I attended the free software development conference Developer Developer Day 5. I first heard about this event just a few months ago and when I had a look back over the presentations that had been given in previous conferences I became quite excited. This is a community run event and as such it works differently to many commercial ones.

Firstly, the community provides the content and secondly, the community decides upon the agenda. Submissions are accepted a few months in advance and then they are posted on the DDD website and voting is opened up. We got to choose 10 presentations that we would most like to see. The presentations that receive the most votes get put in.

Facilities

Seeing as the event was free I wasn't expecting all that much but I have to take my hat off to Microsoft here - the facilities were excellent, as good as any paid conference that I have been to. I had never been to the Microsoft Campus before but needless to say it was very swish indeed. They put on free food throughout the day including breakfast rolls, loads of cookies and unlimited coffee. Who can say no to free food eh?

The presentations that I chose to attend were held in the Chicago 1 room which was the main theatre and the Memphis room which was smaller. Both were excellent - very good seating, air conditioned, good sound quality, a nice clear screen for everyone to see. Sitting through an all day conference can be tiring but having comfortable conditions makes it a whole lot better.

Of course, food and seating aside, the most important aspect was the content of the presentations. I was not disappointed. The sessions I chose to attend were:

  • An Introduction to Unit testing with Mock Objects - Colin Mackay
  • Bluffers Guide to C# 3.0 - Ian Cooper & Oliver Sturm
  • 10 Cool Things to do With C# 3.0 - Ian Cooper & Oliver Sturm
  • Do Design Patterns Make Sense in ASP.NET? - Alex Homer
  • CSS 101 - Moving Away From Table Based Layout - Dave Sussman

The Unit Testing Talk

I really enjoyed the talk on unit testing. I have dabbled with unit testing but so far it has all been very manual. I have used a few unit test frameworks such as Boost.Test in C++ and MBUnit in C# but I have not used a mocking framework before so I found this very interesting. Colin has supplemented his talk with a comprehensive article which he has posted on his website along with the slides and source code used in the talk.

The C# Talks

The two C# 3.0 talks were a bit over my head. I've only been using C# for about 4 months and I still have a lot to learn. I think what these guys wanted to do was cram in as much cool new stuff as they could into the two hours to whet our appetites and to pique our interest in the upcoming features of the new version of the language. They succeeded :-) Throughout both the talks I found myself thinking 'oh yeah that's cool' quite a lot but much of the second session was going over my head. I picked out two main themes underpinning the talks. the first was that of code reduction; Microsoft are trying to reduce the amount of redundant code we have to write and that's always a good thing. The second theme was quite a paradigm shift for me and that was that the new features promoted a shift towards a functional style of programming and away from traditional imperative styles. I studied functional programming at Uni and although I can see the benefit I find it very unnatural to use.

The ASP.NET Talk

ASP.NET is also something that is quite new to me (ok very new) but I was interested in the idea of applying design patterns to it as I hadn't seem them mentioned in any books I have booked at. For me, this talk was the weakest of the ones I attended. The speaker put many diagrams in his slides which showed how the design patterns worked and showed a few pieces of code but I felt that he glossed over them very lightly. Also on some slides, he put several patterns together on one diagram which confused me a little. This is probably my lack of understanding rather than any fault of the speaker though.

The CSS Talk

Finally, the CSS talk. This was my favourite talk, mainly because I was able to understand all of it! The main aim of the speaker was to encourage the audience to start thinking about the correct way to build websites using web standards rather than continuing to use out dated practices such as embedded styling and table-based layouts. There wasn't a lot of 'meat' in this talk, he could have gone into a little more depth I think but for me i came away feeling like I had learned quite a lot and i wanted to go away and learn more.

All in all, a thoroughly enjoyable day.

Wednesday, 20 June 2007

My Love Affair with C++

I first started learning C++ in around 1997, and I used it in my second job as a developer up until around 1999. I lost my job then and pretty much stopped programming entirely so I never really got my teeth stuck into the language.

Over the years I dabbled a bit but I didn't get to do much with it until I went to Uni. Here I had lots of opportunities, most notably in the third year for my project. I chose to develop an online RPG creator called Morde. This was quite a hefty project, there was a client and server, both developed in C++ (my first foray into network programming) and a 'builder tool' which I wrote in C#.

At first I had a lot of plans for Morde and I wanted to continue with it after Uni but towards the end of the project I ran into many problems and in the end, I just decided to do what I needed to do for the sake of the Uni project and then dump it.

However, it had given me a taste of non-trivial games programming using C++. After Uni I got a job at Aston Broadcast and for the first 6 or 7 months I used C++ to develop client / server applications which was pretty cool. In those first few months I got myself reacquainted with the industry and started learning about all the new developments to the C++ language that had been going on in recent years.

There were a few things that struck out at me. Firstly, the Boost libraries which are open-source libraries of handy utilities written by many well known industry professionals, had really grown over the years. C++ is renowned for being so painful to program in. The standard library alleviated a bit of that pain but it was lacking in many areas. Boost makes up for that lack in a multitude of areas. In particular, there was a groovy library called Asio (Asynchronous I/O) which could be used for robust client / server code and I used this at work.

Another thing I noticed was that many of the familiar faces in the industry were still around. Herb Sutter, one of my favourite authors, had become some kind of C++ God and had released lots more cool looking books such as C++ Coding Standards. The book Effective C++ by Scott Meyers had recently had a 3rd edition published. I devoured these new books quickly.

Lastly, the community seemed to be just as strong as before. The ACCU conference was now in its 9th or 10th year and I was fortunate enough to get hold of 5 years worth of conference slides and looking through those showed me just how C++ had grown over the years.

So at this point I felt like I was beginning my C++ journey all over again except that now I had some new tools to play with such as unit testing, agile techniques, new Boost libraries and so on. I was really enjoying my projects at work but I felt like I needed a really substantial 'pet project' at home to try out all the new techniques that I was learning about. Generally speaking, testing out cutting edge stuff in the workplace doesn't usually go down too well with the boss!

This is when the idea for Mod Wars was born. It was going to be another online game, but without the features that caused me such a headache in Morde - namely, complicated graphics issues. I'm not an artist, neither am I a graphics programmer so this game would be a simple 2D affair with simplistic, mostly static, graphics only.

I also started to get ideas for some web development that I wanted to do and my spare time at home was becoming limited so I put Mod Wars on hold and decided to work on web development exclusively for a while. However, a few months ago at work I was moved off of my C++ work and onto the C# team. This means that I am no longer doing C++ development at all and I'm now missing it badly!

I know it's an old language. I know there are a squillion new technologies now that are probably a lot easier to use but I feel like I need my 'closure' over C++. I'm having some fun with C# at work but I know that I can't rest until I've developed a substantial C++ software project.

Mod Wars was always going to be that project but then I had an idea which threw a major spanner into the works. In the small amount of development I did for it, I had some compatibility issues. My output was displaying fine under Windows but it was all screwed up on a Linux machine. I never did find a solution to that, and that bug is still outstanding. With all this study around Web development I got the idea that I could make Mod Wars a web-based game!

This would allow anyone to play the game, regardless of whether they had a PC, Linux box, Mac, whatever. There would be no download / installation / patching issues to worry about. I'd only need to develop one code base. In short it would make the game far more accessible for the players and would remove many of the technical headaches for me.

But that leaves one tiny problem... How does C++ fit into the plan for a browser based game? This has been a source of major conflict for me ever since I thought of it. On the one hand, making Mod Wars browser based would be an excellent idea, but on the other hand, I still need my C++ fix!

I think I may have a solution to this conflict now, but I need to do some more investigation before I can reach a conclusion about that.

Thursday, 14 June 2007

My Web Development Roadmap

Having completed my Head First HTML book a couple of weeks ago, I started having a play around with some HTML and building a little test site. At the same time I began to sketch out some ideas for the kind of websites that I would ultimately like to build. I have several ideas and most of them have several features in common:

  • They'll be database driven in some way
  • Most will require a secure login system
  • I'll want a nice Ajax front end
I already have a book on Ajax and its after starting that book that I realised I would need to take a step back and brush up on my HTML and learn a little Javascript too. So my initial plan was to study HTML, then Javascript and then move onto Ajax.

However, after pondering my above list I realised that all of my sites needed to be dynamic. They would all need to be database driven but I could cope without Ajax to start with. So this has changed things a bit. As much as I've like to play with the cool features of Ajax, I am more concerned with getting something functional up and running quickly so I had to find out a little about database driven websites.

After a little digging there seemed to be two popular paths that stood out - the Php / MySql one, and the ASP.NET / Sql Server one. They seemed to be biased towards *nix / Windows respectively though in the case of Php / MySql they can also be run on Windows servers. I don't know any of those technologies though I am a C# developer by day so I'm pretty sure that ASP.NET is going to be easier for me to pick up than Php. For that reason alone I went for that route.

I've now bought the Wrox book Beginning ASP.NET 2.0 with C# and I'm working my way through it. I'm feeling a little frustrated at the moment as I realise that I can't really do much yet - it's all just study. Hopefully I'll get to a point where it will all start to click and I can really get moving on something.

Sunday, 3 June 2007

Those Cocky Developers!

What is it about software developers eh? They think that just because they write software for a living (or in my case, fix bugs!) that they know everything there is to know about computers. Do you think they read manuals? Nope. Do they use the CD's that come shipped with their computers? Nope. They just try to fix things by themselves - 'cos that's what they're supposed to be good at.

Thursday night I switched on my PC and within a minute or so of booting it just froze. Odd I thought. So I rebooted and it did the same thing again. It continued to do this and I didn't find a solution to it. Most of Thursday night and all of yesterday afternoon and evening was spent trying to fix it. I went to the Major Geeks forums and followed the instructions in there for removing malware. I did find some extra stuff but it didn't fix the problem. I double checked all my hardware, I fiddled with my router a lot. Nothing worked.

After some hours I reluctantly phoned my broadband provider for help. After walking me through his little checklist of mindlessly pointless things that I had already tried he asked his supervisor for help who told him to tell me that only one PC would be supported and they could therefore offer me no more help as another two computers on our network were working fine.

So, time for a reinstall. I spent ages copying some crap that always gets installed to your C drive (like save games for Oblivion & GTA - how irritating), and I carefully made a list of all the stuff I'd need to reinstall. I reinstalled Windows - still didn't work. This flummoxed me because usually XP is pretty good at just figuring out our network all by itself without me having to fiddle with it too much.

After many many hours of frustration I decided to have a little dig into my Alienware pack that had come with the PC. I realised that I'd installed an old version of XP so I reinstalled all over again using the Alienware version. This was better because at least it came with SP2. But the network was still buggered. Then I found another CD called "Master CD". I wonder what that is I thought to myself.

I plopped it in the drive, found a folder called Drivers and in that, a folder called Network. Hmmm. There was a readme in there that said that the network drivers were installed with the NForce drivers. These NForce drivers were found under Motherboard so I tried installing that. It installed an Ethernet controller and suddenly new hardware was found and installed, I had a LAN and an IP Address. I loaded up a browser and bingo - it all worked!

Now if only I had tried that first...

Moral of the story : check the stuff the manufacturer sends you!

Friday, 1 June 2007

I'm such a w00b!

A what?? A w00b! Ok so I play a lot of computer games and a 'newbie', somebody who is new to the game is often referred to in a derogatory fashion as a n00b in 'dude speak'. I happen to quite like calling people n00bs in the nicest possible way you understand! :)

And what does this have to do with software? Yesterday I finished my introductory book on HTML & CSS so my new mission is to just get started building a website. I flicked through the book and pulled out the main teaching points and built a list of 29 things to do with the site to exercise all of my new skills. Step 1 was to simply create a page with a header, title, headings, paragraphs and an image. Pretty basic stuff and of course there is no styling yet so it looks horrid.

I'm working through my list of 29 things and I'm up to number 4 - making lists whoooo! I thought to myself "I feel like a complete web n00b" and that just led me naturally to the word w00b! So, just in case nobody has thought of it before, YOU READ IT HERE FIRST!

I'm a w00b yay!

Oh dear, back to the HTML...

Thursday, 31 May 2007

[Book Review] Head First HTML with CSS & XHTML

I first stumbled across the Head First series of books last year when somebody showed me Head First Design Patterns. In case you have not heard of these particular books let me enlighten you... They take serious topics in software and teach them to you in a wacky, humorous, graphic-heavy style. Imagine a dry university text - Head First books are just the opposite. Lots of pictures, characters, a storyline, plots even! Lots of exercises and fun stuff to do.

My first reaction was to balk. "Pah, this can't be a serious book" and I associated them with the "teach yourself the latest complex technology in 10 seconds" type of book but I was wrong. These books are very good and they teach you best practices.

So, I decided I wanted to do some web development, and Ajax seemed really funky, and after a quick search on Amazon I saw that Head First did an Ajax book so I bought it. To my dismay I found myself lost in chapter 1! In my three years of developing web sites for a living I never really learnt anything other than how to use Front Page and how to do funky web layouts with graphics. So, I figured that I should do things properly and learn HTML. I felt a bit silly buying a book on HTML but sometimes you just have to stop winging it and do things properly.

I logged all the time I spent on the book and it took me 16 hours to work through it completely. I did all the exercises and I typed in most of the examples. These books are a nice quick read. Don't be put off by the size because they are filled with graphics and you can zip through them real quick.

I really enjoyed the book and I felt like I learned a lot. I managed all the exercises with ease and I was really happy with myself right up until I got to the end of the book and then I realised that I didn't quite know where to start at actually building my own site using my new skills. These books take you by the hand step by step and they are designed for absolute beginners but the downside to that approach is that they lack meatier exercises for more advanced readers. I had typed in a few lines of HTML & CSS here and there but I had not built anything from scratch.

I suppose you could say just about the same for any other tutorial-style book of this kind. You learn what you can from the book but ideally you'd follow along and build your own sample site along side it. That's what I didn't do so my next step will be to do a chapter breakdown of the book summarising the key points learned in each, and then build a simple website that utilities everything I have learned. Once I have done that I should be ready to move on.

CONCLUSION

If you're really new to HTML & CSS then Head First HTML is a must buy but be prepared to do some extra practice along side it. If you're looking for a quick refresher or a reference book, look elsewhere.

Saturday, 26 May 2007

My Software History

I got my first computer (a Commodore 64) in 1983 when I was 11 and from that moment on I was hooked. The games I loved the most were text adventures, and my first taste in programming came around a year or two later when I bought a book that taught me how to write text adventures in basic. I wrote my first game that I was mightily proud of only to have the tape chew up some months later. Tragic, really :)

Around 1986 I progressed to 16 bit, but rather than move to the Commodore Amiga which would have been the logical step, instead I went for the rival, the Atari ST. There was only one reason for this - there was a piece of software, the Graphical Adventure Creator only available for the ST. I bought it and then hardly ever used it. Graphics were not my thing it would seem.

I didn't do much more programming after that for many years as I developed a mail order company and concentrated on that. The business closed in 1995 and I became employed in the IT department of Telewest Communications. Here I started to tinker with programming again. We worked with DEC Vax machines and I bought a book on DCL, the DEC Command Language and wrote little programs to automate just about everything we did manually. I coded myself out of a job heh - there was nothing to do after that and I moved on to a company called Bytel who provided the software that Telewest used to run its services.

I had to relocate for my job in Bytel and for the first few months I simply rented a room while I looked for a house. I was bored and lonely so I thought that would be a good time to teach myself programming properly. I had dabbled with Visual Basic in the past and thought I'd learn that (try not to laugh too hard!) So I popped down to PC World as one does (!), and they didn't have VB, but they did have something called Visual C++. I had no clue what that was but I was in one of those moods where I just had to spend money, oh and I had to buy a book too. I bought "Programming Windows 95 with MFC".

Well I plodded through that book and I wrote my first proper game, a puzzler called ColourBox. People at work knew I was learning C++ and this caught the attention of the development manager. At the time I was working as a systems administrator for the Vax machines. He asked me if I'd like to switch into his department as a programmer and of course I jumped at it. I was in! :) The job was pretty crap really. The system was very old and we used three languages - COBOL (oh dear), C and 4GL, a front end for a database system called Ingres.

A little while later Bytel lost Telewest as a customer and things went really down hill from that point. However I now had enough experience to get a job as a developer which I did. I joined News Digital Systems as a Junior Developer and I was using C++ now which is what I wanted. Unfortunately I lost my job 18 months later but rather than get another one I had the bright idea of starting out on my own.

At the time this was a mistake because I had absolutely no idea of what software I could write. Over the next couple of months I found myself doing some website stuff and I somehow just continued with that. Three years later I was running websites, bored to tears and really missing development. I tried to get a job but what little commercial experience I had was now out of date. I had no recent experience, no degree and no recent references.

So I went to University as a mature student and did Computer Science. I figured I could brush up on my skills properly, get in well with the lectures and get myself a good job afterwards. The plan worked flawlessly and three days after graduation I started the job I work at currently - I'm now a software enginner for Aston Broadcast Systems developing character generation software.

I love writing software but there's more to it than that. My real deep down passion is games. When I was first accepted to Uni I had to wait almost a year to start. In that time I decided that I wanted to be a games developer so I put all my attention into that. I studied maths books, I wrote a couple of trivial games, all my third year courses were geared towards games and my third year project was an RPG game creator. However, about six months before graduating I started to learn more about the realities of the games industry. I would have to work very long hours on low pay and I just didn't want to do that much work at my age, especially with my family commitments.

So I figured that games could be my hobby projects and I'd get a regular 9-5. That's worked out pretty well so far except that I've not actually developed anything yet! When I first started my job I wolfed down C++ books as that was what I was using then (I'm now on a C# team) but being back in the software industry full time fired up my enthusiasm for everything and I started reading books on C#, quality coding practices, design & patterns, and web development as well as loads of stuff on games development. I got to a point where I was spending so much time reading books that I wasn't actually writing any code.

So where am I now? I've been in my job a little over 10 months and I have an idea for an ambitious MMORPG that I want to write. One other regret that I have is that in the three years that I spent building websites I never learned any real web development techniques - I just used builders such as Front Page. What I'd like to do is learn some proper techniques such as XHTML, Javascript, Ajax, Php etc and build some proper sites that might actually be able to generate a side income for me.

My MMO project is big and although I started on it I didn't get very far when I was spreading myself amongst so many other things. So now I've cut right down on my books, I've put my MMO on hold, and I'm concentrating on a single area, web development until such time as I can actually build something then I'll build my first real site, though I'm not sure what it will be yet.

It's a really hard thing for me to cut back in that way because there are so many things I like to read - books, magazines, blogs, web articles, conference papers etc, the list is endless. I even got all worked up about the idea of learning 68000 assembly just for fun so I could write some retro games for my Commodore 64! There just aren't enough hours in the day! *sigh*. Hopefully though there will be many years in my lifetime for me to learn all I want to learn and write all I want to write.