from machine import Pin
import utime
Sensor = Pin(3,Pin.IN)

while True:
    while Sensor.value() == 0:
        print("Objetivo detectado")
        utime.sleep(.25)
    while Sensor.value() == 1:
        print("No hay objetivos")
        utime.sleep(.25)

BOOTSELLED1239USBRaspberryPiPico©2020RP2-8020/21P64M15.00TTT