Syncing Car Telemetry Data in Real-Time: Ford's OpenXC API and Cloudant's Traffic Tamer App

By Norman Barker

The London Traffic Challenge

OpenXC is a combination of open source hardware and software that allows developers to read car telemetry data in real time. This work is being led by Ford.

OpenXC software is primarily focused on Android developers and uses a bluetooth or USB connection. As part of the London Traffic Tamer App Challenge, Cloudant developed a HTML5 Chrome application that used WebWorkers, the Chrome TextToSpeech engine, the Leaflet JavaScript library for interactive maps, and PouchDB, the in-browser database that syncs.

The goal of the contest is to design applications to help alleviate traffic congestion on the streets of London. We call our app "Cloudant's Traffic Tamer."

Create a free Cloudant account and get coding in minutes

About the App

Our Traffic Tamer app collects car telemetry data. Every time a car stops, this event is synchronized with Cloudant to enable crowd-sourced traffic information.

Every 5 minutes, the application executes a server-side geospatial radius search, and congestion alerts are sent to the device. To avoid distractions, this alert is spoken to the driver. In development mode, Leaflet is used to display a map of the driver's location and path.

The app was designed for low bandwidth / offline usage. Everything is stored locally in the web browser (PouchDB). Vehicles have spotty mobile connectivity while in transit, so we designed the app to transmit only lightweight, individual JSON documents over the network in this scenario. The entire database is only synchronized with the cloud (Cloudant) when the user has a Wi-Fi connection. Synchronizing the entire database allows analysis of driving patterns to provide route recommendations.

We chose Chrome as an application technology because:

  • It works offline
  • It can run in the background
  • It can read USB devices
  • Text-to-speech engine
  • Can run on any device
  • Easy deployment on Chrome Web Store

Using the Code

The code is available on GitHub under the Cloudant repo openxc-js and is licensed under the Apache 2.0 Software License. A vehicle simulator has been provided that runs a WebWorker thread and updates the development display.

The OpenXC Platform provides car telemetry data on a line-by-line basis, and this data is JSON, e.g.


The application aggregates this data, and every 10 seconds stores it into PouchDB as GeoJSON, e.g.

  "geometry": {
    "type": "Point",
    "coordinates": [125.6, 10.1]
  "properties": {

N.B.: As per the GeoJSON spec, the "properties" field above could contain any number of nested telemetry objects, such as those given in the preceding code block.

This can be seen in the Chrome Development Console:


The application can be installed from the Chrome Web Store here


Vote for Cloudant's Traffic Tamer App

Please vote for our submission by following this link and clicking the red "VOTE" button. The video walkthrough of our submission to the contest is also reproduced here below. Thank you for giving it a look.

Sign Up for Updates!

Recent Posts