Last active
June 5, 2020 17:22
-
-
Save lean8086/716c3028a684a6b122d913920933f5cc 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
const int BUTTON_PIN = 2; | |
void setup() { | |
pinMode(BUTTON_PIN, INPUT); | |
pinMode(LED_BUILTIN, OUTPUT); | |
} | |
void loop() { | |
int buttonState = digitalRead(BUTTON_PIN); | |
digitalWrite(LED_BUILTIN, buttonState); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment