-
Fototrend
Amit érdemes tudni a Raspberry Pi-kről:
A legelső változat 2012-ben jelent meg. Pici, olcsó és nagyon alacsony fogyasztású, hobby-célú kártyagép. Felépítése ARM alapú, nem PC-architektúra, hanem kb. egy régi mobilhoz hasonló. Nagyon sok mindenre használható! A Linux-nak és a magas eladási mennyiségnek köszönhetően jelentős fejlesztőtáborral rendelkezik.
Új hozzászólás Aktív témák
-
petya220
senior tag
válasz
D@reeo
#22791
üzenetére
Nem válasz akart ez lenni :c Bocsi

Üdv
Egy kis segítséget szeretnék kérni, szereztem egy 7 szegmensű led kijelzőt (vagy miez... ), és írtam is hozzá egy programot,de ezt nem tudom, valahogy lerövidíteni? xDD
Ez a kód pl visszaszámol, de ez rohadt hosszú számomra..import RPi.GPIO as GPIO
import time
GPIO.setmode(GPIO.BCM)
GPIO.setwarnings(False)
GPIO.setup(9,GPIO.OUT)
GPIO.setup(10,GPIO.OUT)
GPIO.setup(17,GPIO.OUT)
GPIO.setup(18,GPIO.OUT)
GPIO.setup(23,GPIO.OUT)
GPIO.setup(24,GPIO.OUT)
GPIO.setup(27,GPIO.OUT)
GPIO.output(23,GPIO.LOW)
GPIO.output(17,GPIO.LOW)
GPIO.output(27,GPIO.LOW)
GPIO.output(10,GPIO.HIGH)
GPIO.output(18,GPIO.LOW)
GPIO.output(24,GPIO.LOW)
GPIO.output(9,GPIO.LOW)
time.sleep(0.5)
GPIO.output(23,GPIO.LOW)
GPIO.output(17,GPIO.LOW)
GPIO.output(27,GPIO.LOW)
GPIO.output(10,GPIO.LOW)
GPIO.output(18,GPIO.LOW)
GPIO.output(24,GPIO.LOW)
GPIO.output(9,GPIO.LOW)
time.sleep(0.5)
GPIO.output(23,GPIO.LOW)
GPIO.output(17,GPIO.LOW)
GPIO.output(27,GPIO.LOW)
GPIO.output(10,GPIO.LOW)
GPIO.output(18,GPIO.LOW)
GPIO.output(24,GPIO.LOW)
GPIO.output(9,GPIO.LOW)
time.sleep(0.5)
GPIO.output(23,GPIO.LOW)
GPIO.output(17,GPIO.LOW)
GPIO.output(27,GPIO.HIGH)
GPIO.output(10,GPIO.HIGH)
GPIO.output(18,GPIO.HIGH)
GPIO.output(24,GPIO.LOW)
GPIO.output(9,GPIO.HIGH)
time.sleep(0.5)
GPIO.output(23,GPIO.HIGH)
GPIO.output(17,GPIO.LOW)
GPIO.output(27,GPIO.LOW)
GPIO.output(10,GPIO.LOW)
GPIO.output(18,GPIO.LOW)
GPIO.output(24,GPIO.LOW)
GPIO.output(9,GPIO.LOW)
time.sleep(0.5)
GPIO.output(23,GPIO.HIGH)
GPIO.output(17,GPIO.LOW)
GPIO.output(27,GPIO.LOW)
GPIO.output(10,GPIO.HIGH)
GPIO.output(18,GPIO.LOW)
GPIO.output(24,GPIO.LOW)
GPIO.output(9,GPIO.LOW)
time.sleep(0.5)
GPIO.output(23,GPIO.LOW)
GPIO.output(17,GPIO.LOW)
GPIO.output(27,GPIO.HIGH)
GPIO.output(10,GPIO.HIGH)
GPIO.output(18,GPIO.LOW)
GPIO.output(24,GPIO.HIGH)
GPIO.output(9,GPIO.LOW)
time.sleep(0.5)
GPIO.output(23,GPIO.LOW)
GPIO.output(17,GPIO.LOW)
GPIO.output(27,GPIO.LOW)
GPIO.output(10,GPIO.HIGH)
GPIO.output(18,GPIO.HIGH)
GPIO.output(24,GPIO.LOW)
GPIO.output(9,GPIO.LOW)
time.sleep(0.5)
GPIO.output(23,GPIO.LOW)
GPIO.output(17,GPIO.HIGH)
GPIO.output(27,GPIO.LOW)
GPIO.output(10,GPIO.LOW)
GPIO.output(18,GPIO.HIGH)
GPIO.output(24,GPIO.LOW)
GPIO.output(9,GPIO.LOW)
time.sleep(0.5)
GPIO.output(23,GPIO.LOW)
GPIO.output(17,GPIO.LOW)
GPIO.output(27,GPIO.HIGH)
GPIO.output(10,GPIO.HIGH)
GPIO.output(18,GPIO.HIGH)
GPIO.output(24,GPIO.HIGH)
GPIO.output(9,GPIO.HIGH)
time.sleep(0.5)
GPIO.output(23,GPIO.LOW)
GPIO.output(17,GPIO.LOW)
GPIO.output(27,GPIO.LOW)
GPIO.output(10,GPIO.LOW)
GPIO.output(18,GPIO.LOW)
GPIO.output(24,GPIO.LOW)
GPIO.output(9,GPIO.HIGH)Valami ötlet?

Új hozzászólás Aktív témák
- Bontott 0perces MIDNIGHT MacBook Air 15" M4 10C/1G 16GB 256GB Gar.: 1 év APPLE gar
- Huawei Free Clip 2 - Hüvely a füledre, de a füled a hüvelye
- Magyarország piacvezető szoftver webáruháza
- ÚJ Apple Airpods Pro 3 - www.stylebolt.hu - 1 Év Apple garancia - 27 százalékos Áfá-s száma !!!!
- BESZÁMÍTÁS! Apple MacBook Air 15 M4 32GB RAM 1TB SSD notebook garanciával hibátlan működéssel
Állásajánlatok
Cég: Laptopműhely Bt.
Város: Budapest



wassermann