Cov txheej txheem:
- Khoom siv
- Kauj Ruam 1: Sib dhos Kho Vajtse
- Kauj ruam 2: Nruab Lirc
- Kauj Ruam 3: Kho Lirc_options.conf
- Kauj Ruam 4: Ua kom txav mus rau tshem tawm.dist Suffix From Lircd.conf.dist
- Kauj ruam 5: Kho kom raug Config.txt
- Kauj Ruam 6: Txheeb Cov xwm txheej thiab rov pib dua
- Kauj Ruam 7: Xeem Chaw Taws Teeb
Video: Teeb Yooj Yim IR Kev Tswj Chaw Taws Teeb Siv LIRC rau Raspberry PI (RPi) - Lub Xya Hli 2019 [Ntu 1]: 7 Cov Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:25
Tom qab tshawb nrhiav ntau kuv tau xav tsis thoob thiab poob siab txog cov ntaub ntawv tsis sib haum ntawm yuav teeb tsa IR chaw taws teeb tswj rau kuv li haujlwm RPi li cas. Kuv xav tias nws yuav yooj yim tab sis teeb tsa Linux InfraRed Control (LIRC) tau muaj teeb meem ntev tab sis hloov pauv ntau nyob rau lub Rau Hli 2019 nrog kev tso Buster version ntawm Raspbian ua ntau qhov kev qhia tawm tsis muaj nqis. Ntau qhov kev qhia koj tau tsim cov ntaub ntawv kho vajtse.conf tab sis LIRC tsis xav tau lossis tsis xav tau thiab lirc-rpi module tau hloov pauv nrog gpio-ir module.
Cov ntawv qhia xav tias RPi tab tom ua haujlwm raspbian (version Buster Jun 2019). Tsis tas li kev paub ua haujlwm ntawm lub davhlau ya nyob twg, cov lus txib yooj yim los ntawm kev hais kom ua sai sai thiab kho cov ntawv cov ntawv yog xav tau.
NCO TSEG: Kev teeb tsa LIRC yuav ua tsis tiav yog tias ua haujlwm hauv paus thiab ua rau muaj kev ntshai "tsis tuaj yeem ntshuam lub npe RawConnection" yuam kev thaum khiav cov nab npawb nab npawb. Cov ntawv qhia no xav tias koj tau nkag rau hauv tus neeg siv (piv txwv li: PI)
Lub Hom Phiaj: Txhawm rau pab IR tswj chaw taws teeb ntawm RPi cov haujlwm
1) Teeb LIRC ntawm RPi [Ntu 1]
2) Qhia tawm LIRC siv nab hab sej [Ntu 2]
Khoom siv
--- Raspberry Pi (3, 4, xoom)
--- Dupont xaim (poj niam-poj niam)
--- VS 1838b IR tus txais
Kauj Ruam 1: Sib dhos Kho Vajtse
Siv VS1838b IR tus txais tsis tuaj yeem yooj yim dua. Tsuas yog txuas tus ntsuas mus rau RPi ncaj qha nrog Dupont xaim (Poj niam-Poj niam). Koj kuj tseem tuaj yeem siv daim ntawv qhia zaub mov (tsis pom) lossis muab lo rau ntawm daim phiaj thaiv (duab)
Saib ntawm VS1838b IR Tus Tau Txais los ntawm sab xub ntiag (nrog X loj ntsib koj)
---- Sab laug sab tes tawm
---- Center ceg yog hauv av
Txoj cai ceg yog 3.3v
1) Txuas sab laug rau BCM tus pin 17 ntawm RPi (xaim daj)
2) Txuas nruab nrab ceg rau hauv av (xaim dub)
3) Txuas sab xis rau 3.3v (xaim liab)
Kauj ruam 2: Nruab Lirc
1) Qhib lub dav hlau qhov rai thiab teeb tsa LIRC. Yuav tsum ceeb toom tias qhov no yuav ua rau yuam kev "Ua tsis tiav los pib hloov pauv tau yooj yim IR cov chaw taws teeb nkag/tso tawm daim ntawv thov" raws li cov ntaub ntawv teeb tsa tam sim no muaj.dist txuas ntxiv thiab cov ntawv ntxiv yuav tsum raug tshem tawm raws li tau hais hauv qab no. Tsis nyuaj tab sis chim siab.
$ sudo apt-tau hloov tshiab
$ sudo apt-tau nruab lirc
---- Tsis txhob txhawj! raws li qhov no yuav tshwm sim qhov ua yuam kev "Ua tsis tiav pib hloov pauv tau yooj yim IR cov chaw taws teeb nkag/tso tawm daim ntawv thov" raws li.dist cov ntawv txuas ntxiv yuav tsum tau muab tshem tawm ntawm lirc_options.conf. Tsuas yog hloov npe cov ntaub ntawv raws li qhia.
$ sudo mv /etc/lirc/lirc_options.conf.dist /etc/lirc/lirc_options.conf
2) Rov txhim kho lirc tam sim no uas lirc_options.conf cov ntaub ntawv tau raug hloov pauv
$ sudo apt-tau nruab lirc
Kauj Ruam 3: Kho Lirc_options.conf
Kho kom raug /etc/lirc/lirc_options.conf raws li hauv qab no los ntawm kev hloov ob kab no:
:
:
tsav tsheb = default
ntaus ntawv = /dev /lirc0
:
:
Kauj Ruam 4: Ua kom txav mus rau tshem tawm.dist Suffix From Lircd.conf.dist
Tshem cov ntawv txuas ntxiv.dist los ntawm /etc/lirc/lircd.conf.dist
$ sudo mv /etc/lirc/lircd.conf.dist /etc/lirc/lircd.conf
Kauj ruam 5: Kho kom raug Config.txt
Kho /boot /config.txt los ntawm kev ntxiv ib kab hauv kab lirc-rpi module raws li hauv qab no. Qhov piv txwv no kwv yees RPi yog 'mloog' ntawm BCM Pin 17 rau IR tus txais tab sis ib qho RPi IO tus pin tuaj yeem siv tau. Kuv tseem tsis tau sim nws tab sis yog tias koj xav xa cov lus txib los ntawm RPi tom qab ntawd ntxiv thiab tsis pom zoo kab 4 pom hauv qab no kom xa IR cov lus txib ntawm BCM tus pin 18
:
:
:
# Tsis pom zoo qhov no txhawm rau ua kom lirc-rpi module
#dtoverlay = lirc-rpi
dtoverlay = gpio-ir, gpio_pin = 17
#dtoverlay = gpio-ir-tx, gpio_pin = 18
:
:
:
Kauj Ruam 6: Txheeb Cov xwm txheej thiab rov pib dua
1) Nres, pib thiab txheeb xyuas qhov xwm txheej ntawm lub lircd kom ntseeg tau tias tsis muaj qhov yuam kev!
$ sudo systemctl nres lircd.service
$ sudo systemctl pib lircd.service
$ sudo systemctl xwm txheej lircd.service
2) Rov pib dua
$ sudo rov pib dua
Kauj Ruam 7: Xeem Chaw Taws Teeb
Cov kauj ruam no xav tias koj muaj IR tus txais xov tooj txuas rau koj RPi ntawm tus pin tshwj xeeb hauv config.txt.
1) nres LIRCD cov kev pabcuam thiab sim cov chaw taws teeb siv hom 2 hais kom ua
$ sudo systemctl nres lircd.service
$ sudo mode2 -d /dev /lirc0
3) Taw tes rau cov chaw taws teeb ntawm tus txais thiab nias qee lub khawm. Koj yuav tsum pom qee yam LIKE qhov no:
:
:
qhov chaw
mem tes
:
:
4) Nias Ctrl-C kom tawm mus
5) Koj tus neeg txais IR tau teeb tsa thiab npaj txhij mus rau ntu 2 thiab nkag mus rau hauv nab hab sej.
Pom zoo:
D.I.Y YOOJ YIM YOOJ YIM YOOJ YIM YOOJ YIM YOOJ YIM LOS NTAWM SCRAPS: 4 Cov Kauj Ruam (nrog Duab)
D.I.Y YOOJ YIM YOOJ YIM YOOJ YIM YOOJ YIM LOS NTAWM SCRAPS: Hnub no kuv xav qhia yuav ua li cas kom pom lub teeb pom kev zoo los ntawm lub zog xa hluav taws xob tsis siv hluav taws xob los ntawm tus txhuam txhuam hniav thiab lub tshuab solenoid valve coils uas tau khaws los ntawm scrapyard.Ua ntej pib, thov saib cov vis dis aus hauv qab no:
Ordinary Cov Khoom Siv Hluav Taws Xob Hloov pauv mus rau Plaub-channel RC Qho Chaw Taws Teeb Chaw Taws Teeb: 4 Cov Kauj Ruam
Ordinary Cov Khoom Siv Hluav Taws Xob hloov pauv mus rau plaub-channel RC Toy Remote Control: 将 将 通用 遥控 器 转换 转换 玩具 玩具 模型 使用 的 62 62 62 62 62 62 62 62 62 62 62 62 62 62 62 62 62 62方法 方法 非常。 只需 准备 一些 瓦楞纸 瓦楞纸 板 板 , , , 然后 然后
DIY MusiLED, Music Synchronized LEDs Nrog Ib-nias Windows & Linux Application (32-ntsis & 64-ntsis). Yooj Yim Rov Ua Dua, Siv Yooj Yim, Yooj Yim rau Chaw Nres Nkoj: 3 Kauj Ruam
DIY MusiLED, Music Synchronized LEDs Nrog Ib-nias Windows & Linux Application (32-ntsis & 64-ntsis). Yooj Yim Rov Ua Dua, Siv Yooj Yim, Yooj Yim rau Chaw Nres Nkoj: Qhov haujlwm no yuav pab koj txuas 18 LEDs (6 Liab + 6 Xiav + 6 Daj) rau koj lub Rooj Tswjhwm Saib Arduino thiab txheeb xyuas koj lub khoos phis tawj Lub Suab Suab Lub suab lub sijhawm tiag tiag thiab xa lawv mus rau cov LEDs kom pom lawv raws li qhov cuam tshuam (Snare, High Hat, Kick)
YUAV UA LI CAS YOOJ YIM YOOJ YIM YOOJ YIM YOOJ YIM YOOJ YIM TSHAJ PLAWS YOOJ YIM: 4 Cov Kauj Ruam
YUAV UA LI CAS YOOJ YIM YOOJ YIM YOOJ YIM YOOJ YIM YOOJ YIM TSHAJ PLAWS: Nyob zoo txhua tus hauv cov lus qhia no kuv yuav qhia koj yuav ua li cas kom yooj yim " SOIL DRYNESS SENSOR ". Qhuav ntawm cov av tau txheeb xyuas siv qhov taw qhia coj. Lub teeb ci wi
MediaCenter Yooj Yim thiab Kev Tswj Chaw Taws Teeb Nrog Kev Txhim Kho Kev Siv: 6 Cov Kauj Ruam
Yooj Yim MediaCenter thiab Kev Tswj Chaw Taws Teeb Nrog Kev Txhim Kho Kev Siv Tau: Yog, qhov ntawd yog lwm qhov DIY PC-based Media-Center (lossis HTPC), tab sis nrog ib tus yam ntxwv tshwj xeeb: nws damn yooj yim los tswj, yog li haum rau cov neeg laus, cov neeg xiam oob qhab, lossis tsuas yog cov neeg siv tub nkeeg. Los ntawm Wikipedia: “