Created
January 6, 2026 18:51
-
-
Save ikizoglu/7735abefaf45c197d5e9a9d727cf315e to your computer and use it in GitHub Desktop.
RaspberryPi-LED
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #RaspberryPi Temel LED Yakma Kodu | |
| #-------------------------------- | |
| import RPi.GPIO as GPIO | |
| import time | |
| GPIO.setmode(GPIO.BCM) | |
| GPIO.setwarnings(False) | |
| LED_PIN = 17 # GPIO17 (Pin 11) | |
| GPIO.setup(LED_PIN, GPIO.OUT) | |
| print("LED yanıyor...") | |
| GPIO.output(LED_PIN, GPIO.HIGH) | |
| time.sleep(5) | |
| print("LED sönüyor...") | |
| GPIO.output(LED_PIN, GPIO.LOW) | |
| GPIO.cleanup() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment