Live MBTA Data

Our Large MBTA boards are an update to our first MBTA board in many ways, they are larger, show the whole network, and have moved away from updates every minute, to updates every second.

Updating the board every minute is easy, we just make a vehicle location request to the MBTA API, displaying that data on the board’s LEDs. Updating every second is much more complicated, we can’t use vehicle locations anymore (they only update once a minute), so we have to use departure predictions.

We pull departure predictions from the MBTA API, and then cycle through each one, adjusting the LEDs as the trains are predicted to depart from each station. This make the movement on the board look much more fluid and natural, but does have it’s drawbacks.

  • Trains can go faster or slower than predicted, so the LEDs can jump when the next set of predictions come in.
  • Predictions aren’t available outbound for the last stop on the line, as there aren’t any public departures.
  • We don’t know where vehicles are, just when they are supposed to arrive/leave. Because of this we don’t show trains waiting to depart from their first stop, until they are scheduled to depart.

Despite these limitations, being able to see the trains move around the network in real time is much more engaging, and we think it’s a big improvement.

Leave a Reply

Your email address will not be published. Required fields are marked *