I wrote some code for the Novation Launchpad a while back, and I was taking a look at it recently and (of course) couldn't figure out how it worked, so I wanted to start over.  I separated the interaction with the Novation Launchpad into a side project so that I could just grab it whenever.  

Here it is, for reference, if anyone wants to copy it.  The examples are all stupidly simple; the useful part is that the MIDI messages are already parsed into grid coordinates; that was the part I kept wanting to import ^_^

https://github.com/jordanorelli/Launchpad-Examples

-Jordan