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

    Posts

    Recent Best Controversial
    • RE: MMM-OpenWeatherForecast - Replacement for MMM-DarkSkyForecast

      @shiryu1031 The screenshots you see in GitHub were incorrect. My old code for Dark Sky was using km/h, and I hadn’t replaced the label with m/s when I took these screen shots. So the screenshots are actually illustrating a bug! The actual speed value shown is m/s, but the label is incorrect as km/h. :beaming_face_with_smiling_eyes:

      I thought about it, and it would take me just as much time to fix the screen shots as it would to add the capability to convert m/s into km/h. So now there is a new config parameter: displayKmhForWind. If you add this to your config and set it to true, m/s wind speed will be converted and displayed as km/h. This parameter only works when units is set to "metric" or "standard". If you’re using "imperial" you will always see mph.

      Do a git pull in your installed MMM-OpenWeatherForecast directory to get the updated code.

      posted in Utilities
      J
      j.e.f.f
    • RE: MMM-OpenWeatherForecast - Replacement for MMM-DarkSkyForecast

      @oberfragger

      There is only one property that is used for both sunrise and sunset: label_sunriseTimeFormat. In your example above, you’ve specified hh:mm for this property, which displays 12h time, not 24h time.

      Change your config from this:

      iconset: "3c",
      label_hourlyTimeFormat: "k[ Uhr]",
      label_sunriseTimeFormat: "hh:mm",
      label_sunsetTimeFormat: "k:mm",
      label_days: ["So", "Mo", "Di", "Mi", "Do", "Fr", "Sa"]
      

      to this:

      iconset: "3c",
      label_hourlyTimeFormat: "k[ Uhr]",
      label_sunriseTimeFormat: "k:mm",  // change the format for this one 
      label_days: ["So", "Mo", "Di", "Mi", "Do", "Fr", "Sa"]
      
      posted in Utilities
      J
      j.e.f.f
    • RE: MMM-OpenWeatherForecast - Replacement for MMM-DarkSkyForecast

      @karsten13 I don’t think there is much I can do here. I’ve coded this module to explicitly pass through a language parameter, either whatever is set in your main MM config, or whatever you explicitly set in the module’s config. It seems that OpenWeather doesn’t translate the weather alert, but merely passes them on as-is from whatever source it gets them from. Which is why sometimes you’re getting only English, and other times you’re getting multiple translations.

      posted in Utilities
      J
      j.e.f.f
    • RE: MMM-OpenWeatherForecast - Replacement for MMM-DarkSkyForecast

      @swvalenti yes you can. The weather alerts are part of the summary section. OpenWeather returns such a short summary that I didn’t think it necessary to make two separate configure. Two ways to turn off the alerts:

      • set summary : false
      • if you want the summary but not the alerts, you can hide them in your custom css as follows:
      .MMM-OpenWeatherForecast .weather-alert {
        display: none;
      }
      

      I think I’ll look at a way to truncate weather alerts so they don’t take up so much space.

      posted in Utilities
      J
      j.e.f.f
    • RE: MMM-OpenWeatherForecast - Replacement for MMM-DarkSkyForecast

      @shiryu1031 you can’t do that independently on the main units setting. OpenWeather returns mph for imperial, and m/s for standard and metric.

      posted in Utilities
      J
      j.e.f.f
    • RE: MMM-OpenWeatherForecast - Replacement for MMM-DarkSkyForecast

      @dkhorse74 that’s the main header for the module. Change it like this:

        {
          module: "MMM-OpenWeatherForecast",
          position: "top_right",
          header: "Forecast",  <— here
          config: {
            apikey: "a1b2c3d4e5f6g7h8j9k0", //only string here
            latitude: 51.490230,            //number works here
            longitude: "-0.258810"          //so does a string
          }
        },
      
      posted in Utilities
      J
      j.e.f.f
    • RE: MMM-OpenWeatherForecast - Replacement for MMM-DarkSkyForecast

      @anubis273 I just tried the default config with your long/lat settings and the module worked for me. So let’s try digging a little more. Are you seeing any errors in the logs? There are a bunch of places to look:

      If you are running MagicMirror using PM2, run pm2 restart mm && pm2 logs mm. Look for any output prefixed with [MMM-OpenWeatherForecast]. If you are instead running MagicMirror from the command line, any errors will be in the in the console, prefixed like above.

      Also need to check to see if Electron is throwing any errors. start MagicMirror in dev mode npm start dev. Any Electron errors will show in the browser console, usually in red.

      Also, since the basic config isn’t working for you, but is for me, can you double check that your API Key is correct?

      • Jeff
      posted in Utilities
      J
      j.e.f.f
    • RE: MMM-OpenWeatherForecast - Replacement for MMM-DarkSkyForecast

      @anubis273 This module works on 2.14 – tested that specifically myself. MagicMirror’s version numbering can get a bit confusing… 2.14 is MUCH newer than 2.2. Versioning goes 2.2, 2.3, … 2.9, 2.10, 2.11, etc.

      Double check your config settings. Maybe try with just the minimal config required for MMM-OpenWeatherForecast – apikey, latitude, and longitude – and see if the module works with just those. Also make sure you’ve run npm install in the MMM-OpenWeatherForecast directory.

      If the module runs with just the above, then start adding your additional configuration options one at a time to see which one caused it to fail. Let me know and we can take it from there.

      posted in Utilities
      J
      j.e.f.f
    • RE: Help please

      @innovation There are a few ways to do this. I’ve done this for a kitchen display where I have several pages that rotate in sequence, but are also controlled manually with an IR remote control (using the LEFT/RIGHT buttons to go to previous.next pages).

      I’m using a combination of the Profile Switcher module (https://github.com/tosti007/MMM-ProfileSwitcher.git) and my own Profile Carousel module the I wrote to handle input from the IR remote (https://github.com/jclarke0000/MMM-ProfileCarousel).

      My config looks like this:

          {
            module: "MMM-ProfileSwitcher",
            disabled: false,
            config: {
              defaultClass: "L_CALENDAR",
              everyoneClass: "L_ALL",
              includeEveryoneToDefault: true,
              defaultTime: 10000,
              useLockStrings: true
              // animationDuration: 500,
              // timers: {
              //   "L_CALENDAR" : {
              //     profile: "L_FORECAST"
              //   },
              //   "L_FORECAST" : {
              //     profile: "L_CALENDAR"
              //   }
              // }
            }
          },
      
          {
            module: "MMM-ProfileCarousel",
            disabled: false,
            config: {
              profiles: ["L_CALENDAR","L_FORECAST","L_NOTES"],
              carouselDelay: 10000, //10 seconds
              carouselResumeDelay: 1 * 30 * 1000, //30 seconds
              useScreensaver: true,
              screensaverProfile: "L_WORDCLOCK",
              screensaverTimeout: 1.25 * 60 * 1000,
              screensaverBlackoutPeriod: {
                start: 11,
                end: 12
              }        
            }
          },
      

      And every module has one or more class names applied that indicate which profile the module should be visible for:

      The clock module is visible for all profiles, so it looks like this:

          {
            module: "clock",
            position: "top_left",
            classes: "L_CALENDAR L_FORECAST L_NOTES",
            config: {
              timeFormat: 12,
              showPeriod: true,
              displaySeconds: false
            }
          },
      

      While my weather module is only available on one page, so it looks like this:

          {
            module: "MMM-OpenWeatherForecast",
            position: "top_right",
            header: "Forecast",
            classes: "L_FORECAST",
            disabled: false,
            config: {
      

      In your case, you’ll need to work with one of the Voice modules to provide input to Profile Switcher. You can explicitly set the current profile using the sendNotification function:

        this.sendNotification("CURRENT_PROFILE",  "profile name"); 
      
      posted in Development
      J
      j.e.f.f
    • RE: MMM-OpenWeatherForecast - Replacement for MMM-DarkSkyForecast

      @majorc said in MMM-OpenWeatherForecast - Replacement for MMM-DarkSkyForecast:

      @cowboysdude it would be nice if someone with knowledge could have a look at the API of www.yr.no

      The forecast is very good and they are providing free world wide data.

      This looks promising, and seemingly doesn’t require an API key. I’ll keep an eye on this as a replacement candidate in case OpenWeather follows Dark Sky’s lead.

      posted in Utilities
      J
      j.e.f.f
    • 1
    • 2
    • 3
    • 4
    • 5
    • 6
    • 68
    • 69
    • 4 / 69