Read the statement by Michael Teeuw here.
Default Weather Updates not working
-
I seem to be having an intermittent problem with getting weather updates. I am using the default weather module, and I am aware of the issues with using some of the different providers. But I have read that using the Pirate Weather API would work. I have configured my MM to display both the current weather conditions and a second display of the weekly forecast. Initially, everything works as expected. But eventually, either my current weather display OR my weekly forecast will stop providing updated information. Whenever I reboot/restart my MM, the problem is resolved and I get the correct information.
I understand that Pirate Weather allows 10,000 API calls per month. I set the first update interval to 600,000 (every 10 minutes) and the second one to 1,800,000 (every half hour). I assume this results in 8 calls per hour or just under 6,000 calls per month. So, I don’t believe that I am exceeding the call limitation. Also, the fact that a reboot will fix the problem would indicate that this is not a call limitation issue.
I have read that others have run into problems which they resolved by offsetting the times when the call requests are sent by adjusting the ‘initialLoadDelay’ value. I have set that value to ‘5000’ on my second display (value not set on the first display).
I set my MM to restart every week (via crontab) so I can get an idea if the problem re-occurs at a specific point. I attempt to monitor the uptime whenever I see the problem. It doesn’t seem to have a pattern. It can fail after two days, or three days, four days, etc. Sometimes, it will work for the entire week, and my MM will restart and reset the uptime clock.
The failure can appear on the current conditions (ie. the displayed temperature is ‘stuck’ at the same value for days), or it can appear on the weekly forecast (ie. the days of the week will not change). It seems to be random. I know that if I just wait a few days, it will get resolved on its own, but I would prefer to get an idea on how to fix this so that the display is correct all the time. Any ideas?
Thanks in advance.
{ module: "weather", position: "top_right", config: { type: "current", weatherProvider: "pirateweather", apiBase: "https://api.pirateweather.net", weatherEndpoint: "/forecast", apiKey: "my API key", lat: "my latitude", lon: "my longitude", tableClass: "medium", colored: "true", fadePoint: "0.50", maxNumberOfDays: "1", updateInterval: "600000", degreeLabel: "true" },
},
{ module: "weather", position: "top_right", config: { type: "forecast", Header: "true", appendLocationNameToHeader: "true", weatherProvider: "pirateweather", apiBase: "https://api.pirateweather.net", weatherEndpoint: "/forecast", apiKey: "my API key", lat: "my latitude", lon: "my longitude", tableClass: "small", colored: "true", fadePoint: "0.50", maxNumberOfDays: "7", updateInterval: "1800000", degreeLabel: "true", initialLoadDelay: "5000" },
},
-
@Freddy_boy weather is done all in browser, so you would have to look in the developer window console tab
crrl-shift-i
or install
MMM-LogExt or MMM-Logging which will send the browser log to the npm start log -
@Freddy_boy Just out of interest, why use multiple instances for current and forecast if you can get both in a single module? There are a few different modules that provide the combined view.
My apologies, just want to know out of interest.
Below is an example of both rolled into one.
-
@mumblebaj
Wow! That looks like just what I would need… What module is that? I thought that sticking to the default modules would be advantageous but maybe that is a better solution. -
@Freddy_boy You can have a look at the following link.
This is my forked version which works and caters for different providers.
-
@mumblebaj
I installed the module and it looks good! I will continue to monitor for the next while to see if the updates continue to work. Thanks!