Kapitel 15 GPIO
This commit is contained in:
Binary file not shown.
0
gpio/.gitignore → teil15/.gitignore
vendored
0
gpio/.gitignore → teil15/.gitignore
vendored
@@ -13,8 +13,8 @@ if __name__ =='__main__':
|
|||||||
# benutze Broadcom Pin Nummerierung
|
# benutze Broadcom Pin Nummerierung
|
||||||
GPIO.setmode(GPIO.BCM)
|
GPIO.setmode(GPIO.BCM)
|
||||||
|
|
||||||
# Pin 16 als Input mit Pull-Up-Widerstand schalten.
|
|
||||||
logging.debug(f'konfiguriere Pin ${__PIN__} als Input.')
|
logging.debug(f'konfiguriere Pin ${__PIN__} als Input.')
|
||||||
|
# Pin 16 als Input mit Pull-Up-Widerstand schalten.
|
||||||
GPIO.setup(__PIN__, GPIO.IN, pull_up_down=GPIO.PUD_UP)
|
GPIO.setup(__PIN__, GPIO.IN, pull_up_down=GPIO.PUD_UP)
|
||||||
pressed = False
|
pressed = False
|
||||||
|
|
Reference in New Issue
Block a user