Chris McCormick - News - tech http://www.mccormick.cx/news/tags/tech Chris McCormick - News - tech en Copyright 2008- Chris McCormick 60 GMT chris@mccormick.cx www.mccormick.cx/news/ Global Game Jam 2012 - postmortem entries/global-game-jam-2012-postmortem http://www.mccormick.cx/news/entries/global-game-jam-2012-postmortem Here is what I ended up with at the end of GGJ 2012. I've cleaned it up a bit, got it working under Internet Explorer (mostly) and put it online here.

Screen shot of commit 31

I ended up with more of a virtual world or virtual ecosystem than a video game. I ran out of time to put probably the most important thing into the game - game mechanics. Also no time for sound, the player has very little agency in the world, and there are no win or lose conditions.

Overall it was a lot of fun to build though, and I got some pretty neat new technology for jsGameSoup out of it, namely the isometric camera library, and a lightweight vector math library.

GGJ was also really fun just because of the social aspect of being crammed into a room with like minded people for 48 hours. Can't wait for next year!

]]>
/tags/tech Wed, 01 Feb 2012 14:17 GMT
Global Game Jam 2012 - day 2 entries/global-game-jam-2012-day-2 http://www.mccormick.cx/news/entries/global-game-jam-2012-day-2 End of Saturday night, day two:

The Cycle - day two

Got some sleep. Lots of on the TODO list for today. About 7 hours left. :)

]]>
/tags/tech Sun, 29 Jan 2012 02:21 GMT
Global Game Jam 2012 - day 1 entries/global-game-jam-2012-day-1 http://www.mccormick.cx/news/entries/global-game-jam-2012-day-1 The theme is "Ouroboros". Progress as at midnight day 1:

The Cycle - title screen

The Cycle - current gameplay

I have a reasonably concrete idea of where I am going. Hopefully there will be time to iterate on my idea and "find the fun".

]]>
/tags/tech Sat, 28 Jan 2012 03:26 GMT
Coherent Noise in jsGameSoup entries/coherent-noise-in-jsgamesoup http://www.mccormick.cx/news/entries/coherent-noise-in-jsgamesoup Recently I added Sean McCullough's Javascript implementation of the Perlin noise algorithms to jsGameSoup. These Academy Award winning algorithms by Ken Perlin are fantastic for adding procedural content to your games.

Simple noise generated RPG map

The RPG map above with grass, water, road, sand, and tree tiles represented in the different colours, was produced with the simplex noise demo here. It can randomly generate a basically infinite number of unique RPG maps of basically infinite size. Check the jsGameSoup documentation for more details.

]]>
/tags/tech Tue, 24 Jan 2012 13:50 GMT
Will Phobos Grunt Hit My Head? entries/will-phobos-grunt-hit-my-head- http://www.mccormick.cx/news/entries/will-phobos-grunt-hit-my-head- Worried an out-of-control Russian satellite may land upon your head?

]]>
/tags/tech Sun, 15 Jan 2012 15:27 GMT
A* Path Finding for jsGameSoup entries/astar-path-finding-for-jsgamesoup http://www.mccormick.cx/news/entries/astar-path-finding-for-jsgamesoup A* Path finding algorithm demo in jsGameSoup

I have included a modified version of Benjamin Hardin's 2009 A* implementation in jsGameSoup. This is a nice general way for entities in your game to find a path between two squares on a two dimensional board with some obstructed squares. Check the demo here and the documentation here.

Have fun!

]]>
/tags/tech Sat, 14 Jan 2012 10:25 GMT
D-Link DNS-320 ShareCenter NAS review entries/dlink-dns-320-sharecenter-nas-review http://www.mccormick.cx/news/entries/dlink-dns-320-sharecenter-nas-review This thing is great. I got it from VTech Industries for about $220 AUD. It is basically a mini GNU/Linux server with 2 giant hard drives in it. That price gets you a single 1TB drive and you can install your own drive in the other bay by removing the lid and dropping it in place. The unit, pictured below, is a bit taller and wider than three PC hard drives stacked together.

DNS-320

It comes with a reasonable web interface you can access over your LAN, but I installed the fun_plug hack on it by copying the files across the network and restarting the device - easy. That hack gets you SSH access, rsync, and a bunch of other Linuxy stuff.

We are storing our media and backups on it and it is basically perfect for that use-case. I now once again have a cron-and-rsync based regular backup of all of my servers in the USA, hooray! I'm also routing all SSH traffic to our ADSL router through to it so I can access the files on the device from outside our network if neccessary.

All in all I am very pleased with this purchase.

]]>
/tags/tech Tue, 03 Jan 2012 01:58 GMT
Local PHP Dev Server with Mongoose entries/local-php-dev-server-with-mongoose http://www.mccormick.cx/news/entries/local-php-dev-server-with-mongoose Sometimes you want to test a bit of PHP code on your local machine without installing a full LAMP stack. Mongoose is a web server that will let you do that.

Under Ubuntu I first downloaded and installed the mongoose source code, then I installed the package php-cgi and here is the script called phpserve that I use to launch Mongoose in the top level directory of my PHP project:

#!/bin/bash
mongoose -e error.log -r `pwd` -i index.php -p 8000 -C .php -I /usr/bin/php-cgi

After that you can browse to http://localhost:8000/ and you should see your site.

Enjoy!

]]>
/tags/tech Sat, 17 Dec 2011 09:01 GMT
Your Handwriting as a Web Font entries/your-handwriting-as-a-web-font http://www.mccormick.cx/news/entries/your-handwriting-as-a-web-font If you visit my website you will notice everything is in a scrawly hand-written font now. This is a digitized version of my own handwriting. Here is how I produced it:

  • Went to YourFonts and printed the templates twice.
  • Scanned both copies, used the best version of each letter, and tweaked some stuff in an image editor.
  • Uploaded the templates, paid $15, and downloaded the resulting TTF file.
  • Tested it out on my blog (see the cross-browser CSS font-face declaration below).
  • Loaded up the TTF in font forge and tweaked more stuff.

To get it as a web useable font:

  • Use a program called ttf2eot to create a web font file that Internet Explorer likes.
  • Use the following CSS font-face declaration, which works on pretty much all mainstream browsers including Internet Explorer 6.

Font-face declaration:

@font-face {
    font-family: 'MyFont'; /* Use the real name of your actual font */
    src: url('MyFont.eot');
    src: url('MyFont.eot?#iefix') format('embedded-opentype'),
    url('MyFont.ttf') format('truetype');
}

You can do this with basically any TTF font, but watch out for the legal implications of using commercial fonts on the web. It's obviously fine to do it with a font of your own handwriting. There are probably lots of other free fonts you can do it with too, but read the licensing information first.

Here's to more flexible web typography!

]]>
/tags/tech Fri, 02 Dec 2011 00:10 GMT
Piwik Web Analytics Is Great entries/piwik-analytics-software http://www.mccormick.cx/news/entries/piwik-analytics-software Looking for a good open source Software Libre alternative to Google Analytics? I can't recommend Piwik highly enough.

Piwik graph example

  • Setup was easy - PHP & MySQL with a simple web based installer.
  • Basic mechanism is similar to G.A. - add a code snippet to the bottom of your HTML code and you are done.
  • Reporting seems more comprehensive than G.A. - all kinds of interesting data, visitor trails, etc.
  • Take back ownership of your stats data!

Have fun.

]]>
/tags/tech Thu, 01 Dec 2011 04:57 GMT
I Am Back entries/i-am-back http://www.mccormick.cx/news/entries/i-am-back Calm down, Internet, I am back! My server had a small mishap.

My new hosting provider is much more reliable than my old one. Hooray!

My new one is called prgmr.com and they are great.

I have also taken the opportunity to redesign my website. I hope you like it.

]]>
/tags/tech Sat, 26 Nov 2011 13:38 GMT
Google Reader is Dead entries/google-reader-is-dead http://www.mccormick.cx/news/entries/google-reader-is-dead Linus Torvalds in a Speedo.jpg

(image of Linus Torvalds in a speedo originally from xkcdsucks.blogspot.com)

Google recently announced that they are discontinuing the social features of Google Reader and folding that functionality into Google+. So basically the thing that I liked most about Google Reader, not it's social network features but it's actual social network - the one made of the real people who inhabit my Google Reader friends list - is going to disappear this some time this week. Google Reader was by far my favorite and most active social network so this is pretty crummy from my perspective.

Maybe Google don't realise the value in that network aside from the features of the software itself. Maybe they don't care because they just want to get people into Google+. Either way, we the users lose.

Oh well, this is what you get when you use proprietary software. At some point the company that develops and controls that software will do something you don't like. There is basically nothing you can do about it.

So long, Reader friends, it has been a genuine pleasure! (and for the OCD amongst you, I am very sorry for the hypersharing) :)

]]>
/tags/tech Sat, 22 Oct 2011 10:05 GMT
WApp submission entries/wapp-submission http://www.mccormick.cx/news/entries/wapp-submission pocketloops-design.png

Today I submitted this PocketLoops prototype app to the Univation WApp competition.

This builds on my PdDroidParty work, which is the engine of the app (as well as the impending CanOfBeats re-release!).

Fun mobile-music times. :)

]]>
/tags/tech Fri, 07 Oct 2011 03:56 GMT
Openness is the Only Usability Feature That Matters entries/openness-is-the-only-feature http://www.mccormick.cx/news/entries/openness-is-the-only-feature Android versus iOS use amongst Stackoverflow users

]]>
/tags/tech Wed, 21 Sep 2011 01:03 GMT
PyConAU 2011 talk entries/pycon-2011-talk http://www.mccormick.cx/news/entries/pycon-2011-talk

Here is the talk I gave in Sydney last weekend about Infinite 8-Bit Platformer.

]]>
/tags/tech Tue, 23 Aug 2011 11:44 GMT
Infinite 8-Bit Platformer at PyConAU 2011 entries/pycon-2011 http://www.mccormick.cx/news/entries/pycon-2011 masthead6.png

I'm in Sydney for PyConAU 2011 to give a talk about Infinite 8-Bit Platformer. Hopefully you've registered already because I'm very late in posting about this!

I'll post a link to the video after it goes up.

]]>
/tags/tech Fri, 19 Aug 2011 04:12 GMT
Finite-State Machines in jsGameSoup entries/finite-state-machines-in-jsgamesoup http://www.mccormick.cx/news/entries/finite-state-machines-in-jsgamesoup A finite-state machine is an algorithmic structure which is frequently useful in video games. A finite-state machine can be used to simulate any game entity which has a set of discrete states which it changes between, and which looks different and/or exhibits different behaviour in each of those states. Here are some examples:

  • A non-player character which wanders around and then starts chasing the player once they come in range.
  • A door which switches between closed, opening (animated), and open states.
  • A spacecraft under player control which has an proximity-triggered docking procedure.

Public domain image of a finite-state machine from Wikipedia

Many video game entities can be most easily modelled in this way. In jsGameSoup it is now very easy to create state machines like this. Simply include "statemachine.js" in your HTML file:

<script src="jsGameSoup/js/statemachine.js"></script>

Then call the statemachine() function on an entity inside it's constructur:

function MyEntity() {
    statemachine(this);
    ...
}

After that your entity will have a new method set_state(state) which switches it between different arbitrary states. These states are completely up to you. You can define different behaviours, events, and visual representations by creating multiple versions of jsGameSoup's normal expected methods. For example, let's say the entity above has a state "wandering" and a state "seeking" when it is moving towards the player. In this case we would define two different sets of methods:

/****** Update and draw this entity in the wandering state. ******/

this.wandering_update = function() {
    // update the entity in "wandering" mode
    ...
}

this.wandering_draw = function() {
    // draw the entity in "wandering" mode
    ...
}

/****** Update and draw this entity in the seeking state. ******/

this.seeking_update = function() {
    // update the entity in "seeking" mode
    ...
}

this.seeking_draw = function() {
    // draw the entity in "seeking" mode
    ...
}

When you want to put the entity into a particular state, you call set_state(state), for example in the init() method of the entity to put it into a certain state from the start:

this.init = function() {
    this.set_state("wandering");
}

Here is an example of a jsGameSoup entity class which switches between a "chill" and an "antsy" state. View source to see how it works.

Hopefully this will help you write games and get them infront of players more quickly.

Screenshot of an old game

]]>
/tags/tech Sun, 07 Aug 2011 06:04 GMT
MineAscender - is it fun? entries/mineascender-is-it-fun http://www.mccormick.cx/news/entries/mineascender-is-it-fun

I wrote this game in a few hours today using jsGamesoup.

Is it fun? I would like to know what you think.

(Inspired by SpoutDS).

]]>
/tags/tech Tue, 26 Jul 2011 15:06 GMT
Infinite 8-bit Platformer Alpha entries/infinite-8-bit-platformer-alpha http://www.mccormick.cx/news/entries/infinite-8-bit-platformer-alpha After nearly two and a half years of development (longer if you include prototypes), I am releasing the alpha binaries of Infinite 8-bit Platformer for Windows and Mac. Linux users can of course continue to use the source, Luke.

Alpha screen

I guess there is not much else to say. This is a kinda big deal for me. I would really appreciate it if you share this around!

Let me know what you think!

]]>
/tags/tech Tue, 24 May 2011 10:39 GMT
Pure Data Los Angeles entries/pure-data-los-angeles http://www.mccormick.cx/news/entries/pure-data-los-angeles bang.jpg

This awesomeness was designed and laser cut by Theron Trowbridge.

Also, sign up here for my Pd Workshop tonight in LA!

]]>
/tags/tech Fri, 29 Apr 2011 18:59 GMT
Infinite 8-bit Platformer commit record broken entries/infinite-8-bit-platformer-commit-record-broken http://www.mccormick.cx/news/entries/infinite-8-bit-platformer-commit-record-broken Cool, I just broke my previous record for number of commits to the Infinite 8-bit Platformer codebase in one month! 40 commits and there are still 5 days left in February.

Infinite 8-bit Platformer commits graph for February 2011

The good news is that I think this baby is almost ready for beta-release candidate one. With just 6 items left in the TODO list, I'm getting very excited!

Infinite 8-bit Platformer screenshot for version 252 February 2011

(Perhaps the kind reader and Infinite 8-bit Platformer fan will overlook the previous three months of childbirth related decompression in which not a single commit was made. :] )

