umts / BusInfoBoard

A place to view bus arrival information from Avail's JSON feed
Apache License 2.0
15 stars 3 forks source link

This application uses Avail Technologies' InfoPoint API endpoints to show departures for specified stops. It was written by UMass Transit IT for use by the Pioneer Valley Transit Authority. The application is intended for use on monitors and kiosks located at bus stops.

Screenshot

Deployment

This application is entirely client-side, which means that all you need to deploy it is a web browser capable of being full-screen. GitHub pages is enabled on the master branch of this repository, which means that you can use it by simply pointing a browser at http://umts.github.io/BusInfoBoard/. Alternatively, you can host a copy of the code on any web server capable of serving static files, or even keep a copy of the code as a local file on your kiosk device.

If you would like to use this site with an Avail transit agency other than PVTA, you will need to edit the url in main.js to point to your installation of InfoPoint.

Configuration

Configuration can be done in two ways: by using query strings in the request url, or by passing a URL where a configuration JSON file lives. If both methods are used, query string parameters take precedence.

Query String

Config URL

All of the same parameters can be passed via config URL. Set the config_url variable in main.js to point to a JSON-formatted configuration file. For example:

{
  "routes": ["B43", "30"],
  "interval": 30000,
  "excluded_trips": ["Bus Garage via Mass Ave", "Bus Garage via Compsci"]
}

Examples

All 7 Holyoke Transportation Center Gates:

http://umts.github.io/BusInfoBoard/?stops=9098+9097+9096+9089+9088+9087+9086

UMass campus shuttle at ILC and Morrill:

http://umts.github.io/BusInfoBoard/?stops=64+63&routes=34+35

All buses at the Academy of Music, ordered by departure time:

http://umts.github.io/BusInfoBoard/?stops=261&sort=time

Haigis Mall with more "flair" :trollface::

http://umts.github.io/BusInfoBoard/?stops=73&interval=5&start_animation=bounceIn&end_animation=rotateOutUpRight