MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    MMM-PIR-Sensor: Everything works fine, just one thing not...

    Scheduled Pinned Locked Moved Troubleshooting
    7 Posts 3 Posters 2.8k Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • MedoM Offline
      Medo
      last edited by

      My sensor is working fine for months now. It works as designed (shuts my mirror down after 5 minutes and is reactivated if someone enters the room or goes by).

      But i noticed this:
      After a reboot of the whole PI mirror system, the screen isn’ t turned off by the MMM-PIR-Sensor-module (even after waiting for more than an hour or more - i think it would be on forever). Only if someone goes by, the sensor shuts down the screen (monitor) for a millisecond and immediately after that, turns the screen on again. After that, the PIR sensor works fine like every day before…

      Does any one of you ever had a similar behavior of a PIR sensor configuration?

      Thanks!

      Medo

      1 Reply Last reply Reply Quote 0
      • A Offline
        AxLed Module Developer
        last edited by

        Hi Medo,
        i think i read something that after a reboot you have to wave your hand (for example) in front of sensor once, so the sensor is active.

        AxLED

        MedoM 1 Reply Last reply Reply Quote 0
        • MedoM Offline
          Medo @AxLed
          last edited by

          @AxLed
          Thanks, did not know that this has to be done to “activate” a PIR sensor…Interesting…hmm…

          Does anyone know, if there is a method that this can be “simulated” in any way?

          1 Reply Last reply Reply Quote 0
          • cruunnerrC Offline
            cruunnerr
            last edited by

            one idea is to just put the tvservice -o command in your rc.local.
            before that u should do a little sleep.

            like this:

            sudo nano /etc/rc.local

            #!/bin/sh -e
            #
            # rc.local
            #
            # This script is executed at the end of each multiuser runlevel.
            # Make sure that the script will "exit 0" on success or any other
            # value on error.
            #
            # In order to enable or disable this script just change the execution
            # bits.
            #
            # By default this script does nothing.
            
            # Print the IP address
            _IP=$(hostname -I) || true
            if [ "$_IP" ]; then
              printf "My IP address is %s\n" "$_IP"
            fi
            
            sleep 60 &
            
            tvservice -o
            
            exit 0
            

            So on every reboot it will wait 60 seconds (just to let everything start like MM) and then turn the monitor off.

            MedoM 1 Reply Last reply Reply Quote 3
            • MedoM Offline
              Medo
              last edited by

              Sounds like a great idea! I will try that soon and will geht you a reply if it works! Thanks for that possible solution…

              1 Reply Last reply Reply Quote 0
              • MedoM Offline
                Medo @cruunnerr
                last edited by

                @cruunnerr
                Your solution worked like a charm.
                Thanks!

                cruunnerrC 1 Reply Last reply Reply Quote 1
                • cruunnerrC Offline
                  cruunnerr @Medo
                  last edited by

                  @Medo

                  Glad to hear that :)

                  1 Reply Last reply Reply Quote 0
                  • 1 / 1
                  • First post
                    Last post
                  Enjoying MagicMirror? Please consider a donation!
                  MagicMirror created by Michael Teeuw.
                  Forum managed by Sam, technical setup by Karsten.
                  This forum is using NodeBB as its core | Contributors
                  Contact | Privacy Policy