Cov txheej txheem:

Arduino Telesketch Nrog Led Matrix: 6 Cov Kauj Ruam (nrog Duab)
Arduino Telesketch Nrog Led Matrix: 6 Cov Kauj Ruam (nrog Duab)

Video: Arduino Telesketch Nrog Led Matrix: 6 Cov Kauj Ruam (nrog Duab)

Video: Arduino Telesketch Nrog Led Matrix: 6 Cov Kauj Ruam (nrog Duab)
Video: Калибруем китайские весы BEKA Calibration (градуировать; калибровать; тарировать) 2024, Lub Xya hli ntuj
Anonim
Arduino Telesketch Nrog Led Matrix
Arduino Telesketch Nrog Led Matrix
Arduino Telesketch Nrog Led Matrix
Arduino Telesketch Nrog Led Matrix
Arduino Telesketch Nrog Led Matrix
Arduino Telesketch Nrog Led Matrix

Nov tsuas yog cov lus qhia yooj yim los tsim lub telesketch siv Arduino. Qhov kev tsim qauv no siv Arduino, ob lub cim coj ntawm 8x32, Buzzer, ob lub cav nkag teb chaws thiab qee cov nyees khawm. Peb cia siab tias koj yuav kawm paub siv cov encoders teb thiab coj matrix. Tsis tas li nws vam tias koj yuav muaj kev lom zem ua raws cov kauj ruam thiab tsim koj tus kheej retro telesketch !!

Kauj Ruam 1: Xaiv Cheebtsam

Xaiv Cheebtsam
Xaiv Cheebtsam

Cov ntaub ntawv xav tau:

Rau lub thawv:

  1. DM 2 hli
  2. Acrylic iav (dawb)
  3. Xim (xim uas koj xav tau)
  4. 3D luam tawm npog rau cov encoder teb (daim ntawv txuas nrog)

Rau electronics:

  1. Led matrix 8 x 32 (2 chav nyob)
  2. Teb encoder (2 chav nyob)
  3. Laub khawm (3 chav nyob)
  4. Buzzer
  5. 220 ohm Resistors (2 chav nyob)
  6. Jumper xov hlau (28 chav nyob)
  7. 9V roj teeb

Kauj Ruam 2: Ua Lub Thawv

Ua Lub Thawv
Ua Lub Thawv
Ua Lub Thawv
Ua Lub Thawv
Ua Lub Thawv
Ua Lub Thawv

Txhawm rau ua lub thawv koj yuav muaj kev nkag mus rau lub tshuab laser zoo dua.

Peb tsim lub thawv kom muaj qhov rov zoo saib thiab zoo nkauj uas tsis muaj cov ces kaum. Lub thawv yog ua los ntawm DM ib hom ntoo pheej yig dua thiab zoo tshaj rau kev txiav laser.

Txhawm rau txiav lub thawv koj yuav tsum rub daim ntawv txuas nrog, nws muaj txhua daim duab npaj rau kev txiav ntawm laser.

Txhawm rau txheeb xyuas cov ntu peb pom zoo siv kub yaj nplaum nws muaj zog thiab nrawm.

  1. Firs koj yuav tsum sib koom 2 tav kom ua tau 1 lub zog, thaum kawg koj yuav muaj 2 tav tav txhua tus ua los ntawm 2 tav.
  2. Tom qab ntawd assamble phab ntsa mus rau tus tav.
  3. Coj lub hau ntej thiab nqes lub vijtsam thav duab tom qab.
  4. Xim tag nrho cov ntoo nrog cov xim uas koj nyiam ntau !! (peb xaiv hluav taws xob xiav)
  5. Muab cov iav acrylic tshuaj ntsuam.
  6. Koom nrog lub hau ntej thiab phab ntsa nrog cov tav.
  7. Tsis txhob koom nrog lub nraub qaum kom txog thaum cov khoom siv hluav taws xob nyob hauv qhov chaw.

Kauj Ruam 3: Mounting Electronics

Mounting Electronics
Mounting Electronics

Daim duab saum toj no qhia txog kev teeb tsa ntawm txoj haujlwm. Lub Circuit Court yuav tsum teeb tsa raws li hauv qab no:

  • Txuas cov xaim liab los ntawm 5V tus pin ntawm Arduino mus rau qhov zoo ntawm lub khob cij.
  • Txuas cov xaim dub los ntawm GND tus pin ntawm arduino mus rau qhov tsis zoo ntawm lub khob cij
  • Buzzer = tus pin 8
  • Coj matrix

    • VCC
    • GND
    • DI = pin 12
    • CS = pin 11
    • CLK = pin 10
  • Teb encoder (1)

    • VCC
    • GND
    • DT = pin 3
    • CLK = pin 4
  • Teb encoder (2)

    • VCC
    • GND
    • CS = pin 5
    • CLK = pin 6
  • Laub khawm (rov pib dua) = tus pin 1
  • Laub khawm (ua si) = tus pin 2

