mirror of
https://github.com/arduino/Arduino.git
synced 2025-02-20 14:54:31 +01:00
added a slight delay to loop in DigitalReadSerial example so we don't overload Serial Monitor
This commit is contained in:
parent
c44329d732
commit
59f7f988d7
@ -22,6 +22,7 @@ void loop() {
|
||||
int buttonState = digitalRead(pushButton);
|
||||
// print out the state of the button:
|
||||
Serial.println(buttonState);
|
||||
delay(1); // delay in between reads for stability
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user