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

    Posts

    Recent Best Controversial
    • RE: mmm-nest-status unresponsive after 12hours

      It’s been 24 hours and still working fine! Thanks!

      posted in Troubleshooting
      R
      rts58
    • RE: mmm-nest-status unresponsive after 12hours

      @sdetweil just got the update, I’ll let you know what I find. Thanks!

      posted in Troubleshooting
      R
      rts58
    • RE: mmm-nest-status unresponsive after 12hours

      Based upon the display, it stopped on me last night. I was running mm serveronly so I could see the dev output in browser. I couldn’t find any errors. It could have stopped when scheduler is set to hide all modules. I did see this in the console after this mornings schedule to show modules:

      Whoops! There was an uncaught exception...
      TypeError: Cannot read property 'statusCode' of undefined
          at Request._callback (/home/pi/MagicMirror/modules/mmm-nest-status/node_helper.js:20:25)
          at self.callback (/home/pi/MagicMirror/node_modules/request/request.js:185:22)
          at emitOne (events.js:116:13)
          at Request.emit (events.js:211:7)
          at Request.onRequestError (/home/pi/MagicMirror/node_modules/request/request.js:881:8)
          at emitOne (events.js:116:13)
          at ClientRequest.emit (events.js:211:7)
          at TLSSocket.socketErrorListener (_http_client.js:401:9)
          at emitOne (events.js:116:13)
          at TLSSocket.emit (events.js:211:7)
      MagicMirror will not quit, but it might be a good idea to check why this happened. Maybe no internet connection?
      

      In the past I don’t think I ever had a conflict between scheduler and nest status.

      posted in Troubleshooting
      R
      rts58
    • RE: mmm-nest-status unresponsive after 12hours

      I tried to open the console via remote but wasn’t able to. Sorry.

      posted in Troubleshooting
      R
      rts58
    • RE: mmm-nest-status unresponsive after 12hours

      Bummer, mine has stopped as well.

      posted in Troubleshooting
      R
      rts58
    • RE: mmm-nest-status unresponsive after 12hours

      I also have been having the same issue with this module. It worked well for months. I’ve just been restarting and haven’t had time to chase down the errors.

      posted in Troubleshooting
      R
      rts58
    • RE: Control MagicMirror from Alexa?

      I have 2nd gen echo’s

      posted in Troubleshooting
      R
      rts58
    • RE: [Remote-Control] Shutdown, Configure and Update your MagicMirror

      That changed worked for me. I also had issue of white screen on my phone. After the change above and restarting phone, works fine now.

      posted in System
      R
      rts58
    • RE: Control MagicMirror from Alexa?

      @jrotondo I’m using AlexaOnOff which allows me some control over MM.

      Here is the thread.

      posted in Troubleshooting
      R
      rts58
    • New weather module (develop branch) not updating

      I’ve noticed recently that the new weather module in the develop branch stops updating. I got this error in the developer console:

      2cors-anywhere.herokuapp.com/https://api.darksky.net/forecast/mykey/mylatlong?units=us&lang=en Failed to load resource: the server responded with a status of 503 (Service Unavailable)
      0.0.0.0/:1 Failed to load https://cors-anywhere.herokuapp.com/https://api.darksky.net/forecast/mykey/mylatlong?units=us&lang=en: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://0.0.0.0:8080' is therefore not allowed access. The response had HTTP status code 503.
      

      If the service is unavailable shouldn’t the weather module update once it is available?

      If I restart MM, the module will update properly and work for about a day.

      posted in Bug Hunt
      R
      rts58
    • RE: Best way to display recipe

      @mykle1 Great, thanks, I’ll take a look at the voice modules and see what I can come up with. I also just found MMM-ImageFileWatcher which looks like it may do a lot of what I was looking for.

      posted in Development
      R
      rts58
    • RE: Best way to display recipe

      @justjim1220 thank you, I just looked at it again. I thought it was pulling a daily menu from somewhere, not a way of displaying a specific recipe. Where do the recipes come from?

      posted in Development
      R
      rts58
    • Best way to display recipe

      Hi, my MM is actually a kitchen display. Currently it is showing calendar, weather, news, nests, and background images. I’m looking for the best way to shutdown current modules and display a recipe full screen. My first thought was to send the web page link via MagicRemote and use pages to switch to a page that would only show the page in an iframe. However, it looks like most pages don’t like to be displayed in iframe. Second thought was to save page as an image, and have MM look for a file in remote location and if it finds it, close other modules and display the image. Has anyone done something like this already, or have a suggestion for a better approach?

      Thanks!

      posted in Development
      R
      rts58
    • RE: Module help for variable

      @sdetweil Thanks, I got it. I needed to get rid of “this”. So the correct test was:

      if (!(oldAwayState === awayState) && (awayState === 'home')) 
      
      posted in Troubleshooting
      R
      rts58
    • RE: Module help for variable

      @sdetweil thanks, I’ll give that a try. I’ve been writing the variables to the consol log but it’s not quite as helpful.

      posted in Troubleshooting
      R
      rts58
    • RE: Module help for variable

      Is there something wrong with this:

      if (!(this.oldAwayState === awayState) && (this.awayState === 'home')) 
      

      maybe they are both not strings or something?

      posted in Troubleshooting
      R
      rts58
    • RE: Module help for variable

      That’s what I thought. But it still fires off every two minutes, there must be an error in the logic.

      posted in Troubleshooting
      R
      rts58
    • RE: Module help for variable

      Thank you @sdetweil ! So that helps me to create the module level variable. Sorry for dumb question, but how to I read/write it from within my process data function? I thought using this.oldAwayState would be the module level.

      posted in Troubleshooting
      R
      rts58
    • Module help for variable

      Hi,
      I’ve created a small module to turn my monitor off when my nest realizes I’ve left the house. This uses a notification from mmm-nest-status. Since I’m a noob I don’t understand how to keep track of a variable between notifications. I’m guessing I need something in start: ? Here is the code:

      Module.register("controlMonitor", {
      	defaults: {},
      	notificationReceived: function(notification, payload, sender) {
      		if (notification === 'MMM_NEST_STATUS_UPDATE') {
                  this.processData(payload);
      		}
      	},
      	processData: function(data) {
      		var awayState = 'unknown'; // 'home', 'away'
      		// check for away state
      		if (data.devices && data.structures) {
      			var sId = Object.keys(data.structures)[0];
      			var sObj = data.structures[sId];
      			awayState = sObj.away;
      		}
      		var oldAwayState = this.awayState;
      		this.awayState = awayState;
      		// if state has changed and new is away then shut monitor off
      		if (!(this.oldAwayState === awayState) && (this.awayState === 'away')) {
      			//this.sendNotification("REMOTE_ACTION", {action: 'MONITOROFF'});
      				console.log(this.name + "awayState " + awayState + "oldAwayState " + oldAwayState + " " + this.datetime4log());
      		}
      		// if state has changed and new is home then turn monitor on
      		if (!(this.oldAwayState === awayState) && (this.awayState === 'home')) {
      			//this.sendNotification("REMOTE_ACTION", {action: 'MONITORON'});
      				console.log(this.name + "awayState " + awayState + "oldAwayState " + oldAwayState + " " + this.datetime4log());
      		}
      	},
      	datetime4log: function() {
      		var d = new Date();
      		return (d.getMonth()+1) + "/" + d.getDate() + "/" + d.getHours() + ":" + d.getMinutes() + ":" + d.getSeconds();
      		}
      });
      
      

      What’s happing now is the home state is firing off every 2 minutes for every notification. I need a module level oldAwayState variable, so the when I get the update I can test against it to only fire off an update if there is a change.

      Thanks

      posted in Troubleshooting
      R
      rts58
    • RE: module for mm background

      @surger13, I did it similar in way as @sdetweil but with extra steps:frowning_face: . I set up a new directory hpmv in the module folder with a symbolic link to the mounted directory in my case ~/Pictures/hpmv. Which required changing the imagePaths setting in config. I had challenges with getting the link to automount after rebooting. I finally got it to work without errors with this entry in /etc/fstab:
      //my.Nas.Ip.Addr/Photos /home/pi/Pictures/hpmv cifs guest,x-systemd.automount,vers=1.0 0 0 and by also using raspi-config setting to wait for network on boot.
      ​

      posted in Requests
      R
      rts58
    • 1
    • 2
    • 3
    • 2 / 3