Kauj ruam 4: Txoj Cai

Tam sim no koj tau ua tiav kev teeb tsa, nws yog lub sijhawm rau code. Koj tuaj yeem luam te cov cai hauv qab no thiab hloov kho nws txhawm rau txhim kho telesketch.

// Peb ib txwm yuav tsum suav nrog cov tsev qiv ntawv

#include "LedControl.h" #include "pitches.h" LedControl lc = LedControl (12, 11, 10, 8); koj val; int encoder0PinA = 3; int encoder0PinB = 4; int encoder0Pos = 0; int encoder0PinALast = LOW; int n = LOW; koj valo; int encoder1PinA = 5; int encoder1PinB = 6; int encoder1Pos = 0; int encoder1PinALast = LOW; int o = LOW; int chaw nyob = 3; cov khoom siv = lc.getDeviceCount (); int nkauj = NOTE_D5; int suab paj nruag 1 = NOTE_C5; int ntev = 50; boolean play = cuav; boolean menu = cuav; unsigned ntev ncua sij hawm = 500; teeb tsa tsis muaj dab tsi () {pinMode (2, INPUT); pinMode (1, INPUT); pinMode (7, INPUT); pinMode (encoder0PinA, INPUT); pinMode (encoder0PinB, INPUT); pinMode (encoder1PinA, INPUT); pinMode (encoder1PinB, INPUT); Serial.begin (9600); cov khoom siv = lc.getDeviceCount (); rau (int chaw nyob = 0; chaw nyob = 0) {yog (encoder1Pos 4) {yog (encoder1Pos> 7) {adress--; encoder1Pos = 0; }} yog (chaw nyob <3) {yog (encoder1Pos 3 && chaw nyob <7) {yog (encoder1Pos 7) {chaw nyob += 4; encoder0Pos = 0; } yog (encoder0Pos <0) {adress -= 4; encoder0Pos = 7; }} void Movement () {n = digitalRead (encoder0PinA); yog ((encoder0PinALast == LOW) && (n == HIGH)) {yog (digitalRead (encoder0PinB) == LOW) {encoder0Pos--; suab nrov (8, suab paj nruag 1, 50); } lwm {encoder0Pos ++; suab (8, suab paj nruag, 50); }} encoder0PinALast = n; o = digitalRead (encoder1PinA); yog ((encoder1PinALast == LOW) && (o == HIGH)) {yog (digitalRead (encoder1PinB) == LOW) {encoder1Pos--; suab nrov (8, suab paj nruag 1, 50); } lwm {encoder1Pos ++; suab (8, suab paj nruag, 50); }} encoder1PinALast = o; cov khoom siv = lc.getDeviceCount (); } void omple () {int devices = lc.getDeviceCount (); for (int row = 0; row <8; row ++) {for (int address = 0; address <devices; address ++) {lc.setLed (chaw nyob, kab, 7, tseeb); lc.setLed (chaw nyob, kab, 6, tseeb); lc.setLed (chaw nyob, kab, 5, tseeb); lc.setLed (chaw nyob, kab, 4, tseeb); lc.setLed (chaw nyob, kab, 3, tseeb); lc.setLed (chaw nyob, kab, 2, tseeb); lc.setLed (chaw nyob, kab, 1, tseeb); lc.setLed (chaw nyob, kab, 0, tseeb); ncua (50); }}} tsis muaj nuj nqis neteja () {int devices = lc.getDeviceCount (); for (int row = 0; row <8; row ++) {for (int address = 0; address <devices; address ++) {lc.setLed (chaw nyob, kab, 7, cuav); lc.setLed (chaw nyob, kab, 6, cuav); lc.setLed (chaw nyob, kab, 5, cuav); lc.setLed (chaw nyob, kab, 4, cuav); lc.setLed (chaw nyob, kab, 3, cuav); lc.setLed (chaw nyob, kab, 2, cuav); lc.setLed (chaw nyob, kab, 1, cuav); lc.setLed (chaw nyob, kab, 0, cuav); }} ua si =! ua si; }

Kauj ruam 5: Tiav Kov

Tiav Kov
Tiav Kov

Hauv cov ntsiab lus no koj tuaj yeem hloov kho qhov tsim ntawm rooj plaub los ntawm kev ntxiv qee cov yas yas thiab cov ntawv luam tawm 3D rau cov khoos phis tawj teb.

Cov ntaub ntawv rau tus qauv 3D yog qhov kawg ntawm daim ntawv hauv cov qauv.

Kauj Ruam 6: Ua Si & Txaus Siab

Ua Si & Txaus Siab
Ua Si & Txaus Siab
Ua Si & Txaus Siab
Ua Si & Txaus Siab

Nov yog qhov haujlwm lom zem heev, peb muaj kev lom zem heev tsim nws. Tam sim no yog lub sijhawm los ua si thiab rov nco txog thaum yau !!

Peb tso koj ob peb daim duab rau koj sim !!

Pom zoo: