Cov txheej txheem:

Qhov kawg Arduino Paper Piano: 5 Kauj Ruam
Qhov kawg Arduino Paper Piano: 5 Kauj Ruam

Video: Qhov kawg Arduino Paper Piano: 5 Kauj Ruam

Video: Qhov kawg Arduino Paper Piano: 5 Kauj Ruam
Video: His laptop died so he used his TYPEWRITER. 😭🤷‍♂️ #shorts 2024, Hlis ntuj nqeg
Anonim

Hav Nws Soumojit Rov qab dua nrog txoj haujlwm txias. Nws yog daim ntawv piano kawg nrog tsuas yog arduino. Yuav yog txoj haujlwm zoo rau hnub so lossis tuaj yeem yog qhov zoo tshaj plaws hauv kev nthuav qhia txuj ci ib yam nkaus. Yog li txhua yam ua haujlwm ntawm lub tswv yim ntawm kev muaj peev xwm kov, koj tuaj yeem nyeem ntxiv txog nws ntawm no https://playground.arduino.cc/Main/CapacitiveSensor/. Kuv kuj tsis muaj kev paub ntau txog piano tab sis kuv tau tshawb fawb me ntsis hauv internet thiab kawm qee yam txog piano thiab sau ntawv.

Yog li, hauv cov piano no lawv yog 2 octaves thiab lwm qhov cim c, tag nrho 15 tus yuam sij. Cov yuam sij tau ua los ntawm cov xaum hauv daim ntawv thiab txuas nrog rau arduino ntawm daim ntawv kaw thiab xaim. Lawv kuj yog tus hais lus txuas nrog rau arduino rau qhov tso tawm.

Yog li cia peb ua nws ….

Kauj Ruam 1: Yam Koj Xav Tau

Yam Koj Xav Tau
Yam Koj Xav Tau
Yam Koj Xav Tau
Yam Koj Xav Tau
Yam Koj Xav Tau
Yam Koj Xav Tau

Yog li peb xav tau qee yam khoom siv yooj yim thiab cov cuab yeej los ua qhov piano no.

1) Arduino Nano (Raws li lub hlwb, koj tuaj yeem siv lwm cov qauv arduino zoo li UNO, Mega, thiab lwm yam)

2) 15x1Mega Ohm Resistors.

3) Pawg Thawj Tswj Hwm

4) Cov xov hlau

5) 8-ohm hais lus

6) Ntawv Clips

7) Daim Ntawv Zoo lossis cov qauv luam tawm

8) Cwj mem

Koj tuaj yeem kos tus piano los ntawm koj tus kheej lossis kuv tau ua 15 tus qauv tseem ceeb uas koj tuaj yeem luam tawm thiab sau cov yuam sij nrog xaum.

Kauj ruam 2: Tsim Circuit Court

Tsim lub Circuit
Tsim lub Circuit
Tsim lub Circuit
Tsim lub Circuit
Tsim lub Circuit
Tsim lub Circuit
Tsim lub Circuit
Tsim lub Circuit

Yog li txheeb xyuas cov duab kos hauv Circuit Court thiab tso cov arduino tso rau hauv lub khob cij. tom qab ntawd txuas cov resistors ib sab hauv txoj kev tsheb nqaj hlau thiab lwm sab hauv qhov tshwj xeeb arduino pins (tus pin D3 - D12, A0 - A3) raws li cov lus qhia. Tom qab ntawd txuas txoj kev tsheb ciav hlau nrog tus pin D2. Tam sim no txiav qee cov xaim thiab ntxiv xaim hauv txhua tus pin arduino (tus pin D3 - D12, A0 -A3) qhov twg tus tiv thaiv txuas nrog.

Tom qab ntawd coj koj tus neeg hais lus thiab txuas ib kawg rau tus pin D13 thiab lwm qhov kawg rau hauv av.

Kev tsim hluav taws xob feem ntau ua tiav, tam sim no peb tsuas yog yuav tsum tau ua tus lej thiab yuav tsum tau ua tus yuam sij hauv tus papaer.

Kauj Ruam 3: Cia Ua Qee Qhov Coding

Cia Ua Ib co Coding
Cia Ua Ib co Coding
Cia Ua Ib co Coding
Cia Ua Ib co Coding

Yog li cov cai yooj yim heev thiab muaj kev xaiv yog li koj ua si ib puag ncig nrog nws.

Koj yuav tsum rub tawm lub tsev qiv ntawv ntsuas lub peev xwm thiab tom qab ntawd koj zoo mus

Koj tuaj yeem rub tawm cov cai thiab xa mus rau koj Arduino thiab pib ua si thiab kov cov xaim xaus kom ua nws.

Tsis tas li, koj tuaj yeem teeb tsa daim ntawv ntawm txhua tus yuam sij, tsuas yog saib ntawm cov ntawv pitches.h thiab tom qab ntawd hloov cov ntawv raws li koj xav tau.

Tom qab ua tiav xa cov cai peb tuaj yeem txav mus ua tus yuam sij hauv daim ntawv.

Nco tseg- Tom qab txuas cov xov hlau rau cov keyboard koj yuav xav tau rov ntsuas tus nqi trigeer. Ua ntej tshaj, koj yuav tsum tso tus lej thiab qhib qhov saib ua ntej, koj yuav pom cov pawg ntawm cov lej hauv kab, Tom qab ntawd koj tuaj yeem kov ib qho xaim thiab pom pes tsawg tus lej nce mus yog li koj tuaj yeem teeb tsa tus nqi, yog li yog tus nqi mus saum tus nqi txhais nws yuav tsim lub suab.

Kauj Ruam 4: Ua Cov Yuam Sij Hauv Daim Ntawv

Ua Cov Ntsiab Lus hauv Daim Ntawv
Ua Cov Ntsiab Lus hauv Daim Ntawv
Ua Cov Ntsiab Lus hauv Daim Ntawv
Ua Cov Ntsiab Lus hauv Daim Ntawv

Yog li tam sim no peb muaj txoj haujlwm ua haujlwm, tam sim no koj tuaj yeem kos 15 tus yuam sij hauv ib daim ntawv me lossis tsuas yog luam kuv tus qauv (Txuas hauv qib 1). Tam sim no siv lub siab tawv, xaum xim dub kom puv cov yuam sij no. Sim ua kom tiav cov yuam sij kom thiaj li tuaj yeem ua tau qhov zoo. Tom qab ntawd ntxiv cov ntawv txiav ntawm lwm qhov kawg ntawm cov xov hlau thiab txuas lawv mus rau cov ntawv tuav.

Tam sim no koj zoo mus.

Kauj Ruam 5: Cov Khoom Kawg thiab Xaus

Khoom Kawg thiab Xaus
Khoom Kawg thiab Xaus

Yog tias koj ua txhua yam kom raug koj yuav muaj daim ntawv ntaus piano ua nrog Arduino. Koj tuaj yeem ua si nrog cov cai kom hloov octaves lossis sau ntawv. Yog tias koj muaj microcontroller nrog ntau GPIO (Zoo li - Arduino Mega) koj tuaj yeem ntxiv cov yuam sij ntxiv.

Nws tuaj yeem yog txoj haujlwm hnub so zoo nrog cov khoom siv tsawg dua. Kuv vam tias koj nyiam nws.

Yog tias koj muaj teeb meem lossis tawm tswv yim tsuas yog nug hauv cov lus.

Kuj thov pov npav qhov haujlwm no rau Arduino kev sib tw.

Ua tsaug, ntsib koj tom ntej nrog ib qhov project txaus…..

Thov pov npav rau kuv rau kev sib tw arduino.

Pom zoo: