Monday, April 27, 2015

The Wheel of (BASIC) Excuses

Back in the day, over at IEEE Spectrum magazine, the editorial elves had a sheet of paper stuck on a wall, with a spinning arm which pointed to any number of plausible excuses for not having handed in homework an article in time.

The offices were renovated last year, and Stephen Cass thought that it was time to update the paper version, bringing it kicking and screaming into the 1980s with a Raspberry Pi-based BASIC system. You can’t fit many excuses on wheel drawn on a sheet of paper. With a big enough SD card, you can fit all the excuses onto a Raspberry Pi.

wheelexcuses1.HandsOnWheel-opener

I remember struggling with getting BASIC to do things fast enough to be useful when I was at school back in the dark ages. The RISC OS version on your Pi is much evolved from the BBC BASIC we knew and loved in (squints) 1980-something; it’s also much, much faster by virtue of all that extra RAM. Stephen was pleased and alarmed by this.

Stephen didn’t put the code for the spinner in his original piece, because he had the aberrant view that nobody would be interested. Happily, he’s fixed that and pasted everything into a comment below his article. (Hit “See more” to view the whole block.)

There are, of course, plenty of non-journalist applications for this snippet of code: games for the kids, allocating chores, automating decision-making…we hope some of you will end up adapting it and letting us know what you did below.

No comments:

Post a Comment