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.

    MMM-Awesome-Alexa (again =p)

    Scheduled Pinned Locked Moved Troubleshooting
    17 Posts 3 Posters 3.0k Views 3 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.
    • S Offline
      sdetweil @stalker401
      last edited by

      @stalker401 lets look for errors

      in the window where u start MM, look for messages, either npm start, or if using pm2, the pm2 logs --lines=??? where ??? is a number, default 15

      also open the developers window, ctrl-shoft-i on the mm keyboard, and select the tab labeled console, and scroll up. u can also filter messages by module by putting a unique part of the module name in the filter field, in this case alexa

      u have what we call black screen…

      Sam

      How to add modules

      learning how to use browser developers window for css changes

      S 1 Reply Last reply Reply Quote 0
      • S Offline
        stalker401 @sdetweil
        last edited by

        @sdetweil thanks I’ll try that tonight

        1 Reply Last reply Reply Quote 0
        • S Offline
          stalker401
          last edited by

          So when I ran the pm2 logs --lines=15 i got the error about an invalid ClientID and when I changed the client ID to null i got the same error with the clinet secret. When i changed that null i got the clientsecret error again. i’m not really sure when i went wrong here as I copied and pasted the clientID & clientSecret from my AVS account.

          I did also put the dev consule and I didn’t see any alexa errors

          0|mm       | [2020-12-20 15:47:11.604] [ERROR]  WARNING! Could not validate config file. Starting with default configuration. Please correct syntax errors at or above this line: /home/pi/MagicMirror/config/config.js:115
          0|mm       | 		    "clientSecret": null
          0|mm       | 		    ^^^^^^^^^^^^^^
          0|mm       | 
          0|mm       | SyntaxError: Unexpected string
          0|mm       |     at Module._compile (internal/modules/cjs/loader.js:722:23)
          0|mm       |     at Object.Module._extensions..js (internal/modules/cjs/loader.js:798:10)
          0|mm       |     at Module.load (internal/modules/cjs/loader.js:645:32)
          0|mm       |     at Function.Module._load (internal/modules/cjs/loader.js:560:12)
          0|mm       |     at Module.require (internal/modules/cjs/loader.js:685:19)
          0|mm       |     at require (internal/modules/cjs/helpers.js:16:16)
          0|mm       |     at loadConfig (/home/pi/MagicMirror/js/app.js:70:12)
          0|mm       |     at App.start (/home/pi/MagicMirror/js/app.js:217:3)
          0|mm       |     at Object.<anonymous> (/home/pi/MagicMirror/js/electron.js:129:7)
          0|mm       |     at Module._compile (internal/modules/cjs/loader.js:786:30)
          
          

          Here’s the error again with the clientID and what not in there:

          /home/pi/.pm2/logs/mm-error.log last 15 lines:
          0|mm       | [2020-12-20 15:52:34.906] [ERROR]  WARNING! Could not validate config file. Starting with default configuration. Please correct syntax errors at or above this line: /home/pi/MagicMirror/config/config.js:114
          0|mm       | 		    "clientId": amzn1.application-oa2-client.0fa20b28debc4858a0acd193871bd8e1
          0|mm       | 		                                            ^^
          0|mm       | 
          0|mm       | SyntaxError: Invalid or unexpected token
          0|mm       |     at Module._compile (internal/modules/cjs/loader.js:722:23)
          0|mm       |     at Object.Module._extensions..js (internal/modules/cjs/loader.js:798:10)
          0|mm       |     at Module.load (internal/modules/cjs/loader.js:645:32)
          0|mm       |     at Function.Module._load (internal/modules/cjs/loader.js:560:12)
          0|mm       |     at Module.require (internal/modules/cjs/loader.js:685:19)
          0|mm       |     at require (internal/modules/cjs/helpers.js:16:16)
          0|mm       |     at loadConfig (/home/pi/MagicMirror/js/app.js:70:12)
          0|mm       |     at App.start (/home/pi/MagicMirror/js/app.js:217:3)
          0|mm       |     at Object.<anonymous> (/home/pi/MagicMirror/js/electron.js:129:7)
          0|mm       |     at Module._compile (internal/modules/cjs/loader.js:786:30)
          
          S 1 Reply Last reply Reply Quote 0
          • S Offline
            sdetweil @stalker401
            last edited by sdetweil

            @stalker401 1st error, missing comma on line before

            2nd error, the id needs to be in quotes

            also,
            general rules for module definition
            {} and [] must be matched
            the word to the left of : does not need quotes
            the thing to the right of : if a number or, true/false does NOT need quotes
            otherwise it needs quotes, single or double doesn’t matter as long as start and end quote are the same

            if the thing on the next line starts with a word , then THIS line needs a trailing comma
            if the thing on the next line starts with {, then THIS line needs a trailing comma

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            S 1 Reply Last reply Reply Quote 0
            • S Offline
              stalker401 @sdetweil
              last edited by

              @sdetweil I really appreciate your help, and i’m sorry i can’t seem to figure this out on my own at all. So here’s what I tried:

              i used this code:

              		  module: "MMM-awesome-alexa",
              		  position: "bottom_bar",
              		  config: {
              		    wakeWord: "Alexa",
              		    clientId: "null",
              		    clientSecret: "null",
              		    deviceId: "null",
              		  }
              		},
              

              and got this error:

              /home/pi/.pm2/pm2.log last 15 lines:
              PM2        | 2020-12-20T15:53:14: PM2 log: pid=27048 msg=process killed
              PM2        | 2020-12-20T16:28:35: PM2 log: App [mm:0] starting in -fork mode-
              PM2        | 2020-12-20T16:28:35: PM2 log: App [mm:0] online
              PM2        | 2020-12-20T16:29:25: PM2 log: App [mm:0] exited with code [0] via signal [SIGINT]
              PM2        | 2020-12-20T16:29:25: PM2 log: App [mm:0] starting in -fork mode-
              PM2        | 2020-12-20T16:29:25: PM2 log: App [mm:0] online
              PM2        | 2020-12-20T16:29:34: PM2 log: Stopping app:mm id:0
              PM2        | 2020-12-20T16:29:35: PM2 log: App [mm:0] exited with code [0] via signal [SIGINT]
              PM2        | 2020-12-20T16:29:35: PM2 log: pid=27383 msg=process killed
              PM2        | 2020-12-20T16:31:10: PM2 log: App [mm:0] starting in -fork mode-
              PM2        | 2020-12-20T16:31:10: PM2 log: App [mm:0] online
              PM2        | 2020-12-20T16:32:41: PM2 log: Stopping app:mm id:0
              PM2        | 2020-12-20T16:32:42: PM2 log: pid=27457 msg=failed to kill - retrying in 100ms
              PM2        | 2020-12-20T16:32:42: PM2 log: App [mm:0] exited with code [0] via signal [SIGINT]
              PM2        | 2020-12-20T16:32:42: PM2 log: pid=27457 msg=process killed
              
              /home/pi/.pm2/logs/mm-error.log last 15 lines:
              0|mm       |     at Module._compile (internal/modules/cjs/loader.js:786:30)
              0|mm       |     at Object.Module._extensions..js (internal/modules/cjs/loader.js:798:10)
              0|mm       |     at Module.load (internal/modules/cjs/loader.js:645:32) {
              0|mm       |   code: 'MODULE_NOT_FOUND',
              0|mm       |   requireStack: [
              0|mm       |     '/home/pi/MagicMirror/modules/MMM-awesome-alexa/node_modules/snowboy/lib/node/index.js',
              0|mm       |     '/home/pi/MagicMirror/modules/MMM-awesome-alexa/node_helper.js',
              0|mm       |     '/home/pi/MagicMirror/js/app.js',
              0|mm       |     '/home/pi/MagicMirror/js/electron.js',
              0|mm       |     '/home/pi/MagicMirror/node_modules/electron/dist/resources/default_app.asar/main.js',
              0|mm       |     undefined
              0|mm       |   ]
              0|mm       | }
              0|mm       | [2020-12-20 16:31:29.816] [ERROR]  MagicMirror will not quit, but it might be a good idea to check why this happened. Maybe no internet connection?
              0|mm       | [2020-12-20 16:31:29.816] [ERROR]  If you think this really is an issue, please open an issue on GitHub: https://github.com/MichMich/MagicMirror/issues
              
              /home/pi/.pm2/logs/mm-out.log last 15 lines:
              0|mm       | [2020-12-20 16:31:29.774] [LOG]    No helper found for module: alert.
              0|mm       | [2020-12-20 16:31:29.775] [LOG]    Initializing new module helper ...
              0|mm       | [2020-12-20 16:31:29.776] [LOG]    Module helper loaded: updatenotification
              0|mm       | [2020-12-20 16:31:29.777] [LOG]    No helper found for module: clock.
              0|mm       | [2020-12-20 16:31:29.779] [LOG]    Initializing new module helper ...
              0|mm       | [2020-12-20 16:31:29.779] [LOG]    Module helper loaded: MMM-Remote-Control
              0|mm       | [2020-12-20 16:31:29.781] [LOG]    Initializing new module helper ...
              0|mm       | [2020-12-20 16:31:29.781] [LOG]    Module helper loaded: calendar
              0|mm       | [2020-12-20 16:31:29.782] [LOG]    Initializing new module helper ...
              0|mm       | [2020-12-20 16:31:29.783] [LOG]    Check MagicMirror version for node helper 'MMM-Ring' - Minimum version:  2.11.0 - Current version: 2.13.0
              0|mm       | [2020-12-20 16:31:29.783] [LOG]    Version is ok!
              0|mm       | [2020-12-20 16:31:29.784] [LOG]    Module helper loaded: MMM-Ring
              0|mm       | [2020-12-20 16:31:29.785] [LOG]    No helper found for module: MMM-DailyPokemon.
              0|mm       | [2020-12-20 16:31:29.991] [LOG]    Launching application.
              0|mm       | [2020-12-20 16:32:42.341] [LOG]    Shutting down server...
              

              I also did this code:

              		{
              		  module: "MMM-awesome-alexa",
              		  position: "bottom_bar",
              		  config: {
              		    wakeWord: "Alexa",
              		    clientId: "amzn1.application-oa2-client.0fa20b28debc4858a0acd193871bd8e1",
              		    clientSecret: "53e57d1db3d529ac84ee1b6f9d42d5339acfba752812aa4faf6efbb848aa39b4",
              		    deviceId: "MagicMirror_2",
              		  }
              		},
              

              and got this error:

              /home/pi/.pm2/pm2.log last 15 lines:
              PM2        | 2020-12-20T16:29:34: PM2 log: Stopping app:mm id:0
              PM2        | 2020-12-20T16:29:35: PM2 log: App [mm:0] exited with code [0] via signal [SIGINT]
              PM2        | 2020-12-20T16:29:35: PM2 log: pid=27383 msg=process killed
              PM2        | 2020-12-20T16:31:10: PM2 log: App [mm:0] starting in -fork mode-
              PM2        | 2020-12-20T16:31:10: PM2 log: App [mm:0] online
              PM2        | 2020-12-20T16:32:41: PM2 log: Stopping app:mm id:0
              PM2        | 2020-12-20T16:32:42: PM2 log: pid=27457 msg=failed to kill - retrying in 100ms
              PM2        | 2020-12-20T16:32:42: PM2 log: App [mm:0] exited with code [0] via signal [SIGINT]
              PM2        | 2020-12-20T16:32:42: PM2 log: pid=27457 msg=process killed
              PM2        | 2020-12-20T16:37:11: PM2 log: App [mm:0] starting in -fork mode-
              PM2        | 2020-12-20T16:37:11: PM2 log: App [mm:0] online
              PM2        | 2020-12-20T16:38:25: PM2 log: Stopping app:mm id:0
              PM2        | 2020-12-20T16:38:26: PM2 log: pid=27652 msg=failed to kill - retrying in 100ms
              PM2        | 2020-12-20T16:38:26: PM2 log: App [mm:0] exited with code [0] via signal [SIGINT]
              PM2        | 2020-12-20T16:38:26: PM2 log: pid=27652 msg=process killed
              
              /home/pi/.pm2/logs/mm-error.log last 15 lines:
              0|mm       |     at Module._compile (internal/modules/cjs/loader.js:786:30)
              0|mm       |     at Object.Module._extensions..js (internal/modules/cjs/loader.js:798:10)
              0|mm       |     at Module.load (internal/modules/cjs/loader.js:645:32) {
              0|mm       |   code: 'MODULE_NOT_FOUND',
              0|mm       |   requireStack: [
              0|mm       |     '/home/pi/MagicMirror/modules/MMM-awesome-alexa/node_modules/snowboy/lib/node/index.js',
              0|mm       |     '/home/pi/MagicMirror/modules/MMM-awesome-alexa/node_helper.js',
              0|mm       |     '/home/pi/MagicMirror/js/app.js',
              0|mm       |     '/home/pi/MagicMirror/js/electron.js',
              0|mm       |     '/home/pi/MagicMirror/node_modules/electron/dist/resources/default_app.asar/main.js',
              0|mm       |     undefined
              0|mm       |   ]
              0|mm       | }
              0|mm       | [2020-12-20 16:37:32.113] [ERROR]  MagicMirror will not quit, but it might be a good idea to check why this happened. Maybe no internet connection?
              0|mm       | [2020-12-20 16:37:32.114] [ERROR]  If you think this really is an issue, please open an issue on GitHub: https://github.com/MichMich/MagicMirror/issues
              
              /home/pi/.pm2/logs/mm-out.log last 15 lines:
              0|mm       | [2020-12-20 16:37:32.067] [LOG]    No helper found for module: alert.
              0|mm       | [2020-12-20 16:37:32.068] [LOG]    Initializing new module helper ...
              0|mm       | [2020-12-20 16:37:32.069] [LOG]    Module helper loaded: updatenotification
              0|mm       | [2020-12-20 16:37:32.071] [LOG]    No helper found for module: clock.
              0|mm       | [2020-12-20 16:37:32.072] [LOG]    Initializing new module helper ...
              0|mm       | [2020-12-20 16:37:32.074] [LOG]    Module helper loaded: MMM-Remote-Control
              0|mm       | [2020-12-20 16:37:32.075] [LOG]    Initializing new module helper ...
              0|mm       | [2020-12-20 16:37:32.076] [LOG]    Module helper loaded: calendar
              0|mm       | [2020-12-20 16:37:32.077] [LOG]    Initializing new module helper ...
              0|mm       | [2020-12-20 16:37:32.078] [LOG]    Check MagicMirror version for node helper 'MMM-Ring' - Minimum version:  2.11.0 - Current version: 2.13.0
              0|mm       | [2020-12-20 16:37:32.079] [LOG]    Version is ok!
              0|mm       | [2020-12-20 16:37:32.080] [LOG]    Module helper loaded: MMM-Ring
              0|mm       | [2020-12-20 16:37:32.082] [LOG]    No helper found for module: MMM-DailyPokemon.
              0|mm       | [2020-12-20 16:37:32.962] [LOG]    Launching application.
              0|mm       | [2020-12-20 16:38:26.368] [LOG]    Shutting down server...
              

              I’ll also say when I try to get to the dev console i get this error that stats couldn’t not connect…

              S 1 Reply Last reply Reply Quote 0
              • S Offline
                sdetweil @stalker401
                last edited by

                @stalker401 u didn’t finish the install. all 14 steps.

                Sam

                How to add modules

                learning how to use browser developers window for css changes

                S 1 Reply Last reply Reply Quote 0
                • S Offline
                  stalker401 @sdetweil
                  last edited by

                  @sdetweil lol i was racking my brain what i was doing wrong. I’ll go back and see what I missed thanks!

                  S 1 Reply Last reply Reply Quote 0
                  • S Offline
                    sdetweil @stalker401
                    last edited by sdetweil

                    @stalker401 i made a script out of the steps

                    https://www.dropbox.com/s/omrx3vztjp738hf/do-install.sh?dl=0

                    download, make it executable ( chmod +x do-install.sh)
                    and then execute it… (./do-install.sh)

                    the steps include the whole thing, git clone, and onward

                    Sam

                    How to add modules

                    learning how to use browser developers window for css changes

                    D 1 Reply Last reply Reply Quote 2
                    • S Offline
                      stalker401
                      last edited by

                      Thanks so much for your help. I got it up and working, and i see where I missed some early steps actually.

                      1 Reply Last reply Reply Quote 0
                      • S Offline
                        stalker401
                        last edited by

                        So i’m having another issue, but it’s not the installation. When I try to add an item to my calendar or remove one, alexa responds to me with a confirmation question. But does not listen for my response. Anyone else seen this issue, or has anyone dealt with this? I tried looking through the GitHub issues and searching online, but I couldn’t find anything.

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