Monday, 12 January 2015

Flying a Drone in the Royal Institution Christmas Lectures

In December 2014, the first cohort of FARSCOPE Centre for Doctoral Training students developed an automated drone cymbal player to take part in an RI Christmas Lecture.  FARSCOPE Director Arthur Richards reflects on the experience.

The Royal Institution approached Bristol Robotics Lab in November 2014 to ask if we could contribute a drone to their robot orchestra project, inspired by this YouTube video and others.  The brief was quite broad: get a drone to play something somehow.  We agreed to investigate and see what we could do.  In particular, we made this a "crash project" for the new FARSCOPE students, perhaps a poor choice of term under the circumstance, but highlighting the emphasis on simplicity and timeliness of whatever we came up with.

Drones are tough to control with great accuracy, so we quickly narrowed our ideas down to percussion.  My personal, and slightly ironic, wish was to have a drone play the triangle This urge was quickly subdued, both by the drowning of the triangle sound by the motor noise, and the alarming response of the drone when affixed with a beater and flown into a triangle.  It was clear that some sort of transmission would be required to strike the instrument.  Electrical transmission was ruled out, as we wanted it to be obvious that it was really the drone making the noise.  Therefore, we had a requirement for a mechanism that would convert some motion of the drone into motion of the beater striking the instrument.

CDT Student Dave wheels the drone kit into the Faraday Lecture Theatre
Around this point, I started to have unsettling thoughts about a drone flying into a live audience of youngsters, never mind in front of TV cameras.  Consultation with the production team indicated that a perspex shield would give reflection problems, and our ideas for cages made fishing wire just seemed pretty outlandish.  So, the drone would have to be tethered.  This neatly solved the mechanism debates as well, as the tether would serve to actuate a beater.  So, with a few weeks to go, we had a concept: a drone tethered to a pivoting arm, which would crash into a cymbal when pulled upwards.  All this could be mounted on a trolley, conveniently also serving as transport and landing pad.

Meanwhile, other details had been falling into place.  Students had been building QAV250 quadrotor drones and equipping them with Naze32 flight stabilizers.  These turned out to be excellent machines, mechanically robust, well-stabilized, and easy to fly for beginners, so very suited to our needs.  Some Arduinos were programmed to take commands from our ROS environment and convert them to PWM streams for the trainer port of our radio transmitters, with an added emergency stop functionality.  With our Vicon motion capture system tracking the drone, we were able to close the loop.  One day we may share the radio control bridge and PID tuning packages with the ROS community, but it's the nature of crash projects that things aren't done as tidily as they could be.

Students put finishing touches to the drone landing pad in the RI library
With a van full of spare drones, computers, markers, cameras, tools and fishing wire, we headed to London for the first of two long days rehearsing and filming.  With plenty of practice in the lab and enough spare kit to do the whole project twice, we would be confident, but nevertheless the first successful cymbal clap when hooked up to the orchestra was a great relief all round.  As so often in robotics, the thing that came closest to stopping us was a flaky network.

One surprise was yet to come: the producers liked the drone so much they wanted to make more of it, so we quickly contrived a demo for it to follow an external target.  For comedy reasons and as a nod to the computer vision world, it had to be a teapot.  It's a great credit to the students involved that an extra function was written into the software at about an hour's notice, but that went on to work beautifully.

FARSCOPE students at the control station, backstage at the RI.
You can see the finished product late on in the video at the RI Channel: Sparks Will Fly: How to Hack Your Home  For the cynics, there was absolutely no cheating involved.  There was a manual transmitter out back but it was never used during filming, and the only manual intervention was me pressing the button to land the drone, giving lecturer Danielle a bit of a fright.  (Ground effect when the downwash hits a surface makes it hard to fly a drone very low and keep it tightly controlled - you're better off just cutting the power once low and slow.)  Everything you see in the video is genuinely automated, with students pressing only a start button and switching the teapot tracking on and off.

So what do we learn from all this?  Drones will clearly not be great musicians in the near future.  Still, the students learnt a wide range of practical skills through this exercise, from ROS use to drone construction.  Time management, teamwork and the importance of testing were also reinforced, although this was far from a good model of systems engineering.  Finally, it was great for those of us running FARSCOPE in its first year to explore the flexibility and responsiveness that the Centre for Doctoral Training gives us.

No comments:

Post a Comment