Browse Source

Start work on camera script

master
lheimbs 5 years ago
parent
commit
60271ce420
2 changed files with 22 additions and 0 deletions
  1. 22
    0
      camera/camera.py
  2. BIN
      camera/image2.jpg

+ 22
- 0
camera/camera.py View File

#!/usr/bin/env python2

import time
import RPi.GPIO as GPIO

IR_PIN = 3

GPIO.setmode(GPIO.BOARD)
GPIO.setup(IR_PIN, GPIO.OUT)

try:
while True:
print "Gpio Low"
GPIO.output(IR_PIN, GPIO.LOW)
time.sleep(20)
print "Gpio High"
GPIO.output(IR_PIN, GPIO.HIGH)
time.sleep(20)
except Exception as e:
print e
finally:
GPIO.cleanup()

BIN
camera/image2.jpg View File


Loading…
Cancel
Save