• 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.

http request

Scheduled Pinned Locked Moved Development
53 Posts 7 Posters 46.4k Views 6 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.
  • E Offline
    Eunanibus Module Developer
    last edited by Eunanibus Jun 24, 2016, 1:05 PM Jun 24, 2016, 12:57 PM

    Cool. It should work fine! Hurry up and try it, I made it for you :laughing:

    More information about it is here - I posted it for everyone to download.

    1 Reply Last reply Reply Quote 0
    • A Offline
      acdacd2
      last edited by Jun 24, 2016, 4:41 PM

      some errors with nom install

      pi@raspberrypi:~/MagicMirror/modules/default/MMM-HTTPRequestDisplay $ npm install
      npm WARN enoent ENOENT: no such file or directory, open ‘/home/pi/MagicMirror/modules/package.json’
      npm WARN enoent ENOENT: no such file or directory, open ‘/home/pi/MagicMirror/modules/node_modules/node_helper/package.json’
      npm WARN modules No description
      npm WARN modules No repository field.
      npm WARN modules No README data
      npm WARN modules No license field.

      P 1 Reply Last reply Jul 17, 2016, 5:50 PM Reply Quote 0
      • K Offline
        KirAsh4 Moderator
        last edited by Jun 24, 2016, 5:07 PM

        You shouldn’t need to run 'npm install' inside the module folder unless the author specifically told you to do that.

        A Life? Cool! Where can I download one of those from?

        1 Reply Last reply Reply Quote 0
        • A Offline
          acdacd2
          last edited by acdacd2 Jun 24, 2016, 5:12 PM Jun 24, 2016, 5:09 PM

          I did that,

          Now it’s solved, I copied the .json in the right folder

          1 Reply Last reply Reply Quote 0
          • E Offline
            Eunanibus Module Developer
            last edited by Jun 24, 2016, 7:00 PM

            Awesome. @KirAsh4 is correct - The README has all the instructions so be sure to take a look.

            Please let me know how it works cause you’ll be the first person to use it

            1 Reply Last reply Reply Quote 0
            • K Offline
              KirAsh4 Moderator
              last edited by Jun 24, 2016, 7:03 PM

              As a further explanation, 'npm install' is only required if the module you are installing requires other node modules to also be installed. When you first install MagicMirror you have to run 'npm install' to install all the dependencies for it to work, however generally, modules don’t need that. The exception is if someone writes a module that requires another node module that isn’t already installed. So there was no need to run that, nor to copy any '.json' package files anywhere.

              A Life? Cool! Where can I download one of those from?

              1 Reply Last reply Reply Quote 0
              • A Offline
                acdacd2
                last edited by KirAsh4 Jun 24, 2016, 7:33 PM Jun 24, 2016, 7:32 PM

                is that correct ?

                {
                		module: 'MMM-HTTPRequestDisplay',
                		position: 'bottom_bar',	// This can be any of the regions. Best results in left or right regions.
                		header: 'MMM-HTTPRequestDisplay', // This is optional
                		config: {
                			accessToken: 'http://api.openweathermap.org/data/2.5/weather?q=London,uk&mode=xml',
                			// See 'Configuration options' for more information.
                		}
                	},
                

                Note from Moderator: Please use Markdown on code snippets for easier reading.

                1 Reply Last reply Reply Quote 0
                • E Offline
                  Eunanibus Module Developer
                  last edited by Jun 24, 2016, 7:35 PM

                  Sorry, I made a lot of mistakes on the README it seems.

                  Instead of

                  accessToken : "http://etc"
                  

                  use

                  httpRequestURL: "http://etc"
                  

                  apologies

                  1 Reply Last reply Reply Quote 0
                  • A Offline
                    acdacd2
                    last edited by paviro Jul 17, 2016, 6:03 PM Jun 24, 2016, 7:43 PM

                    no problemo,

                    with this config, black screen

                    modules: [
                    	{
                    		module: 'MMM-HTTPRequestDisplay',
                    		position: 'bottom_bar',	// This can be any of the regions. Best results in left or right regions.
                    		header: 'MMM-HTTPRequestDisplay', // This is optional
                    		config: {
                    			httpRequestURL: 'http://192.168.1.248:8889/status.xml',
                    			// See 'Configuration options' for more information.
                    		}
                    	},
                    
                    1 Reply Last reply Reply Quote 0
                    • E Offline
                      Eunanibus Module Developer
                      last edited by Jun 24, 2016, 7:50 PM

                      Make sure that you’re not just copy and pasting blindly into your config file.

                      After each

                      modules: [
                      {
                      etc
                      },
                      

                      Note the comma , after the module. That comma should only be there if there are more modules.

                      Likewise, if you’re pasting it last, you need to make sure the module before it has one, to let the script know there are more modules after the previous one.

                      So the pattern is

                      modules: [
                      {
                         module: ‘firstModule’,
                         config: {
                         option : ""
                         }
                      }, <<< COMMA HERE
                      
                      modules: [
                      {
                         module: ‘middleModule’,
                         config: {
                         option : ""
                         }
                      }, <<< COMMA HERE
                      
                      modules: [
                      {
                         module: ‘last module’,
                         config: {
                         option : ""
                         }
                      } <<<<< NO COMMA
                      

                      hope that makes sense. hopefully that’s the problem.

                      1 Reply Last reply Reply Quote 0
                      • 1
                      • 2
                      • 3
                      • 4
                      • 5
                      • 6
                      • 2 / 6
                      2 / 6
                      • First post
                        19/53
                        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