Cov txheej txheem:

LED Ntaus Nrog Bluetooth: Nkag Mus Rau Lwm Qhov Chaw Dimension: 6 Kauj Ruam
LED Ntaus Nrog Bluetooth: Nkag Mus Rau Lwm Qhov Chaw Dimension: 6 Kauj Ruam

Video: LED Ntaus Nrog Bluetooth: Nkag Mus Rau Lwm Qhov Chaw Dimension: 6 Kauj Ruam

Video: LED Ntaus Nrog Bluetooth: Nkag Mus Rau Lwm Qhov Chaw Dimension: 6 Kauj Ruam
Video: Часы G Shock до 100 долларов-15 лучших часов Casio G Shock до 100 дол... 2024, Kaum ib hlis
Anonim
LED Ntaus Nrog Bluetooth: Nkag Mus Rau Lwm Qhov Chaw Dimension
LED Ntaus Nrog Bluetooth: Nkag Mus Rau Lwm Qhov Chaw Dimension

Nov yog lub teeb pom kev zoo LED ua haujlwm rau kuv qhov haujlwm duab puab hu ua Lub Hom Phiaj Dawb Huv. Kuv siv cov cuab yeej no los nthuav qhia nkag mus rau lub ntiaj teb tshiab. Thaum kuv qhib lub teeb ci LED, peb tuaj yeem pom qhov tsis muaj qhov kawg hauv lub thawv ntawv. Qhov LED sawb yog tswj los ntawm bluetooth ntawm kuv lub xov tooj. Kuv tau yuav txhua yam khoom siv ntawm Amazon.

Cov ntaub ntawv:

- Arduino Ib

-LED sawb

-9v roj teeb

-DSD Tech SH-HC-08 Bluetooth 4.0 BLE qhev Module

-330 Ohms resistor

- iPhone ib

-Concrete

-Acrylic

-Window zaj duab xis (ib txoj kev tsom iav)

-Double sab daim iav zaj duab xis

Kauj Ruam 1: Tsim Circuit Court

Tsim Circuit Court
Tsim Circuit Court
Tsim Circuit Court
Tsim Circuit Court

Nov yog qhov kuv ua kom lub Circuit Court ua haujlwm. Kuv kuj tau tsim ib ntu los sim ua lub zog ntawm lub paj hlwb.

Thawj daim duab yog LED sawb Circuit.

Cov duab thib ob yog Bluetooth Circuit. Lub app ntawm iPhone yog BluetoothLED.

Kauj ruam 2: Arduino Code

#suav nrog

#define LED_PIN 7 #define NUM_LEDS 60 CRGB leds [NUM_LEDS];

teeb tsa tsis muaj dab tsi () {pinMode (LED_PIN, OUTPUT); Serial.begin (9600); FastLED.addLeds (leds, NUM_LEDS); }

