Cov txheej txheem:
- Kauj Ruam 1: Txiav LED Sawb
- Kauj Ruam 2: Tsim Tus Qauv
- Kauj Ruam 3: Txuas cov kab xev LED rau ntawm tus ncej
- Kauj Ruam 4: Txuas Nws
- Kauj Ruam 5: Txuas mus rau ESP8266 thiab Upload Sketch
Video: ESP8266 / Arduino RGB LED Christmas Lub Teeb Kho Kom Zoo Nkauj Qhov Rai: 5 Kauj Ruam (nrog Duab)
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:30
Nws yog lub sijhawm xyoo ntawd: Kaum Ob Hlis. Thiab hauv kuv cov neeg nyob ib puag ncig, txhua tus tau dai lawv lub tsev thiab lub qhov rais nrog qee qhov Christmas teeb. Lub sijhawm no, Kuv txiav txim siab tsim qee yam kev cai, tshwj xeeb, siv ESP8266 tus qauv thiab tsuas yog ob peb ntawm RGB LEDs. Koj tuaj yeem ua qhov no tib yam siv Arduino (Uno/Pro) module, tab sis nrog ESP module koj kuj tau txais nws wifi-ua haujlwm, rau kev tswj chaw taws teeb, teem sijhawm qhib/tua.
Cov khoom siv xav tau…
- ESP8266 (NodeMCU module) lossis Arduino Uno/Pro/Pro Mini/thiab lwm yam. Cov ntawv qhia no yog rau ESP8266, tab sis nws kuj tseem siv rau lwm tus
- Ib tus zuj zus tuaj yeem hais qhia RGB LED teeb sawb (WS2812 chips), pom zoo: 60 RGB LEDs/meter, 1 meter thooj
- Qee cov xov hlau thiab cov laug
- Ntev ntev micro-USB cable (nws yog USB powered)
- Tog ntoo lossis tsuas yog ib lub thawv rau thav duab
- Arduino IDE rau kev txhim kho software (saib cov qauv piv txwv ntawm qhov kawg ntawm kev qhia)
Qhov zoo tshaj plaws ntawm WS2812 RGB LED sawb yog qhov no, tam sim no pheej yig LED cov qauv yog tus kheej tuaj yeem hais qhia thiab raug kaw, yog li koj tsuas yog yuav tsum paub tseeb tias "cov ntaub ntawv" kab txuas los ntawm ib mus rau lwm qhov. Nws yog ib qho yooj yim tivthaiv rau tsob ntoo, vim tias tomqab txiav cov hlua LED rau hauv daim, koj tsuas yog yuav tsum tau txuas lawv nrog ib lub xaim. Lwm qhov txuas ob (+5V thiab hauv av), koj tuaj yeem txuas tau nyob txhua qhov chaw.
Txog qhov hais los ntawm tus lej, koj tuaj yeem pom tias cov chaw nyob ntawm cov pixels pib ntawm 0 (ze rau ntawm lub hauv paus ntoo) thiab mus rau 42, rau tag nrho ntawm 43 LEDs. Koj yog qhov pub dawb siv ntau dua lossis tsawg dua LEDs, tab sis tom qab ntawd koj yuav tsum hloov kho txoj cai.
Kev siv hluav taws xob rau kuv 43 teeb tsa LED yog li 360 mA max nrog cov cai tam sim no, tab sis kuv tsis tshaj tawm cov LEDs. Yog tias koj yuav qhib txhua lub LEDs, lub zog tag nrho, nws yuav muaj peev xwm siab dua 1A, yog li ceev faj!
Txoj cai tam sim no yog ib qho yooj yim, nws teeb tsa tag nrho cov LEDs rau ntsuab, thiab tom qab ntawd hloov lub pixel mus rau ib qho ntawm 6 xim palette txhua 0.5 vib nas this. Koj muaj kev ywj pheej hloov kho nws thiab sim nrog txhua tus qauv nyuaj.
Kauj Ruam 1: Txiav LED Sawb
Ua ntej, teeb tawm RGB LED kab txaij thiab txiav nws kom loj, los tsim tsob ntoo.
Kuv nyiam kom muaj 15 LEDs ua lub pob tw (ntsug), thiab tom qab ntawd 2 + 2, 4 + 4, 8 + 8 LEDs rau cov ceg ntoo, tab sis koj tuaj yeem muaj ntau dua lossis tsawg dua. Nco ntsoov tias tsuas yog txiav cov hlua ntawm cov tooj liab (txiav cov cim).
Kauj Ruam 2: Tsim Tus Qauv
Koj tsuas tuaj yeem siv daim ntawv los xij, tab sis kuv muaj qee (balsa) ntoo dag ib puag ncig thiab kuv xav tias nws zoo li me ntsis zoo dua, yog li kuv siv qhov ntawd. Kos tus qauv ntawm daim A4 los ntawm cov kauj ruam dhau los (qhov uas koj txiav cov LEDs), thiab txiav qee cov ntoo rau qhov loj me. Tom qab ntawd siv cov kua nplaum kub tso rau txhua qhov ua ke.
Kauj Ruam 3: Txuas cov kab xev LED rau ntawm tus ncej
Cov hlua LED muaj cov nplaum rau sab nraub qaum. Siv qhov ntawd los txuas cov kab xev rau tus ncej.
Tsis txhob muab daim kab xev (ntsug) thooj tsis tau, uas yuav tsuas yog cov kauj ruam kawg tom qab thaiv kab yuav luag txhua yam ntawm nws.
Nco tseg cov xub taw qhia ntawm kab txaij - uas yog cov lus qhia ntawm cov saw/cov ntaub ntawv! Koj yuav tsum muaj DI (cov ntaub ntawv hauv) ntawm sab xis, sab tes xis, thiab DO (cov ntaub ntawv tawm) ntawm sab laug ceg, sab laug tes. Peb xav kom muaj cov saw zoo thiab yooj yim ntawm txhua cov LEDs no. Nco tseg, lub zog (+5V, GND) yuav tsis raug kaw.
Kauj Ruam 4: Txuas Nws
Peb xav txuas cov ntaub ntawv, yog li ntawd txhais tau tias peb cov ntaub ntawv xov hlau yuav mus los ntawm ib ceg sab laug mus rau sab xis. Thiab ntawm chav kawm peb txuas tag nrho 3 cov xov hlau nyob hauv nruab nrab, qhov twg sab laug + txoj cai ceg sib ntsib.
Thaum qhov no ua tiav, peb yuav tsum xyuas kom muaj zog txhua qhov khoom, rau qhov ntawd, Kuv tau xaim dub nyob ntawm sab laug tes (ntsug) rau GND thiab nyob sab xis rau +5V.
Kauj Ruam 5: Txuas mus rau ESP8266 thiab Upload Sketch
Txuas tus pin los ntawm ESP8266:
+5V (VIN) - rau LED sawb +5V
GND - rau LED sawb GND
D7 rau LED kab txaij DataNote: yog tias koj siv Arduino Uno/Pro, tus pin no yuav txawv, tsuas yog nco ntsoov tias nws sib phim rau qhov chaws
Pib Arduino IDE, tsim/ntsaws qhov chaws (txuas nrog) hauv nws, tom qab ntawd xyuas kom tseeb tias Arduino IDE tau teeb tsa nrog cov chaw raug (qhov chaw nres nkoj, hom ntaus ntawv, nrawm), tom qab ntawd nias Compile + Upload.
Thaum nws ua tiav, cov hlua LED yuav ci thiab pib tso saib cov qauv. Koj yuav xav tau ntxiv Adafruit - Neopixel lub tsev qiv ntawv rau Arduino IDE (v1.8+). Koj kuj tseem tuaj yeem hloov kho txoj cai los tso saib cov qauv sib txawv, xav tias yuav sim.
Zoo siab heev Christmas!
Pom zoo:
Rov Qab Siv Qub LED Christmas Kho Kom Zoo Nkauj los ntawm Kev Hloov Kho Lawv: 7 Kauj Ruam
Rov Qab Siv Qub LED Christmas Kho Kom Zoo Nkauj los ntawm Kev Hloov Kho Lawv: Kuv yuav qhov kev dai kom zoo nkauj Christmas zoo nkauj hauv khw phaus (piv txwv li khw muag daus) thaum lub caij tom qab muag peb xyoos dhau los. Nws yog qhov tsis txaus ntseeg "NOEL" kos npe uas tau teeb pom kev los ntawm cov xov tooj tsis txaus siv cov roj teeb LEDs
LED Christmas Ntoo Kho Kom Zoo Nkauj: 3 Kauj Ruam (nrog Duab)
LED Christmas Ntoo Kho Kom Zoo Nkauj: Nyob zoo txhua tus. Raws li Christmas los txog, Kuv tau txiav txim siab los tsim kom zoo nkauj Christmas tsob ntoo dai kom zoo nkauj nrog qee qhov LEDs, qee qhov tiv thaiv, thiab 555 timer IC. Tag nrho cov khoom siv xav tau yog THT cov khoom, cov no yooj yim dua rau solder dua SMD cov khoom
WiFi Tswj Christmas Kho Kom Zoo Nkauj Lub Teeb Qhov Rai: 4 Kauj Ruam
WiFi Tswj Christmas Christmas Teeb Qhov Rooj Kho Kom Zoo Nkauj: Tswj lub teeb ci LED los ntawm koj lub xov tooj lossis PC - ntau qhov lom zem Christmas themed teeb qauv
Rooj Teeb Kho Kom Zoo Nkauj thiab Qhov Rooj Teeb Kos Npe: 8 Kauj Ruam (nrog Duab)
Lub Rooj Teeb Kho Kom Zoo Nkauj thiab Lub Teeb Lub Teeb Kos Npe: Phau ntawv qhia no yuav qhia koj yuav ua li cas rau phiaj xwm thiab tsim lub rooj kom zoo nkauj uas ci. Cov teeb no hloov xim nyob rau ib teev. Koj tseem yuav kawm paub yuav teeb tsa program li cas thiab tsim daim paib nrog lub qhov rooj kom pom kev. Koj tuaj yeem siv lub qhov rooj s
Lub Plawv Zoo Li Cov Chaw Taws Teeb Tswj Rov Qab-Teeb Phab Ntsa Kho Kom Zoo Nkauj: 8 Kauj Ruam (nrog Duab)
Lub Plawv Zoo Li Qub Cov Khoom Siv Hluav Taws Xob Back-lit Wall Decor: Hauv no DIY lub tsev kho kom zoo nkauj khoom plig qhia, peb yuav kawm paub yuav ua li cas kom lub plawv zoo li lub backlit phab ntsa dai vaj huam sib luag siv plywood board thiab ntxiv ntau yam teeb pom kev zoo tswj tau los ntawm kev tswj chaw taws teeb thiab teeb sensor (LDR) siv Arduino. Koj c