Thought experiment: hacking Siri to control your TV
After a bit of investigation, I had an answer for him, which was "Yes, you could, but no, you probably don't want to." That's because the degree of hacking necessary to make this happen, versus the actual real-world performance, really isn't worth the effort. It might make a cool demo, but not an effective remote control.
The best and most obvious approach would have been to have Siri use URL schemes to trigger a local application on the iPhone, which would then coordinate with a Mac client or directly with Apple TV over Bonjour. Unfortunately, Siri does not allow you to open web pages -- yet. She's quite apologetic about this, but my hope for a URL-based solution was a no-go.
Moving on, I investigated an AppleScript/email-based approach. Cory Bohon wrote up a series of tutorials a while back on TUAW demonstrating how to use mail rules to trigger scripts. You create rules (Preferences > Rules) that match message subjects and contents, and use the "Run AppleScript" choice to choose a script to trigger based on your rules.
This was a much more promising avenue, but Mike and I agreed that the complexity of sending emails via Siri felt more complicated in practice than using SMS texting. I started investigating ways of triggering email rules by SMS. Fortunately, a simple solution quickly popped up: Google Voice.
GV offers the option of forwarding text messages and provides the bonus feature of tagging subject lines with the incoming phone number. This makes it especially easy to authenticate and match incoming requests to Mail rules.
In order to create the control scripts, I would use AirFlick rather than iTunes. I shall spare you the messy details, but I would extend the app to support external pause and play requests.
Finally, you have to set up a contact on your iPhone using the Google Voice address. No big deal. Just make sure you use a name that Siri can easily recognize.
The operational path then works like this: "Siri, text AirFlick 'pause'." You wait for Siri to compose the SMS message. You then send it. The iPhone texts Google Voice. Google Voice forwards the message to your inbox. The mail rule triggers and runs the AppleScript, which causes AirFlick to send a pause command.
The whole latency from your spoken command to your Apple TV actually pausing? Probably under a minute.
As I said, this is a not an optimal approach, but if I wanted to invest a couple of hours I could get it up and working today.
So how close are we now to extending Siri control to our world and to third-party apps? Well, Siri can already pour you a beer and trigger any SMS-based Arduino set-up. But beyond using it for simple triggers, we're still pretty far away from fine-tuned control.
Apple really needs to release a developer API that will provide third-party rules and vocabulary for Siri to follow before we can truly jump into "build your own remote with Siri" scenarios. Of course, by the time that happens the company may simply release a Siri-savvy TV of its own.
Subscribe to Newsletter
Software Updatesmore updates
- iOS 8.0.1 update now available (Updated -- Don't update!)
- NFL Mobile updated for 2014 Season with new Fantasy Football features, NFL Now integration
- Yahoo Mail improves email inbox searching with new filtering options
- Ember for Mac gains 'hugely-requested' screen recording feature
- Spotify update adds equalizer, refreshed Artist page and more
- Fantastical 2.1 for iOS adds new snooze, search and notification features