Activate Profiles (via MMM-ProfileSwitcher) using MMM-Remote-Control...



  • Hi all,
    I’m trying to switch profiles with the MMM-Remote-Control module via notifications to the MMM-ProfileSwitcher module.
    But I can’t get it to work. I do get the MMM-ProfileSwitcher to “switch” but only to a profile called [object Object].
    My profile in this case is called “Snille”.
    The Profile Switcher work otherwise with the MMM-Touch-Navigation module, so it’s not broken otherwise. :)

    Iv’e tried with the following URL (and variants of that):
    http://MagicMirorIP:8080/remote?action=NOTIFICATION&notification=CURRENT_PROFILE&payload={“Profile”:“Snille”}
    As long as the “json” is ok at the end I get the “Switched to profile [object Object]” on the mirror. But, of course I don’t have any “[object Object]” profile. :)
    I do get a: {“status”:“success”} from the MMM-Remote-Control as well (as long as the “json” string is ok as well).
    Anybody have any idea? :)



  • http://MagicMirorIP:8080/remote?action=NOTIFICATION¬ification=CURRENT_PROFILE&payload={Profile:“Snille”}

    What about if you remove the double quotes from Profile? Just a guess.



  • @mortenbirkelund {“status”:“Unexpected token P in JSON at position 1”}

    Tried that… :)


  • Moderator

    @Snille It is not an object, that you are supposed to send, see the documentation, just a simple string, i.e. ...?action=NOTIFICATION¬ification=CURRENT_PROFILE&payload=%22Snille%22.



  • @Jopyth said in Activate Profiles (via MMM-ProfileSwitcher) using MMM-Remote-Control...:

    %22Snille%22

    Oh! Works! :) I can’t believe that I did not try that… Thank you! :)



  • Bonus for anyone who wounder why I wanted to do this…

    I’m a user of “Alexa” (Amazons Echo Dot). I have 6 dots in my house. I wanted to be able to interact with the mirror with Alexa. And, yes I know there are lot’s of modules and stuff out there for this. But I have tried and not been satisfied with different modules/solutions that I found.

    Now, It happens I already use a small software called “HA-Bridge” for controlling all kind of things using Alexa (for example all my lights via Z-Wave using a Fibaro HC2 controller). So this software can be configured to “visit” URL:s when called up on with a voice command though Alexa (in reality HA emulates a Philips HUE light that Alexa can “find” under “Smart House”, that give 3 different commands: On, off and dim.). This opens up a sea of opportunities as you can imagine. :)

    So, now I say: “Alexa, turn on Snilles Mirror” to view my profile. (Switches to my profile)
    Or: “Alexa, turn off Mirror Screen.” (Monitor off)
    Or: “Alexa, turn off Mirror” (Shutdown the mirror)
    And so on…
    Yes… Imagine the possibilities. :)


Log in to reply
 

Looks like your connection to MagicMirror Forum was lost, please wait while we try to reconnect.