Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MMM-Pir GPIO Busy Error #163

Open
siujd2001 opened this issue Jan 9, 2025 · 4 comments
Open

MMM-Pir GPIO Busy Error #163

siujd2001 opened this issue Jan 9, 2025 · 4 comments
Labels
Available on next Release Coded on dev brach bug Something isn't working

Comments

@siujd2001
Copy link

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’

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
}

@siujd2001
Copy link
Author

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.

@bugsounet
Copy link
Owner

Thanks reporting this issue !

I have forget to kill python process on exit

I will fix it for next release

@bugsounet bugsounet added bug Something isn't working Available on next Release Coded on dev brach labels Jan 10, 2025
@bugsounet bugsounet mentioned this issue Jan 10, 2025
@siujd2001
Copy link
Author

siujd2001 commented Jan 10, 2025 via email

@bugsounet
Copy link
Owner

Note:

I just export some EXT plugins of MMM-GoogleAssistant v7.x for create v2.x of this module
So, sometime if forget to add some rules for common using on MMM-Pir module :/

in all case Happy use ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Available on next Release Coded on dev brach bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants