Created
November 19, 2020 17:00
-
-
Save yemreeke/2abed874b8ecfdadaa277c1257f19554 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int Ledler[] = {2,3,4,5,6,7}; | |
int potDeger; | |
void setup() { | |
for(int i=0;i<6;i++){ | |
pinMode(Ledler[i],OUTPUT); | |
} | |
} | |
void loop() { | |
for(int i=0;i<6;i++){ | |
potDeger = analogRead(A0); | |
digitalWrite(Ledler[i],HIGH); | |
delay(potDeger); | |
digitalWrite(Ledler[i],LOW); | |
} | |
for(int i=4;i>0;i--){ | |
potDeger = analogRead(A0); | |
digitalWrite(Ledler[i],HIGH); | |
delay(potDeger); | |
digitalWrite(Ledler[i],LOW); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment