Read the statement by Michael Teeuw here.
Help I need the MMM-MplayerRadio recipe for GA
-
I would like to use MMM-GoogleAssistant to command MMM-MplayerRadio,.
Does anyone happen to have a recipe for GoogleAssistant?
Thanks you in advance. -
-
I’ve been busy making something like that, using the recipe.template.js. But I’m not a programmer. This is what I made. The MMM-MPlayerRadio module works fine with controls from the screen, but I want to call it with GA. for example: Jarvis “play radio latina”, Jarvis…“play next”, Jarvis…“stop radio”, Jarvis…“previous radio”. Put the recipe in the GA recipe folder and added it to the config.js at GA recipe. But I need help with this? :downcast_face_with_sweat:
/** GoogleAssistant for MMM-MplayerRadio **/ /** recipe.template.js **/ /** @negrito **/ var recipe = { transcriptionHooks: { /* EN Language */ "START_RADIO" : { pattern : "music play", command: "RADIO_PLAY" }, "STOP_RADIO" : { pattern : "radio stop", command: "RADIO_STOP" }, "RADIO_PAUSE" : { pattern: "radio pause", command: "RADIO_PAUSE" }, "RADIO_NEXT" : { pattern: "radio next", command: "RADIO_NEXT" }, "RADIO_PREVIOUS": { pattern: "radio previous", command: "RADIO_PREVIOUS" }, }, commands: { "START_RADIO": { notificationExec: { notification: "MMM_RADIO-PLAY" }, soundExec: { chime: "open" } }, "STOP_RADIO": { notificationExec: { notification: "MMM_RADIO-STOP" }, soundExec: { chime: "close" } }, "PAUSE_RADIO": { notificationExec: { notification: "MMM_RADIO-PAUSE" } }, "NEXT_RADIO": { notificationExec: { notification: "MMM_RADIO-NEXT" }, }, "PREVIOUS_RADIO": { notificationExec: { notification: "MMM_RADIO-PREVIOUS" } } } } exports.recipe = recipe -
@negrito you’ve sorta got the voice/command/notification upsidedown
the notification is “RADIO_PLAY”
not “MM_RADIO_PLAY”
so the ‘command’ should be MM_RADIO_PLAY
which is referenced from the transcription sectionsame for all the others
-
@negrito I can give you a copy of mine if you like.
I’m using Google assistant version 3 -
-
@negrito so are you looking to play your own music or actually radio stations.
I have actually both. That worked pretty well -
@negrito Here is my radio set up
with my personal choices of radio stations.
I only have a couple right nowvar recipe = { transcriptionHooks: { "80+103.7 iHeartRadio From:tuneIn.com": { pattern: "Turn the radio on to 103", command: "103" }, "Radio.net 106.9 KFRC": { pattern: "Turn the radio on to 106", command: "106" }, "Radio.net 107.7 FM KSAN": { pattern: "Turn the radio on to 107", command: "107" }, "radio1": { pattern: "metti radio 1", command: "" // command line. }, "radioanni90": { pattern: "metti radio anni 90", command: "" }, "radio105": { pattern: "metti radio 105", command: "" }, "rds": { pattern: "metti rds", command: "" }, "rtl1025": { pattern: "metti rtl", command: "" }, "radiodj": { pattern: "metti radio dj", command: "" }, }, commands: { "103": { functionExec: { exec: () => { this.radioCommand({ img: "https://cdn-profiles.tunein.com/s33596/images/logod.jpg?t=162569", link: "https://n24a-e2.revma.ihrhls.com/zc4342?TGT=TuneIn&maxServers" }) } }, soundExec: { chime: "open" } }, "106": { functionExec: { exec: () => { this.radioCommand({ img: "https://www.radio.net/images/broadcasts/01/97/29350/c300.png", link: "https://19803.live.streamtheworld.com/KFRCHD2.mp3" }) } }, soundExec: { chime: "open" } }, "107": { functionExec: { exec: () => { this.radioCommand({ img: "https://www.radio.net/images/broadcasts/12/ce/29264/c300.png", link: "https://15363.live.streamtheworld.com/KSANFM.mp3" }) } }, soundExec: { chime: "open" } }, "": { // This must match what's in the command line. functionExec: { exec: () => { this.radioCommand({ img: "https://www.di-ma.info/radio/radio1.png", link: "http://icestreaming.rai.it/1.mp3" }) } }, soundExec: { chime: "open" } }, "": { functionExec: { exec: () => { module.radioCommand({ img: "https://www.di-ma.info/radio/r90.jpg", link: "http://mp3.hitradiort1.c.nmdn.net/rt190swl/livestream.mp3" }) } }, soundExec: { chime: "open" } }, "": { functionExec: { exec: () => { this.radioCommand({ img: "https://www.di-ma.info/radio/r105.jpg", link: "http://icecast.unitedradio.it/Radio105.mp3" }) } }, soundExec: { chime: "open" } }, "": { functionExec: { exec: () => { this.radioCommand({ img: "https://www.di-ma.info/radio/rds.png", link: "https://icstream.rds.radio/rds" }) } }, soundExec: { chime: "open" } }, "": { functionExec: { exec: () => { this.radioCommand({ img: "https://www.di-ma.info/radio/rtl1025.png", link: "https://streamingv2.shoutcast.com/rtl-1025" }) } }, soundExec: { chime: "open" } }, "": { functionExec: { exec: () => { this.radioCommand({ img: "https://www.di-ma.info/radio/radiodj.png", link: "http://radiodeejay-lh.akamaihd.net/i/RadioDeejay_Live_1@189857/master.m3u8" }) } }, soundExec: { chime: "open" } }, } } exports.recipe = recipeLet me know if you want the other one that will play your personal music
-
-
@negrito hope it works out for you. Happy to assist
-
-
@negrito sorry to hear that you do have version 3 of Google assistant
is that right -
@negrito as written the recipe takes a specific voice command
"Turn the radio on to 103"to tune a specific station…
did u modify the voice command and/or station info , or trying to use it as provided?
if as is, you have to say
assistant/jarvis/… “Turn the radio on to 103”
right?
-
Because I’m kind sometime…
I found this in archived GA repo
-
@sdetweil sorry it took so long to reply back. I’ve been kinda busy.
So yes, if you want to listen to the radio station 103 you would sayJarvis Turn the radio on to 103
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login