-
2Step 2
Get 433utils: git clone git://github.com/ninjablocks/433Utils.git && cd 433Utils/RPi_utils && rm RFSniffer.cpp && wget https://raw.githubusercontent.com/Astu04/Raspi_PIR_Push_notif/master/RFSniffer.cpp && nano RFSniffer.cpp // We now modify the value in this file: Remember that value for step 6. // sudo make && mv RFSniffer /var/www/
if (value == 12345) { // <--- The number
-
3Step 3
sudo apt-get update && sudo apt-get install urlwatch lighttpd && sudo urlwatch
Now we create a file /root/.urlwatch/urls.txt with: http://localhost/log.txt
$ echo 'http://localhost/log.txt' > /root/.urlwatch/urls.txt
-
4Step 4
Wire everything up (See tutorials in 433utils/wiringPi) tl;dr data to pin 2, and then vcc and gnd.
-
5Step 5
Sign in http://pushetta.com/ , create a channel, go to dashboard and get the API key. Install the app on your compatible device ( See list in http://pushetta.com/pushetta-downloads/ ). Subscribe to the channel you just created. Modify the .py file with the API KEY and the channel name. My channel is "Stairs PIR".
-
6Step 6
Modify and upload the .ino to the ATMEGA328 following this tutorial: https://www.arduino.cc/en/Tutorial/ArduinoToBreadboard
-
7Step 7
Move all the files (.py, .sh, RFSniffer) to /var/www/ and write in the console ./RFSniffer
-
8Step 8
As homework, move all but log.txt out of /var/www/, so it isn't visible. You could also password protect log.txt
My ATMEGA328P-PU consumption keeps at 90uA most of the time, so a battery should last a long time. The PIR sensor I picked drains by itself 50uA.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.