#define PIR_PIN 15  
#define LED_PIN 18  

void setup() {
  pinMode(PIR_PIN, INPUT);  
  pinMode(LED_PIN, OUTPUT);  
  Serial1.begin(115200);
  Serial1.println("Hello Raspberry Pi Pico");
}

void loop() {
  int pirState = digitalRead(PIR_PIN);  
  if (pirState == HIGH) {
    Serial1.println("Motion Detected");
    digitalWrite(LED_PIN, HIGH);  
    delay(500);  
  } else {
    Serial1.println("No Motion");
    digitalWrite(LED_PIN, LOW);  
    delay(500);
  }
}
BOOTSELLED1239USBRaspberryPiPico©2020RP2-8020/21P64M15.00TTT