Cov txheej txheem:

Visuino Running LED: 9 Kauj Ruam
Visuino Running LED: 9 Kauj Ruam

Video: Visuino Running LED: 9 Kauj Ruam

Video: Visuino Running LED: 9 Kauj Ruam
Video: Boombot V2 S1E8 RemoteXY with WS2812B Neopixels 2024, Kaum ib hlis
Anonim

Hauv qhov kev qhia no peb yuav siv 6x LED, Arduino UNO, thiab Visuino kom khiav LED lub teeb siv cov khoom sib dhos. Cov ntu ntu yog qhov zoo tshaj rau cov xwm txheej uas peb xav ua kom muaj ntau yam xwm txheej hauv ib ntu.

Saib daim vis dis aus.

Kauj ruam 1: Yam Koj Yuav Tsum Tau

Koj Yuav Tsum Tau Dab Tsi
Koj Yuav Tsum Tau Dab Tsi
Koj Yuav Tsum Tau Dab Tsi
Koj Yuav Tsum Tau Dab Tsi
Koj Yuav Tsum Tau Dab Tsi
Koj Yuav Tsum Tau Dab Tsi
  • Arduino UNO (lossis lwm yam Arduino)
  • Jumper xov hlau
  • 6 x LEDs
  • Cov qhob cij
  • Visuino program: Rub tawm Visuino

Kauj Ruam 2: Pib Visuino, thiab Xaiv Arduino UNO Board Type

Pib Visuino, thiab Xaiv Arduino UNO Board Type
Pib Visuino, thiab Xaiv Arduino UNO Board Type
Pib Visuino, thiab Xaiv Arduino UNO Board Type
Pib Visuino, thiab Xaiv Arduino UNO Board Type

Txhawm rau pib ua haujlwm rau Arduino, koj yuav tsum muaj Arduino IDE teeb tsa los ntawm no:

Thov nco ntsoov tias muaj qee qhov teeb meem tseem ceeb hauv Arduino IDE 1.6.6. Nco ntsoov tias koj nruab 1.6.7 lossis siab dua, txwv tsis pub Cov Lus Qhia no yuav tsis ua haujlwm! Yog tias koj tsis tau ua raws cov kauj ruam hauv Phau Ntawv Qhia no teeb tsa Arduino IDE rau program Arduino UNO! Visuino: https://www.visuino.eu tseem yuav tsum tau teeb tsa. Pib Visuino raws li pom hauv thawj daim duab Nyem rau ntawm "Cov cuab yeej" khawm ntawm Arduino tivthaiv (Daim Duab 1) hauv Visuino Thaum qhov kev sib tham tshwm, xaiv "Arduino UNO" raws li qhia hauv daim duab 2

Kauj Ruam 3: Hauv Visuino Ntxiv Cheebtsam

Hauv Visuino Ntxiv Cheebtsam
Hauv Visuino Ntxiv Cheebtsam
Hauv Visuino Ntxiv Cheebtsam
Hauv Visuino Ntxiv Cheebtsam
  • Ntxiv "Sequence" tivthaiv
  • Ntxiv 6x "Toggle (T) Flip-Flop" tivthaiv

Kauj Ruam 4: Hauv Visuino Teeb Cov Khoom

Hauv Visuino Teeb Cov Txheej Txheem
Hauv Visuino Teeb Cov Txheej Txheem
Hauv Visuino Teeb Cov Txheej Txheem
Hauv Visuino Teeb Cov Txheej Txheem

Xaiv "Sequence1" tivthaiv thiab hauv cov khoom qhov rai teeb tsa "Rov Ua" rau "Muaj tseeb"

Xaiv "Sequence1" tivthaiv, ob npaug nias rau nws. Hauv "Elements" Dialog: Drag 6X "Digital Period" keeb rau sab laug.

Xaiv "Digital Period1" lub ntsiab lus thiab hauv qab qhov khoom teeb tsa "Ncua" rau "30"

  • Xaiv "Digital Period2" lub ntsiab lus thiab hauv qab qhov khoom teeb tsa "Ncua" rau "60"
  • Xaiv "Digital Period3" lub ntsiab lus thiab hauv qab qhov khoom tsim teeb tsa "Ncua" rau "90"
  • Xaiv "Digital Period4" lub ntsiab lus thiab hauv qab qhov khoom tsim teeb tsa "Ncua" rau "120"
  • Xaiv "Digital Period5" lub ntsiab lus thiab hauv qab qhov khoom tsim teeb tsa "Ncua" rau "150"
  • Xaiv "Digital Period6" lub ntsiab lus thiab hauv qab qhov khoom tsim teeb tsa "Ncua" rau "180"

