Add support for PIR motion sensors
Use rising-edge event detection for the PIR sensor
instead of polling. Honestly, though, I'm not sure
this is better: rising-edge detection on RPi.GPIO
often seems to detect falling edges as well, and we
get extra snaps right after the moving object has left the field.
flush stdout during PIR loops