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

    siujd2001

    @siujd2001

    0
    Reputation
    1
    Profile views
    11
    Posts
    0
    Followers
    0
    Following
    Joined
    Last Online

    siujd2001 Unfollow Follow

    Latest posts made by siujd2001

    • RE: MMM-PIR Busy Issue

      @redfishbluefish

      Thank you. I will look at ddcutil mode next and update.

      posted in Troubleshooting
      S
      siujd2001
    • RE: MMM-PIR Busy Issue

      @redfishbluefish

      Switching to mode:0 does now appear to work, in that there is no gpio error and ctrl-q and restarts don’t throw an error. So that’s great! Thank you.

      Screen blanks but does not turn all the way off, so that’s still an issue.

      posted in Troubleshooting
      S
      siujd2001
    • RE: MMM-PIR Busy Issue

      on boot, gpioinfo shows “GPIO21” unused input active-high. first start of npm run start:wayland works as intended.

      After CTRL-Q, gpioinfo shows “GPIO21” “lg” input active-high [used pull-down]. Successive npm run start:wayland shows GPIO Busy error.

      posted in Troubleshooting
      S
      siujd2001
    • MMM-PIR Busy Issue

      Upon fresh startup, rpm run start:wayland works as intended

      • MagicMirror starts and all modules appear to work as intended
      • MMM-Pir reads sensor and refreshes countdown timer as desired

      After control-Q to stop the MagicMirror, each successive operation of npm run start:wayland returns error “PIR Error Detected: Error: ‘GPIO busy”

      • Log shows [ERROR] [MMM-Pir] [LIB] [PIR] Error: ‘GPIO Busy’
      • MagicMirror works, including all other modules except MMM-Pir

      Sensor AMR312 connected to 3v power (Pin 1), Ground (Pin 6), and GPIO21 (Pin 40)

      Current config.js settings

      module: ‘MMM-Pir’,
         position: ‘top_left’,
         config: {
             debug: false,
             Display: {
          timeout: 60 * 1000,
                 animate: true,
                style: 1,
                 colorFrom: “#FF0000”,
                 colorTo: “#00FF00”,
      //         mode: 1,
      //     mode: 7,
          mode: 8,
                 counter: true,
                 lastPresence: true,
                 lastPresenceTimeFormat: “LL H:mm”,
          availability: false,
      //         availability: true,
                 autoDimmer: false,
                xrandrForceRotation: “normal”,
                wrandrForceRotation: “normal”,
                wrandrForceMode: null,
                waylandDisplayName: “wayland-0”,
      //     waylandDisplayName: “HDMI-A-1”,
                 relayGPIOPin: 0,  //<-- default was 0
          ddcutil: {
            powerOnCode: “01”,
            powerOffCode: “04”,
            skipSetVcpCheck: false
          }
           },
           Pir: {
        mode: 1,
              gpio: 21
      //   gpio: 4 // <–connected to 4
      }

      posted in Troubleshooting
      S
      siujd2001
    • RE: Help with upgrading to 2.30.0

      @sdetweil After everything was borked, I did try to run 2.29.0 and everything went back to “normal” except MMM-Pir, which remained as “undefined”.

      Currently nothing works at all.

      posted in Troubleshooting
      S
      siujd2001
    • Help with upgrading to 2.30.0

      My MM worked fine under 2.29.0. I had to run some updates recently to MMM-CalendarExt3 and MMM-Pir, and noticed that there was a new version - 2.30.0. I tried to run the sdetweil upgrade script, but things totally went sideways. At first, MMM-CalendarExt3 wouldn’t pull events from Google Calendar, and MMM-Pir would show up as undefined. Then things got worse - now MM won’t even run at all.

      Please help.

      Below is the output from my current state of trying to run the sdetweil scripts:

      Running test script:

      @raspberrypi:~/MagicMirror $ bash -c “$(curl -sL https://raw.githubusercontent.com/sdetweil/MagicMirror_scripts/master/upgrade-script.sh)”
      update log will be in /home//MagicMirror/installers/upgrade.log

      doing test run = true, NO updates will be applied!

      Check current Node installation …
      Node currently installed. Checking version number.
      Minimum Node version: v20.18.1
      Installed Node version: V1.0.0
      Node should be upgraded.
      Node.js upgrade defered, doing test run
      Check current NPM installation …
      NPM currently installed. Checking version number.
      Minimum npm version: V10.8.2
      Installed npm version: V10.8.2
      No npm upgrade necessary.

      saving custom.css
      reverting to master branch from (HEAD, saving changed files
      Previous HEAD position was 94c3c699 Release 2.29.0 (#3568)
      Switched to branch ‘master’
      upgrading from version 2.30.0 to 2.30.0
      fetching latest revisions
      cp: cannot stat ‘installers/mm.sh’: No such file or directory

      Checking for modules with removed libraries
      bash: line 937: /usr/local/bin/node: No such file or directory
      no modules found needing npm refresh
      restoring custom.css

      Running update script:

      @raspberrypi:~/MagicMirror $ bash -c “$(curl -sL https://raw.githubusercontent.com/sdetweil/MagicMirror_scripts/master/upgrade-script.sh)” apply
      update log will be in /home//MagicMirror/installers/upgrade.log
      doing test run = false
      Node currently installed. Checking version number.
      Minimum Node version: v20.18.1
      Installed Node version: V1.0.0
      installing correct version of node and npm, please wait
      /usr/local/bin/n: line 746: /usr/local/bin/node: No such file or directory
      Check current Node installation …
      Node currently installed. Checking version number.
      Minimum Node version: v20.18.1
      Installed Node version: V1.0.0
      Node should be upgraded.
      Installing Node.js …
      apply: line 318: [: too many arguments
      tar (child): /home//node_release-.tar.gz: Cannot open: No such file or directory
      tar (child): Error is not recoverable: exiting now
      tar: Child returned status 2
      tar: Error is not recoverable: exiting now
      node version is apply: line 353: /usr/local/bin/node: No such file or directory
      apply: line 355: /usr/local/bin/node: No such file or directory
      Node.js installation Done! version=
      apply: line 361: [: too many arguments
      Check current NPM installation …
      NPM currently installed. Checking version number.
      Minimum npm version: V10.8.2
      Installed npm version: V10.8.2
      No npm upgrade necessary.

      saving custom.css
      local version 2.30.0 already same as master 2.30.0
      restoring custom.css
      @raspberrypi:~/MagicMirror $

      —--------------------------
      Trying to run MagicMirror

      @raspberrypi:~/MagicMirror $ npm run start

      magicmirror@2.30.0 start
      npm run start:x11

      magicmirror@2.30.0 start:x11
      DISPLAY=“${DISPLAY:=:0}” ./node_modules/.bin/electron js/electron.js

      [2025-01-03 02:01:30.545] [ERROR] App threw an error during load
      [2025-01-03 02:01:30.549] [ERROR] Error: Cannot find module ‘undici’
      Require stack:

      • /home//MagicMirror/js/app.js
      • /home//MagicMirror/js/electron.js
        at Module._resolveFilename (node:internal/modules/cjs/loader:1232:15)
        at s._resolveFilename (node:electron/js2c/browser_init:2:121498)
        at Module._resolveFilename (/home//MagicMirror/node_modules/module-alias/index.js:49:29)
        at Module._load (node:internal/modules/cjs/loader:1058:27)
        at c._load (node:electron/js2c/node_init:2:17025)
        at Module.require (node:internal/modules/cjs/loader:1318:19)
        at require (node:internal/modules/helpers:179:18)
        at Object. (/home//MagicMirror/js/app.js:15:40)
        at Module._compile (node:internal/modules/cjs/loader:1484:14)
        at Module._extensions…js (node:internal/modules/cjs/loader:1564:10)
        at Module.load (node:internal/modules/cjs/loader:1295:32)
        at Module._load (node:internal/modules/cjs/loader:1111:12)
        at c._load (node:electron/js2c/node_init:2:17025)
        at Module.require (node:internal/modules/cjs/loader:1318:19)
        at require (node:internal/modules/helpers:179:18)
        at Object. (/home//MagicMirror/js/electron.js:4:14)
        A JavaScript error occurred in the main process
        Uncaught Exception:
        Error: Cannot find module ‘undici’
        Require stack:
      • /home//MagicMirror/js/app.js
      • /home//MagicMirror/js/electron.js
        at Module._resolveFilename (node:internal/modules/cjs/loader:1232:15)
        at s._resolveFilename (node:electron/js2c/browser_init:2:121498)
        at Module._resolveFilename (/home//MagicMirror/node_modules/module-alias/index.js:49:29)
        at Module._load (node:internal/modules/cjs/loader:1058:27)
        at c._load (node:electron/js2c/node_init:2:17025)
        at Module.require (node:internal/modules/cjs/loader:1318:19)
        at require (node:internal/modules/helpers:179:18)
        at Object. (/home//MagicMirror/js/app.js:15:40)
        at Module._compile (node:internal/modules/cjs/loader:1484:14)
        at Module._extensions…js (node:internal/modules/cjs/loader:1564:10)
        at Module.load (node:internal/modules/cjs/loader:1295:32)
        at Module._load (node:internal/modules/cjs/loader:1111:12)
        at c._load (node:electron/js2c/node_init:2:17025)
        at Module.require (node:internal/modules/cjs/loader:1318:19)
        at require (node:internal/modules/helpers:179:18)
        at Object. (/home//MagicMirror/js/electron.js:4:14)
        ^C/home//MagicMirror/node_modules/electron/dist/electron exited with signal SIGINT

      —--------------------------------------------------
      Trying full installation:

      @raspberrypi:~/MagicMirror $ bash -c “$(curl -sL https://raw.githubusercontent.com/sdetweil/MagicMirror_scripts/master/raspberry.sh)”

      $$\ $$\ $$\ $$\ $$\ $$\ $$$$$$
      $$$\ $$$ | _| $$$\ $$$ |_| $$ $$
      $$$$\ $$$$ | $$$$$$\ $$$$$$\ $$\ $$$$$$$\ $$$$\ $$$$ |$$\ $$$$$$\ $$$$$$\ $$$$$$\ $$$$$$\ _/ $$ |
      $$$$$$ $$ | _
      $$\ $$ $$\ $$ |$$ |$$$$$$ $$ |$$ |$$ $$\ $$ $$\ $$ $$\ $$ $$\ $$$$$$ |
      $$ $$$ $$ | $$$$$$$ |$$ / $$ |$$ |$$ / $$ $$$ $$ |$$ |$$ | _|$$ | _|$$ / $$ |$$ | _|$$ /
      $$ |$ /$$ |$$ __$$ |$$ | $$ |$$ |$$ | $$ |$ /$$ |$$ |$$ | $$ | $$ | $$ |$$ | $$ |
      $$ | _/ $$ |$$$$$$$ |$$$$$$$ |$$ |$$$$$$$\ $$ | _/ $$ |$$ |$$ | $$ | $$$$$$ |$$ | $$$$$$$$
      _
      | _
      | _
      | _
      $$ |_| _
      |_| _|_|_| __| _
      / _| _______|
      $$\ $$ |
      $$$$$$ |
      _
      ____/

      install log being saved to /home//install.log
      Updating packages …
      [ <=> ]
      Installing helper tools …
      bash: line 287: /usr/local/bin/node: No such file or directory
      node failed to execute, please check the error message and resolve before trying again
      @raspberrypi:~/MagicMirror $

      posted in Troubleshooting
      S
      siujd2001
    • RE: MMM-CalendarExt3 24hr time

      @sdetweil

      Thank you.

      I used the following in the Ext3 section and it seemed to work:

      locale: “en-GB”,
      eventTimeOptions: {timeStyle: ‘short’},

      posted in Troubleshooting
      S
      siujd2001
    • RE: MMM-CalendarExt3 24hr time

      @sdetweil

      I also have MMM-Config installed if that makes a difference.

      /* Config Sample
       *
       * For more information on how you can configure this file
       * see https://docs.magicmirror.builders/configuration/introduction.html
       * and https://docs.magicmirror.builders/modules/configuration.html
       *
       * You can use environment variables using a `config.js.template` file instead of `config.js`
       * which will be converted to `config.js` while starting. For more information
       * see https://docs.magicmirror.builders/configuration/introduction.html#enviromnent-variables
       */
      let config = {
      	address: "localhost",	// Address to listen on, can be:
      							// - "localhost", "127.0.0.1", "::1" to listen on loopback interface
      							// - another specific IPv4/6 to listen on a specific interface
      							// - "0.0.0.0", "::" to listen on any interface
      							// Default, when address config is left out or empty, is "localhost"
      	port: 8080,
      	basePath: "/",	// The URL path where MagicMirror² is hosted. If you are using a Reverse proxy
      									// you must set the sub path here. basePath must end with a /
      	ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"],	// Set [] to allow all IP addresses
      									// or add a specific IPv4 of 192.168.1.5 :
      									// ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.1.5"],
      									// or IPv4 range of 192.168.3.0 --> 192.168.3.15 use CIDR format :
      									// ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.3.0/28"],
      
      	useHttps: false,			// Support HTTPS or not, default "false" will use HTTP
      	httpsPrivateKey: "",	// HTTPS private key path, only require when useHttps is true
      	httpsCertificate: "",	// HTTPS Certificate path, only require when useHttps is true
      
      	language: "en",
      	locale: "en-US",
      	logLevel: ["INFO", "LOG", "WARN", "ERROR"], // Add "DEBUG" for even more logging
      	timeFormat: 24,
      	units: "metric",
      
      	modules: [
      		{
      			module: "alert",
      		},
      		{
      			module: "updatenotification",
      			position: "top_bar"
      		},
      		{
      			module: "clock",
      			position: "top_left"
      		},
      		{
      			module: 'MMM-2Day-NOAA-Forecast',
      			position: 'top_right',
      			config: {
      			  lat: LAT,
      			  lon: LONG,
      			  units: 'imperial',
      			  fontSize: '32px',
      			  interval: 10 * 60 * 1000
      			}
      		},
      		{
      			module: "MMM-OnThisDayWikiApi",
      			position: "top_center", // All available positions // <= this works in landscape
      //			position: "middle_left",  // trying for vertical mode
      			config: {  // See below for configurable options, this is optional
      			  reloadInterval: 10000
      			}
      		},
      		{
      			module: "calendar", /* default/calendar module configuration */
      //			position: "top_left",
        			config: {
          			  broadcastPastEvents: true, // <= IMPORTANT to see past events
          			  calendars: [
            			    {
              		      url: "webcal://www.calendarlabs.com/ical-calendar/ics/76/US_Holidays.ics",
              		      name: "us_holiday", // <= RECOMMENDED to assign name
              		      color: "orange" // <= RECOMMENDED to assign color
            			    },
                                  {
      			      url: "CALENDAR",
                                    name: "NAME",
                                    color: "purple"
      			    },
      			  ]
      		  	}
      		},
      		{
      			module: "MMM-CalendarExt3",
      //			position: "bottom_bar",
      			position: "lower_third",  // <= works in landscape mode
      //			position: "upper_third",  // trying for vertical mode
      			title: "",
      			config: {
      			  mode: "month",
      			  instanceId: "basicCalendar",
      			  locale: 'en-US',
      			  maxEventLines: 5,
      			  firstDayOfWeek: 0,
      			  calendarSet: ['us_holiday', 'CALENDAR'],
      			  eventTransformer: (event) => {
      			    if (event.title.search("STB") > -1) event.color = "blue";
      			    else if (event.title.search("St. B") > -1) event.color = "blue";
      			    else if (event.title.search("FMCHS") > -1) event.color = "green";
      			    else if (event.title.search("B-Day") > -1) event.color = "red";
      //			    else if (event.description.search("Birthday") > -1) event.color = "red";
      //			    else if (event.getDescription()?.toLowerCase().includes("birthday")) event.setColor(CalendarApp.EventColor.red);
      			    return event;
      			    }
      			}
      		},
      		{
      			module: "MMM-Dad-Jokes",
      			position: "top_center",  // <= this works in landscape mode
      //			position: "middle_right",  // <= trying for vertical mode
      //			color: "red",
      			config: {
      			  updateInterval: 15000
      			}
      		},
      		{
      			module: 'MMM-Pir',
        			position: 'top_left',
        			config: {
          			  debug: false,
          			  Display: {
      //     			    timeout: 2 * 60 * 1000,
      			    timeout: 60 * 1000,
            			    animate: true,
      //     			    style: 1,
      			    stile: 2,
            			    colorFrom: "#FF0000",
            			    colorTo: "#00FF00",
      //     			    mode: 1,
      			    mode: 2,
            			    counter: true,
            			    lastPresence: true,
            			    lastPresenceTimeFormat: "LL H:mm",
      			    availability: false,
      //     			    availability: true,
            			    autoDimmer: false,
            		 	    xrandrForceRotation: "normal",
            			    wrandrForceRotation: "normal",
            			    wrandrForceMode: null,
            			    waylandDisplayName: "wayland-0",
            			    relayGPIOPin: 0
          			},
          			Pir: {
            			  mode: 0,
      //     			  gpio: 21
      			  gpio: 4
          			},
          			Motion: {
            			  deviceId: 0,
            			  captureIntervalTime: 1000,
            			  scoreThreshold: 100
          			},
          			Cron: {
            			  ON: [],
            			  OFF: []
          			},
          			Touch: {
            			mode: 3
          			},
          			Governor: {
            			  sleeping: 4,
            			  working: 2
          			},
          			Sounds: {
            			  on: "open.mp3",
            			  off: "close.mp3"
          			}
      		}
        		},
      	]
      };
      
      /*************** DO NOT EDIT THE LINE BELOW ***************/
      if (typeof module !== "undefined") { module.exports = config; }
      
      posted in Troubleshooting
      S
      siujd2001
    • MMM-CalendarExt3 24hr time

      I’m having some difficulty getting the module to show 24hr time instead of 12. Raspberry Pi 4 set to 24 hour time, and config.js is set with locale: “en-US” and timeformat: 24. Other modules show 24hr time, but Google calendar doesn’t. When viewing calendar.google.com, 24hr time is shown.

      Any insights?

      posted in Troubleshooting
      S
      siujd2001
    • Rolling 30 day calendar

      Re: MMM-CalendarExt3

      Is it possible to display the calendar showing the current week + 3 weeks after that? If you use mode: “month” it shows the current month but it’s not as helpful near the end of the month. If you use mode: “week” and weeksInView, I have only been able to get 3 weeks total.

      Any help on new language for config.js would be helpful.

      On a side note, it would also be nice if someone could comment on how to change the css to highlight the particular day, ideally by changing the white box around the current day to yellow or some other color + the date highlight bar at the top of the day.

      Thank you.

      posted in Utilities
      S
      siujd2001