Belegung der GPIO-Pins des Raspberry Pi Model B.
Belegung GPIO-Pins (P1)
3V3 (1) (2) 5V
GPIO2 (3) (4) 5V
GPIO3 (5) (6) GND
GPIO4 (7) (8) GPIO14
GND (9) (10) GPIO15
GPIO17 (11) (12) GPIO18
GPIO27 (13) (14) GND
GPIO22 (15) (16) GPIO23
3V3 (17) (18) GPIO24
GPIO10 (19) (20) GND
GPIO9 (21) (22) GPIO25
GPIO11 (23) (24) GPIO8
GND (25) (26) GPIO7
Python Code-Beispiel: Blinkende LED
from gpiozero import LED
from time import sleep
led = LED(2)
while True:
led.on()
sleep(0.5)
led.off()
sleep(0.5)