Merely Hornsea

P1030910.jpg

Now, isn’t this a turn-up for the books? After yesterdays “grey-fest” today has dawned all bright and sunny. Of course, we’ve got to stay at home waiting for a package to be delivered, but once that arrived we headed out to Hornsea Mere, one of my favourite places in all the world. It has a place you can buy cups of tea, and a very old Pike stuck on the wall.

P1030933.jpg

It also has a pitch and putt golf course where I once got a hole in one. Unfortunately it was the wrong hole though. The massive slice I played at hole number 1 somehow ended up in hole number 9. And there are ducks and geese and boats and stuff.

P1030978.jpg

“You lookin’ at my bird?”

Cafe.jpg

Cafe view

If you are lucky enough to be a student at Hull and you are at a loose end later this term, take a trip to the Mere. Just a great place.

Software Updates at the Humber Bridge

01monitor

All my own work

One thing which I’m very proud of is that I helped to write the software that manages the toll data from the Humber Bridge. Ian and I wrote the “Instation and Control Room Mimic” system which tracks the traffic over the bridge, makes sure that vehicles are registered correctly by the toll booth operators and totalises all the takings. We wrote the programs around 12 years ago which means that if my code was a child it would now be starting secondary school. Scary stuff. (and probably due for an update)

Some time ago the wonderful Verity Stob introduced me to Meir M "Manny" Lehman's Software Uncertainty Principle. Put simply, it states that at some point in the lifetime of a project certain assumptions that were baked into the solution when it was first built become wrong. Today that happened to me. One of the assumptions that I’d made in the design was that it would never be free to cross the bridge. The program was built to validate the price entry and reject any values which were less than or equal to zero. And then at the weekend the Humber Bridge Tolls were revised downwards (a very nice thing to happen) and it became free for a motorbike to cross the bridge. Thing is, my software didn’t allow for this. And so, for the last day or so the price of a motorbike crossing the bridge has been recorded as a single penny (although of course the money wasn’t collected)

Today I drove round to the Bridge Control Room and did a code update of the bridge software, effectively changing a >0 to a >=0 and now the prices can be set correctly.

Rob at Campfire

image

I’ve just got back from Bulgaria and already I’m preparing for the next trip away. The week after next I’ll be heading for Singapore to give some sessions (and be part of the keynote) at Microsoft Campfire. I’ve had a look at the agenda and it looks really interesting. I’ll be doing some Windows Phone and some Kinect stuff (let’s see if we can lay ‘The Curse of the Kinect’ to rest once and for all) and there’s some Imagine Cup action too. Should be great fun.

If you are in the area you can sign up here.

The Curse of Kinect

DSCF6824

A very patient audience, thanks for putting up with me.

Just completed my Kinect session. Having done lots of tests I then got lots of problems during the demos. But everything worked in the end. For those who were there and wondering what the problem was, I think I’ve found the solution. Sometimes the sensor doesn’t wake up before my update thread tries to use it. Which doesn’t end well. I’ll be putting up a nice long blog post (and some useful code) to address this later.

After I’ve had a lie down..

MS Days in Sofia

DSCF6727

Got up bright(ish) and early this morning to head for Sofia. Nothing like a 6:10 am flight. But the journey was smooth enough and this time there was no rain when I arrived, which was nice.

DSCF6775

This is the rather funky buildings you can see from my hotel room. Although now you’ve seen the photograph there is probably less need to do so.

In the evening we went out to the Timeless Cafe for tea. Nice place. There was a clock there but it had stopped – which seems fair enough. We had a great evening of good food, drink and Geek Speak.

DSCF6783

The universal language of beer…

Then it was back to the hotel. Sessions tomorrow, looking forward to them. Hope the audience is too…

Best Programming Language?

IMG_7331-Edit.jpg

There’s a program in the App Store called “Best Camera”. It takes as its starting point the idea that “The Best Camera you’ve got is the one that you have with you at the time”. The application then goes on to provide all kinds of useful tools that make the iPhone camera as good as possible.

I was reminded of this when there was a tiny bit of debate on my post about the CodeAcademy site, which teaches JavaScript. Now, JavaScript is not a great language, but it works and can be used to create useful stuff. So it is automatically a candidate for “Best Language”. In my opinion, the Best Language is the one that you are using at the moment. I base this on “Robs Rules for Programming Languages”:

  1. You can write great code in any language.
  2. You can write horrible code in any language.
  3. The user does not care what language you used to write the program they are using. The user only cares that it works and does what they want. And that they can afford it.

