Cov txheej txheem:

Xovxwm (Khawm); // Ib qho Arduino LCD Game: 5 Kauj Ruam (nrog Duab)
Xovxwm (Khawm); // Ib qho Arduino LCD Game: 5 Kauj Ruam (nrog Duab)

Video: Xovxwm (Khawm); // Ib qho Arduino LCD Game: 5 Kauj Ruam (nrog Duab)

Video: Xovxwm (Khawm); // Ib qho Arduino LCD Game: 5 Kauj Ruam (nrog Duab)
Video: LCD & OLED Display Comparison 2024, Kaum ib hlis
Anonim
Xovxwm (Khawm); // Ib qho Arduino LCD Game
Xovxwm (Khawm); // Ib qho Arduino LCD Game

Tsis ntev los no hauv Scouts, Kuv tau ua haujlwm ntawm Game Game tsim cov cim npe. Rau ib qho ntawm qhov yuav tsum tau ua, Kuv tsim qhov kev ua si no siv Arduino uas yog raws li LED Rocker Game. Qhov kev ua si yog ua kom tau qhab nia siab tshaj plaws ntawm cov ntsiab lus tau. Thaum pib qhov kev ua si, koj yuav tsum nias lub pob kom pib, tom qab ntawd yuav muaj tus xub nyob nruab nrab ntawm qhov screen. Muaj lwm tus xub hauv qab nws uas txav hla qhov screen. Thaum cov xub sib tw, koj yuav tsum nias lub pob thiab tuav nws kom txog thaum lub teeb ntsuab ntsuab teeb. Tom qab ntawd koj yuav tau txais cov ntsiab lus, thiab qhov kev ua si yuav nrawm dua.

Khoom siv

  • Arduino Uno lossis Nano
  • Breadboard (me me yog tias koj siv Arduino Uno, nruab nrab yog tias koj siv Arduino Nano)
  • 16x2 LCD npo sib xws nrog Arduino
  • Liab thiab ntsuab LED (ib qho)
  • Pushbutton hloov
  • Creadboard xov hlau
  • Ib 10 kilo ohm resistor
  • Ib tug potentiometer
  • Ob 220 Ohm resistors (koj yuav xav tau lwm tus rau koj lub vijtsam LCD nyob ntawm hom)
  • Yeem: 3d tshuab luam ntawv los ua rooj plaub rau qhov kev ua si

Kauj Ruam 1: Luam lub Pushbutton thiab cov LEDs

Solder Pushbutton thiab LEDs
Solder Pushbutton thiab LEDs
Solder Pushbutton thiab LEDs
Solder Pushbutton thiab LEDs

Txiav qee cov xov hlau txuas thiab txuas lawv rau lub laub thiab lub LEDs. Koj tuaj yeem ua ib qho hauv paus rau LEDS.

Kauj Ruam 2: Tsis teb los tau: Case rau Game

Yeem: Case rau Game
Yeem: Case rau Game

Nov yog cov ntaub ntawv rau rooj plaub luam tawm 3D rau qhov kev ua si no.

Qhov no tau xub tsim los rau Arduino Uno, tab sis tuaj yeem siv nrog Nano.

Kauj Ruam 3: Txuas Tus Kheej Ntawm Lub Circuit Court

Txuas Tus Kheej Ntawm Lub Circuit Court
Txuas Tus Kheej Ntawm Lub Circuit Court
Txuas Tus Kheej Ntawm Lub Circuit Court
Txuas Tus Kheej Ntawm Lub Circuit Court
Txuas Tus Kheej Ntawm Lub Circuit Court
Txuas Tus Kheej Ntawm Lub Circuit Court

Txuas lwm qhov hauv Circuit Court uas siv daim duab kos.

Cov kev sib txuas yog:

  • Arduino 5v rau daim txiag ntoo +, thiab Arduino GND rau lub khob cij -
  • LED thaj av mus rau hauv av breadboard
  • Liab LED rau tus pin 3, thiab ntsuab LED rau tus pin 4
  • Breadboard + rau khawm, thiab lwm sab ntawm lub pob kom tus pin 6 thiab hauv av
  • Breadboard + rau potentiometer davhlau ya nyob twg 1, thiab potentiometer davhlau ya nyob twg 2 rau LCD hauv av
  • Breadboard + rau LCD VCC
  • Potentiometer wiper (tus pin nruab nrab) rau LCD sib piv tus pin
  • LCD Sau Npe Xaiv tus pin rau Arduino tus pin 7
  • LCD RW tus pin rau breadboard -
  • LCD E rau Arduino tus pin 9
  • LCD D4 rau Arduino tus pin 10
  • LCD D5 rau Arduino tus pin 11
  • LCD D6 rau Arduino tus pin 12
  • LCD D7 rau Arduino tus pin 8
  • LCD LED + mus rau daim phiaj +, LCD LED - rau daim phiaj -

Kauj ruam 4: Txoj Cai

Tshaj tawm cov cai rau Arduino.

Xav tias hloov pauv cov cai yog tias koj xav tau, nws yog qhov haujlwm yooj yim dua.

Kauj Ruam 5: Ua Si Game

Ua Si Game!
Ua Si Game!
Ua Si Game!
Ua Si Game!
Ua Si Game!
Ua Si Game!

Nias lub pob thaum tus pointer nyob nruab nrab thiab tuav nws kom pom lub teeb ntsuab thiab nce mus rau qib tom ntej.

Ua tsaug rau qhov tshuaj xyuas Cov Lus Qhia no! Yog tias koj nyiam nws, thov txiav txim siab pov npav rau kuv hauv 1, 000th kev sib tw.

Rau cov neeg uas xav tsis thoob, lub npe raug teeb tsa zoo li kab ntawm Arduino (C ++) code.

Pom zoo: