<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[PIR Sensor turning display on&#x2F;off over and over]]></title><description><![CDATA[<p dir="auto">Hello!</p>
<p dir="auto">tl;dr  - display wakes/sleeps repeatedly.</p>
<p dir="auto">Display sleeps fine, but once PIR Sensor is triggered, the monitor wakes, then immediately sleeps, then wakes, then sleeps, and so on, until I remove myself as a trigger to the PIR Sensor.</p>
<p dir="auto">FWIW - I utilized a tutorial for setting up the PIR Sensor and testing it via python script to see if it is even working. Here’s the script:</p>
<pre><code>from gpiozero import MotionSensor

pir = MotionSensor(4)
while True:
    if pir.motion_detected:
        print("Motion detected!")
</code></pre>
<p dir="auto">It works, but it continues to print over and over (and so on) until I remove the trigger for the PIR Sensor (much like how the display wakes and sleeps repeatedly).</p>
<p dir="auto">I’m honestly not sure if it is supposed to print that output over and over (like mine does), or not. But I feel like the two might be connected.</p>
<p dir="auto">Any pointers here would be much obliged. Thank you!</p>
]]></description><link>https://forum.magicmirror.builders/topic/1837/pir-sensor-turning-display-on-off-over-and-over</link><generator>RSS for Node</generator><lastBuildDate>Mon, 11 May 2026 21:02:45 GMT</lastBuildDate><atom:link href="https://forum.magicmirror.builders/topic/1837.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 22 Feb 2017 03:08:56 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Wed, 05 Apr 2017 04:32:04 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/elmerito25" aria-label="Profile: elmerito25">@<bdi>elmerito25</bdi></a> Hi:</p>
<p dir="auto">Thanks for the reply. The PIR has two rheostats labeled Sx and Tx, so which is which. I’m tempted to dispense with the PIR altogether and just use the monitor on/off switch to activate the display.  But, I’ll mess with the PIR when I get a chance and see if I can get anywhere.  Using Board numbering,  the PIR has its VCC pin wired to pin 4, its ground pin wired to Pin 6 and its signal pin wired to Pin 7. I set the pin number in my config.js file to 4 (Board pin 7 is GPIO pin 4). Would there be any problem with this wiring?</p>
]]></description><link>https://forum.magicmirror.builders/post/18972</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/18972</guid><dc:creator><![CDATA[jproehl]]></dc:creator><pubDate>Wed, 05 Apr 2017 04:32:04 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Tue, 04 Apr 2017 23:01:35 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/jproehl" aria-label="Profile: jproehl">@<bdi>jproehl</bdi></a> Does your PIR sensor has a sensitivity and time option?  Try playing with it and see if it works.  Also, feel free to post pix of the wiring connection so we can visually verify.  I also play around with the GPIO pins.  Hope this helps!</p>
]]></description><link>https://forum.magicmirror.builders/post/18961</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/18961</guid><dc:creator><![CDATA[elmerito25]]></dc:creator><pubDate>Tue, 04 Apr 2017 23:01:35 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Sun, 02 Apr 2017 06:44:49 GMT]]></title><description><![CDATA[<p dir="auto">Hi: I’m having the same problem with the PIR sensor module - when motion is detected the screen comes on for about 1 sec and then shuts off. It operates like that for a minute or so and then begins to not respond or responds intermittently to motion. I’ve added a magnet ring, updated the OS and the MMM-PIR module, but still have the same issues.   Any ideas what I should check?  Thx!</p>
]]></description><link>https://forum.magicmirror.builders/post/18662</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/18662</guid><dc:creator><![CDATA[jproehl]]></dc:creator><pubDate>Sun, 02 Apr 2017 06:44:49 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Fri, 10 Mar 2017 21:53:11 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/johnnyboy" aria-label="Profile: johnnyboy">@<bdi>johnnyboy</bdi></a></p>
<p dir="auto">The steps I described started after a succesfully installation of the operating system on the pi, so with no MagicMirror installed --&gt; step 3 is the first time MM is installed.<br />
These are the steps which worked for me, somehow after the second install of the MagicMirror (step 7) the PIR worked --&gt; this step could be obsolete for others, thats just what i did experience.</p>
]]></description><link>https://forum.magicmirror.builders/post/17023</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/17023</guid><dc:creator><![CDATA[Jay]]></dc:creator><pubDate>Fri, 10 Mar 2017 21:53:11 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Fri, 10 Mar 2017 21:03:17 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/deepshades" aria-label="Profile: deepshades">@<bdi>deepshades</bdi></a><br />
Well ok…<br />
<strong>step 1:</strong> get nodejs and npm --&gt; <code>sudo apt-get install nodejs </code> then  <code>sudo apt-get install npm  </code><br />
<strong>step 2:</strong> update + upgrade the pi --&gt; <code>sudo apt-get update</code> then <code>sudo apt-get dist-upgrade </code><br />
<strong>step 3:</strong> install MagicMirror --&gt; as seen here <a href="https://github.com/MichMich/MagicMirror" target="_blank" rel="noopener noreferrer nofollow ugc">MagicMirror Github Page</a><br />
<strong>step 4:</strong> connect the PIR-Sensor to your Pi --&gt; ground to ground (e.g. Pin 6), VCC to 5V (e.g. Pin 2), Out to GPIO XX (e.g. Pin 16)<br />
<strong>step 5:</strong> check if PIR-Sensor works --&gt; as seen at my script above (watch your connected GPIO pin, maybe change in script is required) --&gt; some fiddling with sensitivity knobs here is needed<br />
<strong>step 6:</strong> install MMM-PIR --&gt; <a href="https://github.com/paviro/MMM-PIR-Sensor" target="_blank" rel="noopener noreferrer nofollow ugc">MMM-PIR Github Page</a><br />
<strong>step 7:</strong> reboot and reinstall MagicMirror in MagicMirror directory --&gt; <code>cd MagicMirror</code> and <code>npm install</code></p>
<p dir="auto">this has worked for me…</p>
]]></description><link>https://forum.magicmirror.builders/post/17019</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/17019</guid><dc:creator><![CDATA[Jay]]></dc:creator><pubDate>Fri, 10 Mar 2017 21:03:17 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Fri, 10 Mar 2017 20:34:44 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/jay" aria-label="Profile: Jay">@<bdi>Jay</bdi></a></p>
<p dir="auto">Ok, so you just use a script to let the sensor deactivate the hdmi output?<br />
Could you tell me the steps to let all work together?</p>
]]></description><link>https://forum.magicmirror.builders/post/17018</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/17018</guid><dc:creator><![CDATA[deepshades]]></dc:creator><pubDate>Fri, 10 Mar 2017 20:34:44 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Fri, 10 Mar 2017 20:14:31 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/deepshades" aria-label="Profile: deepshades">@<bdi>deepshades</bdi></a><br />
Basically its just the standard PIR-Sensor shipped with female to female gpio connections (<a href="https://www.amazon.de/dp/B0104LSJGQ/ref=pe_386171_37038021_TE_3p_dp_1" target="_blank" rel="noopener noreferrer nofollow ugc">PIR-Sensor Amazon</a>).</p>
]]></description><link>https://forum.magicmirror.builders/post/17016</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/17016</guid><dc:creator><![CDATA[Jay]]></dc:creator><pubDate>Fri, 10 Mar 2017 20:14:31 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Fri, 10 Mar 2017 20:05:04 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/jay" aria-label="Profile: Jay">@<bdi>Jay</bdi></a></p>
<p dir="auto">Hi Jay, can you reply a link to your PIR module you finaly use?</p>
]]></description><link>https://forum.magicmirror.builders/post/17013</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/17013</guid><dc:creator><![CDATA[deepshades]]></dc:creator><pubDate>Fri, 10 Mar 2017 20:05:04 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Sun, 05 Mar 2017 21:08:46 GMT]]></title><description><![CDATA[<p dir="auto">Basically I had the same error with the display turning on and off over time. All in anger, I deinstalled the MagicMirror from the Pi and began at zero again.<br />
After updating and upgrading the Pi and installing the MagicMirror, a new try with the PIR-Module was iniciated. So I installed the PIR-Module and somehow noticed that my GPIO cables were wrong connected (ground connected to GPIO21 and vice-versa).<br />
So after this embarassing moment of disbelieve I changed the connections and checked if the sensor is working with a simple python script:</p>
<pre><code>from gpiozero import MotionSensor
import time

