Navigation

    MagicMirror Forum

    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • Donate
    • Discord

    UNSOLVED Error in config file

    Troubleshooting
    4
    5
    604
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • A
      afrench10 last edited by

      Hi Folks,

      Can someone please help troubleshoot the error in my config file? I’m not a professional dev, and could use some assistance 🙂 Please reference below:

      var config = {
      	address: "localhost", // Address to listen on, can be:
      	                      // - "localhost", "127.0.0.1", "::1" to listen on loopback interface
      	                      // - another specific IPv4/6 to listen on a specific interface
      	                      // - "", "0.0.0.0", "::" to listen on any interface
      	                      // Default, when address config is left out, is "localhost"
      	port: 8080,
      	ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], // Set [] to allow all IP addresses
      	                                                       // or add a specific IPv4 of 192.168.1.5 :
      	                                                       // ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.1.5"],
      	                                                       // or IPv4 range of 192.168.3.0 --> 192.168.3.15 use CIDR format :
      	                                                       // ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.3.0/28"],
      
      	language: "en",
      	timeFormat: 24,
      	units: "imperial",
      
      	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: "Chicago",
      				locationID: "4887398",  //ID from http://bulk.openweathermap.org/sample/; unzip the gz file and find your city
      				appid: "c9306b83172dfaa7dc5c2b72cdcc3ff7"
      			}
      		},
      		{
      			module: "weatherforecast",
      			position: "top_right",
      			header: "Weather Forecast",
      			config: {
      				location: "Chicago",
      				locationID: "4887398",  //ID from http://www.openweathermap.org/help/city_list.txt
      				appid: "c9306b83172dfaa7dc5c2b72cdcc3ff7"
      			}
      		},
      		{
      			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
      			}
      		},
      		{
      			module: "CTA",
      			position: "bottom_left",
      			config: {
      				updateTime: 60000, // 1 minute, the API does not update much more often so going below this is unnecessary
      				//Bus Routes
      				ctaApiKey: "cg4QkprLT9WppdSuJXpDLB9PF",
      				busStopName: "66 - Chicago - Westbound",  // String value, Name your bus stop
      				stopId: 601, // Bus station ID: Chicago and Milwaukee example; go to http://www.transitchicago.com/riding_cta/systemguide/default.aspx to find your stop ID
      				maxResult: 1,  // The maximum number of incoming busses you want to display for bus stops
      				//Train Routes
      				ctaApiKeyTrain: "your-train-APIkey",
      				trainStopName: "Chicago Red Line",  //String value, name your train stop
      				trainStationID: CHIR, //Train station ID:  Chicago Blue line example; http://www.transitchicago.com/developers/ttdocs/default.aspx#_Toc296199909
      				maxResultTrain: 5, // Max number of incoming trains to disply
      				moduleInstance: 3, // To run multiple instances of this module
      			}
      		},
      	]
      
      };
      
      /*************** DO NOT EDIT THE LINE BELOW ***************/
      if (typeof module !== "undefined") {module.exports = config;}
      

      I hope this helps. Thanks in advance for your insight!

      Sean 1 Reply Last reply Reply Quote 0
      • Sean
        Sean Module Developer @afrench10 last edited by

        @afrench10
        trainStationID: might have string as its value. You missed quotation marks.
        trainStationID: "CHIR",

        A 1 Reply Last reply Reply Quote 3
        • A
          afrench10 @Sean last edited by

          @sean Thank you so much, Sean!

          bhepler 1 Reply Last reply Reply Quote 0
          • bhepler
            bhepler Project Sponsor @afrench10 last edited by

            @afrench10 - Glad you got it fixed! Remember to mark the question as solved.

            1 Reply Last reply Reply Quote 0
            • cowboysdude
              cowboysdude Project Sponsor Module Developer last edited by

              Ok so before you add ANY new modules make a backup of your config so you will always have a working copy 🙂

              1 Reply Last reply Reply Quote 1
              • 1 / 1
              • First post
                Last post
              Enjoying MagicMirror? Please consider a donation!
              MagicMirror created by Michael Teeuw.
              Forum managed by Paul-Vincent Roll and Rodrigo Ramírez Norambuena.
              This forum is using NodeBB as its core | Contributors
              Contact | Privacy Policy