|
i am using a orange pi 3 lts and i want to use my gpio pins and i do a nano ledBlink.py and then i do small program useing the OPi.GPİO library and i write a program that just turns HIGH AND LOW 4 time but i keep geting this error it i been trying to fix this error for over a 4 months but i can fix it i would be very happy if one help me and know there is PYa20 library i can also use but i realy want to use OPi.GPIO
import OPi.GPIO as GPIO here is the ledBlink program import time GPIO.setmode(GPIO.BOARD)LED_PIN = 7GPIO.setwarnings(False)GPIO.setup(LED_PIN, GPIO.OUT)try: while True: GPIO.output(LED_PIN, GPIO.TRUE) time.sleep(1) GPIO.output(LED_PIN, GPIO.FALSE) time.sleep(1)except KeyboardInterrupt: GPIO.cleanup()
File "ledBlink.py", line 7, in <module> GPIO.setup(LED_PIN, GPIO.OUT) File "/usr/local/lib/python3.7/site-packages/OPi.GPIO-0.5.3-py3.7.egg/OPi/GPIO.py", line 482, in setup sysfs.direction(pin, direction) File "/usr/local/lib/python3.7/site-packages/OPi.GPIO-0.5.3-py3.7.egg/OPi/sysfs.py", line 56, in direction fp.write("out")OSError: [Errno 22] Invalid argumentyusufsait@orangepi3-lts:~$ and here is the error |
|