Cov txheej txheem:
- Khoom siv
- Kauj Ruam 1: Lub Tswv Yim
- Kauj ruam 2: Schematic thiab Suab Ua
- Kauj Ruam 3: LED Log
- Kauj ruam 4: Pom kev pom
- Kauj Ruam 5: Kov Khawm Tswj
- Kauj Ruam 6: Tuav Kev Tshawb Fawb thiab Servo "seev cev"
- Kauj Ruam 7: Duab 3D
- Kauj Ruam 8: Cov Khoom Siv Hluav Taws Xob
- Kauj Ruam 9: Bluetooth Tswj
- Kauj Ruam 10: Tswj App Raws Li Blynk
- Kauj Ruam 11: Sketches and Libraries
- Kauj Ruam 12: Kev txhim kho yav tom ntej
Video: Portable Party Lights: 12 Cov Kauj Ruam (nrog Duab)
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:26
Tinkercad Cov Haujlwm ยป
Koj puas tuaj yeem coj lub teeb ci rau ib tog twg thiab ua kom lom zem dua?
Qhov ntawd yog lo lus nug. Thiab cov lus teb yog YOG (tau kawg).
Cov lus qhia no yog hais txog kev ua lub cuab yeej siv tau uas mloog cov nkauj thiab tsim cov nkauj pom ntawm lub ntsej muag ntawm Neopixel LEDs.
Ib qho kev sim tau ua kom ntaus ntawv "seev cev", piv txwv li, txav mus rau qhov ntaus suab paj nruag, tab sis kev ntsuas ntsuas tau ua pov thawj los ua txoj haujlwm nyuaj dua li lub suab (tsis muaj lub hom phiaj xav tau), yog li "seev cev" yog qhov ua tau txawv me ntsis, tab sis tseem muaj.
Lub cuab yeej tau qhib Bluetooth thiab yuav teb rau cov lus txib. Kuv tsis muaj sijhawm los sau App los tswj Party Lights (ib qho hauv lossis iOS). Yog tias koj tab tom ua txoj haujlwm - thov qhia rau kuv paub !!!
Yog tias koj nyiam cov lus qhia no, thov pov npav rau nws hauv Kev Sib Tw Ua Kom Nws Glow!
Khoom siv
Txhawm rau tsim Party Lights koj yuav xav tau:
- STM32F103RCBT6 Leaflabs Leaf Maple Mini USB ARM Cortex -M3 Module rau Arduino (txuas ntawm no) - lub hlwb ntawm lub cuab yeej. Cov cuab yeej pheej yig no muaj zog heev, nws tsis meej vim li cas koj thiaj yuav rov qab mus rau Arduino.
- MSGEQ7 Band Graphic Equalizer IC DIP-8 MSGEQ7 (txuas ntawm no)
- HC-05 lossis HC-06 Bluetooth module (txuas ntawm no)
- Adafruit MAX9814 lub microphone (txuas ntawm no)
- Tus qauv servo lub cev (txuas ntawm no) yog koj xav kom koj lub cuab yeej "seev cev"
- CJMCU 61 Ntsis WS2812 5050 RGB LED Tsav Txhim Kho Pawg Thawj Coj (txuas ntawm no)
- TTP223 Touch Key Module Capacitive Settable Self-Lock/No-Lock Switch Board (txuas ntawm no)
- Ultra Compact 5000-mah Dual USB Outputs Super Slim Power Bank (txuas ntawm no)
- Resistors, capacitors, xov hlau, kua nplaum, ntsia hlau, cov laug cam prototyping, thiab lwm yam.
Kauj Ruam 1: Lub Tswv Yim
Lub tswv yim yog kom muaj lub cuab yeej nqa tau uas tuaj yeem tso ze rau lub hauv paus suab paj nruag, thiab qhov ntawd yuav tsim kom pom cov nkauj zoo nkauj. Koj yuav tsum muaj peev xwm tswj hwm tus cwj pwm ntaus ntawv ntawm cov nyees khawm (kov) thiab Bluetooth.
Tam sim no, Party Lights muaj 7 qhov pom kev siv (qhia rau kuv paub yog tias koj muaj tswv yim ntxiv!):
- Concentric cov yeeb yuj voj voog
- Maltese ntoo khaub lig
- Pulsating teeb
- Qhov cub (kuv tus kheej nyiam)
- Teeb teeb
- Ntoo ntoo
- Sab ib sab
Los ntawm lub neej ntawd, lub cuab yeej yuav hloov pauv los ntawm kev pom txhua feeb. Txawm li cas los xij, tus neeg siv tuaj yeem xaiv los lo nrog ib qho kev pom thiab/lossis kev mus los ntawm lawv tus kheej.
Kev pom qhov muag uas tig lawv cov xim palette tseem tuaj yeem "khov" yog tias tus neeg siv nyiam cov xim tshwj xeeb.
Thiab raws li ob peb qhov kev tswj hwm ntau dua, tus neeg siv tuaj yeem hloov pauv lub suab nrov ntawm lub microphone thiab pab/lov tes taw servo motor "seev cev" hom.
Kauj ruam 2: Schematic thiab Suab Ua
Cov ntaub ntawv tsis txaus ntseeg tau suav nrog hauv pob ntawm Github hauv "cov ntaub ntawv" subfolder.
Yeej, MSEQ7 nti ua lub suab ua haujlwm, faib lub suab tawm rau hauv 7 pawg: 63Hz, 160Hz, 400Hz, 1kHz, 2.5kHz, 6.25kHz, thiab 16kHz
Lub microcontroller siv cov 7 pab pawg los tsim ntau yam kev pom, qhov tseem ceeb ua piv txwv cov qhab nia sib luag rau hauv LED teeb pom kev zoo thiab ua ke xim.
Lub suab los yog lub microphone nrog 3 qib kev tswj kom nce. Koj tuaj yeem hloov pauv los ntawm kev teeb tsa siv ib qho ntawm cov nyees khawm nyob ntawm qhov deb/nrov lub suab qhov twg.
Lub microcontroller kuj tseem sim ua "ntaus" nrhiav pom ntawm 63Hz "bass" band. Kuv tseem tab tom ua haujlwm ntawm txoj hauv kev uas ntseeg tau txhawm rau txheeb xyuas thiab tswj tuav txoj kev sib tw.
Kev siv khawm "kov" yog qhov kev sim. Kuv xav tias lawv ua haujlwm tau zoo heev, txawm li cas los xij, tsis muaj xov xwm tawm tswv yim yog tsis meej pem me ntsis.
Kauj Ruam 3: LED Log
Lub hauv paus ntawm kev pom kev yog 61 LED log.
Thov nco ntsoov tias ib feem los ua ib lub nplhaib uas koj yuav tau muab tso ua ke. Kuv siv qhov xav tias tooj liab hlau rau cov kab hluav taws xob (uas tseem tuav cov hlua ua ke zoo), thiab cov xov hlau nyias nyias.
Cov LEDs suav nrog 0 txog 60 pib los ntawm cov hauv qab sab hauv LED thiab mus raws txoj kab rov tav. Qhov nruab nrab LED yog tus lej 60.
Txhua qhov kev pom pom tso rau ntawm ob kab ntawv cov ntaub ntawv, uas qhia txhua qhov LED rau hauv ib txoj haujlwm tshwj xeeb rau ntu kev pom pom.
Piv txwv li, rau cov voj voos kheej kheej, muaj 5 ntu:
- Lub voj voog sab nrauv, LEDs 0 - 23, 24 LEDs ntev
- Qhov thib ob sab nrauv, LEDs 24 - 39, 16 LEDs ntev
- Lub voj voog thib peb (nruab nrab), LEDs 40 - 51, 12 LEDs ntev
- Qhov thib ob sab hauv, LEDs 52 - 59, 8 LEDs ntev
- Sab hauv LED, LED 60, 1 LED ntev
Cov duab qhia pom pom 5 tawm ntawm 7 lub suab tso tawm thiab teeb tsa LEDs zuj zus raws li lawv txoj haujlwm hauv cov pab pawg ncig sib faib rau qib suab hauv pab pawg.
Lwm qhov kev pom pom siv cov ntaub ntawv sib txawv thiab cov qauv, tab sis lub tswv yim ib txwm muaj kom pom kev tsav los ntawm cov ntaub ntawv arrays, tsis ntau los ntawm cov cai. Txoj hauv kev pom kev no tuaj yeem hloov kho rau cov duab sib txawv (ntau dua lossis tsawg dua LEDs, ntau EQ bands) yam tsis hloov pauv txoj cai, tsuas yog tus nqi hauv cov ntaub ntawv.
Piv txwv li, qhov no yog li cas cov qauv ntaub ntawv rau kev pom pom 1 zoo li hauv daim duab:
// Visualization 1 & 3 - tag nrho 5 Circlesconst byte TOTAL_LAYERS1 = 5; const byte LAYERS1 [TOTAL_LAYERS1] [25] = {// 00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 {24, 0, 1, 2, 3, 4 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23}, {16, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39}, {12, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51}, {8, 52, 53, 54, 55, 56, 57, 58, 59}, {1, 60}};
Kauj ruam 4: Pom kev pom
Txog tam sim no muaj 7 qhov pom kev thiab pib ua yeeb yaj kiab:
Pib-animation
Thaum lub cuab yeej tau qhib, qhov ua piv txwv ntawm lub foob pob hluav taws tau tshwm sim. Qhov no tau xav tias yog LED thiab Servo ntu sib tw, tab sis tom qab hloov pauv mus rau qhov ua yeeb yaj kiab ntawm qhov kev sim ntawd
Concentric cov yeeb yuj voj voog
Lub teeb mus ib ncig ntawm cov zaub hauv cov vojvoog sib luag sib npaug rau qhov dav ntawm qhov sib npaug band. Hloov pauv ntawm lub moos- thiab txee-moos-ntse thiab maj mam tig cov xim hla 256 lub log xim
Maltese ntoo khaub lig
Ib pawg yog qhov chaw nruab nrab LED. Lwm pab pawg yog kab ntsug thiab kab rov tav ntawm LEDs, thiab ntu seem uas sawv cev rau txhua pawg EQ. Txhua ntu tau hloov xim hauv 128 offset kom nyob sib xws.
Pulsating teeb
Txhua lub voj voos teeb txhua LEDs hauv kev sib koom ua ke rau kev ua haujlwm tshwj xeeb, thaum maj mam tig cov xim nrog qhov me me. Cov qhab EQ tau hloov pauv zuj zus los ntawm ib lub voj voog mus rau lwm qhov tsim tawm sab nrauv.
Qhov cub
Cov pab pawg yog ib nrab-lub voj voos teeb los ntawm hauv qab mus rau sab saum toj pib nrog ci liab thiab ntxiv daj ntawm txoj kev nce simulating qhov hluav taws kub hauv qhov cub. Qee lub sij hawm qaim dawb "txim taws" ua rau tawg tuaj. Tsis muaj kev hloov xim
Teeb teeb
Txhua lub voj voos kheej kheej yog cais EQ band. LEDs ua ntej yog cov kab ntawm kab ntsug hauv qab qhov chaw nruab nrab LED. Thaum LED teeb pom kev sib npaug rau cov qhab nia, nws pib "khiav" nyob ib ncig ntawm lub voj voos sib luag maj mam txo qis. Ob lub moos- thiab cov khoom siv rov qab-clockwise tig tau txais kev txhawb nqa, hloov pauv ib yam.
Ntoo ntoo
Cov ntu tau teeb nyob rau hauv txoj kab ncaj ncaj los ntawm hauv qab LED nce thiab tom qab ntawd ib sab hauv lub ntsej muag ib nrab ib puag ncig ua piv txwv ntoo xibtes. Kev sib hloov xim
Sab ib sab
Nov yog qhov hloov pauv yav dhau los Maltese Hla nrog tsuas yog 2 ntu kab pheeb ces kaum siv. Xav tias zoo ib yam li lub cim rau lub suab yoj.
Kauj Ruam 5: Kov Khawm Tswj
Muaj 4 lub khawm kov-rhiab:
- Mus los ntawm kev pom kev thiab khaws qhov tam sim no mus kom txog thaum lwm tus raug xaiv (los ntawm kev pom pom lub voj voog txhua 30 vib nas this)
- "Khov" / "tsis khov" cov xim tam sim no - yog tias koj nyiam cov xim tshwj xeeb koj tuaj yeem khov nws - cov xim sib hloov yog xiam oob khab thiab pom kev yuav txuas ntxiv nrog tsuas yog cov xim xim
- Kho lub microphone rhiab heev
- Qhib / tawm hom "seev cev"
Hauv kev seev cev, lub cuab yeej yuav sim ntsuas "ntaus" ntawm cov nkauj tam sim no thiab tig nws lub taub hau raws li kev ntaus. Txog tam sim no "seev cev" yog qhov txawv txawv dua li zoo nkauj, ua siab ncaj.
Kauj Ruam 6: Tuav Kev Tshawb Fawb thiab Servo "seev cev"
Cov cuab yeej siv tas li txhawm rau txhawm rau txheeb xyuas "ntaus" ntawm lub suab tam sim no raws li qhov nrug nruab nrab ntawm qhov sib txuas ntawm qhov siab tshaj ntawm 63Hz band. Thaum kuaj pom (thiab tsuas yog tias hom kev seev cev yog ON), lub cuab yeej yuav qhib nws lub cav servo kom tig tig sab laug lossis sab xis raws li kev ntaus.
Txhua lub tswv yim ci ntsa iab ntawm yuav ua li cas kom ntseeg tau zoo dua no tau txais tos!
'Music_Test_LED' kos duab tawm 7 EQ bands hauv txoj hauv kev uas tsim nyog rau kev npaj siv Arduino IDE.
Kauj Ruam 7: Duab 3D
Tag nrho Cov Teeb Rooj Sib Tham tau tsim los ntawm kos siv Autodesk TinkerCAD.
Tus thawj tsim yog nyob ntawm no. Cov ntawv "cov ntaub ntawv/3D" ntawm github.com muaj cov qauv STL.
Qhov kev tsim no qhia txog yuav ua li cas lub cuab yeej zoo li ua ke.
Tag nrho cov khoom siv tau luam tawm thiab tom qab ntawd sib sau ua ke/ua ke ua ke.
Lub "dome" yog tus tuav lub microcontroller, Bluetooth board, thiab lub microphone. Lub microcontroller tau muab tso rau ntawm 40mm x 60 mm board thiab tau txais kev txhawb nqa los ntawm cov ntsia hlau.
Qhov kev pabcuam yog nyob hauv "ceg" ntawm lub dome, thaum cov nyees khawm nyob hauv lub hauv paus.
Cov roj teeb tau muab luam tawm tshwj xeeb rau hom roj teeb uas tau hais hauv ntu Cov Khoom Siv. Yog tias koj xaiv siv lub roj teeb sib txawv, chav yuav tsum tau rov tsim dua kom haum.
Kauj Ruam 8: Cov Khoom Siv Hluav Taws Xob
Ultra-Compact 5000-mah Dual USB Outputs Super Slim Power Bank zoo li tau muab lub zog txaus rau cov sijhawm ua haujlwm.
Cov roj teeb tau tsim nyob rau hauv ib txoj hauv kev uas nws tshem tawm ntawm cov khoom siv tas li thiab tuaj yeem hloov nrog qhov tsim los rau lwm hom roj teeb.
Lub USB ntsaws tau muab tso rau hauv thiab kub zoo rau hauv qhov chaw kom txuas lub roj teeb thaum nws swb hauv.
Kauj Ruam 9: Bluetooth Tswj
Ib qho HC-05 module tau ntxiv los muab txoj hauv kev los tswj cov cuab yeej siv wireless.
Thaum nyob, lub cuab yeej tsim kev sib txuas Bluetooth hu ua "LEDDANCE", uas koj tuaj yeem txuas koj lub xov tooj nrog.
Qhov zoo tshaj, yuav tsum muaj App uas tso cai tswj hwm PartyLights (xaiv cov xim palette, simulating khawm nias, thiab lwm yam). Txawm li cas los xij, kuv tseem tsis tau sau ib qho.
Yog tias koj xav pab sau Android lossis iOS App rau Party Lights, thov qhia rau kuv paub!
Txhawm rau tswj lub cuab yeej, tam sim no koj tuaj yeem siv Bluetooth lub davhlau ya nyob twg app, thiab xa cov lus txib hauv qab no:
- LEDDBUTT - qhov twg yog '1', '2', '3', lossis '4' simulates nias ib lub pob. Piv txwv: LEDDBUTT1
- LEDDCOLRc - qhov c yog tus lej ntawm 0 txog 255 - txoj haujlwm ntawm cov xim uas xav tau ntawm lub log xim. Cov cuab yeej yuav hloov mus rau xim tshwj xeeb LED.
-
LEDDSTAT - xa rov qab 3 tus lej tus lej suav nrog '0's thiab' 1's nkaus xwb:
- thawj txoj haujlwm: '0' - xim tsis tig, '1' - xim tig
- txoj haujlwm thib ob: '0' - hom kev seev cev raug kaw, '1' - hom kev seev cev tau qhib
- txoj haujlwm thib peb: '0' - lub microphone zoo li qub, '1' - lub microphone muaj qhov nce siab
Kauj Ruam 10: Tswj App Raws Li Blynk
Blynk (blynk.io) yog kho vajtse-agnostic IoT platform. Kuv siv Blynk hauv kuv li IoT Automatic Plant Irrigation System qhia tau thiab txaus siab rau qhov yooj yim thiab muaj zog ntawm lub platform.
Blynk txhawb kev txuas mus rau cov cuab yeej ntug ntawm Bluetooth - raws nraim qhov peb xav tau rau PartyLights.
Yog tias koj tseem tsis tau muaj, thov rub tawm Blynk App, sau npe thiab rov tsim dua Blynk PartyLights App siv cov ntawv tshuaj ntsuam txuas nrog rau theem no. Thov nco ntsoov tias txoj haujlwm pin tus lej zoo ib yam li ntawm lub vijtsam, txwv tsis pub, cov nyees khawm ntawm lub app yuav tsis ua haujlwm raws li xav tau.
Cov ntaub ntawv "blynk_settings.h" muaj kuv tus kheej Blynk UID. Thaum koj tsim koj qhov project, nws yuav muab ib qho tshiab rau koj siv.
Rub lub PartyLightsBlynk.ino kos duab, tua lub App. Pair nrog Bluetooth ntaus ntawv thiab txaus siab rau tog.
Kauj Ruam 11: Sketches and Libraries
Daim duab tseem ceeb thiab cov ntaub ntawv txhawb nqa yog nyob ntawm Github.com ntawm no.
Cov tsev qiv ntawv hauv qab no tau siv nyob hauv Party Teeb duab kos:
- TaskScheduler - koom tes ua haujlwm ntau yam - ntawm no (tsim los ntawm kuv)
- AverageFilter - tus qauv nruab nrab lim - ntawm no (tsim los ntawm kuv)
- Servo - Servo tswj - yog tus qauv Arduino tsev qiv ntawv
- WS2812B -NEOPixel tswj - los ua ib feem ntawm pob STM32
Nplooj ntawv Wiki no piav qhia yuav siv STM32 cov laug cam nrog Arduino IDE li cas.
Kauj Ruam 12: Kev txhim kho yav tom ntej
Ob peb yam tuaj yeem txhim kho hauv qhov tsim qauv no, uas koj yuav xav txog yog tias koj pib ua txoj haujlwm no:
- Siv ESP32 hloov chaw ntawm Maple Mini board. ESP32 muaj 2 CPUs, Bluetooth thiab WiFi sib tshooj, thiab tuaj yeem khiav ntawm 60MHz, 120MHz thiab txawm tias 240MHz.
- Kev tsim me dua - cov cuab yeej siv tau yog qhov loj. Yuav ua rau muaj kev cog lus ntau dua (tshwj xeeb tshaj yog tias koj tso lub tswv yim seev cev thiab cuam tshuam nrog servo)
- Kev ntsuas qhov ntsuas tuaj yeem txhim kho tsis kawg. Dab tsi los ib txwm rau peb tib neeg, zoo li yog txoj haujlwm nyuaj rau lub khoos phis tawj
- Ntau qhov pom kev ntau dua tuaj yeem tsim thiab siv tau.
- Thiab, tau kawg, App tuaj yeem sau los tswj lub cuab yeej wirelessly nrog UI txias.
Pom zoo:
Cov Duab Duab Duab thiab Cov Duab 1: 4 Cov Kauj Ruam (nrog Duab)
Cov Duab Duab Cubes thiab Cov Duab 1: Thaum sim nrog qee cov ntoo ntoo thiab cov duab los qhia, kuv pom ob peb txoj hauv kev los ua cov voos thiab lwm yam duab los ntawm cov khoom siv yooj yim. Los ntawm kev muab cov no los ua Cov Ntawv Qhia, Kuv vam tias yuav txhawb nqa kev ua si thiab kev kawm. Kev hloov pauv ntawm qhov kev qhia no
Cov Duab Duab Duab Duab, WiFi Txuas - Raspberry Pi: 4 Cov Kauj Ruam (nrog Duab)
Cov Duab Duab Duab Duab, WiFi Txuas - Raspberry Pi: Nov yog txoj hauv kev yooj yim heev thiab tus nqi qis mus rau cov duab thav duab digital - nrog qhov zoo ntawm kev ntxiv /tshem cov duab hla WiFi ntawm 'nyem thiab luag' siv (pub dawb) xa cov ntaub ntawv . Nws tuaj yeem siv tau los ntawm qhov me me ยฃ 4.50 Pi Zero. Koj tseem tuaj yeem hloov pauv
Rov Qab Siv Cov Khoom Siv Laus qub los Tsim Cov Pheej Yig Portable System: 3 Cov Kauj Ruam (nrog Duab)
Rov Qab Siv Cov Khoom Siv Laus qub los tsim Cov Txheej Txheem Nqis Pheej Yig: Tsis ntev los no kuv lub Laptop qub tau tuag thiab kuv yuav tsum yuav ib qho tshiab, (RIP! 5520 koj yuav tsis nco). Lub khoos phis tawj niam niam lub rooj tuag tau tuag thiab qhov kev puas tsuaj tuaj yeem kho tau Txog thaum tsis ntev los no kuv coj Raspberry ncuav qab zib thiab pib tinkering nrog IOT sutff tab sis xav tau kev mob siab rau
Rov Qab Siv Cov Duab Duab Nrog Virtual Asistent: 7 Cov Kauj Ruam (nrog Duab)
Rov Qab Siv Cov Duab Duab Nrog Virtual Asistent: Nyob zoo txhua tus! Cov lus qhia no tau yug los ntawm lub laptop faib ua ib nrab, yuav los ntawm ib tus phooj ywg. Thawj qhov kev sim ntawm txoj haujlwm no yog kuv Lego Digital Photo Frame, txawm li cas los xij, yog ib tus neeg mob siab rau Siri thiab Google Tam sim no, Kuv txiav txim siab coj nws mus rau qhov tshiab
Portable Dej Resistant LED Picnic Pam Nrog Cov Chaw Nyuaj Siab Ua Haujlwm Nto!: 10 Cov Kauj Ruam (nrog Duab)
Portable Water Resistant LED Picnic Blanket With Hard Center Serving Surface !: Ntawm no hauv Los Angeles muaj ntau qhov chaw mus noj mov thaum yav tsaus ntuj thiab saib yeeb yaj kiab sab nraum zoov, zoo li Cinespia hauv Hollywood Forever Cemetery. Qhov no zoo li txaus ntshai, tab sis thaum koj muaj koj tus kheej daim yas yas pam pam pam kom nthuav tawm rau ntawm cov nyom, txhawm rau