Kauj Ruam 5: Hauv Visuino Connect Components

Hauv Visuino Connect Components
Hauv Visuino Connect Components
  • Txuas "Sequence1" tivthaiv "Digital Period1" tus pin [Tawm] rau "TFlipFlop1" tivthaiv tus pin [Clock]
  • Txuas "Sequence2" tivthaiv "Digital Period1" tus pin [Tawm] mus rau "TFlipFlop2" tivthaiv tus pin [Clock]
  • Txuas "Sequence3" tivthaiv "Digital Period1" tus pin [Tawm] mus rau "TFlipFlop3" tivthaiv tus pin [Clock]
  • Txuas "Sequence4" tivthaiv "Digital Period1" tus pin [Tawm] rau "TFlipFlop4" tivthaiv tus pin [Clock]
  • Txuas "Sequence5" tivthaiv "Digital Period1" tus pin [Tawm] mus rau "TFlipFlop5" tivthaiv tus pin [Clock]
  • Txuas "Sequence6" tivthaiv "Digital Period1" tus pin [Tawm] mus rau "TFlipFlop6" tivthaiv tus pin [Clock]
  • Txuas "TFlipFlop1" tiv thaiv tus pin [Tawm] rau Arduino board Digital tus pin [4]
  • Txuas "TFlipFlop2" tiv thaiv tus pin [Tawm] rau Arduino board Digital tus pin [5]
  • Txuas "TFlipFlop3" tiv thaiv tus pin [Tawm] rau Arduino board Digital tus pin [6]
  • Txuas "TFlipFlop4" tiv thaiv tus pin [Tawm] rau Arduino board Digital tus pin [7]
  • Txuas "TFlipFlop5" tiv thaiv tus pin [Tawm] rau Arduino board Digital tus pin [8]
  • Txuas "TFlipFlop6" tiv thaiv tus pin [Tawm] rau Arduino board Digital tus pin [9]

Kauj Ruam 6: Circuit Court

Qhov Circuit
Qhov Circuit
  • Txuas LED1 tus pin zoo (Anode) rau Arduino Digital tus pin [4]
  • Txuas LED2 tus pin zoo (Anode) rau Arduino Digital tus pin [5]
  • Txuas LED3 tus pin zoo (Anode) rau Arduino Digital tus pin [6]
  • Txuas LED4 tus pin zoo (Anode) rau Arduino Digital tus pin [7]
  • Txuas LED5 tus pin zoo (Anode) rau Arduino Digital tus pin [8]
  • Txuas LED6 tus pin zoo (Anode) rau Arduino Digital tus pin [9]

Txuas Arduino tus pin [GND] rau breadboard GND tus pin

  • Txuas LED1 tus pin tsis zoo (Cathode) mus rau lub rooj noj mov GND tus pin
  • Txuas LED2 tus lej tsis zoo (Cathode) mus rau lub rooj noj mov GND tus pin
  • Txuas LED3 tus pin tsis zoo (Cathode) mus rau lub rooj noj mov GND tus pin
  • Txuas LED4 tus pin tsis zoo (Cathode) mus rau lub rooj noj mov GND tus pin
  • Txuas LED5 tus pin tsis zoo (Cathode) mus rau lub rooj noj mov GND tus pin
  • Txuas LED6 tus lej tsis zoo (Cathode) mus rau lub rooj noj mov GND tus pin

Kauj Ruam 7: Tsim, Ua Ke, thiab Tshaj Tawm Arduino Code

Tsim, Sau, thiab Tso Tawm Arduino Code
Tsim, Sau, thiab Tso Tawm Arduino Code

Hauv Visuino, hauv qab nyem rau ntawm "Tsim" Tab, xyuas kom tseeb tias qhov chaw nres nkoj raug xaiv, tom qab ntawd nyem rau ntawm "Compile/Build and Upload" khawm.

Kauj ruam 8:

Kauj ruam 9: Ua si

Yog tias koj siv zog Arduino UNO module, LEDs yuav tsum pib ua haujlwm.

Nrog koj zoo siab! Koj tau ua tiav koj txoj haujlwm nrog Visuino.

Kuj txuas nrog yog Visuino qhov haujlwm, uas kuv tau tsim rau qhov Qhia Qhia no. Koj tuaj yeem rub tawm thiab qhib nws hauv Visuino:

Pom zoo: