Navigation

    MagicMirror Forum

    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • Donate
    • Discord
    MagicMirror² v2.15.0 is available! For more information about this release, check out this topic.

    Blackscreen after install MMM-PIR-Sensor

    Troubleshooting
    5
    15
    6373
    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
      Blackmirror last edited by

      Hello,

      it’s my first entry here.

      I will start to build a MagicMirror and I have a Problem with the MMM-PIR_Sensor Modul.

      I have installed and have no problems at the install, but will the Mirror start I see only a black screen. When I move the mouse at the raspberry I can see the mouse arrow.

      When I unmarker the PIR-Module lines in the config.js . I can see the normal Mirror.

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

        post your config.js minus any keys so we can take a peek…

        1 Reply Last reply Reply Quote 0
        • B
          Blackmirror last edited by yawns

          Here, but I think it is not a problem with the config.js, because when I have the module in the config.js include and deinstall the module in Magicmirror/modules I can see the Mirror:

          var config = {
                  port: 8080,
                  ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"],
          
                  language: 'de',
                  timeFormat: 24,
                  units: 'metric',
          
                  modules: [
                          {
                                  module: 'alert',
                          },
          //      {
          //              module: 'MMM-PIR-Sensor',
          //              config: {
          //              relayGpio: '26',
          //              relayOnState: '0',
          //              powerSaving: false,
          //                      // See 'Configuration options' for more information.
          //              },
          //      },
                  {
                      module: 'MMM-Carousel',
                      config: {
                          transitionInterval: 10000,
                          ignoreModules: [],
                          mode: 'positional',
                          top_right: {enabled: true, ignoreModules: [], overrideTransitionInterval: 15000}
                      }
                  },
          
                          {
                                  module: "updatenotification",
                                  position: "top_bar"
                          },
          
                          {
                          module: 'MMM-FRITZ-Box-Callmonitor',
                          //position: 'top_bar',  // This can be any of the regions. Best results in left or right regions.
                          //header: "Recent calls", // This is optional
                          config: { password: 'xxx'
                          }
                          },
                  {
                          module: 'MMM-Callmonitor-Current-Call',
                          position: 'top_bar',    // This can be any of the regions. Best results in left or right regions.
                          //header: "Active Calls", // This is optional
                  },
                          {
                                  module: 'clock',
                                  position: 'top_left'
                          },
                            {
                              module: 'MMM-DHT22',
                                  position: 'top_left',
                              config: {
                                sensorPIN: 22,
                                 updateInterval: 0.5, // Minutes
                               },
                                },
                          {
                                  module: 'currentweather',
                                  position: 'top_left',
                                  config: {
                                          location: 'xxx',
                                          locationID: 'xxx',  //ID from http://www.openweathermap.org
                                          appid: 'xxx'
                                  }
                          },
          
                          {
                  module: 'MMM-Traffic',
                  position: 'top_left',
                  classes: 'dimmed medium', //optional, default is 'bright medium', only applies to commute info not route_name
                  config: {
                          api_key: 'xxx',
                          mode: 'driving',
                          origin: 'xxx',
                          destination: 'xxx',
                          //arrival_time: '0800', //optional, but needs to be in 24 hour time if used.
                          route_name: 'xxx',
                          changeColor: true,
                          showGreen: false,
                          limitYellow: 5, //Greater than 5% of journey time due to traffic
                          limitRed: 20, //Greater than 20% of journey time due to traffic
                          traffic_model: 'pessimistic',
                          interval: 120000, //2 minutes
                          showWeekend: true,
                          allTime: true,
                  }
                          },
                          {
                                  module: 'calendar',
                                  header: 'Termine',
                                  position: 'top_right',
                                  config: {
                                          calendars: [
                                                  {
                                                          symbol: 'calendar-check-o ',
                                                          url: 'xxxs',
                                                          maximumEntries: '5'
                                                  }
                                          ]
                                  }
                          },
                         {
                              module: "MMM-Fuel",
                             position: "top_right",
                                   config: {
                                  api_key: "xxx",
                          lat: xxx,
                                  lng: xxx,
                                   types: ["diesel"],
                                  max: 2,
                                  rotate: false,
                                  colored: true,
                                  open: true
          
                              }
                          },
            //             {
          //                               module: 'MMM-Wunderlist',
          //                      position: 'top_right',  // This can be any of the regions. Best results in left or right regions.
          //                      header: 'Wunderlist', // This is optional
          //                      config: {
            //                    // See 'Configuration options' for more information.
              //                                   }
             //   },
                          {
                                  module: 'weatherforecast',
                                  position: 'top_right',
                                  header: 'Weather Forecast',
                                  config: {
                                          location: 'xxx',
                                          locationID: 'xxx',  //ID from http://www.openweathermap.org
                                          appid: 'xxx'
                                  }
                          },
          //              {
          //                      module: 'newsfeed',
          //                      position: 'bottom_bar',
          //                      config: {
          //                              feeds: [
          //                                      {
          //                                              title: "xxx",
          //                                              url: "xxxl"
          //                                      }
          //                              ],
          //                              showSourceTitle: true,
          //                              showPublishDate: true
          //                      }
          //              },
                  ]
          
          };
          
          /*************** DO NOT EDIT THE LINE BELOW ***************/
          if (typeof module !== 'undefined') {module.exports = config;}
          
          1 Reply Last reply Reply Quote 0
          • cowboysdude
            cowboysdude Project Sponsor Module Developer last edited by cowboysdude

            @Blackmirror said in Blackscreen after install MMM-PIR-Sensor:

            // {
            // module: ‘MMM-PIR-Sensor’,
            // config: {
            // relayGpio: ‘26’,
            // relayOnState: ‘0’,
            // powerSaving: false,
            // // See ‘Configuration options’ for more information.
            // },
            // },

            Right off the top here is an issue 🙂 should only have one }, 🙂 Like this below…
            It has too many }, so it’s stopping at the first one then errors out because it goes to the next }, as a new line and that creates your problem. 🙂

            {
            module: ‘MMM-PIR-Sensor’,
            config: {
            relayGpio: ‘26’,
            relayOnState: ‘0’,
            powerSaving: false,
            }
            },

            B 1 Reply Last reply Reply Quote 1
            • B
              Blackmirror @cowboysdude last edited by

              @cowboysdude

              No, this is not the problem, I have unlined this, because I can not use the Mirror, when I delete the // I see the black screen.

              It’s my fault to show the config.js this the //.

              1 Reply Last reply Reply Quote 0
              • B
                Blackmirror last edited by

                I have it remove and make a new installation, after this it comes errors:

                pi@Mirror:~/MagicMirror/modules/MMM-PIR-Sensor $ sudo npm install -g

                epoll@0.1.21 install /usr/lib/node_modules/Magic-Mirror-Module-PIR-Sensor/node_modules/epoll
                node-gyp rebuild

                gyp WARN EACCES user “root” does not have permission to access the dev dir “/root/.node-gyp/6.10.0”
                gyp WARN EACCES attempting to reinstall using temporary dev dir “/usr/lib/node_modules/Magic-Mirror-Module-PIR-Sensor/node_modules/epoll/.node-gyp”
                make: Entering directory ‘/usr/lib/node_modules/Magic-Mirror-Module-PIR-Sensor/node_modules/epoll/build’
                CXX(target) Release/obj.target/epoll/src/epoll.o
                SOLINK_MODULE(target) Release/obj.target/epoll.node
                COPY Release/epoll.node
                make: Leaving directory ‘/usr/lib/node_modules/Magic-Mirror-Module-PIR-Sensor/node_modules/epoll/build’

                Magic-Mirror-Module-PIR-Sensor@1.1.0 postinstall /usr/lib/node_modules/Magic-Mirror-Module-PIR-Sensor
                electron-rebuild -e …/…/node_modules/electron

                sh: 1: electron-rebuild: not found
                npm ERR! Linux 4.4.50-v7+
                npm ERR! argv “/usr/bin/nodejs” “/usr/bin/npm” “install” “-g”
                npm ERR! node v6.10.0
                npm ERR! npm v3.10.10
                npm ERR! file sh
                npm ERR! code ELIFECYCLE
                npm ERR! errno ENOENT
                npm ERR! syscall spawn

                npm ERR! Magic-Mirror-Module-PIR-Sensor@1.1.0 postinstall: electron-rebuild -e ../../node_modules/electron
                npm ERR! spawn ENOENT
                npm ERR!
                npm ERR! Failed at the Magic-Mirror-Module-PIR-Sensor@1.1.0 postinstall script ‘electron-rebuild -e …/…/node_modules/electron’.
                npm ERR! Make sure you have the latest version of node.js and npm installed.
                npm ERR! If you do, this is most likely a problem with the Magic-Mirror-Module-PIR-Sensor package,
                npm ERR! not with npm itself.
                npm ERR! Tell the author that this fails on your system:
                npm ERR! electron-rebuild -e …/…/node_modules/electron
                npm ERR! You can get information on how to open an issue for this project with:
                npm ERR! npm bugs Magic-Mirror-Module-PIR-Sensor
                npm ERR! Or if that isn’t available, you can get their info via:
                npm ERR! npm owner ls Magic-Mirror-Module-PIR-Sensor
                npm ERR! There is likely additional logging output above.

                npm ERR! Please include the following file with any support request:
                npm ERR! /home/pi/MagicMirror/modules/MMM-PIR-Sensor/npm-debug.log

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

                  Did you go to the module directory that the pir module is in and run ‘npm install’?

                  If not try that first.

                  1 Reply Last reply Reply Quote 1
                  • B
                    Blackmirror last edited by

                    Hello,
                    I have delete the ‘,’ but I have still this problem. In the past failure in the config.js make a white screen at me.

                    And I have run ‘sudo npm install -g’ in the MMM-PIR-Sensor directory,
                    and I see this Error messages. And I have still a black screen.

                    1 Reply Last reply Reply Quote 0
                    • broberg
                      broberg Project Sponsor last edited by

                      I don’t think you are supposed to be using sudo when doing npm install just the other parts,
                      Using sudo will probably give access issues for the module.

                      1 Reply Last reply Reply Quote 1
                      • B
                        Blackmirror last edited by

                        So I Have rm -rf MMM-PIR-Sensor and new install. after this I run npm install -g, is give the follow error messages

                        pi@Mirror:~/MagicMirror/modules/MMM-PIR-Sensor $ npm install -g
                        npm WARN checkPermissions Missing write access to /usr/lib/node_modules
                        /usr/lib
                        └─┬ Magic-Mirror-Module-PIR-Sensor@1.1.0
                        └─┬ onoff@1.1.2
                        └─┬ epoll@0.1.21
                        ├── bindings@1.2.1
                        └── nan@2.5.1

                        npm ERR! Linux 4.4.50-v7+
                        npm ERR! argv “/usr/bin/nodejs” “/usr/bin/npm” “install” “-g”
                        npm ERR! node v6.10.0
                        npm ERR! npm v3.10.10
                        npm ERR! path /usr/lib/node_modules
                        npm ERR! code EACCES
                        npm ERR! errno -13
                        npm ERR! syscall access

                        npm ERR! Error: EACCES: permission denied, access ‘/usr/lib/node_modules’
                        npm ERR! at Error (native)
                        npm ERR! { Error: EACCES: permission denied, access ‘/usr/lib/node_modules’
                        npm ERR! at Error (native)
                        npm ERR! errno: -13,
                        npm ERR! code: ‘EACCES’,
                        npm ERR! syscall: ‘access’,
                        npm ERR! path: ‘/usr/lib/node_modules’ }
                        npm ERR!
                        npm ERR! Please try running this command again as root/Administrator.

                        npm ERR! Please include the following file with any support request:
                        npm ERR! /home/pi/MagicMirror/modules/MMM-PIR-Sensor/npm-debug.log

                        And a black screen at the mirror

                        1 Reply Last reply Reply Quote 0
                        • 1
                        • 2
                        • 1 / 2
                        • 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