MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    1. Home
    2. LincolnClay
    3. Posts
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.
    L
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 4
    • Posts 11
    • Groups 0

    Posts

    Recent Best Controversial
    • Voicecontrol interaction with compliments

      Hi, I am using the voicecontrol by alexya and I am trying to display a message on the mirror after saying a hotword. Because this is a one-time thing, I figured I could use the compliments module to display the message.

      I have downloaded the .pmdl file from Snowboy, but I still struggle to implement the code in the compliments module.
      This is how my config file looks like:

      {
      			module: 'voicecontrol',
      			position: 'bottom_left',
      			config: {
      				models: [
      					{
      						keyword: "Test",   // keyword 
      						description: "Say 'Test",
      						file: "Test.pmdl", // trained model file name
      						message: "PLAY_MUSIC"   // notification message that's broadcast in the MagicMirror app
      					},
      				]
      			}
      		},
      

      Obvously I know PLAY_MUSIC is incorrect, but I still havent found out what the correct command would be to display the message in the compliments module.

      Also if I understood it correctly the following code is suppsoed to go within the compliments.js file.

      notificationReceived: function(notification, payload, sender) {
      		if (notification === "Test"){
      			this.media.play();
      		}
      	},
      

      What should I replace with PLAY_MUSIC and this.media.play(); to display a message from the compliments module ?

      And how do I specify what kind of message that get displayed?

      posted in Troubleshooting
      L
      LincolnClay
    • RE: MMM-Ruter (for Oslo and Akershus in Norway)

      @Cato I’m sorry for the late reply, I had to figure out if there was any issues with my initial MM install. You where absolutely right, the issue had nothing to do with the module. I did a re-install and now the module works perfectly. Thanks for your help and your work on this module :)

      posted in Transport
      L
      LincolnClay
    • RE: Settings in config.js aren't loaded after reboot of RasPi

      @morozgrafix sorry for the late reply, I didn’t want to waste your troubleshooting the MagicMirror files, my suspicion was that these problems where caused by my autoboot fix for vnc-server. Which indeed was the issue. After a new clean install NOOBS install with a lot of less sudo's than the first time. Everything now works perfectly. I am definitely not the right person to talk about this stuff, but I think the problem was caused by a " No session for PID XXXX" error at every launch.
      Anyways, I really appreciate you taking your time to help. I wouldn’t have found all my problems and fixes without it :)

      posted in Troubleshooting
      L
      LincolnClay
    • RE: Settings in config.js aren't loaded after reboot of RasPi

      @morozgrafix I really appreciate in depth answer. I am sorry for hijacking this thread, I had no intention to do so. I in fact closed my thread because I thought your last suggestion resolved my issues permanently. This was before I realized I got a new issue after rebooting my raspberry.

      Regarding your questions:

      Yes, I deleted the MagicMirror directory from /home/pi, before the re-install.

      I checked if pi had full access and it did.

      drwxr-xr-x  15 pi   pi   4096 Jan 21 23:10 MagicMirror
      -rwxr-xr-x   1 pi   pi     38 Jan 21 14:37 mm.sh
      -rwxr-xr-x   1 pi   pi     38 Jan 21 14:43 mm.sh.save
      drwxr-xr-x 154 root root 4096 Jan 19 18:18 node_modules
      
      

      Regarding if I saved the /config folder files: Yes, I copied the edited text from /home/pi/MagicMirror/config.js and pasted it in config.js.sample both where saved. What I meant was after I have edited these files, MM starts with my desired weather and news info, which I input in the /config files. So before reboot, MM is not displaying any default settings.

      When the raspberry is rebooted, MM now starts with default settings, even though the files in /config is exactly the same as before the reboot. (still in /home/pi/MagicMirror/config with edited text as before).

      posted in Troubleshooting
      L
      LincolnClay
    • Settings in config.js aren't loaded after reboot of RasPi

      @morozgrafix Thanks for the feedback. I did a re-install without the all the sudo commands. However I am running into a new problem now. After some other installations earlier I turned my raspberry off. When I turned it on again, and did a npm start from /MagicMirror MM started but it doesn’t seem to get the config.js file from /MagicMirror/Config. I have changed the file to match my local weather etc. When I start MM now after a full shutdown, I get the standard info displayed on MM. I did a sudo halt before I unplugged my raspberry.

      Edit: Getting the following errors:
      0_1485033314437_23dd.PNG

      posted in Troubleshooting
      L
      LincolnClay
    • RE: MMM-Ruter (for Oslo and Akershus in Norway)

      @Cato Thanks for the prompt response. Yes I installed pm2, but when run pm2 restart mm MM doesn’t open. I only get successful starts with npm start.

      If I delete the insertion in config.js file from your module, mm starts normally without being all black. Do you spot any other errors?

      posted in Transport
      L
      LincolnClay
    • RE: MMM-Ruter (for Oslo and Akershus in Norway)

      Hi @Cato. Great work on this very practical module.
      I am just getting into raspberry pi (3) and MM, so this is the first module i try to install. Unfortnatly when I run MM it goes black. I guess there is something with how I inserted the module in the config.js file.
      This is how I did it.
      0_1485001911821_321d.PNG

      Also this is what the terminal with the same config.js file.

      //pi@raspberrypi:~/MagicMirror $ npm start
      
      > magicmirror@2.1.0 start /home/pi/MagicMirror
      > electron js/electron.js
      
      Xlib:  extension "RANDR" missing on display ":1.0".
      Starting MagicMirror: v2.1.0
      Loading config ...
      Loading module helpers ...
      No helper found for module: MMM-Ruter.
      No helper found for module: alert.
      Initializing new module helper ...
      No helper found for module: clock.
      Initializing new module helper ...
      No helper found for module: compliments.
      No helper found for module: currentweather.
      No helper found for module: weatherforecast.
      Initializing new module helper ...
      All module helpers loaded.
      Starting server op port 8080 ... 
      Server started ...
      Connecting socket for: updatenotification
      Connecting socket for: calendar
      Starting node helper for: calendar
      Connecting socket for: newsfeed
      Starting module: newsfeed
      Sockets connected & modules started ...
      Whoops! There was an uncaught exception...
      { Error: listen EADDRINUSE :::8080
          at Object.exports._errnoException (util.js:1026:11)
          at exports._exceptionWithHostPort (util.js:1049:20)
          at Server._listen2 (net.js:1253:14)
          at listen (net.js:1289:10)
          at net.js:1399:9
          at _combinedTickCallback (internal/process/next_tick.js:77:11)
          at process._tickCallback (internal/process/next_tick.js:98:9)
          at Module.runMain (module.js:592:11)
          at run (bootstrap_node.js:402:7)
          at startup (bootstrap_node.js:157:9)
        code: 'EADDRINUSE',
        errno: 'EADDRINUSE',
        syscall: 'listen',
        address: '::',
        port: 8080 }
      MagicMirror will not quit, but it might be a good idea to check why this happened. Maybe no internet connection?
      If you think this really is an issue, please open an issue on GitHub: https://github.com/MichMich/MagicMirror/issues
      Xlib:  extension "XInputExtension" missing on display ":1.0".
      Xlib:  extension "RANDR" missing on display ":1.0".
      Launching application.
      Xlib:  extension "XInputExtension" missing on display ":1.0".
      Xlib:  extension "XInputExtension" missing on display ":1.0".
      
      
      posted in Transport
      L
      LincolnClay
    • RE: Npm start...

      @morozgrafix Thank you so much for this. I finally got it up and running following your method.
      I did it on a Raspberry pi 3 and after adding in a few more sudo’s it worked!

      sudo apt-get install git
      sudo git clone https://github.com/MichMich/MagicMirror.git
      sudo curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash -
      sudo apt-get install -y nodejs
      node --version
      sudp curl -sL https://www.npmjs.com/install.sh | sudo -E bash -
      npm --version
      cd MagicMirror/
      sudo cp config/config.js.sample config/config.js
      sudo npm install
      npm start
      
      posted in Troubleshooting
      L
      LincolnClay
    • 1 / 1