Skip to content

Instantly share code, notes, and snippets.

@michaelsarduino
Created December 22, 2015 18:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save michaelsarduino/b0ccf5870537944917f9 to your computer and use it in GitHub Desktop.
Save michaelsarduino/b0ccf5870537944917f9 to your computer and use it in GitHub Desktop.
void setup() {
pinMode(2, INPUT);
Serial.begin(9600);
}
void loop() {
if(digitalRead(2) == HIGH)
{
Serial.println("Laerm!");
}
else
{
Serial.println("Ruhe...");
}
delay(10);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment