• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
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.

AVStock not responding to Hello-Lucy commands/notifications

Scheduled Pinned Locked Moved Utilities
2 Posts 2 Posters 490 Views 2 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.
  • B Offline
    bazil1000
    last edited by Jul 7, 2019, 4:13 AM

    Hi day @Mykle1,
    Thanks so much for your work on this module. Just great functionality and elegant solution. Being able to control individual modules visibility is a massive help!! :)

    I personally am still pretty new to this so you’ll need to forgive my ignorance off the bat. I’ve installed MM along with a good range of modules, including Hello Lucy. One module in particular, namley AVStock, is however giving me grief and doesn’t appear to be responding to the hide/show commands.

    Would you mind helping me with it? I’ve incorporated the code exactly as suggested and i can’t for the life of me work out why the module isn’t responding when the others are? I’ve even had other check it for me. Have you had any experience using this module? Do instructions differ at all?

    Also is there a way to view the contents of variables in an “online / debug” mode? If so how? (please forgive the stupid question)

    M 1 Reply Last reply Jul 9, 2019, 1:30 AM Reply Quote 0
    • M Offline
      Mykle1 Project Sponsor Module Developer @bazil1000
      last edited by Jul 9, 2019, 1:30 AM

      @bazil1000 said in AVStock not responding to Hello-Lucy commands/notifications:

      Would you mind helping me with it?

      Wow. I didn’t think anyone was using Lucy these days. Yes, I’ll do what I can to help you. I took a look at the AVStock.js file. I see the getDom function closes at line 47. I assume you made your modification at line 48

        getDom: function() {
          var wrapper = document.createElement("div")
          wrapper.id = "AVSTOCK"
          return wrapper
        },
      
      notificationReceived: function(notification, payload) {
              if (notification === 'HIDE_STOCK') {
                  this.hide();
              }  else if (notification === 'SHOW_STOCK') {
                  this.show(1000);
              }        
          },
      

      It can be tedious but you’ll have to check and recheck your other modifications. Check that you’ve changed the command words and that they all match in each modification.

      This one
      One in the new node_helper
      Two in the new MMM-voice.js file

      I don’t use AVStock but Lucy should work. Any time Lucy failed to work it was always an oversight on my part. Please do this first. If it still doesn’t work we may have to move the notificationReceived function or add the modification to the existing notificationReceived function that is already present in MMM-AVStock.js file. Keep me posted. Sorry for the delay in response

      Create a working config
      How to add modules

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