It’s A Second Life Jim, But Not As We Know It

A few weeks ago I was asked to help move a piano which was being sent to the tip. Now before anyone gets over excited, this instrument had been out in the rain, avoided being scrapped once before and survived toddlers, papier mâché and builders: it was well past saving.

As part of the process of dragging the recalcitrant castors (which to the best of my knowledge have never rotated on at least one corner) across the tarmac and down a steep hill which still required pushing to assist gravity, I ended up adopting the piano’s hammers.

The action of an upright piano is relatively easy to take out, it is simply a matter of undoing a couple of wingnuts, whilst avoiding the glee club of arachnids, and carefully lifting the entire unit out. My prize for this modest undertaking was a massive set of beautifully balanced percussion beaters. This could be deployed to excite almost any object provided it could be struck by the hammers in a roughly upright position, and depending on the size of the sounding thing and the dexterity of the user potentially 88 somethings at any one time.


The problem was, I had no idea creatively what to do with it.

This was just simply one of those opportunities which if not taken at the time may not happen again. So in order to move things along I have tried to consider how I would make it work, so that when the chance to create something artistic with it happens the technical side is already in place. Experience has also shown that often when tinkering with things ideas come to light, but also ideas left un-resolved tend to drift into the background in a world where sedimentation outweighs erosion by a significant margin.

Sitting cross-legged on the floor of the attic, my basic knowledge of pianoforte anatomy was soon vindicated when I found that by prodding the whippen (!) at the bottom of the action with my finger, the hammer bounced obligingly forward. Several minutes later after the novelty had started to wane fractionally it occurred to me that this could obviously be mechanised in some way.

People have been experimenting with automating pianos for a long time. Sitting as I was, it brought to mind the player-pianos much vaunted in films with cowboys in big hats, or for that matter, Muppet satires of such. The problem with this though it that they work very much like a music box or punch card loom in that the musical material is essentially fixed until one physical record of the notes is removed and another inserted in its place.

So, this was an option to try to avoid if possible. The idea of being able to use the action as an instrument, which after all was what it originally was part of, still held a lot of appeal and somehow a piano roll set-up felt like it would reduce it to some sort of playback device. No matter how expressively you nuanced the predetermined material it would never be something that as a person you could play in any reactive sense.

Starting very simply I tried fiddling around with a servo motor, using it as a robotic analogue of my finger, changing how far it moved and how quickly by way of a simple controller chip and becoming terribly overexcited when I found that it had enough force to easily achieve the task of banging something with a (piano) hammer. Emboldened by this small success I then set myself to the task of scaling up the project. After all, it did not really matter how nice the sound was that the one servo hammer was actuating, within a while it would get perniciously dull.

Seeking out more servo motors I wired them in, duplicating what I had done for the first one, because it had worked. In order to test this new set up I needed something that would be relatively simple to do but was sufficiently detailed to show up any errors or inaccuracies. As a simple starting ‘riff’ I tried the melody from Piano Phase by Steve Reich.

I set up the chip to run playing the loop through the servos, with one chip doing the locked in piano part and the other one doing the part of the instrument which accelerates. The process behind the 18 minute video could be boiled down to a few lines of code, defining notes to the servos, linking them to pins, saying how many times to loop and arranging the order and length of notes in the loop.

Servo E;
Servo Fs;
Servo B;
Servo Cs;
Servo D;

void setup() {

void loop() {
for (int x = 0; x < 4; x++) {
for (int x = 0; x < 4; x++) {
void note(Servo pitch, int duration) {
void atempo() {
note(E, 147);
note(Fs, 147);
note(B, 147);
note(Cs, 147);
note(D, 147);
note(Fs, 147);
note(E, 147);
note(Cs, 147);
note(B, 147);
note(Fs, 147);
note(D, 147);
note(Cs, 147);
void accel() {
note(E, 144);
note(Fs, 144);                                          //etc……

Running the two separate ‘pianos’ on two separate chips created something of a problem, as, gradually over time the chips could without any sense of irony fall out of synchronisation, let along the difficulties of starting them off in time initially. So it was with deep regret that I realised I that the simplest answer would be to combine the 2 time streams on a single processor.

There may be people out there who have figured out how to run 2 separate asynchronous loops on a single Arduino chip: sadly I am not one of them. However having sat down with a simple spreadsheet I figured out that if each semiquaver lasted 147ms I could make the ones that get quicker to shift the phase 3ms shorter and that would mean that the music shifted by 1 semiquaver over the accelerated 4 bars to lock back into metrical sync. Sadly the chip I have only reliably works in whole numbers of milliseconds so the ratios are relatively critical, but it did mean that with a little bit of Excel spreadsheet automation it was possible to manufacture the entire piece (phase shifts and all) pretty simply. You can see the link for the full code if you are really interested!

I am still left at the stage of the piano roll, but we are moving forwards. Time will tell as to how I can make the actual material grow and evolve and what sounds and objects will be brought into life through it, but it is shaping up to be great fun 🙂


One thought on “It’s A Second Life Jim, But Not As We Know It

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s