Cov txheej txheem:
- Kauj Ruam 1: Qhov Chaw
- Kauj ruam 2: Teeb Kho Vajtse
- Kauj Ruam 3: Programming Xim Sensor
- Kauj Ruam 4: Teeb Raspbian rau RFID RC522
- Kauj Ruam 5: Tsim Node-RED Flow kom Nyeem Koj Li RFID Tag thiab Xim Xim
- Kauj Ruam 6: Tso thiab Dashboard
- Kauj ruam 7: Yav tom ntej
Video: RFID + Xim Sensor IoT Project: 7 Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:27
Lub tswv yim ntawm txoj haujlwm no yog muab nqi zog rau cov neeg uas haus cov khob kas fes thiab pov tseg lawv kom raug. Ua ib lub tuam txhab zoo li Tim Hortons piv txwv; xyoo 2014, lawv tau sau tseg ua haujlwm 2 billion khob kas fes txhua xyoo. Txawm hais tias lawv lub khob tuaj yeem rov ua dua tshiab, lawv tsis raug lees txais rov ua dua txhua qhov chaw nyob rau lub sijhawm no. Raws li tau hais hauv lawv lub vev xaib, tam sim no peb muaj cov haujlwm hauv ntau lub tsev noj mov thoob plaws tebchaws Canada uas peb ntes peb lub khob ntawv (thiab lwm yam ntim khoom) rau rov ua dua tshiab los yog ua dua tshiab. Tus naj npawb ntawm cov chaw uas peb muab rau hauv khw muag khoom rov ua dua tshiab txuas ntxiv thaum peb ua haujlwm nrog cov tuam txhab tswj hwm pov tseg hauv nroog txhawm rau nthuav peb txoj haujlwm…”
Yog li, thaum lawv txuas ntxiv nthuav thiab nce kev lag luam raws li kev saib xyuas ib puag ncig ib puag ncig, peb ntseeg tias lawv tseem tuaj yeem ua rau cov neeg siv khoom nce ntxiv thiab nce kev paub los ntawm kev tsim cov khoom plig txhawb zog.
Txoj haujlwm no yog kev sim txhawm rau txhim kho cov txheej txheem ib puag ncig lub tswv yim no.
Kauj Ruam 1: Qhov Chaw
- Raspberry Pi 3
- Arduino Mega Cov
- Mini khob cij
- Poj niam. Txiv neej jumper xov hlau
- 2 x LEDs (liab & ntsuab)
- 2 x 330 Ohm Resistors
- TCS3200 Xim Sensor
- RC522 RFID nyeem ntawv thiab Cim npe
- USB 2.0 Cable Hom A/B.
- Computer thiab Internet
- Khob kas fes
Kauj ruam 2: Teeb Kho Vajtse
Txuas TCS 3200 rau Arduino
VCC 5 VV
GND GND
S04 ib
S1 5
S2 6
S3 7
E0 NPE
TSUAS 8
Txuas RFID/LEDs rau Raspberry Pi
SDAB 24
SWB 23
MOOG 19
MYOB 21
NQA 6
TSW 22
3.3V 1
GREEN LED 12 thiab 330 Ohm rau GND
RED LED 11 thiab 330 Ohm rau GND
Kauj Ruam 3: Programming Xim Sensor
TCS3200 hnov xim lub teeb los ntawm sab hauv 8 x 8 photodiode array. Tam sim no qhov hloov pauv zaus tau siv los hloov kev nyeem ntawv los ntawm photodiode mus rau hauv lub xwmfab yoj uas nws qhov zaus yog sib piv rau qhov siv ntawm lub teeb.
Photodiodes muaj peb lub lim dej sib txawv. Muaj 16 lub lim dej liab, 16 lub lim dej ntsuab, 16 lub lim dej xiav, thiab lwm yam 16 cov duab tsis muaj lim.
Txhawm rau kom lub photodiode nyeem cov xim, peb yuav tsum tswj tus pin S2 thiab S3.
Rooj Xim:
Xim S2 S3
Liab LOW LOW
Xiav LOW HIGH
Ntsuab HIGH HIGH
Txhua lub sensor tej zaum yuav txawv me ntsis hauv zaus. Nqa lub sensor ze rau lub khob. Siv Colour_Tester.ino tus lej txhawm rau nrhiav qhov tseeb raug rau koj lub khob tshwj xeeb thiab nco qab cov txiaj ntsig muab hauv Serial Monitor. Tom qab ntawd sau yog tias cov lus tshaj tawm "yog" lossis "tsis yog" yog lub ntsuas tau pom lub khob raws li qhia hauv Sensor_Data.ino.
Thaum ua tiav, txuas Arduino mus rau Raspberry Pi ntawm USB cable.
Kauj Ruam 4: Teeb Raspbian rau RFID RC522
1. Pab kom SPI (Serial Peripheral Interface), qhib lub davhlau ya nyob twg thiab khiav cov lus txib hauv qab no.
sudo raspi-teeb tsa
2. Siv tus xub xub los xaiv “5 Qhov Kev Xaiv Ua Ntej” thiab nias Enter.
3. Siv koj cov yawm sij xub xaiv "P4 SPI", thiab nias Enter.
4. Tam sim no koj yuav raug nug yog tias koj xav kom pab tau SPI Interface, xaiv Yog nrog koj tus xub xub thiab nias Enter kom mus ntxiv.
5. Thaum SPI interface tau ua tiav ua tiav koj yuav tsum pom cov ntawv hauv qab no tshwm ntawm qhov screen, "SPI interface tau qhib". Pib dua Raspberry Pi los ntawm nias Enter thiab tom qab ntawd ESC. Ntaus cov lus txib hauv qab no rau hauv lub davhlau ya nyob twg ntawm koj tus Raspberry Pi kom rov pib dua koj li Raspberry Pi.
sudo rov pib dua
6. Thaum koj Raspberry Pi tau rov ua tiav tiav, kos kom paub tseeb tias nws tau ua tiav qhov tseeb. Khiav cov lus txib hauv qab no kom pom tias spi_bcm2835 tau teev tseg.
lsmod | pab spi
7. Nruab Python-dev thiab git nrog cov lus txib.
sudo apt-tau nruab python-dev git
8. Pib Node-Liab los tsim daim nplaub tshev ~/.node hauv koj lub tsev nplaub tshev. Khiav qhov hais kom ua
ntawm-liab-pib
Nkag mus rau tus neeg siv siv koj tus browser, taw rau qhov chaw nyob https://: 1880. Piv txwv li kuv tus Pi nyob ntawm kuv lub chaw haujlwm hauv tsev network ntawm chaw nyob 192.168.0.17, yog li nkag Node-RED Kuv xauj mus rau
Tam sim no nres Node-Red Server nrog cov lus txib.
ntawm-liab-nres
9. Nruab Daemon node thiab Serial node.
cd ~./node-liab
npm i node-red-node-daemon npm i node-red-node-serialport
10. Nruab SPI-Py.
cd ~ ib
git clone https://github.com.lthiery/SPI-Py.git cd SPI-Py/sudo python setup.py install
11. Luam cov ntaub ntawv no los ntawm zip hauv koj tus neeg siv phau ntawv qhia tsev - piv txwv li /tsev /pi.
12. Reboot tus pi thiab Pib Node-Red ib zaug ntxiv.
13. Kuaj daim npav nyeem ntawv los ntawm kev sau tsab ntawv los ntawm kab hais kom ua
cd ~ ib
nab hab sej rfidreader.py
Thaum koj yoj daim ntawv tsis pub dhau ~ 1cm ntawm thaj tsam tseem ceeb ntawm daim npav nyeem ntawv, tsab ntawv yuav luam tawm qhov tshwj xeeb UID ntawm daim npav, thiab nws yog hom. Muaj ntau hom ntawv, feem ntau hu ua MIFARE 1KB, tab sis muaj lwm tus. Tsis yog txhua daim npav siv tib txoj kev sib txuas lus RF yog li tsis txhob poob siab yog tias daim npav random uas koj khaws tuaj tsis raug lees paub. Nco ntsoov UID ntawm koj cov ntawv cim npe rau tom qab.
Kauj Ruam 5: Tsim Node-RED Flow kom Nyeem Koj Li RFID Tag thiab Xim Xim
Txuas rau Node-RED ntawm koj Pi siv lub browser-xws li los ntawm lwm lub khoos phis tawj lossis ntawm Pi nws tus kheej.
1. Nyem rau lub cim hamburger nyob ib sab ntawm lub pob liab liab tso rau saum txoj cai.
2. Mus rau Ntshuam thiab nyem rau ntawm Clipboard.
3. Luam tag nrho cov ntsiab lus ntawm cov ntawv hauv kab ntawv-liab-flow.txt thiab muab tshuaj txhuam rau hauv daim ntawv los teev cia thiab nias Ntshuam.
4. Peb yuav tsum xyuas kom txhua yam tau teeb tsa kom raug. Ua ntej tshaj, nyem rau ntawm kab lus txiv kab ntxwv daj (sab laug sab laug). Nyem rau ntawm lub cim Cim thiab tom qab ntawd lub Viewfinder icon thiab xaiv qhov chaw nres nkoj txuas uas Arduino txuas nrog. Tom qab ntawd Nyem rau qhov hloov tshiab khawm ua raws li lub pob ua tiav liab.
5. Tom ntej no peb yuav teeb tsa lub paj liab MQTT (tom ntej no rau ntawm cov kab ntawv txuas). Nyem rau ntawm Pen icon. Ntaus tus IP chaw nyob ntawm qhov chaw koj xav kom tus broker ua. Thaum ua tiav, nyem lub pob Hloov tshiab liab thiab khawm Ua tiav liab.
6. Thaum kawg, peb teeb tsa lub txiv kab ntxwv ua haujlwm hu ua JSON mus rau Lub Hom Phiaj nyob ib sab ntawm RFIDReader node. Txoj haujlwm muaj cov lus hloov pauv. Qhov no yuav siv UID ntawm cov cim npe thiab hloov npe rau lawv. Hauv peb qhov xwm txheej, peb muaj ob daim ntawv cim npe uas peb tau hloov pauv Tus Neeg Siv 1 thiab Tus Neeg Siv 2.
CEEB TOOM CEEB TOOM: Yog tias koj npaj siab siv ntau dua ob daim ntawv koj yuav tau hloov cov ntawv sau/ntws.
Kauj Ruam 6: Tso thiab Dashboard
Txhua yam yog teeb tsa thiab npaj mus. Nias lub pob Deploy liab nyob rau sab xis saum toj.
Nyem rau ntawm kab duab kab cim hauv qab nws ua raws los ntawm lub cim uas zoo li yog lub npov nrog tus xub. Lub qhov rai tshiab yuav tsum tshwm nrog RFID & SENSOR TABLE thiab RFID-RC522 widgets.
Nias lub khawm Tsim kom pib lub rooj tshiab thiab pib ntsuas koj cov ntawv cim npe. Koj yuav tsum pom lub rooj qhia pom cov cim cim sib txawv ntawm cov ntsiab lus/sijhawm nws tau kuaj pom thiab hnub/sijhawm. Lub caij no, ntawm lub khob cij, cov zaub ntsuab yuav tsum ci thaum twg pom cov cim, yog tias tsis yog lub teeb liab yuav nyob. (Txhawm rau tshem lub rooj, nyem Clear thiab rho tawm lub rooj xovxwm Rho tawm). Cov xim xim yuav tsum ua haujlwm zoo ib yam. Yog tias lub khob raug kuaj pom ces lub teev dub yuav tig ntsuab.
Kauj ruam 7: Yav tom ntej
- Zoo saib UI
- Ntau Cov Neeg Siv
- Lub Koob Yees Duab/Duab cov ntaub ntawv kom pom tseeb lub khob kas fes
- Xa cov ntsiab lus hloov tshiab rau twitter account
Pom zoo:
Yuav Ua Li Cas Tus Qauv Xim Xim hauv Modkit rau Vex: 7 Cov Kauj Ruam
Yuav Ua Li Cas Tus Qauv Xim Xim hauv Modkit rau Vex: Nyob zoo txhua tus, hauv qhov kev qhia no koj yuav kawm paub yuav ua li cas rau tus lej pob xim xim hauv Modkit rau VexHope koj ua thiab txaus siab rau! Pls pov npav rau kuv
App Tswj Xim Xim: 7 Kauj Ruam (nrog Duab)
App Tswj Cov Xim Xim: Nyob zoo, hauv cov lus qhia no kuv qhia koj yuav tsim chav chav teeb pom kev zoo li cas los ntawm txoj kab zeb zeb. Txhua yam tuaj yeem tswj tau ntawm WLAN nrog app.https: //youtu.be/NQPSnQKSuoUT Muaj qee qhov teeb meem nrog txoj haujlwm. Tab sis thaum kawg koj tuaj yeem ua rau nws ntse
Kev pleev xim rau xim: 5 Kauj Ruam
Cov xim pleev xim: Sensorial Painting es un proyecto diseñado para que alguien no vidente pueda pintar o dibujar dentro de bordes que uno pueda delimitar. En este caso utilizaremos un Kultrun de la cultura y pueblo mapuche. SP te avisará mediante sonidos de un Trompe
MESOMIX - Automated Xim Xim Xim Tshuab: 21 Cov Kauj Ruam (nrog Duab)
MESOMIX - Automated Xim Xim Xim Tshuab: Koj puas yog tus tsim qauv, tus kws kos duab lossis tus neeg muaj tswv yim uas nyiam tha xim rau ntawm koj daim ntaub, tab sis feem ntau nws nyuaj thaum nws los ua qhov ntxoov ntxoo uas xav tau. uas tawm tsam rau huab cua nyias. Raws li cov cuab yeej no, koj
Cov xim pleev xim ntau xim (Kov Rhuav): 8 Kauj Ruam (nrog Duab)
Cov xim pleev xim ntau xim (Kov Rhuav): Teeb duab yog cov txheej txheem thaij duab siv los tsim cov teebmeem tshwj xeeb ntawm qhov kaw qhov nrawm. Lub teeb nyem feem ntau yog siv rau "xim" cov duab. Hauv Cov Lus Qhia no, Kuv yuav qhia koj yuav ua li cas txhawm rau tsim txhua yam hauv ib tus kws pleev xim nrog kov