• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
MagicMirror Forum
  • Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
A New Chapter for MagicMirror: The Community Takes the Lead
Read the statement by Michael Teeuw here.

hi, i need your help... tell me, how i do a new modules please

Scheduled Pinned Locked Moved Troubleshooting
14 Posts 5 Posters 3.6k Views 5 Watching
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.
  • B Offline
    bjjsoul
    last edited by sdetweil Oct 10, 2019, 8:25 PM Oct 10, 2019, 8:16 PM

    hi, i need your help, tell me , how i do to install a new madules please…
    in this moment i am trying to install a module,it is called snow , but i dont know how to insert the code.

    when i run magic mirror it says error

     modules: [
    	{
    		module: 'MMM-Snow',
    		position: 'fullscreen_above'
    		config: { // See 'Configuration options' for more information.
    			flakeCount: 100,
    			theme: "winter"			
    		}
    	}
    ]
    
    M 1 Reply Last reply Oct 11, 2019, 12:00 AM Reply Quote 0
    • B Offline
      buzzkc
      last edited by Oct 10, 2019, 8:24 PM

      It’s missing a comma after the postion: ‘fullscreen_above’

      https://forum.magicmirror.builders/topic/4231/how-to-add-modules-for-absolute-beginners

      Darren

      My Build: https://forum.magicmirror.builders/topic/11153/new-non-mirror

      1 Reply Last reply Reply Quote 1
      • B Offline
        buzzkc
        last edited by Oct 10, 2019, 8:25 PM

        Here is additional information on checking your config file that may help…

        https://forum.magicmirror.builders/topic/5399/how-to-check-your-config-for-errors-for-absolute-beginners

        Darren

        My Build: https://forum.magicmirror.builders/topic/11153/new-non-mirror

        1 Reply Last reply Reply Quote 1
        • B Offline
          bjjsoul
          last edited by Oct 10, 2019, 8:50 PM

          in this moment, i am fix the comma, but no work it. now i am check the configuration and see like this…

          Checking file… /home/pi/MagicMirror/config/config.js
          Line 100 col 9 Expected ‘]’ to match ‘[’ from line 28 and instead saw ‘}’.
          Line 101 col 5 Expected ‘}’ to match ‘{’ from line 11 and instead saw ‘]’.
          Line 101 col 6 Missing semicolon.
          Line 101 col 5 Unrecoverable syntax error. (94% scanned).

          S 1 Reply Last reply Oct 10, 2019, 9:19 PM Reply Quote 0
          • B Offline
            bjjsoul
            last edited by sdetweil Oct 10, 2019, 9:13 PM Oct 10, 2019, 9:03 PM

            this is a little part the file, config.js… tell me please whats is my wrong.

            i can install all magic mirror, in that is ok

            but i want install, alexa awesome, comand voice and other modules, and i have realy problem… :( thank dude for you help…

            
            },
               	{
               		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,
               			broadcastNewsFeeds: true,
               			broadcastNewsUpdates: true
               		}
               	},
                          {
               	module: "MMM-Snow",
               	position: "fullscreen_above",
               	config: { // See 'Configuration options' for more information.
               		flakeCount: 100,
               		theme: "winter",			
               	}
               }
                   },
               ]
               
               };
            
            /*************** DO NOT EDIT THE LINE BELOW ***************/
            if (typeof module !== "undefined") {module.exports = config;}
            
            1 Reply Last reply Reply Quote 0
            • S Online
              sdetweil
              last edited by Oct 10, 2019, 9:14 PM

              please start using the markdown syntax and code blocks around your content…

              i have edited two posts… for clarity

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              1 Reply Last reply Reply Quote 0
              • S Online
                sdetweil @bjjsoul
                last edited by sdetweil Oct 10, 2019, 9:20 PM Oct 10, 2019, 9:19 PM

                @bjjsoul said in hi, i need your help... tell me, how i do a new modules please:

                Line 100 col 9 Expected ‘]’ to match ‘[’ from line 28 and instead saw ‘}’.

                so, you have an error, you look to the line PRIOR to the one called out,
                so line 99… and see what is wrong with that… it says some [] group isn’t completed, cause it say } before ]

                all brackets [] and braces {} have to be matched

                Sam

                How to add modules

                learning how to use browser developers window for css changes

                1 Reply Last reply Reply Quote 0
                • B Offline
                  bjjsoul
                  last edited by sdetweil Oct 11, 2019, 11:44 AM Oct 10, 2019, 9:34 PM

                  mmmm sorry , i dont understand… :( my magic mirror is run perfect , whitout this module0_1570743430371_WhatsApp Image 2019-10-07 at 9.50.47 AM.jpeg

                  AND THIS is , file MM-Snow.js

                  /* Magic Mirror
                   * Module: MMM-Snow
                   *
                   * By Michael Teeuw http://michaelteeuw.nl
                   * MIT Licensed.
                   * 
                   * Comment on terminology: a 'flake' is any moving item being shown on the mirror, while
                   * the specific themed items are called 'snow' or 'heart'. This applies to variable names
                   * file names and css class names.
                   */
                  
                  Module.register("MMM-Snow",{
                  
                  	defaults: {
                  		flakeCount: 100,
                  		theme: "winter"                 // pick from themes map below, i.e. winter, love
                  	},
                  
                  	themes: {
                  		"winter" : { 
                  			"flakePrefix"  : "snow",    // prefix of css name, e.g. snow1 
                  			"imagesCount"  : 3,         // number of images available in this theme, here:  snow1, snow2, snow3
                  			"downwards"    : true,      // direction of flake movements, snow goes downwards
                  			"sizeFactor"   : 1},        // adapt size of flakes to your liking, use original flake size
                  		"love"   : { 
                  			"flakePrefix" : "heart",    // prefix of css name, e.g. heart1 
                  			"imagesCount"  : 2,         // number of images in this theme, here:  heart1, heart2
                  			"downwards"    : false,     // direction of flake movements, hearts raise upwards			
                  			"sizeFactor"   : 2},        // adapt size of flakes to your liking, we like bigger hearts
                  		"water"   : { 
                  			"flakePrefix" : "bubble",   // prefix of css name, e.g. bubble1 
                  			"imagesCount"  : 1,         // number of images in this theme, here:  bubble1
                  			"downwards"    : false,     // direction of flake movements, bubbles raise upwards			
                  			"sizeFactor"   : 2}         // adapt size of flakes to your liking, we like bigger bubbles
                  	},
                  
                  	getStyles: function() {
                  		return [ "MMM-Snow.css" ]
                  	},
                  
                  	getDom: function() {
                  		var themeSettings = this.themes[this.config.theme];
                  		var wrapper = document.createElement("div")
                  		wrapper.className = "wrapper"
                  
                  		var flake, jiggle, size;
                  
                  		for(var i = 0; i < this.config.flakeCount; i++) {
                  
                  			size = themeSettings.sizeFactor * (Math.random() * 0.75) + 0.25;
                  			flakeImage = document.createElement("div")
                  			
                  			var flakeSuffix = Math.round(1 + Math.random() * (themeSettings.imagesCount - 1));
                  			flakeImage.className = themeSettings.flakePrefix + flakeSuffix;
                  			flakeImage.style.transform = "scale(" + size +", " + size + ")";
                  			flakeImage.style.opacity = size;
                  
                  			flake = document.createElement("div");
                  			if(themeSettings.downwards) {
                  				flake.className = "flake-downwards";
                  			}
                  			else {
                  				flake.className = "flake-upwards"
                  			}
                  
                  			jiggle = document.createElement("div");
                  			jiggle.style.animationDelay = (Math.random() * 4) + "s";
                  			jiggle.style.animationDuration = ((Math.random() * 30) + 30) + "s";
                  			jiggle.appendChild(flakeImage);
                  
                  			size = (Math.random() * 0.75) + 0.25;
                  			jiggle.style.transform = "scale(" + size +", " + size + ")";
                  			jiggle.style.opacity = size;
                  
                  			flake.appendChild(jiggle);
                  			flake.style.left = ((Math.random() * 100) - 10) + "%";
                  			flake.style.animationDelay = (Math.random() * 100) + "s";
                  			flake.style.animationDuration = 100 - (Math.random() * 50 * size) + "s";
                  
                  			wrapper.appendChild(flake);
                  		}
                  		return wrapper;
                  	}
                  
                  });
                  
                  S 1 Reply Last reply Oct 10, 2019, 9:41 PM Reply Quote 0
                  • S Online
                    sdetweil @bjjsoul
                    last edited by sdetweil Oct 11, 2019, 2:47 AM Oct 10, 2019, 9:41 PM

                    @bjjsoul can’t be perfect if you want to add another module

                       	{   < --- start module
                       		module: "newsfeed",
                       		position: "bottom_bar",
                       		config: {  < ---  start module config
                       			feeds: [  < --- start array of feeds
                       				{ < --- start feed 
                       					title: "New York Times",
                       					url: "http://www.nytimes.com/services/xml/rss/nyt/HomePage.xml"
                       				}  < -- end feed
                       			], < --- end array (only one entry)
                       			showSourceTitle: true,
                       			showPublishDate: true,
                       			broadcastNewsFeeds: true,
                       			broadcastNewsUpdates: true
                       		} < ----  end module config
                       	}, < --- end module
                            {  < --- start module
                       	module: "MMM-Snow",
                       	position: "fullscreen_above",
                       	config: {   < - start module config
                                       // See 'Configuration options' for more information.
                       		flakeCount: 100,
                       		theme: "winter",			
                       	} < ---- end module config
                       } < ---- end module , no comma, no more modules to follow
                           },   < ------ what is this??????? -------------------------------
                       ]    < --- no more modules, end module array 
                    

                    Sam

                    How to add modules

                    learning how to use browser developers window for css changes

                    1 Reply Last reply Reply Quote 1
                    • B Offline
                      bjjsoul
                      last edited by bjjsoul Oct 10, 2019, 10:31 PM Oct 10, 2019, 10:26 PM

                      HEY BRO YOU ARE AWESOME … THANK YOU DUDE, I AM VERY HAPPY! IS WORKING … HEY BRO YOU HAVE WHATSAPP THIS MY NUMBER 504 98674031 … I AM GONNA BE NEEDING YOU, IN MY NEXT MODULES INSTALLATIONS… THANKS

                      0_1570746677017_WhatsApp Image 2019-10-10 at 4.02.42 PM.jpeg

                      VIDEO

                      S 1 Reply Last reply Oct 10, 2019, 10:28 PM Reply Quote 0
                      • 1
                      • 2
                      • 1 / 2
                      1 / 2
                      • First post
                        3/14
                        Last post
                      Enjoying MagicMirror? Please consider a donation!
                      MagicMirror created by Michael Teeuw.
                      Forum managed by Sam, technical setup by Karsten.
                      This forum is using NodeBB as its core | Contributors
                      Contact | Privacy Policy