from machine import Pin,PWM
import time
buzzer = PWM(Pin(4,Pin.OUT))
while True:
    buzzer.freq(1047)
    buzzer.duty(50)
    time.sleep(0.5)