"It's done, when it's done." -- John Carmack

]]>
/tags/tech Fri, 25 Feb 2011 14:25 GMT
Inherent Limitations of a Computational Model of Reality entries/inherent-limitations-of-a-computational-model-of-reality http://www.mccormick.cx/news/entries/inherent-limitations-of-a-computational-model-of-reality
  • Some people believe that a computational model of reality is the best model.

  • In this model, reality itself is assumed to be a mathematical process. It is a mathematical system sufficient to describe the set of natural numbers.

  • Therefore Gödel's incompleteness theorms apply to this model of reality.

  • Therefore in such a model of reality you can never prove the consistency of the model from within the model.

  • Additionally, there are true statements within this model which are not provable.

  • This means that such a model of reality cannot possibly contain a nested copy of itself, a perfect predictive model of reality/itself, since such a nested model would allow you to break both of the incompleteness theorems.

  • I think that this is proof that any computational or mathematical model of reality paradoxically excludes itself from ever being a perfect model of reality. This probably applies to all mathematical models of our reality, including any Grand Unified Theory.

  • We can never come up with a mathematical model of reality that is 100% predictive and accurate.

    ]]>
    /tags/tech Sun, 13 Feb 2011 14:12 GMT
    Google as a game console giant entries/google-as-a-game-console-giant http://www.mccormick.cx/news/entries/google-as-a-game-console-giant How Google could become a game console heavyweight to rival the likes of Nintendo, Microsoft, and Sony:

    • Supply USB gamepad drivers for Android OS (this code is actually already in the GNU/Linux kernel underneath Android OS).
    • Put joystick hooks into the Android Java API and market this fact to developers.
    • Encourage TV retailers to sell branded USB gamepads as add-ons with their Android based set-top boxes and TVs.

    Atari by Great Beyond - tonyjcase on flickr

    Developers could then put joystick support in their games, and people could play said games on their TVs through their Android OS set-top boxes. USB Gamepads are a stable, cheap, and robust technology which everyone understands.

    This may result in a new indie console gaming golden age, with all of the wonderful new indie games of recent years running in peoples' lounge rooms on their TVs just like in the 80s. Admit it, wouldn't you love to sit cross legged together under the TV and return to the days of Sonic the Hedgehog, Mario Bros., Alex Kidd, Commander Keen, and friends? Only newer, and cheaper, and open, and network multiplayer. Oh boy, that is a vision I find irresistable!

    A guy can dream, right?

    ]]>
    /tags/tech Fri, 28 Jan 2011 00:43 GMT
    squeakyshoecore: New tunes, interview, live set entries/squeakyshoecore-new-tunes-interview-live-set http://www.mccormick.cx/news/entries/squeakyshoecore-new-tunes-interview-live-set Hello! I've uploaded two new tunes to the squeakyshoecore album of algorithmic acid. They are called ring singularity and prolate spheroid. Get yr rave on here. Incidentally, you might like to type the names of the squeakyshoecore songs into the search bar of Wikipedia. They are all named after fascinating science and mathematics topics.

    upside down squeakyshoecore shoe

    On the 18th of December, I will also be playing a live gig in Hyde Park, Perth. I will be using the GarageAcidLab algorithms that I use to make squeakyshoecore here in Perth, Western Australia as part of the Seriously Sound System music festival organised by the local radio station, RTRFM. I am on just after midday at 12.40 in the afternoon. It should be a lot of fun!

    Leading up to that I will be interviewed on that radio station at 8am local time this Friday the 10th of December. If you are not awake for it (like me), or you don't live in Western Australia, you can listen to the podcast, which I'll post here afterwards if I can figure out where it is.

    Kampai!

    ]]>
    /tags/tech Thu, 09 Dec 2010 16:06 GMT
    Disapora first run entries/diaspora-first-run http://www.mccormick.cx/news/entries/diaspora-first-run Diaspora is the new social network effort by a group of hackers who are building a Free Software implementation of something like Facebook, or Google Buzz, but in a decentralised, open source, privacy aware way. Here are the things that I think are really promising about it so far:

    • Your people are organised into 'aspects' which are logical groupings like in real life e.g. "family people", "work people", "people I send rude jokes to" etc. so that you won't ever post a picture of yourself drunk and naked for your grandmother to see by accident. This is baked into the interface in a completely natural way that feels right and fits with your existing mental model of your social groups. To me this is the number one killer feature that might encourage people to use it over Facebook. I was convinced that this is neccessary by the slides from this talk: http://www.slideshare.net/padday/the-real-life-social-network-v2. I think that Mark Zuckerberg's everyone-should-over-share-with-everyone-and-get-over-it philosophy of privacy is at odds with basic human nature.

    • Your 'seed' (user) is portable. If you don't like the pod (server) you started with you can easily move to a different one. This is great as you aren't locked down to a particular provider. If your social service provider stops maintaining their code, or their service is bad, or they try to snoop on people, then you can get up and leave and find a better provider and take all of your data, posts, contacts etc. with you.

    • It's decentralised. There isn't a single server or point of access like there is with Facebook and Google Buzz. This might sound like it would not work, but it does because you can friend people on other servers and it works exactly as if they were on the same server as you. You can even be the only person on your own privately run pod (server) and still network with, and see what your friends on other pods are up to. It's like email in that respect, except without the spam. Your address at a particular pod looks like an email address, so that is a concept that people already understand well.

    • It's going to link up with other social networking services like Twitter, Buzz, Facebook etc. I guess the update posting will be based on the "aspects" idea too so if you post publically then it goes out to social networks, but otherwise not. This bit isn't done yet, but I'm excited about it as it means I can stop using the other services by visiting their sites. Instead when I post something on Diaspora, I can elect to also have it tweeted or fb updated, or whatever. I am not sure if it will be two-way so that you could also read your friends Facebook status updates from your diaspora instance, but that would be very cool if they can pull it off. That would provide a big incentive for people to switch as they can maintain their existing networks.

    • Encryption of your data keeps it away from snooping sysadmins. You don't have to completely trust whoever is hosting your account, and the fact that Google and Mark Zuckerberg don't own your data and they can't "mine" it for their own benefit, is another big feature for me. My social graph is not a corporate asset.

    People have said to me "but nothing can kill Facebook now, it's too big." I beg to differ for two reasons:

    • I've had internet access since about 1995, and I have seen a ton of protocols come and go, even ones that literally everyone on the internet used. Remember BBSes, Gopher, Archie, news groups, ICQ, IRC, etc. etc.? Yes, most of them are still around, but the majority of internet users don't use them any more. There is no doubt in my mind that the same thing can happen to Facebook.

    • Facebook is not the only social network. There are a ton of others and some of them come close to rivalling it in size. In some countries other networks have a larger presence than Facebook does. I think that people will follow two things to new software: a) their friends b) features. I think that privacy features are important to people, good ideas spread virally, and friendship groups will stick together across networks.

    • The internet is built on competition between software and protocols. It's a thriving environment in which the most evolved software is selected by users and survives in the long run. I believe that even if Diaspora is not it, something better than Facebook will come along and unseat it. Historically speaking it's the open and free systems and software that survive the best and longest in the network environment.

    Because it's Free Software following the "release early, realease often" development model, Diaspora is buggy and insecure and lacking in features right now, but I think it holds huge promise. In the few days I have had it running I've already seen bugfixes and features going in at a tremendous rate. I'm going to continue hosting my own pod and fingers crossed, maybe I'll meet you in the Diaspora universe one day soon.

    "They trust me - dumb fucks." -- Mark Zuckerberg

    ]]>
    /tags/tech Fri, 19 Nov 2010 06:46 GMT
    FallingGame jsGameSoup demo - updated entries/fallinggame-jsgamesoup-demo http://www.mccormick.cx/news/entries/fallinggame-jsgamesoup-demo Update: There appears to be some weird bug on WebKit (at least in Chrome) making objects randomly not get drawn in both demos. Will have to figure this one out!

    Update 2: The WebKit bug is now fixed and was due to the strage fact that Array.sort is unstable in WebKit - one to remember. Have fun!

    jsGameSoup logo - a bowl and chopsticks

    Here's another demo built using my HTML5 and Javascript game engine, jsGameSoup.

    I also updated the AsteroidsTNG demo to support collisions so that the ship no longer passes through the asteroids.

    I'm finding it pretty fun to fly around this almost infinite asteroid field finding interesting little places amongst the virtual space rocks. I really want to add some kind of multiplayer component to this demo.

    After these changes jsGameSoup now has the following new features:

    • Collision engine with support for circle, poly, and axis-aligned bounding-box (rectangle) collisions.
    • Sprite engine which is capable of basic animation.
    • Seedable random number generator, useful for procedurally generated worlds where you want the same seed to generate the same thing for everyone every time.
    • Basic support for touch on WebKit browsers (like in the iPad and Android devices).

    The collision, sprite, and random number engines are each simple and self-contained, and can be used independently of the jsGameSoup library by just including the respective javascript file in your project. If you use the library though, you also get cross platform events and robust entity management thrown in for free.

    Unfortunately I still haven't updated the documentation or the jsGameSoup page to reflect these changes. Whoops!

    ]]>
    /tags/tech Sat, 06 Nov 2010 02:08 GMT
    Android is a ghetto entries/android-is-a-ghetto http://www.mccormick.cx/news/entries/android-is-a-ghetto When people try to engage me in iPhone vs. Android arguments, I usually concede to almost all of their pro-iPhone, anti-Android arguments. The iPhone user experience is paramount. I do not know of a greater technology user experience than that of using those hand held Apple products. Android is a total ghetto.

    The problem for Apple is that all of the interesting things come from the ghetto. Hip hop and punk rock came from the ghetto. Apple does not have a single gram of punk rock in it's entire being - they are the furthest possible thing from punk rock in the technology world. Apple is the U2 of the technology world; bland, pleasant, and pushing all of the right buttons to make us feel good. Apple is easy, and easy is utterly boring.

    Examples of this are clearly emerging now into mainstream conciousness. Brilliant apps which simply can't work on the Apple platform because of the restrictions placed on them there, are emerging on the Android platform right alongside the multitude of hideously ugly, broken apps which are also emerging. This is called evolution. It's ugly, and complicated, and it is much better at optimising for survival. It's the exact same reason why Free Software (also a technology favela, upon which Android is based) has been so incredibly successful in the last 20 years.

    Android is succeeding because it is the ghetto. Sorry Steve Jobs, you will never understand how people can reject your pristine perfect jail for the thriving, ugly richness of the software underbelly.

    "I have an important message to deliver to all the cute people all over the world. If you're out there and you're cute, maybe you're beautiful. I just want to tell you somethin' - there's more of us UGLY MOTHERFUCKERS than you are, hey-y, so watch out."

    -- Frank Zappa

    ]]>
    /tags/tech Fri, 29 Oct 2010 12:35 GMT
    Get Google Spreadsheet data into Python entries/get-google-spreadsheet-data-into-python http://www.mccormick.cx/news/entries/get-google-spreadsheet-data-into-python If you want an easy interface for someone to input regular data, you might like to use a Google Spreadsheet. You can extract the resulting data from the spreadsheet into Python using this code snippet:

    import urllib2
    import csv
    
    url = GOOGLE_DOC_URL + "&output=csv"
    request = urllib2.Request(url)
    
    cookie_handler = urllib2.HTTPCookieProcessor()
    redirect_handler = urllib2.HTTPRedirectHandler()
    opener = urllib2.build_opener(redirect_handler,cookie_handler)
    
    u = opener.open(request)
    
    data = list(csv.reader(u))
    

    You will need to share the document as "Anyone who has the link can view" because there is no authentication happening here. The variable GOOGLE_DOC_URL should be the URL shown in the "Sharing settings" panel. The final variable 'data' will hold an array of arrays of strings - the spreadsheet values are the strings.

    ]]>
    /tags/tech Mon, 18 Oct 2010 05:01 GMT
    GarageAcidLab on Android entries/garage-acid-lab-on-android http://www.mccormick.cx/news/entries/garage-acid-lab-on-android My third Android app is now available in the Android Market. Click below or use the QR code to install GarageAcidLab, an algorithmic 303 bassline generator.


    Here is a small website I made about the software, which you can also download and run inside Pure Data. It's Free Software, like most of my other work.

    This is also the set of patches that I am using to create the album squeakyshoecore.

    ]]>
    /tags/tech Sun, 03 Oct 2010 10:59 GMT
    CanOfBeats in the Android Market entries/canofbeats-in-the-android-market http://www.mccormick.cx/news/entries/canofbeats-in-the-android-market CanOfBeats running on Android

    There's a good reason I haven't been posting many squeakyshoecore tunes lately, or making much progress on my video game Infinite8BitPlatformer. I've been hacking hard in my spare time, and the good news is that CanOfBeats, my algorithmic hiphop beat generator, is now available for Android phones and devices! So if you are seeking beats and you rock an Android phone, help an indie developer out and get yrself a copy from the Android Market.

    Enjoy!

    ]]>
    /tags/tech Sun, 26 Sep 2010 16:51 GMT
    Cheap, modular, fun music devices entries/cheap-modular-fun-music-devices http://www.mccormick.cx/news/entries/cheap-modular-fun-music-devices Android music panel 1

    Android music panel 2

    Android music panel 3

    Android music panel 4

    Hope you enjoyed these drawings of my ultimate music-making dream setup. My apologies to anyone using a screen reader.

    ]]>
    /tags/tech Thu, 23 Sep 2010 15:25 GMT
    PyConAU 2010 Video entries/pyconau-2010-video http://www.mccormick.cx/news/entries/pyconau-2010-video I am ridiculously behind on blogging because of the amount of contract work I have going on at the moment (working Saturdays and weeknights until 2am - not fun!) Anyway, I'll stop whining now.

    Below is a video of the talk I gave at PyCon AU at the end of June. In it I talk about my time working for London based "reactive music" company, RjDj, and also about my video game Infinite8BitPlatformer.

    I haven't posted an Infinite8BitPlatformer update for ages, and I have been meaning to do so since a lot of progress has been made since my last post, but here's a quick update:

    • Multiplayer code: this is going really well. It's almost at the point of beta release.
    • Contributors: another person has started contributing to the codebase. I am hopefully going to be merging his code this weekend. Julian has put basic chat into the multiplayer code, among other tweaks and bugfixes, and a huge amount of very useful information for other people looking to contribute. He's been very patient about my lack of time!

    Anyway, back to work.

    ]]>
    /tags/tech Sat, 31 Jul 2010 06:15 GMT
    The Robustness Principle as a social heuristic entries/the-robustness-principle-as-a-social-heuristic http://www.mccormick.cx/news/entries/the-robustness-principle-as-a-social-heuristic The Robusness Principle is a good principle for writing network server/client software. If you follow it your software is less likely to fail when interfacing with other software. I also find it to be an optimal heuristic when it comes to interacting with other human beings.

    Be conservative in what you do; be liberal in what you accept from others.

    -- Jon Postell

    I wonder if there is a formal proof that it is an optimally efficient algorithm for interacting entities who don't completely know eachother's context/protocol, from the perspective of information theory?

    ]]>
    /tags/tech Mon, 21 Jun 2010 12:50 GMT
    Self contained, non-root python library directory entries/self-contained-non-root-python-library-directory http://www.mccormick.cx/news/entries/self-contained-non-root-python-library-directory If you want to have some Python libraries installed in your system somewhere other than the standard place ("site-packages"), here's how to do it. This can be useful if you don't want them to interfere with your operating-system installed path, or if you don't want to become root/admin in order to install them.

    This problem is solved by things like virtualenv and buildout, but I find that this will suffice for a lot of cases, or if you don't want to learn the ins and outs of those systems.

    First, create a directory somewhere for your alternative Python libraries to go into:

    $ mkdir ~/my-python-libraries/
    

    You only have to do that step once.

    Next, tell future Pythons that we have an alternative path where libraries live by setting an environment variable:

    $ export PYTHONPATH=~/my-python-libraries/
    

    This means that Python will check that directory for Python libraries when you try to import them. If you are always using that library path, you could put it in your .profile or .bashrc file so that it is set on login.

    Now when you install new libraries, make sure they go into that alternative path:

    $ cd some-library
    $ python setup.py install --prefix=$PYTHONPATH --install-purelib=$PYTHONPATH --install-platlib=$PYTHONPATH --install-scripts=$PYTHONPATH/bin --install-data=$PYTHONPATH
    

    One good thing to do is make a handy little one-line script which sets the PYTHONPATH variable when you want to start working on a project which needs those libraries. You could put it in ~/bin or in your project's root or scripts/ subdirectory.

    You can also make a script in your ~/bin directory which runs the python setup.py command with those command line arguments set and call it something like "install-python-library".

    ]]>
    /tags/tech Sat, 12 Jun 2010 03:02 GMT
    Nearest power of two entries/nearest-power-of-two http://www.mccormick.cx/news/entries/nearest-power-of-two I had a hard time finding where I had written this down, and I will almost certainly need it again.

    update: More power-of-two fun at Frank's blog with Fast power-of-two modulo.

    To find the nearest power of two (linearly) to a given number:

    pow(2, int(log(n, 2) + 0.5))
    

    To find the next highest power of two:

    int(pow(2, ceil(log(n, 2))))
    

    That's Python code, but pretty much applies in any language. There are some very fast log2 implementations out there if you need them.

    Also, if you only have access to log10 in your programming environment (as I did when I worked that out), you might need this:

    log2(n) = log10(n) / log10(2)
    

    This is expressed generally as:

    logX(n) = logY(n) / logY(X)
    

    (Those two aren't Python code).

    ]]>
    /tags/tech Thu, 03 Jun 2010 08:31 GMT
    More 3d printed robots entries/more-3d-printed-robots http://www.mccormick.cx/news/entries/more-3d-printed-robots This 3d printing stuff is addictive.

    ]]>
    /tags/tech Sun, 30 May 2010 05:40 GMT
    PyCon AU 2010 entries/pycon-au-2010 http://www.mccormick.cx/news/entries/pycon-au-2010 PyCon AU Logo

    There is a new Python conference running this year for the first time. It's in Sydney, Australia, at the end of June. I'll be speaking, and I'm very excited about attending too; there are a number of high quality topics evident in the conference schedule. I'm particularly happy not to have a clashing time slot with my friend and occasional colleague, Simon Wittber, as his talk looks fascinating. If you are into Python, you should go!

    Go to the PyCon AU 2010 website for more details.

    ]]> /tags/tech Tue, 18 May 2010 15:22 GMT Android, iPhone, evolution, and intelligent design entries/android-iphone-evolution-intelligent-design http://www.mccormick.cx/news/entries/android-iphone-evolution-intelligent-design With the recent news that Android phones are outselling phones running the iPhone OS in the USA in the first quater of 2010, I wanted to write down something that I have been ranting at my more patient friends for the last few months. The open development platform style of Android is like evolution, whilst the closed Apple platforms are more like intelligent design.

    • Apple periodically come out with a single near-perfect product.
    • Android products get incrementally better with each iteration from each phone company.

    • Apple must make every product a hit - they can't afford failures like Apple TV. Failures are very expensive for Apple.

    • Android allows Google to outsource failure. Infact, failures by the 3rd party companies who make Android phones actually help the evolution of other Android products as all products in that class can learn and benefit from the mistakes of eachother. This is like the transfer of genetic information. Failing phones are part of the survival of the fittest style of interaction that occurs in nature.

    • Like the traditional Mac platform strategy, the iPhone strategy is about elite, expensive, "cool" devices with fantastic usability.

    • The Android strategy is more like the PC platform of years past. It will result in a wide choice of generally uglier phones that don't work as well as the iPhone, but that slowly get better and better. Everyone will use them anyway, much to the confusion of die-hard Apple fans. This will be because market pressures will ensure that the cheapest phones of the highest quality, which give the user the most control and choice, will be the most popular. Often the most successful new designs will be copied from market leaders like Apple and other Android makers.

    Evolution is dirty, ugly, and messy, but the end result is always more successful in a competitive ecosystem. It's interesting to consider which strategy will be more robust in the smartphone market.

    ]]>
    /tags/tech Mon, 17 May 2010 03:47 GMT
    Tabs versus spaces entries/tabs-versus-spaces http://www.mccormick.cx/news/entries/tabs-versus-spaces
  • vectors vs pixels
  • stems vs downmix
  • modfiles/patches vs wavs
  • meshes vs render
  • tabs vs spaces
  • Usually I choose to store and edit the things on the left hand side.

    ]]>
    /tags/tech Mon, 10 May 2010 12:43 GMT
    Ludum Dare #17 Post-mortem entries/ld17-postmortem http://www.mccormick.cx/news/entries/ld17-postmortem I recently took part in the Ludum Dare 48 hour game challenge, number 17. Here's my list of blog entries at the Ludum Dare site.

    Hovergirl

    I didn't finish a game, but it gave me a chance to experiment some more with writing games in pure Javascript in the browser. I consider the final product a reasonable proof of concept of a Sprite() class which uses div tags with background-images. I'll probably develop it some more and put it into jsGameSoup. I really need to do a speed test on various platforms, and between using div tags and canvas.drawImage.

    Graphics mockup

    Here is a link to the tech demo, which has only been tested in recent versions of Firefox, but probably works in webkit browsers too. The world is procedurally generated using perlin noise on the server side, and a seedable MWS number generator on the client side for placement of trees and stuff.

    Final screenshot

    Here is a link to the source code. There is a working bzr branch repository in the tarfile, as well as the source code itself.

    I recently started working on the multiplayer code for Infinite8BitPlatformer, so hopefully there will be a playable multiplayer demo in the not-too-distant future. What I have working is test-client connecting to the server and getting a unique ID back.

    ]]>
    /tags/tech Wed, 05 May 2010 11:07 GMT
    "Thoughts on Flash" Rebuttal entries/thoughts-on-flash-rebuttal http://www.mccormick.cx/news/entries/thoughts-on-flash-rebuttal It's ridiculous that a Free Software developer like me should be defending one prorietary software maker against another, but that's the point that this whole thing has reached: ridiculousness.

    Steve Jobs, April 2010:

    I wanted to jot down some of our thoughts on Adobe’s Flash products so that customers and critics may better understand why we do not allow Flash on iPhones, iPods and iPads. Adobe has characterized our decision as being primarily business driven – they say we want to protect our App Store – but in reality it is based on technology issues. Adobe claims that we are a closed system, and that Flash is open, but in fact the opposite is true. Let me explain.

    Both are wrong. Flash is a closed system. Apple products are closed systems.

    Adobe’s Flash products are 100% proprietary. They are only available from Adobe, and Adobe has sole authority as to their future enhancement, pricing, etc. While Adobe’s Flash products are widely available, this does not mean they are open, since they are controlled entirely by Adobe and available only from Adobe. By almost any definition, Flash is a closed system.

    Ditto for Apple products.

    Apple even creates open standards for the web. For example, Apple began with a small open source project and created WebKit, a complete open-source HTML5 rendering engine that is the heart of the Safari web browser used in all our products. WebKit has been widely adopted. Google uses it for Android’s browser, Palm uses it, Nokia uses it, and RIM (Blackberry) has announced they will use it too. Almost every smartphone web browser other than Microsoft’s uses WebKit. By making its WebKit technology open, Apple has set the standard for mobile web browsers.

    To quote Wikipedia:

    "WebKit was originally created as a fork of KHTML as the layout engine for Apple's Safari; it is portable to many other computing platforms."

    -- "WebKit" on Wikipedia

    It's deeply offensive that Steve Jobs implies that Apple made WebKit technology open. They did not. It is open because KTML, upon which it is based, is Free Software. Forking KTHML was the fastest way that Apple could gain a competitive advantage without doing too much of their own actual work. This is the identical move they made when they took chunks of the BSD licensed FreeBSD and NetBSD operating systems and the Mach kernel to make OSX. Apple have a history of taking the work of other people and using it in their closed systems to make themselves rich. It's incredibly selfish behaviour.

    The only person who could truly claim original credit for the 'opening' of so much software these days is the creator of the LGPL and founder of the Free Software movement, Richard Stallman. Almost all of Apple's products up to this point have been compiled with a compiler which Richard Stallman wrote, called gcc.

    Adobe has repeatedly said that Apple mobile devices cannot access “the full web” because 75% of video on the web is in Flash. What they don’t say is that almost all this video is also available in a more modern format, H.264, and viewable on iPhones, iPods and iPads. YouTube, with an estimated 40% of the web’s video, shines in an app bundled on all Apple mobile devices, with the iPad offering perhaps the best YouTube discovery and viewing experience ever. Add to this video from Vimeo, Netflix, Facebook, ABC, CBS, CNN, MSNBC, Fox News, ESPN, NPR, Time, The New York Times, The Wall Street Journal, Sports Illustrated, People, National Geographic, and many, many others. iPhone, iPod and iPad users aren’t missing much video.

    Nice advertisement. I thought this was supposed to be about Flash, not how great your YouTube application is and how many dead media companies are sucking up to you.

    Another Adobe claim is that Apple devices cannot play Flash games. This is true. Fortunately, there are over 50,000 games and entertainment titles on the App Store, and many of them are free. There are more games and entertainment titles available for iPhone, iPod and iPad than for any other platform in the world.

    "many of them are free," except in the sense of freedom which implies that you are free to do what you want with something you own. No, those games are very definately not free. They come with the high price of locking you into a system owned by Apple and behaving in Apple sanctioned ways. That goes for users and developers.

    Symantec recently highlighted Flash for having one of the worst security records in 2009. We also know first hand that Flash is the number one reason Macs crash. We have been working with Adobe to fix these problems, but they have persisted for several years now. We don’t want to reduce the reliability and security of our iPhones, iPods and iPads by adding Flash.

    One word: sandbox. If Google can do it with Chrome, then Apple could do it with Safari. In other words, if your operating system was written correctly, 3rd party buggy plugins and apps should not be an issue. Giving your users the freedom to run any software they like (even if it does contain bugs) is important. Otherwise you risk treating them like children, or like idiots.

    In addition, Flash has not performed well on mobile devices. We have routinely asked Adobe to show us Flash performing well on a mobile device, any mobile device, for a few years now. We have never seen it. Adobe publicly said that Flash would ship on a smartphone in early 2009, then the second half of 2009, then the first half of 2010, and now they say the second half of 2010. We think it will eventually ship, but we’re glad we didn’t hold our breath. Who knows how it will perform?

    Development takes time. Don't talk to us about slow development, Steve Jobs. A cursory look at Apple's history is enough to see the pot calling the kettle black.

    To achieve long battery life when playing video, mobile devices must decode the video in hardware; decoding it in software uses too much power. Many of the chips used in modern mobile devices contain a decoder called H.264 – an industry standard that is used in every Blu-ray DVD player and has been adopted by Apple, Google (YouTube), Vimeo, Netflix and many other companies.

    Although Flash has recently added support for H.264, the video on almost all Flash websites currently requires an older generation decoder that is not implemented in mobile chips and must be run in software. The difference is striking: on an iPhone, for example, H.264 videos play for up to 10 hours, while videos decoded in software play for less than 5 hours before the battery is fully drained.

    Ridiculous nitpicking. Flash could, and should use hardware decoders. I wonder why they can't, or won't? Oh, that's right, it's because Apple only just openned up that previously closed API. Infact, since then Adobe have indeed put that functionality into Flash.

    In other words, more FUD from Steve Jobs.

    When websites re-encode their videos using H.264, they can offer them without using Flash at all. They play perfectly in browsers like Apple’s Safari and Google’s Chrome without any plugins whatsoever, and look great on iPhones, iPods and iPads.

    That is great, except that H.264 is also not a free codec that anyone can use without worries. It requires licensing, unlike ogg, vorbis, theora.

    Flash was designed for PCs using mice, not for touch screens using fingers. For example, many Flash websites rely on “rollovers”, which pop up menus or other elements when the mouse arrow hovers over a specific spot. Apple’s revolutionary multi-touch interface doesn’t use a mouse, and there is no concept of a rollover. Most Flash websites will need to be rewritten to support touch-based devices.

    Just like most apps have to be written from the iPhone to the iPad, right? Just like most apps have to be re-written from any other language and framework on the planet, into C/C++/ObjC/Cocoa right? Double standards.

    Software needs to be written and re-written all the time. That's not a good reason for sabotaging the people who develop for your platform. If anything you should be helping them by supporting as many 3rd party frameworks as possible.

    If developers need to rewrite their Flash websites, why not use modern technologies like HTML5, CSS and JavaScript?

    Or modern, open technologies like Objective C and Cocoa and... wait a second, those aren't modern or open, but you still require your app developers to use only those techonlogies. Again, double standards.

    Even if iPhones, iPods and iPads ran Flash, it would not solve the problem that most Flash websites need to be rewritten to support touch-based devices.

    Could be rewritten like this: "Even if iPads run the same technology as iPhones, it would not solve the problem that most apps need to be rewritten to support a larger screen size." Hippocracy.

    We know from painful experience that letting a third party layer of software come between the platform and the developer ultimately results in sub-standard apps and hinders the enhancement and progress of the platform. If developers grow dependent on third party development libraries and tools, they can only take advantage of platform enhancements if and when the third party chooses to adopt the new features. We cannot be at the mercy of a third party deciding if and when they will make our enhancements available to our developers.

    Total rubbish. Any 3rd party framework which doesn't keep up with the latest innovations will be ditched by developers. In addition, any worthwhile framework will still let you use the features of a specific platform outside of that framework. It's called a function call, but you probably haven't heard of it because Woz wrote all of the function calls for you.

    The truth is that there are many wonderful pieces of software out there, like Mozilla Firefox, which use abstraction layers and 3rd party libraries and frameworks so that they run in as many places and on as many platforms as possible.

    This becomes even worse if the third party is supplying a cross platform development tool. The third party may not adopt enhancements from one platform unless they are available on all of their supported platforms. Hence developers only have access to the lowest common denominator set of features. Again, we cannot accept an outcome where developers are blocked from using our innovations and enhancements because they are not available on our competitor’s platforms.

    Once again, total rubbish. No framework would try to block it's developers from doing something outside the framework for a specific platform. Oh wait, one framework would try and do that and guess who makes it?

    Flash is a cross platform development tool. It is not Adobe’s goal to help developers write the best iPhone, iPod and iPad apps. It is their goal to help developers write cross platform apps.

    100% true, and laudible. The more places your application runs the better.

    Our motivation is simple – we want to provide the most advanced and innovative platform to our developers, and we want them to stand directly on the shoulders of this platform and create the best apps the world has ever seen. We want to continually enhance the platform so developers can create even more amazing, powerful, fun and useful applications. Everyone wins – we sell more devices because we have the best apps, developers reach a wider and wider audience and customer base, and users are continually delighted by the best and broadest selection of apps on any platform.

    This paragraph is the truest of the whole thing. Basically there is a frank admission in here that Apple want developers to only work on Apple platforms so that Apple can "have the best apps" and sell more devices. They want to be the only ones to have those apps. They don't want those apps to run anywhere else. The part about developers reaching a wider audience is total rubbish. If you only release on Apple devices you are by definition not going to reach the widest user base you can. Only writing a cross-platform app can garuantee you that. This is also definately not best for users. If you are locked to a particular platform because the applications you use only run on that platform then you lose all freedom of choice. No, there is only one entity that this is really good for, and that is Apple.

    Flash was created during the PC era – for PCs and mice. Flash is a successful business for Adobe, and we can understand why they want to push it beyond PCs. But the mobile era is about low power devices, touch interfaces and open web standards – all areas where Flash falls short.

    Stupid argument. iPhone OS and OSX are based on the Mach kernel and parts of FreeBSD which is based on 1960s technology. Additionally, HTML5 is slow as hell right now, as anyone who has tried to write a game as a web-app knows.

    The avalanche of media outlets offering their content for Apple’s mobile devices demonstrates that Flash is no longer necessary to watch video or consume any kind of web content. And the 200,000 apps on Apple’s App Store proves that Flash isn’t necessary for tens of thousands of developers to create graphically rich applications, including games.

    It's not necessary at all, but Apple want to make it impossible. Apple want to dicatate completely what users and developers and can can't do on their platform. Do you want Apple controlling every aspect of your computing life so tightly?

    New open standards created in the mobile era, such as HTML5, will win on mobile devices (and PCs too). Perhaps Adobe should focus more on creating great HTML5 tools for the future, and less on criticizing Apple for leaving the past behind.

    That would be awesome. If Adobe re-wrote Flash in HTML5 it would be a win for everyone. It would also be a big win for everyone if Apple openned up their platform and allowed developers and users the freedom to use their devices how they please.

    They should both stop being such conniving selfish jerks.

    ]]>
    /tags/tech Fri, 30 Apr 2010 07:53 GMT
    Ludum Dare #17 entries/ludum-dare-17 http://www.mccormick.cx/news/entries/ludum-dare-17 I am taking part in the Ludum Dare #17 48 hour game challenge this weekend, and hence taking a bit of a break from Infinite8BitPlatformer programming this weekend. Follow me on the competition blog if you're interested! I will be releasing all of the sourcecode from my game at the end of the competition.

    Incidentally, I have fixed up many of the Infinite8BitPlatformer bugs that were reported during the pre-alpha, and had some more great contributions from Crispin, such as a spray-can tool for in-game editing and some fun levels. Also last week I finished a bunch of tweaks, features, and bug fixes on the PodSixNet code, so next on the agenda is the multi-player code. Hopefully I'll be able to fit that in around the contract work I have on next week. Exciting stuff!

    Anyway, back to the competition.

    ]]>
    /tags/tech Sat, 24 Apr 2010 06:58 GMT
    Infinite8BitPlatformer - Crispin's World entries/infinite-8bit-platformer-crispins-world http://www.mccormick.cx/news/entries/infinite-8bit-platformer-crispins-world

    Wow, today marks a huge milestone in the life of Infinite8BitPlatformer, thanks to my friend Crispin. He's written some code which adds a line tool to the existing suite of pencil and fill tools, and he created a level with it. This is the very first substantial code submitted from someone else, and the very first user contributed level, and the game isn't even released yet! In case you can't tell, I am super excited.

    This was also the first opportunity for me to experience the proof-of-concept of exploring a level someone else created. I must admit that it lived up to my expectations. Running around in the new level, exploring, and finding items was a genuinely enjoyable experience, and one I can't wait to repeat many more times as the game matures and gets further contributions. Good times.

    Thanks, Crispin!

    PS The game is currently in pre-alpha testing. If you'd like to try it out, drop me an email and I'll send you the link.

    ]]>
    /tags/tech Wed, 14 Apr 2010 05:02 GMT
    Matter entries/matter http://www.mccormick.cx/news/entries/matter Only one of the little robots that I designed survived the 3D printing process. This is because of my inexperience in designing for 3d printing. As you can see from the one that worked out, many of the connecting struts were almost too thin to be structurally sound, and this was the case in the other ones I sent off for printing.

    Nonetheless there is something deeply profound and kind of humbling about holding this delicate little robot in my hand. I've spent my whole life creating virtual things - computer programs, graphics, music - and now it is possible to use the exact same skills to produce something who's physical structure may well outlast that of my own. Walking through Roman ruins earlier this year I realised that there is something about hard physical matter that is so important. Seeing a marble carving of some guy's face which has outlasted his original face by so many thousands of years really drove it home.

    Last year I also read "Matter" by Iain M. Banks and although it didn't grab me as much as some of his previous books, there was an interesting argument about virtuality from one of his characters. The essence of the argument was that we don't inhabit a virtual universe overseen by some creator or creator race because any sufficiently advanced entity or culture would not allow the terrible things that can happen to sentient beings in our universe, to occur. It's sort of a meta-ethical argument saying that we can't be anywhere other than at the top of the stack of turtles, if the ethics of highly evolved intelligences are always consistent.

    On a related note, this blog post makes the case that in software development the execution of an idea is much more important than the idea. I have come to believe that this is true in general. Because we now live in this highly populated and deeply connected age, ideas have become cheap. Real things, done things, executed things, are better than virtual things and ideas.

    This decade is going to be fascinating because of the increasing protrusion of the virtual into the real and the modification of the real by the virtual. Bring on the self configuring household ornaments built of programmable nanotech, such as a flower which has as many petals as there are emails in your inbox.

    Virtual things are ok, but real things are better.

    ]]>
    /tags/tech Tue, 06 Apr 2010 14:21 GMT
    Enso - The start of a gadget tidal wave entries/enso-the-start-of-a-gadget-tidal-wave http://www.mccormick.cx/news/entries/enso-the-start-of-a-gadget-tidal-wave

    Recently on Engadget this little gem slipped past quietly. If you read the about page you will find a fascinating company.

    "...legal entity in Hong Kong and main offices in the Shenzhen City (China)..."

    "The devices we deal with must be powered by opensource software ( no vendor locks ) and mantain general high quality standards concerning all phases of the production flow."

    "We absolutely refuse to work with any company that contribute to destroying our planet, and act unethically or illegally."

    "All our staff comes from different countries, like Italy, Canada and Sweden."

    Enso

    Equally fascinating are the specifications and the competitive price of this gadget. At under $US 200 it's quite irresistable. If the quality turns out to equal that of American sourced devices, I think that this could be the start of a tidal wave of new devices coming out of China and its SARs and satellites.

    In previous decades the car companies of the United States were completely decimated by their asian counterparts who started out making cheap copies, and ended up making better cars for less. The gadget makers in the USA (yep, even the big ones) are in for a similar suprise during this decade.

    ]]>
    /tags/tech Fri, 26 Mar 2010 02:40 GMT
    Ada Lovelace day 2010 entries/ada-lovelace-day-2010 http://www.mccormick.cx/news/entries/ada-lovelace-day-2010 Technically it's still yesterday where the server that hosts this blog lives, so I'm not too late to post this. As is traditional on Ada Lovelace day, I am going to write about women in technology who have influenced and inspired me.

    First up is somebody I don't know personally, but her hardware hack is so ridiculously awesome that I just have to mention her here. Her name is Jeri Ellsworth, and she is a self-taught chip designer and technology consultant. The hack which excited me so much was to make a regular old floppy disk drive into an audio delay effect. Check out this youtube video. I so have to make one of those! If you read her blog and Wikipedia page you'll notice a large number of other awesome techy things she has done with her time too.

    Kay Smoljak is somebody I worked with in my first real programming job. Kay was one of the most productive coders at Perthweb, singlehandedly developing some enormous sites in Coldfusion and putting the rest of us to shame. Now she and her partner Dave run a successful web consultancy business called Clever Starfish, in between rocking out at metal gigs. Because of those guys I got to hear a lot of great metal. I haven't seen Kay and Dave for years, but we should have a beer sometime!

    This will probably embarrass the hell out of her, but I also want to name-drop my friend and colleague at RjDj, Andie Nordgren. Despite the presence of the word "manager" in her title, Andie is utterly invaluable, and different from every other manager-type-person, because she has committed actual code into our various project repositories. She knows the correct syntax for a handful of languages, as well as diving into new ones at the drop of a hat, and I've witnessed her banging out SQL statements to extract stats from our database when we were too slow to get a proper frontend working. That's an exceptionally rare and wonderful thing in someone who goes by the title of manager! Finally she's just an all round nice person and I think everybody in the team feels on a level with her, never "managed", although she has saved the team from mutually assured destruction a couple of times by coming up with technical and management solutions which nobody else did. So thanks, Andie, it's really great working with you! P.S. also check out her "soldering is easy" instructional comic.

    The last woman in technology who I'd like to mention is my mother. Sally McCormick taught this young whippersnapper how to program on an Apple //e shortly after I learned how to walk and talk, and I've never looked back. I quite literally owe her my entire career and luckily I know she's much too nice to ever ask for it back. After a distinguished career teaching mostly science and mathematics at several different schools around the planet, she now teaches information technology in Western Australia. Often's the time I drop past my parent's place in the evening to find her, head down, snoozing into an Actionscript book or Java manual. Pretty sure she learns by osmosis. Thanks Mum!

    ]]>
    /tags/tech Thu, 25 Mar 2010 02:27 GMT
    Infinite 8-bit Platformer commit graph entries/infinite-8bit-platformer-commit-graph http://www.mccormick.cx/news/entries/infinite-8bit-platformer-commit-graph Staying motivated on your personal side projects is really quite hard! Moose and I have moved closer to the city, so now I have a bit more time and space and have been hacking on Infinite 8-bit Platformer again. Here is a graph of commits-per-month on the project:

    Infinite Platformer commits per month to March 2010

    I prefer to think of them as "experience points" rather than commits, because making games should be the meta game. :)

    I also made a page on the website where you can see the commit log.

    I set up a twitter stream for the commits too: http://twitter.com/infinite8bit, and also an identi.ca account if you're that way inclined: http://identi.ca/infinite8bit

    You can subscribe to the RSS feed of those commit messages: http://twitter.com/statuses/user_timeline/121975057.rss

    click for detail

    On my current contract with RjDj I have to work as close to London time as possible, so this means that I have some mornings somewhat free, and I've been spending the hours between 8am and 11am drinking coffee and working on my game.

    As you can see, even at the beginning of this month there have been almost as many commits as there were last month, hooray! There are 37 line-items left in the TODO file at the moment. My rule of thumb is about two line-items per working day. If I can work at roughly 3 half-days per week I should have the beta release ready for testers in about three months. That's assuming that the networking library I previously wrote, PodSixNet, is up to the task of linking everyone together into some kind of platformy MMO goodness. If I do a release without the networking stuff it means I can get something in front of people in probably one month. That's a very motivating thought! The important thing is that I don't rush myself though. Slow software development makes better quality software (although implemented software is better than vapourware).

    I have found that the best way to stay motivated is never to feel guilty about not working on something. If I don't feel like it I just forget about it and do something else. Eventually if the project is worth it I'll get excited about it and naturally come back to work on it again. Judging by the graph, that seems to be exactly what happens. Some months I leave it entirely (zero commits), but over the long term progress continues because somewhere deep inside I know this project is worth it. One of life's great lessons is that at some point we must always let go of the things we love, and I think this really applies to staying motivated about projects too!

    Ok, time to write some more code. :)

    Boring stuff

    Here is the very small bash shell script which produces the csv file used to generate the graph (unfortunately it skips empty months so you have to add those manually):

    #!/bin/sh
    bzr log --short --forward | sed -n -e 's/.*\([0-9]\{4\}-[0-9]\{2\}\).*/\1/p' | uniq -c | sed -n -e 's/\ *\(.*\)\ \(.*\)/\2\,\1/p'
    

    Here is a very small bash shell script that I wrote for turning emails into tweets:

    !/bin/sh
    header="START"
    # concatenate all lines (ignore email header)
    while read line; do
        if [ "$header" == "" ]; then
            message=`echo $message $line`
        else; header=$line
        fi
    done
    # post to twitter
    wget -O - --user=xxxx --password=xxxx --post-data="status=$message" https://twitter.com/statuses/update.xml
    

    That last line is a handy one-liner for posting to twitter!

    To post to identi.ca, change the url to "identi.ca/api/statuses/update.xml".

    ]]>
    /tags/tech Fri, 12 Mar 2010 02:11 GMT
    Something something shapes entries/something-something-shapes http://www.mccormick.cx/news/entries/something-something-shapes

    ]]>
    /tags/tech Wed, 10 Mar 2010 15:14 GMT
    Hong Kong KIRF Lego entries/hong-kong-kirf-lego http://www.mccormick.cx/news/entries/hong-kong-kirf-lego Some "Lego" I bought in Hong Kong at a street market recently. Space Lego + cheapfakes + Hong Kong is pretty much my personal nexus of awesome.

    You can buy this stuff on ebay very cheaply too, and it's compatible with the real bricks. I can't really tell much of a difference in quality. The idea of Lego is too good to be monopolised - I wonder if anyone has tried 3d printing lego parts?

    I am really looking forward to when those "fake" Android phones & tablets start to perform better (and cheaper) than the official stuff. The smart thing about Google's Android strategy is that they benefit from that kind of Wild East tech cowboyism. It's like if Windows 95 had have been Free Software instead of pirated globally.

    ]]>
    /tags/tech Sat, 27 Feb 2010 05:04 GMT
    Non-real objects entries/non-real-objects http://www.mccormick.cx/news/entries/non-real-objects Here are some virtual objects I've been working on, which will soon be fully actualized, real objects that you can hold in your hand. I've sent them off to the Netherlands based Shapeways to be 3d printed in plastic and mailed back to me. I am super excited!

    PS If you like these you can also order them from my Shapeways profile.

    ]]>
    /tags/tech Wed, 17 Feb 2010 15:47 GMT