Maps Platform
Product updates, customer stories, and tips and tricks on Google Maps Platform
Google Maps API for Flash at Progressive Insurance Automotive X PRIZE
Friday, July 23, 2010
The following is a guest blog post by Kevin MacDonald of ThinkWrap Solutions
We're coming to you live from the Michigan International Speedway, where the Progressive Insurance Automotive X PRIZE (PIAXP) competition is underway.
This competition will award $10 million in prizes to the teams that win a rigorous stage competition for clean, production-capable vehicles that exceed 100 MPG energy equivalent (MPGe).
Vehicles are equipped with telemetry sensors and a GPS that together capture the following key performance indicators (KPI): fuel consumption, CO2 emissions, carbon footprint, speed, distance travelled and location.
ThinkWrap Solutions partnered with PIAXP to build a web experience that lets you monitor these KPI -- second-by-second -- from the comfort of your web browser.
The web-based experience is centered around a dashboard, a Flash application that embeds a number of telemetry gadgets, each responsible for the display of one KPI.
A Google Map is central to this experience, which uses a combination of location and horizontal dilution of precision (HDOP) to show the vehicle's movement around the track.
It's quite a novelty to be present at the Speedway, to watch the vehicle's icon round a turn on the map -- and then look away from the browser and to the track to see the actual vehicle approach and pass by.
To enjoy this experience, visit
the official website
,
to meet the teams and their vehicles. (Check
this video
to see the map and telemetry data in action.)
Race times and vehicles are updated daily and posted at
this page
. Click on one of the vehicle photos on this page to view its telemetry data, and track its progress as it races around the racetrack, live on a Google Map!
Challenges
Our first challenge was to make sure that the map accurately tracks the vehicle's movement around the track. Although a GPS reports latitude and longitude coordinates to a precision of a few feet, availability of GPS satellite signals and atmospheric conditions can affect coordinate accuracy. Without concern for this accuracy, the map might show a vehicle hopping around the track, up on to the stands, over the stands and into a nearby farmers field!
We all know that GPS coordinates include latitude and longitude. GPS also measure the accuracy of these horizontal coordinates through a metric called Horizontal Dilution of Precision (HDOP) which for us, varies from 1 to 50 (1 is best and 50 is worst).
The map plots the coordinates on the map only if HDOP is 3 or less. If it's greater, the vehicle icon does not move. After 30 seconds, the icon is removed from the map.
Another challenge was to economically satisfy the clients' real-time demand for data, especially under conditions where a media blitz attracts tens or hundreds of thousands of visitors. Data flow -- from vehicle to website -- involves many intermediate stages: each vehicle independently broadcasts its KPI through a Sprint cellular connection, second-by-second, to a central server. Every second, this server batches KPI records across all reporting vehicles, and pushes, as a POST request, through a REST interface to a Java-based server running on Google App Engine. This server then caches the data in memory, and stores a copy in Datastore.
Client applications, which display the dashboard, poll for new data from Google App Engine through another REST interface. If the request hit the servlet that originally received the KPI from the vehicles, the request is serviced from a cache. Otherwise, the servlet needs to
query the Datastore, cache the data and then reply to the client.
The client receives a batch of KPI data for the last 10 or so seconds, which it plays back through the dashboard, one record per second. When the client's buffer is nearly empty, it requests another batch of new data and continues, rinse-cycle-repeat.
Although the clients play back KPI data from a few seconds ago, collectively, they place much less burden on the server, and maintain sufficient buffer so as to minimize interruptions when updating the map.
We built our map on the
Google Maps API for Flash
platform, primarily due to the maturity of its
software development kit (Flex Builder), relative ease of development, and cross-browser support.
Enjoy!
Posted by Kevin MacDonald of
ThinkWrap Solutions
Labels
5 Great Maps
ads
advertising
africa
Andorra
Android
App Engine
art
Australia
Autocomplete
Boston
brazil
Bruce Springsteen
Bulgaria
Campus Map
Chrome
City 24/7
Code for America
COM API
Computerlogy
creative advertising campaigns
Custom Map Types
design
developer
Developer Challenge
Developer stories
Directions API
Drawing Tools
Driving Directions
Earth
Earth API
Elevation API
environment
epungo
Estonia
Europe
Fab Friday
flash
Fusion Tables
GAE
games
GDAL
Gears
geo
Geodesic Lines
Germany
Gibraltar
GIS
Global Economy
gme
Google Analytics
Google App Engine
Google Earth
Google Earth API
Google I/O
Google Maps
Google Maps API
Google Maps Engine
Google Places API
Google Places API Developer Challenge
Google Street View API
government
Hackathon
Hamburg
heat map
heatmap
hiking
Hungary
iOS
JavaScript
jQuery
kenya
KML
Latitude API
Latvia
launch
Lithuania
local search
London
Mac
Map of the Week
maps
Maps API
Maps API for Flash
Maps Data API
Maps Zen
Marker Clusterer
Marketing
Mars
meetup
mobile
moca
modern art
More Than a Map
Morethanamap
Movies
Neighborhoods
New York City
Office Hours
Olympics
Panoramio
photos
Place Summaries
Places API
Plus
polygons
Premier
public transit
public transit layer
Python
real estate
rock
sao paulo
screencast
SketchUp
Slovakia
Slovenia
South Africa
Spain
Spatial Data Files
Static Maps API
street view
Styled Maps
Sydney
Track
traffic layer
Transportation
Tripline
Twitter
UN
United Nations
V3
Vancouver Olympics
visualizations
Volkswagen
VW
web
youtube
Archive
2018
Nov
Jul
Jun
May
Mar
Feb
2017
Nov
Jun
May
Apr
Mar
Feb
Jan
2016
Dec
Nov
Oct
Sep
Aug
Jul
Jun
May
Apr
Feb
2015
Dec
Nov
Oct
Sep
Aug
Jul
Jun
May
Apr
Mar
Feb
Jan
2014
Dec
Nov
Oct
Sep
Aug
Jul
Jun
May
Apr
Mar
Feb
2013
Dec
Nov
Oct
Sep
Aug
Jul
Jun
May
Apr
Mar
Feb
Jan
2012
Dec
Nov
Oct
Sep
Aug
Jul
Jun
May
Apr
Mar
Feb
Jan
2011
Dec
Nov
Oct
Sep
Aug
Jul
May
Apr
Mar
Feb
Jan
2010
Dec
Nov
Oct
Sep
Aug
Jul
Jun
May
Apr
Mar
Feb
Jan
2009
Dec
Nov
Oct
Sep
Aug
Jul
Jun
May
Apr
Mar
Feb
Jan
2008
Dec
Nov
Oct
Sep
Aug
Jul
Jun
May
Feed
Follow @GMapsPlatform
Follow
Google Maps Platform Website
Give us feedback in our
Product Forums
.