Get weather from a self-updated GPS Location
JavaScript PHP CSS
Switch branches/tags
Nothing to show
Clone or download
Latest commit 17c3a22 Nov 13, 2016
Permalink
Failed to load latest commit information.
server-files Updated gps.php for time Nov 10, 2016
MMM-GPSWeather.css Formatting Aug 3, 2016
MMM-GPSWeather.js Updated Icon display Nov 13, 2016
README.md Updated code Aug 3, 2016

README.md

Module: MMM-GPSWeather

The MMM-GPSWeather module is a MagicMirror addon module. This module outputs the last location of a user who's updated a specific website. Uses a modified version of Herv� Renault's Self Hosted GPS Tracker The modified files are located in the server-files folder

Using the module

To use this module, add it to the modules array in the config/config.js file:

modules: [
	{
		module: 'MMM-GPSWeather',
		position: 'bottom_left',	// This can be any of the regions.
									// Best results in one of the side regions like: bottom_left
		config: {
			// See 'Configuration options' for more information.
			locationOnly: false, //Display just location, or loc & weather
			locationAPIKey: '1234567890zbcdefghijkl', //google maps API key - REQUIRED
			username: 'MyName', // Part of the position URL
			latlonUrlBase: "http://yourserver.net/gps", //The server you have your GPS file hosted - REQUIRED
			WUAPIKey: '12391290348sjdf834' // Wunderground API Key - REQUIRED

		}
	}
]

Configuration options

The following properties can be configured:

Option Description
username The username used for URL differentiation and display.

Example: JohnR
This value is REQUIRED
locationAPIKey The Google's API key, which can be obtained by creating google account.

This value is REQUIRED
locationOnly Do you just want position and not weather?

Possible values: true or false
Default value: false
fileLocation The JSON data page for your GPS data

Example: here.php
WUAPIKey The Wunderground.com's API key, which can be obtained by creating a free Cumulus plan.

This value is REQUIRED
latlonUrlBase The server where your gps file is stored

Example: http://www.myserver.com/gps
This value is REQUIRED
nameUrlBase Google's Geooding API URL

Default Value: "https://maps.googleapis.com/maps/api/geocode/json?latlng="
apiBase Wunderground's API URL

Default Value: "http://api.wunderground.com/api/"
forecastEndpoint Wunderground's API URL

Default Value: "/forecast10day/q/"
updateInterval How often does the content needs to be fetched? (Milliseconds)

Possible values: 1000 - 86400000
Default value: 3600000 (1 hour)
animationSpeed Speed of the update animation. (Milliseconds)

Possible values:0 - 5000
Default value: 2000 (2 seconds)
initialLoadDelay The initial delay before loading. If you have multiple modules that use the same API key, you might want to delay one of the requests. (Milliseconds)

Possible values: 1000 - 5000
Default value: 2500 (2.5 seconds)
retryDelay Time between retries if one of the pages doesn't load correctly (Milliseconds)

Possible values: 1000 - 5000
Default value: 2500 (2.5 seconds)
Units Override Config Units

Default value: From Config