Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int led=13,button=12;
- void setup() {
- pinMode(led,OUTPUT);
- pinMode(button,INPUT);
- }
- void loop() {
- if (digitalRead(button)==HIGH)
- digitalWrite(led,HIGH);
- }
- int led=13,button=12;
- void setup() {
- pinMode(led,OUTPUT);
- pinMode(button,INPUT);
- }
- void loop() {
- if (digitalRead(button)==HIGH)
- {
- digitalWrite(led,HIGH);
- delay(1000);
- digitalWrite(led,LOW);
- delay(1000);
- } }
Add Comment
Please, Sign In to add comment