daily pastebin goal
1%
SHARE
TWEET

Untitled

a guest Jan 23rd, 2019 86 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. int sensoreP = 2;
  2. int motB = 3;
  3. void setup() {
  4.     pinMode(sensoreP, INPUT);
  5.     pinMode(motB, OUTPUT);
  6. }
  7. void loop(){
  8.     digitalWrite(motB, HIGH);
  9.     delay(2000);
  10.     while (digitalRead(sensoreP) == 0) {
  11.         digitalWrite(motB, HIGH);
  12.     }
  13.     digitalWrite(motB, LOW);
  14.     delay(20000);
  15.    
  16. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top