Holiday time - bulk declining Google Calendar events

I’m getting married in a few weeks, so recently I wanted a way to decline about 3 weeks worth of Google Calendar events en-masse. Since I was using Google Apps for our organisation’s calendar, I found the easiest way to accomplish this was to bust out some Google Apps Scripting, which lets you script a number of Google Apps in your domain, including the [Calendar](

See an example below on how to bulk decline Google Calendar events using Google Apps Scripting - you’ll just need a calendar name & a date range and run this via the script console:

function GCalHoliday() {
var fromDate = new Date('July 17, 2017 00:00:00 +0100');
var toDate = new Date('August 8, 2017 23:30:00 +0100');
var calendarName = '<Your Calendar - e.g.>';

var calendar = CalendarApp.getCalendarsByName(calendarName)[0];
var events = calendar.getEvents(fromDate, toDate, {});
Logger.log('Events: ' + events.length);

for (var i = 0; i < events.length; i++) {
var ev = events[i];
// try/catch for setting status - may get exceptions where events
// are on calendar, but user is not a "guest" of the event - these can be ignored
try {
// !!!
// ev.setMyStatus(CalendarApp.GuestStatus.NO); // Uncomment to actually update status
// !!!
} catch (e) {
Logger.log('Error updating event status ' + e);
Logger.log('Item ' + ev.getTitle() + ' found on ' + ev.getStartTime() + ' marked as declined');

High Altitude Adventures - Part 3

A few weeks ago, I was mostly ready to launch. We’d bought an N30 cylinder of Helium from Irish Party Supplies, containing 7.82m³ of Helium - enough for roughly two launches of a standard sized 1000g balloon. Previously, I’d thought hydrogen would be a better choice, but considering it was a first launch we decided to play it safe (after having a gas seller painstakingly explain the various ways in which Hydrogen tanks can explode).

I’d also figured out the legals - the IAA didn’t seem to be able to grant permission to anyone other that Met Eireann, so rather than labour the point I decided to launch from Northern Ireland instead. I’m still not entirely sure if launches here are legal or not, but the IAA, who regulate our skies didn’t seem to be in a position to grant permission. The CAA in the UK have a procedure for weather balloon launches. So long as you heed their guidelines (which are very sensible), you have an excellent chance of being given permission. There also didn’t appear to be any issue with me being an Irish resident.

Frequently checking the CUSF Landing Predictor, I finally happened upon a good weekend at the end of June. The winds were calm and a predicted landing that wasn’t in either the sea or a lake - all good! I contacted the CAA at short notice for permission to launch, and they were very helpful and prompt - I received permission documentation the following day.

2013-06-28 15.44.08

My payload was complete - I’d bought a 42 inch Spherachute and a 1000g Hwoyee weather balloon from the good people at Random Aerospace. I’d also sourced a small polystyrene payload box. For recording 1080p video, I finally settled on the excellent Veho Muvi HD - the video captured turned out better than I’d ever imagined.

2013-06-29 14.34.38

The launch was a great success, with most things working as planned. The vertical radiator of the antenna broke off while we quickly tied off the balloon after filling.

2013-06-29 14.41.09

2013-06-29 15.00.04

I thought this would mean we wouldn’t get any live telemetry during the flight. But as it turned out, because the balloon was high above the horizon with no obstacles in the way, the transmitter’s weak 10mW signal was received clearly throughout by us in the car with a little handheld receiver as we chased the balloon.

While chasing, however, it become obvious that the GPS on board was not receiving updates, presumably because it had no lock. Although live telemetry was transmitted throughout the flight, without GPS data it wasn’t particularly interesting - the altitude was stuck at 4km. I’m still not entirely sure what failed, but my guess is that the active GPS antenna I used wasn’t working. The antenna was placed at the top of the payload box, which was quite close to the underbelly of the balloon. We’d tied things off quickly, so there was only about 6m between the payload box, the parachute and finally the balloon. I’d stowed a backup GPS tracker on board with GSM (redundancy!) which I’d hoped would give us a landing location in cse the primary tracker was no longer functional. I was able to call the GSM modem in the payload until sometime after the GPS lost it’s lock (~4km up), which was higher than I thought.

Two and a half hours after launch, with the payload still transmitting the same 4km, I was able to call the payload once more - which meant it was descending and was close to landing. After about 30 minutes of frantic texting “where” over and over to the payload box, it finally responded with it’s actual location. After landing, the GPS had regained a lock. The backup tracker refused to give us it’s location throughout, presumably (I thought) because the payload box had tipped over. We raced towards the field where it had landed only to find that it had landed with some very curious cows. Eventually, after concocting a distraction, I managed to hop the gate and recover our payload - all in tact and still working.

2013-06-29 19.24.35

2013-06-30 07.35.40


Source for the Arduino Mega, Siemens TC35 serial GSM modem, RTTY transmission via the NTX2 is available here

South East Maker Space Presentation

The good folks at the South East Maker space (@semakerspace) invited me to talk about this recently. Slides are available here.

High Altitude Adventures - Part 2

Following on from my previous post, I’m going to go into a little more detail as to what we’re planning and what I’ve built so far - hopefully it will be of interest!

The payload (or safeload as I’m now calling it) is now complete. It consists of:


It took a while to piece together the kind of parts I needed. I originally thought I could use an old Arduino Diecimila that I had lying around, along with a nice EM406-A GPS module that I’d used before. Unfortunately, the Diecimila only had 16KB of flash (2KB taken by the bootloader), and it looked like I’d need at least 32KB.

I bought an Uno and initally everything was going well - I had the EM406-A hooked up and was processing NMEA with relative ease, thanks to the great TinyGPS library. The NTX2 arrived a little later - this is when the problems began.

Software Serial Ports

I planned to transmit telemetry throughout the flight with the NTX2. To do this, I was going to use RTTY (simple frequency shift keying) to encode telemetry and transmit. This worked fine in isolation, so I then hooked up the GPS again and tried to send some telemetry. There were weird errors in the RTTY transmission that I spent a few days tracking down late at night. The problem in the end turned out to be the SoftwareSerial port I was using.

Uno’s only come with one hardware UART, and it’s wired into the USB port via FTDI. It was available to use, but it’s fiddly and it’d mean swapping things around when it came to programming over USB (which I needed to do a lot of, since nothing worked!), so the EM-406A was hooked up via a software serial port. Arduino’s SoftwareSerial is interrupt driven so NMEA data coming in on the SoftwareSerial port would trigger an interupt - RTTY transmissions are timing sensitive, so these interrupts interfered with transmission and introduced errors.

Once I’d figured out was going wrong, disabling interrupts and having a “quiet period” for RTTY transmissions seemed to mostly fix things. Half way through uncovering the fix, however, I got frustrated and ordered an Arduino Mega (which has 4 hardware UARTs). When the Mega arrived, things got a lot simpler - lots of complicated timing logic could be removed.


I’ll post more about this later, but here’s a short video of an RTTY transmission of some telemetry:

High Altitude Adventures

A few weeks ago, I spied a video on YouTube via Reddit - some guys had gotten together and put some cameras high up into the atmosphere (100,000ft, ~30km). I looked at it and thought it seemed like a good use of time. I got talking to a friend of mine at work about the possibilites of launching something like this from Ireland. As it turned out, some people from launched successfully from Kerry a few years back.

My initial plan was to launch something simple: a helium filled 800g balloon with some kind of cheap Android phone taking snaps every now and then. After watching lots of YouTube footage, and lots scouring through resources such the UK High Altitude Society, our plans evolved. Dan was keen for a more elaborate payload (it involves a fixed wing glider, some servos and a death spiral - I’m sure he’ll tell you all about it). Eventually we settled on the idea of sending two payloads on one flight.

Initial Questions

One of the first things that I wanted answering was whether or not it was actually legal to launch a high altitude balloon in Irish airspace. As it turns out, the IAA have a pretty comprehensive document on the subject here. I’ve yet to receive permission to launch from them, but I am hopeful.

Update: the IAA were very firm in giving a “No” to any such launch. Apparently they’ve only ever given permission for such launches to Met Éireann. Disappointing, but the CAA in the UK granted me permission to launch in Northern Ireland and were far more helpful.


In the first few days, with some whiteboarding during lunches and late night conversations, we came up against some issues.

  • Initially, Android devices looked like a good idea for simple flight computers. We had some ideas to develop some FeedHenry powered Apps to record and relay basic telemetry to a Node.js app - we’d use WebSockets to pipe data back in realtime. Knowing how flakey your average cellular data network is, I had my doubts this would work. A bigger problem, though, was that GSM was unlikely to work at anywhere near the altitudes we were interested in.

  • We largely started out with no idea of how much this was likely to cost. Our guestimates of maybe €200 each were blown in the first week of parts acquisition (for me at least).

Lifting Gas

Helium looked like the best lifting gas, since it was inert and it’s relatively cheap. Or it was - this isn’t the case anymore. Poking around, we found many places offering balloon helium for party balloons. This, as it turned out, wasn’t good enough for our purposes. Your average party balloon gas is only about 30% helium - the rest is usually air. We’d heard some estimates from others that 9cubic meters of industrial helium from BOC costs about €600 (including tank rental) - which is pretty extraordinary.


Way back in November, 2008, I read an article by Tom Preston-Werner which detailed his approach to blogging and blogging software. For years I’ve been trying to use one terrible CMS or another. The idea of sitting down to write yet another CMS to tackle some of the issues I have with blogging software really didn’t appeal to me. Remembering his article, I started poking with Jekyll. I had a pretty good idea of what I wanted:

  • Simplicity
  • CLI-based editing
  • Posts in a plaintext format, with formatting in a really lightweight
    markup language like
  • Static content generation - if you post something popular, chances
    are you’re going to start flushing “dynamic” content out to disk as
    static HTML. Why bother waiting to write posts out as static files?
  • No comments — as far as I’m concerned, the effort required to manage
    spam and user comments simply isn’t worth it.

Irish Weather app live on the App Store

I was bored three weekends ago and had an idea for a simple Irish weather app. Met Eireann have tons of great data available to the public, but finding the good stuff was a little fiddly. Anyway, after a weekend of work in Photoshop and Xcode, I had a pretty nice app. It was finally approved late last night. It’s free to download, so feel free to give it a spin.

Irish Weather 1.0

The day a Time Capsule died

This is the first Apple product I’ve owned that’s died. The hard drive seems to be fine though. Plugged it into another machine and it works just fine. I guess all that heat killed the logicboard. I guess it had been warning me with a few months though - its DHCP server had become very flakey over the past few weeks.

Oh well, time to dust off my old dependable WRT54GL.

Node.js - Event driven, non-blocking web servers written in JavaScript

Update - 2015-09-11 while porting posts: This Node.js thing turned out to be a pretty big deal

I’ve been fiddling with Ryan Dahl’s Node.js event driven I/O framework for the V8 JavaScript VM over the past couple of days. It’s probably the coolest piece of software I’ve come across in ages, and it really builds upon one of JavaScript’s core strengths: event driven programming. If you’ve been looking to brush up on your event driven programming, it’s seriously worth taking the time to play with. As part of his work on Node, Ryan has also released a seriously cool tiny HTTP parser in C (and used by Node). At 128 bytes per connection, it’s perfect for use in any embedded environment which could do with some HTTP love, like the Arduino.

Bluetooth/USB tethering & MMS for O2 Ireland with iPhone OS 3.0

Update #2: These carrier settings will work with Beta 2 also. Also,
Safari likes to attach a .zip extension to the ipcc, so either rename
the downloaded file minus the extension or use Firefox/curl something
else to download the updated carrier settings.

Update: Updated the MMS proxy settings, the previous version was using
an old proxy. To update just re-download the carrier settings and apply
an update once more.

After a little dicking around prompted by some stuff I noticed on
twitter, I cobbled together this updated carrier bundle for O2 Ireland
to enable USB/Bluetooth tethering for iPhone OS 3.0. This also enables
the sending/recieving of MMS messages a new photo button will appear in to send pictures as MMS messages.

Grab it here.

To install, option (alt) click update in iTunes, and select this updated

If something terrible happens, you can grab a backup of the old one to
restore here.

Trip report - fowadublin

I attended FOWA Dublin Friday last, and had a pretty good time. The
speakers were the main reason I attended, with DHH & Simon Willison
delivering particularly great talks. There were a couple of things that
bugged me about the event setup. Not to be a jerk or anything, but
there’s a few points I hope the
Carsonified guys take a look at and
fix in time for next year:

  • Poor WiFi - I know the guys have apologised about this already, but
    it stuck in most people’s craw and I guess it bears repeating. With
    400 odd people milling about with iPhones and Macs some decent WiFi
    would’ve been nice.
  • Socialising is kind of hard when you’ve got absolutely no room to
  • I don’t really care about toilets, but I heard there was only one
    bathroom for guys and one for girls.
  • Lack of freebies. The tickets were pretty pricey (although I’d guess
    individuals paying for their own tickets were in the minority).
    Basically the only thing given away was a name-tag & holder. Free
    coffee for breaks or something would’ve gone down nicely.