<?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[MMM-PIR-Sensor wont do anything]]></title><description><![CDATA[<p dir="auto">This is really bugging me!  Ok, I am new to Pi programming but I have knowledge of a few programming languages and can usually tweak my head around problems but this has really stumped me!</p>
<p dir="auto">I turned the PIR sensor away from me to show no movement.  When I use “sudo ./test.sh” I get a load of 0’s on the screen displaying no movement.  When I wave my hand in front I get a load of 1’s.  So its working correctly.</p>
<p dir="auto">I setup MMM-PIR-Sensor and change the pin from default to number 7 in the config file.  Nothing happens on the screen.  It doesn’t switch off when it senses no movement (like its supposed to)</p>
<p dir="auto">This is my <a href="http://test.sh" target="_blank" rel="noopener noreferrer nofollow ugc">test.sh</a> code (which works):</p>
<pre><code>echo "4" &gt; /sys/class/gpio/export
echo "in" &gt; /sys/class/gpio/gpio4/direction

while true;  do
        trap 'echo "4" &gt; /sys/class/gpio/unexport' 0
        stat=`cat /sys/class/gpio/gpio4/value`
        echo $stat

done
exit 0
</code></pre>
<p dir="auto">And my config code:</p>
<pre><code>{
module: 'MMM-PIR-Sensor',
config: {
sensorPIN: 7 
}
},
</code></pre>
<p dir="auto">I just know its something simple but I am stumped!</p>
]]></description><link>https://forum.magicmirror.builders/topic/6429/mmm-pir-sensor-wont-do-anything</link><generator>RSS for Node</generator><lastBuildDate>Thu, 16 Apr 2026 17:21:58 GMT</lastBuildDate><atom:link href="https://forum.magicmirror.builders/topic/6429.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 29 Jan 2018 21:46:20 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to MMM-PIR-Sensor wont do anything on Mon, 29 Jan 2018 21:53:53 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/ts77uk" aria-label="Profile: TS77UK">@<bdi>TS77UK</bdi></a> said in <a href="/post/34910">MMM-PIR-Sensor wont do anything</a>:</p>
<blockquote>
<p dir="auto">echo “4” &gt; /sys/class/gpio/export</p>
</blockquote>
<p dir="auto">Ignore that!  I was looking at the wrong pin map for my model Pi!  I should have been in number 4 not 7!  As soon as I typed it I realised the answer lol</p>
<p dir="auto">Thank you for your time</p>
]]></description><link>https://forum.magicmirror.builders/post/34911</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/34911</guid><dc:creator><![CDATA[TS77UK]]></dc:creator><pubDate>Mon, 29 Jan 2018 21:53:53 GMT</pubDate></item></channel></rss>