Windows Media Player is broken

Now normally I wouldn't touch Windows Media Player with a barge pole, even when I do use Windows at work or for gaming I use VLC. This is mainly because Windows Media Player seems to be plagued by problems with codecs which I never have with VLC (and anyone who tells me to just download a massive codec pack clearly doesn't get the point) but also because it's a big clunky program made of fail. Today I found out (via a colleague, I wasn't using it myself) that Windows Media Player doesn't toggle between play and pause when you press the spacebar if it's fullscreened. This seems trivial until you think about it. Absolutely every other video or media player worth using recognises that the spacebar is the play/pause toggle button. Even YouTube recognises this. You can rely on it.

Need to stop the movie because the popcorn is ready? No problem, hit the space bar. Even if this computer you are playing the video on is a Mac and you've never touched an Apple product in your life you can pretty much guarantee it'll work. Linux command line movie players such as MPlayer know this shortcut, VLC knows this shortcut. It's universal. Windows Media Player clearly just sucks. No real surprise there.

Comments [0]

Running a Left 4 Dead dedicated server on Ubuntu Karmic 64 bit

This is half notes for myself and half helpful information for anyone else who wants a dedicated server on a decent OS. I assume you can use said decent OS and thus don't need me to hold your hand and guide you around the CLI.

Based off http://www.left4deadforums.com/1187-left-4-dead-linux-server-guide.html

1. Make a directory to put it all in.

mkdir hlds && chdir hlds

2. Download the file from valve to start it all off.

wget http://storefront.steampowered.com/download/updatetool.bin

3. Install the necessary 32bit libraries because Valve are still in the dark ages.

sudo apt-get install lib32gcc1

4. Run the file you downloaded.

chmod +x hldsupdatetool.bin && ./hldsupdatetool.bin

5. Accept the license agreement. Yes it scrolled past too fast to read. No you wern't going to read it anyway. Just accept it.

yes

6. Run the new steam executable with the right stuff to install the l4d server. The '-dir .' bit makes it put a l4d folder in the current dir. This is probably what you want.

chmod +x steam && ./steam -command update -game l4d_full -dir .

7. Wait for it to download then the configs will be in l4d/left4dead/cfg/server.cfg

vim l4d/left4dead/cfg/server.cfg

8. Make a config file. Something like the following should do fine.

hostname "My Server's Name"


rconn_password "password"


sv_other_settings "corresponding values"

9. Run the server up.

l4d/srcds_run l4d -autoupdate +ip <your servers ip address here> +hostpost 27203 +exec server.cfg +map l4d_farm01_hilltop &

10. Enjoy. You can control the server through the console in game by using "rcon_password <whatever password you put in the config file>".

Filed under  //

Comments [0]

Notifications when you couldn't care less

I have been using Ubuntu Jaunty for the last few months and it has a nice new notification server which works pretty well. It looks much nicer than the previous speech bubbles and the notifications are no longer tied to the icon in the tray for the program that generated them (this is important as it looks stupid if you don't have a tray which I often don't). There are no longer any buttons on the notifications and they fade out letting you interact with whatever they cover up (appearing in the top right it is often the window manager buttons) so you no longer have to dismiss notifications you don't care about before you can click underneath them.

This is all very nice and most certainly an improvement over the previous notification server but there are still notifications that I receive that I couldn't care less about so I started thinking about how the new notification system (and notifications in general) could be improved.

Firstly there are times when notifications are useful, and times when they are just distracting. Ideally notifications would be 100% useful and never distracting but this tends to be hard to achieve. Some notifications are more important than others. While giving a presentation it would certainly be useful to know the computer is going to turn off in 5 minutes because I was a goit and didn't plug in the power cable. During the same presentation I almost certainly don't want to know when my Pidgin contacts are signing in and out. This gives us at least 2 types of notification, important and normal, and two states for the notification server to be in, important-only and normal (which shows all notifications). This is pretty much how the new notification system works at the moment.

There are some notifications that exist to prompt an action. If I receive an email then it is somewhat expected that I might go and read it, possibly even respond to it. If I'm browsing the internet and an email comes in I personally probably will check the new email out. If I'm working on a report or writing code I probably won't. I'm busy doing something and the email can wait until I'm done. This gives a concept of context. If I'm coding or writing reports then don't tell me about any emails that arrive until I'm done or until I take a break. The same goes for the presentation example. If I'm giving a presentation then don't tell me about notifications in set X, but do tell me about notifications in set Y. When I finish the presentation I might close the pdf and drop back to the desktop but I probably don't want to be told about notices I missed as I won't notice, being too busy answering questions and doing all the kind of stuff you do after a presentation. The notification server needs to pick a good time to tell me. Probably when I first use the computer again at least one minute after I close the presentation.

How can the computer know all this without me spending hours telling it? If notifications expect at least some response, some of the time, the server can notice when it consistently gets no response. If it has delayed notices and when it shows them it gets no response then it should wait a minute, then wait for someone to use the computer (indicating their presence) and remind them again. If they react then in future it waits that length of time, checks for presence and then notifies the user. The time it waits should increase each time, first one minute, then two, then five, then ten, then twenty. If the user has ignored all of these then it should just accept the user doesn't care about this batch, reset the timer and do the process again next time.

This just requires notices to include information about whether they might prompt an action, if they do then we can expect the program that supplied the notification to be used in the next minute after the notification appears. If it is consistently not used in a particular context then these notices should not be shown during this context and delayed as explained above. If notices are ignored in all contexts then they should possibly only be shown when the computer idles for more than two minutes and is then used (indicating the user has returned from a break and won't mind the interruption as much as they might if it interrupted them while working).

This would remove the requirement to simply label notices as important as anything important is just something that is never ignored in any context. It gives a finer grained control over the notices and should reduce the number of useless notices that appear at the wrong time.

Comments [1]

Rescuing contact details from accounts you can't export them from.

My Mum's work recently switched email systems at work and helpfully didn't move any of her contacts across to the new system. She tried to get me to do it for her manually but boredom and drudgery are evil so that was out. Instead I hunted around for any kind of export function that might let me get access to the contacts but, due to the poor system her work decided to use, there was no way to get any contacts out. In the end I resorted to composing an email to every contact, moving the addresses from the 'To' box to the message body and sending the email to myself with the idea that I could work with the list later.

Earlier today I decided to try and convert the list into vCard format. It would only be the most basic of information but it would be enough for Mum to send emails again which would keep her happy. The list was in the format:

Firstname Lastname <email@example.com>, Firstname2 and Firstname3 Lastname2
<email2@example.org>, ...

In short, it was a set of comma separated values with line breaks spread throughout and angle brackets around email addresses. Some entries had interesting names to work with ('Dad at work' for example) and others didn't have a name so just had the email address put in as the name (example@example.com <example@example.com>).

I knocked up a simple solution in Python using the vObject package for the vCard stuff. It kept me entertained for the afternoon and I have attached the resulting script for anyone who wants to use it for anything. (Disclaimer: It might wreck everything and/or anything. Don't come crying to me when it does, it isn't my fault. IANAL.) The code is fairly unreadable in parts, that is semi-deliberate (I decided to optimise the main function to get it down to the smallest number of statements, no doubt it can be done in fewer but I think I did pretty well at it).

Since I used a fair bit of functional programming stuff in it I am quite tempted to rewrite it in Scheme at some point but that will have to wait a while as I have university exams coming up shortly and have wasted too much time already.

Comments [0]

The Web as an Interface

The web is wonderful and software as a service (SAAS) makes it even more useful, giving us the ability to access our documents, images and videos using sites like Google docs, flickr and youtube wherever we go without needing to bring it all with us. This ability to access content wherever we are provided we have an internet connection is one of the biggest selling points of SAAS but there are other things to consider before throwing desktop apps out the window for good, not the least of which is desktop cohesion.

When using a given desktop environment you expect the programs you use to be consistent in their UI and to work together. For example, when using the Gnome desktop environment as I am now it is expected that I can select an image in F-Spot (the Gnome photo management program) and choose to send it to one of my contacts in Evolution (the Gnome email client). This is pretty standard behaviour.

On the other hand when using web applications I have no way of selecting a photo on my flickr account and sending it via email to one of my google contacts. At the very best I have to download the picture, leave flickr, open gmail, compose the email and attach the picture. This seems far too much effort in comparison to the ease at which such a task is accomplished using the equivalent desktop applications.

A second issue is the lack of a common visual interface between web applications. Taking each individual web application separately there is (normally) a clear reasoning behind the design. However when looking at the web applications as a whole the user interfaces vary greatly and although they are all usable individually when switching between sites often (to email pictures to friends for example) the interfaces can become confusing as the user is having to context switch far to often.

SAAS is a very useful concept but unless all the software comes from a single company or a group that have agreed on standards to work with it will continue to fail at what should be very simple tasks that users are used to expecting from the desktop applications they are used to using. The core problem lies in the lack of a common standard for an interface, either visually or programatically, to be used by all web apps but the very idea of imposing a standard opposes core concepts of the web as a creative medium.

There are two obvious solutions to this problem. The first is dull, uninnovative and useless as a realistic solution and is to merely revert to desktop applications. This immediatly solves the problem but loses all the benefits of switching to SAAS in the first place. This ’solution’ is obviously not viable for anyone who desires the benefits of SAAS.

The second solution is to somehow create a common interface between the web applications. Whether this is by seperating the service from the interface and developing a variety of interfaces to fit with the users expectations or by creating a single common interface for the web apps is something that remains to be seen but until web applications improve the interoperability between apps the SAAS platform will be left lacking a very basic and vital feature of the desktop based competition.

Comments [2]