from machine import Pin
import time
sens = Pin(0, Pin.IN)
led = Pin(5, Pin.OUT)
while True:
hep = sens.value()
if hep == 1:
print("Heyyy je t'ai vu!!! ", hep)
led.value(1)
time.sleep(5)
time.sleep(1)
print(hep)
led.value(0)
from machine import Pin
import time
sens = Pin(0, Pin.IN)
led = Pin(5, Pin.OUT)
while True:
hep = sens.value()
if hep == 1:
print("Heyyy je t'ai vu!!! ", hep)
led.value(1)
time.sleep(5)
time.sleep(1)
print(hep)
led.value(0)