Cov txheej txheem:
- Kauj Ruam 1: Yam Koj Yuav Tsum Tau
- Kauj Ruam 2: Cov Khoom Siv Hluav Taws Xob
- Kauj Ruam 3: Teeb Kho Raspberry Pi
Video: Pumpkin Pi Digital Decoration Controller: 5 Kauj Ruam (nrog Duab)
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:29
Nyob zoo cov neeg, cia kuv qhia koj rau Pumpkin Pi. Cias muab nws yog tus tswj hwm I/O rau Raspberry Pi nrog kaum ob lub programmable outputs, tab sis nrog me ntsis hocus-pocus (lossis Python code rau koj thiab kuv) nws dhau los ua cov khoom siv kho kom zoo nkauj uas muaj ob qho video tso tawm nrog suab, thiab teeb pom kev zoo FX synced rau video.
Tom Qab Los Xus Halloween Kuv txiav txim siab los tsim Witching themed window display, tsis ntev los no tau pom AtmosFX's Digital Decorations Kuv xav tau kev tshoov siab kom siv tau zoo ntawm lawv thiab koom nrog lawv rau hauv kuv cov zaub.
Kuv xav tau txoj hauv kev rov ua dua ob daim vis dis aus playlists hloov ntawm ob qhov sib txawv (TV thiab projector) yam tsis muaj cov vis dis aus yuam kev sib tshooj. Kuv kuj xav koom ua ke teeb pom kev zoo FX ntxiv rau huab cua.
Xav paub ntau ntxiv txog Tus Tswj Raws li nws tau tshwm sim los ntawm qhov haujlwm Xus kuv xav tias lub npe Pumpkin Pi tsim nyog heev. Nws yog npaj los ua cov hauv qab no:
- Tswj txog 12x tus kheej LEDs (lossis 4x RGB strips) ntawm 12x cov phiaj xwm tsim tawm
- Ua haujlwm ntawm 12v ntawm nws tus kheej lub zog hluav taws xob sab nraud
- 3x quad NPN transistor arrays los txhawb 1 Amp tso tawm tam sim no ib qhov txuas
- Suav nrog qhov kev xaiv ntawm PIR / cov lus tsa suab ua rau rov ua haujlwm thiab ua
- Cov vis dis aus thiab tso suab siv lub peev xwm yees duab ntawm Raspberry Pi
- Ob daim vis dis aus tuaj yeem rov ua si ib txhij lossis hloov ua tsaug rau ob qho Pis tau txuas ntawm lawv GPIOs txhawm rau ua qhov kev ua haujlwm tau zoo thiab tiv thaiv cov vis dis aus tsis xav tau sib tshooj
- Sync teeb pom kev zoo FX rau kev ua yeeb yaj kiab video
- Built-in LEDs los qhia qhov xwm txheej ntawm tus kheej
Lwm Txoj Kev Siv Koj tseem tuaj yeem siv Pumpkin Pi ua lub rooj sib cais nrog ib tus Raspberry Pi nkaus xwb thiab tseem muaj 12x programmable outputs los tswj LEDs, motors, relays thiab lwm yam.
Nco tseg: Xav pom tias kuv siv Pumpkin Pi li cas hauv kuv qhov kev lom zem Halloween? Txheeb tawm kuv Dab Ntxwg Nyoog Teev Xus Qhia Qhia.
Kauj Ruam 1: Yam Koj Yuav Tsum Tau
Txhawm rau rov tsim Pumpkin Pi koj yuav xav tau cov cuab yeej thiab cov khoom siv hauv qab no:
Cov cuab yeej
- Soldering Hlau
- Ntau lub 'meter'
- Hlau txiav
- Ntsia Hlau (Kuv siv lub tiaj tiaj me me nrog kuv lub dav hlau thaiv)
- Laum thiab laum cov khoom (Kuv siv 0.7mm thiab 1.0mm carbide cov khoom)
- PCB Etching Khoom
Cheebtsam
- 1x Copper PCB Board (102mm X 70mm kwv yees.)
- 14 x 1 kΩ Resistors
- 2 x 10kΩ Resistors
- 1 x 4k7Ω Resistor
- 1x Capacitor (Tsis teb los tau)
- 1x Liab 5mm LED thiab qhov tsim nyog tam sim no txwv kev tiv thaiv
- 12x Daj 5mm LEDs nrog kev sib txuas ua ke rau 12v mov
- 3x ULN2074B Quad NPN Darlington Pair Transistor Arrays
- 3x 16-Way IC Qhov (Socket)
- 1 x DC Jack
- 1x2-Txoj Kev Header
- 2x 40-Pin 2x20 Txiv neej Header
- 7x 3-Txoj Kev 5mm Ntsug PCB Mount Ntsia Hlau Terminal Thaiv
- 1x PIR Sensor (Tsis teb los tau)
Raspberry Pi
Koj tseem yuav xav tau Raspberry Pi (lossis ob) nrog txhua yam uas tsim nyog los siv Pi. Qhov no suav nrog Pi lub zog xa khoom, MicroSD daim npav thiab Raspbian software. Txog kev ua yeeb yaj kiab zoo tshaj plaws Kuv xav pom Raspberry Pi 3.
Txog kev ua yeeb yaj kiab peb yuav siv OMXPlayer nrog OMXPlayer-Wrapper (tab sis ntau ntxiv tom qab no!).
Nco tseg: Phau ntawv qhia no xav tias koj muaj qee qhov kev paub dhau los lossis kev paub ua haujlwm ntawm Electronics, Kev Muag Khoom, PCB tsim thiab Raspberry Pi. Yog tias koj tab tom sim ib qho ntawm cov txuj ci no thawj zaug kuv xav kom koj ua tibzoo saib qee yam ntawm cov peev txheej hauv qab no:
- Chav Kawm Hluav Taws Xob Suav nrog Phau Ntawv Pib Pib thiab npog yam xws li cov khoom siv thiab cov khoom siv yooj yim.
- PCB Ua Qhia los ntawm ASCAS. Npog cov txheej txheem tsim cov tshuab luam ntawv siv ntawm no.
- Yog tias koj xav mus ntxiv nrog Circuit Boards, mus saib hauv Circuit Board Design Class.
- Raspberry Pi Chav Kawm. Nrhiav paub txog Raspberry Pi, kawm paub yuav teeb tsa thiab siv nws li cas.
Kauj Ruam 2: Cov Khoom Siv Hluav Taws Xob
Tsim Circuit Court
Thawj qhov koj yuav tsum tau ua yog tsim koj li Circuit Court. Txoj hauv kev yooj yim tshaj plaws los tsim nws yog los tsim PCB siv cov txheej txheem hloov pauv toner nrog cov ntawv luam tawm txuas hauv PDFs. Yog tias koj tsis tau sim qhov no ua ntej nws yooj yim dua qhov koj xav, thiab koj tsuas xav tau ob peb yam khoom los pib. Kuv ib txwm pom zoo DIY Customized Circuit Board (PCB Making) Qhia los ntawm ASCAS.
Nco tseg: Kuv kuj tseem suav nrog PCB tsim cov ntawv uas kuv tsim siv DesignSpark.
Koj yuav xav tau cov hlau txuas thiab qee cov txuj ci yooj yim kom sib sau ua ke txhua yam hauv PCB, muaj ntau Cov Lus Qhia ntawm kev siv lub tshuab tooj liab yog tias koj tshiab rau nws, muaj Cov Ntawv Qhia Zoo Hluav Taws Xob ib yam nkaus!
Yog tias PCB ua cov txheej txheem tsis yog rau koj ces koj tuaj yeem rov tsim nws ntawm kab txaij (vero) pawg thawj coj lossis ntawm lub khob cij (Kuv tau ua daim phiaj rau kuv daim ntawv pov thawj, raws li qhia hauv daim duab saum toj no). Hauv kuv tsab ntawv kuv siv tus kheej NPN darlington khub transistors raws li tawm tsam rau transistor arrays ntawm IC (kev sib koom ua ke).
Nws Ua Haujlwm Li Cas
Nws yog lub hauv paus kev sib cais rau Pi uas txuas kaum ob ntawm Pi's GPIO pins rau NPN darlington khub transistors (hauv daim ntawv ntawm peb lub transistor arrays). Thaum cov txiaj ntsig Pi cuam tshuam mus rau siab, nws hloov lub transistor kom ua tiav Circuit Court.
Kuj tseem muaj ob qhov GPIO pins ntxiv uas 'txuas' ob Pis ua ke los ntawm kev rub tawm tus tiv thaiv uas ua raws li qhov tshwm sim (ntau ntxiv ntawm qhov no hauv 'Programming the Pi' kauj ruam tom qab).
Nws Ua Li Cas
Pumpkin Pi tau siv los ntawm nws tus kheej lub zog 12v sab nraud. Nrog kev siv cov transistors kuv tau xaiv nws muaj peev xwm nce txog 1.75 Amp tam sim no rau ib qho zis (lossis 1 Amp hauv qhov no vim yog kuv xaiv cov ntsia hlau txuas). Lub Pis tau siv los ntawm lawv tus kheej Pi cov khoom siv hluav taws xob, Pumpkin Pi tso qhov xav tau tsawg heev ntawm Pi lub peev xwm muaj peev xwm vim nws tsuas yog siv los hloov transistors. Lub Circuit Court suav nrog qhov kev xaiv ntawm lub tshuab ua kom du, tab sis nws tsis yog qhov tseem ceeb. Kuv siv 2200uF ntsuas ntawm 16v (uas yog overkill, tab sis kuv muaj lawv rau tes).
Qhov taw qhia LEDs thiab Resistors
Muaj kaum ob lub teeb liab tso tawm LEDs thiab ib qho xwm txheej liab liab LED. Nco ntsoov siv qhov tam sim no txwv LED nrog koj cov xwm txheej liab LED, kuv muaj lub zog txuas ntawm 3.2v thiab tam sim no mus rau 20mA, yog li kuv tau xaiv 470Ω resistor (raws li 12v input tam sim no). Yog tias koj tsis paub meej tias yuav xaiv qhov ntsuas qhov raug rau koj li LED li cas, txheeb xyuas qhov kev ua lej no.
Tej zaum koj yuav tau pom tias tsis muaj tus tiv thaiv ntawm Circuit Court rau txhua ntawm kaum ob qhov taw qhia daj daj LEDs. Raws li kuv xav tseg qhov chaw ntawm PCB Kuv tau xaiv qhov tsim los siv LEDs nrog kev tiv thaiv kev tiv thaiv rau 12v khoom.
Tsab ntawv tsa suab Tsab ntawv tsa suab (PIR Sensor) thiab Override
Lub Circuit Court suav nrog qhov kev xaiv ntawm cov lus tsa suab. Nws siv lub zog rub tawm, yog li thaum twg lub tswb tus pin (sau tias AL ntawm PCB) mus qis nws ua rau muaj kev nqis tes ua. Qhov no tuaj yeem siv tau yog tias koj xav kom koj lub suab paj nruag kho kom zoo nkauj kom rov ua haujlwm.
Lub Circuit Court tseem suav nrog qhov ua kom hla dhau. Thaum qhov kev hla dhau yog nyob hauv lub xeev kaw nws txuas cov tswv yim rau hauv av, tso cai rau koj los ua qhov kev nqis tes ua. Siv ob-tus lej hla lub taub hau nrog hloov lossis 'jumper'.
Kauj Ruam 3: Teeb Kho Raspberry Pi
Txhim kho Raspbian
Txhawm rau pib teeb tsa Raspberry Pi koj yuav tsum npaj koj daim npav MicroSD nrog duab Raspbian. Rub tawm cov duab tshiab ntawm no (Raspbian Stretch yog qhov hloov tshiab kawg thaum lub sijhawm sau ntawv).
Nrog koj daim npav MicroSD npaj txhij, ntxig nws rau hauv Pi thiab txhawb zog. Tej zaum koj yuav xav tau TV, keyboard thiab nas txuas ntawm qhov no. Los ntawm lub neej ntawd Pi yuav tsum khau raj rau hauv GUI desktop OS, Kuv pom zoo kom koj teeb tsa hnub thiab sijhawm raug rau ntawm koj Pi thiab tej zaum tau txuas nrog koj li WiFi.
Txog ntawm qhov no kuv ib txwm ua kom ntseeg tau tias SSH kev sib txuas tau qhib yog li kuv tuaj yeem nkag mus rau Pi lub dav hlau hla lub network ntawm PuTTy, tom qab ntawd kuv teeb tsa Pi rau khau raj rau CLI (kab lus hais kom ua kab) los ntawm lub neej ntawd hloov ntawm GUI desktop, tab sis qhov no yog nyob ntawm koj
Nco tseg: Phau ntawv qhia no xav tias koj twb tau paub txog Raspberry Pi, yog tias tsis yog koj tuaj yeem ua raws li txoj cai Raspberry Pi qhia rau txhim kho cov duab ua haujlwm hauv koj ib puag ncig ntawm no: Windows, MacOS, Linux.
Tswv yim: Yog tias koj tshiab tshiab rau Raspberry Pi Kuv xav kom koj ua tibzoo saib ntawm Chav Qhia Ntawv no.
Thaum koj tus Pi nce thiab khiav nrog Raspbian thiab kev teeb tsa yooj yim ua tiav, koj npaj tau kom nws ua haujlwm li Digital Decoration player uas txhawb suab thiab Video rov ua dua. Nco ntsoov tias yog tias koj siv ob lub Raspberry Pi's rau kev ua haujlwm ob zaug, koj yuav tsum tau rov ua txhua yam ntawm cov theem no ntawm Pi thib ob.
OMXPlayer-Wrapper rau Python
Txhawm rau ua peb cov yeeb yaj kiab Kho Kom Zoo Nkauj Digital peb yuav siv OMXPlayer. Qhov no txhawb nqa cov vis dis aus siab (suav nrog HD) hauv ntau hom yeeb yaj kiab. Txawm hais tias OMXPlayer suav nrog Raspbian 'tawm-ntawm-lub-lub thawv', kom nws ua si zoo nrog kev cai Python cov ntawv peb yuav tsim koj yuav xav tau rau nruab OMXPlayer-Wrapper.
Ua ntej txhim kho lub wrapper Kuv pom zoo hloov kho cov txheej txheem pob. Khiav cov lus txib hauv qab no los ntawm CLI lub davhlau ya nyob twg (Pi yuav tsum txuas nrog internet rau qhov no kom ua haujlwm):
Hloov kho kab ke cov npe khoom:
sudo apt-tau hloov tshiab
Txhim kho tag nrho koj cov pob khoom nruab rau qhov hloov tshiab kawg:
sudo apt-tau nruab dist-upgrade
Ua kom huv qhov chaw siv los rub tawm pob tshiab:
sudo apt-tau ntxuav
Tom ntej no koj yuav xav rub OMXPlayer-Wrapper nws tus kheej. Txhawm rau ua qhov no ua raws cov lus txib hauv qab no, ntxiv los ntawm CLI lub davhlau ya nyob twg nrog Pi txuas rau hauv is taws nem:
Nruab OMXPlayer-Wrapper:
sudo python3 -m pip nruab omxplayer -wrapper
Yog xav paub ntxiv ntawm omxplayer-wrapper txheeb xyuas cov ntawv no.
Tswv yim: Yog tias koj ntsib DBUS qhov yuam kev txuas thaum sim ua yeeb yaj kiab siv OMXPlayer-Wrapper, sim teeb tsa sej-3-dbus nrog cov lus txib hauv qab no:
sudo apt-tau nruab python3-dbus
Lwm Qhov Chaw thiab Tweaks
Default Audio Output
Raspberry Pi txhawb nqa kev ua suab ntawm HDMI lossis 3.5mm nkaus. Txawm li cas los xij yog tias Pi pom tias cov cuab yeej txuas HDMI txhawb lub suab nws yuav tsis txuas rau lub cuab yeej HDMI. Yog tias zoo li kuv koj muaj lub peev xwm HDMI ntaus ntawv tab sis koj xav kom koj lub suab tso tawm rau lub 3.5mm nkaus xwb, koj tuaj yeem yuam kom nws ua li ntawd los ntawm kev ntxiv kab hauv qab no rau hauv config.txt cov ntaub ntawv ntawm Pi:
hdmi_ignore_edid_audio = 1
Teeb Console Output rau Blank
Yog tias koj tsis xav kom Pi cov vis dis aus tso tawm kom pom lub vijtsam console tom qab khau raj koj tuaj yeem teeb tsa lub console kom khoob los ntawm kev ntxiv cov hauv qab no mus rau qhov kawg ntawm /boot/cmdline.txt cov ntaub ntawv ntawm Pi. Nco tseg tias yog lub kernel hais kom ua qhov ntsuas thiab yuav tsum yog ntawm ib kab ntawm kab ntawv:
consoleblank = 0
Pom zoo:
Ib IoT Halloween Pumpkin - Tswj LEDs Nrog Arduino MKR1000 thiab Blynk App ???: 4 Cov Kauj Ruam (nrog Duab)
Ib IoT Halloween Pumpkin | Tswj LEDs Nrog Arduino MKR1000 thiab Blynk App ???: Nyob Zoo Txhua Tus, Ob peb lub lis piam dhau los yog Xus thiab ua raws li kev coj noj coj ua kuv txiav tawm lub taub dag zoo rau kuv lub sam thiaj. Tab sis muaj kuv lub taub dag sab nraum zoov, Kuv pom tau tias nws yog qhov txaus siab heev uas yuav tsum tau tawm mus txhua hmo kom taws tswm ciab. Thiab kuv
Xus Pumpkin Nrog Tsiv Tsiaj Animatronic Qhov Muag - Lub taub dag no tuaj yeem dov nws lub qhov muag!: 10 Kauj Ruam (nrog Duab)
Xus Pumpkin Nrog Tsiv Tsiaj Animatronic Qhov Muag | Lub Taub Hau No Tuaj Yob Nws Lub Qhov Muag!: Hauv Phau Ntawv Qhia no, koj yuav kawm paub yuav ua li cas taub dag Xus uas ua rau txhua tus ntshai thaum nws lub qhov muag txav mus. Kho lub ntsuas hluav taws xob ultrasonic ntsuas qhov nrug mus rau tus nqi raug (kauj ruam 9), thiab koj lub taub dag yuav ua rau txhua tus neeg uas tsis kam noj tswm ciab
Tsev DECORATION WITH FAKE INDUSTRIAL HIGH PRESSURE BULB: 6 Kauj Ruam (nrog Duab)
KEV KHO TSHUAJ TSEV KAWM NTAWV nrog FAKE INDUSTRIAL HIGH PRESSURE BULB: Kuv tau pom hauv cov vaj tsev seem qee qhov zoo nkauj zoo li lub teeb qhov muag teev. Kuv tuaj nrog qee lub tswv yim los ua lub teeb pom kev zoo hauv tsev los ntawm cov teeb tawg no thiab sau ob peb qhov muag teev. Hnub no, Kuv txaus siab qhia yuav ua li cas kuv thiaj tig cov qij no mus rau deco tsev
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