Cov txheej txheem:
- Kauj ruam 1: Tau txais cov khoom siv
- Kauj Ruam 2: Ua Haujlwm Hauv Luv luv
- Kauj Ruam 3: Cia Ua Qhov Sib Txuas
- Kauj Ruam 4: Tshaj Tawm Arduino Code
- Kauj Ruam 5: Qhib Txoj Haujlwm Ua Haujlwm
Video: Flappy Bird Siv Arduino thiab Ua: 5 Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:26
Nyob zoo sawv daws !!!
Txais tos rau qhov tshiab Arduino raws txoj haujlwm. Peb txhua tus muaj ib zaug hauv peb lub neej lub sijhawm ua si flappy noog game. Yuav ua li cas yog tias peb ua nws ntawm peb lub PC thiab tswj nws siv peb Arduino ?? Ua raws txhua qib hauv qab no thiab thaum kawg ntawm qhov kev qhia no koj yuav tswj hwm qhov kev ua si siv koj lub microcontroller.
Kauj ruam 1: Tau txais cov khoom siv
Yog li rau txoj haujlwm no peb yuav siv Arduino Uno Board thiab SR-04 Ultrasonic sensor. Kuv qhia koj kom yuav cov khoom no los ntawm UTSource.net vim lawv muab cov khoom siv hluav taws xob qis thiab cov qauv uas tsis muaj kev cuam tshuam zoo. Xyuas lawv tawm !!!
1 X Arduino Uno
1 X SR-04Ultrasonic Sensor
Ib daim ntawv qhia zaub mov (xaiv tau) thiab ob peb kab ntawv xov tooj
Kauj Ruam 2: Ua Haujlwm Hauv Luv luv
Vim li cas peb siv lub ntsuas ultrasonic ntawm no yog kom tau txais cov ntaub ntawv nrug ntawm peb txhais tes thiab
sensor thiab siv cov txiaj ntsig no los kho qhov siab ntawm cov noog txav chaw. Qhov kev ua si yog tsim hauv Kev Ua thiab Arduino sib txuas lus nrog nws siv cov chaw nres nkoj txuas. Kuv tau txuas ob peb cov duab ntawm qhov kev ua si saum toj no yog li saib lawv txhawm rau kom tau txais qee lub tswv yim txog txoj haujlwm no.
Kauj Ruam 3: Cia Ua Qhov Sib Txuas
Ua ntej tshaj txuas SR-04
sensor mus rau Arduino board. Raws li tsuas muaj ib lub sensor rau interface Kuv yuav tsis ntxiv daim duab kos rau qhov haujlwm no. Cov kev sib txuas yog raws li hauv qab no -
SR-04 >> Arduino Uno
Vcc >> 5V
Nwg >> Gnd
Pib Pin >> Digital pin 11
Echo Pin >> Digital pin 10
Ntawd yog qhov kev sib txuas tau ua tiav.
Kauj Ruam 4: Tshaj Tawm Arduino Code
Tam sim no lub sijhawm los tshaj tawm cov cai rau koj pawg thawj coj Arduino.
Download tau cov cai los ntawm hauv qab no.
Ua ntej rub tawm cov cai kom ntseeg tau xaiv qhov chaw com kom raug thiab tus nqi baud raws li peb yuav siv nws rau xa cov ntaub ntawv mus rau qhov kev ua si.
***************************************************
void teeb tsa ()
{
tus pinMode (trigPin, OUTPUT);
pinMode (echoPin, INPUT);
Serial.begin (9600); // Teeb tus nqi baud ntawm no
}
*******************************************************
Kauj Ruam 5: Qhib Txoj Haujlwm Ua Haujlwm
Thaum cov lej Arduino tau rub tawm, rub tawm thiab qhib
ua txoj cai. Ib zaug ntxiv teeb tsa tus lej qub thiab hais txog qhov chaw nres nkoj com kom raug raws li koj tau ua dhau los.
*******************************************************
void teeb tsa () {
loj (400, 600);
p1.x = dav + 50;
p2.x = dav + 220;
p3.x = dav + 370;
myPort = Serial tshiab (qhov no, "COM3", 9600); // Hloov qhov chaw nres nkoj com thiab tus nqi baud ntawm no
myPort.bufferUntil (10);
}
********************************************************
Tam sim no cia peb sim qhov kev ua si no. Tsuas yog nyem rau ntawm lub pob khiav hauv kev ua tswv yim thiab koj zoo mus.
Tus noog txav raws qhov deb ntawm koj txhais tes thiab lub ntsuas cua.
Vam tias koj nyiam qhov kev qhia me me no. Yog tias yog, thov qhia qee qhov kev txhawb nqa los ntawm nias lub pob nyiam thiab qhia rau koj cov phooj ywg. Yog tias koj xav tau ib qho kev pab thov tawm tswv yim hauv qab no. Qhov ntawd yog rau hnub no cov txiv neej. Saib koj yuav sai sai nrog lwm qhov project txaus.
Pom zoo:
Arduino Flappy Bird - Arduino 2.4 "TFT Touchscreen SPFD5408 Bird Game Project: 3 Kauj Ruam
Arduino Flappy Bird | Arduino 2.4 "TFT Touchscreen SPFD5408 Bird Game Project: Flappy Bird yog qhov kev ua si nrov dhau los nyob rau ob peb xyoos thiab ntau tus neeg tsim nws hauv thier tus kheej txoj kev yog li kuv, Kuv tsim kuv li version ntawm flappy noog nrog Arduino thiab pheej yig 2.4" TFT Touchscreen SPFD5408, Yog li cia peb pib ua
Arduino Neeg Hlau Nrog Kev Nyob, Kev Qhia thiab Qib Kev Sib Hloov (Sab Hnub Poob, Sab Hnub Poob, Sab Qaum Teb, Sab Qab Teb) Tswj los ntawm Lub Suab Siv Bluetooth Module thiab Kev Siv Tus Neeg Siv Hluav Taws Xob: 6 Kauj Ruam
Arduino Neeg Hlau Nrog Kev Nyob, Kev Qhia thiab Qib Kev Sib Hloov (Sab Hnub Poob, Sab Hnub Poob, Sab Qaum Teb, Sab Qab Teb) Tswj los ntawm Lub Suab Siv Bluetooth Module thiab Kev Siv Tus Neeg Siv Hluav Taws Xob: Cov lus qhia no piav qhia yuav ua li cas thiaj tsim tau Arduino Robot uas tuaj yeem txav mus raws qhov xav tau (Forward, Backward) , Sab laug, Txoj Cai, Sab Hnub Poob, Sab Hnub Poob, Sab Qaum Teb, Sab Qab Teb) xav tau Kev nrug deb hauv Centimeters siv lub suab hais kom ua. Neeg hlau kuj tseem tuaj yeem txav tau tus kheej
BBC Microbit Flappy Bird Game thiab Case: 7 Kauj Ruam
BBC Microbit Flappy Bird Game thiab Case: Cov ntaub ntawv no rau BBC microbit Thiab kev ua si rau kev lom zem tsis kawg
Flappy Bird ntawm ATtiny85 thiab OLED Display SSD1306: 6 Cov Kauj Ruam (nrog Duab)
Flappy Bird ntawm ATtiny85 thiab OLED Display SSD1306: Hav Txhua Tus, Hnub no kuv yuav qhia koj qhov yooj yim flappy noog clone uas kuv tau tsim, thiab yuav ua li cas koj tuaj yeem mus ua qhov kev ua si zoo sib xws. Kuv yuav yeej ib txwm hla dhau kuv cov cai nrog koj thiab piav qhia nws ua haujlwm li cas txhua kauj ruam ntawm txoj kev. Qhov game no yog tsim los rau ru
8 Relay Tswj Nrog NodeMCU thiab IR Txais Txais Siv WiFi thiab IR Chaw Taws Teeb thiab Android App: 5 Kauj Ruam (nrog Duab)
8 Relay Tswj Nrog NodeMCU thiab IR Txais Txais Siv WiFi thiab IR Chaw Taws Teeb thiab Android App: Tswj 8 qhov hloov pauv hloov siv nodemcu thiab ir tus txais tshaj wifi thiab ir chaw taws teeb thiab hauv app.the ir tej thaj chaw deb ua haujlwm ywj pheej ntawm wifi txuas. NTUJ