Skip to content

Estanz0/MMM-AT-Bus

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MMM-AT-Bus

This an extension for the MagicMirror. It will display the minutes until arrival of a selected bus number to a selected stop. The bus number and stop code can be configured in the config file. To use this module you will need to create a free Auckland Transport Developer Portal account.

Example shown top left:

MMM-AT-Bus Module Example

Installation

  1. Navigate into your MagicMirror's modules folder
  2. Execute git clone https://github.com/Estanz0/MMM-AT-Bus.git
  3. Navigate to newly created folder MMM-AT-Bus

Using the module Add the below to the modules array in the config/config.js file:

modules: [
	{
		module: "MMM-AT-Bus",
		position: "top_left",
		config: {
			provider: "AT", // One of ['AT']
			routeShortNames: ["NX1", "82"], // The short name of the bus route
			stopCode: "7036", // The bus stop code (Displayed on Google maps)
			forwardLimitHours: 2, // Show trips which begin within the set number of hours
			refreshIntervalSeconds: 20, // Refresh frequency
			key: "api_key" // The API Key for the selected provider
		}
	}
];

Configuration options

The following properties can be configured:

Option Description
provider API Provider
AT: Auckland Transport
routeShortNames A list of bus routes
The route short name is generally 2 - 3 characters and numbers.
stopCode The bus stop code.
This can be found using the AT app, website or Google maps.
forwardLimitHours Hours.
Buses arriving further in the future than this limit will not be displayed.
refreshIntervalSeconds Seconds.
How often the arrival times should be refreshed.
key A developer API key for the provider APIs.
For AT this can be obtained by signing up for a developer account (subscription) through the AT developer portal product subscription.
Note: it can take a few days for your developer account to be activated after signing up.

Finding bus route and stop

AT app:

  • Go to live departures and select a stop from the map.
  • Bus route can be seen on the left hand side.
  • Stop code can be found up the top.

AT App

More Demo Images

Loading Screen

Loading

Bus and Stop Code configured

Loading

Only Stop Code configured

Loading

Check out the other modules here

3rd party Magic Mirror modules

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published