Updated fetchprogram, ignores pycache, created ledtest with npn

This commit is contained in:
LazyAssassin445
2017-03-11 13:46:58 +00:00
parent 731acedea7
commit 2ad3620908
3 changed files with 20 additions and 1 deletions

View File

@@ -1,7 +1,7 @@
#!/usr/bin/python3
import os, sys
lib_path = os.path.abspath(os.path.join('..', 'modules'))
lib_path = os.path.abspath(os.path.join('.', 'modules'))
sys.path.append(lib_path)
import hdc1000
import weight

2
modules/.gitignore vendored Normal file
View File

@@ -0,0 +1,2 @@
__pycache__

17
testprograms/ledtest Executable file
View File

@@ -0,0 +1,17 @@
#!/usr/bin/python3
import RPi.GPIO as GPIO
import time
import sys
GPIO.setmode(GPIO.BCM)
GPIO.setup(23, GPIO.OUT)
GPIO.output(23, 0)
while True:
time.sleep(1)
GPIO.output(23, 1)
time.sleep(1)
GPIO.output(23, 0)