What is this site?

This site is just a little experiment in Web 2.0 mashups. Starting with an XML feed of state-wide traffic incidents from the California Highway Patrol at http://media.chp.ca.gov/sa_xml/sa.xml we pull out local incidents and build on them.

Hopfully the result is something useful.

What can I see here?

First we display local incidents and their details then we map them using Google Maps. We try to use the location information included in the incident but if it's not their, we'll geocode it manually.

Area-wide advisories and media alerts will also be displayed "banner-style" across the top of the site.

Then we add Google's support for traffic condition overlays so you can see at-a-glance area traffic conditions.

We also provide an RSS feed of all the active incidents that is customizable to show specific streets or even a set of streets. You can customize it to, say, your commute streets and get updates of traffic incidents along your commute while at work.

But wait, there's more! There's a Twitter feed as well. You can get updates virtually live as they come in. Using the Twitter 'track' feature you can get traffic updates for the street or freeway of your choice as well.

We also have live video from both Cal Trans and the Department of Transportation too. Now you can see traffic too.

Can I build on your work?

Of course! The JSON data for every CHP "dispatch" is located here: http://www.sactraffic.org/json/ -- where http://www.sactraffic.org/json/STCC-STCC.json is the data for the Sacramento area.

I also have a JSONP hook set up through http://www.sactraffic.org/jsonp.php. Simply pass a callback and a dispatch argument and go nuts.

Here's a jQuery example:

$.getJSON("http://www.sactraffic.org/jsonp.php?dispatch=STCC-STCC&callback=", function(data){ // do stuff... }); });

Feel free to use them as you see fit. If you do, let me know if you come up with something cool.

You can be reached where?

I'm "sactraffic" at this domain.

What's next?

I dunno. Perhaps an alert setup for CHP "sigalerts"? More cameras? I'd like to get real graphic icons for the various incident types to display on the map.