October 30, 2013

Brain Drain

So over the past two weeks I have been working on a new project: Brain Drain.

If you have known me for a while you're probably aware that I'm a frequent sufferer of headaches. I have even blogged about it here before. Having gone through another pretty bad week I decided I needed something which helps me get a better picture of my headaches. Whenever a headache strikes I want to be able to easily log its occurence and its strength.

I went in the direction of a very basic smartphone app. My phone is rarely very far away, and starting it up, opening the app and taking a measurement is a pretty fast and painless process. So it seemed like a natural solution.

I now have a basic app running, and in its current incarnation it looks like this:


Yeah, not very pretty, and full of debug info. But in bit of a return to the roots of this blog I wanted to actually write about this project as I'm developing it. Which means you'll get to see the nitty gritty details.

At this point the app is usable, I can collect the data on my computer, and I can visualize that data for inspection (I'll show more of that in future posts). There are a few more features on my wanted list, such as adding tags when logging headaches.

I have shared the code on Sourceforge for those who want to take a look. And in any case you'll be able to read more about my progress here soon.

October 28, 2013

It's Behind You

In "It's Behind You" Bob Pape tells the story of how he, mostly by chance, became a game developer, and ended up having to port R-Type (now easily considered a must-have-played classic) to the ZX Spectrum; a job he was not looking forward to. That over thirty years later his port is still considered among the best for that platform is something the author would never have expected. And if you read the book you'll understand why.

Bob includes some technical details to satisfy geeks like me, but he writes mostly about the circumstances leading up to, and surrounding, the creation of the game; and that's exactly as it should be. Allow yourself to be exported back to the early 80's, and get a feeling what it was like to be a junior programmer in those days.

Oh, did I mention the entire story is free to read ?

October 15, 2013

Hidden Variables

Hidden Variables is a small tech blog by Domenic Denicola. You won't find many articles, but what is there is very interesting. The latest post is on the extensible web, which is pointing at some exciting work being done in making the web a more sane development platform.

October 01, 2013

Beautiful Quine

Found this via StackOverflow. The following piece of code is a Quine, and it's amazing:

eval(z='p="<"+"pre>"/* ,.oq#+     ,._, */;for(y in n="zw24l6k\
4e3t4jnt4qj24xh2 x/* =<,m#F^    A W###q. */42kty24wrt413n243n\
9h243pdxt41csb yz/* #K       q##H######Am */43iyb6k43pk7243nm\
r24".split(4)){/* dP      cpq#q##########b, */for(a in t=pars\
eInt(n[y],36)+/*         p##@###YG=[#######y */(e=x=r=[]))for\
(r=!r,i=0;t[a/*         d#qg `*PWo##q#######D */]>i;i+=.05)wi\
th(Math)x-= /*        aem1k.com Q###KWR#### W[ */.05,0<cos(o=\
new Date/1e3/*      .Q#########Md#.###OP  A@ , */-x/PI)&&(e[~\
~(32*sin(o)*/* ,    (W#####Xx######.P^     T % */sin(.5+y/7))\
+60] =-~ r);/* #y    `^TqW####P###BP           */for(x=0;122>\
x;)p+="   *#"/* b.        OQ####x#K           */[e[x++]+e[x++\
]]||(S=("eval"/* l         `X#####D  ,       */+"(z=\'"+z.spl\
it(B = "\\\\")./*           G####B" #       */join(B+B).split\
(Q="\'").join(B+Q/*          VQBP`        */)+Q+")//m1k")[x/2\
+61*y-1]).fontcolor/*         TP         */(/\\w/.test(S)&&"#\
03B");document.body.innerHTML=p+=B+"\\n"}setTimeout(z)')//

A Quine is a piece of code which when evaluated yields its own source code. It's basically a geeky exercise in self-replicating code. Some Quines create a chain of Quines; that is they evaluate to a different piece of code which itself evaluates to yet another piece of code, and so on, until you get back to the initial code. The above Quine is such a chain with an interesting feature: it creates an animation of a spinning globe. Check out the original for full effect.