Cov txheej txheem:

Arduino Minutes Tracker: 3 Kauj Ruam
Arduino Minutes Tracker: 3 Kauj Ruam

Video: Arduino Minutes Tracker: 3 Kauj Ruam

Video: Arduino Minutes Tracker: 3 Kauj Ruam
Video: Amazing arduino project 2024, Kaum ib hlis
Anonim
Arduino feeb taug qab
Arduino feeb taug qab
Arduino feeb taug qab
Arduino feeb taug qab

Tinkercad Cov Haujlwm »

Hauv qhov kev qhia no, Kuv yuav qhia koj yuav ua li cas los ua tus feeb taug qab siv Arduino Uno. Tus feeb taug qab yog lub cuab yeej uas koj tuaj yeem siv los taug qab seb koj ua haujlwm ntev npaum li cas nyob rau qee lub sijhawm. Koj nias lub pob pib kom pib suav feeb, thiab nias lub khawm pib dua/cav kom xa cov feeb ntawd mus rau ib daim ntawv. Cov ntaub ntawv tuaj yeem nkag mus thiab koj tuaj yeem pom pes tsawg feeb uas koj tau sau ua ke dhau sijhawm.

Khoom siv

Arduino Ib

Cov qhob cij

18 jumper xov hlau

4 tus lej 7-ntu tso saib

2 cov nyees khawm

2 10k ohm resistors

Kauj ruam 1: Tsim Kho Vajtse

Tsim Kho Vajtse
Tsim Kho Vajtse

Ua raws li cov txheej txheem saum toj no los tsim koj cov logger feeb.

Nco tseg: sab laug-tus lej feem ntau ntawm 7-ntu zaub tau sab laug tsis txuas vim tias txhua tus pin tau siv. Yog tias koj xav siv tag nrho 4 tus lej, sim Arduino Mega.

Nco tseg: ntau lub npe ntawm cov khoom siv yuav raug teeb tsa sib txawv. Nco ntsoov xyuas cov xov txuas ncaj qha rau koj cov khoom siv.

Kauj ruam 2: Code Software

Code Software
Code Software
Code Software
Code Software
Code Software
Code Software

Muaj peb tus neeg hloov pauv rau coding software: coding timer, txuas cov zaub, thiab siv kev txiav ntoo. Yog tias koj tau daig lossis tsis xav sau tus lej no rau koj tus kheej, xav tias dawb los txheeb xyuas kuv tus lej ntawm no:

Tswv yim: thaum sau tus lej, muaj qhov program teev vib nas this (tsis yog feeb) kom yooj yim sim.

Coding lub Timer

Thawj ntu ntawm txoj cai tseem ceeb tsim lub sijhawm saib. Nws siv khawm pib/nres thiab rov pib khawm kom taug qab cov feeb. Pib los ntawm kev pib thiab nres khawm ua haujlwm: luam sijhawm dhau mus rau lub console tom qab tsoo lub pob, thiab ncua nws ib zaug koj ntaus lub pob dua. Hint: koj yuav tau siv millis () ua haujlwm.

Hint: koj yuav tau ntxiv qhov ncua sijhawm li ntawm 20-50ms kom ntseeg tau tias lub pob tsis qhib thiab kaw nrog nias ib zaug.

Thaum koj tau ua txoj haujlwm no, cov kauj ruam tom ntej yog suav nrog kev ncua. Piv txwv li, yog tias koj pib, nres, thiab rov pib dua, koj xav kom lub sijhawm ua haujlwm txuas ntxiv qhov uas koj tawm mus. Kuv tau ua qhov no los ntawm kev taug qab qhov ntev ntawm kev ncua thiab rho tawm qhov no los ntawm lub sijhawm ua ntej luam tawm nws.

Tam sim no tias koj pib/nres khawm tau ua haujlwm, cov kauj ruam tom ntej yog khawm rov pib dua. Qhov ua haujlwm ntawm qhov no yog teeb tsa lub sijhawm rov qab rau 0. Hint: nco ntsoov rov pib koj lub sijhawm pib thiab ncua sijhawm hloov pauv.

Txuas Cov Zaub

Thaum koj qhov haujlwm tau ua raws lub sijhawm ua tiav, koj yuav tsum xa cov ntaub ntawv sijhawm mus rau 4-lej 7-ntu tso saib. Koj tuaj yeem tsim txoj haujlwm suav los ntawm kos lossis tau txais kev pab online txhawm rau qhia qee tus lej. Nco ntsoov teeb tsa qhov txwv ntawm tus nqi siab tshaj plaws uas koj tuaj yeem pom (yog tias koj siv 3 tus lej no yuav yog 999).

Siv Kev Txiav Txim

Kauj ruam kawg yog txhawm rau taug qab cov ntaub ntawv sijhawm hauv cov ntaub ntawv. Qhov no yuav ua tiav siv Kev Ua Haujlwm, yog li xyuas kom koj tau rub tawm nws ua ntej pib ua cov kauj ruam no. Koj tuaj yeem khaws cov ntaub ntawv sijhawm raws li txoj hauv kev uas yuav pab tau rau koj. Tus kheej, Kuv muaj kab ntawv rau lub sijhawm nkag thiab tag nrho lub sijhawm. Hint: siv chav kawm PrintWriter los sau rau hauv.txt cov ntaub ntawv.

Kauj ruam 3: Ua tiav

Qhov ntawd yog nws! Xav tias dawb los ntxiv rau txoj haujlwm no thiab kho nws rau yam koj tab tom nrhiav. Ua tsaug rau kev nyeem ntawv.

Pom zoo: