Read the statement by Michael Teeuw here.
My first module
-
@gismo2006 try to debug where you’re module is getting stuck like this
notificationReceived: function(notification, payload, sender) { if (notification === "test"){ Log.info("test notification received"); exec("sudo /home/pi/MagicMirror/modules/Sounds/Sounds.sh"); } },
if you don’t see this message in the dev console you propably misconfigured your voice command
-
Ok I will do what you say.
Ok I have done
I have found the Problem. the dev consoles says
Sounds.js:15 Uncaught ReferenceError: exec is not defined.
Can i delete the word exec? But I think I have to use it to run the script, right?
greets gismo
-
@gismo2006 yeah you have to create a node_helper to run the script and send a socketnotification t the node_helper and there you can run the script
-
Ok, Thank you for your help. I will try myself to go this next step…
-
@gismo2006 https://github.com/fewieden/MMM-voice/blob/f9eb4cd4bde5c64ef894e8625250c4092aa0d4a7/node_helper.js
line 10, 23-31, 213 will help you
-
Thank you I have looked in the notification Node_helper.js code which was posted in the Voicecontrol post from @tyho. And it works now fine. Now I can learning something new. To grow up my modul and finding a really reason for my module :-D
But I like to say Thank you. You helped me a lot. :-)
greets gismo
-
@gismo2006 no worries, if you come up with more questions don’t hesitate to ask