I noticed that few cities provide a bus map for smartphones. As a result, tourists usually resort to just taking the subway instead because it's easy to figure out, although riding a bus is a better way to discover a city.

I was wondering what tools are available to write a smartphone application (Android and iPhone) that would do this:

  • Show the whole bus network
  • Allow the user to point their current location (or get it from GPS, if available), then point to where they'd like to go, and display the different bus lines they should take to get there.

Does this require extensive computer knowledge to write?

Thank you.


Short answers is yes, it takes a decent amount of knowledge, both of software development and transit systems, to create this type of system from scratch. You have to obtain, process, and continuously update data for the transit system (at least scheduled data, most likely in the General Transit Feed Specification (GTFS) format). If you want to do end-to-end routing, in addition to displaying the transit system, you'll need street/sidewalk data (most likely from OpenStreetMap.org (OSM)). Additionally, if you want to suggest the best path, you would have to handle time-dependent routing due to the bus schedules, and determine if its faster to wait for a given bus or bike/walk to another location to take a different bus - not nearly as simple as traditional shortest-path algorithms (e.g., Dijkstra, A*).

Luckily, there has been a lot of work in open-source software to perform these tasks over the last few years. The OpenTripPlanner project does multi-modal routing (transit/bike/walk) and uses GTFS and OSM data. We built an Android client for OTP that is also open-source.

So, I'd suggest working with / enhancing the above systems rather than starting from scratch.


These could be easily deployed with an API provided by a transit network. I.E. Los Angeles Metro System provides an API for real time bus locations via ajax call. This could be appended to your personal web map of choice in a mobile or desktop environment.



I can't yet add a comment, but this info below may be useful addition to Sean Barbeau's answer.

The first part of the problem is to get a published bus network data including locations of bus stops, routes and schedule arrival/departure times into a computer readable format. Some common standard data format are:

  1. GTFS is a common bus network data format used in US and elsewhere.
  2. TransXChange is a UK nationwide standard for exchanging bus schedules and related data.
  3. Neptune is Norme d’Echange Profil Transport collectif Utilisant la Normalisation Européenne a French bus network data format.

Many bus operators now supports GTFS or the other data formats above, automatically converting from their operational scheduling software internal format, and publishing it on the web/internet. Hence, one of the software tool necessary to display bus network, is an application that will be able to import data in one of the formats above (or other similar ones).

If you are unlucky and find your target bus operator publish their network data only in printable format (paper or PDF), then you would need to manually translate that into one of the computer readable format above. That is tedious, error prone, time consuming and costly. You may need to use one of the available GTFS editing/creation software tools.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.