Cov txheej txheem:
- Kauj Ruam 1: Txuas Koj Raspberry Pi GPIO Nrog LED ntawm Breadboard lossis Pawg Thawj Coj Ua Haujlwm
- Kauj ruam 2: Teeb
- Kauj Ruam 3: Nruab GPIO Libraries
- Kauj Ruam 4: Txoj Haujlwm
Video: Raspberry Pi Tutorial ntawm LED Blinking: 4 Cov Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:29
Yuav tsum tau:
- Raspberry Pi
- BreadBoard lossis T-Cobbler
- Jumper Hlau
- LED
Nyem rau qhov no Yog Xav Paub Ntxiv
Kauj Ruam 1: Txuas Koj Raspberry Pi GPIO Nrog LED ntawm Breadboard lossis Pawg Thawj Coj Ua Haujlwm
Tam sim no raws li cov vis dis aus koj tuaj yeem siv tus lej tus lej 27 raws li tso tawm thiab txuas GND nrog coj GND davhlau ya nyob twg, Nco ntsoov tias koj qhov kev sib txuas GPIO yuav tsum raug.
Kauj ruam 2: Teeb
Txuas LED ntawm breadbard lossis T-cobbler raws li txuas video.
Kauj Ruam 3: Nruab GPIO Libraries
$ sudo apt-tau hloov tshiab
$ sudo apt-tau nruab python-rpi.gpio python3-rpi.gpio
Kauj Ruam 4: Txoj Haujlwm
ntshuam RPi. GPIO ua GPIO
lub sij hawm ntshuam
LedPin = 11 # pin11
def teeb tsa ():
GPIO.setmode (GPIO. BOARD) # Tus lej GPIOs los ntawm qhov chaw nyob
GPIO.setup (LedPin, GPIO. OUT) # Teeb LedPin hom yog tso tawm
GPIO.output (LedPin, GPIO. HIGH) # Teeb LedPin siab (+3.3V) kom tig rau coj
def ntsais ():
thaum Muaj Tseeb:
GPIO.output (LedPin, GPIO. HIGH) # coj mus
tsaug zog (1)
GPIO.output (LedPin, GPIO. LOW) # coj tawm sijhawm.sleep (1)
def rhuav tshem ():
GPIO.output (LedPin, GPIO. LOW) # coj tawm
GPIO.cleanup () # Tso peev txheej
yog _name_ == '_main_':
teeb ()
sim:
ntsais muag ()
tshwj tsis yog KeyboardInterrupt:
rhuav tshem ()
Pom zoo:
Plotting Real-time Graph ntawm Android Los Ntawm Arduino Los Ntawm HC-05: 3 Cov Kauj Ruam
Plotting Real-time Graph ntawm Android Los ntawm Arduino Los ntawm HC-05: Hav nyob ntawm no, ntawm no yog kev qhia qhia yuav ua li cas npaj cov phiaj xwm ntawm lub sijhawm tiag tiag ntawm qhov tseem ceeb los ntawm tus tswj hwm micro xws li Arduino rau lub app. Nws siv Bluetooth qauv xws li HC-05 los ua lub cuab yeej xa xov mus rau kis thiab tau txais cov ntaub ntawv ntawm Ar
AVR Microcontroller Fuse Cov Khoom Kho. Tsim thiab Tshaj Tawm hauv Flash Nco ntawm Microcontroller LED Blinking Program: 5 Kauj Ruam
AVR Microcontroller Fuse Cov Khoom Kho. Tsim thiab Tshaj Tawm hauv Flash Nco ntawm Microcontroller LED Blinking Program: Hauv qhov no peb yuav tsim cov phiaj xwm yooj yim hauv C code thiab hlawv nws mus rau hauv lub cim xeeb ntawm microcontroller. Peb yuav sau peb tus kheej txoj haujlwm thiab suav sau cov ntawv hex, siv Atmel Studio ua kev txhim kho kev sib koom ua ke. Peb yuav teeb tsa fuse ob
Tsim thiab Ua tiav ntawm Cov Txheej Txheem ntawm Kev Taw Qhia ntawm Photovoltaic Panels: 5 Cov Kauj Ruam
Tsim thiab Ua kom tiav ntawm Cov Txheej Txheem ntawm Kev Taw Qhia ntawm Photovoltaic Panels: Tsim thiab Ua tiav ntawm Cov Txheej Txheem ntawm Kev Taw Qhia ntawm Photovoltaic Panels
Kev tswj hwm tus kheej ntawm RPM ntawm Lub Cav Siv Lub Tswv Yim Los Ntawm IR Raws Li Tachometer: 5 Cov Kauj Ruam (nrog Duab)
Kev Tswj Tus Kheej ntawm RPM ntawm Lub Cav Siv Lub Tswv Yim Los Ntawm IR Raws Lub Tachometer: Muaj ib txwm xav tau rau kev siv tshuab txheej txheem, ua nws yooj yim/tsis txaus ntseeg. cov txheej txheem rau dej/siv dej rau peb daim av me me.Qhov teeb meem ntawm tsis muaj kab khoom siv tam sim no
Zaub Cov Duab Tawm ntawm PSP/Lub Xov Tooj Ntawm Lub Xov Tooj Ntawm Digital Duab: 3 Kauj Ruam
Zaub Cov Duab Tawm PSP/Lub Xov Tooj Ntawm Lub Xov Tooj Ntawm Tus Duab: Zoo … lub npe hais tias txhua yam tiag tiag … Qhov no yog qhov qhia tau yooj yim heev thiab nws tsis xav tau kho vajtse lossis software ntau dua li koj yuav tsum muaj ! Cov Lus Nug Qhia Rau Kuv lossis Tawm Tswv Yim! Koj tsis tas yuav hloov kho kom ua