pir = MotionSensor(21)

while True: #repeat this forever
    if pir.motion_detected: # if motion is detected print the message
        print("Motion detected!")
    if not pir.motion_detected: # if no motion is detected print the message
        print("No motion detected!")
    time.sleep(1)
</code></pre>
<p dir="auto">Note that my pir is using GPIO21.<br />
With this script I tested the sensor and it worked like a charm, even though the sensor is placed 5 centimeters away from the raspberry pi 3 (with no case or even a bead installed).<br />
In the end, I only had to do a <code>cd MagicMirror</code> again, and install the MagicMirror:<br />
<code>npm install</code>. With this setup the MMM-PIR-module works magnificient.</p>
]]></description><link>https://forum.magicmirror.builders/post/16544</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/16544</guid><dc:creator><![CDATA[Jay]]></dc:creator><pubDate>Sun, 05 Mar 2017 21:08:46 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Thu, 02 Mar 2017 16:43:23 GMT]]></title><description><![CDATA[<p dir="auto">Even with the bead installed I have various results. Sometimes it’s running ok for an hour or so, but  most of the time I’m getting a lot of false positives. And very strange, only with the output timer (2nd yellow knob) on minimal it’s working ok. But then the screen lits up far too short. But output time has nothing to do with it?</p>
]]></description><link>https://forum.magicmirror.builders/post/16287</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/16287</guid><dc:creator><![CDATA[hermlam]]></dc:creator><pubDate>Thu, 02 Mar 2017 16:43:23 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Thu, 02 Mar 2017 13:49:53 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/phrazelle" aria-label="Profile: phrazelle">@<bdi>phrazelle</bdi></a> Since I am having a ‘cordless’ mirror (power is coming from wall behind mirror) I don’t want to see cables to my mirror. I’ve build the PIR into the frame of my mirror.</p>
]]></description><link>https://forum.magicmirror.builders/post/16286</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/16286</guid><dc:creator><![CDATA[hermlam]]></dc:creator><pubDate>Thu, 02 Mar 2017 13:49:53 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Thu, 02 Mar 2017 13:45:11 GMT]]></title><description><![CDATA[<p dir="auto">Similar problem here, PIR works like a charm (tested with code of post <strong>#4</strong>) but after starting the MagicMirror the display is turned off and on over and over even though nothing is changed in front of the sensor. (I use MMM-PIR).</p>
]]></description><link>https://forum.magicmirror.builders/post/16285</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/16285</guid><dc:creator><![CDATA[Jay]]></dc:creator><pubDate>Thu, 02 Mar 2017 13:45:11 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Wed, 01 Mar 2017 18:17:04 GMT]]></title><description><![CDATA[<p dir="auto">FWIW, a ferrite bead is a working solution, but I was able to circumvent this issue by keeping the PIR Sensor a good distance from the Pi.  Mine is about 3 feet away from the Pi and doesn’t act erratically as it did when it was right next to it during testing.</p>
]]></description><link>https://forum.magicmirror.builders/post/16238</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/16238</guid><dc:creator><![CDATA[phrazelle]]></dc:creator><pubDate>Wed, 01 Mar 2017 18:17:04 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Wed, 01 Mar 2017 01:11:01 GMT]]></title><description><![CDATA[<p dir="auto">i gave up on my PIR sensor cause this was happening to me…guess who is searching for a Ferrite bead tomorrow!!!</p>
]]></description><link>https://forum.magicmirror.builders/post/16168</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/16168</guid><dc:creator><![CDATA[cyberphox]]></dc:creator><pubDate>Wed, 01 Mar 2017 01:11:01 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Tue, 28 Feb 2017 18:38:12 GMT]]></title><description><![CDATA[<p dir="auto">Hi all,<br />
Thanks for the reactions. I ordered one and will test tomorrow.<br />
Herman</p>
]]></description><link>https://forum.magicmirror.builders/post/16107</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/16107</guid><dc:creator><![CDATA[hermlam]]></dc:creator><pubDate>Tue, 28 Feb 2017 18:38:12 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Tue, 28 Feb 2017 17:41:07 GMT]]></title><description><![CDATA[<p dir="auto">Great to hear.  I love it when a plan comes together.</p>
<p dir="auto">Now I need to scrounge up a bead for my build.<br />
Ren</p>
]]></description><link>https://forum.magicmirror.builders/post/16102</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/16102</guid><dc:creator><![CDATA[Renfield]]></dc:creator><pubDate>Tue, 28 Feb 2017 17:41:07 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Mon, 27 Feb 2017 19:36:50 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/elmerito25" aria-label="Profile: elmerito25">@<bdi>elmerito25</bdi></a> said in <a href="/post/15756">PIR Sensor turning display on/off over and over</a>:</p>
<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/cowboysdude" aria-label="Profile: cowboysdude">@<bdi>cowboysdude</bdi></a> said in <a href="/post/15736">PIR Sensor turning display on/off over and over</a>:</p>
<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/renfield" aria-label="Profile: Renfield">@<bdi>Renfield</bdi></a> said in <a href="/post/15715">PIR Sensor turning display on/off over and over</a>:</p>
<blockquote>
<p dir="auto">It might be interference.  Try installing a ferrite bead.  The person whose site I’ve linked below had a very similar problem and describes how he fixed it.</p>
<p dir="auto"><a href="https://helentronica.com/2016/01/11/magic-mirror-with-motion-detector/" target="_blank" rel="noopener noreferrer nofollow ugc">https://helentronica.com/2016/01/11/magic-mirror-with-motion-detector/</a></p>
<p dir="auto">Renfield</p>
</blockquote>
<p dir="auto">It’s what I had to do with mine… they are very inexpensive…</p>
</blockquote>
<p dir="auto">Thanks guys!  Will try this once I get home tonight!</p>
</blockquote>
<p dir="auto">Thanks <a class="plugin-mentions-user plugin-mentions-a" href="/user/renfield" aria-label="Profile: Renfield">@<bdi>Renfield</bdi></a> and <a class="plugin-mentions-user plugin-mentions-a" href="/user/cowboysdude" aria-label="Profile: cowboysdude">@<bdi>cowboysdude</bdi></a> ! Followed your advice and found a ferrite bead on unused USB cable and got the PIR sensor working perfectly!</p>
]]></description><link>https://forum.magicmirror.builders/post/16029</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/16029</guid><dc:creator><![CDATA[elmerito25]]></dc:creator><pubDate>Mon, 27 Feb 2017 19:36:50 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Fri, 24 Feb 2017 21:02:28 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/cowboysdude" aria-label="Profile: cowboysdude">@<bdi>cowboysdude</bdi></a> said in <a href="/post/15736">PIR Sensor turning display on/off over and over</a>:</p>
<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/renfield" aria-label="Profile: Renfield">@<bdi>Renfield</bdi></a> said in <a href="/post/15715">PIR Sensor turning display on/off over and over</a>:</p>
<blockquote>
<p dir="auto">It might be interference.  Try installing a ferrite bead.  The person whose site I’ve linked below had a very similar problem and describes how he fixed it.</p>
<p dir="auto"><a href="https://helentronica.com/2016/01/11/magic-mirror-with-motion-detector/" target="_blank" rel="noopener noreferrer nofollow ugc">https://helentronica.com/2016/01/11/magic-mirror-with-motion-detector/</a></p>
<p dir="auto">Renfield</p>
</blockquote>
<p dir="auto">It’s what I had to do with mine… they are very inexpensive…</p>
</blockquote>
<p dir="auto">Thanks guys!  Will try this once I get home tonight!</p>
]]></description><link>https://forum.magicmirror.builders/post/15756</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/15756</guid><dc:creator><![CDATA[elmerito25]]></dc:creator><pubDate>Fri, 24 Feb 2017 21:02:28 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Fri, 24 Feb 2017 20:22:31 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/renfield" aria-label="Profile: Renfield">@<bdi>Renfield</bdi></a> said in <a href="/post/15715">PIR Sensor turning display on/off over and over</a>:</p>
<blockquote>
<p dir="auto">It might be interference.  Try installing a ferrite bead.  The person whose site I’ve linked below had a very similar problem and describes how he fixed it.</p>
<p dir="auto"><a href="https://helentronica.com/2016/01/11/magic-mirror-with-motion-detector/" target="_blank" rel="noopener noreferrer nofollow ugc">https://helentronica.com/2016/01/11/magic-mirror-with-motion-detector/</a></p>
<p dir="auto">Renfield</p>
</blockquote>
<p dir="auto">It’s what I had to do with mine… they are very inexpensive…</p>
]]></description><link>https://forum.magicmirror.builders/post/15736</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/15736</guid><dc:creator><![CDATA[cowboysdude]]></dc:creator><pubDate>Fri, 24 Feb 2017 20:22:31 GMT</pubDate></item><item><title><![CDATA[Reply to PIR Sensor turning display on&#x2F;off over and over on Fri, 24 Feb 2017 17:35:25 GMT]]></title><description><![CDATA[<p dir="auto">It might be interference.  Try installing a ferrite bead.  The person whose site I’ve linked below had a very similar problem and describes how he fixed it.</p>
<p dir="auto"><a href="https://helentronica.com/2016/01/11/magic-mirror-with-motion-detector/" target="_blank" rel="noopener noreferrer nofollow ugc">https://helentronica.com/2016/01/11/magic-mirror-with-motion-detector/</a></p>
<p dir="auto">Renfield</p>
]]></description><link>https://forum.magicmirror.builders/post/15715</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/15715</guid><dc:creator><![CDATA[Renfield]]></dc:creator><pubDate>Fri, 24 Feb 2017 17:35:25 GMT</pubDate></item></channel></rss>