Cov txheej txheem:
- Kauj Ruam 1: Sib dhos Circuit
- Kauj Ruam 2: Kho Qhov System Boot File
- Kauj ruam 3: Reboot thiab Txaus siab rau
Video: Raspberry Pi Power Button: 3 Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:27
Yog tias koj zoo li kuv, koj yuav tau scouring internet nrhiav kev daws teeb meem zoo tshaj plaws kom nyab xeeb tig koj lub Raspberry Pi rau thiab tawm nrog kev thawb lub pob. Thaum muaj ntau cov kev daws teeb meem, feem ntau xav kom koj rub tawm Python tsab ntawv thiab ua kom nws ua tiav ntawm khau raj-thiab muaj ntau dua ib txoj hauv kev los ua qhov ntawd. Txawm li cas los xij, kev daws teeb meem yooj yim dua twb tau ci rau hauv Raspberry Pi. Los ntawm kev luv luv tus pin tshwj xeeb thiab ntxiv ib kab rau cov ntawv teeb tsa khau raj, koj tuaj yeem muaj lub zog ua haujlwm tau zoo hauv tsawg li 10 feeb!
Kauj Ruam 1: Sib dhos Circuit
Sau cov ntaub ntawv hauv qab no:
- Raspberry Pi (Kuv siv 3A+ nrog qhov tseeb Raspbian Stretch ntsia)
- 2 poj niam-rau-txiv neej jumper xov hlau ORAdafruit T-Cobbler Ntxiv rau Raspberry Pi (nrog 40 tus pin txuas)
- 2 txiv neej jumper xov (XWB yog siv T-Cobbler)
- 1 lub sij hawm thawb khawm
- 1 ib nrab-me me (lossis loj dua) daim ntawv qhia zaub mov
Txuas txhua xaim mus rau kev sib cuag ntawm lub laub khawm. Tom qab ntawd txuas ib lub xaim rau tus pin 5 (GPIO3/SCL) thiab ib lub xov hlau rau tus pin 6 (GND). Tam sim no, ib nrab txoj haujlwm twb ua tiav lawm! Lub sijhawm luv luv pins 5 thiab 6 los ntawm kev nias lub pob nyem yuav ua rau Pi los ntawm lub xeev nres. (Raspberry Pi tseem nyob hauv lub xeev nres thaum nws "kaw" tab sis tseem txuas nrog lub zog.)
Kauj Ruam 2: Kho Qhov System Boot File
Tam sim no, koj tuaj yeem tsa koj tus Pi tom qab kaw nws. Thaum qhov no yog kauj ruam zoo tiag tiag, koj tuaj yeem ntxiv me ntsis ua haujlwm ntxiv rau koj lub zog khawm tshiab: koj tuaj yeem siv tib lub pob kom kaw koj tus Pi kom nyab xeeb!
Nkag mus rau koj tus Pi (lossis SSH yog siv lub chaw taws teeb/teeb tsa lub taub hau), thiab sau cov hauv qab no rau hauv kab hais kom ua:
sudo nano /boot /config.txt
Qhov no yuav qhib cov ntaub ntawv teeb tsa uas koj Pi siv thaum khau raj. Thaum kawg ntawm cov ntawv, ntxiv cov hauv qab no:
dtoverlay = gpio-kaw
Lub gpio-kaw kaw ua rau Raspberry Pi raug kaw thaum tus pin 5 thiab 6 (twb txuas nrog lub laub khawm) tau luv ib ntus. Nias CTRL X kom tawm mus, tom qab ntawd nias Y thiab ENTER kom txuag koj qhov kev hloov pauv rau "config.txt" cov ntaub ntawv.
Yog Siv I2C:
Koj yuav tau pom tias GPIO3 (tus pin 5) kuj tseem yog SCL tus pin rau txuas I2C cov cuab yeej. Thaum koj YUAV TSUM siv tus pin 5 thiab 6 kom sawv Raspberry Pi los ntawm nws lub xeev nres, koj tuaj yeem hais qhia tus lej GPIO sib txawv los siv rau kaw koj tus Pi, yog li tso GPIO3 siv nrog koj li I2C li.
Txhawm rau txheeb xyuas tus lej sib txawv kaw, qhib "config.txt" cov ntaub ntawv, thiab ntxiv qhov "gpio-pin" parameter rau txheej. Piv txwv li, koj qhov chaw teeb tsa yuav zoo li no yog tias koj yuav siv GPIO21 (tus pin 40) ua tus pin kaw:
dtoverlay = gpio-kaw, gpio-pin = 21
Yog Xav Paub Ntxiv:
Yog tias koj xav kawm paub ntau ntxiv txog kev ua haujlwm ntawm cov txheej txheem no, sau cov hauv qab no:
dtoverlay -h gpio -kaw
Txhawm rau kawm paub txog kev sib tshooj ntxiv, mus rau phau ntawv qhia kev sib tshooj hauv cov npe hauv qab no:
cd/khau raj/sib tshooj/README
Txhawm rau kawm paub ntau ntxiv txog yam tsis txaus ntseeg koj tuaj yeem ua nrog "config.txt", mus ntsib Raspberry Pi lub vev xaib ntawm no rau cov ntaub ntawv raug cai.
Kauj ruam 3: Reboot thiab Txaus siab rau
Rau cov kev hloov pauv no kom siv tau, rov pib dua koj Pi. Thaum rov pib dua, thaum twg koj nias lub pob nyem, koj Pi yuav raug kaw kom nyab xeeb. Thaum koj tus Pi raug kaw, koj tuaj yeem nias lub pob kom rov tsim nws dua los ntawm nws lub xeev nres.
Nrog koj zoo siab! Tam sim no koj muaj lub zog ua haujlwm zoo rau koj li Raspberry Pi!
Pom zoo:
Hacking USB Power Banks rau Power Arduino: 6 Kauj Ruam
Hacking USB Power Banks rau Fais Fab Arduino: Siv lub txhab nyiaj pheej yig pheej yig los txhawb koj li Arduino circuits yog kev ntxhov siab heev nrog lawv qhov qis tam sim no, pib tawm hluav taws xob. 30-40 vib nas this. Cia peb hloov kho Ch
DIY High Power Bench Power Supply: 85W: 3 Kauj Ruam
DIY High Power Bench Power Supply: 85W: Cov khoom siv hluav taws xob yog cov kua txiv ntawm koj cov phiaj xwm, ua yog tus tsim khoom me lossis tus tshaj lij, koj ib txwm xav tau lub zog ruaj khov thiab muaj hwj chim zoo ntawm koj qhov pov tseg. yog kim, yog lawv suav nrog ntau yam
Tsim Kom Zoo Raspberry Pi Power Button: 4 Cov Kauj Ruam
Tsim kom zoo dua Raspberry Pi Fais Fab Khawm: Nws yooj yim heev los ua Raspberry lub zog-tua lossis kaw lub pob. Muaj ntau ntau txoj haujlwm zoo hauv lub vev xaib thiab ob peb ntawm no ntawm Cov Ntawv Qhia, tab sis tsis muaj ib ntawm lawv (uas kuv tuaj yeem pom) qhia koj thaum koj Pi tau ua tiav kaw thiab yog li nws yog
Super Ghetto Power Button ntawm Kuv Oneplus Ib (Yuav Tsum Ua Haujlwm Txhua Yam): 3 Kauj Ruam
Super Ghetto Power Button ntawm Kuv Oneplus Ib (Yuav Tsum Ua Haujlwm Txhua Yam): Qhov teeb meem: Txhua lub pob ntawm kuv lub xov tooj tau tawg lawm. Hloov lawv tsuas yog kev daws teeb meem ib ntus vim tias kuv lub nraub qaum tau tawg thiab kuv tsis tuaj yeem nrhiav qhov twg los hloov qhov uas tsis pub dhau tus nqi ntawm kev siv OPO, tab sis kuv xav tias vim li cas ho tsis hloov kho yog tias kuv
TI-83 Power Button Mod: 6 Kauj Ruam
TI-83 Power Button Mod: Zoo nkauj npaum li txhua lub tsev kawm ntawv theem siab Kuv paub tias yuav tsum muaj TI-83 lossis zoo dua rau lawv chav kawm lej. Koj yuav tsum sawv tawm. Yog li, lo rau lub zog txias zog khawm hauv nws.Kuv tus phooj ywg macbook pro tuag, thiab peb tau noj nws sib nrug, thaum peb ntaus lub pob khawm