Microsoft mobile scripting platform ON(x) is a game-changer

Microsoft announced today a new mobile scripting platform which they're calling ON(x), pronounced "onyx." ON(x) isn't just making apps easier to develop, it's a real game-changer, in that it makes some very sophisticated technology available to app developers that until now they've had to develop themselves.

ON(x) was presented briefly at the Think Next 2012 event hosted by the Microsoft Israel R&D center.  It's scheduled to be available in the summer.

In a nutshell, ON(x) enables scripts to be invoked based on a huge variety of trigger events.

ON(x) scripts are built using a visual editor, where the user defines the trigger actions on which a script is run and the action which is carried out.  Examples include things like "when my wife sends me an SMS that says 'where?' send her back an SMS with my location.

Behind the scenes, these triggers/actions are turned into JavaScript code, and users can edit this JavaScript to customize either the conditions or the actions that are taken.  To the right we see a sample script that reminds the user to buy milk when they get close to home.  The JavaScript shows aspects of this trigger and action that can be modified by anyone who wants to edit the script code.

I think, however, that the real magic of ON(x) is the sophistication that Microsoft has built into the trigger events.  These trigger events include the obvious events, like incoming calls or SMSs, or new Wi-Fi networks or Bluetooth devices in range.  But they also include triggers that are much more sophisticated than the usual OS-level triggers, like geofencing and motion analysis.

Geofencing is the technology underlying location-based reminders - the ability to trigger a script when the phone gets to within a given distance of a known location.  For example, I may want my phone to alert me when I'm within a half-mile of my local drugstore, so I can buy band-aids.  Or I may want a wake-up alarm when I'm on the train and get to within 5 minutes of my station.  There are apps that do this, but it's very hard to do well - if an app checks GPS every minute, it'll drain the battery, but if it checks every hour it'll miss the alerts.  Serious location-based reminder systems take a sophisticated approach to geofencing, such as calculating the earliest that a given alert might be relevant based on the user's current location and likely travel speed, to minimize battery drain.  By taking geofencing and making it part of the platform, Microsoft is taking the responsibility for all this sophistication, and letting apps work on the functionality and user interface.

Microsoft has some serious research in this area, including a patent on calculating travel time (see flowchart) to determine when to next check the device's location, and including more general research on finding nearby ways to take care of goals that the user has.  We don't know whether this research was implemented in ON(x), but it doesn't really matter.  Regardless of the details, it's game-changing for app development nonetheless, because script developers can worry about the end-user functionality and leave the geofencing complexities to Microsoft.  We do know that Microsoft implemented ON(x)'s geofencing to minimize battery drain.

Many other companies are researching this area as well.  Apple has research in using real-time traffic reports to guess how long it was take to reach a given location.  And a Symbian app called WakeUp reminds a user when they're approaching a given location based on how fast their train is traveling. More details on research in this area is available in this report.  But by embedding this technology into a scripting platform, Microsoft is opening it up to a myriad of new applications.

Another sophisticated trigger event that ON(x) supports is "mode of transport detection," where a phone's accelerometer is used to detect whether the user is walking, running, driving, etc.  Scripts can then be activated when the user's mode of transport changes, e.g., to do whatever the user wants done while driving or running, like raising the ring volume and automatically activating the speakerphone.  Microsoft has some research in this area, but interestingly, Google appears to have some very sophisticated related research (shown on the side). We assume that the Microsoft researchers have come up with novel methods that avoid a patent conflict with Google, and more importantly, again, by releasing this technology within an app platform, they're opening it up for any app developer to leverage.

From a business standpoint, Microsoft has made a great decision to release this not only on Windows Phone, but also on Android and other phones.  By putting this out for general purpose use, they're enabling a wide range of apps to leverage their technology and correspondingly to tie themselves in to Microsoft.

Note that there are other mobile scripting platforms out there, including Android Scripting system and the PyS60 Python for S60.  But neither of these currently has serious support from a major company.

We look forward to ON(x)'s release, to seeing the sophisticated uses that app developers come up with, and also to seeing whether competing platforms can release such sophisticated technology for all to use.

Way to go Microsoft!


  1. nice posting.. thanks for sharing.

  2. Extremely useful information particularly the last part I care for such information a lot. I was looking for this certain info for a long time. Thank you and best of luck..