Orodha ya maudhui:

Taa za Uingiliano za Uga, Taa za Barabara: Hatua 3
Taa za Uingiliano za Uga, Taa za Barabara: Hatua 3

Video: Taa za Uingiliano za Uga, Taa za Barabara: Hatua 3

Video: Taa za Uingiliano za Uga, Taa za Barabara: Hatua 3
Video: Polkadot DeFi: Everything You Need to Know About Polkadot’s First DeFi Panel Series 2024, Desemba
Anonim
Taa za Uga za Maingiliano, Taa za Njia
Taa za Uga za Maingiliano, Taa za Njia
Taa za Uga za Maingiliano, Taa za Njia
Taa za Uga za Maingiliano, Taa za Njia

Nilitaka kujenga taa ya yadi ya kuingiliana kwa yadi yangu ya nyuma. Wazo lilikuwa, wakati mtu anatembea kwa njia moja ingeweka uhuishaji katika mwelekeo uliokuwa unatembea. Nilianza na taa za jua za Dollar General $ 1.00

Hatua ya 1: Toa Taa za Solor

Toa Taa za Solor
Toa Taa za Solor
Toa Taa za Solor
Toa Taa za Solor
Toa Taa za Solor
Toa Taa za Solor

Hatua ya kwanza ilikuwa kugeuza taa ili kupisha vitu vya kufurahisha zaidi. Nilianza kwa kukata mwongozo wa awali na betri. Hakikisha uhifadhi sehemu hizi kwani zitakuwa muhimu katika mradi mwingine pia niliondoa dome ya chrome iliyokuwa chini ya mwangaza wa jua na kuipachika juu kama inavyoonekana kwenye picha

Hatua ya 2: Kufunga Taa Bora

Kufunga Taa Bora
Kufunga Taa Bora
Kufunga Taa Bora
Kufunga Taa Bora
Kufunga Taa Bora
Kufunga Taa Bora

kwa inayoongozwa nilitumia ws2811b isiyo na maji ambayo inaweza kupatikana hapa

www.ebay.com/itm/50-X-12mm-LED-Module-RGB-…

Awali nilipanga kuweka sensorer za PIR ndani ya taa za jua. lakini hii ilidhihirika kuwa ni shida sana kwa sababu sensor haikuweza kuona zamani ya plastiki. lazima iwe na aina fulani ya usahihi wa kuchuja UV. kwa hivyo nilichagua kitu kama hiki

www.thingiverse.com/thing 2590216

Hatua ya 3: Usimbuaji

ikiwa unataka kufanya taa zisitumie sensa au tembea kila wakati tafuta tu mahali panapokuwa na maoni kama "kubadilisha hali ya bendera" na kuiweka kwa ether 1 au 0 nitaongeza picha zaidi nitakapojimalizia hii mwenyewe bado ni kazi inayoendelea lakini nadhani ni nadhifu sana kutoshiriki mara moja. asante kwa kuangalia

usanidi batili () {

// weka nambari yako ya usanidi hapa, kukimbia mara moja: FastLED.addLeds (leds, NUM_LEDS); Serial. Kuanza (9600); pinMode (kifungoPin1, INPUT); pinMode (kifungoPin2, INPUT); }

kitanzi batili () {

Serial.println (Bendera ya Jimbo);

ikiwa (FlagState == 0) {MbeleLeds (); } ikiwa (FlagState == 1) {RevLeds (); } ikiwa (FlagState == 2) {Inasubiri (); }}

batili MbeleLeds () {

KwanzaLed = -1; MwishoLed = 16; kwa (int i = 0; i <8; i ++) {LastLed--; KwanzaLed ++; leds [MwishoLed] = CRGB:: Nyeupe; risasi [KwanzaLed] = CRGB:: Nyeupe; kuchelewesha (750); FastLED.show (); Serial.print ("Pass nyeupe"); Printa ya serial (i); Serial.println ("ya 8"); } KwanzaLed = -1; MwishoLed = 16; kwa (int i = 0; i <8; i ++) {LastLed--; KwanzaLed ++; leds [MwishoLed] = CRGB:: Bluu; risasi [KwanzaLed] = CRGB:: Bluu; kuchelewesha (250); FastLED.show (); Serial.print ("Blue Pass"); Printa ya serial (i); Serial.println ("ya 8"); } KwanzaLed = -1; MwishoLed = 16; kwa (int i = 0; i <8; i ++) {LastLed--; KwanzaLed ++; leds [MwishoLed] = CRGB:: Zambarau; risasi [KwanzaLed] = CRGB:: Zambarau; kuchelewesha (250); FastLED.show (); Serial.print ("Red Pass"); Printa ya serial (i); Serial.println ("ya 8"); } KwanzaLed = -1; MwishoLed = 16; kwa (int i = 0; i <8; i ++) {LastLed--; KwanzaLed ++; leds [MwishoLed] = CRGB:: Nyeusi; risasi [KwanzaLed] = CRGB:: Nyeusi; kuchelewesha (250); FastLED.show (); Serial.print ("Kuzima imesababisha"); Printa ya serial (i); Serial.println ("ya 8"); } Bendera ya Jimbo = 2; // kubadilisha hali ya bendera} batili RevLeds () {Serial.println ("in reverse"); KwanzaLed = 8; MwishoLed = 7; kwa (int i = 0; i <8; i ++) {LastLed ++; KwanzaLed--; leds [MwishoLed] = CRGB:: Nyeupe; risasi [KwanzaLed] = CRGB:: Nyeupe; kuchelewesha (750); FastLED.show (); Serial.print ("Kupitisha nyeupe"); Printa ya serial (i); Serial.println ("ya 8"); } KwanzaLed = 8; MwishoLed = 7; kwa (int i = 0; i <8; i ++) {LastLed ++; KwanzaLed--; leds [MwishoLed] = CRGB:: Bluu; risasi [KwanzaLed] = CRGB:: Bluu; kuchelewesha (250); FastLED.show (); Serial.print ("Blue pass"); Printa ya serial (i); Serial.println ("ya 8"); } KwanzaLed = 8; MwishoLed = 7; kwa (int i = 0; i <8; i ++) {LastLed ++; KwanzaLed--; leds [MwishoLed] = CRGB:: Zambarau; risasi [KwanzaLed] = CRGB:: Zambarau; kuchelewesha (250); FastLED.show (); Serial.print ("Kupita nyekundu"); Printa ya serial (i); Serial.println ("ya 8"); }

KwanzaLed = 8;

MwishoLed = 7; kwa (int i = 0; i <8; i ++) {LastLed ++; KwanzaLed--; leds [MwishoLed] = CRGB:: Nyeusi; risasi [KwanzaLed] = CRGB:: Nyeusi; kuchelewesha (250); FastLED.show (); Serial.print ("Kuzima Kuongozwa"); Printa ya serial (i); Serial.println ("ya 8"); } Bendera ya Jimbo = 2; // kubadilisha hali ya bendera} Kusubiri batili () {buttonState1 = digitalRead (buttonPin1); buttonState2 = digitalRead (buttonPin2); ikiwa (buttonState1 == JUU) {Serial.println ("imesababisha mbele"); Jimbo la Bendera = 0; } mwingine ikiwa (buttonState2 == HIGH) {Serial.println ("Rev ilisababisha"); Jimbo la Bendera = 1; } Serial.println ("kitanzi kimemaliza kusubiri"); }

Ilipendekeza: