Read the statement by Michael Teeuw here.
How do I edit config, I see every new module starts whit going to config.js
-
I dont know what to do now … :(
- Duplicate config/config.js.sample to config/config.js.
- Modify your required settings.
The following properties can be configured:
-
- open a terminal type in
cd ~/MagicMirror/configtochangedirectory nano config.js- After you made your changes press
ctrl+xand confirm - change directory to parent directory
cd .. - start the mirror
npm start
- open a terminal type in
-
Thanks! It worked :D Made my day
-
This post is deleted! -
@strawberry-3.141 So I was playing around, thinking I knew everything now and my mirror is blank… I was trying to add a module in the config, and now I messed up. Any suggestions?
-
@KMH0 post your config, this will help to indentify the issues
-
var config = { port: 8080, ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], language: 'en', timeFormat: 24, units: 'metric', modules: [ { module: 'alert', }, { module: "updatenotification", position: "top_bar" }, { module: 'clock', position: 'top_left' }, { module: 'calendar', header: 'US Holidays', position: 'top_left', config: { calendars: [ { symbol: 'calendar-check-o ', url: 'webcal://www.calendarlabs.com/templates/ical/US-Holidays.ics' } ] } }, { module: 'compliments', position: 'lower_third' }, { module: 'currentweather', position: 'top_right', config: { location: 'New York', locationID: '', //ID from http://www.openweathermap.org appid: 'YOUR_OPENWEATHER_API_KEY' }}, { module: 'newsfeed', position: 'bottom_bar', config: { feeds: [ { title: "New York Times", url: "http://www.nytimes.com/services/xml/rss/nyt/HomePage.xml" } ], showSourceTitle: true, showPublishDate: true } }, }; /*************** DO NOT EDIT THE LINE BELOW ***************/ if (typeof module !== 'undefined') {module.exports = config;} -
You missed one ] which I added on 4th line from bottom
var config = { port: 8080, ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], language: 'en', timeFormat: 24, units: 'metric', modules: [ { module: 'alert', }, { module: "updatenotification", position: "top_bar" }, { module: 'clock', position: 'top_left' }, { module: 'calendar', header: 'US Holidays', position: 'top_left', config: { calendars: [ { symbol: 'calendar-check-o ', url: 'webcal://www.calendarlabs.com/templates/ical/US-Holidays.ics' } ] } }, { module: 'compliments', position: 'lower_third' }, { module: 'currentweather', position: 'top_right', config: { location: 'New York', locationID: '', //ID from http://www.openweathermap.org appid: 'YOUR_OPENWEATHER_API_KEY' } }, { module: 'newsfeed', position: 'bottom_bar', config: { feeds: [ { title: "New York Times", url: "http://www.nytimes.com/services/xml/rss/nyt/HomePage.xml" } ], showSourceTitle: true, showPublishDate: true } }, ] }; /*************** DO NOT EDIT THE LINE BELOW ***************/ if (typeof module !== 'undefined') {module.exports = config;} -
@yawns Thank you so much! But how do I add modules ? Do I just copy paste in to the config?
-
@KMH0
Actually it is always the same thing.- Find yourself a module you like, for example: MMM-IP
- Top right on the github repository you see a green button saying “clone or download”. If you click it you get the url for this repository. In this case it is https://github.com/fewieden/MMM-ip.git
- Open a terminal on your pi (either directly or using SSH) and type
cd ~/MagicMirror/modules - Clone the module to your pi by typing
git clone https://github.com/fewieden/MMM-ip.git. This downloads the repository and extracts it into a new folder. - Enter the new directory
cd MMM-ipand runnpm install(in this case it is not required … the readme should tell you to do so) - Edit your config file and add the code for the new module as the readme instructs to.
- Restart your magic mirror process and check what happened.
Sidenote: If you run into trouble with your config file, you can always paste the content into http://jshint.com/. If everything is fine it will only show this which is fine:
One undefined variable 64 module
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login