I’ve written programs in loads of languages. At the moment my personal favourite language is C#, but I have really fond memories of writing embedded C, since in that I could do anything I wanted and I could build all the underlying bits myself from scratch.

This is usually the point that people say things like “But blah doesn’t have blah.” or “Blah programs are really hard to use because the debugging support sucks.” So what. This brings me to the Rob’s Other Rule

  1. Having a nice place to work is much more important than the programming language you are using.

If the language you are using doesn’t have a feature that you need, find a way of programming around it. I’ve written lots of object oriented software in C. C doesn’t support objects, but I arranged the code so that it looked like it did and then programmed by “object rules”.

If the development/debugging support is horrible, wrap something around your program to make it easy to work with. I’ve built emulations of LCD panels and even lasers to avoid having to debug my programs on the real hardware. I’ve written code to make ten thousand customers from nothing, to save me having to type things in by hand. And I’ve added cheat buttons to games so that I can skip levels and inflate my scores and avoid having to play the game all the way through so that I can debug the last bits. 

Remember, when you are writing a program you don’t just control what the code does, you also control the environment the code sits in. Bending this to make things easier is something that will pay off tenfold. Can’t debug your program without a network connection? So what. Fake the web request responses so that you can feed the answers back yourself. This also makes test driven development much easier.

Of course, given the choice, you should pick the most appropriate language for the task. Give me an AI problem and I’ll be looking hard at what Prolog (or perhaps F#) can do for me. But for me programming is not about the language, it is about the problem solving, and that means a programmer should be able to turn their hand to whatever the occasion demands. Even if it is JavaScript.

Imaginationgamers

image

I love it when people do stuff. Anthony, a student at Hull, is doing stuff. He has started up a web site for gamers who want to talk about, play and even build games. The whole thing is very slick and there are lots of forums and places where folks can pitch ideas and find like minded souls to go on and build something. I wish him the best of luck. If you want to take part then you can find the whole thing at http://www.imaginationgamers.com/gb/

Codeacademy for learning JavaScript

DSCF6379.jpg

During a First Year lecture this week I said that the students should spend some time this Easter learning JavaScript. Everyone should know a bit of JavaScript, it is what makes web sites work, and with the coming of HTML 5 it will be even more important. I’ve just found a really good way to learn it too. (this also works for anyone who fancies doing a bit of programming). Take a look at Codeacademy.

http://www.codecademy.com

Looks like great fun.

Tony Hawk: Shredded

image

One of the reasons why some videogame companies are in trouble at the moment is their love of gadgets. Since the original Guitar Hero made a fortune by throwing in a plastic guitar there have been a whole bunch of exotic peripherals thrown at gamers. I reckon they peaked with the Rock Band drum kit, and it has been downhill all the way since. Tony Hawk Shred is perhaps the last big piece of plastic that you will get with a game for a while. It was originally priced at more than 80 pounds, but you can now pick it up, post free, on eBay for around fifteen quid, at which point it starts to look good value. That’s how I ended up with a copy.

The board itself is really sturdy and bristles with sensors that make it able to detect ollies and the like, as well as when you grab the board during a stunt. It even comes with Velcro strips you can use to stop it wearing a hole in your designer wood floor. If you get the Xbox version you should be able to use the sensor signals in your XNA programs, although I suspect the market for skateboard compatible games is probably a bit limited.

The game itself is nothing more than OK though. Rather than give you an environment to explore as you like, instead you are run through some sequences on rails and have to perform tricks and stunts at pre-defined points. This makes the game very restrictive, although the sequences are nice enough to look at. Tony Hawk himself pops up to make comments on your efforts, although they should have added a mini-game where you could work him over with the board after he has said the same inane thing for around the tenth time.

However, if you fancy a night in with some friends doing something stupid (and ideally you live at ground level and have a concrete floor) for fifteen quid you could do a lot worse.

Joe’s team wins TTG Prize

P1030526

Getting it going on

For this competition we introduced a new feature, the Three Thing Game “competitor’s prize”. This was voted for by teams who went round the entrants and checked out each other’s work. After going through the marksheets and totalling up the numbers I found that “The Infamous Two Sirs” had got the most points. However, they were happy that as winners of the main competition it was OK to let the second placed team, “Joe you’ve got it going on” have the prize. Thanks for that guys.

“Joe’s team” made good use of the Kinect sensor to produce a very interactive tower defence take on the words Fruitcake, Tower (I think – they got a wildcard) and Word processor. Well done guys, your signed Wipeout artwork awaits.