void setBlue (int val) {rau (int i = 0; i <NUM_LEDS; i ++) {leds = CRGB (0, 0, val); } FastLED.show (); } void voj () {

yog (Serial.available ()) {val = Serial.read (); } yog (val == 'H') {leds [0] = CRGB (0, 0, 0); FastLED.show (); leds [1] = CRGB (0, 0, 0); FastLED.show (); leds [2] = CRGB (0, 0, 0); FastLED.show (); leds [3] = CRGB (0, 0, 0); FastLED.show (); leds [4] = CRGB (0, 0, 0); FastLED.show ();

leds [5] = CRGB (0, 0, 0); FastLED.show ();

leds [6] = CRGB (0, 0, 0); FastLED.show ();

leds [7] = CRGB (0, 0, 0); FastLED.show ();

leds [8] = CRGB (0, 0, 0); FastLED.show ();

leds [9] = CRGB (0, 0, 0); FastLED.show ();

leds [10] = CRGB (0, 0, 0); FastLED.show ();

leds [11] = CRGB (0, 0, 0); FastLED.show ();

leds [12] = CRGB (0, 0, 0); FastLED.show ();

leds [13] = CRGB (0, 0, 0); FastLED.show ();

leds [14] = CRGB (0, 0, 0); FastLED.show ();

leds [15] = CRGB (0, 0, 0); FastLED.show ();

leds [16] = CRGB (0, 0, 0); FastLED.show ();

leds [17] = CRGB (0, 0, 0); FastLED.show ();

leds [18] = CRGB (0, 0, 0); FastLED.show ();

leds [19] = CRGB (0, 0, 0); FastLED.show ();

leds [20] = CRGB (0, 0, 0); FastLED.show ();

leds [21] = CRGB (0, 0, 0); FastLED.show ();

leds [22] = CRGB (0, 0, 0); FastLED.show ();

leds [23] = CRGB (0, 0, 0); FastLED.show (); leds [24] = CRGB (0, 0, 0); FastLED.show ();

leds [25] = CRGB (0, 0, 0); FastLED.show ();

leds [26] = CRGB (0, 0, 0); FastLED.show ();

leds [27] = CRGB (0, 0, 0); FastLED.show ();

leds [28] = CRGB (0, 0, 0); FastLED.show ();

leds [29] = CRGB (0, 0, 0); FastLED.show ();

leds [30] = CRGB (0, 0, 0); FastLED.show (); leds [31] = CRGB (0, 0, 0); FastLED.show ();

leds [32] = CRGB (0, 0, 0); FastLED.show ();

leds [33] = CRGB (0, 0, 0); FastLED.show (); leds [34] = CRGB (0, 0, 0); FastLED.show ();

leds [35] = CRGB (0, 0, 0); FastLED.show ();

leds [36] = CRGB (0, 0, 0); FastLED.show ();

leds [37] = CRGB (0, 0, 0); FastLED.show ();

leds [38] = CRGB (0, 0, 0); FastLED.show ();

leds [39] = CRGB (0, 0, 0); FastLED.show ();

leds [40] = CRGB (0, 0, 0); FastLED.show ();

leds [41] = CRGB (0, 0, 0); FastLED.show ();

leds [42] = CRGB (0, 0, 0); FastLED.show ();

leds [43] = CRGB (0, 0, 0); FastLED.show (); leds [44] = CRGB (0, 0, 0); FastLED.show ();

leds [45] = CRGB (0, 0, 0); FastLED.show ();

leds [46] = CRGB (0, 0, 0); FastLED.show ();

leds [47] = CRGB (0, 0, 0); FastLED.show ();

leds [48] = CRGB (0, 0, 0); FastLED.show ();

leds [49] = CRGB (0, 0, 0); FastLED.show ();

leds [50] = CRGB (0, 0, 0); FastLED.show ();

leds [51] = CRGB (0, 0, 0); FastLED.show ();

leds [52] = CRGB (0, 0, 0); FastLED.show ();

leds [53] = CRGB (0, 0, 0); FastLED.show (); leds [54] = CRGB (0, 0, 0); FastLED.show ();

leds [55] = CRGB (0, 0, 0); FastLED.show ();

leds [56] = CRGB (0, 0, 0); FastLED.show ();

leds [57] = CRGB (0, 0, 0); FastLED.show ();

leds [58] = CRGB (0, 0, 0); FastLED.show ();

leds [59] = CRGB (0, 0, 0); FastLED.show ();

ncua (100); } lwm {rau (int i = 255; i> 0; i--) {setBlue (i); ncua (10); } rau (int i = 0; i <255; i ++) {setBlue (i); ncua (10); }}}

Kauj Ruam 3: Ua Thawv

Ua Thawv
Ua Thawv
Ua Thawv
Ua Thawv
Ua Thawv
Ua Thawv

Lub thawv yog ua los ntawm cov qhob. Kuv siv cov laug cam ua lub thawv hollow los pov nrog cov qhob. Cia nws qhuav yam tsawg 24 teev.

Kauj Ruam 4: Txiav Laser

Laser Txiav
Laser Txiav
Laser Txiav
Laser Txiav
Laser Txiav
Laser Txiav

Teeb duab zoo haum rau hauv lub thawv ntawv thiab txiav nws nrog Laser txiav.

Kuv siv qhov no rau txheej sib txawv qhov chaw hauv lub npov: qhov chaw xav txog thiab qhov chaw hauv Circuit. Kuv muab ib txoj hauv kev tsom iav qhov rai zaj duab xis thiab ob sab daim iav zaj duab xis tso rau ntawm cov duab plaub fab acrylic.

Kauj Ruam 5: LED Sawb

LED Sawb
LED Sawb
LED Sawb
LED Sawb
LED Sawb
LED Sawb

(Saib los ntawm hauv qab ntawm lub npov)

Kuv tso ib txoj hauv kev tsom iav zaj duab xis thawj zaug, daim iav sab ntsej muag sab hauv ntawm lub thawv. Thiab tshuaj tsuag xim dawb ntawm tus ncej kom tsim tau ib nrab-pob tshab lub raj rau LED kab txaij thiab tso rau hauv nruab nrab ntawm lub thawv.

Kauj ruam 6: Circuit Court

Circuit Court
Circuit Court

Muab ob sab daim iav acrylic tso rau sab saum toj ntawm LED thiab txuas rau Circuit.

Pom zoo: