I want to implement a function that does not abort my program but wait until I press the button on channel 11. And start the program again.
#!/usr/bin/env python
import RPi.GPIO as GPIO
import time
import os
GPIO.setwarnings(False)
GPIO.setmode(GPIO.BCM)
GPIO.setup(11,GPIO.IN) #GPIO17
while GPIO.input(11) == GPIO.LOW:
GPIO.input(11) == GPIO.LOW
os.system("python /home/pi/gpio.py")
if not (GPIO.input(11) == GPIO.HIGH):
break
![enter image description here] (https://i.sstatic.net/UOzdW.jpg)