Giter VIP home page Giter VIP logo

nyu-bustracker-android's Introduction

NYU Bus Tracker

NYU Bus Tracker is designed to combine the functionality of the NYU Mobile and Transloc apps (maps with real time bus locations) with the [massive schedules] (http://www.nyu.edu/life/travel-and-transportation/university-transportation.html) of the NYU bus system.

This app relies on the Transloc API for drawing the routes, getting real time bus locations, and getting the list of stops with locations. The bus times were manually parsed (not available from the API).

See the GitHub issues for a list of things that need to be done. All feature requests, bug reports, pull requests are welcome! Please let me know if you have any issues or questions. Thanks!

Design

  • The data is modeled by Bus, Route, Stop, and Time classes. They are all managed by a singleton BusManager class. Routes have an in order list of Stops. Stops have a list of Routes that service that stop and a list of Times corresponding to that particular route. Data accesses from the activities go through BusManager. Tests for connection between stops generally go through BusManager, as well.

  • Every JSON file (segments, routes, stops, times) is cached when retrieved (except for bus locations). Background network calls are made to ensure data is up to date.

  • Adapters are required to display the list of stops and times. Stops can be selected as the start or end, or favorited by the user (so it appears at the top of the list). Times display which route they correspond to (sometimes, more than one route travels between stops A and B).

  • There is only one activity: [MainActivity] (../master/NYUBusTracker/src/main/java/com/nyubustracker/activities/MainActivity.java). In the future, we may add additional activities to access times in an alternate format (like by route + stop, instead of stop + stop).

Install

  1. Install and open Android Studio.
  2. Open the SDK Manager (Tools > Android > SDK Manager) from Android Studio.
  3. Install API level 20, Android Support Repository, Android Support Library, Google Analytics App Tracking SDK, Google Play Services, and Google Repository, then close the SDK Manager.
  4. Fork this repository on GitHub by clicking the Fork button at the top right.
  5. Clone your fork inside Android Studio (VCS > Checkout from Version Control > Log in to GitHub > Select your fork > Click clone).
  6. Select use default gradle wrapper and click OK.
  7. If needed, open the project view by hovering over the icon at the bottom left of Android Studio.
  8. Set your API keys in the API keys file. You will need:
  1. Connect an Android phone or an emulator. In my opinion, a physical phone is easier to use. But, if you don't have one, you can try the built in Android emulator or a (much faster) Genymotion emulator. As a warning, you may have to do some extra work to get maps working in an emulator.
  2. Run the app (green arrow at the top of Android Studio)!

Release

Here is the release process, for when you're ready to push a new version to the Play Store.

  1. Make sure MainActivity.LOCAL_LOGV = false. Run the app and make sure there is no logging.
  2. Make sure the DownloaderHelper.AMAZON_URL is correct.
  3. Make sure your API keys are correct.
  4. Upgrade any dependencies.
  5. Bump the release version in build.gradle.
  6. git commit -am "Preparing release X.Y"
  7. Tag a release on GitHub.
  8. ./gradlew assembleRelease
  9. Run the app as a last minute check, to make sure everything is in working order.
  10. Upload.

Please see the LICENSE file for license information.

nyu-bustracker-android's People

Contributors

tbpalsulich avatar mikejaoudi avatar ktewell avatar chrismattmann avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.