Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void setup()
- {
- Serial.begin(115200);
- Serial.println("Leitura do botão");
- pinMode(D1,INPUT);
- }
- void loop()
- {
- if(digitalRead(D1)==0)
- {
- Serial.println("Botão não pressionado");
- }
- else
- {
- Serial.println("Botão pressionado");
- }
- delay(1500);
- }
Add Comment
Please, Sign In to add comment