int buzzerPin = 27; // Define pin for buzzer
void setup() {
pinMode(buzzerPin, OUTPUT); // Set buzzer pin as output
Serial.begin(115200); // Initialize serial communication
}
void loop() {
digitalWrite(buzzerPin, HIGH); // Turn buzzer on
Serial.println("ON"); // Print "ON" to the serial monitor
delay(1000); // Wait for 1 second
digitalWrite(buzzerPin, LOW); // Turn buzzer off
Serial.println("OFF"); // Print "OFF" to the serial monitor
delay(2000); // Wait for 1 second
}